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

[snappyHexMesh] extrudeMesh does nothing?

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 1 Post By matejfor
  • 1 Post By leobaz

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 15, 2018, 21:32
Default extrudeMesh does nothing?
  #1
New Member
 
Alex
Join Date: Jul 2018
Posts: 2
Rep Power: 0
Chubmaster is on a distinguished road
I am trying to create a 2D simulation of a flat plate at various angles against incoming air. I used blockmesh to create a rectangular mesh 1 cell deep (x direction), and then used snappyHexMesh to merge it with the flate plate stl. However this creates more cells in the x direction. I am attempting to use extrudeMesh to make the front face the whole mesh.



When I run extrudeMesh, I get:
Code:
Writing mesh to  "/mnt/c/Users/Avedis/Desktop/Fluids_stuff/flateplate02D/constant/region0"
, it does not write to the most recent polymesh.
When I check the constant directory its not there. If I look at the most recent time in paraview, its the same mesh as before. I don't think it did anything.


this is my extrudeMeshDict:
Code:
constructFrom       patch;

sourceCase          ".";

sourcePatches       (front);

exposedPatchName    back;

flipNormals         false;

extrudeModel        linearNormal;

nLayers             1;

expansionRatio      1.0;

linearNormalCoeffs
{
    thickness       0.01;
}

mergeFaces          false;
Chubmaster is offline   Reply With Quote

Old   September 13, 2018, 07:00
Default
  #2
Senior Member
 
matej forman
Join Date: Mar 2009
Location: Brno, Czech Republic
Posts: 182
Rep Power: 17
matejfor is on a distinguished road
Hi, not sure if it is still an issue, but perhaps there was some message utility prints out to the terminal? What does it say?
matejfor is offline   Reply With Quote

Old   June 2, 2021, 04:17
Default
  #3
New Member
 
Léo BAZIN
Join Date: Mar 2021
Posts: 3
Rep Power: 5
leobaz is on a distinguished road
Hello, this topic may be a bit old, but I'm currently working on OpenFoam and also trying to get a 2D mesh after snappyHexMesh turned my 2D mesh into a 3D mesh. So I used extrudeMesh as Chubmaster did and got the same issue. My mesh is apparently written in constant/region0 but there is no region0 file in my constant folder. Does anyone managed to use extrudeMesh and get a 2D mesh ?
leobaz is offline   Reply With Quote

Old   June 2, 2021, 04:33
Default
  #4
Senior Member
 
matej forman
Join Date: Mar 2009
Location: Brno, Czech Republic
Posts: 182
Rep Power: 17
matejfor is on a distinguished road
Hi,

the information that your mesh was written to constant/region0 maybe is not very lucky one, but is here for the cases you build multiregion mesh. Region0 is the default one, so your mesh is written to constant/polyMesh/ directory. In case of a multiregion mesh, it would be constant/<regionName>/polyMesh.

If you have more doubts, try

>> find $FOAM_TUTORIALS -name extrudeMeshDict

for more examples.


Hope it helps
reverseila likes this.
matejfor is offline   Reply With Quote

Old   June 2, 2021, 06:39
Default
  #5
New Member
 
Léo BAZIN
Join Date: Mar 2021
Posts: 3
Rep Power: 5
leobaz is on a distinguished road
Hi,


Thank you for your answer. I tried to run some tutorials which uses this and I finally found what was wrong. It is necessary to execute "snappyHexMesh -overwrite" instead of just "snappyHexMesh" before running extrudeMesh. I hope this can help people.
reverseila likes this.
leobaz is offline   Reply With Quote

Old   June 2, 2021, 09:28
Default
  #6
Senior Member
 
matej forman
Join Date: Mar 2009
Location: Brno, Czech Republic
Posts: 182
Rep Power: 17
matejfor is on a distinguished road
Yes. Well done. SnappyHexMesh is writing the mesh to the time directory according to the time step settings in <system>/controlDict. So without an argument, it is going to write the mesh into a next time directory. overwrite option will make it to write the polyMesh directory into a constant directory.

You can actually copy the polyMesh directory manually yourself e.g.:

>> cp -r 3/polyMesh constant/polyMesh

if your snappyHexMesh has written the final mesh to time dir. 3.
For more info on snappyHexMesh, please look here:

https://www.openfoam.com/documentati...pyhexmesh.html

happy foaming
matejfor is offline   Reply With Quote

Reply

Tags
extrudemesh, snappyhexmesh


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
[mesh manipulation] extrudeMesh can't find any patches shang2 OpenFOAM Meshing & Mesh Conversion 6 February 26, 2021 21:46
[mesh manipulation] extrudeMesh limits Adaptive/Dynamic Mesh Refinenemt potentialFoam OpenFOAM Meshing & Mesh Conversion 3 January 29, 2018 04:42
[mesh manipulation] Generating 3-D axisymmetric mesh using extrudeMesh martyn88 OpenFOAM Meshing & Mesh Conversion 17 June 21, 2017 20:42
[snappyHexMesh] Problem with extrudeMesh sHM 2D airfoil mesh ssss OpenFOAM Meshing & Mesh Conversion 2 September 1, 2014 14:12
[snappyHexMesh] snappyHexMesh after extrudeMesh / Creating background mesh with extrudeMesh pythag0ra5 OpenFOAM Meshing & Mesh Conversion 3 September 11, 2013 10:10


All times are GMT -4. The time now is 12:42.