Appendix: tabulated_data Utility

The tabulated_data utility generates tabulated equation-of-state and optional transport files in the EoSTables/<table_name>/ layout used by Stream tabular EoS workflows.

The utility is installed as tabulated_data in the Stream bin directory.

What The Utility Produces

For a given source mode and set of options, the utility writes a table directory:

EoSTables/<table_name>/

The directory contains:

  • info.desc (table metadata + file references)

  • omega.fit

  • EoS correction surfaces: - kd-tree format: densityCorrect_*.kd, energyCorrect_*.kd - fixed-table format: densityCorrect.fixedTable, energyCorrect.fixedTable

  • Optional fields: - entropy_*.kd - viscosity_*.kd - conductivity_*.kd

  • Optional temperature limits: - TlimitHi.fit - TlimitLo.fit

The exact set of files depends on source mode and output flags.

Invocation

General CLI form:

tabulated_data [--log_level {DEBUG,INFO,WARNING,ERROR}] {cantera,fit_table,refprop} ...

Source modes:

  • cantera: samples a pure-species state from a Cantera mechanism.

  • fit_table: ingests CHEM -fitTable style files.

  • refprop: samples a pure fluid through CoolProp backend queries (REFPROP or HEOS).

Required Inputs By Mode

Required Inputs

Mode

Required Inputs

Notes

cantera

mechanism, --species, --pmin, --pmax, --tmin, --tmax

Requires Python Cantera package.

fit_table

fit_table positional input file

Pressure/temperature bounds are optional and default to fit file limits.

refprop

--fluid, --pmin, --pmax, --tmin, --tmax

Requires CoolProp Python package. Backend defaults to REFPROP.

Common Flags

These options are available for all source modes unless noted otherwise.

Common Flags

Flag

Default

Description

--output_root

EoSTables

Root output directory.

--output_mode {kd,fixed,both}

kd

Write kd files, fixed tables, or both.

--info_mode {kd,fixed}

kd

When --output_mode both is used, selects which set info.desc references.

--omega_mode {constant,fitfile,auto}

mode-dependent

constant writes constant omega.fit; fitfile copies user file; auto uses source-provided fit data.

--omega_constant

1.0

Constant omega value when --omega_mode constant.

--omega_fit_file

none

Existing fit file to copy when --omega_mode fitfile.

--omega_intervals

128

Interval count for generated omega fit.

--tlimit_hi_fit

none

Optional explicit high-T limit fit file to copy as TlimitHi.fit.

--tlimit_lo_fit

none

Optional explicit low-T limit fit file to copy as TlimitLo.fit.

--depth_x, --depth_y

5, 5

Base grid depth in each axis (cells = \(2^{depth}\)).

--num_p, --num_t

none

Explicit pressure/temperature cell counts; overrides depth for that axis.

--adaptive_grid

off

Enables adaptive depth selection within specified min/max depths.

--min_depth_x, --min_depth_y

2, 2

Minimum adaptive depths.

--adapt_l1_tol

1e-5

Adaptive mean relative error target.

--adapt_l8_tol

1e-4

Adaptive max relative error target.

--adapt_ref_floor

1e-12

Small floor in adaptive relative error denominator.

--adapt_max_iters

32

Maximum adaptive refinement iterations.

--log_p / --linear_p

--log_p

Pressure axis scaling for fitting grid.

--log_t / --linear_t

--log_t

Temperature axis scaling for fitting grid.

--baseline_mode

mode-dependent

Baseline correction model (zero/ideal/auto depending on source mode).

--R, --b, --r1, --n, --hf

0

Baseline coefficients used when --baseline_mode zero.

Notes:

  • --adaptive_grid cannot be combined with --num_p or --num_t.

  • --omega_mode auto requires the source adapter to provide omega fit data.

cantera Mode

Purpose: sample a pure species from a Cantera mechanism and produce tabulated correction fields.

Additional flags:

cantera Mode Flags

Flag

Default

Description

mechanism (positional)

required

Cantera YAML mechanism path.

--phase

none

Optional phase name in mechanism.

--species

required

Species name to tabulate as pure fluid.

--table_name

species name

Output table directory name.

--pmin, --pmax

required

Pressure bounds [Pa].

--tmin, --tmax

required

Temperature bounds [K].

--no_transport

off

Skip viscosity/conductivity table generation.

--include_entropy

off

Also write entropy table.

Baseline behavior:

  • Default --baseline_mode ideal computes baseline terms from sampled Cantera state.

fit_table Mode

Purpose: ingest CHEM -fitTable input and generate Stream table outputs.

Additional flags:

fit_table Mode Flags

Flag

Default

Description

fit_table (positional)

required

Path to CHEM fit table input file.

--table_name

file stem

Output table directory name.

--pmin, --pmax

source limits

Optional resampling pressure bounds [Pa].

--tmin, --tmax

source limits

Optional resampling temperature bounds [K].

--fit_eval_mode {chem,linear}

chem

chem uses CHEM-style interpolation logic; linear uses separable linear interpolation.

Fit table input format (CHEM style):

m n
nT
T_1 T_2 ... T_nT
nP
P_1 P_2 ... P_nP
rho(P1,T1) ... rho(PnP,TnT)   # nP*nT values
h(P1,T1)   ... h(PnP,TnT)     # nP*nT values

Compatibility notes:

  • --adaptive_grid is supported in fit_table mode only when --fit_eval_mode chem.

refprop Mode

Purpose: sample pure-fluid properties with CoolProp backends and generate tabulated outputs.

Additional flags:

refprop Mode Flags

Flag

Default

Description

--fluid

required

Fluid name (for example Water, Nitrogen).

--backend {REFPROP,HEOS}

REFPROP

CoolProp backend prefix.

--table_name

fluid name

Output table directory name.

--pmin, --pmax

required

Pressure bounds [Pa].

--tmin, --tmax

required

Temperature bounds [K].

--no_transport

off

Skip viscosity/conductivity table generation.

--include_entropy

off

Also write entropy table.

--liquid_bias

off

Bias sampling toward liquid side near saturation.

--vapor_bias

off

Bias sampling toward vapor side near saturation.

--bias_factor

mode-dependent

Custom bias multiplier for saturation pressure mapping.

--noextrapolate

off

Forces bias factor to 1.0.

--auto_tlimits / --no_auto_tlimits

auto on

Enable or disable generated TlimitHi/Lo fits.

--tlimit_intervals

128

Interval count for generated T-limit fits.

refprop-specific behavior:

  • --baseline_mode auto is available in this mode and is the default.

  • --liquid_bias and --vapor_bias are mutually exclusive.

  • Default --omega_mode in this mode is auto.

Output Selection And Referencing

--output_mode controls file generation:

  • kd: writes kd-tree fields.

  • fixed: writes fixed-table fields.

  • both: writes both kd and fixed outputs.

--info_mode controls what info.desc points to when --output_mode both is used.

Examples

Cantera species tabulation:

tabulated_data cantera chem.yaml --species O2 \
  --pmin 1.0e5 --pmax 5.0e6 --tmin 250 --tmax 3000 \
  --table_name O2_table --output_mode both --info_mode kd

CHEM fit table conversion:

tabulated_data fit_table oxygen.fitTable \
  --table_name oxygen_tab --fit_eval_mode chem \
  --adaptive_grid --min_depth_x 2 --min_depth_y 2 --depth_x 6 --depth_y 6

REFPROP/HEOS-style pure-fluid table:

tabulated_data refprop --backend HEOS --fluid Water \
  --pmin 1.0e5 --pmax 2.0e7 --tmin 280 --tmax 600 \
  --liquid_bias --output_mode kd

Dependencies And Troubleshooting

  • cantera mode requires Cantera Python package.

  • refprop mode requires CoolProp Python package.

  • If --omega_mode fitfile is used, --omega_fit_file must be provided.

  • If explicitly-provided --tlimit_hi_fit or --tlimit_lo_fit paths are invalid, the utility exits with an error.

For the latest option set, run:

tabulated_data -h
tabulated_data cantera -h
tabulated_data fit_table -h
tabulated_data refprop -h