OpenFOAM/C3/Unstructured-mesh-generation-using-Gmsh/English-timed
From Script | Spoken-Tutorial
Revision as of 17:16, 27 November 2015 by Pratik kamble (Talk | contribs)
Time | Narration |
00:01 | Hello and welcome to the spoken tutorial on Unstructured Mesh generation using GMSH. |
00:06 | In this tutorial we will learn to
|
00:18 | To record this tutorial I am using
|
00:30 | This tutorial is a continuation of :
Creation of sphere using GMSH |
00:35 | We have already learnt to create a sphere using GMSH earlier.
|
00:40 | If you don't know how to do so, refer to the GMSH spoken tutorials in the OpenFOAM series on this website. |
00:48 | Here is our problem statement.This picture shows the flow direction and boundary faces.
We will now learn how to create an unstructured mesh using GMSH. |
01:01 | Note that the size of the domain is 45 X 30 X 30, and the radius of the sphere is 1.However, these dimensions can vary from problem to problem.The points for the domain are as shown here. |
01:18 | Let us switch to GMSH now.Here is the sphere we created earlier. |
01:24 | I have also created all the points and lines of the domain.To create the points of the domain, kindly refer to the tutorial mentioned earlier. |
01:36 | Now, select the option plane surface. Then select the respective edges for the surface. The selection will be displayed in red. |
01:48 | Press E on the keyboard to execute the selection.On doing so, we can see the dotted lines. |
01:57 | Repeat the process until all surfaces are created. |
02:02 | Now, select the option Physical Groups, then Add and then surface. |
02:10 | Now, select these four faces for the wall and press E on the keyboard. |
02:17 | Select the front face for inlet and press E. |
02:21 | Select the back face for outlet and press E. |
02:26 | Now close GMSH. |
02:29 | Now, open the sphere1.geo file in gEdit Text Editor.Note that there are additions to this file.
Also note that the identification numbers for the entities is in continuation of the earlier series. |
02:47 | As done earlier, replace the numerical values.Use the letter d for the domain mesh variable. |
02:56 | Then, at the beginning of the file type d = 0.5; |
03:02 | To name the boundaries, change the numerical value with your desired name, as demonstrated. |
03:09 | The first physical surface, we made in the interface was wall.So, here, we will replace it with wall. |
03:18 | The second physical surface, we made in the interface was inlet.Hence, here, we will replace it with inlet. |
03:27 | The third physical surface, we made in the interface was outlet.So, here, we will replace it with outlet. |
03:36 | Now type, Surface Loop, ID which is the next integer in round brackets equals the IDs of all surfaces of the domain in braces which is 43, 45, 47, 49, 51 and 53 |
03:59 | For definition of volume, use Volume, ID which is the next integer in round brackets equals the IDs of the two surfaces in braces Which is 29 and 57. |
04:20 | For physical volume, use Physical Volume, ID which is the next integer in round bracketsequals the IDs of the volume in braces which is 58. |
04:35 | Save this file and close it. Now, using the terminal reopen GMSH by typing:
gmsh sphere1.geo and press Enter |
04:48 | In GMSH, a bottom to top approach is followed
|
05:02 | For 1D mesh creation, press F1 key. |
05:06 | For 2D mesh creation, press F2 key. |
05:10 | For 3D mesh creation, press F3 key. |
05:14 | This may take a while. Watch the progress in the status bar.This shows Done now. |
05:22 | Once the mesh is created, we need to optimize it to remove faulty cells. |
05:27 | For optimization click on Modules , then Mesh and then on Optimize 3d Netgen option |
05:36 | This may also take a while.Once again, watch the progress in the status bar. |
05:43 | To save the mesh go to File, Save mesh and close the terminal. |
05:51 | Create OpenFOAM case directory without the constant folder.In the case directory, copy the newly created file sphere1.msh |
06:01 | Using the terminal window, go to the case directory of this problem. |
06:06 | Once you are in the case directory,Type: gmshToFoam sphere1.msh
To convert the mesh |
06:16 | Ensure that the same boundary names are there in the files of folder 0, before proceeding to the next step. |
06:24 | Let us summarise.
In this tutorial we have learnt to:
|
06:38 | As an assignment,Make refinement in the mesh by changing the values of:
s, d and Mesh.CharacteristicLengthFromCurvature |
06:49 | OpenFOAM series is created by the FOSSEE Project, IIT Bombay. FOSSEE stands for Free and Open Source Software for Education. |
06:58 | This project promotes the use of free and open source software tools. For more details, please visit: http://fossee.in/ |
07:07 | The video at this link summarises the Spoken Tutorial project. Please download and watch it. |
07:13 | The Spoken Tutorial Project Team conducts workshops and gives certificates on passing online tests. For more details, please write to us. |
07:22 | Spoken Tutorial Project is funded by NMEICT, MHRD, Government of India. More information on this Mission is available at this link.This is Pavan Mehta from FOSSEE Project, IIT BOMBAY signing off. Thanks for joining. |