CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   how to set functions about Cd and Cl (http://www.cfd-online.com/Forums/openfoam/120116-how-set-functions-about-cd-cl.html)

xiaof July 1, 2013 05:42

how to set functions about Cd and Cl
 
1 Attachment(s)
Hello everyone
I am simulating flow past a square cylinder problem.I have attached the model here.The flow is along z axis.The square cylinder axis is parallel to the y-axis.The width and the height of the square cylinder is 0.1 and 0.3.
I have tried to set the file accorrding http://openfoamwiki.net/index.php/Be...coftac_ufr2-02but the result looks not good.

Code:

functions
{
   

    forces
    {
        type        forceCoeffs;
        functionObjectLibs ( "libforces.so" );
        outputControl timeStep;
        outputInterval 1;
        patches
        (
            INWALL
        );
                directForceDensity no;

        pName      p;
        UName      U;
        rhoName    rhoInf;
        //log        true;
        rhoInf      1;
        CofR        ( 0 0 0 );
      liftDir    ( 1 0 0 );    //x direction
        dragDir    ( 0 0 1 );    //z direction
        pitchAxis  ( 0 0 0 );
        magUInf    2;        //z direction
        lRef        0.1;
        Aref        0.03;    //
        Aref1        0.01;  //?

        rhoRef      1;
    }

 
}

I am not sure about the red lines.

Thank you very much!

regards


JM


All times are GMT -4. The time now is 03:57.