From 0d6bc863311c0092fc0a07d2ed50177909bc35ab Mon Sep 17 00:00:00 2001 From: Patrick Shriwise Date: Tue, 25 May 2021 09:21:00 -0500 Subject: [PATCH] Moving history reset on CSG surface crossing to correct location after rebase. --- src/particle.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/particle.cpp b/src/particle.cpp index de1b2431f..8abe2d9c6 100644 --- a/src/particle.cpp +++ b/src/particle.cpp @@ -381,6 +381,12 @@ Particle::cross_surface() int64_t idx = simulation::surf_source_bank.thread_safe_append(site); } + // if we're crossing a CSG surface, make sure the DAG history is reset + #ifdef DAGMC + if (surf->geom_type_ != GeometryType::DAG) history().reset(); + #endif + + // Handle any applicable boundary conditions. if (surf->bc_ && settings::run_mode != RunMode::PLOTTING) { surf->bc_->handle_particle(*this, *surf); @@ -504,11 +510,6 @@ Particle::cross_reflective_bc(const Surface& surf, Direction new_u) coord(0).cell = cell_last(n_coord_last() - 1); surface() = -surface(); - // if we're crossing a CSG surface, make sure the DAG history is reset - #ifdef DAGMC - if (surf.geom_type_ != GeometryType::DAG) history().reset(); - #endif - // If a reflective surface is coincident with a lattice or universe // boundary, it is necessary to redetermine the particle's coordinates in // the lower universes.