Applying translation for mesh surface filters.

This commit is contained in:
Patrick Shriwise 2021-02-16 21:30:59 -06:00
parent 08e4b43d94
commit 711d9267bd

View file

@ -13,6 +13,11 @@ MeshSurfaceFilter::get_all_bins(const Particle& p, TallyEstimator estimator,
{
Position r0 = p.r_last_current_;
Position r1 = p.r();
if (translated_) {
r0 -= translation();
r1 -= translation();
}
Direction u = p.u();
model::meshes[mesh_]->surface_bins_crossed(r0, r1, u, match.bins_);
for (auto b : match.bins_) match.weights_.push_back(1.0);