The chemistry.py module#

Summary#

Chemistry

Define and preprocess Chemkin chemistry set.

Material

Surface Chemkin material object.

SurfacePhase

Surface phase object.

verbose

Get current Pychemkin verbose mode.

set_verbose

Set Pychemkin verbose mode.

chemkin_version

Return the Chemkin-CFD-API version number currently in use.

verify_version

Check the Chemkin-CFD-API vwersion.

chemkin_bin_dir

Return the local Ansys Chemkin bin directory.

ansys_dir

Return the local Ansys installation.

done

Release Chemkin license and reset the Chemistry sets.

check_chemistryset

Check whether the Chemistry Set is initialized in Chemkin-CFD-API.

activate_chemistryset

Switch to (re-activate) the Chemistry Set.

force_activate_chemistryset

Activate the Chemistry Set automatically and silently.

chemistryset_new

Create a new Chemistry Set.

chemistryset_initialized

Set the Chemistry Set Initialization flag to True.

check_active_chemistryset

Verify if the chemistry set is currently activated.

verify_chemset_surface

Check the chemistry set has surface chemistry data.

verify_chemset_sizes

Verify the gas chemistry sizes.

set_temp_array

Set up the temperature array for Chemkin-CFD-API calls.

get_symbol_length

Get the length of Chemkin symbols.

Description#

Chemkin Chemistry utilities.

Module detail#

chemistry.verbose() bool#

Get current Pychemkin verbose mode.

chemistry.set_verbose(onoff: bool)#

Set Pychemkin verbose mode.

chemistry.chemkin_version() int#

Return the Chemkin-CFD-API version number currently in use.

chemistry.verify_version(min_version: int) bool#

Check the Chemkin-CFD-API vwersion.

chemistry.chemkin_bin_dir() str#

Return the local Ansys Chemkin bin directory.

chemistry.ansys_dir() str#

Return the local Ansys installation.

chemistry.done()#

Release Chemkin license and reset the Chemistry sets.

chemistry.check_chemistryset(chem_index: int) bool#

Check whether the Chemistry Set is initialized in Chemkin-CFD-API.

chemistry.activate_chemistryset(chem_index: int) int#

Switch to (re-activate) the Chemistry Set.

chemistry.force_activate_chemistryset(chem_index: int)#

Activate the Chemistry Set automatically and silently.

chemistry.chemistryset_new(chem_index: int)#

Create a new Chemistry Set.

chemistry.chemistryset_initialized(chem_index: int)#

Set the Chemistry Set Initialization flag to True.

chemistry.check_active_chemistryset(chem_index: int) bool#

Verify if the chemistry set is currently activated.

chemistry.verify_chemset_surface(chem_set_index: int) bool#

Check the chemistry set has surface chemistry data.

chemistry.verify_chemset_sizes(chem_set_index: int, num_elements: int = -1, num_gas_species: int = -1, num_gas_reactions: int = -1) bool#

Verify the gas chemistry sizes.

chemistry.set_temp_array(temp: float, temp_ele: float | None = None, temp_ion: float | None = None) numpy.typing.NDArray[numpy.double]#

Set up the temperature array for Chemkin-CFD-API calls.

chemistry.get_symbol_length() int#

Get the length of Chemkin symbols.

chemistry.MAX_SPECIES_LENGTH = 17#
chemistry.COMPLETE = 0#
chemistry.LP_c_char#
chemistry.chemkin_verbose = True#