@@ -39,6 +39,7 @@ class FlatSourceDomain {
3939 void reset_tally_volumes ();
4040 void random_ray_tally ();
4141 virtual void accumulate_iteration_flux ();
42+ void accumulate_iteration_source ();
4243 void output_to_vtk () const ;
4344 void convert_external_sources ();
4445 void count_external_source_regions ();
@@ -49,6 +50,7 @@ class FlatSourceDomain {
4950 void flatten_xs ();
5051 void transpose_scattering_matrix ();
5152 void serialize_final_fluxes (vector<double >& flux);
53+ void serialize_final_sources (vector<double >& source);
5254 void apply_meshes ();
5355 void apply_mesh_to_cell_instances (int32_t i_cell, int32_t mesh_idx,
5456 int target_material_id, const vector<int32_t >& instances,
@@ -72,6 +74,37 @@ class FlatSourceDomain {
7274 int64_t lookup_mesh_bin (int64_t sr, Position r) const ;
7375 int lookup_mesh_idx (int64_t sr) const ;
7476
77+ // ----------------------------------------------------------------------------
78+ // Methods for kinetic simulations
79+ virtual void update_single_neutron_source_td (SourceRegionHandle& srh);
80+ void compute_single_neutron_source_time_derivative (SourceRegionHandle& srh);
81+ void compute_single_scalar_flux_time_derivative_2 (SourceRegionHandle& srh);
82+ virtual void update_all_neutron_sources_td ();
83+
84+ void compute_single_delayed_fission_source (SourceRegionHandle& srh);
85+ void compute_single_precursors (SourceRegionHandle& srh);
86+ void compute_all_precursors ();
87+
88+ void serialize_final_td_fluxes (vector<double >& flux_td);
89+ void serialize_final_td_sources (vector<double >& source_td);
90+ void serialize_final_precursors (vector<double >& precursors);
91+ void serialize_final_delayed_fission_source (
92+ vector<double >& delayed_fission_source);
93+
94+ void flux_td_swap ();
95+ void precursors_swap ();
96+ void accumulate_iteration_quantities ();
97+ void normalize_final_quantities ();
98+ void propagate_final_quantities ();
99+ void store_time_step_quantities (bool increment_not_initialize = true );
100+ void compute_rhs_bd_quantities ();
101+ void update_material_density (int i);
102+
103+ int64_t n_delay_elements () const
104+ {
105+ return source_regions_.n_source_regions () * ndgroups_;
106+ }
107+
75108 // ----------------------------------------------------------------------------
76109 // Static Data members
77110 static bool volume_normalized_flux_tallies_;
@@ -149,6 +182,31 @@ class FlatSourceDomain {
149182 // technique.
150183 bool is_transport_stabilization_needed_ {false };
151184
185+ // ---------------------------------------------------------------------------
186+ // Public Data Members for kinetic simulations
187+
188+ // 2D arrays stored in 1D representing values for all materials x
189+ // delay_groups
190+ vector<double > lambda_;
191+
192+ // 3D arrays stored in 1D representing values for all materials x energy
193+ // groups x delay groups
194+ vector<double > nu_d_sigma_f_;
195+ vector<double > chi_d_;
196+
197+ // 2D arrays stored in 1D representing values for all materials x energy
198+ // groups
199+ vector<double > nu_p_sigma_f_;
200+ vector<double > chi_p_;
201+ vector<double > inverse_vbar_;
202+
203+ // Time-dependent cross section arrays for use with material density
204+ // timeseries
205+ vector<double > sigma_t_td_;
206+ vector<double > nu_sigma_f_td_;
207+ vector<double > sigma_f_td_;
208+ vector<double > sigma_s_td_;
209+
152210protected:
153211 // ----------------------------------------------------------------------------
154212 // Methods
@@ -165,6 +223,7 @@ class FlatSourceDomain {
165223 // ----------------------------------------------------------------------------
166224 // Private data members
167225 int negroups_; // Number of energy groups in simulation
226+ int ndgroups_; // Number of delay groups in simulation
168227
169228 double
170229 simulation_volume_; // Total physical volume of the simulation domain, as
0 commit comments