#include <boxmodus.h>
BoxModus: Provides a modus for infinite matter calculations.
Matter is confined in a cubical box. Depending on the initial condition, particles are either reflected on the boundaries (not implemented now) or inserted on opposite positions.
To use this modus, choose Modus: Box
in the configuration file.
Options for BoxModus go in the "Modi"→"Box" section of the configuration:
The following configuration options are understood: Box
Definition at line 46 of file boxmodus.h.
Public Member Functions | |
BoxModus (Configuration modus_config, const ExperimentParameters ¶meters) | |
Constructor. More... | |
double | initial_conditions (Particles *particles, const ExperimentParameters ¶meters) |
Generates initial state of the particles in the system according to specified parameters: number of particles of each species, momentum and coordinate space distributions. More... | |
int | impose_boundary_conditions (Particles *particles, const OutputsList &output_list={}) |
Enforces that all particles are inside the box. More... | |
Grid< GridOptions::PeriodicBoundaries > | create_grid (const Particles &particles, double min_cell_length, double timestep_duration, CellSizeStrategy strategy=CellSizeStrategy::Optimal) const |
Creates the Grid with normal boundary conditions. More... | |
std::unique_ptr< GrandCanThermalizer > | create_grandcan_thermalizer (Configuration &conf) const |
Creates GrandCanThermalizer. More... | |
double | max_timestep (double max_transverse_distance_sqr) const |
double | length () const |
![]() | |
int | impose_boundary_conditions (Particles *, const OutputsList &={}) |
Enforces sensible positions for the particles. More... | |
int | total_N_number () const |
int | proj_N_number () const |
bool | cll_in_nucleus () const |
bool | is_collider () const |
double | impact_parameter () const |
double | velocity_projectile () const |
double | velocity_target () const |
FermiMotion | fermi_motion () const |
double | max_timestep (double) const |
double | length () const |
Grid< GridOptions::Normal > | create_grid (const Particles &particles, double min_cell_length, double timestep_duration, CellSizeStrategy strategy=CellSizeStrategy::Optimal) const |
Creates the Grid with normal boundary conditions. More... | |
Private Attributes | |
const BoxInitialCondition | initial_condition_ |
Initial momenta distribution: thermal or peaked momenta. More... | |
const double | length_ |
Length of the cube's edge in fm/c. More... | |
const double | temperature_ |
Temperature of the Box in GeV. More... | |
const double | start_time_ = 0. |
Initial time of the box. More... | |
const bool | use_thermal_ = false |
Whether to use a thermal initialization for all particles instead of specific numbers. More... | |
const double | mub_ |
Baryon chemical potential for thermal initialization; only used if use_thermal_ is true. More... | |
const double | mus_ |
Strange chemical potential for thermal initialization; only used if use_thermal_ is true. More... | |
const std::map< PdgCode, int > | init_multipl_ |
Particle multiplicities at initialization; required if use_thermal_ is false. More... | |
std::map< PdgCode, double > | average_multipl_ |
Average multiplicities in case of thermal initialization. More... | |
Friends | |
std::ostream & | operator<< (std::ostream &out, const BoxModus &m) |
Console output on startup of box specific parameters; writes the initial state for the box to the output stream. More... | |
|
explicit |
Constructor.
Gathers all configuration variables for the Box.
[in] | modus_config | The configuration object that sets all initial conditions of the experiment. |
[in] | parameters | Unused, but necessary because of templated initialization |
Definition at line 161 of file boxmodus.cc.
double smash::BoxModus::initial_conditions | ( | Particles * | particles, |
const ExperimentParameters & | parameters | ||
) |
Generates initial state of the particles in the system according to specified parameters: number of particles of each species, momentum and coordinate space distributions.
Subsequently makes the total 3-momentum 0.
[out] | particles | An empty list that gets filled up by this function |
[in] | parameters | The initialization parameters of the box |
Initialize formation time
Definition at line 175 of file boxmodus.cc.
int smash::BoxModus::impose_boundary_conditions | ( | Particles * | particles, |
const OutputsList & | output_list = {} |
||
) |
Enforces that all particles are inside the box.
[in] | particles | particles to check their position and possibly move it |
[in] | output_list | output objects |
In BoxModus if a particle crosses the wall of the box, it is inserted from the opposite side. Wall crossings are written to collision output: this is where OutputsList is used.
Definition at line 254 of file boxmodus.cc.
|
inline |
Creates the Grid with normal boundary conditions.
[in] | particles | The Particles object containing all particles of the currently running Experiment. |
[in] | min_cell_length | The minimal length of the grid cells. |
[in] | timestep_duration | Duration of the timestep. It is necessary for formation times treatment: if particle is fully or partially formed before the end of the timestep, it has to be on the grid. |
[in] | strategy | The strategy to determine the cell size |
Definition at line 90 of file boxmodus.h.
|
inline |
Creates GrandCanThermalizer.
(Special Box implementation.)
[in] | conf | configuration object |
Definition at line 107 of file boxmodus.h.
|
inline |
Definition at line 117 of file boxmodus.h.
|
inline |
Definition at line 122 of file boxmodus.h.
|
private |
Initial momenta distribution: thermal or peaked momenta.
Definition at line 126 of file boxmodus.h.
|
private |
Length of the cube's edge in fm/c.
Definition at line 128 of file boxmodus.h.
|
private |
Temperature of the Box in GeV.
Definition at line 130 of file boxmodus.h.
|
private |
Initial time of the box.
Definition at line 132 of file boxmodus.h.
|
private |
Whether to use a thermal initialization for all particles instead of specific numbers.
Definition at line 137 of file boxmodus.h.
|
private |
Baryon chemical potential for thermal initialization; only used if use_thermal_ is true.
Definition at line 142 of file boxmodus.h.
|
private |
Strange chemical potential for thermal initialization; only used if use_thermal_ is true.
Definition at line 147 of file boxmodus.h.
|
private |
Particle multiplicities at initialization; required if use_thermal_ is false.
Definition at line 152 of file boxmodus.h.
|
private |
Average multiplicities in case of thermal initialization.
Saved to avoid recalculating at every event
Definition at line 157 of file boxmodus.h.