CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM (https://www.cfd-online.com/Forums/openfoam/)
-   -   a room mechanical/natural ventilation case (https://www.cfd-online.com/Forums/openfoam/143575-room-mechanical-natural-ventilation-case.html)

vaina74 October 28, 2014 09:19

a room mechanical/natural ventilation case
 
1 Attachment(s)
Hi Foamers,
I'm trying to set a mechanical/natural ventilation case, concerning a ship engine room. I don't need to model fans and other devices, just inlet and outlet openings. I'm new at ventilation problems, so I'm tackling the problem gradually. I've already looked for similar cases here and I'd like to share my little experience step by step. I started with the simpleFoam solver for earlier tests, but I think that I'll use buoyantBoussinesqSimpleFoam later.
The attached picture show the simple test domain: a cubic room with three openings: inlet (on the left) and outlet (on the top) with mechanical ventilation systems and a window for natural ventilation (on the right).
The turbulent model k-epsilon model is adopted. I guess a velocity fluctuating component of 5% of U and a turbulent length scale of 0.038*Dh (hydraulic diameter). The following boundary conditions are set:

U
INLET
type flowRateInletVelocity;
volumetricFlowRate constant 0.5;
value uniform (0 0 0);
OUTLET
type flowRateInletVelocity;
volumetricFlowRate constant -0.2;
value uniform (0 0 0);
WINDOW
type inletOutlet;
inletValue uniform (0 0 0);
value uniform (0 0 0);
WALL
type fixedValue;
value uniform (0 0 0);

p
INLET
type zeroGradient;
OUTLET
type fixedValue;
value uniform 0;
WINDOW
type fixedValue;
value uniform 0;
WALL
type zeroGradient;

epsilon, k
INLET
type fixedValue;
value $internalField;
OUTLET
type zeroGradient;
WINDOW
type zeroGradient;
WALL
type epsilon(or kqR)WallFunction;
value $internalField;

I used the following numerical schemes
Code:

ddtSchemes
{
    default        steadyState;
}

gradSchemes
{
    default        Gauss linear;
}

divSchemes
{
    default        none;
    div(phi,U)      bounded Gauss upwind;
    div(phi,k)      bounded Gauss upwind;
    div(phi,epsilon) bounded Gauss upwind;
    div(phi,R)      bounded Gauss upwind;
    div(R)          Gauss linear;
    div(phi,nuTilda) bounded Gauss upwind;
    div((nuEff*dev(T(grad(U))))) Gauss linear;
}

laplacianSchemes
{
    default        Gauss linear corrected;
}

interpolationSchemes
{
    default        linear;
}

snGradSchemes
{
    default        corrected;
}

fluxRequired
{
    default        no;
    p              ;
}

and solution and algorithm controls
Code:

solvers
{
    p
    {
        solver          PCG;
        preconditioner  DIC;
        tolerance      1e-09;
        relTol          0.1;
    }

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

SIMPLE
{
    nNonOrthogonalCorrectors 0;

    residualControl
    {
        p              1e-2;
        U              1e-3;
        "(k|epsilon|omega)" 1e-3;
    }
}

relaxationFactors
{
    fields
    {
        p              0.15;
    }
    equations
    {
        U              0.005;
        k              0.001;
        epsilon        0.001;
        R              0.001;
        nuTilda        0.001;
    }
}

I'd like to have your suggestions, remarks and corrections about my choice of turbulent model, initial turbulent settings, boundary conditions, fvSchemes, fvSolution. Thanks for your attention and your help.

taxalian October 29, 2014 15:57

Hi vaina74,

Your numerical setup seems to be ok.

But by having a look at your boundary conditions, you specify at first a fixed mass flow rate at the inlet and at the outlet you are using kind of suction boundary condition to filter out the flow. I think this might cause some convergence problem because i don't know how the continuity will be satisfied i.e "mass_flow inlet = mass_flow outlet"


Make sure you also specify the exact values of epsilon & k for your flow case.

Well if you are new to this area, my advice would be to start with icoFoam (incompressible, laminar, unsteady) solver if your velocities are low and then switch on to laminar flow with simpleFoam.

Finally go for buoyantBoussinesqSimpleFoam solver.

Good luck.

vaina74 October 30, 2014 03:17

Hi Taxialan, thanks for your suggestions. I had no convergence problems so far (about 400 iterations) and I'm already going deep in buoyantBoussinesqSimpleSolver - I'm not confident with p_rgh and other stuff :)
About epsilon and k initial guess, I'm not sure of the turbulent length scale. But I think that initial values should not be so important, if not quite unrealistic.
You are right about continuity, but this simple model is not so far from reality. One or more fans blow clean air in the engine room, one or more openings help ventilation, one or more (less powered) suction fans suck dirty air. Obviously machinery (diesel engines, diesel generators, ...) burn out air, but I think I'll model that as a simply outlet condition at the final stage.


All times are GMT -4. The time now is 14:41.