alphaEqnSubCycle.H
Go to the documentation of this file.
1 #include "alphaControls.H"
2 
4 {
5  dimensionedScalar totalDeltaT = runTime.deltaT();
6  surfaceScalarField rhoPhiSum
7  (
8  IOobject
9  (
10  "rhoPhiSum",
11  runTime.timeName(),
12  mesh
13  ),
14  mesh,
15  dimensionedScalar(rhoPhi.dimensions(), 0)
16  );
17 
18  for
19  (
20  subCycle<volScalarField> alphaSubCycle(alpha1, nAlphaSubCycles);
21  !(++alphaSubCycle).end();
22  )
23  {
24  #include "alphaEqn.H"
25  rhoPhiSum += (runTime.deltaT()/totalDeltaT)*rhoPhi;
26  }
27 
28  rhoPhi = rhoPhiSum;
29 }
30 else
31 {
32  #include "alphaEqn.H"
33 }
34 
35 {
36  volScalarField rhoNew(alpha1*rho1 + alpha2*rho2 + alpha3*rho3);
37 
38  // solve(fvm::ddt(rho) + fvc::div(rhoPhi));
39  // Info<< "density error = "
40  // << max((mag(rho - rhoNew)/mag(rhoNew))().primitiveField()) << endl;
41 
42  rho == rhoNew;
43 }
const volScalarField & rho1
volScalarField & alpha1(mixture.alpha1())
fvMesh & mesh
alpha2
Definition: alphaEqn.H:115
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:58
const label nAlphaSubCycles(alphaControls.lookup< label >("nAlphaSubCycles"))
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
const volScalarField & rho2
rhoPhi
Definition: rhoEqn.H:10
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField