CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [snappyHexMesh] Create Cylinder (HOLLOW NO MESH OR CAVITY) inside a Cuboid (https://www.cfd-online.com/Forums/openfoam-meshing/191280-create-cylinder-hollow-no-mesh-cavity-inside-cuboid.html)

saddy August 5, 2017 10:25

Create Cylinder (HOLLOW NO MESH OR CAVITY) inside a Cuboid
 
1 Attachment(s)
hello foamers
i have an interesting problem to discuss with you all.
1. i am having a cuboid of 10 cmx 10 cmx 10cm...which i can easily make in blockmesh.
2. i have to create a cylinder which lies entirely inside the cuboid close to the bottom. its dia is 1 cm and length 6 cm so it lies inside the cuboid.
3.i have to give boundary condition to this cylinder surface. so its a wall here

how do i delete the mesh of this cylinder, the cylinder is not supposed to have mesh inside
how do i define a patch of cylindrical surface, so i can give bc in 0 folder

the issue is: i cannot do so using blockmesh which is very tiring and prone to mistakes

i am trying to use cell set by deleting the cells using cylinder to cell
and define a patch using cylinder to cell
but i don't know exactly how to write this procedure using toposet dict
please help me foamers
i really need to get this done

saddy August 6, 2017 06:10

1 Attachment(s)
i'm so glad i did it...
however i ran into another minute issue
when i create the cylinder
the mesh around it is irregular and nott a perfect circle.
how ca i smooth these faces to get the smooth circle...not exactly..but how can i improve this??
collapse edges or what??
image is attached here

saddy August 6, 2017 14:08

i tried more refinement but still the circumference of circle contues to be irregular
my conclusion is: it can't be done using refinement or toposet or blockmesh
only way is
use .stl file of cylinder inside a cuboid
next use snapphexmesh to get the job done
will keept his thread updated

Antimony August 7, 2017 21:19

Hi,

If you know there is going to be cylinder in your geometry, then you can use blockMesh to create a mesh that has a cylinder. That way you can avoid the issue with irregular cells.

Cheers,
Antimony

saddy August 8, 2017 10:15

Quote:

Originally Posted by Antimony (Post 659814)
Hi,

If you know there is going to be cylinder in your geometry, then you can use blockMesh to create a mesh that has a cylinder. That way you can avoid the issue with irregular cells.

Cheers,
Antimony

i know can be done using blockmesh. but there is a problem. to get a cylinder completely inside the cube. you have to create different regions and write their numbering and its a whole lot tedious. job and once you get your numbering wrong/mistype. blockmesh will kill you with flurry of errors.
i am thinking about using snappy hex mesh using .stl file
if u have any simple beginner tutorials using a cylinder, could you point me in that direction???

Atefeh T August 8, 2023 07:10

Hi, can you please explain how did you extract the mesh inside the cylinder from your general mesh?


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