mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: combustible mixtures to be read from dictionary
This commit is contained in:
@ -50,9 +50,9 @@ Foam::dieselMixture<ThermoType>::dieselMixture
|
|||||||
|
|
||||||
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
||||||
|
|
||||||
fuel_(thermoDict.lookup("fuel")),
|
fuel_(thermoDict.subDict("fuel")),
|
||||||
oxidant_(thermoDict.lookup("oxidant")),
|
oxidant_(thermoDict.subDict("oxidant")),
|
||||||
products_(thermoDict.lookup("burntProducts")),
|
products_(thermoDict.subDict("burntProducts")),
|
||||||
|
|
||||||
mixture_("mixture", fuel_),
|
mixture_("mixture", fuel_),
|
||||||
|
|
||||||
@ -91,9 +91,9 @@ const ThermoType& Foam::dieselMixture<ThermoType>::mixture
|
|||||||
template<class ThermoType>
|
template<class ThermoType>
|
||||||
void Foam::dieselMixture<ThermoType>::read(const dictionary& thermoDict)
|
void Foam::dieselMixture<ThermoType>::read(const dictionary& thermoDict)
|
||||||
{
|
{
|
||||||
fuel_ = ThermoType(thermoDict.lookup("fuel"));
|
fuel_ = ThermoType(thermoDict.subDict("fuel"));
|
||||||
oxidant_ = ThermoType(thermoDict.lookup("oxidant"));
|
oxidant_ = ThermoType(thermoDict.subDict("oxidant"));
|
||||||
products_ = ThermoType(thermoDict.lookup("burntProducts"));
|
products_ = ThermoType(thermoDict.subDict("burntProducts"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -50,9 +50,9 @@ Foam::egrMixture<ThermoType>::egrMixture
|
|||||||
|
|
||||||
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
||||||
|
|
||||||
fuel_(thermoDict.lookup("fuel")),
|
fuel_(thermoDict.subDict("fuel")),
|
||||||
oxidant_(thermoDict.lookup("oxidant")),
|
oxidant_(thermoDict.subDict("oxidant")),
|
||||||
products_(thermoDict.lookup("burntProducts")),
|
products_(thermoDict.subDict("burntProducts")),
|
||||||
|
|
||||||
mixture_("mixture", fuel_),
|
mixture_("mixture", fuel_),
|
||||||
|
|
||||||
@ -101,9 +101,9 @@ void Foam::egrMixture<ThermoType>::read(const dictionary& thermoDict)
|
|||||||
{
|
{
|
||||||
stoicRatio_ = thermoDict.lookup("stoichiometricAirFuelMassRatio");
|
stoicRatio_ = thermoDict.lookup("stoichiometricAirFuelMassRatio");
|
||||||
|
|
||||||
fuel_ = ThermoType(thermoDict.lookup("fuel"));
|
fuel_ = ThermoType(thermoDict.subDict("fuel"));
|
||||||
oxidant_ = ThermoType(thermoDict.lookup("oxidant"));
|
oxidant_ = ThermoType(thermoDict.subDict("oxidant"));
|
||||||
products_ = ThermoType(thermoDict.lookup("burntProducts"));
|
products_ = ThermoType(thermoDict.subDict("burntProducts"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -84,8 +84,8 @@ const ThermoType& Foam::homogeneousMixture<ThermoType>::mixture
|
|||||||
template<class ThermoType>
|
template<class ThermoType>
|
||||||
void Foam::homogeneousMixture<ThermoType>::read(const dictionary& thermoDict)
|
void Foam::homogeneousMixture<ThermoType>::read(const dictionary& thermoDict)
|
||||||
{
|
{
|
||||||
reactants_ = ThermoType(thermoDict.lookup("reactants"));
|
reactants_ = ThermoType(thermoDict.subDict("reactants"));
|
||||||
products_ = ThermoType(thermoDict.lookup("products"));
|
products_ = ThermoType(thermoDict.subDict("products"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -51,9 +51,9 @@ Foam::inhomogeneousMixture<ThermoType>::inhomogeneousMixture
|
|||||||
|
|
||||||
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
||||||
|
|
||||||
fuel_(thermoDict.lookup("fuel")),
|
fuel_(thermoDict.subDict("fuel")),
|
||||||
oxidant_(thermoDict.lookup("oxidant")),
|
oxidant_(thermoDict.subDict("oxidant")),
|
||||||
products_(thermoDict.lookup("burntProducts")),
|
products_(thermoDict.subDict("burntProducts")),
|
||||||
|
|
||||||
mixture_("mixture", fuel_),
|
mixture_("mixture", fuel_),
|
||||||
|
|
||||||
@ -95,9 +95,9 @@ void Foam::inhomogeneousMixture<ThermoType>::read(const dictionary& thermoDict)
|
|||||||
{
|
{
|
||||||
stoicRatio_ = thermoDict.lookup("stoichiometricAirFuelMassRatio");
|
stoicRatio_ = thermoDict.lookup("stoichiometricAirFuelMassRatio");
|
||||||
|
|
||||||
fuel_ = ThermoType(thermoDict.lookup("fuel"));
|
fuel_ = ThermoType(thermoDict.subDict("fuel"));
|
||||||
oxidant_ = ThermoType(thermoDict.lookup("oxidant"));
|
oxidant_ = ThermoType(thermoDict.subDict("oxidant"));
|
||||||
products_ = ThermoType(thermoDict.lookup("burntProducts"));
|
products_ = ThermoType(thermoDict.subDict("burntProducts"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -38,7 +38,7 @@ const ThermoType& Foam::multiComponentMixture<ThermoType>::constructSpeciesData
|
|||||||
speciesData_.set
|
speciesData_.set
|
||||||
(
|
(
|
||||||
i,
|
i,
|
||||||
new ThermoType(thermoDict.lookup(species_[i]))
|
new ThermoType(thermoDict.subDict(species_[i]))
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -155,7 +155,7 @@ void Foam::multiComponentMixture<ThermoType>::read
|
|||||||
{
|
{
|
||||||
forAll(species_, i)
|
forAll(species_, i)
|
||||||
{
|
{
|
||||||
speciesData_[i] = ThermoType(thermoDict.lookup(species_[i]));
|
speciesData_[i] = ThermoType(thermoDict.subDict(species_[i]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -51,9 +51,9 @@ Foam::veryInhomogeneousMixture<ThermoType>::veryInhomogeneousMixture
|
|||||||
|
|
||||||
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
stoicRatio_(thermoDict.lookup("stoichiometricAirFuelMassRatio")),
|
||||||
|
|
||||||
fuel_(thermoDict.lookup("fuel")),
|
fuel_(thermoDict.subDict("fuel")),
|
||||||
oxidant_(thermoDict.lookup("oxidant")),
|
oxidant_(thermoDict.subDict("oxidant")),
|
||||||
products_(thermoDict.lookup("burntProducts")),
|
products_(thermoDict.subDict("burntProducts")),
|
||||||
|
|
||||||
mixture_("mixture", fuel_),
|
mixture_("mixture", fuel_),
|
||||||
|
|
||||||
@ -96,9 +96,9 @@ void Foam::veryInhomogeneousMixture<ThermoType>::read
|
|||||||
const dictionary& thermoDict
|
const dictionary& thermoDict
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
fuel_ = ThermoType(thermoDict.lookup("fuel"));
|
fuel_ = ThermoType(thermoDict.subDict("fuel"));
|
||||||
oxidant_ = ThermoType(thermoDict.lookup("oxidant"));
|
oxidant_ = ThermoType(thermoDict.subDict("oxidant"));
|
||||||
products_ = ThermoType(thermoDict.lookup("burntProducts"));
|
products_ = ThermoType(thermoDict.subDict("burntProducts"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user