Skip to content

Input parameters

Entity reads almost all the information (except for the problem generator) about the simulation at runtime from an input file provided in the .toml format. The most up-to-date full version of the input file with all the possible input parameters with their descriptions can be found in the root directory of the main repository in the input.example.toml.

required
These paremeters are required to be specified for any simulation
inferred
These parameters are not directly specified by the user, but are inferred from other input parameters
parameter type description default
simulation
name
string
Name of the simulationThe name is used for the output files.
engine
string
"SRPIC", "GRPIC"
Simulation engine to use
runtime
float 
> 0
Max runtime in physical (code) units
domain
number
int
Number of domains 1 [no MPI]; MPI_SIZE [MPI]
decomposition
array<int> 
size 1 :->: 3
Decomposition of the domain (for MPI) in each of the directions* -1 means the code will determine the decomposition in the specific direction automatically.
* Automatic detection is either done by inference from # of MPI tasks, or by balancing the grid size on each domain.
$[-1, -1, -1]$
grid
resolution
array<uint> 
size 1 :->: 3
Spatial resolution of the gridDimensionality is inferred from the size of this array.
extent
array<tuple<float>> 
size 1 :->: 3
Physical extent of the grid* For spherical geometry, only specify
[[rmin, rmax]]
, other values are set automatically.
* For cartesian geometry, cell aspect ratio has to be 1:
dx=dy=dz
.
dim
short
1, 2, 3
Dimensionality of the grid
metric
metric
string
"Minkowski", "Spherical", "QSpherical", "Kerr_Schild", "QKerr_Schild", "Kerr_Schild_0"
Metric on the grid
qsph_r0
float 
-∞ -> rmin
r0 paramter for the QSpherical metric x1 = log(r-r0)Negative values produce almost uniform grid in r.
$0.0$
qsph_h
float 
-1 :->: 1
h paramter for the QSpherical metric th = x2 + 2*h x2 (pi-2*x2)*(pi-x2)/pi^2 $0.0$
ks_a
float 
0 :-> 1
Spin parameter for the Kerr Schild metric $0.0$
coord
string
"cartesian", "spherical", "qspherical"
Coordinate system on the grid
ks_rh
float
Size of the horizon for GR Kerr Schild
params
map<string, float>
A map of all metric-specific parameters together (for easy access)
boundaries
fields
array<tuple<string>> 
"PERIODIC", "MATCH", "FIXED", "ATMOSPHERE", "CUSTOM", "HORIZON", "CONDUCTOR"
Boundary conditions for fields* When periodic in any of the directions, you should only set one value: [..., ["PERIODIC"], ...].
* In spherical, bondaries in theta/phi are set automatically (only specify bc @
[rmin, rmax]
): [["ATMOSPHERE", "MATCH"]].
* In GR, the horizon boundary is set automatically (only specify bc @ rmax): [["MATCH"]].
particles
array<tuple<string>> 
"PERIODIC", "ABSORB", "ATMOSPHERE", "CUSTOM", "REFLECT", "HORIZON"
Boundary conditions for fields* When periodic in any of the directions, you should only set one value [..., ["PERIODIC"], ...].
* In spherical, bondaries in theta/phi are set automatically (only specify bc @
[rmin, rmax]
) [["ATMOSPHERE", "ABSORB"]].
* In GR, the horizon boundary is set automatically (only specify bc @
rmax
): [["ABSORB"]].
match
ds
float 
or
 array<tuple<float>>
Size of the matching layer in each direction for fields in physical (code) unitsIn spherical, this is the size of the layer in
r
from the outer wall.
1% of the domain size (in shortest dimension)
absorb
ds
float
Size of the absorption layer for particles in physical (code) units* In spherical, this is the size of the layer in
r
from the outer wall.
* In cartesian, this is the same for all dimensions where applicable.
1% of the domain size (in shortest dimension)
atmosphere
temperature
float
Temperature of the atmosphere in units of m0 c^2[required] if
ATMOSPHERE
is one of the boundaries.
density
float
Peak number density of the atmosphere at base in units of n0
height
float
Pressure scale-height in physical units
species
array<int> 
size 2
Species indices of particles that populate the atmosphere
ds
float
Distance from the edge to which the gravity is imposed in physical units0.0 means no limit.
$0.0$
g
float
Acceleration due to imposed gravity
scales
larmor0
float 
> 0.0
Fiducial larmor radius
skindepth0
float 
> 0.0
Fiducial plasma skin depth
dx0
float
fiducial minimum size of the cell
V0
float
fiducial elementary volume
n0
float
Fiducial number density
q0
float
Fiducial elementary charge
sigma0
float
Fiducial magnetization parameter
B0
float
Fiducial magnetic field
omegaB0
float
Fiducial cyclotron frequency
algorithms
current_filters
ushort 
>= 0
Number of current smoothing passes $0$
toggles
fieldsolver
bool
Toggle for the field solver
true
deposit
bool
Toggle for the current deposition
true
timestep
CFL
float 
0.0 -> 1.0
Courant-Friedrichs-Lewy numberCFL number determines the timestep duration.
$0.95$
correction
float
Correction factor for the speed of light used in field solver $1.0$
dt
float
timestep duration
gr
pusher_eps
float 
> 0.0
Stepsize for numerical differentiation in GR pusher $10^{-6}$
pusher_niter
ushort 
> 0
Number of iterations for the Newton-Raphson method in GR pusher $10$
gca
e_ovr_b_max
float 
0.0 -> 1.0
Maximum value for E/B allowed for GCA particles $0.9$
larmor_max
float
Maximum Larmor radius allowed for GCA particles (in physical units)When
larmor_max
== 0, the limit is disabled.
$0.0$
synchrotron
gamma_rad
float 
> 0.0
Radiation reaction limit gamma-factor for synchrotron[required] if one of the species has
cooling = "synchrotron"
.
$1.0$
particles
ppc0
float 
> 0.0
Fiducial number of particles per cell
use_weights
bool
Toggle for using particle weights
false
clear_interval
uint
Timesteps between particle re-sorting (removing dead particles)Set to 0 to disable re-sorting.
$100$
nspec
uint
Number of particle species
species
label
string
Label of the species
<INDEX>
is the index of the species in the list starting from 1.
"s<INDEX>"
mass
float 
>= 0.0
Mass of the species (in units of fiducial mass)
charge
float
Charge of the species (in units of fiducial charge)
maxnpart
uint 
> 0
Maximum number of particles per task
pusher
string
"Boris", "Vay", "Boris,GCA", "Vay,GCA", "Photon", "None"
Pusher algorithm for the species "Boris" [massive]; "Photon" [massless]
n_payloads
ushort
Number of additional (payload) variables for each particle of the given species $0$
cooling
string
"None", "Synchrotron"
Radiation reaction to use for the species
"None"
setup
Parameters for specific problem generators and setups
output
format
string
"disabled", "hdf5", "BPFile"
Output format
"hdf5"
interval
uint 
> 0
Number of timesteps between all outputsValue is overriden by output intervals for specific outputs.
$1$
interval_time
float
Physical (code) time interval between all outputs* When
interval_time
< 0, the output is controlled by
interval
, otherwise by
interval_time
.
* Value is overriden by output intervals for specific outputs.
$-1.0$
separate_files
bool
Whether to output each timestep into separate files
true
fields
enable
bool
Toggle for the field output
true
quantities
array<string>
"E", "B", "J", "divE", "Rho", "Charge", "N", "Nppc", "T0i", "Tij", "Vi", "D", "H", "divD", "A"
Field quantities to output* For
T
, you can use unspecified indices:
Tij
,
T0i
, or specific ones:
Ttt
,
T00
,
T02
,
T23
.
* For
T
, in cartesian can also use "x" "y" "z" instead of "1" "2" "3".
* By default, we accumulate moments from all massive species, one can specify only specific species:
Ttt_1_2
,
Rho_1
,
Rho_3_4
.
[]
custom
array<string>
Custom (user-defined) field quantities []
mom_smooth
ushort
Smoothing window for the output of moments ("Rho", "Charge", "T", ...) $0$
interval
uint
Number of timesteps between field outputs* When
!= 0
, overrides
output.interval
.
* When
== 0
,
output.interval
is used.
$0$
interval_time
float
Physical (code) time interval between field outputs* When
< 0
, the output is controlled by
interval
.
* When specified, overrides
output.interval_time
.
$-1.0$
downsampling
uint 
or
 array<uint> 
>= 1
Downsample factor for the output of fields* The output is downsampled by the given factors in each direction.
* If a scalar is given, it is applied to all directions.
$[1, 1, 1]$
particles
enable
bool
Toggle for the particles output
true
species
array<int>
Particle species indices to outputIf empty, all species are output.
[]
stride
uint 
> 1
Stride for the output of particles $100$
interval
uint
Number of timesteps between particle outputs* When
!= 0
, overrides
output.interval
.
* When
== 0
,
output.interval
is used.
$0$
interval_time
float
Physical (code) time interval between particle outputs* When
< 0
, the output is controlled by
interval
.
* When specified, overrides
output.interval_time
.
$-1.0$
spectra
enable
bool
Toggle for the spectra output
true
e_min
float
Minimum energy for the spectra output $10^{-3}$
e_max
float
Maximum energy for the spectra output $10^{3}$
log_bins
bool
Whether to use logarithmic bins
true
n_bins
uint 
> 0
Number of bins for the spectra output $200$
interval
uint
Number of timesteps between spectra outputs* When
!= 0
, overrides
output.interval
.
* When
== 0
,
output.interval
is used.
$0$
interval_time
float
Physical (code) time interval between spectra outputs* When
< 0
, the output is controlled by
interval
.
* When specified, overrides
output.interval_time
.
$-1.0$
debug
as_is
bool
Output fields "as is" without conversions
false
ghosts
bool
Output fields with values in ghost cells
false
stats
enable
bool
Toggle for the stats output
true
interval
uint 
> 0
Number of timesteps between stat outputsOverriden if
output.stats.interval_time != -1
.
$100$
interval_time
float
Physical (code) time interval between stat outputsWhen
< 0
, the output is controlled by
interval
.
$-1.0$
quantities
array<string>
"B^2", "E^2", "ExB", "N", "Charge", "Rho", "T00", "T0i", "Tij"
Field quantities to outputSame notation as for
output.fields.quantities
.
[
"B^2"
,
"E^2"
,
"ExB"
,
"Rho"
,
"T00"
]
custom
array<string>
Custom (user-defined) stats []
checkpoint
interval
uint 
> 0
Number of timesteps between checkpoints $1000$
interval_time
float 
> 0
Physical (code) time interval between checkpointsWhen
< 0
, the output is controlled by
interval
.
$-1.0$
keep
int
Number of checkpoints to keep* 0 = disable checkpointing.
* -1 = keep all checkpoints.
$2$
walltime
string
Write a checkpoint once after a fixed walltime* The format is "HH:MM:SS".
* Empty string or "00:00:00" disables this functionality.
* Writing checkpoint at walltime does not stop the simulation.
"00:00:00"
write_path
string
Parent directory to write checkpoints toThe directory is created if it does not exist.
<simname>.ckpt
read_path
string
Parent directory to use when resuming from a checkpoint inherit write_path
is_resuming
bool
Whether the simulation is resuming from a checkpoint
start_step
uint
Timestep of the checkpoint used to resume
start_time
float
Time of the checkpoint used to resume
diagnostics
interval
int 
> 0
Number of timesteps between diagnostic logs $1$
blocking_timers
bool
Blocking timers between successive algorithms
false
colored_stdout
bool
Enable colored stdout
true
log_level
string
"VERBOSE", "WARNING", "ERROR"
Specify the log level"VERBOSE" prints all messages, "WARNING" prints only warnings and errors, "ERROR" prints only errors.
"VERBOSE"