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

Adding refinement zone causes multiRegion case to fail

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By boffin5

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 30, 2021, 16:51
Default Adding refinement zone causes multiRegion case to fail
  #1
Senior Member
 
Alan w
Join Date: Feb 2021
Posts: 283
Rep Power: 6
boffin5 is on a distinguished road
This case consists of a fluid domain, and a separate domain containing only a cuboid shaped radiator.


It runs okay, but I would like to improve the results by adding a refinement zone to the fluid domain. But with this change, it fails with the the message "Foam Fatal Error - plane normal defined with zero length." Here is the complete output text:
Code:
Create time

Create fluid mesh for region fluid for time = 0

Create fluid mesh for region solid for time = 0

*** Reading fluid mesh thermophysical properties for region fluid

    Adding to thermoFluid

Selecting thermodynamics package 
{
    type            heRhoThermo;
    mixture         pureMixture;
    transport       polynomial;
    thermo          hPolynomial;
    equationOfState icoPolynomial;
    specie          specie;
    energy          sensibleEnthalpy;
}

    Adding to rhoFluid

    Adding to UFluid

    Adding to phiFluid

    Adding to gFluid

    Adding to hRefFluid

    Adding to pRefFluid

    Adding to ghFluid

    Adding to ghfFluid

    Adding to turbulenceFluid

Selecting turbulence model type RAS
Selecting RAS turbulence model kEpsilon
RAS
{
    RASModel        kEpsilon;
    turbulence      on;
    printCoeffs     on;
    Cmu             0.09;
    C1              1.44;
    C2              1.92;
    C3              0;
    sigmak          1;
    sigmaEps        1.3;
}

    Adding to thermophysicalTransport

Selecting thermophysical transport type RAS
Selecting default RAS thermophysical transport model eddyDiffusivity
    Adding to reactionFluid

Combustion model not active: combustionProperties not found
Selecting combustion model none
    Adding to radiationFluid

Selecting radiationModel none
    Adding to KFluid

    Adding to dpdtFluid

    Adding to fieldsFluid

    Adding MRF

No MRF models present

    Adding fvOptions

Creating finite volume options from "constant/fvOptions"

Selecting finite volume options model type constantHeatTransfer
    Source: fluidTosolid
Selecting finite volume options model type interRegionExplicitPorositySource
    Source: porosityBlockage
- selecting inter region mapping
Creating mesh-to-mesh addressing for fluid and solid regions using cellVolumeWeight
[0] 
[0] 
[0] --> FOAM FATAL ERROR: 
[0] Plane normal defined with zero length
Bad points:(2.10957 -0.0521885 0.105936) (2.10957 -0.0510421 0.105936) (2.10957 -0.05 0.105936)
[0] 
[0]     From function void Foam::plane::calcPntAndVec(const point&, const point&, const point&)
[0]     in file meshes/primitiveShapes/plane/plane.C at line 85.
[0] 
FOAM parallel run aborting
I tried it with 2 kinds of refinment zones: one using a searchable box, and another one using an stl file. But the effect was the same. This is baffling behavior, and if anyone has experienced and solved this problem, I would appreciate hearing about it.
boffin5 is offline   Reply With Quote

Old   December 4, 2021, 16:26
Default Solved! Problem with case failure due to blockMesh refinement
  #2
Senior Member
 
Alan w
Join Date: Feb 2021
Posts: 283
Rep Power: 6
boffin5 is on a distinguished road
After a lot of searching and connecting the dots, I found the key to making my simulation run. This is the one where one of the two regions is an empty blockmesh, and it failed when I applied a refinement zone.


In fvOptions for the fluid zone (the empty one), there is an 'interpolationMethod' setting, which is usually set to cellVolumeWeight. But by changing it to 'mapNearest' as shown, the mesh-to-mesh addressing between regions was able to operate properly.


Code:
  

fluidTosolid
{
    type            constantHeatTransfer;

    interpolationMethod mapNearest;    
    nbrRegionName       solid;
    master          false;

    nbrModel        solidTofluid;
    fields          (h);
    semiImplicit    no;
}

porosityBlockage
{
    type            interRegionExplicitPorositySource;

    interRegionExplicitPorositySourceCoeffs
    {
        interpolationMethod mapNearest;     
        nbrRegionName       solid;

        type            DarcyForchheimer;
        
        // D 100;  // Very little blockage
        // D 200;  // Some blockage but steady flow
        // D 500;  // Slight waviness in the far wake
        // D 1000; // Fully shedding behavior

        d   (120 1e9 1e9);
        f   (120 1e9 1e9);

        coordinateSystem
        {
            type    cartesian;
            origin  (0 0 0);
            coordinateRotation
            {
                type    axesRotation;
                e1      (0.5 0 0.866025);
             e2      (0 1 0);
            }
        }
    }
}
Also, in the snappyHexMeshDict for the fluid zone, I changed the 'snap' setting to false, since I figured that in this empty mesh, there was nothing to snap to.


Code:
castellatedMesh true;
snap            false;
addLayers       false;

geometry
{
    refbox2.stl
    {
        type triSurfaceMesh;
        name    refbox2;
    }

};
I hope that someone can derive benefit from this fix; it had me thrown for a long time!
Yann likes this.
boffin5 is offline   Reply With Quote

Reply


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
[snappyHexMesh] Edge Refinement fracasce OpenFOAM Meshing & Mesh Conversion 3 December 2, 2017 14:30
conjugateHeatFoam + interFoam farhagim OpenFOAM Programming & Development 15 July 19, 2016 08:55
killed "snappyHexMesh" parkh32 OpenFOAM Pre-Processing 2 April 8, 2012 18:12
Free surface boudary conditions with SOLA-VOF Fan Main CFD Forum 10 September 9, 2006 13:24
Error to re-open fluent case file J.Gimbun FLUENT 0 April 27, 2006 09:42


All times are GMT -4. The time now is 05:31.