CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Difference between explicitPorositySource and interRegionExplicitPorositySource (https://www.cfd-online.com/Forums/openfoam-solving/215474-difference-between-explicitporositysource-interregionexplicitporositysource.html)

zarox March 6, 2019 09:27

Difference between explicitPorositySource and interRegionExplicitPorositySource
 
2 Attachment(s)
Dear all,

I have a flow in a pipe with a part that is considered as a porous. I use fvOption with explicitPorositySource with DarcyForchheimer coefficient. The porous cell zone is extract from topoSet. I also have a solid mesh that represent this porous as I have conjugate heat transfer.

So, I was thinking that I could define the porous zone for the fvOption for the fluid thanks to the solid region and use interRegionExplicitPorositySource. However, doing that, the forcing depend on the size of the solid mesh and so the pressure loss depend on the solid mesh. This is not the case with the porous zone define by topoSet on the fluid region.

I was thinking that interRegionExplicitPorosity source works as explicitPorositySource but with zone extract from the region (here solid) overlapping the region fluid. So at the end I was the same porous region define, the same coefficient but the result depend on the solid mesh in the interRegionExplicitPorositySource method.

However, I checked the DarcyForchheimer model, and same computation are done, expect that the Volume cell taken is the Volume of the solid cell. I don't understand all in interRegionPorositySource code but I believe to understand that the forcing compute on the solid mesh is then convert in source for the fluid region.

Perhaps, I completely misunderstood this interRegionExplicitPorositySource.


In attachment, there is the case with two mesh size for the solid. fvOption is interRegion, but there are commented lines for the explicit source with cellZone. To do the mesh for air, as I need extrusion and extrudeMesh region seems to not works, I do the following :

for air:

1/ cp system/air/blockMesh system
2/ blockMesh
3/ stitchMesh -overwrite iY iY2
4/ extrudeMesh
5/ cp -r constant/polyMesh constant/air/
6/ remove iY and IY2 patch from boundary file in polyMesh
7/ topoSet -region air


for solid :

1/ cp system/solid/blockMesh system
2/ blockMesh
3/ extrudeMesh
5/ cp -r constant/polyMesh constant/solid/

The picture show the pressure drop with the two method for the two Mesh of solid. I also do a test with change of the air mesh for explicitPorositySource, and the change of the fluid Mesh don't impact the result for explicitPorositySource.

Emeline

mishrashubham January 15, 2022 05:14

Did you find your answer ?
 
Please reply

AlxB March 22, 2022 05:29

Dear Emeline,
did you find the issue out ?


Dear Foamers,

I have a similar problem using a porosity zone specified with DarcyForchheimer coefficients.

My first case uses the interRegionExplicitPorositySource fvOption with some specific DarcyFor. coeffs and a specific h coefficient for the heat transfer to a porous media where water is circulating.

My second case duplicates the first one excepts that the DarcyFor. coeffs are not used from the interRegionExplicitPorositySource but are used from an explicitPorositySource specification.

What I can see is:

. the explicitPorositySource fvOption manages to calculate a drag force but the interRegionExplicitPorositySource one doesn't, despite an identical cellzone specification.

. the explicitPorositySource fvOption gives a pressure drop three times smaller than the interRegionExplicitPorositySource one.


What could be the explanation for these differences ?

Many thanks

here below the fvOptions:

Code:

airToporous
{
    type            constantHeatTransfer;
    interpolationMethod cellVolumeWeight;
    nbrRegion    porous;  // neighbour region name
    master        false;

    nbrModel    porousToair;
    fields          (h);
    semiImplicit    no;
}
porosityBlockage
{
    type            interRegionExplicitPorositySource;

    interRegionExplicitPorositySourceCoeffs
    {
        interpolationMethod cellVolumeWeight;
        nbrRegion      porous; // neighbour region name
        type            DarcyForchheimer;
        d  ($dx1  $dy1 $dz1);          // case 1
        f    ($fx1  $fy1 $fz1);            // case 1
        selectionMode  cellZone;
        cellZone        porosity1;
        // d  (0 0 0);                        // case 2
        // f  (0 0 0);                        // case 2

        coordinateSystem
        { origin  (0 0 0); e1 (1 0 0); e2 (0 1 0);}
    }
}

porosity1
{
    type            explicitPorositySource;

    explicitPorositySourceCoeffs
    {
        selectionMode  cellZone;
        cellZone        porosity1;
        type            DarcyForchheimer;
        // d  ($dx1  $dy1 $dz1);      // case 2
        // f  ($fx1  $fy1 $fz1);        // case 2
        d  (0 0 0);                          case 1
        f  (0 0 0);                          case 1

        coordinateSystem
        { origin  (0 0 0); e1 (1 0 0); e2 (0 1 0);}
    }       
}


zarox March 22, 2022 05:57

Sorry don't work on it anymore
 
I am sorry, I don't work on it anymore.
I thnik explicitPorositySource is more reliable.

Bloerb March 22, 2022 14:05

interRegionExplicitPorositySource is used to add porosity between different mesh regions. I.e you have a water and air region on separate meshes and these meshes overlap. Like in a heat exchanger, where there is a bunch of tiny pipes crossing each other, but you can't resolve those because it is way to expensive to resolve each pipe. hence you model them via a porosity. Is that what you are trying to solve?


Hence the difference is that the first one uses the velocity from the master region for porosity and is used for a single region porosity, while the second one is likely using the velocity of the slave region to account for their path crossing.


All times are GMT -4. The time now is 19:07.