mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 21:55:41 -04:00
Unified the calculate XS functions, as its not really necessary to split them up. Also cleaned up simulation headers.
This commit is contained in:
parent
2ea0859fd3
commit
e1abbe6fcb
4 changed files with 5 additions and 18 deletions
|
|
@ -7,7 +7,7 @@
|
|||
#include <vector>
|
||||
|
||||
#include "openmc/particle.h"
|
||||
#include "openmc/tallies/filter.h"
|
||||
//#include "openmc/tallies/filter.h"
|
||||
|
||||
|
||||
namespace openmc {
|
||||
|
|
|
|||
|
|
@ -226,8 +226,7 @@ public:
|
|||
//! \param src Source site data
|
||||
void from_source(const Bank* src);
|
||||
|
||||
void event_calculate_xs_I();
|
||||
void event_calculate_xs_II();
|
||||
void event_calculate_xs();
|
||||
void event_advance();
|
||||
void event_cross_surface();
|
||||
void event_collide();
|
||||
|
|
|
|||
|
|
@ -130,7 +130,7 @@ Particle::from_source(const Bank* src)
|
|||
}
|
||||
|
||||
void
|
||||
Particle::event_calculate_xs_I()
|
||||
Particle::event_calculate_xs()
|
||||
{
|
||||
// Set the random number stream
|
||||
if (type_ == Particle::Type::neutron) {
|
||||
|
|
@ -168,11 +168,7 @@ Particle::event_calculate_xs_I()
|
|||
if (write_track_) write_particle_track(*this);
|
||||
|
||||
if (settings::check_overlaps) check_cell_overlap(this);
|
||||
}
|
||||
|
||||
void
|
||||
Particle::event_calculate_xs_II()
|
||||
{
|
||||
|
||||
// Calculate microscopic and macroscopic cross sections
|
||||
if (material_ != MATERIAL_VOID) {
|
||||
if (settings::run_CE) {
|
||||
|
|
|
|||
|
|
@ -2,30 +2,23 @@
|
|||
|
||||
#include "openmc/bank.h"
|
||||
#include "openmc/capi.h"
|
||||
//#include "openmc/cell.h"
|
||||
#include "openmc/container_util.h"
|
||||
#include "openmc/eigenvalue.h"
|
||||
#include "openmc/error.h"
|
||||
//#include "openmc/geometry.h"
|
||||
#include "openmc/material.h"
|
||||
#include "openmc/message_passing.h"
|
||||
//#include "openmc/mgxs_interface.h"
|
||||
#include "openmc/nuclide.h"
|
||||
#include "openmc/output.h"
|
||||
#include "openmc/particle.h"
|
||||
#include "openmc/photon.h"
|
||||
//#include "openmc/physics.h"
|
||||
//#include "openmc/physics_mg.h"
|
||||
#include "openmc/random_lcg.h"
|
||||
#include "openmc/settings.h"
|
||||
#include "openmc/source.h"
|
||||
#include "openmc/state_point.h"
|
||||
//#include "openmc/thermal.h"
|
||||
#include "openmc/timer.h"
|
||||
#include "openmc/tallies/derivative.h"
|
||||
#include "openmc/tallies/filter.h"
|
||||
#include "openmc/tallies/tally.h"
|
||||
//#include "openmc/tallies/tally_scoring.h"
|
||||
#include "openmc/tallies/trigger.h"
|
||||
#include "openmc/track_output.h"
|
||||
|
||||
|
|
@ -47,8 +40,7 @@ namespace openmc {
|
|||
void transport_history_based_single_particle(Particle& p)
|
||||
{
|
||||
while(true) {
|
||||
p.event_calculate_xs_I();
|
||||
p.event_calculate_xs_II();
|
||||
p.event_calculate_xs();
|
||||
p.event_advance();
|
||||
if( p.collision_distance_ > p.boundary_.distance )
|
||||
p.event_cross_surface();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue