From 0c8ce53d94d4f5d9db0bbbcbe275a95fce6b70de Mon Sep 17 00:00:00 2001 From: YoungHui Park Date: Tue, 17 Mar 2020 00:20:00 -0500 Subject: [PATCH] Rough banking of surface source into surf_src_bank --- include/openmc/particle.h | 2 ++ src/particle.cpp | 2 ++ 2 files changed, 4 insertions(+) diff --git a/include/openmc/particle.h b/include/openmc/particle.h index f70faa611..705675e2e 100644 --- a/include/openmc/particle.h +++ b/include/openmc/particle.h @@ -159,6 +159,8 @@ public: neutron, photon, electron, positron }; + int64_t icross = 0; + //! Saved ("banked") state of a particle //! NOTE: This structure's MPI type is built in initialize_mpi() of //! initialize.cpp. Any changes made to the struct here must also be diff --git a/src/particle.cpp b/src/particle.cpp index b3bdede06..28d93eee3 100644 --- a/src/particle.cpp +++ b/src/particle.cpp @@ -423,6 +423,8 @@ Particle::cross_surface() site.particle = this->type_; // site.parent_id = this->id_; // site.progeny_id = this->n_progeny_; + simulation::surf_src_bank[Particle::icross] = site; + Particle::icross += 1; } // Handle any applicable boundary conditions.