EEqns.H
Go to the documentation of this file.
1 for (int Ecorr=0; Ecorr<nEnergyCorrectors; Ecorr++)
2 {
3  fluid.correctEnergyTransport();
4 
5  autoPtr<phaseSystem::heatTransferTable>
6  heatTransferPtr(fluid.heatTransfer());
7 
8  phaseSystem::heatTransferTable& heatTransfer = heatTransferPtr();
9 
10  forAll(fluid.anisothermalPhases(), anisothermalPhasei)
11  {
12  phaseModel& phase = fluid.anisothermalPhases()[anisothermalPhasei];
13 
14  const volScalarField& alpha = phase;
15  tmp<volScalarField> tRho = phase.rho();
16  const volScalarField& rho = tRho();
17  tmp<volVectorField> tU = phase.U();
18  const volVectorField& U = tU();
19 
21  (
22  phase.heEqn()
23  ==
24  *heatTransfer[phase.name()]
25  + alpha*rho*(U&g)
26  + fvOptions(alpha, rho, phase.thermoRef().he())
27  );
28 
29  EEqn.relax();
30  fvOptions.constrain(EEqn);
31  EEqn.solve();
32  fvOptions.correct(phase.thermoRef().he());
33  }
34 
35  fluid.correctThermo();
36  fluid.correctContinuityError();
37 }
38 
39 
41 {
42  phaseModel& phase = phases[phasei];
43 
44  Info<< phase.name() << " min/max T "
45  << min(phase.thermo().T()).value()
46  << " - "
47  << max(phase.thermo().T()).value()
48  << endl;
49 }
fvMatrix< scalar > fvScalarMatrix
Definition: fvMatricesFwd.H:42
fv::options & fvOptions
label phasei
Definition: pEqn.H:27
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:251
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:58
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:57
forAll(phases, phasei)
Definition: EEqns.H:40
phaseSystem & fluid
Definition: createFields.H:11
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
U
Definition: pEqn.H:72
phaseSystem::phaseModelList & phases
Definition: createFields.H:12
messageStream Info
volScalarField alpha(IOobject("alpha", runTime.timeName(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
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)==combustion->Qdot()+radiation->Sh(thermo, he)+parcels.Sh(he)+surfaceFilm.Sh()+fvOptions(rho, he))
const dimensionedVector & g