CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Native Meshers: blockMesh (http://www.cfd-online.com/Forums/openfoam-meshing-blockmesh/)
-   -   blockMesh-how to use prism (http://www.cfd-online.com/Forums/openfoam-meshing-blockmesh/122845-blockmesh-how-use-prism.html)

bieshuxuhe August 29, 2013 08:34

blockMesh-how to use prism
 
Hi, I am a beginner.
I know how to use hex in blockMeshDict because user guide has told us.
for example: hex (0 1 2 3 4 5 6 7) (20 20 1) simpleGrading (1 1 1)

But I wonder how to use prism in blockMeshDict, as user guide doesn't tell us!
I don't know where to find how to use "prism" .
Could you help me?

Thank you!

wyldckat September 1, 2013 17:17

Greetings bieshuxuhe,

It's explained in the section "5.3.3 Creating blocks with fewer than 8 vertices": http://www.openfoam.org/docs/user/blockMesh.php

edit: I see you've gotten the answer here: http://www.cfd-online.com/Forums/ope...tml#post448744

Best regards,
Bruno

CFDUser_ March 31, 2014 08:25

Quote:

Originally Posted by wyldckat (Post 449254)
Greetings bieshuxuhe,

It's explained in the section "5.3.3 Creating blocks with fewer than 8 vertices": http://www.openfoam.org/docs/user/blockMesh.php

edit: I see you've gotten the answer here: http://www.cfd-online.com/Forums/ope...tml#post448744

Best regards,
Bruno

Dear Burno,

Is there any way to make uniform cell distribution in prism?

Like this (http://www.cfd-online.com/Forums/ope...blockmesh.html)

Thanks

Regards
CFDUser_

wyldckat April 1, 2014 15:16

Quote:

Originally Posted by CFDUser_ (Post 483006)
Is there any way to make uniform cell distribution in prism?

Like this (http://www.cfd-online.com/Forums/ope...blockmesh.html)

Quick answer: AFAIK, it's not possible to do it in an easy way. You'll have to build the prism manually with several blocks.

CFDUser_ April 2, 2014 00:36

Quote:

Originally Posted by wyldckat (Post 483293)
Quick answer: AFAIK, it's not possible to do it in an easy way. You'll have to build the prism manually with several blocks.

Can you explain little more?

wyldckat April 5, 2014 18:57

Quote:

Originally Posted by CFDUser_ (Post 483358)
Can you explain little more?

It's simple... well, sort-of simple. The triangular prism feature in blockMesh is actually a squished quadrangular prism, on one of the sides. Therefore, the only way to create with blockMesh such a prism which is shown in the post, namely this:
http://www.cfd-online.com/Forums/att...form-prism.png

Is to build it in parts, namely by using:
  • 1 large quadrangular prism
  • + 2 smaller quadrangular prisms
  • + 4 triangular prisms
The other possibility is to use splitMesh, which means that you first need to create a normal mesh and then split it diagonally.


I suggest that you try using SwiftBlock instead of creating the "blockMeshDict" manually: http://openfoamwiki.net/index.php/Contrib/SwiftBlock


Best regards,
Bruno

CFDUser_ April 10, 2014 01:46

Quote:

Originally Posted by wyldckat (Post 484076)
It's simple... well, sort-of simple. The triangular prism feature in blockMesh is actually a squished quadrangular prism, on one of the sides. Therefore, the only way to create with blockMesh such a prism which is shown in the post, namely this:
http://www.cfd-online.com/Forums/att...form-prism.png

Is to build it in parts, namely by using:
  • 1 large quadrangular prism
  • + 2 smaller quadrangular prisms
  • + 4 triangular prisms
The other possibility is to use splitMesh, which means that you first need to create a normal mesh and then split it diagonally.


I suggest that you try using SwiftBlock instead of creating the "blockMeshDict" manually: http://openfoamwiki.net/index.php/Contrib/SwiftBlock


Best regards,
Bruno


Dear Bruno,

I am not looking for 1big hex+2small hex and 4 triangular blocks. I want grading as shown in the figure. I tried all the ways but getting squeezed cells to one corner of the triangle.
If you dont mind can you post blockMeshDict file n series of operations i have to follow. Sorry for struggling but i dont want to do it in blender because i have to try different triangle angles for my problem. for that i can write script file for generating it automatically. all i need now is how to do it in blockmesh.

Thankyou,

Regards
CFDUser_

alexeym April 10, 2014 03:15

Hi,

do you REALLY need prisms? As the geometry you've shown can be easily meshed with hexagons.

CFDUser_ April 10, 2014 03:36

Quote:

Originally Posted by alexeym (Post 485128)
Hi,

do you REALLY need prisms? As the geometry you've shown can be easily meshed with hexagons.

Hi Alexeym,

Yes, i need prisms as shown in the attached figure (all four sides in 3D) and i have to play with different theta.

CFDUser_ April 10, 2014 03:51

1 Attachment(s)
Quote:

Originally Posted by alexeym (Post 485128)
Hi,

do you REALLY need prisms? As the geometry you've shown can be easily meshed with hexagons.

Hi Alexeym again,

problem is grading. One can make prisms using blockMesh, but grading will be something like in the attached fig.
http://www.cfd-online.com/Forums/dat...KKKKACiiigD//Zhttp://www.cfd-online.com/Forums/dat...KKKKACiiigD//Z



i want to make grading like in the below fig
http://www.cfd-online.com/Forums/att...form-prism.png

I want it to be done in blockMeshDict. If its possible please help me.

Regards
CFDUser_

alexeym April 10, 2014 03:59

Still not sure if I get you correctly.

You need to construct a mesh which consists of a cuboid block and a prismatic block to simulate something. (You can create fully hexagonal mesh for the geometry you've attached)

OR

You need a mesh with the prismatic cells at the edges to check how good OpenFOAM at dealing with this type of meshes (AFAIK blockMesh can't automatically build the mesh you've shown in your figures. Well, that's more-or-less what wyldckat said already).

CFDUser_ April 10, 2014 04:09

Quote:

Originally Posted by alexeym (Post 485143)
Still not sure if I get you correctly.

You need to construct a mesh which consists of a cuboid block and a prismatic block to simulate something. (You can create fully hexagonal mesh for the geometry you've attached)

OR

You need a mesh with the prismatic cells at the edges to check how good OpenFOAM at dealing with this type of meshes (AFAIK blockMesh can't automatically build the mesh you've shown in your figures. Well, that's more-or-less what wyldckat said already).

1st one. i need cuboids and prisms to define my geometry. Defining them in blockmeshDict is pretty straight forward. using simpleGrading i need somthing like in the attached pic.

blacklines define geometry and red lines define grading.

Thankyou

alexeym April 10, 2014 04:26

1 Attachment(s)
Well,

see my suggestion about splitting your mesh into hexagonal blocks in the attached picture. Arrows along the sides show grading direction (hope I get right what you need).

In general you'll need to define separate patches for top cuboid surface (patch-c in the picture) and prism bottom surface (patch-c in the picture). And then use mergePatchPairs or stitchMesh to merge these patches (so there's no obstacle between prism and cuboid).

CFDUser_ April 10, 2014 04:38

Quote:

Originally Posted by alexeym (Post 485149)
Well,

see my suggestion about splitting your mesh into hexagonal blocks in the attached picture. Arrows along the sides show grading direction (hope I get right what you need).

In general you'll need to define separate patches for top cuboid surface (patch-c in the picture) and prism bottom surface (patch-c in the picture). And then use mergePatchPairs or stitchMesh to merge these patches (so there's no obstacle between prism and cuboid).

Hi Alexeym,

I tried this already, but the problem is im getting the skewed cells at point P as shown in the attached fig. to avoid that i need triangular cells. thats what i mean by different kind of grading in prisms.
Anyway thanks for the help. :) Thanks a lot for your time.

Regards
CRDUser_

bullmut August 7, 2014 03:17

Hi Foamers

So when i read through this thread, you guys keep using the keyword hex
In the user documentation there is a keyword prisim.
Am i incorrect in assuming the difference between them is
hex (0 1 2 3 4 5 6 7) ( )...
prism (0 1 2 3 4 5) ( )...

If this is the case can i have a prism and hex block in the same mesh?

/* I have removed the prism entry from my file, it works now.
But still not sure how to use prism as an option*/

wyldckat August 11, 2014 10:41

Greetings bullmut,

According to the documentation: http://www.openfoam.org/docs/user/blockMesh.php - currently only the "hex" blocks are supported. If you want a prism (a "wedge", according to the documentation), you'll have to repeat 2 vertex indexes, as explained in the subsection "Creating blocks with fewer than 8 vertices".

The possibility to use other names was left open for other keywords so that other new blocks could be implemented, but I guess no one ever funded such an effort, possibly because configuring "blockMeshDict" files can be pretty hard to do, specially if done manually.

Best regards,
Bruno


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