You are on page 1of 24

ICEM 102

ghazlani m . ali

Understanding the tutorials May 2013 version 1.0

Ghazlani M. Ali: ICEM 102, Understanding the tutorials, c May 2013

Teachers open the door but you must enter by yourself Chinese proverb

INTRODUCTION

Before going any further, i would like to inform the reader that Im far from being an experienced ICEM CFD user with some ten years of experience. I have started not even three years ago, every time i had problems with the software, i went online and asked for help on cfdonline.com. A great community is there, which without them, probably this book would have been absent. The tutorials available in Ansys customer portal are the real deal. Sometimes, you tend to follow the instruction without knowing whats happening. The purpose of this book is... lets say to bring a sense to all of what you are doing. To explain why we do this or that. I will also include some interesting features not covered in the tutorials. Many thanks go to the people in cfd-online, i have learned a lot with you guys, gratitude. Mistakes will be made throughout the book. English is my third language, please bear with me...

iii

CONTENTS

i a guide to the graphical interface 1 working efficiently 2 1.1 Organization 2 1.2 Useful buttons 2 ii geometry 4 2 geometry 5 2.1 Parts 5 2.2 Bodies 5 2.3 Curve and surfaces

iii the mesh 8 3 unstructured mesh 9 3.1 Good geometry 9 3.2 Flow of work 9 3.3 Adding an interior wall 10 3.4 Mesh Algorithm 10 3.5 Never too late to change the boundaries 11 3.6 The Edit Mesh Tab 12 4 structured mesh 14 4.1 Introduction 14 4.2 blocks can be parts 15 4.3 Useful links 15 5 merging an unstructured mesh with a structured mesh 17 6 conclusion 19

iv

LIST OF FIGURES

Figure 1 Figure 2 Figure 3 Figure 4 Figure 5 Figure 6 Figure 7 Figure 8 Figure 9 Figure 10 Figure 11 Figure 12 Figure 13 Figure 14 Figure 15

The tabs 2 Holes to be grouped 5 A look at the mesh... 6 Difference 6 Difference 7 The mesh tab 9 The global mesh parameters 10 Interior wall 10 Select mesh elements tool 11 Select geometry tool 11 Selected boundary 12 Before and after 12 Duplicated mesh 13 Before and after 17 Before and after 18

Part I A G U I D E T O T H E G R A P H I C A L I N T E R FA C E
There is a lot of tabs in ICEM CFD, its all about ordering your work, You will always navigate those tab from left to right. Take some time and read this part to learn more about the steps of creating a mesh

W O R K I N G E F F I C I E N T LY

1.1

organization

The graphic interface in ICEM CFD is made so people do not get lost when working in it, but yet if you are just starting in cfd, you WILL GET LOST. here is what you need to understand: The steps by which we go through are pretty simple: 1. One starts by creating, or importing and modifying its geometry. This is why the geometry tab is rst in the row. Everything there is related to creating, deleting, and changing the points, the surfaces, and the curves. 2. Next is the Mesh tab. This is where the parameters of the mesh will be specied: size of element, what kind of meshing technique one wants to use, each of the parameters can be applied in a global scale, or for a particular part of your geometry, this why we nd "surface mesh" or "curve mesh" tab. 3. Next is the blocking tab, this is to be skipped if you are planing an unstructured mesh (for the moment). There are some times when the blocking tab can be used along the mesh tab, but that will happen when youll level up your knowledge in ICEM CFD. 4. When your mesh is generated, you will have to improve its quality, may be duplicate it, delete it, and many more editing. The edit mesh is there for that. So you will play with that tab when you have a generated mesh, and not before. 5. Finally when everything is ready to be transfered to your solver, you will then use the "output tab", the name speaks for itself, there you will assign the boundary conditions and create the mesh le to be imported in the solver

ICEM 102 version 1.0

Figure 1: The tabs

1.2

useful buttons

There are some very useful buttons there, you will get the chance to use them all while discovering the software, or after reading this book...

1.2 useful buttons

Most of them deal with "how to efciently select and entity". There are many, i will only cite the most useful ones. The more we advance in this book, i shall explain more. Let us take our cube, as we all know, the cube has 6 faces (surfaces), 8 corners (points), and 12 edges (curves). The toggle selection buttons make the job easier by letting you pick only the entity you desire. Two more buttons you may want to use: All entities Only visible all entities will even select the objects that are not displayed in your screen, very useful if you wish to delete "everything". only visible lets you buy some time if you wish to select all surfaces that are displayed on your screen when you have ONLY those surfaces shown. Again, if your points are displayed (checked in the tree menu) and if you hit that button, surfaces AND point will be selected... just to make sure you got it ;)

Part II G E O M E T RY
When just starting with ICEM CFD. One has to understand the important of having a perfect geometry. As seen later, the algorithm behind generating a mesh depends on knowing the curves, points and surfaces of the geometry so mesh boundaries can be applied. If the geometry is bad, absence of curves, or overlapping surfaces, the resulting mesh -if generatedmay just not be the one you wanted.

G E O M E T RY

Icem Cfd is good in importing geometries, but not creating ones. Unless you want to draw a box, a sphere any simple body, it is better to just use the importer. Using the workbench reader, i never failed in importing an IGES, STEP or a workbench geometry. 2.1 parts

One of the coolest feature in ICEM CFD is to create a part. Parts can be anything: curves, surfaces, bodies, points and even a mix of all of them them. The main reason why we create part is to dene boundary condition for the curves (in 2D) and for the surfaces (in 3D). Im not sure if it is available in the tutorials or the training materials but here is one more useful feature to use the create part which will give you some more insights and understanding. Lets say we have a group of holes as shown in the picture below: While meshing this, Figure 2: Holes to be grouped you boss expect from you to put a minimum a 20 nodes in each og the curves representing the holes. As you begin with ICEM, you will probably select individual curves and assign them the 20 nodes. Here is where the create part will be useful: select create part, toggle on (only curves) and select all the curves that matter. Name that par "group_curves". Now you have one part that includes all those curves and if you go to Mesh Tab -> Mesh Curve -> Select Part -> "group_curves" and Number of nodes-> "20" : it will assign 20 nodes for each curve there. Now you are using ICEM CFD efciently. 2.2 bodies

Whats a body? Why creating a body ? I will try to explain it by a very simple example: gure 2 shows a cube inside another. Think of it as a metal box suspended in the air. I decide to create a body outside of the inner cube and name it "AIR". If i generate a mesh. The gure below shows how it will look like. We notice here that the elements created will propagate until surfaces

2.3 curve and surfaces

Figure 3: A look at the mesh...

are met. They will not cross the surfaces. I now have a convenient way to tell my solver FLUENT -for example- that everything outside of the inner cube means air. Now, What if i want to study the temperature prole inside of the box. I need to tell my solver that i have aluminum inside of it. More over, i need to go back to Icem and create a body inside the inner cube, and call it "Aluminum". the gure below shows the resulting mesh composed of two bodies.

(a) One body

(b) Two bodies

Figure 4: Before and after.

I hope you could get this interesting concept. Bodies can be used for too many reasons, and it will be up to you to exploit this feature in the future. Lets move on to put into practice the use of the curve and surface features. 2.3 curve and surfaces

REMINDER: if we have a square surface, then we have 4 curves, and 4 points acting as boundaries. Simple right? I wanna show now how i can change my geometry by using them in order to have different inlet. Figure 5 shows a face of a cube, that face represents an inlet of air. What if i want to add a small window where the air will enter, and declare all

2.3 curve and surfaces

the other boundaries as wall. This can be easily done by going through the following steps below: By doing so, and after generating the mesh. I will have two distinctive faces and i can move on to the solver to assign whatever boundaries i want.

(a) Added points

(b) Added curve

(c) Surface split

(d) Generated mesh

Figure 5: The steps for splitting a mesh.

Part III THE MESH


Mesh can be structured or unstructured or both. In 2D, we tri elements for the unstructured and quad elements for the structured. In 3D, we have tetra elements for unstructured and hexa for structured. Penta elements are presents when prism has been generated...

UNSTRUCTURED MESH

I will not get into every details on how to generate an unstructured mesh because it is well covered in the tutorials and the training materials. I want to show some additional features that will let you avoid starting a thread in the cfd-online forum. I will cover: adding wall, converting the mesh to a delaunay, checking the quality, creating part for mesh and some more the Edit Tab. 3.1 good geometry

Before going any further, we have to make sure that we have a good geometry. Mesh generation will fail if holes, and open surfaces are presents. 3.2 flow of work

The gure below shows whats under the Mesh tab. One of the rst thing to do is starting by giving a global element seed size. By global it means that everywhere in your geometry you will not get an element bigger than what you have specied, for precaution. Always under the Mesh

Figure 6: The mesh tab

tab, the ow of work goes from left to right. After you select you global parameters, you move on to "customize" your mesh on individual entities. If you want to set a max size of 1 for a certain wall, and a max size of 12 for another entity, you can do that under the part mesh setup. if you want to apply a special meshing method on a specic surface, or to apply a specic sizing, you can do that under the surface mesh setup. The Curve mesh setup let you add a specic node law distribution to a curve. This is where you specify the number of nodes as seen in chapter 2 section 1.

3.3 adding an interior wall

10

Figure 7: The global mesh parameters

3.3

adding an interior wall

Let us consider our cube example: as we saw in chapter 2 section 3, we used tow bodies (one inside the inner cube) and one outside the inner cube (the metal box surrounded by air) What if i have a surface inside the cube, as shown in gure 8, and that i wish to consider that surface as a wall in my simulation. ICEM CFD will ignore that surface if you dont specify it as wall. Even if it looked like the mesh was successfully generated, you will not see your surFigure 8: Interior wall face in the solver, because no shell element are associated to it. Lets see how we can avoid this: I will start by putting my surface into a part and call it "wall_inner_cube", we click on Mesh tab->Part Mesh Setup, then we check int wall for our wall_inner_cube. Hit Apply then Dismiss. Thats it, our mesh is generated and that surface is taken into account . A typical example for this case can be a ow over vertical plate ;)

checking the internal wall

3.4

mesh algorithm

Our mesh was generated using the Octree mesh method. Personally, i often convert it to a delaunay mesh, the latter tends to generate less node, and is more suitable for CFD simulations. In opposition to the Octree Method, the Delaunay Method takes root from the surface, making it way up to ll the hole geometry. That being said, if you want to generate a delaunay mesh without passing through the Octree method, you need to have your surfaces meshed. To get the delaunay mesh, head to Compute Mesh under the Mesh Tab, and select Quick (delaunay) instead of Robust Octree, click Compute.

3.5 never too late to change the boundaries

11

3.5

never too late to change the boundaries

Now we have a beautiful mesh. But still we are not ready to export it. In fact, we forgot to dene the boundary condition. We usually name a surface -part- as inlet, then we generate the mesh. The interesting fact to understand here is that all the shells and the superimposed surface will form one part, and that will be inlet. If i delete that part, the shell and the surface will be deleted. That being said, we show again that a part can be shell elements too, deleting that part will result in deleting the surface and the shells. below is a quick demo on how to dene a group of shell as a boundary: 1. Right click on part, then select select new part 2. Give a name to your part (boundary), something like INLET 3. click on Select entity, things get interesting here, you need to know that there is two kind of windows for selecting elements, shown below, one is to let you select entities for geometry, and another one for mesh elements, you can toggle between them using the button framed in blue:

Figure 9: Select mesh elements tool

4. Im introducing here a few more useful button to help you select what you want. If you click on surface elements (framed in red), this will select all the shell elements, they can be either quads or tri. In our example, they are TRI since we used an unstructured mesh. Similarly, the button next to it is for Volume elements. i will use that button if i would like to delete my volume mesh and leave the surface mesh so i can generate a Delaunay mesh for example. If you know the parts name, click on the button framed in pink, all entities belonging the that part will be selected.

Figure 10: Select geometry tool

5. With the select mesh elements turned on, notice what happens if you click on any tri elements, followed by all item attached to selected element, up to angle, the entire boundary will be selected as shown in gure 7. Thats it, we have now an INLET ready to be set in the solver after the output is done.

3.6 the edit mesh tab

12

Figure 11: Selected boundary

3.6

the edit mesh tab

Sometimes, it is good to anticipate matters and spend less time dealing with the geometry. We all now how cylindrical geometries are generation, its all about revolution around a specic axis. Once a mesh is generated, ICEM CFD can extrude it, copy it, scale it and rotate it. Knowing this, why not mesh just one sector ? Consider the geometry shown below. Here, i have used a structured mesh by blocking a portion of my geometry.

(a) A sector

(b) full meshing

Figure 12: Before and after.

3.6 the edit mesh tab

13

The quality is not great, the purpose of it is just to show you the capabilities of the Edit mesh tab. I will then mirror it twice to get the nal geometry. The steps are very easy, under the Edit mesh tab, click on Transform mesh-> Mirror -> Select all. In our case, we want to get the a hole 360 geometry so we need to check copy1 . Below again, a pattern was created using the copy and translate feature. Very easy and time saving !

Figure 13: Duplicated mesh

1 One more example on the use of the Edit Mesh tab:


http://www.cfd-online.com/Forums/ansys-meshing/107222-heat-exchanger-too-much-fins. html

STRUCTURED MESH

4.1

introduction

This is tough to explain. One way to get a structured mesh in icem CFD is to block your geometry. It all start by one block initialized, then it is split into multiple blocks, to nally adapt it to the geometry. For one geometry, there can be multiple blocking strategy, it is the reason why it is hard to cover it, and no matter how many geometries I show, you will always end up with one different that the other, and it will require some time to come up with a blocking strategy. Some thinks that it like a gene, you either know how to block or you dont. I personally dont think so. You need to know that there is no special recipe to master it, or there is only one way: practise on geometries as much as you can. Cfd-online is full of people seeking help, even if you cant help, try. And see the solution from those who helped. Another important point: when you block your geometry you dont actually create a mesh, it is more like a scheme. To have a mesh, you need to right button click on blocking and select convert to unstructured. Someone once asked this question in cfdonline: why do I always have to convert my mesh to unstructured even if its structured ? It seems confusing what icem calls a unstructured mesh is every mesh you can edit using the edit tab and you can output. As I said before, when you dont convert your block , you dont actually have a mesh, you cant extrude it or scale or do anything under the edit tab. I hope I made myself clear, if not... Just keep doing it, one day youall get it ;) It is true that a structured mesh is more acurrate, I found the size of its .msh le much smaller also. Because generating one requires time and expertise I often start by an unstructured mesh, see how it behaves during the simulations , if I get a lots of warnings when performing iterations , I will try to make a structured mesh meanwhile waiting for the results. Here are some rules that will help you get a good blocking: when you split a lot, avoid confusing by using the index control. It may seems difcult to use the numbers to lter the blocks you want at rst sight, so instead, use the select corners option, it is sometimes difcult to select the blocks you want, I usually right button click on block and select solid. It makes it easier to look through than having them set to wire frame you get a good quality when the vertices are aligned, there are many ways to align the vertices, take some time to discover how. It is not difcult at all.

14

4.2 blocks can be parts

15

a blocking can look beautiful, but its quality can be very bad. That is a problem from the inside.use scan plane after lest mouse click on premesh to identify where does the problem come from. 4.2 blocks can be parts

Remember the concept of bodies, the purpose of having different bodies ? When using a structured mesh, if you want to differentiate between different block, you can do that by right button click on create part then click on blocking material, create part as shown in the margin. This will result in having different materials in your solver. 4.3 useful links

I tried to gather all the icem cfd related videos on youtube. some of them are mine, some from ansys, but the majority are from a channel called turboengineer. The creator of the channel is a dedicated cfd engineer, very well known among the cfd-online community. He goes by the name of FAR in the forum. A special thank for all these link... ICEM CFD basics The 3D hexa elbow tutorial The Hexa airfoil in 2D Wing with sharp trailing edge Cylinder 2D to 3D Injector Cylinder Cylinder inside cylinder Meshing of complex cylinder Introduction to quarter o-grid Meshing of elliptical cylinder Sphere cube tutorial Meshing of ahmed body (and simulation) Backward step with downstream rectangular inclined plate Mirroring block and geometry around symmetry plane 2D to 3D via rotation Blocking strategy for cruciforms ns

4.3 useful links

16

LES ICEM CFD blocking Supersonic intake hexa

MERGING AN UNSTRUCTURED MESH WITH A STRUCTURED MESH

From time to time. we can come across geometries that can be decomposed in 2 parts: a difcult part impossible to block. Another one where blocking is pretty much doable. In this case, it is possible to merge a structured mesh with and unstructured one. Another scenario: using a structured mesh obliges us to have a dense region even when we dont really need it. It is practical to use large elements near the entrance and rene the more and more we approach our object of interest. The gure below explains very well what i mean.

Figure 14: Steps.

Here are the main steps on how to perform this operation: 1. Start by generating your unstructured mesh 2. When your blocking is nished, convert it to unstructured mesh. Icem will ask you if you want to replace your existing mesh or merge, hit merge. Merging allow two meshes to coexist. 3. under the Edit Tab, click on Merge nodes, then Merge meshes. The nal step will be to select a surface. That surface should contain both the unstructured and the structured elements.

17

merging an unstructured mesh with a structured mesh

18

I usually call that surface "interface". And be careful with this technique, size matters here, your TRI and Quad should be of the same size (Tri 1.3 bigger than Quad) otherwise the mesh quality will be bad. Since i love to see things in action, let us apply this to our cube inside cube, here are some screen shots:

(a) A sector

(b) A sector

(c) A sector

(d) full meshing

Figure 15: Before and after.

CONCLUSION

6
http://goo.gl/9BkiO

That was it for this small documentation. This is the rst version of this book, yet more has to be added later, i will update this book with new informations regularly. To be honest, i was too excited to put it on-line. Of course, everybody who wishes to participate in the writing of this book is more than welcome. Just send me and e-mail. I need your support to continue with updating this book. I will feel very happy if I can get some feedbacks and critics in this website:

Thank You

19