CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Running, Solving & CFD

strange behavior in interPhaseChangeFoam

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

Reply
 
LinkBack Thread Tools Display Modes
Old   June 15, 2015, 10:23
Default strange behavior in interPhaseChangeFoam
  #1
Senior Member
 
Huang Xianbei
Join Date: Sep 2013
Location: CAU,China
Posts: 277
Rep Power: 6
huangxianbei is on a distinguished road
Hi,all:
I'm doing a cavitation simulation around the hydrofoil recently with interPhaseChangeFoam. However, I found quite strange results from this solver.

Description of my model: A hydrofoil fixed in a channel , the free stream velocity (inlet velocity is U = 5.33m/s), the cavitation number is defined as : a = (p_out - p_sat)/(0.5*rho*U^2)=1.25, as in interPhaseChangeFoam, the reference pressure is set to 0 Pa by default, the pressure in the calculation is the absolute pressure. Therefore, p_out = 20055.6 Pa according to the definition of the cavitation number.

The mesh used is about 20000 elements, with yPlus ranging from 37 to 267, which is suitable to use the wall function.

First of all, I ran a case (3D, 0.5 million cells) in simpleFoam to see the pressure distribution under noncavitating condition, here is the comparison with experiment.

The result is in acceptable agreement with exp
huangxianbei is offline   Reply With Quote

Old   June 15, 2015, 10:29
Default
  #2
Senior Member
 
Huang Xianbei
Join Date: Sep 2013
Location: CAU,China
Posts: 277
Rep Power: 6
huangxianbei is on a distinguished road
As 3D simulation is time consuming, I study 2D case in interPhaseChangeFoam.

Still, I'd like to see if the noncavitating case agrees with the exp. So I set the following boundary conditionsthe estimation of k and epsilon can be found http://openfoamwiki.net/index.php/TurboECPGgi2D and http://support.esi-cfd.com/esi-users/turb_parameters/)

alpha1:
Code:
INLET
    {
        type            fixedValue;
        value           $internalField;
    }

    OUTLET
    {
        type            inletOutlet;
        inletValue      $internalField;
    }

   UPWALL
    {
        type            zeroGradient;
    }

    BOTTOMWALL
    {
        type            zeroGradient;
    }
    
    PART_1
    {
        type            zeroGradient;
    }
    
     frontAndBackPlanes
    {
        type            empty;
        
    }
epsilon:
Code:
INLET
    {
        type            fixedValue;
        value           $internalField;
    }

    OUTLET
    {
        type            inletOutlet;
        inletValue      $internalField;
    }

    UPWALL
    {
        type            epsilonWallFunction;
        value           $internalField;
    }

    BOTTOMWALL
    {
        type            epsilonWallFunction;
        value           $internalField;
    }

    PART_1
    {
        type            epsilonWallFunction;
        value           $internalField;
    }

     frontAndBackPlanes
    {
        type            empty;
        
    }
k:
Code:
INLET
    {
        type            fixedValue;
        value           $internalField;
    }

    OUTLET
    {
        type            inletOutlet;
        inletValue      $internalField;
    }

    UPWALL
    {
        type            kqRWallFunction;
        value           $internalField;
    }

    BOTTOMWALL
    {
        type            kqRWallFunction;
        value           $internalField;
    }

    PART_1
    {
        type            kqRWallFunction;
        value           $internalField;
    }

     frontAndBackPlanes
    {
        type            empty;
        
    }
nut:
Code:
    INLET
    {
        type            calculated;
        value           uniform 0;
    }

    OUTLET
    {
        type            calculated;
        value           uniform 0;
    }

    UPWALL
    {
        type            nutkWallFunction;
        value           uniform 0;
    }

    BOTTOMWALL
    {
        type            nutkWallFunction;
        value           uniform 0;
    }

    PART_1
    {
        type            nutkWallFunction;
        value           uniform 0;
    }

     frontAndBackPlanes
    {
        type            empty;
        
    }
p_rgh
Code:
INLET
    {
        type            zeroGradient;
    }

    OUTLET
    {
        type            fixedValue;
        value           $internalField;
    }

    UPWALL
    {
        type            buoyantPressure;
    }

    BOTTOMWALL
    {
        type            buoyantPressure;
    }

    PART_1
    {
        type            buoyantPressure;
    }

     frontAndBackPlanes
    {
        type            empty;
        
    }
U
Code:
INLET
    {
        type            fixedValue;
        value           $internalField;
    }

    OUTLET
    {
        type            pressureInletOutletVelocity;
        phi             phi;
        value           $internalField;
    }

    

    PART_1
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }

    UPWALL
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }

    BOTTOMWALL
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
     frontAndBackPlanes
    {
        type            empty;
        
    }
huangxianbei is offline   Reply With Quote

Old   June 15, 2015, 10:37
Default
  #3
Senior Member
 
Huang Xianbei
Join Date: Sep 2013
Location: CAU,China
Posts: 277
Rep Power: 6
huangxianbei is on a distinguished road
the transportProperties:
Code:
phaseChange on;
//transportModel Newtonian;
//nu nu [0 2 -1 0 0 0 0] 1e-6;
phaseChangeTwoPhaseMixture SchnerrSauer;

pSat             pSat       [1 -1 -2 0 0]    2300;   // saturation pressure

sigma           sigma [1 0 -2 0 0 0 0] 0.07;

phase1
{
    transportModel Newtonian;
    nu              nu [0 2 -1 0 0 0 0] 1e-6;
    rho             rho [1 -3 0 0 0 0 0] 1000;
}

phase2
{
    transportModel Newtonian;
    nu              nu [0 2 -1 0 0 0 0] 4.273e-04;
    rho             rho [1 -3 0 0 0 0 0] 0.02308;
}
SchnerrSauerCoeffs
{
    n               n      [0 -3 0 0 0 0 0]     1.6e+13;
    dNuc            dNuc   [0 1 0 0 0 0 0]      2.0e-06;
    Cc              Cc     [0 0 0 0 0 0 0]      1;
    Cv              Cv     [0 0 0 0 0 0 0]      1;
}
fvSchemes:
Code:
ddtSchemes
{
    default              Euler;
}

interpolationSchemes
{
    default              linear;
}

divSchemes
{
    default              none;
    div(rhoPhi,U)        Gauss linearUpwind grad(U);
    div(phi,epsilon)       Gauss linearUpwind grad(epsilon);
    div(phi,k)           Gauss linearUpwind grad(k);

    div(phi,alpha)       Gauss vanLeer;
    div(phirb,alpha)     Gauss interfaceCompression;
}

gradSchemes
{
    default              Gauss linear;
}

laplacianSchemes
{
    default              Gauss linear limited 0.5;
}

snGradSchemes
{
    default              none;
    snGrad(pd)           limited 0.5;
    snGrad(rho)          limited 0.5;
    snGrad(alpha1)       limited 0.5;
}

fluxRequired
{
    default              none;
    p_rgh;
    pcorr;
    alpha1;
}
fvSolution
Code:
solvers
{
    alpha1
    {
        maxUnboundedness 1e-5;
        CoCoeff          2;
        maxIter          5;
        nLimiterIter     2;

        solver           PBiCG;
        preconditioner   DILU;
        tolerance        1e-12;
        relTol           0.1;
    };

    "(U|k|epsilon)"
    {
        solver          PBiCG;
        preconditioner  DILU;
        tolerance       1e-06;
        relTol          0.1;
    }

    "(U|k|epsilon)Final"
    {
        solver          PBiCG;
        preconditioner  DILU;
        tolerance       1e-06;
        relTol          0;
    }

    p_rgh
    {
        solver           GAMG;
        tolerance        1e-8;
        relTol           0.1;

        smoother         DICGaussSeidel;
        nPreSweeps       0;
        nPostSweeps      2;

        cacheAgglomeration true;

        nCellsInCoarsestLevel 10;
        agglomerator     faceAreaPair;
        mergeLevels      1;

        maxIter          50;
    };

    pcorr
    {
        $p_rgh;
        relTol           0;
    };

    p_rghFinal
    {
        solver            PCG;
        preconditioner
        {
            preconditioner  GAMG;

            tolerance        1e-6;
            relTol           0;

            nVcycles         2;

            smoother         DICGaussSeidel;
            nPreSweeps       0;
            nPostSweeps      2;
            nFinestSweeps    2;

            cacheAgglomeration false;
            nCellsInCoarsestLevel 10;
            agglomerator     faceAreaPair;
            mergeLevels      1;
        };
        tolerance        1e-7;
        relTol           0;
        maxIter          50;
    };
}

PIMPLE
{
    momentumPredictor          no;
    nOuterCorrectors           1;
    nCorrectors                2;
    nNonOrthogonalCorrectors   1;

    cAlpha                     0;
    nAlphaCorr                 1;
    nAlphaSubCycles            1;
}


relaxationFactors
{
    fields
    {
    }
    equations
    {
        "U.*"                      1;
    }
}
As can be seen , all the settings are the same with the tutorial: cavitatingBullet

The resulting Cp at x/l = 0.1 is about -2, which is much lower than the exp, indicating a much lower pressure than exp. While the calculation is at least stable.

I used to think the time scheme may affect the result, so I change it to the second order backward/ Crank , however, the two schemes used can easily lead to overflow>

I have got stuck on this problem for days Is there anyone who can tell me what's wrong? Any advice is appreciated.

Best regards
Xianbei
huangxianbei is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
interphasechangeFoam: strange residual behaviour with keps and kwSST shipman OpenFOAM Post-Processing 1 June 14, 2014 08:58
Problem with INTERPHASECHANGEFOAM shipman OpenFOAM 2 March 26, 2014 13:36
InterPhaseChangeFoam ERROR shipman OpenFOAM Running, Solving & CFD 37 March 23, 2014 13:43
Wrong forces on a 2D airfoil using interPhaseChangeFoam Artur OpenFOAM 0 August 7, 2013 11:38
Bug about MULES::implicitSolve for interPhaseChangeFoam in OF-1.6 chiven OpenFOAM Bugs 18 April 18, 2013 22:56


All times are GMT -4. The time now is 10:37.