2 word alphaScheme(
"div(phi,alpha)");
8 tmp<fv::ddtScheme<scalar>> tddtAlpha
13 mesh.ddtScheme(
"ddt(alpha)")
16 const fv::ddtScheme<scalar>& ddtAlpha = tddtAlpha();
20 isType<fv::EulerDdtScheme<scalar>>(ddtAlpha)
21 ||
isType<fv::localEulerDdtScheme<scalar>>(ddtAlpha)
26 else if (
isType<fv::CrankNicolsonDdtScheme<scalar>>(ddtAlpha))
31 <<
"Sub-cycling is not supported " 32 "with the CrankNicolson ddt scheme" 39 ||
mesh.time().timeIndex() >
mesh.time().startTimeIndex() + 1
43 refCast<const fv::CrankNicolsonDdtScheme<scalar>>(
ddtAlpha)
50 <<
"Only Euler and CrankNicolson ddt schemes are supported" 76 surfaceScalarField::Boundary& phicBf =
77 phic.boundaryFieldRef();
101 #include "alphaSuSp.H" 107 ? fv::localEulerDdtScheme<scalar>(
mesh).fvmDdt(
alpha1)
108 : fv::EulerDdtScheme<scalar>(
mesh).fvmDdt(
alpha1)
110 + fv::gaussConvectionScheme<scalar>
114 upwind<scalar>(
mesh, phiCN)
124 Info<<
"Phase-1 volume fraction = " 130 tmp<surfaceScalarField> talphaPhi1UD(alpha1Eqn.flux());
135 Info<<
"Applying the previous iteration compression flux" <<
endl;
160 #include "alphaSuSp.H" 164 tmp<surfaceScalarField> talphaPhi1Un
182 tmp<surfaceScalarField> talphaPhi1Corr(talphaPhi1Un() -
alphaPhi10);
190 talphaPhi1Corr.ref(),
204 alpha1 = 0.5*alpha1 + 0.5*
alpha10;
233 talphaPhi1Corr0.ref().rename(
"alphaPhi1Corr0");
244 word(
mesh.ddtScheme(
"ddt(rho,U)"))
245 == fv::EulerDdtScheme<vector>::typeName
246 || word(
mesh.ddtScheme(
"ddt(rho,U)"))
247 == fv::localEulerDdtScheme<vector>::typeName
265 Info<<
"Phase-1 volume fraction = " forAll(phic.boundaryField(), patchi)
fvsPatchField< scalar > fvsPatchScalarField
tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh >> grad(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
fvMatrix< scalar > fvScalarMatrix
errorManipArg< error, int > exit(error &err, const int errNo=1)
surfaceScalarField rho1f(fvc::interpolate(rho1))
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
word alpharScheme("div(phirb,alpha)")
Ostream & endl(Ostream &os)
Add newline and flush stream.
const fv::ddtScheme< scalar > & ddtAlpha
surfaceScalarField alphaPhi10(alphaPhi10Header, phi *fvc::interpolate(alpha1))
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh >> &tdf1, const word &name, const dimensionSet &dimensions)
GeometricField< scalar, fvPatchField, volMesh > volScalarField
tmp< surfaceScalarField > phiCN(phi)
surfaceScalarField rho2f(fvc::interpolate(rho2))
volScalarField alpha10("alpha10", alpha1)
bool isType(const Type &t)
Check the typeid.
const volScalarField & alpha1
Info<< "Predicted p max-min : "<< max(p).value()<< " "<< min(p).value()<< endl;rho==max(psi *p+alphal *rhol0+((alphav *psiv+alphal *psil) - psi) *pSat, rhoMin);# 1 "/home/ubuntu/OpenFOAM-6/applications/solvers/multiphase/cavitatingFoam/alphavPsi.H" 1{ alphav=max(min((rho - rholSat)/(rhovSat - rholSat), scalar(1)), scalar(0));alphal=1.0 - alphav;Info<< "max-min alphav: "<< max(alphav).value()<< " "<< min(alphav).value()<< endl;psiModel-> correct()
Info<< "Reading field p_rgh\"<< endl;volScalarField p_rgh(IOobject("p_rgh", runTime.timeName(), mesh, IOobject::MUST_READ, IOobject::AUTO_WRITE), mesh);Info<< "Reading field U\"<< endl;volVectorField U(IOobject("U", runTime.timeName(), mesh, IOobject::MUST_READ, IOobject::AUTO_WRITE), mesh);Info<< "Creating phaseChangeTwoPhaseMixture\"<< endl;autoPtr< phaseChangeTwoPhaseMixture > mixture
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
static tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate(const GeometricField< Type, fvPatchField, volMesh > &tvf, const surfaceScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
surfaceScalarField phic(mixture.cAlpha() *mag(phi/mesh.magSf()))
dimensionedSymmTensor symm(const dimensionedSymmTensor &dt)
surfaceScalarField phir(IOobject("phir", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::NO_WRITE), mixture.cAlpha() *mag(phi/mesh.magSf()) *mixture.nHatf())
dimensioned< scalar > mag(const dimensioned< Type > &)
tmp< surfaceScalarField > flux(const volVectorField &vvf)
Return the face-flux field obtained from the given volVectorField.
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
void explicitSolve(const RdeltaTType &rDeltaT, const RhoType &rho, volScalarField &psi, const surfaceScalarField &phiPsi, const SpType &Sp, const SuType &Su)
tmp< surfaceScalarField > talphaPhi1Corr0