MUSICA Python API#

C++ Bindings#

Core#

Wrapper classes for MICM

class musica._musica._micm.MICM#

Bases: pybind11_object

_pybind11_conduit_v1_()#
class musica._musica._micm.VectorConditions#

Bases: pybind11_object

_pybind11_conduit_v1_()#
append(self: musica._musica._micm.VectorConditions, x: micm::Conditions) None#

Add an item to the end of the list

clear(self: musica._musica._micm.VectorConditions) None#

Clear the contents

extend(*args, **kwargs)#

Overloaded function.

  1. extend(self: musica._musica._micm.VectorConditions, L: musica._musica._micm.VectorConditions) -> None

Extend the list by appending all the items in the given list

  1. extend(self: musica._musica._micm.VectorConditions, L: collections.abc.Iterable) -> None

Extend the list by appending all the items in the given list

insert(self: musica._musica._micm.VectorConditions, i: SupportsInt, x: micm::Conditions) None#

Insert an item at a given position.

pop(*args, **kwargs)#

Overloaded function.

  1. pop(self: musica._musica._micm.VectorConditions) -> micm::Conditions

Remove and return the last item

  1. pop(self: musica._musica._micm.VectorConditions, i: typing.SupportsInt) -> micm::Conditions

Remove and return the item at index i

class musica._musica._micm._Conditions(temperature: float | int | None = None, pressure: float | int | None = None, air_density: float | int | None = None)#

Bases: pybind11_object

Conditions class for the MICM solver. If air density is not provided, it will be calculated from the Ideal Gas Law using the provided temperature and pressure.

temperature#

Temperature in Kelvin.

Type:

float

pressure#

Pressure in Pascals.

Type:

float

air_density#

Air density in mol m-3

Type:

float

_pybind11_conduit_v1_()#
property air_density#
property pressure#
property temperature#
class musica._musica._micm._SolverResult#

Bases: pybind11_object

_pybind11_conduit_v1_()#
property state#
property stats#
class musica._musica._micm._SolverResultsStats#

Bases: pybind11_object

_pybind11_conduit_v1_()#
property accepted#
property decompositions#
property final_time#
property function_calls#
property jacobian_updates#
property number_of_steps#
property rejected#
property solves#
class musica._musica._micm._SolverState#

Bases: pybind11_object

Members:

NotYetCalled

Running

Converged

ConvergenceExceededMaxSteps

StepSizeTooSmall

RepeatedlySingularMatrix

NaNDetected

InfDetected

AcceptingUnconvergedIntegration

AcceptingUnconvergedIntegration = <_SolverState.AcceptingUnconvergedIntegration: 8>#
Converged = <_SolverState.Converged: 2>#
ConvergenceExceededMaxSteps = <_SolverState.ConvergenceExceededMaxSteps: 3>#
InfDetected = <_SolverState.InfDetected: 7>#
NaNDetected = <_SolverState.NaNDetected: 6>#
NotYetCalled = <_SolverState.NotYetCalled: 0>#
RepeatedlySingularMatrix = <_SolverState.RepeatedlySingularMatrix: 5>#
Running = <_SolverState.Running: 1>#
StepSizeTooSmall = <_SolverState.StepSizeTooSmall: 4>#
_pybind11_conduit_v1_()#
_SolverState.name -> str
property value#
class musica._musica._micm._State#

Bases: pybind11_object

_pybind11_conduit_v1_()#
concentration_strides(self: musica._musica._micm._State) tuple[int, int]#
property concentrations#

native 1D list of concentrations, ordered by species and grid cell according to matrix type

property conditions#

list of conditions structs for each grid cell

number_of_grid_cells(self: musica._musica._micm._State) int#
user_defined_rate_parameter_strides(self: musica._musica._micm._State) tuple[int, int]#
property user_defined_rate_parameters#

native 1D list of user-defined rate parameters, ordered by parameter and grid cell according to matrix type

musica._musica._micm._create_solver(arg0: str, arg1: musica::MICMSolver) musica._musica._micm.MICM#
musica._musica._micm._create_solver_from_mechanism(arg0: mechanism_configuration::v1::types::Mechanism, arg1: musica::MICMSolver, arg2: bool) musica._musica._micm.MICM#
musica._musica._micm._create_state(arg0: musica._musica._micm.MICM, arg1: SupportsInt) musica::State#
musica._musica._micm._get_micm_version() str#

Get the version of MICM

musica._musica._micm._is_cuda_available(*args, **kwargs)#

Overloaded function.

  1. _is_cuda_available() -> bool

Check if CUDA is available

  1. _is_cuda_available() -> bool

Check if CUDA is available

musica._musica._micm._micm_solve(arg0: musica._musica._micm.MICM, arg1: musica::State, arg2: SupportsFloat) musica._musica._micm._SolverResult#

Solve the chemistry system

musica._musica._micm._print_state(arg0: musica::State, arg1: SupportsFloat) None#

Print the state to stdout with the current time

musica._musica._micm._species_ordering(arg0: musica::State) dict[str, int]#

Return map of species names to their indices in the state concentrations vector

musica._musica._micm._user_defined_rate_parameters_ordering(arg0: musica::State) dict[str, int]#

Return map of reaction rate parameters to their indices in the state user-defined rate parameters vector

musica._musica._micm._vector_size(arg0: musica::MICMSolver) int#

Returns the vector dimension for vector-ordered solvers, 0 otherwise.

class musica._musica._micm._SolverType#

Bases: pybind11_object

Members:

rosenbrock

rosenbrock_standard_order

backward_euler

backward_euler_standard_order

cuda_rosenbrock

_pybind11_conduit_v1_()#
backward_euler = <_SolverType.backward_euler: 3>#
backward_euler_standard_order = <_SolverType.backward_euler_standard_order: 4>#
cuda_rosenbrock = <_SolverType.cuda_rosenbrock: 5>#
_SolverType.name -> str
rosenbrock = <_SolverType.rosenbrock: 1>#
rosenbrock_standard_order = <_SolverType.rosenbrock_standard_order: 2>#
property value#

Mechanism Configuration#

Wrapper classes for Mechanism Configuration for the chemical system configuration schema

class musica._musica._mechanism_configuration._Arrhenius(name: str | None = None, A: float | None = None, B: float | None = None, C: float | None = None, Ea: float | None = None, D: float | None = None, E: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing an Arrhenius rate constant.

k = A * exp( C / T ) * ( T / D )^B * exp( 1 - E * P )

where:

k = rate constant A = pre-exponential factor [(mol m-3)^(n-1)s-1] B = temperature exponent [unitless] C = exponential term [K-1] D = reference temperature [K] E = pressure scaling term [Pa-1] T = temperature [K] P = pressure [Pa] n = number of reactants

name#

The name of the Arrhenius rate constant.

Type:

str

A#

Pre-exponential factor [(mol m-3)^(n-1)s-1] where n is the number of reactants.

Type:

float

B#

Temperature exponent [unitless].

Type:

float

C#

Exponential term [K-1].

Type:

float

D#

Reference Temperature [K].

Type:

float

E#

Pressure scaling term [Pa-1].

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the Arrhenius rate constant.

Type:

Dict[str, Any]

property A#
property B#
property C#
property D#
property E#
_pybind11_conduit_v1_()#
property gas_phase#
property name#
property other_properties#
property products#
property reactants#
serialize() Dict#

Serialize the Arrhenius object to a dictionary using only Python-visible data.

Returns:

A dictionary representation of the Arrhenius object.

Return type:

Dict

property type#

Get the reaction type.

class musica._musica._mechanism_configuration._Branched(name: str | None = None, X: float | None = None, Y: float | None = None, a0: float | None = None, n: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, nitrate_products: List[_Species | Tuple[float, _Species]] | None = None, alkoxy_products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a branched reaction rate constant.

name#

The name of the branched reaction rate constant.

Type:

str

X#

Pre-exponential branching factor [(mol m-3)^-(n-1)s-1].

Type:

float

Y#

Exponential branching factor [K-1].

Type:

float

a0#

Z parameter [unitless].

Type:

float

n#

A parameter [unitless].

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

nitrate_products#

A list of products formed in the nitrate branch.

Type:

List[Union[Species, Tuple[float, Species]]]

alkoxy_products#

A list of products formed in the alkoxy branch.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the branched reaction rate constant.

Type:

Dict[str, Any]

property X#
property Y#
_pybind11_conduit_v1_()#
property a0#
property alkoxy_products#
property gas_phase#
property n#
property name#
property nitrate_products#
property other_properties#
property reactants#
serialize() Dict#

Serialize the Branched object to a dictionary using only Python-visible data.

Returns:

A dictionary representation of the Branched object.

Return type:

Dict

property type#

Get the reaction type.

class musica._musica._mechanism_configuration._Emission(name: str | None = None, scaling_factor: float | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing an emission reaction rate constant.

name#

The name of the emission reaction rate constant.

Type:

str

scaling_factor#

The scaling factor for the emission rate constant.

Type:

float

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the emission reaction rate constant.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property gas_phase#
property name#
property other_properties#
property products#
property scaling_factor#
serialize() Dict#
property type#
class musica._musica._mechanism_configuration._FirstOrderLoss(name: str | None = None, scaling_factor: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a first-order loss reaction rate constant.

name#

The name of the first-order loss reaction rate constant.

Type:

str

scaling_factor#

The scaling factor for the first-order loss rate constant.

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the first-order loss reaction rate constant.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property gas_phase#
property name#
property other_properties#
property reactants#
property scaling_factor#
serialize() Dict#

Serialize the FirstOrderLoss object to a dictionary using only Python-visible data.

Returns:

A dictionary representation of the FirstOrderLoss object.

Return type:

Dict

property type#
class musica._musica._mechanism_configuration._Mechanism(name: str | None = None, reactions: List[Any] | None = None, species: List[_Species] | None = None, phases: List[_Phase] | None = None, version: _Version | None = None)#

Bases: pybind11_object

A class representing a chemical mechanism.

name#

The name of the mechanism.

Type:

str

reactions#

A list of reactions in the mechanism.

Type:

List[Reaction]

species#

A list of species in the mechanism.

Type:

List[Species]

phases#

A list of phases in the mechanism.

Type:

List[Phase]

version#

The version of the mechanism.

Type:

Version

_pybind11_conduit_v1_()#
export(file_path: str) None#
property name#
property phases#
property reactions#
serialize() Dict#
property species#
property version#
class musica._musica._mechanism_configuration._Parser#

Bases: pybind11_object

_pybind11_conduit_v1_()#
parse(self: musica._musica._mechanism_configuration._Parser, arg0: str) musica._musica._mechanism_configuration._Mechanism#
parse_and_convert_v0(self: musica._musica._mechanism_configuration._Parser, arg0: str) musica._musica._mechanism_configuration._Mechanism#

Parse a v0 mechanism configuration file

class musica._musica._mechanism_configuration._Phase(name: str | None = None, species: List[_Species] | List[_PhaseSpecies] | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a phase in a chemical mechanism.

name#

The name of the phase.

Type:

str

species#

A list of species in the phase.

Type:

List[Species]

other_properties#

A dictionary of other properties of the phase.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property name#
property other_properties#
serialize()#
property species#
class musica._musica._mechanism_configuration._PhaseSpecies(name: str | None = None, diffusion_coefficient_m2_s: float | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

Represents a chemical species within a specific phase of a mechanism, including phase-specific properties such as diffusion coefficients.

This class is distinct from a regular Species class in that it models properties relevant to the species’ behavior in a particular phase (e.g., gas, liquid, or solid), such as the diffusion coefficient.

name#

The name of the species.

Type:

str

diffusion_coefficient_m2_s#

Diffusion coefficient in the phase [m2 s-1].

Type:

float

other_properties#

A dictionary of other phase-specific properties of the species.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property diffusion_coefficient_m2_s#
property name#
property other_properties#
serialize() Dict#
class musica._musica._mechanism_configuration._Photolysis(name: str | None = None, scaling_factor: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a photolysis reaction rate constant.

name#

The name of the photolysis reaction rate constant.

Type:

str

scaling_factor#

The scaling factor for the photolysis rate constant.

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the photolysis reaction rate constant.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property gas_phase#
property name#
property other_properties#
property products#
property reactants#
property scaling_factor#
serialize() Dict#
property type#
class musica._musica._mechanism_configuration._ReactionComponent(name: str | None = None, coefficient: float | None = 1.0, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a reaction component in a chemical reaction.

A reaction component typically consists of a chemical species, its stoichiometric coefficient in the reaction, and any additional properties relevant to its role in the reaction.

species_name#

The name of the chemical species involved in the reaction.

Type:

str

coefficient#

The stoichiometric coefficient of the species in the reaction.

Type:

float

other_properties#

A dictionary of other properties relevant to the reaction component.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property coefficient#
property other_properties#
serialize() Dict#
property species_name#
class musica._musica._mechanism_configuration._Reactions(reactions: List[Any] | None = None)#

Bases: pybind11_object

A class representing a collection of reactions in a chemical mechanism.

reactions#

A list of reactions in the mechanism.

Type:

List[Any]

_pybind11_conduit_v1_()#
property arrhenius#
property branched#
property emission#
property first_order_loss#
property photolysis#
property surface#
property taylor_series#
property ternary_chemical_activation#
property troe#
property tunneling#
property user_defined#
class musica._musica._mechanism_configuration._ReactionsIterator#

Bases: pybind11_object

_pybind11_conduit_v1_()#
class musica._musica._mechanism_configuration._Species(name: str | None = None, molecular_weight_kg_mol: float | None = None, constant_concentration_mol_m3: float | None = None, constant_mixing_ratio_mol_mol: float | None = None, is_third_body: bool | None = False, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a species in a chemical mechanism.

name#

The name of the species.

Type:

str

molecular_weight_kg_mol#

Molecular weight [kg mol-1]

Type:

float

constant_concentration_mol_m3#

Constant concentration of the species (mol m-3)

Type:

float

constant_mixing_ratio_mol_mol#

Constant mixing ratio of the species (mol mol-1)

Type:

float

is_third_body#

Whether the species is a third body.

Type:

bool

other_properties#

A dictionary of other properties of the species.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property constant_concentration_mol_m3#
property constant_mixing_ratio_mol_mol#
property is_third_body#
property molecular_weight_kg_mol#
property name#
property other_properties#
serialize() Dict#
class musica._musica._mechanism_configuration._Surface(name: str | None = None, reaction_probability: float | None = None, gas_phase_species: _Species | Tuple[float, _Species] | None = None, gas_phase_products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a surface in a chemical mechanism.

name#

The name of the surface.

Type:

str

reaction_probability#

The probability of a reaction occurring on the surface.

Type:

float

gas_phase_species#

The gas phase species involved in the reaction.

Type:

Union[Species, Tuple[float, Species]]

gas_phase_products#

The gas phase products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the surface.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property gas_phase#
property gas_phase_products#
property gas_phase_species#
property name#
property other_properties#
property reaction_probability#
serialize() Dict#
property type#
class musica._musica._mechanism_configuration._TaylorSeries(name: str | None = None, gas_phase: _Phase | None = None, A: float | None = None, B: float | None = None, C: float | None = None, D: float | None = None, E: float | None = None, taylor_coefficients: List[float] | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a Taylor series rate constant.

The rate constant k is represented as a Taylor series expansion in temperature (and optionally other variables):

k = a0 + a1*T + a2*T^2 + a3*T^3 + … + an*T^n

where:

k = rate constant T = temperature [K] a0, a1, …, an = Taylor series coefficients

Optionally, additional parameters (A, B, C, D, E) may be provided for compatibility or extended forms.

name#

The name of the Taylor series rate constant.

Type:

str

taylor_coefficients#

Coefficients [a0, a1, …, an] for the Taylor series expansion.

Type:

List[float]

A#

Optional parameter for extended forms.

Type:

float, optional

B#

Optional parameter for extended forms.

Type:

float, optional

C#

Optional parameter for extended forms.

Type:

float, optional

D#

Optional parameter for extended forms.

Type:

float, optional

E#

Optional parameter for extended forms.

Type:

float, optional

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the Taylor series rate constant.

Type:

Dict[str, Any]

property A#
property B#
property C#
property D#
property E#
_pybind11_conduit_v1_()#
property gas_phase#
property name#
property other_properties#
property products#
property reactants#
serialize() Dict#
property taylor_coefficients#
property type#
class musica._musica._mechanism_configuration._TernaryChemicalActivation(name: str | None = None, k0_A: float | None = None, k0_B: float | None = None, k0_C: float | None = None, kinf_A: float | None = None, kinf_B: float | None = None, kinf_C: float | None = None, Fc: float | None = None, N: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a Ternary Chemical Activation rate constant.

name#

The name of the Ternary Chemical Activation rate constant.

Type:

str

k0_A#

Pre-exponential factor for the low-pressure limit [(mol m-3)^(n-1)s-1].

Type:

float

k0_B#

Temperature exponent for the low-pressure limit [unitless].

Type:

float

k0_C#

Exponential term for the low-pressure limit [K-1].

Type:

float

kinf_A#

Pre-exponential factor for the high-pressure limit [(mol m-3)^(n-1)s-1].

Type:

float

kinf_B#

Temperature exponent for the high-pressure limit [unitless].

Type:

float

kinf_C#

Exponential term for the high-pressure limit [K-1].

Type:

float

Fc#

Ternary Chemical Activation parameter [unitless].

Type:

float

N#

Ternary Chemical Activation parameter [unitless].

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the Ternary Chemical Activation rate constant.

Type:

Dict[str, Any]

property Fc#
property N#
_pybind11_conduit_v1_()#
property gas_phase#
property k0_A#
property k0_B#
property k0_C#
property kinf_A#
property kinf_B#
property kinf_C#
property name#
property other_properties#
property products#
property reactants#
serialize() Dict#

Serialize the Ternary Chemical Activation object to a dictionary using only Python-visible data.

Returns:

A dictionary representation of the Ternary Chemical Activation object.

Return type:

Dict

property type#
class musica._musica._mechanism_configuration._Troe(name: str | None = None, k0_A: float | None = None, k0_B: float | None = None, k0_C: float | None = None, kinf_A: float | None = None, kinf_B: float | None = None, kinf_C: float | None = None, Fc: float | None = None, N: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a Troe rate constant.

name#

The name of the Troe rate constant.

Type:

str

k0_A#

Pre-exponential factor for the low-pressure limit [(mol m-3)^(n-1)s-1].

Type:

float

k0_B#

Temperature exponent for the low-pressure limit [unitless].

Type:

float

k0_C#

Exponential term for the low-pressure limit [K-1].

Type:

float

kinf_A#

Pre-exponential factor for the high-pressure limit [(mol m-3)^(n-1)s-1].

Type:

float

kinf_B#

Temperature exponent for the high-pressure limit [unitless].

Type:

float

kinf_C#

Exponential term for the high-pressure limit [K-1].

Type:

float

Fc#

Troe parameter [unitless].

Type:

float

N#

Troe parameter [unitless].

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the Troe rate constant.

Type:

Dict[str, Any]

property Fc#
property N#
_pybind11_conduit_v1_()#
property gas_phase#
property k0_A#
property k0_B#
property k0_C#
property kinf_A#
property kinf_B#
property kinf_C#
property name#
property other_properties#
property products#
property reactants#
serialize() Dict#

Serialize the Troe object to a dictionary using only Python-visible data.

Returns:

A dictionary representation of the Troe object.

Return type:

Dict

property type#
class musica._musica._mechanism_configuration._Tunneling(name: str | None = None, A: float | None = None, B: float | None = None, C: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a quantum tunneling reaction rate constant.

k = A * exp( -B / T ) * exp( C / T^3 )

where:

k = rate constant A = pre-exponential factor [(mol m-3)^(n-1)s-1] B = tunneling parameter [K^-1] C = tunneling parameter [K^-3] T = temperature [K] n = number of reactants

name#

The name of the tunneling reaction rate constant.

Type:

str

A#

Pre-exponential factor [(mol m-3)^(n-1)s-1].

Type:

float

B#

Tunneling parameter [K^-1].

Type:

float

C#

Tunneling parameter [K^-3].

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the tunneling reaction rate constant.

Type:

Dict[str, Any]

property A#
property B#
property C#
_pybind11_conduit_v1_()#
property gas_phase#
property name#
property other_properties#
property products#
property reactants#
serialize() Dict#

Serialize the Tunneling object to a dictionary using only Python-visible data.

Returns:

A dictionary representation of the Tunneling object.

Return type:

Dict

property type#
class musica._musica._mechanism_configuration._UserDefined(name: str | None = None, scaling_factor: float | None = None, reactants: List[_Species | Tuple[float, _Species]] | None = None, products: List[_Species | Tuple[float, _Species]] | None = None, gas_phase: _Phase | None = None, other_properties: Dict[str, Any] | None = None)#

Bases: pybind11_object

A class representing a user-defined reaction rate constant.

name#

The name of the photolysis reaction rate constant.

Type:

str

scaling_factor#

The scaling factor for the photolysis rate constant.

Type:

float

reactants#

A list of reactants involved in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

products#

A list of products formed in the reaction.

Type:

List[Union[Species, Tuple[float, Species]]]

gas_phase#

The gas phase in which the reaction occurs.

Type:

Phase

other_properties#

A dictionary of other properties of the photolysis reaction rate constant.

Type:

Dict[str, Any]

_pybind11_conduit_v1_()#
property gas_phase#
property name#
property other_properties#
property products#
property reactants#
property scaling_factor#
serialize() Dict#
property type#
class musica._musica._mechanism_configuration._Version#

Bases: pybind11_object

_pybind11_conduit_v1_()#
property major#
property minor#
property patch#
to_string(self: musica._musica._mechanism_configuration._Version) str#
class musica._musica._mechanism_configuration._ReactionType#

Bases: pybind11_object

Members:

Arrhenius

Branched

Emission

FirstOrderLoss

Photolysis

Surface

TaylorSeries

TernaryChemicalActivation

Troe

Tunneling

UserDefined

Arrhenius = <_ReactionType.Arrhenius: 0>#
Branched = <_ReactionType.Branched: 1>#
Emission = <_ReactionType.Emission: 2>#
FirstOrderLoss = <_ReactionType.FirstOrderLoss: 3>#
Photolysis = <_ReactionType.Photolysis: 4>#
Surface = <_ReactionType.Surface: 5>#
TaylorSeries = <_ReactionType.TaylorSeries: 6>#
TernaryChemicalActivation = <_ReactionType.TernaryChemicalActivation: 7>#
Troe = <_ReactionType.Troe: 8>#
Tunneling = <_ReactionType.Tunneling: 9>#
UserDefined = <_ReactionType.UserDefined: 10>#
_pybind11_conduit_v1_()#
_ReactionType.name -> str
property value#

Musica Types#

TUVX#

CARMA#