alphaSuSp.H
Go to the documentation of this file.
1 volScalarField::Internal Sp
2 (
3  IOobject
4  (
5  "Sp",
6  runTime.timeName(),
7  mesh
8  ),
9  mesh,
10  dimensionedScalar("Sp", dgdt.dimensions(), 0)
11 );
12 
13 volScalarField::Internal Su
14 (
15  IOobject
16  (
17  "Su",
18  runTime.timeName(),
19  mesh
20  ),
21  mesh,
22  dimensionedScalar("Su", dgdt.dimensions(), 0)
23 );
24 
25 forAll(dgdt, celli)
26 {
27  if (dgdt[celli] > 0.0)
28  {
29  Sp[celli] -= dgdt[celli]/max(1.0 - alpha1[celli], 1e-4);
30  Su[celli] += dgdt[celli]/max(1.0 - alpha1[celli], 1e-4);
31  }
32  else if (dgdt[celli] < 0.0)
33  {
34  Sp[celli] += dgdt[celli]/max(alpha1[celli], 1e-4);
35  }
36 }
37 
38 volScalarField::Internal divU
39 (
40  mesh.moving()
41  ? fvc::div(phiCN() + mesh.phi())
42  : fvc::div(phiCN())
43 );
zeroField Su
Definition: alphaSuSp.H:1
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
engineTime & runTime
tmp< surfaceScalarField > phiCN(phi)
const dimensionedScalar e
Elementary charge.
Definition: doubleScalar.H:98
dynamicFvMesh & mesh
const volScalarField & alpha1
forAll(dgdt, celli)
Definition: alphaSuSp.H:25
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
zeroField divU
Definition: alphaSuSp.H:3
zeroField Sp
Definition: alphaSuSp.H:2