Files
OpenFOAM-12/etc/caseDicts/postProcessing/surfaceFieldValue/faceZoneAverage
Henry Weller 84a1266706 faceZoneAverage: New functionObject configuration to average fields over a faceZone
e.g. given a vol pressure field p

functions
{
    // Interpolate the pressure field to the faces
    surfacep
    {
        type        surfaceInterpolate;
        libs        ("libfieldFunctionObjects.so");
        fields      ((p surfacep));
        writeControl none;
    }

    // Average the surface pressure field over the centre faceZone
    #includeFunc faceZoneAverage(name=centre, surfacep)
    .
    .
    .
}
2019-08-21 11:57:16 +01:00

20 lines
781 B
C++

/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: dev
\\/ M anipulation |
-------------------------------------------------------------------------------
Description
Calculates the average value of one or more fields on a faceZone.
\*---------------------------------------------------------------------------*/
name <faceZoneName>;
fields (<field_names>);
operation areaAverage;
#includeEtc "caseDicts/postProcessing/surfaceFieldValue/faceZone.cfg"
// ************************************************************************* //