bloc.carbon_utils#
Functions#
|
Return a list of solid carbon species from the gas phase object. |
|
Return the mass fraction of solid carbon species in the gas object. |
|
Return the mole fraction of solid carbon species in the gas object. |
|
Get the PAH species in the gas / states object based on the number of carbon atoms. |
|
Get the mole fraction of PAH species in the gas / states object based on the number of carbon atoms. |
|
Return the mass fraction vector of solid carbon species from a Cantera states object. |
|
Return the mole fraction vector of solid carbon species from a Cantera states object. |
Module Contents#
- bloc.carbon_utils.get_solid_carbon_species(gas, n_C_min=80, solid_species_base=['C(s)', 'C(soot)', 'CSOLID', 'C(gr)'])#
Return a list of solid carbon species from the gas phase object.
- Parameters:
gas (
cantera.Solutionorcantera.SolutionArray) – The solution object from Cantera.n_C_min (
int, optional) – Minimum number of carbon atoms to consider a species as solid. Default is 80, according to Martin et al. see spark-cleantech-l3/bloc#182.solid_species_base (
listofstr, optional) – Predefined list of solid species names. Default is["C(s)", "C(soot)", "CSOLID", "C(gr)"].
- Returns:
solid_species – A list of solid species names that have at least n_C_min carbon atoms OR are in the predefined solid species list.
- Return type:
listofstr
- bloc.carbon_utils.get_solid_carbon_mass_fraction(gas, solid_sp=['C(s)', 'C(soot)', 'CSOLID'], n_C_min=300)#
Return the mass fraction of solid carbon species in the gas object.
Solid species are identified by their name or by the number of carbon atoms, through
get_solid_carbon_species().- Parameters:
gas (
cantera.Solution) – The gas object containing gaseous species and soot.solid_sp (
listofstr, optional) – List of solid species to consider. Default is [“C(s)”, “C(soot)”, “CSOLID”].n_C_min (
int, optional) – Minimum number of carbon atoms to consider a species as solid. Default is 300. This is used as a second filter to identify solid carbon species. A specie is considered solid if it satisfies one criterium (s in solid_sp) OR the other (n_C >= n_C_min).
- Returns:
The mass fraction of solid carbon species in the gas object.
- Return type:
float
- bloc.carbon_utils.get_solid_carbon_mole_fraction(gas, solid_sp=['C(s)', 'C(soot)', 'CSOLID'], n_C_min=300)#
Return the mole fraction of solid carbon species in the gas object.
- Parameters:
gas (
cantera.Solutionorcantera.SolutionArray) – The gas object with composition set.solid_sp (
listofstr, optional) – List of solid species to consider. Default is [“C(s)”, “C(soot)”, “CSOLID”].n_C_min (
int, optional) – Minimum number of carbon atoms to consider a species as solid. Default is 300.
- Returns:
The mole fraction of solid carbon species in the gas object.
- Return type:
float
- bloc.carbon_utils.get_PAH_species(gas, n_C_min=6, n_C_max=300)#
Get the PAH species in the gas / states object based on the number of carbon atoms.
- bloc.carbon_utils.get_PAH_mole_fraction(gas, n_C_min=6, n_C_max=300)#
Get the mole fraction of PAH species in the gas / states object based on the number of carbon atoms.
- bloc.carbon_utils.get_solid_carbon_mass_fraction_from_states(states, solid_sp=['C(s)', 'C(soot)', 'CSOLID'], n_C_min=300)#
Return the mass fraction vector of solid carbon species from a Cantera states object.
Solid species are identified by their name or by the number of carbon atoms, through
get_solid_carbon_species().- Parameters:
states (
cantera.SolutionArray) – The states object from Cantera.solid_sp (
listofstr, optional) – List of solid species to consider. Default is [“C(s)”, “C(soot)”, “CSOLID”].n_C_min (
int, optional) – Minimum number of carbon atoms to consider a species as solid. Default is 300. This is used as a second filter to identify solid carbon species. A specie is considered solid if it satisfies
- Returns:
The mass fraction vector of solid carbon species (for each time step).
- Return type:
np.ndarray
- bloc.carbon_utils.get_solid_carbon_mole_fraction_from_states(states, solid_sp=['C(s)', 'C(soot)', 'CSOLID'], n_C_min=300)#
Return the mole fraction vector of solid carbon species from a Cantera states object.
Solid species are identified by their name or by the number of carbon atoms, through
get_solid_carbon_species().- Parameters:
states (
cantera.SolutionArray) – The states object from Cantera.solid_sp (
listofstr, optional) – List of solid species to consider. Default is [“C(s)”, “C(soot)”, “CSOLID”].n_C_min (
int, optional) – Minimum number of carbon atoms to consider a species as solid. Default is 300. This is used as a second filter to identify solid carbon species. A specie is considered solid if it satisfies one criterium (s in solid_sp) OR the other (n_C >= n_C_min).
- Returns:
The mole fraction vector of solid carbon species (for each time step).
- Return type:
np.ndarray