示例#1
0
Foam::zeroField
Foam::fvm::Su
(
    const zero&,
    const GeometricField<Type, fvPatchField, volMesh>& vf
)
{
    return zeroField();
}
void Foam::mulesWithDiffusionImplicitLimiter
(
    const volScalarField& rho,
    volScalarField& Y,
    const surfaceScalarField& phiPos,
    const surfaceScalarField& phiNeg,
    scalarField& lambdaFace,
    surfaceScalarField& rhoPhif,
    surfaceScalarField& diffFlux,
    const surfaceScalarField& Dmi,
    const fvScalarMatrix& SuSp
)
{
    const fvMesh& mesh = rho.mesh();
    const dictionary& MULEScontrols = mesh.solverDict("Yi");

    label nLimiterIter
    (
	readLabel(MULEScontrols.lookup("nLimiterIter"))
    );
    
    upwind<scalar> UDsPos(mesh, phiPos);
    upwind<scalar> UDsNeg(mesh, phiNeg);
    
    fvScalarMatrix YConvection
    (
	fv::gaussConvectionScheme<scalar>(mesh, phiPos, UDsPos).fvmDiv(phiPos, Y)
	+
	fv::gaussConvectionScheme<scalar>(mesh, phiNeg, UDsPos).fvmDiv(phiNeg, Y)
    );
    
    surfaceScalarField rhoPhifBD = YConvection.flux();

    surfaceScalarField& rhoPhifCorr = rhoPhif;
    rhoPhifCorr -= rhoPhifBD;

    volScalarField Su
    (
	"Su",
	SuSp & Y
    );

    MULES::limiter
    (
	lambdaFace,
	1.0/mesh.time().deltaTValue(),
	rho,
	Y,
	rhoPhifBD,
	rhoPhifCorr,
	zeroField(),
	Su,
	1.0, //psiMax,
	0.0, //psiMin,
	nLimiterIter
    );
}
示例#3
0
Foam::zeroField
Foam::fvm::Sp
(
    const zeroField&,
    GeometricField<Type, fvPatchField, volMesh>&
)
{
    return zeroField();
}
示例#4
0
void Foam::MULES::LTScorrect
(
    volScalarField& psi,
    const surfaceScalarField& phi,
    surfaceScalarField& phiPsiCorr,
    const scalar psiMax,
    const scalar psiMin
)
{
    LTScorrect
    (
        geometricOneField(),
        psi,
        phi,
        phiPsiCorr,
        zeroField(), zeroField(),
        psiMax, psiMin
    );
}
示例#5
0
void Foam::MULES::implicitSolve
(
    volScalarField& psi,
    const surfaceScalarField& phi,
    surfaceScalarField& phiPsi,
    const scalar psiMax,
    const scalar psiMin
)
{
    implicitSolve
    (
        geometricOneField(),
        psi,
        phi,
        phiPsi,
        zeroField(), zeroField(),
        psiMax, psiMin
    );
}