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

[snappyHexMesh] Add layers at the bottom of a mesh

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 1, 2021, 11:31
Default Add layers at the bottom of a mesh
  #1
New Member
 
Clarisse Hayoun
Join Date: Mar 2021
Location: France
Posts: 5
Rep Power: 5
chayoun is on a distinguished road
Hello everyone,


I have troubles to add extra cell layers at the bottom of my mesh like Scott A.Brown (2016) did in his PhD. I want to add 6 cell layers at the bottom of my mesh, each layer being twice thicker than the layer below it. The smallest one at the bottom should be 1mm thick.


Using tutorials, forum posts and youtube videos, I end up with those parameters to add the layers.



Code:
addLayersControls
 {
     layers
     {
        bottom
        {
           nSurfaceLayers 6;
        }
     }
      
     

   relativeSizes false;
    expansionRatio 2.0;
    firstLayerThickness 1e-3;
    minThickness 5e-1;
    nGrow 2;
 
 
     // Advanced settings
  
 
     // Static analysis of starting mesh
 
 
     featureAngle 130;
     layerTerminationAngle -180;
     maxFaceThicknessRatio 0.5;
 
 
     // Patch displacement
 
 
     nSmoothSurfaceNormals 3;
     nSmoothThickness 10;
 
 
     // Medial axis analysis
      
    

   minMedialAxisAngle 90;
    maxThicknessToMedialRatio 0.3;
    nSmoothNormals 3;
 
 
     // Mesh shrinking
 
 
     slipFeatureAngle 30;
     nRelaxIter 5;
 
 
     nBufferCellsNoExtrude 0;
     nLayerIter 50;
 
 
 }
No layers are added at the bottom patch of the mesh.



Looking at the polyMesh directory and its set sub-directory, the files « addedCells » and « layerFaces » are empty but the other files « nonAlignFaces », « nonOrthoFaces », « skewFaces » and « wrongFaces » are not.


I have been struggling for months with it, using documentation, forum and even youtube videos to help me but I am obviously missing something important here.



Any help would be more than welcome !


Please find attached my case, run it with the Allrun script attached.


Best regards,


Clarisse Hayoun

p { margin-bottom: 0.25cm; line-height: 115%; background: transparent }
Attached Files
File Type: zip Add_Layers_CH.zip (17.6 KB, 6 views)
chayoun is offline   Reply With Quote

Old   June 2, 2021, 01:46
Default
  #2
Senior Member
 
M
Join Date: Dec 2017
Posts: 642
Rep Power: 12
AtoHM is on a distinguished road
You might missed there is a switch at the top of the snappyHexMeshDict. You have to enable addLayers there for snappy to perform that phase of meshing.

I hope it's just that, can't see any obvious error in the rest there.
AtoHM is offline   Reply With Quote

Old   June 2, 2021, 04:13
Default
  #3
New Member
 
Clarisse Hayoun
Join Date: Mar 2021
Location: France
Posts: 5
Rep Power: 5
chayoun is on a distinguished road
Quote:
Originally Posted by AtoHM View Post
You might missed there is a switch at the top of the snappyHexMeshDict. You have to enable addLayers there for snappy to perform that phase of meshing.

I hope it's just that, can't see any obvious error in the rest there.

Thank you for your reply AtoHM.


I did run it with the switch on, in the dict that I shared with you it might not be on as I tried the other steps before hand to be sure you could run it fully.


Best,


Clarisse
chayoun is offline   Reply With Quote

Old   June 2, 2021, 04:58
Default
  #4
Senior Member
 
M
Join Date: Dec 2017
Posts: 642
Rep Power: 12
AtoHM is on a distinguished road
Ok, I checked the case just now.
You reference a region called "frontBack" in the layers-subdictionary. But this name is not declared anywhere in the geometry-section, so it is just ignored.
AtoHM is offline   Reply With Quote

Old   June 2, 2021, 05:22
Default
  #5
New Member
 
Clarisse Hayoun
Join Date: Mar 2021
Location: France
Posts: 5
Rep Power: 5
chayoun is on a distinguished road
Quote:
Originally Posted by AtoHM View Post
Ok, I checked the case just now.
You reference a region called "frontBack" in the layers-subdictionary. But this name is not declared anywhere in the geometry-section, so it is just ignored.

The patch "frontBack" belongs to the blockMeshDict. How do I put this in the geometry-section of snappy?
chayoun is offline   Reply With Quote

Old   June 2, 2021, 11:35
Default
  #6
Senior Member
 
M
Join Date: Dec 2017
Posts: 642
Rep Power: 12
AtoHM is on a distinguished road
Oh that seems right. Unfortunately, I never used it that way and I found someone else had a similar issue unanswered: Why doesn't SnappyHexMesh retain patches from BlockMesh


Maybe someone else knows how to add layers to a patch from blockMesh?
AtoHM 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] Boundary layers across rotorDisk cellZone vLhomme OpenFOAM Meshing & Mesh Conversion 3 April 7, 2021 04:46
[snappyHexMesh] Snappy add layers failed mqsim OpenFOAM Meshing & Mesh Conversion 1 January 24, 2021 15:02
how to set periodic boundary conditions Ganesh FLUENT 15 November 18, 2020 06:09
[snappyHexMesh] SHM is not extruding/adding Layers everywhere matthiasd OpenFOAM Meshing & Mesh Conversion 2 October 16, 2016 16:45
Icemcfd 11: Loss of mesh from surface mesh option? Joe CFX 2 March 26, 2007 18:10


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