/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.2.0                                   |
|   \\  /    A nd           | Web:      http://www.OpenFOAM.org               |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      controlDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

application     simpleFoam; //simpleFoam, turbFoam, vmsFoam, etc;

startFrom       latestTime;

startTime       latestTime;

stopAt          endTime;

endTime         1000;

deltaT          1.0;

writeControl    timeStep;

writeInterval   $nIterations$;

purgeWrite      1;

writeFormat     ascii;

writePrecision  10;

writeCompression uncompressed;

timeFormat      general;

timePrecision   10;

runTimeModifiable yes;
libs ("$lib$")
functions
(
/*
    Surface-0
/*    {
    type faceSource;//patchAverage; //patchAverage, patchFieldFlow, patchIntegrate
    functionObjectLibs ("libFieldFunctionObjects.so");
    outputControl timeStep;
    outputInterval 1;
    verbose true;
log yes;
source faceZone;
sourceName mixer_1;
operation weightedAverage;    
fields
        (
                U
        );
   // patches
   // (
   //     pressure_outlet.8
   // );
   // factor 1.1614;
    }*/
{
        type            faceSource;
        functionObjectLibs ("libfieldFunctionObjects.so");
        enabled         yes;
        outputControl   timeStep;//outputTime;
outputInterval 1;
        log             yes;
        valueOutput     no;
        source          sampledSurface;//faceZone;
               
        sampledSurfaceDict
        {
            // Sampling on triSurface
            type        sampledTriSurfaceMesh;
            surface     disc2.stl;
            source      cells;  // sample cells or boundaryFaces
            interpolate true;
        }

        // Operation: areaAverage/sum/weightedAverage ...
//sourceName      maxX2minX0MasterZone;
        operation       areaAverage;//weightedAverage;
        //weightField     phi;
autoInterpolate true;        
fields
        (
            
          U
p
        );
    }
*/
);


// ************************************************************************* //
