Unit Test Common Runtime Parameters
There are a number of runtime parameters that are common to all (or most) of the unit tests.
These are defined in the top-level unit_test/_parameters
file.
Thermodynamics
The equation of state enforces minimum density and temperatures, which must be set upon initialization. These are controlled by the following runtime parameters:
unit_test.small_temp
: the low temperature cutoff used in the equation of stateunit_test.small_dens
: the low density cutoff used in the equation of state
Defining composition
Most of the unit tests require a composition to be defined (for the
initial mass-fractions,
One-zone (
*_cell
) tests (see One Zone Tests) usually do one of:Explicitly setting the individual mass fractions. This is controlled by the parameters
unit_test.X1
,unit_test.X2
, …,unit_test.X35
, e.g.:unit_test.X1 = 0.5 unit_test.X2 = 0.2 unit_test.X3 = 0.2 unit_test.X4 = 0.1
While many of the tests will renormalize the abundances, the user should take care to ensure that the mass fractions sum to unity.
Setting the composition to be uniform. This is controlled by
unit_test.uniform_xn
. If this is set to1
, then each mass fraction is initialized to1 / NumSpec
.
Comprehensive tests (see Comprehensive Unit Tests) need many different compositions, since they are creating a cube
of varying thermodynamic properties, and thus require a prescription to create the composition. This is done by setting
unit_test.primary_species_1
,unit_test.primary_species_2
, andunit_test.primary_species_3
to one of the names of the species in the network.The function
setup_composition()
is then used to set limits on the species abundances (it takes a parameter which is the index into the cube of data that is being initialized) which is then used byget_xn()
to create the individual mass fractions. Both of these routines are contained inreact_util.H
.