45 zeroField(), zeroField(),
53 forAll(phiPsiCorrs[0], facei)
60 if (phiPsiCorrs[
phasei][facei] > 0)
62 sumPos += phiPsiCorrs[
phasei][facei];
66 sumNeg += phiPsiCorrs[
phasei][facei];
70 scalar
sum = sumPos + sumNeg;
72 if (sum > 0 && sumPos > VSMALL)
74 scalar
lambda = -sumNeg/sumPos;
78 if (phiPsiCorrs[
phasei][facei] > 0)
84 else if (sum < 0 && sumNeg < -VSMALL)
86 scalar
lambda = -sumPos/sumNeg;
90 if (phiPsiCorrs[
phasei][facei] < 0)
#define forAll(list, i)
Loop across all elements in list.
dimensioned< Type > sum(const DimensionedField< Type, GeoMesh > &df)
GeometricField< scalar, fvPatchField, volMesh > volScalarField
void limitSum(UPtrList< scalarField > &phiPsiCorrs)
void explicitSolve(const RdeltaTType &rDeltaT, const RhoType &rho, volScalarField &psi, const surfaceScalarField &phiPsi, const SpType &Sp, const SuType &Su)
A templated 1D list of pointers to objects of type <T>, where the size of the array is known and used...
dimensionedScalar lambda(laminarTransport.lookup("lambda"))
MULES: Multidimensional universal limiter for explicit solution.
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
label size() const
Return the number of elements in the UPtrList.