solveSolid.H
Go to the documentation of this file.
1 if (finalIter)
2 {
3  mesh.data::add("finalIteration", true);
4 }
5 
6 {
7  for (int nonOrth=0; nonOrth<=nNonOrthCorr; ++nonOrth)
8  {
9  fvScalarMatrix hEqn
10  (
12  - (
13  thermo.isotropic()
14  ? fvm::laplacian(betav*thermo.alpha(), h, "laplacian(alpha,h)")
15  : fvm::laplacian(betav*taniAlpha(), h, "laplacian(alpha,h)")
16  )
17  ==
18  fvOptions(rho, h)
19  );
20 
21  hEqn.relax();
22 
23  fvOptions.constrain(hEqn);
24 
25  hEqn.solve(mesh.solver(h.select(finalIter)));
26 
27  fvOptions.correct(h);
28  }
29 
30  thermo.correct();
31 
32  Info<< "Min/max T:" << min(thermo.T()).value() << ' '
33  << max(thermo.T()).value() << endl;
34 }
35 
36 if (finalIter)
37 {
38  mesh.data::remove("finalIteration");
39 }
thermo
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
Foam::endl
Ostream & endl(Ostream &os)
Definition: Ostream.H:381
Foam::min
label min(const labelHashSet &set, label minValue=labelMax)
Definition: hashSets.C:26
Foam::fvScalarMatrix
fvMatrix< scalar > fvScalarMatrix
Definition: fvMatricesFwd.H:38
fvOptions
fv::options & fvOptions
Definition: setRegionFluidFields.H:23
Foam::constant::universal::h
const dimensionedScalar h
Definition: setRegionSolidFields.H:33
Foam::Info
messageStream Info
rho
rho
Definition: readInitialConditions.H:88
Foam::max
label max(const labelHashSet &set, label maxValue=labelMin)
Definition: hashSets.C:40
mesh
dynamicFvMesh & mesh
Definition: createDynamicFvMesh.H:6
nNonOrthCorr
const int nNonOrthCorr
Definition: readFluidMultiRegionSIMPLEControls.H:3
betav
const volScalarField & betav
Definition: setRegionSolidFields.H:35
Foam::fac::ddt
tmp< GeometricField< Type, faPatchField, areaMesh > > ddt(const dimensioned< Type > dt, const faMesh &mesh)
Definition: facDdt.C:40
Foam::fac::laplacian
tmp< GeometricField< Type, faPatchField, areaMesh > > laplacian(const GeometricField< Type, faPatchField, areaMesh > &vf, const word &name)
Definition: facLaplacian.C:40
taniAlpha
tmp< volSymmTensorField > taniAlpha
Definition: setRegionSolidFields.H:10