Configuration reference¶
A neoVULCAN simulation is configured by a single TOML file passed to
vulcan.py with the -c flag (default: vulcan_cfg.toml next to
vulcan.py). The file is parsed by tomllib (Python 3.11+) or
tomli (Python 3.10) and validated against the Pydantic schema
defined in src/neovulcan_config.py. Validation is strict: any
unknown key, wrong type, or out-of-range value is rejected at load time
with a precise error message rather than silently ignored.
The file is organised into ten sections. Each section maps to one of
the Pydantic model classes
(NetworkConfig,
PathsConfig,
ElementsConfig,
AtmosphereConfig,
PhotochemConfig,
BoundaryConfig,
CondensationConfig,
SolverConfig,
OutputConfig,
PlottingConfig).
A machine-generated reference with every parameter and its default is
shipped at vulcan_cfg_defaults.toml in the package root and in
cfg_examples/. Treat it as documentation; do not edit it for
production runs. To regenerate it after a schema change run:
python _gen_defaults_toml.py
CGS units (cm, g, s, K, dyn cm-2, erg) are used throughout unless explicitly stated.
[network]¶
Chemical-reaction network and thermochemistry inputs.
Schema: neovulcan_config.NetworkConfig.
Key |
Type |
Description |
|---|---|---|
|
list[str] |
Required. Elements tracked for conservation (e.g.
|
|
str |
Required. Path to the network file (e.g.
|
|
str |
Index file listing the NASA-9 polynomial files used to build
Gibbs free energies. Default |
|
str |
Composition file with basic per-species properties (mass,
charge, atomic content). Default |
|
str |
Directory of photolysis cross-sections.
Default |
|
bool |
Clip thermal rates to their low-temperature limits below the
Arrhenius validity range. Default |
|
list[int] |
Reaction indices to disable. Forward/reverse pairs should be
removed together (e.g. |
[paths]¶
File-system paths for atmospheric input, stellar flux, boundary
conditions, and output.
Schema: neovulcan_config.PathsConfig.
When VulcanConfig.from_toml is called with absolutify_paths=True
(used by the library API), relative paths are resolved against the
base_dir argument (TOML’s directory by default); otherwise the
values are passed through unchanged.
Key |
Type |
Description |
|---|---|---|
|
str |
FastChem element & rate-coefficient directory. Default
|
|
str |
Required. Temperature–pressure profile (and optional \(\Kzz\)). |
|
str |
Required. Stellar flux density at the stellar surface (\(\mathrm{erg\,cm^{-2}\,s^{-1}\,nm^{-1}}\)). |
|
str |
Top-of-atmosphere boundary-condition flux file. Default
|
|
str |
Bottom-of-atmosphere boundary-condition flux file. Default
|
|
str |
Previous |
|
str |
Output directory for the pickle file. Default |
|
str |
Output directory for plots. Default |
|
str |
Output directory for live-plot frames. Default
|
|
str |
Required. Output file name (extension |
[elements]¶
Elemental abundances and initial mixing-ratio mode.
Schema: neovulcan_config.ElementsConfig.
Key |
Type |
Description |
|---|---|---|
|
bool |
Use the solar abundances of Lodders (2009). If |
|
dict[str, float] |
Element-to-hydrogen number ratios (e.g.
|
|
str |
Initial-condition mode: one of |
|
float |
Metallicity scaling factor passed to FastChem for the trace
elements not in |
|
dict[str, float] |
Constant mixing ratios used when |
[atmosphere]¶
Atmospheric structure: vertical grid, T–P profile, eddy diffusion,
molecular diffusion, advection, planet/star geometry.
Schema: neovulcan_config.AtmosphereConfig.
Key |
Type |
Description |
|---|---|---|
|
str |
Bulk gas. One of |
|
bool |
|
|
int |
Required. Number of vertical layers ( |
|
float |
Required. Pressure at the bottom of the model
(dyn cm-2, |
|
float |
Required. Pressure at the top of the model
(dyn cm-2, |
|
bool |
Include eddy diffusion. Default |
|
bool |
Include molecular diffusion (with thermal-diffusion drift).
Default |
|
bool |
Alternative mixing-length parameterisation in place of
molecular diffusion. Default |
|
bool |
Include vertical advection. Default |
|
str |
How \(T(P)\) is specified: |
|
str |
How \(\Kzz(P)\) is specified: |
|
float |
Plateau value of \(\Kzz\) (cm2s-1) used
with |
|
float |
Transition pressure (bar) where |
|
float, optional |
Lower-atmosphere plateau value used by some |
|
str |
|
|
float |
Required. Surface gravity (cm s-2). |
|
float |
Isothermal temperature (K), only read when
|
|
list[float] |
\((T_\mathrm{int}, T_\mathrm{irr}, \kappa_L, \kappa_S,
\beta_S, \beta_L)\) parameters for the analytical T–P profile of
Heng et al. (2014). Six elements; default
|
|
list[float], optional |
Same six parameters used when |
|
float |
Constant \(\Kzz\) (cm2s-1) used when
|
|
float |
Constant vertical wind (cm s-1) used when
|
|
int |
Number of steps between updates of \(\mathrm{d}z\) and
\(\mathrm{d}z_i\) due to changes in the mean molecular
weight. Default |
|
float |
Stellar radius in \(R_\odot\). Default |
|
float |
Required. Planetary radius (cm). |
|
float |
Planet–star distance (AU). Default |
|
float |
Solar zenith angle in degrees (the conventional dayside
average is 58°). Default |
|
float |
Diurnal-averaging factor applied to all photolysis rates
(0.5 for an Earth-like rotator, 1.0 for a tidally-locked planet).
Default |
[photochemistry]¶
Photochemistry and the radiative-transfer backend used to compute the
actinic flux.
Schema: neovulcan_config.PhotochemConfig.
Key |
Type |
Description |
|---|---|---|
|
bool |
Include photochemistry. Default |
|
bool |
Include photoionisation chemistry. Requires |
|
list[str] |
Bulk gases that contribute Rayleigh scattering (e.g.
|
|
list[str] |
Species for which temperature-dependent UV cross-sections are loaded. Currently available: CO2, H2O, NH3, SH, H2S, SO2, S2, COS, CS2. Start-up cost is noticeably higher when this list is non-empty. |
|
float |
First Eddington coefficient \(\epsilon\) used by the
two-stream backend to convert the diffuse flux to actinic units.
Default |
|
float |
Wavelength bin width in the VUV (nm), below |
|
float |
Wavelength bin width in the MUV/NUV (nm), above
|
|
float |
Transition wavelength (nm) where the bin width changes from
|
|
int |
Number of time steps between actinic-flux updates while the
chemistry is still evolving rapidly. Default |
|
int |
Number of time steps between actinic-flux updates once the
chemistry is near steady state. Default |
|
str |
Radiative-transfer backend. |
|
float |
Lambertian surface albedo at the lower boundary. Only honoured by
the DisORT++ backend. Default |
|
int |
Number of streams (Gauss–Legendre points) used by the DisORT++
backend. Higher = more accurate angular discretisation but
\(\mathcal{O}(n_\mathrm{str}^{\,3})\) more expensive per
layer. Default |
[boundary_conditions]¶
Top and bottom boundary conditions.
Schema: neovulcan_config.BoundaryConfig.
Key |
Type |
Description |
|---|---|---|
|
bool |
Apply a top-of-atmosphere flux from |
|
bool |
Apply a surface flux from |
|
dict[str, float] |
Fixed mixing ratios at the bottom boundary
(e.g. |
|
list[str] |
Species treated with the diffusion-limited escape flux at the
top boundary. Default |
|
float |
Upper limit (cm-2s-1) for the escape flux.
Default |
|
bool |
Use a surface-temperature-controlled water saturation as the
bottom boundary for H2O. Default |
|
bool |
Pin the H2/He ratio at the lower boundary. Useful for
deep hot-Jupiter columns where the H2/He inventory must
not drift. Default |
|
list[str] |
Species excluded from the element-conservation diagnostic
(useful for surface sinks that legitimately consume mass).
Default |
[condensation]¶
Condensation, evaporation and particle settling.
Schema: neovulcan_config.CondensationConfig.
Key |
Type |
Description |
|---|---|---|
|
bool |
Enable condensation/evaporation reactions. Default |
|
bool |
Apply Stokes settling to condensed species. Default |
|
list[str] |
Species advanced by implicit relaxation instead of the global
Rosenbrock step (typically |
|
float |
Relative humidity for water vapour. Default |
|
dict[str, float] |
Particle radius (cm) keyed by condensate species (e.g.
|
|
dict[str, float] |
Particle density (g cm-3) keyed by condensate species.
Set in sub-table |
|
float |
Simulation time (s) at which condensation is switched on.
Default |
|
float |
Simulation time (s) after which condensation is switched off.
Default |
|
list[str] |
Condensable gas species. Default |
|
list[str] |
Names of the corresponding condensate species (e.g.
|
|
list[str] |
Species frozen after |
|
float, optional |
Simulation time (s) after which the species in |
|
bool |
Only pin species below the cold-trap level. Default |
|
bool |
Apply a cold trap to the initial state. Default |
[solver]¶
ODE integrator, step-size controller, convergence diagnostics, optional
Newton finisher.
Schema: neovulcan_config.SolverConfig.
Key |
Type |
Description |
|---|---|---|
|
str |
|
|
bool |
Use a PI step-size controller instead of the default integrating
controller. Default |
|
bool |
Print a progress line every |
|
bool |
Print the per-step truncation error. Default |
|
int |
Progress-print frequency in steps. Default |
|
float |
Initial time step (s). Default |
|
float |
Minimum total integration time (s). Default |
|
float |
Maximum total integration time (s). Default |
|
float |
Hard lower bound on the time step (s). Default |
|
float, optional |
Hard upper bound on the time step (s). If omitted, derived as
|
|
float |
Maximum per-step time-step growth factor. Default |
|
float |
Minimum per-step time-step shrink factor. Default |
|
int |
Minimum number of steps before convergence checks fire. Default
|
|
int |
Hard upper bound on the number of steps. Default |
|
float |
Absolute tolerance (cm-3). Number densities below this
are excluded from the error norms. Default |
|
float |
Relative-tolerance floor used by the step-size controller.
Default |
|
float |
Relative-tolerance floor used by the convergence check. Default
|
|
float |
Clip small positive values to zero. Default |
|
float |
Threshold below which negative updates trigger a step rejection.
Default |
|
float |
Element-conservation tolerance used by the adaptive |
|
float |
Relative change \(\Delta\hat n\) threshold (the
\(\delta\) in Numerical methods). Default |
|
float |
\(\Delta\hat n / \Delta\tau\) threshold (the \(\epsilon\)
in Numerical methods). Default |
|
float |
Relaxed alternative for |
|
float |
Relative change of the actinic flux threshold. Default |
|
float |
Absolute tolerance for the actinic flux
(photons cm-2s-1nm-1). Default
|
|
float |
Fraction of the integration time used for the steady-state window (default 0.5 means the last half is examined). |
|
int |
Hard cap on the number of past steps used in the convergence
check. Default |
|
list[str] |
Species excluded from the convergence diagnostic (used for
species whose noise level dominates the dominant-\(\Delta\)
test but does not matter for the result). Default |
|
float |
Relative tolerance \(\mathcal{T}\) for the step-size
controller. Default |
|
float |
Value of |
|
bool |
Adapt |
|
float |
Lower bound for the adaptive |
|
float |
Upper bound for the adaptive |
|
bool |
Enable the optional damped-Newton tail described in
Numerical methods. Default |
|
float |
Per-step fractional change below which the Newton finisher takes
over. Default |
|
int |
Number of Rosenbrock steps that must elapse between successive
Newton firings. Default |
|
int |
Maximum number of Newton iterations per firing. Default |
|
float |
Residual norm at which the Newton finisher considers itself
converged. Default |
|
float |
Smallest damping factor allowed by the line-search inside the
Newton finisher. Default |
[output]¶
Pickle file and evolution-history options.
Schema: neovulcan_config.OutputConfig.
Key |
Type |
Description |
|---|---|---|
|
bool |
Also write a human-readable text dump of the final state.
Default |
|
bool |
Easter egg. |
|
bool |
Store the abundance and time history in the output file.
Default |
|
int |
Number of steps between evolution-history samples. Default
|
|
int |
Number of steps between snapshots stored in the evolution
arrays. Default |
[plotting]¶
Live-plot, end-of-run plot, and movie options.
Schema: neovulcan_config.PlottingConfig.
Key |
Type |
Description |
|---|---|---|
|
bool |
Plot the T–P profile at the start of the run. Default |
|
bool |
Show a live matplotlib plot of mixing-ratio profiles during
integration. Default |
|
bool |
Show a live plot of the actinic flux. Default |
|
bool |
Plot mixing ratios after the integration finishes. Default
|
|
bool |
Plot the time evolution at each layer at the end. Default
|
|
bool |
Save the live-plot frames to |
|
bool |
Save live-flux frames. Default |
|
bool |
Use the altitude (cm) instead of pressure on the vertical axis.
Default |
|
bool |
Use the Pillow library to composite live plots; fall back to a
simpler renderer if Pillow is unavailable. Default |
|
int |
Number of steps between live-plot updates. Default |
|
int, optional |
Number of steps between movie-frame saves. If omitted, aliased
to |
|
list[str] |
Species to include in live plots. Default |
Cross-section validators¶
A small number of consistency rules are enforced after every load and after every programmatic override:
atmosphere.P_t < atmosphere.P_b— the top pressure must be strictly smaller than the bottom one.atmosphere.para_warmandatmosphere.para_anaTPmust each have exactly six elements.photochemistry.use_ion = truerequiresphotochemistry.use_photo = true.solver.ode_solver = "Rodas3"requiresatmosphere.use_moldiff = true.
These are all expressed as Pydantic validators in
src/neovulcan_config.py; their error messages identify the
offending field on failure.
Practical advice¶
Start from one of the example configurations in
cfg_examples/rather than from scratch; the boundary conditions, network choice, and \(\Kzz\) profile of a working setup are difficult to guess.For hot atmospheres (\(T \gtrsim 1000\) K), the default
elements.ini_mix = "EQ"together with the SNCHO photo network is the recommended starting point.For terrestrial atmospheres, set
atmosphere.rocky = true, chooseatmosphere.atm_baseto match the bulk gas, useelements.ini_mix = "const_mix"with realistic surface mixing ratios, and switch on condensation.If the solver oscillates between accepting and rejecting steps, reduce
solver.atol(a smaller absolute tolerance is more permissive in this code, because trace species belowatolare not used to judge the step size).If the run terminates with
end_case != 1even aftersolver.count_maxsteps, the most common causes are (i) a poorly conditioned boundary condition, (ii) a missing reaction in the network that should close a fast cycle, or (iii) a \(\Kzz\) profile with very large gradients that interact badly with the finite-difference stencil.