Skip to content

deprecate_gri30_phases

Ray Speth edited this page Feb 8, 2021 · 6 revisions

Transitional Phase names in GRI-3.0-based Files

Several phases in the new gri30.yaml, gri30_highT.yaml, and h2o2.yaml files are transitional definitions that are marked deprecated and will be removed after Cantera 2.5. These include the gri30_mix and gri30_multi phases in both gri30.yaml and gri30_highT.yaml, as well as the ohmech-multi phase in h2o2.yaml. In addition, the default phase definition will have mixture-averaged transport properties. We anticipate that these changes will not cause any results from Cantera to change. If you have found a case where your results have changed, please post a message on the Cantera Google Users' Group.

If you need to change the transport model of the input file that you're loading, the following methods are recommended replacements. Note that these examples use the gri30.yaml input file, but the same syntax can be used for any input file.

Python

The general syntax is:

ct.Solution(input-file-name, phase-name, transport_model=desired-transport-model)

The following specific examples omit the optional phase-name argument, so they load the first phase in the file:

# No transport model enabled
ct.Solution('gri30.yaml', transport_model=None)
# Mixture-averaged transport
ct.Solution('gri30.yaml', transport_model='Mix')
# Multicomponent transport
ct.Solution('gri30.yaml', transport_model='Multi')

MATLAB

The general syntax is

Solution(input-file-name, phase-name, transport-name);

In MATLAB, the phase-name and transport-name arguments are both optional. However, if you want to set the transport model, you must include the phase-name argument. The following examples use the gri30 phase name from the gri30.yaml input file.

% No transport model enabled
Solution('gri30.yaml', 'gri30', 'None');
% Mixture-averaged transport
Solution('gri30.yaml', 'gri30', 'Mix');
% Multicomponent transport
Solution('gri30.yaml', 'gri30', 'Multi');

C++

The general syntax is

newSolution(input-file-name, phase-name, transport-name);

Like MATLAB, the phase-name and transport-name arguments are both optional. However, if you want to set the transport model, you must include the phase-name argument. The following examples use the gri30 phase name from the gri30.yaml input file.

// No transport model enabled
newSolution("gri30.yaml", "gri30", "None");
// Mixture-averaged transport
newSolution("gri30.yaml", "gri30", "Mix");
//Multicomponent transport
newSolution("gri30.yaml", "gri30", "Multi")