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

[snappyHexMesh] Local refinements

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 1, 2021, 14:09
Default Local refinements
  #1
New Member
 
Santi Parera
Join Date: Jul 2019
Location: BARCELONA
Posts: 25
Rep Power: 6
Kalabagh is on a distinguished road
Hey there,

I'm in a 3D case with a complex geometry that implies complex meshing process. By now, I have reached a good mesh, but in some zones a local refinement is necessary.

The fact is that the type of local refinement I want to do is "edge refinement" as surfaces and regions nearby are ok and I don't want to overcharge more the mesh.

My question is how can I manage this with my snappyHexMeshDict??

I tried to create an .stl file with only the lines in their perfect position, but my software "Inventor" does not seem to agree with saving something that is just "lines", either in .stl.

Then I thought I would be able to call this file on the featureRefinement and assign refinement levels as normal.

Thanks.
Kalabagh is offline   Reply With Quote

Old   September 2, 2021, 03:19
Default
  #2
Senior Member
 
Yann
Join Date: Apr 2012
Location: France
Posts: 1,053
Rep Power: 26
Yann will become famous soon enough
Hi,

You can use the surfaceFeatureExtract utility to extract the feature lines from your STL file. It will create a .eMesh file you can then use for featureRefinement in snappyHexMesh.

The surfaceFeatureExtract utility has been replaced by surfaceFeatures a while ago in the foundation branch so depending on the version you are running you need to use surfaceFeatureExtract or surfaceFeatures.
Cheers,
Yann
Yann is offline   Reply With Quote

Old   September 23, 2021, 13:07
Default
  #3
New Member
 
Santi Parera
Join Date: Jul 2019
Location: BARCELONA
Posts: 25
Rep Power: 6
Kalabagh is on a distinguished road
Hi Yann,

Thank you for your information. The fact is that I have learned a little bit more about surfaceFeatureExtract since your post. I've seen that you can adjust the amount of edges from stl file that will be included in the eMesh file. And also that with some adjustements you can made it so locally. But still, I don't see any possibility to select THAT specific edge I want. There is the "plane" option which all lines coplanar to the plane will get included. But if the geometry is a little complex, that plane will intersect also other zones of the mesh.

Is there any option to select specific edges and convert them into an eMesh file and use it in snappyHexMesh as another edge refinement?

Question: How to manage with the interference between the edge refinement coming from the general eMesh file and the local refinement that is using few but same edges??

Thanks
Kalabagh is offline   Reply With Quote

Old   September 24, 2021, 03:36
Default
  #4
Senior Member
 
Yann
Join Date: Apr 2012
Location: France
Posts: 1,053
Rep Power: 26
Yann will become famous soon enough
Hi,

You can create a specific STL file containing only the surfaces around the edge you want to select and then use it with surfaceFeatureExtract. (Since you can use as many STL as you wish with surfaceFeatureExtract, and as many eMesh files as you wish with snappyHexMesh)

About your last question: you can control the refinement levels on edges, surfaces and volumes and snappy always keeps the finest level. So if you want a finer mesh on specific edges you just have to get an eMesh for these edges and define the refinement level you need. No matter if the surface refinement is coarser.

Cheers,
Yann
Yann is offline   Reply With Quote

Old   September 24, 2021, 05:06
Default
  #5
Senior Member
 
M
Join Date: Dec 2017
Posts: 642
Rep Power: 12
AtoHM is on a distinguished road
Regarding your problem of exporting a line as stl: If you take a closer look at an stl in PV, or in the ascii file really, you will notice that the files consists of a list of triangles. There is no way to save a line as a triangle.


I am looking at an eMesh file of mine (I have never done before) and it seems, the file needs only some points and edges with point start and endindex. Would you be able to create the eMesh for your surface, identify the relevant edges you need to refine and delete the rest in the eMesh-file?
AtoHM is offline   Reply With Quote

Reply

Tags
local refinement


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
pimpleDyMFoam computation randomly stops babapeti OpenFOAM Running, Solving & CFD 5 January 24, 2018 05:28
Upgraded from Karmic Koala 9.10 to Lucid Lynx10.04.3 bookie56 OpenFOAM Installation 8 August 13, 2011 04:03
[blockMesh] BlockMeshmergePatchPairs hjasak OpenFOAM Meshing & Mesh Conversion 11 August 15, 2008 07:36
IcoFoam parallel woes msrinath80 OpenFOAM Running, Solving & CFD 9 July 22, 2007 02:58
Could anybody help me see this error and give help liugx212 OpenFOAM Running, Solving & CFD 3 January 4, 2006 18:07


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