ENH: Adding additional entry to stabilizationSchemes.

Correcting tutorial and expanding documentation
This commit is contained in:
sergio
2018-06-19 11:21:56 -07:00
parent 02f97872ca
commit a3a6768608
4 changed files with 36 additions and 9 deletions

View File

@ -61,6 +61,7 @@ void Foam::functionObjects::stabilityBlendingFactor::writeFileHeader
os << endl;
}
bool Foam::functionObjects::stabilityBlendingFactor::calc()
{
init(false);
@ -511,6 +512,7 @@ Foam::functionObjects::stabilityBlendingFactor::stabilityBlendingFactor
{
FatalErrorInFunction
<< " Field : " << nonOrthogonalityName_ << " not found."
<< " The function object will no be used"
<< exit(FatalError);
}
}
@ -542,6 +544,7 @@ Foam::functionObjects::stabilityBlendingFactor::stabilityBlendingFactor
{
FatalErrorInFunction
<< " Field : " << faceWeightName_ << " not found."
<< " The function object will no be used"
<< exit(FatalError);
}
}
@ -572,6 +575,7 @@ Foam::functionObjects::stabilityBlendingFactor::stabilityBlendingFactor
{
FatalErrorInFunction
<< " Field : " << skewnessName_ << " not found."
<< " The function object will no be used"
<< exit(FatalError);
}
}
@ -582,11 +586,14 @@ Foam::functionObjects::stabilityBlendingFactor::stabilityBlendingFactor
indicator_.writeOpt() = IOobject::AUTO_WRITE;
}
init(true);
if (writeToFile_)
{
writeFileHeader(file());
}
init(true);
}
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
@ -714,6 +721,9 @@ bool Foam::functionObjects::stabilityBlendingFactor::write()
<< " blended cells : " << nCellsBlended << nl
<< endl;
if (writeToFile_)
{
writeTime(file());
file()
@ -721,6 +731,7 @@ bool Foam::functionObjects::stabilityBlendingFactor::write()
<< tab << nCellsScheme2
<< tab << nCellsBlended
<< endl;
}
return true;
}

View File

@ -174,7 +174,10 @@ Usage
{
type stabilityBlendingFactor;
libs ("libfieldFunctionObjects.so");
log true;
writeToFile false;
switchNonOrtho yes;
switchGradCc no;
switchResiduals yes;
@ -218,6 +221,7 @@ Usage
type residuals;
libs ("libutilityFunctionObjects.so");
writeFields true;
writeControl outputTime;
fields (p);
}
@ -228,8 +232,9 @@ Usage
Property | Description | Required | Default value
type | Type name: stabilityBlendingFactor | yes |
log | Log to standard output | no | yes
writeToFile | Log to file | no | yes
switchNonOrtho | non-orthogonal method | no | false
switchGradCc | cell centre gradient method | no | false
switchResiduals | residual evolution method | no | false
@ -274,6 +279,13 @@ Usage
\endtable
The 'log' flag true write the number of cells on each scheme, plus it
writes the field name "blendedIndicator".
The 'result' entry is the field which is read by the localBlended scheme
specified in fvSchemes. This name is determined by the localBlended class.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject

View File

@ -22,6 +22,7 @@ restore0Dir -processor
runParallel renumberMesh -overwrite
runParallel potentialFoam -initialiseUBCs
runParallel checkMesh -writeFields '(nonOrthoAngle)' -constant
runParallel $(getApplication)
#------------------------------------------------------------------------------

View File

@ -20,6 +20,9 @@ blendingFactor
type stabilityBlendingFactor;
libs ("libfieldFunctionObjects.so");
log true;
writeToFile false;
switchNonOrtho yes;
switchGradCc no;
switchResiduals yes;