CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   ANSYS Meshing & Geometry (https://www.cfd-online.com/Forums/ansys-meshing/)
-   -   [ICEM] Can't create prism layer on 2D extruded mesh (https://www.cfd-online.com/Forums/ansys-meshing/85233-cant-create-prism-layer-2d-extruded-mesh.html)

PedroC February 20, 2011 21:38

Can't create prism layer on 2D extruded mesh
 
3 Attachment(s)
Hello. I am relatively new to ICEM and I've been searching similar cases on this forum for days with no luck. I'm using 12.1.

I have a problem whenever I try to create a prism layer on my tri mesh. My geometry consists of a rectangular farfield and the body is a train, which is almost touching the "ground" surface of the farfield. I mesh this 2D geometry with tetra and up to this point everything is wonderful and great (BTW it's a tri only and patch independant). Then I extrude the surface with the Extrude Mesh tool, since my solver needs a 3D mesh to work with. Now comes the problem. I want to create a prism layer all over my body to capture boundary layer effects. The problem is that the prism mesher doesn't do anything when I hit Compute. Through a variety of different combinations of meshing and extruding ways, I get one error or another. The most common error is:

shells 32350 and 29061 not consistently oriented

Followed by the not less popular:

expecting 2 shells on edge 36 39 found 3

After showing this messages hundreds of times and alternating one with another, the prism mesher seems to finish succesfully. It even makes the different iterations required to make you think that he is working. But when it's done, nothing has changed and no new volume part has been created. Sometimes eventhough no errors are displayed on the log, but still no prisms are created.

I think I've run every single tool on ICEM trying to find some mesh/geometry singularity, but I couldn't find the root of my problem. I'm attaching 2 pictures and a txt with my prism log so you can understand my problem better. Thanks in advance for your help and I hope someone can throw some light on this.

PSYMN February 21, 2011 09:37

Wrong process.
 
ICEM CFD Prism needs to move tetras out of the way as it inserts the prism layer. Tetras are very flexible. It was never designed to move hexas or prisms or pyramids. Your model is swept prisms, so you can't insert prism (post).

However, you can change the order of operations and still get what you want.

For instance, you could insert the prism while the model is still 2D. To do this, you must go into the Global Parameters for Prism (first icon under the mesh tab and then 4th ICON in the Global Params DEZ), go into advanced settings and turn on "BLayer2D". Then make sure that curves to be inflated have the prism option turned on under "params by parts".

The rest is the same as for 3D prism... You would extrude after your prisms are done.


Or, If you want to generate the prisms with 3D (it probably uses a slightly better algorithm for 3D), you could start with extruding the geometry (to 2.5D really) and then generate a Patch independent Tetra mesh on your model. Then Insert your prisms. Then delete the volume mesh, sides and back face of your model so you are back to 2D. Then Extrude that front face back again to get your swept model...

Have fun with your choice of process...

PedroC February 21, 2011 09:55

Thank you very much for your response Simon. If I try your first option, which I already have, I get the error messages:

shells 10068 and 10068 not consistently oriented
expecting 2 shells on edge 1050 1052 found 1
shells 10069 and 10069 not consistently oriented
expecting 2 shells on edge 1049 1050 found 1

And that goes on over and over. I don't know why but Blayer 2d hates me. About the second option; by extruding the geometry you mean to copy it on a parallel plane with the Transform Geometry tool? Because I can't find an option to extrude a geometry the same way the mesh does. Or perhaps you mean turning off the FLUID mesh part and extrude the remaining meshed curves?

Well, thank you again for your help.

PSYMN February 21, 2011 12:48

Extrude Geometry...
 
You can create two points (vector) and then go to Geometry (tab) => Create Modify Surface => Sweep Surface (with a vector).

This will get you the side surfaces from the curves. You can use Geometry => Transform Geometry to copy the original surfaces by the same vector. You can use the "increment parts" option if you want them to have new part names.

Best regards,

Simon

PedroC February 21, 2011 17:38

Prism
 
Well, I did the following. I extruded the geometry in the first place. I copied the fluid surface on the oposite face in order to have a closed volume. I meshed the volume with a tetra/mixed octree volume mesh. After this I tried to run again the prism mesher, since now I have a tetrahedral volume mesh. No error came out after finishing, but no prisms either.

I also tried, after having extruded the geometry, surface meshing my fluid surface, and then run the prism mesher. I think this case is very similar to an ansys tutorial I did, where you prism mesh a fuselage that is located on a symmetry plane already surface meshed. Unfortunately, the 2 error messages I commented on the previous posts showed again.

I really don't know why I'm having so much trouble with this. The geometry is very simple and I've seen similar cases where prism meshing isn't this challenging. I think the cause may be related to the 2 errors that keep popping up. I'm really lost at this point. Any help would be very preciated. Thank you for your patience reading this post. Regards.

PSYMN February 21, 2011 23:01

Sorry if these questions seem basic, but have you flagged the parts for Prism? (Under parameters by parts)? Have you set a number of prism layers either globally or on parts?

If you have error messages, you could cut and paste them here for help. (I can't always understand them either, but I have a better chance of helping if I have seen them).

Best regards,

Simon

PedroC February 22, 2011 06:16

Prism
 
1 Attachment(s)
Hi Simon. Yes I flagged prism on the Part Mesh Setup and I set the number of layers globally. I'll attach the error log on a txt because it wouldn't fit here. This log is from a 2D surface mesh which I tried to prism with Blayer 2D on.

shanshanbu April 6, 2011 21:19

choose the face
 
1 Attachment(s)
I met the same problem to yours yesterday.I solved this problem in the follwing way.
First,turn on "BLayer2D".Then,the curves and the surface to be inflated have the prism option turned on under "params by parts".
At the beginning,I did not have the surface turned on,and I got the same error messages to yours.

[IMG]file:///C:/icemcfd/2d/New%20Folder/wange.jpg[/IMG]


Quote:

Originally Posted by PedroC (Post 296271)
Thank you very much for your response Simon. If I try your first option, which I already have, I get the error messages:

shells 10068 and 10068 not consistently oriented
expecting 2 shells on edge 1050 1052 found 1
shells 10069 and 10069 not consistently oriented
expecting 2 shells on edge 1049 1050 found 1

And that goes on over and over. I don't know why but Blayer 2d hates me. About the second option; by extruding the geometry you mean to copy it on a parallel plane with the Transform Geometry tool? Because I can't find an option to extrude a geometry the same way the mesh does. Or perhaps you mean turning off the FLUID mesh part and extrude the remaining meshed curves?

Well, thank you again for your help.


shanshanbu April 6, 2011 21:32

1 Attachment(s)
I was inspired by the following thread,thanks to Anderson.
http://www.cfd-online.com/Forums/ans...meshes-2d.html

Quote:

Originally Posted by shanshanbu (Post 302578)
I met the same problem to yours yesterday.I solved this problem in the follwing way.
First,turn on "BLayer2D".Then,the curves and the surface to be inflated have the prism option turned on under "params by parts".
At the beginning,I did not have the surface turned on,and I got the same error messages to yours.

[IMG]file:///C:/icemcfd/2d/New%20Folder/wange.jpg[/IMG]


cjz April 17, 2011 08:37

2 Attachment(s)
Hello All,
I've had limited success at meshing a 2D BLayer on an airfoil (see images). It appears I'm missing something simple. I've tried the "3D way" by meshing a 3D airfoil and then deleting all surfaces except the front face but that was unsuccessful as well so I'm back to tying it in 2D. I'm trying to do a BL mesh with quads and the rest of the domain with triangles. I'm doing this by specifying the parameters under Curve Mesh Setup and then defining those curves to be meshed with prisms. I've also specified the surface to be mesh with triangle and patch dependent. Given this I get the attached images. If I set the domain to have patch independence I just get triangle down the the surface of the airfoil.

Any help at all would be most appreciated. I've been through many forum postings and tried to incorporate all suggestions but still the closest I get is shown in these images.

Thanks for any help anyone can provide!

PSYMN April 18, 2011 11:24

The mesher is failing for your larger loop... Not sure why. Attach the tetin file (if you are ok with that) and someone could take a look...

Also, this isn't really blayer2D, this looks like it is just offset based on curve settings (similar end result).

cjz April 18, 2011 12:29

Hello Simon,
Thanks for your reply. Yes I did use the mesh curve settings (with patch dependence on the surface mesh) in an attempt to build a BL mesh on the airfoil's surface. I'm not able to get a BL mesh using blayer 2d or in any other way. Is there a tutorial or other example that might walk me through the process? I need precise control over the BL mesh quads then triangle from there on out.

PSYMN April 18, 2011 16:42

I don't have a tutorial for that, but I do have one for 2D hexa... Have you seen that on Youtube?

http://www.youtube.com/ansysinc#p/u/17/tYrbScUH9RE

cjz April 18, 2011 17:10

Thanks...I'll take a look

cjz April 19, 2011 04:26

Hello Simon,
I took a look at all three videos...very nice. As you can see from my images above I'm trying to create a mesh using Blayer 2d and then triangles from there on out. I assume this means I don't need to use blocking. Am I correct? I'm trying to keep this as simple as possible. To me that means to define a BL mesh out of quads by defining and initial size, a growth rate, and a the number of cells normal to the airfoil surface. From there I'd like the mesh to be triangles all the way to the far field with a defined maximum cell size. Is this not possible with ICEM?

Thanks for any help you can provide.

PSYMN April 19, 2011 08:11

Correct... The videos show how to do it with blocking to get a structured quad mesh. The method for meshing with tri's and a quad boundary layer is totally different.

But yes, it is very possible. I guess I could look at your model for you quickly and see if I can figure out why it didn't just work for you.

PSYMN April 19, 2011 13:01

Hands on help...
 
OK, I looked, but didn't have enough time to sort it all out and write about it. Here is a start... In the end, I think it is easier to do it 3D and keep the front (3D prism has better options), or to use the hexa method.

Quote:

The first problem I found was some overlapping and unset curves at the back of the airfoil... I built topology to reduce the set to curves attached to the surface (the ones used for the perimeter loop sizing) and found that the upper trailing edge had 2 curves in the Domain part that had no sizes set at all.

So, I put those curves in the AFTop part, then I went into the Params by Parts and checked the box for "Apply inflation parameters to curves", then hit apply.

Then I went to Global Mesh Setup => Shell and changed the Mesh Method to Patch Dependent (it was set to patch independent). I also reduced the Ingore Size down to 0.01 so it wouldn't ignore the trailing edge.

And it still failed... So I went back and turned off the number of layers (reduced it to 0). Then it gave me a mesh. So, it is having trouble with the boundary layers, specifically connecting them back in with the outer mesh. Keep in mind that this "offset" within pat dependent method was designed for making quadrings around bolt holes (for FEA bolt spiders). It was not intended for full blown CFD.

So lets just use blayer2D (designed for CFD). Also, it may be helpful to have a trailing edge curve so the prisms know what to do at the trailing edge... It can also help me refine my wake.

So, I went back to the params by parts menu and set the initial height and growth ratio to zero also... Then regenerate. This gave me decent tri paving, but nothing special.

I then went into Global Prism Setup => Advanced Prism Meshing parameters and turned on Blayer 2d.

To add my trailing edge curve, I turned on points.

I went to Geometry => Create Points => Parameter along a curve. This defaults to 50% and I selected the outlet curve. This created a new point at the mid point of that surface.

Then I created a curve from points. I started with the end of the airfoil. I wanted this to curve down a little so I selected a second point in the field below the surface iso curve, then I selected the mid point of the outlet as the third point and hit the middle mouse button. This gave me a nice curve. Maybe I went too low or should have included a 4th point to straighten it out further down... Actually, just right click to undo the last couple points (actually hit undo if you already accepted the curve), and lets recreate with a 4th point... Ahh, that looks better.

Now we run Repair Geometry => build diagnostic topology again with a tolerance of 0.001. This will cut in our new curve. (it will turn red to indicate it is connected)

Since the curve started with the end point of the airfoil and since I had its part set to inherited, it was in the AFTBOTTOM part. Lets change that to a unique Part. This is the only curve in that part, so go into Params by Parts and select it for Prism. When it comes to BOCOS, this will be internal, but I will probably just delete the line elements anyway.

Now we need to setup the curve params on this new curve. Since it must join very fine mesh with very coarse mesh, we will setup a biasing. Go to mesh => Curve mesh setup. Select the new curve. I set the number of nodes to 50, which was just a guess, but it turned out well. I scrolled down and set the Advanced Bunching Meshing law to Geometric1, Spacing 1=1, Ratio1 1.2. Apply.

Then I went back to compute mesh => Surface Mesh, hit apply. Maybe the 50 wasn't quite enough or maybe I should have used bigeometric to set the other side equal to the size set on the output wall, Oh well, never mind now. Lets keep going

(But then I hit prism and it didn’t work as expected, I will need to look closer at the prism params, etc. and try to figure out the problem. So I turned back on the patch conforming offset and that worked... Sort of. But I could get better mesh with 3D Tetra/prism or 2D blocking... Anyway, I will try to get back to it later.)

PSYMN April 19, 2011 13:02

Pics...
 
Deleted pics

PSYMN April 19, 2011 20:46

Done as a volume mesh...
 
2 Attachment(s)
I was asked how to make the trailing edge *without* the tail of quads to the outlet. No problem, we can just break that curve into segments. Put the segment closer to the airfoil in a part to be prismed and don’t prism the other part. The tail gives prism room to stairstep off.

There was also a problem with the geometry. The curves wouldn’t “subtract from the rectangular “far field” domain”. I just avoided the whole problem. Here are my steps.
1) Copy one of the FF corner points about one or two Coarse elements out from the wall. The largest size in the model was 80, so I offset one corner point by 100 units in Z using Transform=>Translate => Explicit with Copy on. (in retrospect, 100 was a bit wider than it needed to be since I later reduced the max size to 64)
2) Then I went into Create/Modify Surface => Sweep Surface => Vector thru two points. I selected all the curves.
3) The surface creation on the other side probably failed because that airfoil is made up of some many little segments (lots of places for something to go wrong). So just skip all that drama and copy the original surface the same way we copied the point. Name the new side “Junk” or something like that since it will be thrown away.
4) Build topology at the end to sew everything together. Since we will be using Octree and don’t need all the little junk surfaces that make up your airfoil, don’t forget to turn on the option to filter out curves and points. Otherwise the octree mesher will get nodes stuck on these later and quality will be limited.
5) Under Mesh (tab)=> Part mesh setup, don’t forget to turn on the trailing edge baffle as an “int wall”. Without this internal wall setting, the elements will be automatically removed. I also set that part to have a size double that of the airfoil, but with a tetra width = 3 setting to help refine the wake region. While I was in there, I set powers of 2 for the inlet and outlet, top and bottom, original surface and new Junk surface. I used 32 on the inlets and outlets, 64 elsewhere.
6) Since we are now dealing with 3D, we can use the octree tetra mesher and the curvature and proximity sizing. Set those up under Global mesh params. I set the Global Max size to 64, turned on curvature and proximity based refinement, set the min size limit to 0.5 and the refinement to 12. Apply.
7) Compute mesh => Volume Mesh => Tetra Mixed => Octree. Compute.
8) The mesher does its own smoothing, but I recommend a few more iterations of Laplace smoothing (set upto to 0.6, run 10 iterations). Then end with one last run of 5 iterations without Laplace.
9) Run Check mesh and make sure you have no serious problems. You can ignore multiple and single edges and just remove any unconnected verts…
10) For Prism, I set the initial height to zero and the total height to zero… This lets the prism float based on the base height and leads to better volume transitions… I set the max prism angle to 165 so it wouldn’t try to wrap around the end of the trailing edge curve (it will stair step off instead). If you wanted to set a trailing edge initial height on the curve to the rear of the trailing edge surface, you could cause a transition to a coarser size… but I didn’t take the time to set that up. Make sure to turn off blayer2d if it is on.
11) Back to compute mesh => Prism mesh. Make sure the right parts are selected for Prism layer (airfoil and trailing edge surface), compute.
12) Next, I would delete all the volume elements (Edit mesh => Delete, then select all the volume elements with the tool bar. Then I would turn the model sideways and delete all the mesh except the original 2D plane. Don’t forget to keep the line elements since those are your bocos…

Any questions?

PSYMN April 19, 2011 20:48

Oops, one more step. Delete the line elements in the trailing edge part. otherwise it will appear as an internal wall in the solution, and you don't need it at all.


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