Procedures

ProcedureLocationProcedure TypeDescription
allocate_work_arrays solver_state Subroutine

Allocate all solver work arrays owned by a solver instance.

Read more…
apply_bcs boundary_conditions Subroutine

Update ghost-state vectors from the current solution and BC types.

Read more…
apply_initial_condition initial_conditions Subroutine

Fill state%ub with the initial condition selected by cfg%problem_type.

Read more…
apply_weno_js_generic weno_family Subroutine

Generic Jiang-Shu WENO reconstruction for odd-width schemes.

Read more…
ausm_plus euler_physics Subroutine

AUSM+ FDS scheme (AUSM family).

Read more…
band_lapack_solve time_integration Subroutine

Banded linear solver using LAPACK dgbsv.

Read more…
band_lu_solve time_integration Subroutine

Banded Gaussian elimination without pivoting. Band storage: AB(ku+1+i-j, j) = A(i,j). On exit x = A^{-1} b. The matrix ab_loc is overwritten with LU factors.

bdf2_step time_integration Subroutine

Advance the solution by one time step using the BDF2 (Gear) scheme.

Read more…
beuler_step time_integration Subroutine

Advance the solution by one time step using backward (implicit) Euler.

Read more…
c_string_to_fortran solver_c_api Function

Convert a NUL-terminated C string into a fixed-length Fortran buffer.

central2_reconstruct central2 Subroutine

Second-order central reconstruction in physical space.

Read more…
cfd_solver_advance solver_c_api Function

Advance the solver by at most max_steps iterations.

Read more…
cfd_solver_call_udf initial_conditions Interface
cfd_solver_copy_solution solver_c_api Function

Copy the primitive solution into caller-owned C buffers.

Read more…
cfd_solver_create solver_c_api Function

Allocate the sole supported v1 session and return its opaque handle.

cfd_solver_destroy solver_c_api Function

Destroy the active session referenced by handle.

cfd_solver_get_bool solver_c_api Function

Read a logical configuration field by canonical schema key.

cfd_solver_get_int solver_c_api Function

Read an integer configuration field by canonical schema key.

cfd_solver_get_last_error solver_c_api Function

Copy the last surfaced error string into a C buffer.

Read more…
cfd_solver_get_pid initial_conditions Interface
cfd_solver_get_point_count solver_c_api Function

Return the grid-point count required by solution-copy buffers.

cfd_solver_get_progress solver_c_api Function

Copy out the current progress snapshot for a session.

cfd_solver_get_real solver_c_api Function

Read a scalar real configuration field by canonical schema key.

cfd_solver_get_real3 solver_c_api Function

Read a length-3 real configuration field by canonical schema key.

cfd_solver_get_string solver_c_api Function

Read a string or choice-token configuration field by canonical schema key.

cfd_solver_host_platform initial_conditions Interface
cfd_solver_initialize solver_c_api Function

Validate config and allocate the runtime owned by handle.

cfd_solver_load_namelist solver_c_api Function

Load a namelist file into the session configuration.

cfd_solver_run_to_end solver_c_api Function

Run the session to completion without intermediate polling.

cfd_solver_schema_bounds solver_c_api Function

Return optional numeric bounds for schema entry index.

cfd_solver_schema_choice solver_c_api Function

Copy one allowed string token for a choice-valued schema entry.

Read more…
cfd_solver_schema_choice_count solver_c_api Function

Return the number of allowed string choices for schema entry index.

cfd_solver_schema_count solver_c_api Function

Return the number of schema entries exported through the ABI.

Read more…
cfd_solver_schema_default_bool solver_c_api Function

Copy the compiled-in default logical value for schema entry index.

cfd_solver_schema_default_int solver_c_api Function

Copy the compiled-in default integer value for schema entry index.

cfd_solver_schema_default_real solver_c_api Function

Copy the compiled-in default scalar real value for schema entry index.

cfd_solver_schema_default_real3 solver_c_api Function

Copy the compiled-in default length-3 real vector for schema entry index.

cfd_solver_schema_default_string solver_c_api Function

Copy the compiled-in default string or choice token for schema entry index.

cfd_solver_schema_group solver_c_api Function

Copy the namelist group name for schema entry index.

cfd_solver_schema_help solver_c_api Function

Copy the short help text for schema entry index.

cfd_solver_schema_key solver_c_api Function

Copy the canonical key for schema entry index.

cfd_solver_schema_kind solver_c_api Function

Return the cfg_kind_* tag for schema entry index.

cfd_solver_set_bool solver_c_api Function

Set a logical configuration field by canonical schema key.

cfd_solver_set_int solver_c_api Function

Set an integer configuration field by canonical schema key.

cfd_solver_set_real solver_c_api Function

Set a scalar real configuration field by canonical schema key.

cfd_solver_set_real3 solver_c_api Function

Set a length-3 real configuration field by canonical schema key.

cfd_solver_set_string solver_c_api Function

Set a string or choice-token configuration field by canonical schema key.

cfd_solver_write_checkpoint solver_c_api Function

Force an immediate checkpoint write for the active runtime.

cfd_solver_write_result solver_c_api Function

Write the current solution in the standard text result format.

compute_candidate_reconstructions weno_family Subroutine

Evaluate candidate reconstruction polynomials from tabulated coefficients.

Read more…
compute_candidate_smoothness weno_family Subroutine

Evaluate candidate Jiang-Shu smoothness indicators from quadratic forms.

Read more…
compute_eigensystem euler_physics Subroutine

Compute the right eigenvector matrix K and its inverse K^{-1} of the Euler Jacobian at a given state.

Read more…
compute_euler_flux euler_physics Subroutine

Compute the Euler flux vector F(Q) for a given conserved state.

Read more…
compute_full_stencil_smoothness weno_family Subroutine

Evaluate a quadratic smoothness form on the full stencil.

Read more…
compute_max_wave_speed euler_physics Function

Return the global maximum wave speed max_i(|u_i| + c_i).

Read more…
compute_resid spatial_discretization Subroutine

Compute the spatial residual R(Q) = -1/dx * (F_{i+1/2} - F_{i-1/2}).

Read more…
compute_resid_glob time_integration Subroutine

Accumulate the global L2 norm of the residual into state%resid_glob.

Read more…
compute_roe_averages euler_physics Subroutine

Compute Roe-averaged velocity, enthalpy, and sound speed.

Read more…
config_default_integer config_schema Subroutine

Read the compiled-in default integer value for a schema key.

config_default_logical config_schema Subroutine

Read the compiled-in default logical value for a schema key.

config_default_real config_schema Subroutine

Read the compiled-in default scalar real value for a schema key.

config_default_real3 config_schema Subroutine

Read the compiled-in default length-3 real vector for a schema key.

config_default_string config_schema Subroutine

Read the compiled-in default string or choice token for a schema key.

config_get_integer config_schema Subroutine

Read one integer-valued field from cfg by schema key.

config_get_logical config_schema Subroutine

Read one logical field from cfg by schema key.

config_get_real config_schema Subroutine

Read one scalar real-valued field from cfg by schema key.

config_get_real3 config_schema Subroutine

Read one fixed-length real-3 field from cfg by schema key.

config_get_string config_schema Subroutine

Read one string or choice token from cfg by schema key.

config_schema_choice_count config_schema Function

Return the number of allowed choices for a choice-valued schema entry.

Read more…
config_schema_count config_schema Function

Return the number of published schema entries.

config_set_integer config_schema Subroutine

Write one integer-valued field in cfg by schema key.

Read more…
config_set_logical config_schema Subroutine

Write one logical field in cfg by schema key.

config_set_real config_schema Subroutine

Write one scalar real-valued field in cfg by schema key.

config_set_real3 config_schema Subroutine

Write one fixed-length real-3 field in cfg by schema key.

config_set_string config_schema Subroutine

Write one string or choice token in cfg by schema key.

copy_choice config_schema Subroutine

Copy one 1-based choice-list item into value.

copy_current_solution solver_runtime Subroutine

Copy the current solution into primitive-variable arrays.

destroy_solver_state solver_state Subroutine

Nullify procedure pointer components of a solver_state_t instance.

Read more…
emit logger Subroutine
eno3_reconstruct eno3 Subroutine

Perform classical ENO3 reconstruction on the supplied stencil.

Read more…
ensure_schema config_schema Subroutine

Populate the schema table on first use.

Read more…
euler_step time_integration Subroutine

Advance the solution by one time step using the explicit Euler scheme.

Read more…
eval_face_sensor spatial_discretization Function

Evaluate the hybrid shock sensor for face iface.

Read more…
extract_primitives euler_physics Subroutine

Extract primitive variables (rho, u, p) from a conserved state vector.

Read more…
fill_stencil spatial_discretization Subroutine

Fill a reconstruction stencil from field, applying ghost states at domain boundaries.

Read more…
finalize_runtime solver_runtime Subroutine

Write the final solution to the output file and print the performance table.

Read more…
find_config_schema_entry config_schema Function

Find a schema entry by key and return its 1-based index.

Read more…
finish solver_session Subroutine

Store the last writable-operation error and mirror it to optional outputs.

finish_readonly solver_session Subroutine

Mirror readonly-operation status without mutating the session state.

fortran_to_c_buffer solver_c_api Subroutine

Copy trimmed Fortran text into a NUL-terminated C buffer.

get_config_schema_choice config_schema Subroutine

Copy one allowed string token from a schema entry's choice list.

Read more…
get_config_schema_entry config_schema Subroutine

Copy one schema entry by its 1-based index.

Read more…
get_host_platform initial_conditions Function

Return the host platform detected by the C portability shim.

get_q_at_face spatial_discretization Function

Return Q at grid cell idx with ghost-state fallback at boundaries.

Read more…
get_windows_temp_dir initial_conditions Function

Return the preferred runtime-UDF output directory on Windows.

hll_flux euler_physics Subroutine

HLL approximate Riemann solver.

Read more…
hllc_flux euler_physics Subroutine

HLLC approximate Riemann solver with contact-wave restoration.

Read more…
ic_from_file initial_conditions Subroutine

Load the initial condition from a data file containing columns: x rho u p.

Read more…
ic_udf initial_conditions Subroutine

Compile a user-defined Fortran source file to a shared library at runtime and call its ic_udf subroutine to fill the initial state.

Read more…
init_flux_scheme euler_physics Subroutine

Bind the flux dispatch pointers in @p state to the requested scheme.

Read more…
init_from_config solver_state Subroutine

Populate a solver_state_t from a config_t.

Read more…
init_recon_scheme reconstruction Subroutine

Bind the reconstruction procedure pointers and stencil metadata in @p state to the requested scheme, then resolve state%use_char_proj.

Read more…
init_time_scheme time_integration Subroutine

Bind the procedure pointer @p step to the requested scheme.

Read more…
initialize_runtime solver_runtime Subroutine

Populate ctx and bring the solver to a ready-to-run state.

Read more…
is_fds_flux_scheme option_registry Function
is_valid_boundary_condition option_registry Function
is_valid_char_proj_mode option_registry Function
is_valid_flux_scheme option_registry Function
is_valid_hybrid_sensor option_registry Function
is_valid_limiter option_registry Function
is_valid_nrbc_mode option_registry Function
is_valid_problem_type option_registry Function
is_valid_recon_scheme option_registry Function
is_valid_time_scheme option_registry Function
jac_store_col time_integration Subroutine

Store one Jacobian column into band storage AB(diag_row_loc+i-j, j) = J(i,j). Works for both the custom (diag_row_loc = ku+1) and LAPACK (diag_row_loc = kl+ku+1) storage layouts.

join_path initial_conditions Function

Join a directory and leaf name with a platform-appropriate separator.

join_token_list option_registry Function
lax_friedrichs_split euler_physics Subroutine

Lax-Friedrichs flux splitting.

Read more…
lax_friedrichs_split_both euler_physics Subroutine

Fused Lax-Friedrichs flux splitting: returns F^+ and F^- in one call.

Read more…
lim_koren muscl Function

Koren TVD limiter. Third-order accurate for smooth data; preserves monotonicity near discontinuities.

Read more…
lim_mc muscl Function

Monotonized Central (MC) TVD limiter. Good balance between dissipation and resolution; recommended for most shock-capturing applications.

Read more…
lim_minmod muscl Function

Minmod TVD limiter. Most dissipative of the standard limiters; guaranteed TVD for any CFL within the stability limit.

Read more…
lim_superbee muscl Function

Superbee TVD limiter. Least dissipative TVD limiter; may over-sharpen contact discontinuities on smooth problems.

Read more…
lim_van_leer muscl Function

van Leer smooth TVD limiter.

Read more…
limit_positivity positivity_limiter Subroutine

Scale a reconstructed face state toward the cell average to ensure density ρ ≥ ε and pressure p ≥ ε (Zhang-Shu 2010).

Read more…
linear_weno5_reconstruct linear_weno Subroutine

5th-order linear WENO reconstruction on a 5-point stencil.

Read more…
linear_weno7_reconstruct linear_weno Subroutine

7th-order linear WENO reconstruction on a 7-point stencil.

Read more…
log_debug logger Subroutine

Emit a DEBUG-level message.

log_effective_config solver_runtime Subroutine

Log the effective (post-promotion) configuration at startup. Reads from the authoritative copy ctx % state % cfg, which may differ from the original namelist values when BC promotions have been applied (e.g. smooth_wave → periodic, woodward_colella → reflecting).

log_error logger Subroutine

Emit an ERROR-level message.

log_finalize logger Subroutine

Close the log file and reset file-logging state.

log_info logger Subroutine

Emit an INFO-level message.

log_init logger Subroutine

Initialise the logger: set verbosity level and optionally open a log file.

log_iteration solver_runtime Subroutine

Log one iteration summary line (time, residual, per-iteration and elapsed wall time). The lightweight iter_s and elapsed_s fields are always populated. Called every ctx % print_freq iterations and once unconditionally after the loop.

log_performance_summary solver_runtime Subroutine

Print the wall-clock performance table after the run completes. Reports total time, I/O time, and the three hot-path timers (compute_resid, flux precompute, face loop) plus overall throughput. Only called when ctx % state % cfg % do_timing is .true..

log_warn logger Subroutine

Emit a WARN-level message.

lowercase_token config Function

Return a left-trimmed, lowercased copy of value. Pure: has no side effects; suitable for use in constant expressions.

minmod2 mp5 Function

Two-argument minmod function. Returns the value with the smaller magnitude if a and b have the same sign, else 0.

minmod4 mp5 Function

Four-argument minmod function. Returns 0 if the arguments do not all share the same sign; otherwise returns the value with the smallest magnitude.

mp5_reconstruct mp5 Subroutine

Perform MP5 reconstruction on the supplied stencil.

Read more…
muscl_koren_reconstruct muscl Subroutine

MUSCL reconstruction with the Koren limiter.

muscl_mc_reconstruct muscl Subroutine

MUSCL reconstruction with the Monotonized Central (MC) limiter.

muscl_minmod_reconstruct muscl Subroutine

MUSCL reconstruction with the Minmod limiter.

muscl_reconstruct muscl Subroutine

Core MUSCL reconstruction kernel (component-wise, left-biased stencil).

Read more…
muscl_superbee_reconstruct muscl Subroutine

MUSCL reconstruction with the Superbee limiter.

muscl_van_leer_reconstruct muscl Subroutine

MUSCL reconstruction with the van Leer smooth limiter.

normalize_config config Subroutine

Lowercase all scheme-selection and option string fields in cfg. Called automatically by validate_config before any comparisons so that namelist values are accepted regardless of the case supplied by the user.

normalize_key config_schema Function

Normalise a user-provided parameter key to lowercase trimmed form.

pack_field time_integration Subroutine

Flatten a (neq x n_pt) field into a length-neq*n_pt 1-D array. Ordering: (eq=1,cell=1), (eq=2,cell=1), ..., (eq=neq,cell=n_pt).

precompute_boundary_fluxes initial_conditions Subroutine

Pre-compute the boundary split fluxes fl_pos/fl_neg/fr_pos/fr_neg for FVS schemes. No-op when the FDS path is active (state%use_fds = .true.).

quote_shell_arg initial_conditions Function

Wrap a filesystem path for the shell used by execute_command_line.

Read more…
read_checkpoint checkpoint Subroutine

Read a checkpoint file and restore solver state.

Read more…
read_config config Subroutine

Read simulation parameters from a namelist file.

Read more…
recon_uses_char_proj_by_default option_registry Function
reconstruct_with_proj spatial_discretization Subroutine

Reconstruct a face flux or state with optional characteristic projection.

Read more…
release_work_arrays solver_state Subroutine

Release all allocatable arrays owned by a solver instance.

report_performance_summary solver_runtime Subroutine

Print the end-of-run performance table once after a completed run.

Read more…
reset_runtime solver_session Subroutine

Tear down the live runtime context while keeping editable config state.

Read more…
resolve_cli_namelist solver_runtime Subroutine

Read the namelist filename from the first command-line argument. Falls back to 'input.nml' when no argument is supplied.

resolve_latest checkpoint Function
resolve_session solver_c_api Function

Resolve an opaque C handle to the active Fortran session pointer.

resolve_time_scheme time_integration Subroutine

Resolve a scheme name to a specific stepper procedure pointer.

Read more…
rk4_step time_integration Subroutine

Advance the solution by one time step using the classic RK4 scheme.

Read more…
roe_flux euler_physics Subroutine

Roe approximate Riemann solver with Harten entropy fix.

Read more…
run_solver solver_runtime Subroutine

Execute the main time-marching loop until time_stop is reached.

Read more…
run_solver_steps solver_runtime Subroutine

Advance the main time loop by at most max_steps iterations.

Read more…
schema_entry_text solver_c_api Function

Shared helper for copying one text field from a schema entry into a C buffer.

set_entry config_schema Subroutine

Fill one slot in the lazily initialised schema table.

set_left_right_states initial_conditions Subroutine

Convert namelist primitives (rho_left, u_left, p_left / rho_right, …) to conserved ghost state vectors and optionally pre-compute boundary split fluxes for FVS schemes.

set_status config_schema Subroutine

Fan out a success flag and optional message to caller-provided outputs.

setup_band_storage time_integration Subroutine

Compute banded-storage dimensions for the Newton-step Jacobian.

Read more…
solver_session_advance solver_session Subroutine

Advance the runtime by at most max_steps iterations.

Read more…
solver_session_copy_solution solver_session Subroutine

Copy the current primitive-variable solution into caller-owned arrays.

Read more…
solver_session_create solver_session Subroutine

Reset a session to its default empty state.

solver_session_destroy solver_session Subroutine

Tear down any live runtime allocations and clear the last error.

solver_session_get_integer solver_session Subroutine

Read an integer configuration field by canonical schema key.

solver_session_get_logical solver_session Subroutine

Read a logical configuration field by canonical schema key.

solver_session_get_point_count solver_session Subroutine

Return the current grid-point count expected by solution copy-out buffers.

solver_session_get_progress solver_session Subroutine

Copy out a lightweight progress snapshot for polling clients.

solver_session_get_real solver_session Subroutine

Read a scalar real configuration field by canonical schema key.

solver_session_get_real3 solver_session Subroutine

Read a real-3 configuration field by canonical schema key.

solver_session_get_string solver_session Subroutine

Read a string or choice-token configuration field by canonical schema key.

solver_session_initialize solver_session Subroutine

Validate the current configuration and allocate the runtime context.

solver_session_last_error solver_session Subroutine

Copy the last stored writable-operation error message.

solver_session_load_namelist solver_session Subroutine

Load configuration from a namelist file into the session.

Read more…
solver_session_run_to_end solver_session Subroutine

Run the current session until time_stop is reached.

solver_session_set_integer solver_session Subroutine

Set an integer configuration field and invalidate any live runtime.

solver_session_set_logical solver_session Subroutine

Set a logical configuration field and invalidate any live runtime.

solver_session_set_real solver_session Subroutine

Set a scalar real configuration field and invalidate any live runtime.

solver_session_set_real3 solver_session Subroutine

Set a real-3 configuration field and invalidate any live runtime.

solver_session_set_string solver_session Subroutine

Set a string or choice-token configuration field and invalidate any runtime.

solver_session_write_checkpoint solver_session Subroutine

Force an immediate checkpoint write using the configured or overridden base name.

solver_session_write_result solver_session Subroutine

Write the current solution in the standard result.dat-style text format.

Read more…
ssprk22_step time_integration Subroutine

Advance the solution by one time step using the SSPRK(2,2) scheme.

Read more…
ssprk54_step time_integration Subroutine

Advance the solution by one time step using the SSPRK(5,4) scheme.

Read more…
steger_warming_split euler_physics Subroutine

Steger-Warming flux vector splitting.

Read more…
steger_warming_split_both euler_physics Subroutine

Fused Steger-Warming flux splitting: returns F^+ and F^- in one call.

Read more…
teardown_runtime solver_runtime Subroutine

Release all allocations held by ctx and finalise the logger. Must be the last call in the lifecycle; ctx is invalid afterwards.

teno5_reconstruct teno5 Subroutine

Perform TENO5 reconstruction on the supplied stencil.

timer_elapsed_running_s timer Function

Return elapsed wall time in seconds, including the current running segment.

Read more…
timer_elapsed_s timer Function

Return accumulated wall time in seconds.

Read more…
timer_report timer Subroutine

Print a one-line performance report to stdout.

Read more…
timer_reset timer Subroutine

Reset a timer to the zero state.

timer_start timer Subroutine

Start (or resume) the timer.

Read more…
timer_stop timer Subroutine

Stop the timer and accumulate elapsed counts.

Read more…
token_in_list option_registry Function
tvd_rk3_step time_integration Subroutine

Advance the solution by one time step using the TVD-RK3 scheme.

Read more…
unpack_add time_integration Subroutine

Add a flattened 1-D correction to a (neq x n_pt) 2-D field in place.

update_ghost boundary_conditions Subroutine

Compute one ghost-state vector and its split fluxes from a boundary cell.

Read more…
update_latest checkpoint Subroutine
upwind1_reconstruct upwind1 Subroutine

First-order upwind reconstruction.

Read more…
upwind2_reconstruct upwind2 Subroutine

Second-order upwind reconstruction.

Read more…
validate_config config Subroutine

Validate that all namelist parameters are physically and numerically sensible.

Read more…
van_leer_split euler_physics Subroutine

van Leer flux vector splitting.

Read more…
van_leer_split_both euler_physics Subroutine

Fused van Leer flux splitting: returns F^+ and F^- in one call.

Read more…
weno11_js_reconstruct weno11_js Subroutine
weno5_fallback_reconstruct weno_cu6 Subroutine
weno5_js_reconstruct weno5_js Subroutine

Perform WENO5-JS reconstruction on the supplied stencil.

Read more…
weno5_smoothness weno_family Subroutine

Compute the Jiang-Shu smoothness indicators for a 5-point WENO5 stencil.

Read more…
weno5_substencils weno_family Subroutine

Compute the three 3rd-order substencil reconstructions for WENO5.

Read more…
weno5_z_reconstruct weno5_z Subroutine

Perform WENO5-Z reconstruction on the supplied stencil.

weno7_js_reconstruct weno7_js Subroutine

Perform WENO7-JS reconstruction on the supplied stencil.

Read more…
weno9_js_reconstruct weno9_js Subroutine
weno_cu6_reconstruct weno_cu6 Subroutine
write_cell_row solver_runtime Subroutine

Write a single row of primitive variables to io_unit in '(4ES20.12)' format. Shared by finalize_runtime and write_snapshot to avoid duplicating the conserved-to-primitive conversion.

write_checkpoint checkpoint Subroutine

Write a checkpoint file for the current solver state.

Read more…
write_snapshot solver_runtime Subroutine

Write a live snapshot of the current solution to snapshot_file. The file is overwritten on each call. A header comment records the current iteration and time; subsequent rows are (x, ρ, u, p) via write_cell_row. Open/write failures are logged as warnings rather than fatal errors so that a snapshot glitch does not abort the run. This file path is retained for compatibility with legacy file-watching tooling; new integrations should prefer the polling session/API surface.

write_solution_file solver_runtime Subroutine

Write the current solution to a text file.