CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Meshing & Mesh Conversion

[snappyHexMesh] Not all entries in refinementSurfaces dictionary were used

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 13, 2015, 07:08
Default Not all entries in refinementSurfaces dictionary were used
  #1
New Member
 
Caro
Join Date: Jul 2014
Posts: 15
Rep Power: 12
will_ca is on a distinguished road
Hi everyone,
I'm trying to learn how to use snappyHexMesh.
I'm trying to mesh the quarter of a cylinder. I build that geometry in Salome and saved it as stl files.
I saved the different parts (wall, two symmetryplanes, inlet and outlet) as separate files and changed the file so that every surface has its name like this:
solid wall
<facet ….>
endsolid wall


when I try to run snappyHexMesh I get the warning:

Code:
Reading refinement surfaces. 
 --> FOAM Warning :  
     From function refinementSurfaces::refinementSurfaces(..) 
     in file autoHexMesh/refinementSurfaces/refinementSurfaces.C at line 226 
     Reading "/home/cw591/OpenFOAM/cw591-2.3.0/run/testmesh2/system/snappyHexMeshDict.castellatedMeshControls.refinementSurfaces" from line 150 to line 154 
     Not all entries in refinementSurfaces dictionary were used. The following entries were not used :  
 4 
 ( 
 SymPlane1 
 inlet 
 outlet 
 wall 
 )
so it looks as if only the stl file that I use last in the geometry part of my snappyHexMeshDict (see below) is used.


I also tried making one stl file (vol.stl) that includes all surfaces with their names and then using just that, adding regions like in the part commented geometry part in the snappyHexMeshDict below. When I run that I get the same warning, but now none of the patches are used:

Code:
Not all entries in refinementSurfaces dictionary were used. The following entries were not used :  
 5 
 ( 
 SymPlane1 
 SymPlane2 
 inlet 
 outlet 
 wall 
 )
Does anyone know what I'm doing wrong?
I'd apreciate any help
C

My snappyHexMeshDict:
Code:
castellatedMesh true; 
 snap            true; 
 addLayers       false; 
  
  
 geometry 
 { 
     inlet.stl {type triSurfaceMesh; name inlet} 
     outlet.stl {type triSurfaceMesh; name outlet} 
     wall.stl {type triSurfaceMesh; name wall} 
     SymPlane1.stl {type triSurfaceMesh; name SymPlane1} 
     SymPlane2.stl {type triSurfaceMesh; name SymPlane2} 
  
   /*  vol.stl  
     { 
         type triSurfaceMesh;  
         name volume; 
         /*regions 
         { 
             inlet 
             { name inlet;} 
             outlet 
             {name outlet;} 
             wall 
             { name wall;} 
             SymPlane1 
             { name SymPlane1;} 
             SymPlane2 
             { name SymPlane2;} 
         } 
     }*/ 
  
     // Analytical shape; cylinder, sphere 
     refinementBox 
     { 
         type searchableBox; 
         min (-0.01 -0.01 -0.5); 
         max ( 0.55 0.55 1.4); 
     } 
 }; 
  
  
  
 // Settings for the castellatedMesh generation. 
 castellatedMeshControls 
 { 
  
     maxLocalCells 1000000; 
  
     maxGlobalCells 7000000; 
  
     minRefinementCells 10; 
  
     maxLoadUnbalance 0.10; 
  
     nCellsBetweenLevels 1; 
  
  
     features 
     ( 
         { 
             file "inlet.eMesh"; 
         level 3; 
         } 
         { 
             file "outlet.eMesh"; 
         level 3; 
         } 
  
         { 
             file "wall.eMesh"; 
         level 3; 
         } 
         { 
             file "SymPlane1.eMesh"; 
         level 3; 
         } 
         { 
             file "SymPlane2.eMesh"; 
         level 3; 
         } 
     ); 
  
  
  
     refinementSurfaces 
     { 
                     // Surface-wise min and max refinement level 
             inlet {level (1 1);} 
             outlet {level (1 1);} 
             wall {level (5 6);} 
             SymPlane1 {level (5 6);} 
             SymPlane2 {level (5 6);}         
     } 
  
     // Resolve sharp angles 
     resolveFeatureAngle 80; 
  
  
  
     refinementRegions 
     { 
         refinementBox   
         { 
             mode inside; 
             levels ((1E15 5)); 
         } 
  
     } 
  
  
     locationInMesh (0.01 0.01 0.01); 
  
  
     allowFreeStandingZoneFaces true;  
 } 
  
  
  
 // Settings for the snapping. 
 snapControls 
 { 
  
     nSmoothPatch 3; 
  
     tolerance 4.0; 
  
     nSolveIter 30; 
  
     nRelaxIter 5; 
 } 
  
  
  
 // Settings for the layer addition. 
 addLayersControls 
 { 
  
     relativeSizes true; 
  
      layers 
     { 
         wall  
     { 
             nSurfaceLayers 3; 
         } 
     } 
  
  
     expansionRatio 1.1; 
  
     finalLayerThickness 0.003; 
  
     minThickness 0.003; 
  
     nGrow 0; 
  
  
     // Advanced settings 
  
     featureAngle 60; 
  
     nRelaxIter 3; 
  
     nSmoothSurfaceNormals 1; 
  
     nSmoothNormals 3; 
  
     nSmoothThickness 2; 
  
     maxFaceThicknessRatio 0.5; 
  
     maxThicknessToMedialRatio 0.3; 
  
     minMedianAxisAngle 130; 
  
     nBufferCellsNoExtrude 0; 
  
     nLayerIter 50; 
 } 
  
  
  
 meshQualityControls 
 { 
  
     maxNonOrtho 65; 
  
     maxBoundarySkewness 20; 
     maxInternalSkewness 4; 
  
     maxConcave 80; 
  
     minFlatness 0.5; 
  
     minVol 1e-13; 
     minTetQuality 1e-30; 
  
     minArea -1; 
  
     minTwist 0.02; 
  
     minDeterminant 0.001; 
  
     minFaceWeight 0.02; 
  
     minVolRatio 0.01; 
  
     minTriangleTwist -1; 
  
  
     // Advanced 
  
     nSmoothScale 4; 
  
     errorReduction 0.75; 
 } 
  
  
 // Advanced 
  
 debug 0; 
  
 // Merge tolerance. Is fraction of overall bounding box of initial mesh. 
 // Note: the write tolerance needs to be higher than this. 
 mergeTolerance 1E-6;
will_ca is offline   Reply With Quote

Old   July 29, 2015, 06:27
Default Not all entries in refinement Surfaces dictionary were used
  #2
New Member
 
Surya Kiran
Join Date: Feb 2015
Location: Hamburg
Posts: 2
Rep Power: 0
peravali is on a distinguished road
hello,
I am meshing a propeller case. I didn't have a problem in model scale but when i am remeshing in full scale i am having the same error for one particular region. I am guessing it has something to do with the refinement parameters. Did u able to solve it later?

Last edited by peravali; July 29, 2015 at 06:31. Reason: title wrong
peravali is offline   Reply With Quote

Old   April 29, 2016, 05:35
Default
  #3
Senior Member
 
Derek Mitchell
Join Date: Mar 2014
Location: UK, Reading
Posts: 172
Rep Power: 13
derekm is on a distinguished road
Quote:
Originally Posted by will_ca View Post
Hi everyone,
I'm trying to learn how to use snappyHexMesh.
I'm trying to mesh the quarter of a cylinder. I build that geometry in Salome and saved it as stl files.
I saved the different parts (wall, two symmetryplanes, inlet and outlet) as separate files and changed the file so that every surface has its name like this:
solid wall
<facet ….>
endsolid wall


when I try to run snappyHexMesh I get the warning:

[CODE]Reading refinement surfaces.
--> FOAM Warning :
From function refinementSurfaces::refinementSurfaces(..)
in file autoHexMesh/refinementSurfaces/refinementSurfaces.C at line 226
Reading "/home/cw591/OpenFOAM/cw591-2.3.0/run/testmesh2/system/snappyHexMeshDict.castellatedMeshControls.refineme ntSurfaces" from line 150 to line 154
Not all entries in refinementSurfaces dictionary were used. The following entries were not used :
...

My snappyHexMeshDict:
Code:
castellatedMesh true; 
 snap            true; 
 addLayers       false; 
  
  
 geometry 
 { 
...
     // Analytical shape; cylinder, sphere 
     refinementBox 
     { 
         type searchableBox; 
         min (-0.01 -0.01 -0.5); 
         max ( 0.55 0.55 1.4); 
     } 
 }; 
  
  ..

the error is in the geometry section you missed out the name of the refinement section it should be as below

Code:
  
 geometry 
 { 
...
     // Analytical shape; cylinder, sphere 
     refinementBox 
     {   name    refinementBox ;
         type searchableBox; 
         min (-0.01 -0.01 -0.5); 
         max ( 0.55 0.55 1.4); 
     } 
 }; 
  
  ..
I ran into this problem today and found the fix.. perhaps the error message should be a little more informative like
Code:
 cannot find refinement region "refinementbox"
__________________
A CHEERING BAND OF FRIENDLY ELVES CARRY THE CONQUERING ADVENTURER OFF INTO THE SUNSET
derekm is offline   Reply With Quote

Old   December 5, 2019, 08:11
Default
  #4
New Member
 
Join Date: Nov 2019
Posts: 13
Rep Power: 7
user007 is on a distinguished road
Quote:
Originally Posted by will_ca View Post
Hi everyone,
...


I also tried making one stl file (vol.stl) that includes all surfaces with their names and then using just that, adding regions like in the part commented geometry part in the snappyHexMeshDict below. When I run that I get the same warning, but now none of the patches are used:

Code:
Not all entries in refinementSurfaces dictionary were used. The following entries were not used :  
 5 
 ( 
 SymPlane1 
 SymPlane2 
 inlet 
 outlet 
 wall 
 )

...

I'm experiencing exactly the same problem, have you found a solution to refers the surfaces inside an multi solid stl to refine them?
user007 is offline   Reply With Quote

Old   January 7, 2021, 14:04
Default I guess
  #5
New Member
 
Ahmet Can Ilhan
Join Date: Nov 2020
Posts: 2
Rep Power: 0
ahmetcanilhan is on a distinguished road
I know this is an old thread but I solved this problem with increasing levels


Code:
    refinementSurfaces
    {
        domain
        {
            level (0 0);
            regions
            {
                inlet        { level (1 1); patchInfo { type patch; } }
                outlet        { level (1 1); patchInfo { type patch; } }
                solidExternal    { level (1 1); patchInfo { type wall;  } }
            }
        }

    fluidToSolid
        {
            level (1 1);
            faceZone fluidToSolid;
            cellZone steel;
            cellZoneInside insidePoint;
            insidePoint (-0.005 0.01 0.045);
        }

    steelToAluminum
        {
            level (1 1);
            faceZone steelToAluminum;
            cellZone aluminum;
            cellZoneInside insidePoint;
            insidePoint (-0.005 0.01 0.005);
        }





    }

I got the "Not all entries in refinementSurfaces dictionary were used. The following entries were not used :" message and change below code to



Code:
    refinementSurfaces
    {
        domain
        {
            level (0 0);
            regions
            {
                inlet        { level (1 1); patchInfo { type patch; } }
                outlet        { level (1 1); patchInfo { type patch; } }
                solidExternal    { level (1 1); patchInfo { type wall;  } }
            }
        }

    fluidToSolid
        {
            level (1 2);
            faceZone fluidToSolid;
            cellZone steel;
            cellZoneInside insidePoint;
            insidePoint (-0.005 0.01 0.045);
        }

    steelToAluminum
        {
            level (1 2);
            faceZone steelToAluminum;
            cellZone aluminum;
            cellZoneInside insidePoint;
            insidePoint (-0.005 0.01 0.005);
        }





    }

and problem solved. I hope its helpful.
ahmetcanilhan is offline   Reply With Quote

Old   November 4, 2021, 22:04
Default
  #6
New Member
 
Xiangjie Wang
Join Date: Jul 2019
Posts: 26
Rep Power: 7
XJ_Wang is on a distinguished road
I hope no one is encountering this problem. But if you do , there might be some problem with the syntax. I am not sure which version of OpenFOAM Caro was using. But I believe there was some syntax error in his/her code.
Code:
 inlet.stl {type triSurfaceMesh; name inlet}
[/QUOTE]
There missed an ";" after 'name inlet'

If you are encountering this problem, please check whether there is some other warning ahead of this warning. You might have some syntax problem.


Quote:
Originally Posted by will_ca View Post
Hi everyone,
I'm trying to learn how to use snappyHexMesh.
I'm trying to mesh the quarter of a cylinder. I build that geometry in Salome and saved it as stl files.
I saved the different parts (wall, two symmetryplanes, inlet and outlet) as separate files and changed the file so that every surface has its name like this:
solid wall
<facet ….>
endsolid wall


when I try to run snappyHexMesh I get the warning:

Code:
Reading refinement surfaces. 
 --> FOAM Warning :  
     From function refinementSurfaces::refinementSurfaces(..) 
     in file autoHexMesh/refinementSurfaces/refinementSurfaces.C at line 226 
     Reading "/home/cw591/OpenFOAM/cw591-2.3.0/run/testmesh2/system/snappyHexMeshDict.castellatedMeshControls.refinementSurfaces" from line 150 to line 154 
     Not all entries in refinementSurfaces dictionary were used. The following entries were not used :  
 4 
 ( 
 SymPlane1 
 inlet 
 outlet 
 wall 
 )
so it looks as if only the stl file that I use last in the geometry part of my snappyHexMeshDict (see below) is used.


I also tried making one stl file (vol.stl) that includes all surfaces with their names and then using just that, adding regions like in the part commented geometry part in the snappyHexMeshDict below. When I run that I get the same warning, but now none of the patches are used:

Code:
Not all entries in refinementSurfaces dictionary were used. The following entries were not used :  
 5 
 ( 
 SymPlane1 
 SymPlane2 
 inlet 
 outlet 
 wall 
 )
Does anyone know what I'm doing wrong?
I'd apreciate any help
C

My snappyHexMeshDict:
Code:
castellatedMesh true; 
 snap            true; 
 addLayers       false; 
  
  
 geometry 
 { 
     inlet.stl {type triSurfaceMesh; name inlet} 
     outlet.stl {type triSurfaceMesh; name outlet} 
     wall.stl {type triSurfaceMesh; name wall} 
     SymPlane1.stl {type triSurfaceMesh; name SymPlane1} 
     SymPlane2.stl {type triSurfaceMesh; name SymPlane2} 
  
   /*  vol.stl  
     { 
         type triSurfaceMesh;  
         name volume; 
         /*regions 
         { 
             inlet 
             { name inlet;} 
             outlet 
             {name outlet;} 
             wall 
             { name wall;} 
             SymPlane1 
             { name SymPlane1;} 
             SymPlane2 
             { name SymPlane2;} 
         } 
     }*/ 
  
     // Analytical shape; cylinder, sphere 
     refinementBox 
     { 
         type searchableBox; 
         min (-0.01 -0.01 -0.5); 
         max ( 0.55 0.55 1.4); 
     } 
 }; 
  
  
  
 // Settings for the castellatedMesh generation. 
 castellatedMeshControls 
 { 
  
     maxLocalCells 1000000; 
  
     maxGlobalCells 7000000; 
  
     minRefinementCells 10; 
  
     maxLoadUnbalance 0.10; 
  
     nCellsBetweenLevels 1; 
  
  
     features 
     ( 
         { 
             file "inlet.eMesh"; 
         level 3; 
         } 
         { 
             file "outlet.eMesh"; 
         level 3; 
         } 
  
         { 
             file "wall.eMesh"; 
         level 3; 
         } 
         { 
             file "SymPlane1.eMesh"; 
         level 3; 
         } 
         { 
             file "SymPlane2.eMesh"; 
         level 3; 
         } 
     ); 
  
  
  
     refinementSurfaces 
     { 
                     // Surface-wise min and max refinement level 
             inlet {level (1 1);} 
             outlet {level (1 1);} 
             wall {level (5 6);} 
             SymPlane1 {level (5 6);} 
             SymPlane2 {level (5 6);}         
     } 
  
     // Resolve sharp angles 
     resolveFeatureAngle 80; 
  
  
  
     refinementRegions 
     { 
         refinementBox   
         { 
             mode inside; 
             levels ((1E15 5)); 
         } 
  
     } 
  
  
     locationInMesh (0.01 0.01 0.01); 
  
  
     allowFreeStandingZoneFaces true;  
 } 
  
  
  
 // Settings for the snapping. 
 snapControls 
 { 
  
     nSmoothPatch 3; 
  
     tolerance 4.0; 
  
     nSolveIter 30; 
  
     nRelaxIter 5; 
 } 
  
  
  
 // Settings for the layer addition. 
 addLayersControls 
 { 
  
     relativeSizes true; 
  
      layers 
     { 
         wall  
     { 
             nSurfaceLayers 3; 
         } 
     } 
  
  
     expansionRatio 1.1; 
  
     finalLayerThickness 0.003; 
  
     minThickness 0.003; 
  
     nGrow 0; 
  
  
     // Advanced settings 
  
     featureAngle 60; 
  
     nRelaxIter 3; 
  
     nSmoothSurfaceNormals 1; 
  
     nSmoothNormals 3; 
  
     nSmoothThickness 2; 
  
     maxFaceThicknessRatio 0.5; 
  
     maxThicknessToMedialRatio 0.3; 
  
     minMedianAxisAngle 130; 
  
     nBufferCellsNoExtrude 0; 
  
     nLayerIter 50; 
 } 
  
  
  
 meshQualityControls 
 { 
  
     maxNonOrtho 65; 
  
     maxBoundarySkewness 20; 
     maxInternalSkewness 4; 
  
     maxConcave 80; 
  
     minFlatness 0.5; 
  
     minVol 1e-13; 
     minTetQuality 1e-30; 
  
     minArea -1; 
  
     minTwist 0.02; 
  
     minDeterminant 0.001; 
  
     minFaceWeight 0.02; 
  
     minVolRatio 0.01; 
  
     minTriangleTwist -1; 
  
  
     // Advanced 
  
     nSmoothScale 4; 
  
     errorReduction 0.75; 
 } 
  
  
 // Advanced 
  
 debug 0; 
  
 // Merge tolerance. Is fraction of overall bounding box of initial mesh. 
 // Note: the write tolerance needs to be higher than this. 
 mergeTolerance 1E-6;
XJ_Wang is offline   Reply With Quote

Reply

Tags
not used, patches, refinementsurfaces, stl file


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
driftFluxFoam viscosity model modification problem dleduc OpenFOAM Programming & Development 15 October 1, 2018 10:37
ill defined primitiveEntry starting at keyword 'value' on line 197 ChangeDictionary Struggle_Achieve OpenFOAM Pre-Processing 2 December 20, 2017 04:58
Entries of kinematicCloudProperties Dictionary missios OpenFOAM Pre-Processing 0 October 24, 2017 05:13
Reading a field(?) within a dictionary ecbmxer OpenFOAM Programming & Development 0 July 14, 2014 17:21
Problem with rhoSimpleFoam matteo_gautero OpenFOAM Running, Solving & CFD 0 February 28, 2008 07:51


All times are GMT -4. The time now is 16:32.