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