EEqn.H
Go to the documentation of this file.
1 {
2  volScalarField& he = thermo.he();
3 
5  (
6  mvConvection->fvmDiv(phi, he)
7  + (
8  he.name() == "e"
9  ? fvc::div(phi, volScalarField("Ekp", 0.5*magSqr(U) + p/rho))
10  : fvc::div(phi, volScalarField("K", 0.5*magSqr(U)))
11  )
12  + thermophysicalTransport->divq(he)
13  ==
14  rho*(U&g)
15  + parcels.Sh(he)
16  + radiation->Sh(thermo, he)
17  + combustion->Qdot()
18  + fvOptions(rho, he)
19  );
20 
21  EEqn.relax();
22 
23  fvOptions.constrain(EEqn);
24 
25  EEqn.solve();
26 
27  fvOptions.correct(he);
28  thermo.correct();
29  radiation->correct();
30 
31  Info<< "T gas min/max = " << min(T).value() << ", "
32  << max(T).value() << endl;
33 }
fvMatrix< scalar > fvScalarMatrix
Definition: fvMatricesFwd.H:42
fv::options & fvOptions
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
tmp< GeometricField< Type, fvPatchField, volMesh > > div(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
Definition: fvcDiv.C:47
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:251
rhoReactionThermo & thermo
Definition: createFields.H:28
scalar Qdot
Definition: solveChemistry.H:2
phi
Definition: pEqn.H:104
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:57
rhoReactionThermophysicalTransportModel & thermophysicalTransport
dimensioned< scalar > magSqr(const dimensioned< Type > &)
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
const volScalarField & T
Info<< "Creating combustion model\"<< endl;autoPtr< CombustionModel< psiReactionThermo > > combustion(CombustionModel< psiReactionThermo >::New(thermo, turbulence()))
U
Definition: pEqn.H:72
tmp< fv::convectionScheme< scalar > > mvConvection(fv::convectionScheme< scalar >::New(mesh, fields, phi, mesh.divScheme("div(phi,Yi_h)")))
autoPtr< radiationModel > radiation(radiationModel::New(T))
messageStream Info
volScalarField & p
const dimensionedVector & g
fvScalarMatrix EEqn(fvm::ddt(rho, he)+mvConvection->fvmDiv(phi, he)+fvc::ddt(rho, K)+fvc::div(phi, K)+(he.name()=="e" ? fvc::div(fvc::absolute(phi/fvc::interpolate(rho), U), p, "div(phiv,p)") :-dpdt)+thermophysicalTransport->divq(he)==reaction->Qdot()+fvOptions(rho, he))