foamPostProcess: New volAverage and volIntegrate packaged function objects

These additions mean that the volume-weighted average or volume integral
of a field can be conveniently post-processed. This can be done
interactively using foamPostProcess:

    foamPostProcess -func "volAverage(U)"
    foamPostProcess -func "volIntegrate(rho)"

Or at run-time by adding to the functions sub-section of the
controlDict:

    #includeFunc volAverage(U)
    #includeFunc volIntegrate(rho)
This commit is contained in:
Will Bainbridge
2023-04-19 14:23:56 +01:00
parent 99b36f646a
commit 5c7131288c
14 changed files with 84 additions and 20 deletions

View File

@ -267,17 +267,6 @@ lagrangianFunctions
//#includeFunc dsmcFields
}
minMaxFunctions
{
#includeFunc cellMin(epsilon)
#includeFunc cellMax(k)
#includeFunc cellMinMag(U, writeLocation=yes)
#includeFunc cellMaxMag(U, writeLocation=yes)
}
numericalFunctions
{
#includeFunc residuals(p, U, h, k, epsilon)
@ -410,6 +399,21 @@ surfaceFieldValueFunctions
)
}
volFieldValueFunctions
{
#includeFunc cellMin(epsilon)
#includeFunc cellMax(k)
#includeFunc cellMinMag(U, writeLocation=yes)
#includeFunc cellMaxMag(U, writeLocation=yes)
#includeFunc volAverage(p)
#includeFunc volIntegrate(rho)
}
functions
{
$combustionFunctions;
@ -419,7 +423,6 @@ functions
$forcesFunctions;
$graphsFunctions;
$lagrangianFunctions;
$minMaxFunctions;
$numericalFunctions;
$pressureFunctions;
$probesFunctions;
@ -427,6 +430,7 @@ functions
$streamlinesFunctions;
$surfaceFunctions;
$surfaceFieldValueFunctions;
$volFieldValueFunctions;
}
// ************************************************************************* //