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

[snappyHexMesh] How to force cells to snap and adapt to a line contained in the domain?

Register Blogs Community New Posts Updated Threads Search

Like Tree9Likes
  • 3 Post By Yann
  • 2 Post By finn_amann
  • 3 Post By Yann
  • 1 Post By finn_amann

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   September 16, 2022, 13:22
Default How to force cells to snap and adapt to a line contained in the domain?
  #1
New Member
 
Join Date: Dec 2021
Posts: 27
Rep Power: 4
finn_amann is on a distinguished road
Hello friends,

I am trying to create a rectangular mesh consisting of mostly rectangular cells. A wavy line is placed inside the mesh and I want the cells to mesh and refine along that.

To give you a better understanding, I attached two screenshots.

The first one simply shows us the rectangular mesh. It has a certain resolution in the xy-plane and only one cell in the z-direction resulting in a 3D box shape (do people call this 2.5D?).

The second screenshot shows us the box but in wireframe representation. The mentionend "line" is also visible, but since we operate in 3D, the line is actually a surface (not a solid, not a volume, just a surface), which is stored in an STL-file created with gmsh.

My idea was to use snappyHexMesh to force the line into the mesh and make the cells snap to it and refine the area around the line a bit (think about the xy-plane, then this sentence makes more sense). Keep in mind, I don't want any internal faces, boundaries or baffles, I simply want the line inside the mesh and the surrounding cells to adapt to it.

Now, I have briefly worked with snappyHexMesh before, however, I only worked with volumes that I cut out of other volumes, resulting in new boundaries and faces and all that.

This time, although snappyHexMesh doesn't give me an error, the mesh stays unchanged after execution.

Now, before I post any dicts, full cases or terminal outputs, I want to hear your opinion on this approach. Am I am trying to do something that one simply shouldn't do with snappyHex? At first, this seemed like an easy task, but now I'm not so sure anymore. Do I need to use some kind of other feature from OpenFOAM? I read something about surfaceFeatureExtract, createBaffle and topoSet but I couldn't really find any information that sounded useful to my case.


I know, I can simply achieve my goal by using gmsh, but I've had really bad experiences with gmsh and OpenFOAM when it comes to the performance of the solver that I'll be using. I think it's also possible to already incorporate these wavy splines in blockMesh, but I don't think blockMesh offers any of the snapping and refining of snappyHex, which is why I want to do this with snappyHex in the first place.

Let me know what you think!

Best regards
Finn
Attached Images
File Type: jpg box_only.jpg (157.7 KB, 36 views)
File Type: jpg wireframe_with_sheet.jpg (162.4 KB, 47 views)
finn_amann is offline   Reply With Quote

 


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] Snappy creates strange cells far away from boundary vainilreb OpenFOAM Meshing & Mesh Conversion 3 December 16, 2020 05:11


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