CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Post-Processing

How to use the output of a function object as an input to another one?

Register Blogs Members List Search Today's Posts Mark Forums Read

LinkBack Thread Tools Search this Thread Display Modes
Old   September 17, 2020, 01:03
Default How to use the output of a function object as an input to another one?
Senior Member
Ali Shayegh
Join Date: Oct 2015
Posts: 122
Rep Power: 7
amuzeshi is on a distinguished road
I want to use an average pressure at a section as a reference pressure for pressure coefficient calculation. I have included the following function objects in my controlDict for pressure averaging and calculation of Cp:
            type            surfaceFieldValue;
            libs            (fieldFunctionObjects);
            enabled         true;

            writeControl    onEnd;
            executeControl  onEnd;
            writeFields     true;
            result          pRef;
            surfaceFormat   none;
            regionType      sampledSurface;
            name            sampledP;
                type            cuttingPlane;
                planeType       pointAndNormal;
                    point     (-1.7 0 0.4);
                    normal    (1 0 0);
                interpolate     true;
            operation       areaAverage;
            fields          ( p );

            type            pressure;
            libs            (fieldFunctionObjects);
            executeControl      onEnd;
            writeControl        onEnd;
            result              Cp;
            mode            staticCoeff;

            rho             rhoInf;
            rhoInf          1.0; 
            pInf              0;
            U               UInf;
            UInf            (1 0 0);

Now I don't no how to use the calculated average pressure as a reference pressure for Cp (shown in red).

amuzeshi is offline   Reply With Quote


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
[Other] refineWallLayer Error Yuby OpenFOAM Meshing & Mesh Conversion 1 May 19, 2017 10:13
[blockMesh] Errors during blockMesh meshing Madeleine P. Vincent OpenFOAM Meshing & Mesh Conversion 51 May 30, 2016 10:51
[snappyHexMesh] How to define to right point for locationInMesh Mirage12 OpenFOAM Meshing & Mesh Conversion 7 March 13, 2016 14:07
Problem with compile the setParabolicInlet ivanyao OpenFOAM Running, Solving & CFD 6 September 5, 2008 20:50
Droplet Evaporation Christian Main CFD Forum 2 February 27, 2007 06:27

All times are GMT -4. The time now is 20:48.