|
[Sponsors] |
March 29, 2024, 04:39 |
Meshing a rock sample
|
#1 |
New Member
Tom SALIC
Join Date: Jul 2023
Posts: 10
Rep Power: 3 |
Hello,
I would like to study the flow of a fluid in a porous rock. The rock is created using the Python library Porespy. After pre-processing, I obtain a file in .stl format. Once I have this file, I use SnappyHexMesh to create the mesh. It should mesh the empty space between the solid grains so that the fluid can flow. Unfortunately, it meshes the surfaces of the elements, so when I apply the fluid at the inlet, it gets blocked by the material. I've tried changing the locationInMesh to place it in an empty space, but it didn't yield the expected results. If you have any ideas, I'd appreciate it. I'm attaching two images to show the geometry as well as the mesh results. Thank you for your help. |
|
April 2, 2024, 05:00 |
|
#2 |
Senior Member
Join Date: Dec 2021
Posts: 246
Rep Power: 5 |
Hey!
If you already managed to mesh the solid part, it means that you probably have a working setup the main thing you should change is the locationInMesh keyword: make sure it is located in the fluid part, and not in the solid part, and snappy should keep the fluid cells. One more thing, the background mesh you use should be slightly smaller than the STL of the porous rock so that the mesh cuts off at the borders. |
|
April 2, 2024, 05:10 |
|
#3 | |
New Member
Tom SALIC
Join Date: Jul 2023
Posts: 10
Rep Power: 3 |
Quote:
Hello Alczem, Thank you for the response. I've already changed the LocationInMesh to the void space, but the problem persists. I tried using the Toposet dictionary to select the cells located on the rock and create the other set defined by the void, but the same issue remains. I'm going to reduce the background to avoid the straight borders. |
||
April 3, 2024, 05:05 |
|
#4 |
Senior Member
Join Date: Dec 2021
Posts: 246
Rep Power: 5 |
Hm, weird! Can you share your blockMesh and snappyHexMesh dicts, and your stl file as well? It will probably help diagnose the issue.
If your stl is okay, topoSet should not be needed to have a decent mesh. |
|
April 3, 2024, 05:18 |
|
#5 | |
New Member
Tom SALIC
Join Date: Jul 2023
Posts: 10
Rep Power: 3 |
Quote:
Hi, Thank you for your help. I can upload my snappyHexMeshDict and blockMesh files, but my stl file is 151 MB in size. I won't be able to share it using the forum.Block_SnappyHexMesh.zip |
||
April 3, 2024, 06:32 |
|
#6 |
Senior Member
Yann
Join Date: Apr 2012
Location: France
Posts: 1,200
Rep Power: 28 |
Just a quick question: are you sure there is no scaling issue with your stl file and locationInMesh coordinates?
OpenFOAM works with meters and CAD softwars usually use mm. It is a pretty common mistake to mix things up and give a locationInMesh in mm instead of meters, or have a STL file 1000 time too big. Best way to be sure: open your stl file in paraview, use the point source with your locationInMesh coordinates and make sure it is really in the void space. |
|
April 3, 2024, 09:33 |
|
#7 | |
New Member
Tom SALIC
Join Date: Jul 2023
Posts: 10
Rep Power: 3 |
Quote:
Thank you for the help, I have already looked at the locationInMesh (I encountered this problem in another case ). As you can see in the attached image, the point is located in an void space. |
||
Tags |
complex geometry, micro flows, porous media flow |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[ANSYS Meshing] only automatic meshing works, | kazra | ANSYS Meshing & Geometry | 2 | February 23, 2017 12:38 |
why does 'sample' do this? wallShearStress question | CHARLES | OpenFOAM Post-Processing | 0 | August 7, 2013 20:30 |
Sample issues | MikePo | OpenFOAM Post-Processing | 1 | February 7, 2010 20:20 |
Best Meshing scheme for Cylinder | Nutrex | Main CFD Forum | 4 | July 29, 2008 12:03 |
Volume Meshing & Face Meshing? singularity of grid | ken | FLUENT | 0 | September 4, 2003 12:08 |