removed modifications in chemistryModel

This commit is contained in:
ignis 2018-01-25 18:18:18 +09:00
parent ff2bbf9c44
commit 5a1d0fde23
5 changed files with 0 additions and 312 deletions

View file

@ -175,27 +175,6 @@ public:
//- Return the heat release, i.e. enthalpy/sec [m2/s3]
virtual tmp<volScalarField> dQ() const = 0;
//- Return the mass fraction of the *specieName
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volScalarField> Yspecie(const word *specieName) {}
//- Return the mass fraction of the *specieName
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volScalarField> MoleFracSpecie(const word *specieName) {}
//- Return the epsilon
virtual tmp<volScalarField> epsilon() {}
//- Return the k
virtual tmp<volScalarField> k() {}
//- Return the U field
virtual tmp<volVectorField> U() {}
//- Return the turbulent kinematic diffusivity of chemical species (Le=1 is assumed)
virtual tmp<volScalarField> nut() {}
};

View file

@ -585,249 +585,6 @@ Foam::chemistryModel<CompType, ThermoType>::Sh() const
return tSh;
}
// * * * * * * * quoted by JW 20170320 (13) * * * * * * * * * * * * //
template<class CompType, class ThermoType>
Foam::tmp<Foam::volScalarField>
Foam::chemistryModel<CompType, ThermoType>::Yspecie(const word *specieName) const
{
tmp<volScalarField> tYspecie
(
new volScalarField
(
IOobject
(
"Yspecie",
this->mesh_.time().timeName(),
this->mesh_,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->mesh_,
dimensionedScalar("zero", dimless, 0.0)
)
);
scalarField& Yspecie = tYspecie.ref();
scalar initializationchecker=0.0;
forAll(Yspecie, celli)
{
if (Yspecie[celli] !=0.0){
initializationchecker = 1.0;
}
}
if (initializationchecker != 0.0){
Info<<"mass fraction field failed to be initialized!"<<endl;
}
char SpecieIndex = dynamic_cast<const reactingMixture<ThermoType>&>(this->thermo()).species()[*specieName];
forAll(Yspecie, celli)
{
Yspecie[celli] = Y_[SpecieIndex][celli];
}
return tYspecie;
}
template<class CompType, class ThermoType>
Foam::tmp<Foam::volScalarField>
Foam::chemistryModel<CompType, ThermoType>::MoleFracSpecie(const word *specieName) const
{
tmp<volScalarField> tMoleFracSpecie
(
new volScalarField
(
IOobject
(
"MoleFracSpecie",
this->mesh_.time().timeName(),
this->mesh_,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->mesh_,
dimensionedScalar("zero", dimless, 0.0)
)
);
scalarField& MoleFracSpecie = tMoleFracSpecie.ref();
scalar initializationchecker=0.0;
forAll(MoleFracSpecie, celli)
{
if (MoleFracSpecie[celli] !=0.0){
initializationchecker = 1.0;
}
}
if (initializationchecker != 0.0){
Info<<"mole fraction field failed to be initialized!"<<endl;
}
char SpecieIndex = dynamic_cast<const reactingMixture<ThermoType>&>(this->thermo()).species()[*specieName];
forAll(MoleFracSpecie, celli)
{
scalar totMol(0.0);
for (label i=0; i<nSpecie_; i++)
{
totMol += Y_[i][celli]/specieThermo_[i].W();
}
MoleFracSpecie[celli] = (Y_[SpecieIndex][celli]/specieThermo_[SpecieIndex].W())/totMol;
}
return tMoleFracSpecie;
}
template<class CompType, class ThermoType>
Foam::tmp<Foam::volScalarField>
Foam::chemistryModel<CompType, ThermoType>::epsilon() const
{
tmp<volScalarField> tepsilon
(
new volScalarField
(
IOobject
(
"epsilon_temp",
this->mesh_.time().timeName(),
this->mesh_,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->mesh_,
dimensionedScalar("zero", dimless, 0.0)
)
);
scalarField& epsilon = tepsilon.ref();
const volScalarField& epsilon_ref = this->db().objectRegistry::lookupObject<volScalarField>("epsilon");
forAll(epsilon, celli)
{
epsilon[celli] = epsilon_ref[celli];
}
return tepsilon;
}
template<class CompType, class ThermoType>
Foam::tmp<Foam::volScalarField>
Foam::chemistryModel<CompType, ThermoType>::k() const
{
tmp<volScalarField> tk
(
new volScalarField
(
IOobject
(
"k_temp",
this->mesh_.time().timeName(),
this->mesh_,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->mesh_,
dimensionedScalar("zero", dimless, 0.0)
)
);
scalarField& k = tk.ref();
const volScalarField& k_ref = this->db().objectRegistry::lookupObject<volScalarField>("k");
forAll(k, celli)
{
k[celli] = k_ref[celli];
}
return tk;
}
// * * * * * quoted by JW 20170331(15) * * * * * * //
template<class CompType, class ThermoType>
Foam::tmp<Foam::volVectorField>
Foam::chemistryModel<CompType, ThermoType>::U() const
{
tmp<volVectorField> tU
(
new volVectorField
(
IOobject
(
"U_temp",
this->mesh_.time().timeName(),
this->mesh_,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->mesh_,
dimensionedVector("U_temp", dimLength/dimTime, vector(0.0, 0.0, 0.0))
)
);
vectorField& U = tU.ref();
const volVectorField& U_ref = this->db().objectRegistry::lookupObject<volVectorField>("U");
forAll(U, celli)
{
U[celli] = U_ref[celli];
}
return tU;
}
template<class CompType, class ThermoType>
Foam::tmp<Foam::volScalarField>
Foam::chemistryModel<CompType, ThermoType>::nut() const
{
tmp<volScalarField> tnut
(
new volScalarField
(
IOobject
(
"nut_temp",
this->mesh_.time().timeName(),
this->mesh_,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->mesh_,
dimensionedScalar("zero", pow(dimLength,2)/dimTime, 0.0)
)
);
scalarField& nut = tnut.ref();
const volScalarField& nut_ref = this->db().objectRegistry::lookupObject<volScalarField>("nut");
forAll(nut, celli)
{
nut[celli] = nut_ref[celli];
}
return tnut;
}
template<class CompType, class ThermoType>
Foam::tmp<Foam::volScalarField>

View file

@ -231,29 +231,6 @@ public:
//- Return the heat release, i.e. enthalpy/sec [kg/m2/s3]
virtual tmp<volScalarField> dQ() const;
//- Return mass fraction of *specieName
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volScalarField> Yspecie(const word *specieName) const;
//- Return mole fraction of *specieName
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volScalarField> MoleFracSpecie(const word *specieName) const;
//- Return the epsilon
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volScalarField> epsilon() const;
//- Return the turbulent kinetic energy
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volScalarField> k() const;
//- Return the velocity field
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volVectorField> U() const;
//- Return the turbulent kinematic diffusivity of chemical species (Le=1)
//- 28.Nov.2017 Jinwoo Park
virtual tmp<volScalarField> nut() const;
// ODE functions (overriding abstract functions in ODE.H)

View file

@ -111,23 +111,6 @@ namespace Foam
rhoChemistryModel,
icoPoly8EThermoPhysics
);
// Chemistry moldels based on absoluteEnthalpy
makeChemistryModel
(
chemistryModel,
rhoChemistryModel,
gasHaThermoPhysics
);
// Chemistry moldels based on absoluteInternalEnergy
makeChemistryModel
(
chemistryModel,
rhoChemistryModel,
gasEaThermoPhysics
);
}
// ************************************************************************* //

View file

@ -88,14 +88,6 @@ namespace Foam
incompressibleGasEThermoPhysics
);
makeChemistrySolverTypes(rhoChemistryModel, icoPoly8EThermoPhysics);
// Chemistry solvers based on absoluteEnthalpy
makeChemistrySolverTypes(rhoChemistryModel, gasHaThermoPhysics);
// makeChemistrySolverTypes(rhoChemistryModel, gasHaThermoPhysics);
// Chemistry solvers based on absoluteInternalEnergy
makeChemistrySolverTypes(rhoChemistryModel, gasEaThermoPhysics);
// makeChemistrySolverTypes(rhoChemistryModel, gasEaThermoPhysics);
}