libICEpost.src.thermophysicalModels.thermoModels.thermoMixture.mixingRules.Thermo
@author: F. Ramognino <federico.ramognino@polimi.it> Last update: 17/10/2023
Package for handling mixing rules for combining thermodynamic data of specie into a multi-component mixture
Submodules
Classes
Class handling mixing rule to combine thermodynamic data of specie into a multi-component mixture. |
|
Class handling mixing of multi-component mixture: thermodynamic data in janaf7 definition. |
|
Class handling mixing of multi-component mixture: thermodynamic data in constantCp definition. |
Package Contents
- class libICEpost.src.thermophysicalModels.thermoModels.thermoMixture.mixingRules.Thermo.ThermoMixing(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture)[source]
Bases:
libICEpost.src.base.BaseClass.BaseClassClass handling mixing rule to combine thermodynamic data of specie into a multi-component mixture.
Defines a moethod to generate the thermodynamic data of a mixture of gasses.
- thermos
Link to database of thermodynamic properties (database.chemistry.thermo.Thermo)
- Type:
- static ThermoType() str[source]
- Abstractmethod:
The type of thermodynamic data to lookup for in the database
- thermos: libICEpost.Database._DatabaseClass
Link to database of thermodynamic data
- property mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture
The mixture composition
- _mix
- property Thermo: libICEpost.src.thermophysicalModels.specie.thermo.Thermo.Thermo
The thermodynamic data of the mixture.
- update(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture = None) bool[source]
Method to update the equation of state based on the mixture composition (interface).
- Parameters:
mix (Mixture, optional) – Change the mixture. Defaults to None.
- Returns:
If something changed
- Return type:
bool
- abstractmethod _update(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture = None) bool[source]
Method to update the equation of state based on the mixture composition (implementation).
- Parameters:
mix (Mixture, optional) – Change the mixture. Defaults to None.
- Returns:
If something changed
- Return type:
bool
- class libICEpost.src.thermophysicalModels.thermoModels.thermoMixture.mixingRules.Thermo.janaf7Mixing(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture)[source]
-
Class handling mixing of multi-component mixture: thermodynamic data in janaf7 definition.
- ThermoType
Type of thermodynamic data for which it is implemented
- Type:
str
- ThermoType = 'janaf7'
The type of thermodynamic data to lookup for in the database
- class janaf7(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture)[source]
Bases:
libICEpost.src.thermophysicalModels.specie.thermo.Thermo.janaf7.janaf7Thermodynamic data of mixture with NASA-7 polinomial coefficients consistent with janaf7 class.
- property Rgas
The mass-specific gas constant [J/kgK]
- _mix
- _combineMethod(func: str, *fargs, **fkwargs)[source]
Method for macro-ization of combination of properties based on mixture composition
- Parameters:
func (str) – the name of the method to combine
- Returns:
- Return type:
- cp(p: float, T: float) float[source]
Constant pressure heat capacity [J/kg/K]. If the temperature is not within Tlow and Thigh, and janaf7.__WARNING__ is True a warning is displayed.
cp(T) = sum_{i=0,4} ( a_{i} * T^i )
- dcpdT(p: float, T: float) float[source]
dcp/dT [J/kg/K^2] If the temperature is not within Tlow and Thigh, a warning is displayed.
dcp/dT(T) = sum_{i=1,4}(i * a_{i} * T^(i - 1))
- ha(p: float, T: float) float[source]
Absolute enthalpy [J/kg] If the temperature is not within Tlow and Thigh, a warning is displayed.
ha(T) = sum_{i=0,4} ( a_{i}/(i + 1) * T^i )*T + a_{5}
- update(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture = None) None[source]
- _Thermo
- _update(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture = None) bool[source]
No class data to be updated.
- Parameters:
mix (Mixture, optional) – Change the mixture. Defaults to None.
- Returns:
If something changed
- Return type:
bool
- class libICEpost.src.thermophysicalModels.thermoModels.thermoMixture.mixingRules.Thermo.constantCpMixing(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture)[source]
-
Class handling mixing of multi-component mixture: thermodynamic data in constantCp definition.
- ThermoType
Type of thermodynamic data for which it is implemented
- Type:
str
- ThermoType = 'constantCp'
The type of thermodynamic data to lookup for in the database
- _oldMix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture
The old mixture composition
- _Thermo
- _update(mix: libICEpost.src.thermophysicalModels.specie.specie.Mixture.Mixture = None) bool[source]
Compute new properties as mass-weighted from individual specie in mixture.
- Parameters:
mix (Mixture, optional) – Change the mixture. Defaults to None.
- Returns:
If something changed
- Return type:
bool