CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Fluctuating Pressure with porousSimpleFoam (http://www.cfd-online.com/Forums/openfoam-solving/117046-fluctuating-pressure-poroussimplefoam.html)

matzbanni May 1, 2013 04:42

Fluctuating Pressure with porousSimpleFoam
 
Hello,
I'm running a channel-case with a smaller cross-section in between. The little box in the middle is filled with a porous zone. Furthermore there are also other geometric details, which shouldn't influence the results.

The problem is, that the pressure values which I'm recording right in front of the porous zone are fluctuating considerable, aroung +/- 50 Pa. The values behind the zone are pretty continuous.

Any Ideas?

My fvSchemes:
Code:

ddtSchemes
{
    default        steadyState;
}

gradSchemes
{
    default        Gauss linear;
}

divSchemes
{
    default        none;
    div(phi,U)      Gauss GammaV 0.5;
    div(phi,k)      Gauss Gamma 0.5;
    div(phi,omega)  Gauss Gamma 0.5;
    div((nuEff*dev(T(grad(U))))) Gauss linear;
}

laplacianSchemes
{
    default        Gauss linear limited 0.333;
}

interpolationSchemes
{
    default        linear;
}

snGradSchemes
{
    default        corrected;
}

fluxRequired
{
    default        no;
    p;
}

fvSolution:
Code:

solvers
{
    p
    {
        solver          GAMG;
        tolerance        1e-9;
        relTol          0.1;
        smoother        GaussSeidel;
        nPreSweeps      0;
        nPostSweeps      2;
        cacheAgglomeration on;
        agglomerator    faceAreaPair;
        nCellsInCoarsestLevel 10;
        mergeLevels      1;
    }

    U
    {
        solver          smoothSolver;
        smoother        GaussSeidel;
        tolerance        1e-11;
        relTol          0.1;
        nSweeps          1;
    }

    k
    {
        solver          smoothSolver;
        smoother        GaussSeidel;
        tolerance        1e-11;
        relTol          0.1;
        nSweeps          1;
    }

    omega
    {
        solver          smoothSolver;
        smoother        GaussSeidel;
        tolerance        1e-11;
        relTol          0.1;
        nSweeps          1;
    }
}

SIMPLE
{
    nNonOrthogonalCorrectors 4;
}

potentialFlow
{
    nNonOrthogonalCorrectors 10;
}

relaxationFactors
{
    fields
    {
        p              0.3;
    }
    equations
    {
        U              0.6;
        k              0.3;
        omega          0.3;
    }
}

cache
{
    grad(U);
}


Lieven May 1, 2013 04:52

Hi MB,

A simple test you can perform to see whether the fluctuations are caused by numerical instabilities (wiggles), is to set all 'Gauss gamma 0.5' to 'Gauss upwind'. From accuracy point of view, this is certainly not interesting. But if the wiggles disappear you know it is related to the discretization and not the case setup (BC, initial conditions, ...). If this solves the problem, replace the upwind scheme by a 2nd order one other than the gamma 0.5.

Cheers,

L

matzbanni May 1, 2013 05:14

Quote:

Originally Posted by Lieven (Post 424365)
Hi MB,

A simple test you can perform to see whether the fluctuations are caused by numerical instabilities (wiggles), is to set all 'Gauss gamma 0.5' to 'Gauss upwind'. From accuracy point of view, this is certainly not interesting. But if the wiggles disappear you know it is related to the discretization and not the case setup (BC, initial conditions, ...). If this solves the problem, replace the upwind scheme by a 2nd order one other than the gamma 0.5.

Cheers,

L

Hi Lieven,
thanks four your reply. I already did a simulation with 'Gamma upwind' for k and omega, but the fluctuations are the same. So I have to check my BC, initial conditions etc.? I don't think that I made a mistake there...

Regards,
MB

Lieven May 1, 2013 05:38

Hi MB,

Do it also for div(phi,U). Since the velocity field is directly coupled with the pressure, I even expect this to have a much bigger effect than k and omega.

Cheers,

L

matzbanni May 1, 2013 13:52

Quote:

Originally Posted by Lieven (Post 424383)
Hi MB,

Do it also for div(phi,U). Since the velocity field is directly coupled with the pressure, I even expect this to have a much bigger effect than k and omega.

Cheers,

L

Just got the results. A little bit better, but still fluctuating a lot. Another suggestions?

Regards,
MB

Lieven May 1, 2013 13:55

Did you do set all three to upwind at the same time?

What about the quality of the mesh? Hexahedral? Non-orthogonality? Coarse/fine?
Somewhere conflicting boundary conditions? All steady BC?

Cheers,

L

matzbanni May 2, 2013 08:21

Quote:

Originally Posted by Lieven (Post 424476)
Did you do set all three to upwind at the same time?

What about the quality of the mesh? Hexahedral? Non-orthogonality? Coarse/fine?
Somewhere conflicting boundary conditions? All steady BC?

Cheers,

L

All three are upwind. Regarding the mesh, mostly hexahedral, and a few prisms. Non-orthogonality check is OK, but 3 highly skew faces. Could this be a reason?

Regards,
MB

Lieven May 2, 2013 08:39

This is not so trivial to say but if the fluctuations and/or the prisms or skew faces are near each other this might indeed be the cause...

matzbanni May 2, 2013 08:45

Quote:

Originally Posted by Lieven (Post 424647)
This is not so trivial to say but if the fluctuations and/or the prisms or skew faces are near each other this might indeed be the cause...

Right now I'm creating a new mesh. Thanks for your help so far, I'll let you know how it's working...

matzbanni May 7, 2013 18:38

Quote:

Originally Posted by matzbanni (Post 424650)
Right now I'm creating a new mesh. Thanks for your help so far, I'll let you know how it's working...

Checked a few other meshes, still fluctuating even with upwind. A bit confusing because of the nice values after the porousZone...?!

Regards
MB

Lieven May 8, 2013 01:51

Mmm, do you include the porous zone explicitly or implicitly in the momentum equation?

matzbanni May 8, 2013 05:14

Quote:

Originally Posted by Lieven (Post 425996)
Mmm, do you include the porous zone explicitly or implicitly in the momentum equation?

So far I always included it explicit, but I read that the implicit solver is a bit more robust, let's see...

Lieven May 8, 2013 05:49

Ok, I'm kind of running out of ideas. Anyone else maybe?

fredo490 May 9, 2013 03:38

From my experience on rhoPimpleFoam, you can try to set the pressure relaxation factor to 0.5 and also change the laplacian to 0.5.

I often face "oscillations" on the pressure field that disappear when I rise the relaxation factor. Maybe you can try it.

matzbanni May 9, 2013 10:40

Quote:

Originally Posted by fredo490 (Post 426279)
From my experience on rhoPimpleFoam, you can try to set the pressure relaxation factor to 0.5 and also change the laplacian to 0.5.

I often face "oscillations" on the pressure field that disappear when I rise the relaxation factor. Maybe you can try it.

Okay, I'll give it a try. What do you mean by change the laplacian to 0.5?

fredo490 May 9, 2013 10:45

laplacianSchemes { default Gauss linear limited 0.5; }

NickolasPl December 2, 2013 13:45

Hello everyone,

I' m experiencing exactly the same problem. When I plot the pressure inside the porous region everything looks fine but A LOT of wiggling happens in the non-porous region. I experimented myself with both implicit and explicit posousSimpleFoam solver but without any luck. I also tried different schemes in the fvSchemes dictionary but the wiggling still exists. I do not have any turbulence models on (laminar flow) and I simply cannot understand why this wiggling takes place. The mesh was generated via Gmsh with prismatic cells filling the computational domain which very dense cell arrangements in some regions. Can anybody shed some light regarding this issue? From the BC's point of view I don't think I 've made any mistake. The flow behaviour generally looks..."realistic" short of, and as expected. But the pressure produces oscillations.

Thanks in advance,

Nickolas


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