Difference between revisions of "OpenFOAM/C3/Installing-and-running-Gmsh/English"
Nancyvarkey (Talk | contribs) |
Rahuljoshi (Talk | contribs) |
||
(4 intermediate revisions by 2 users not shown) | |||
Line 2: | Line 2: | ||
− | Script | + | Script : Gautam Sharma |
+ | Narration: Rahul Joshi | ||
− | Keywords: Gmsh.''' ''' | + | Keywords: Gmsh, OpenFOAM, Geometry, Finite Element Mesh, Video Tutorial.''' ''' |
Line 37: | Line 38: | ||
| style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| To record this tutorial, I am using | | style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| To record this tutorial, I am using | ||
− | * '''Ubuntu Linux''' Operating system version | + | * '''Ubuntu Linux''' Operating system version 12.04 and |
− | * '''Gmsh''' version 2.8. | + | * '''Gmsh''' version 2.8.5 |
|- | |- | ||
Line 65: | Line 66: | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Let me show you how to install '''Gmsh'''. | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Let me show you how to install '''Gmsh'''. | ||
− | '''Gmsh'''can be installed using '''Synaptic Package Manager'''. | + | '''Gmsh''' can be installed using '''Synaptic Package Manager'''. |
− | + | ||
|- | |- | ||
Line 78: | Line 78: | ||
− | In search box type '''gmsh'''. Click on the checkbox in front of '''gmsh'''. And click on '''Mark for installation'''. | + | In search box type '''gmsh'''. Click on the checkbox in front of '''gmsh'''. |
+ | And click on '''Mark for installation'''. | ||
Click on '''Apply'''. | Click on '''Apply'''. | ||
− | + | Again click on '''Apply'''. | |
Line 139: | Line 140: | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Gmsh start screen | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Gmsh start screen | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| You can see the '''Gmsh '''start screen. | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| You can see the '''Gmsh '''start screen. | ||
− | |||
− | |||
|- | |- | ||
Line 155: | Line 154: | ||
− | On the left hand, you can see the '''module tree''' with '''Geometry, Mesh''' and '''Solver'''. | + | On the left hand side, you can see the '''module tree''' with '''Geometry, Mesh''' and '''Solver'''. |
|- | |- | ||
Line 183: | Line 182: | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Enter the second | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Enter the second coordinate as (1 0 0) and press '''Enter.''' |
− | The third coordinate as (1 1 0) press '''Enter'''. | + | The third coordinate as (1 1 0) and press '''Enter'''. |
− | The fourth coordinate as (0 1 0) press '''Enter'''. | + | The fourth coordinate as (0 1 0) and press '''Enter'''. |
− | Similarly, enter the '''coordinates''' for the positive z-direction starting with (0 0 1) press '''Enter'''. | + | Similarly, enter the '''coordinates''' for the positive z-direction starting with point (0 0 1) and press '''Enter'''. |
Line 220: | Line 219: | ||
|- | |- | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select end point | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select end point | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| It | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| It will ask for '''end point '''. |
Select the second point. | Select the second point. | ||
Line 230: | Line 229: | ||
Similarly, join all the points. | Similarly, join all the points. | ||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
Line 263: | Line 258: | ||
− | You will | + | You will notice that the edge we select, turns in red color. |
Line 273: | Line 268: | ||
|- | |- | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Face appears with centre lines | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Face appears with centre lines | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| You will notice the the face will appear with dashed centre lines. | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| You will notice that the the face will appear with dashed centre lines. |
|- | |- | ||
| style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Define the top face | | style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Define the top face | ||
| style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Now define the top face. | | style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Now define the top face. | ||
− | |||
− | |||
− | |||
|- | |- | ||
| style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select the remaining faces | | style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select the remaining faces | ||
− | |||
− | |||
| style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Similarly, define the remaining faces. | | style="border:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Similarly, define the remaining faces. | ||
Line 320: | Line 310: | ||
|- | |- | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select the surface boundary | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select the surface boundary | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select the front surface first | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Select the front surface first and press '''e''' to end the selection. |
− | Select the back surface | + | Select the back surface and press '''e '''to end the selection. |
|- | |- | ||
Line 333: | Line 323: | ||
|- | |- | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Define the volume | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Define the physical volume. |
− | Click on volume | + | Click on volume. |
− | Click the yellow dot | + | Click on the yellow dot |
Line 352: | Line 342: | ||
− | The yellow dot will turn red in color. Press '''e '''to end selection. Press '''q''' to abort. | + | The yellow dot will turn red in color. Press '''e '''to end selection. |
+ | |||
+ | Press '''q''' to abort. | ||
|- | |- | ||
Line 366: | Line 358: | ||
− | We will name our file as '''cube.geo | + | We will name our file as '''cube.geo''' |
Line 374: | Line 366: | ||
Click '''Ok'''. | Click '''Ok'''. | ||
− | + | ||
+ | Again click '''Ok'''. | ||
|- | |- | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Slide : Assignment | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Slide : Assignment | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| This brings us to the end of this tutorial. |
− | + | As an '''assignment''', create other simple geometry in '''Gmsh''' like cylinder and sphere. | |
− | + | ||
− | + | ||
− | As an '''assignment''' create other simple geometry in '''Gmsh''' like cylinder and sphere. | + | |
|- | |- | ||
Line 392: | Line 382: | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| In this tutorial we learnt : | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| In this tutorial we learnt : | ||
− | |||
− | |||
* 2 ways to install and run '''Gmsh''' using Synaptic Package Manager and website. | * 2 ways to install and run '''Gmsh''' using Synaptic Package Manager and website. | ||
* Created a cube using '''Gmsh'''. | * Created a cube using '''Gmsh'''. | ||
Line 402: | Line 390: | ||
About Spoken tutorials | About Spoken tutorials | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| This video summarizes the Spoken Tutorial project. |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
If you do not have good bandwidth, you can download and watch it. | If you do not have good bandwidth, you can download and watch it. | ||
Line 414: | Line 398: | ||
About Spoken tutorials | About Spoken tutorials | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| We conduct workshops using spoken tutorials and give certificates |
− | + | Please contact us at this URL | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
contact@spoken-tutorial.org | contact@spoken-tutorial.org | ||
Line 431: | Line 411: | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Spoken | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| Spoken Tutorial is funded by NMEICT, MHRD, Government of India. |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
|- | |- | ||
| style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| About the contributor | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| About the contributor | ||
− | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| | + | | style="border-top:none;border-bottom:1pt solid #000001;border-left:1pt solid #000001;border-right:1pt solid #000001;padding-top:0cm;padding-bottom:0cm;padding-left:0.191cm;padding-right:0.191cm;"| The script was created by Gautam Sharma and this is Rahul Joshi from IIT BOMBAY signing off. |
Thanks for joining. | Thanks for joining. | ||
|} | |} |
Latest revision as of 09:59, 6 January 2015
Tutorial: Installing and runing Gmsh
Script : Gautam Sharma
Narration: Rahul Joshi
Keywords: Gmsh, OpenFOAM, Geometry, Finite Element Mesh, Video Tutorial.
|
|
Slide 1 | Hello and welcome to the spoken tutorial on Installing and running Gmsh. |
Slide 2 : Learning Objectives
|
In this tutorial we will learn how to
|
Slide 2: Pre-requisite | As a pre-requisite, the user should have basic knowledge about mesh. |
Slide 3:
System Requirement |
To record this tutorial, I am using
|
Slide 4: About Gmsh
|
Let me introduce you to Gmsh.
|
Slide 5 : Advantageous in creating complex geometry using blockMesh |
|
Installing Gmsh | Let me show you how to install Gmsh.
Gmsh can be installed using Synaptic Package Manager. |
Synaptic Package Manager
Gmsh installed |
Let me open Synaptic Package Manager for you.
It will ask for your password. Type in your password.
Click on Apply. Again click on Apply.
|
Open browser
|
Alternately, you can also download Gmsh from the Gmsh website.
|
Type: http://geuz.org/gmsh/ | In the address bar, type: http://geuz.org/gmsh/
Press Enter.
|
Scroll down to stable Linux release
|
Scroll down to Downloads and select the current stable release according to your operating system.
|
Go to Home>> Downloads
Locate the file gmsh-2.8.4-Linux64.tgz |
After finishing your download, go to the Downloads folder. |
Extract the files | Here you can see the tar file. Extract the file.
|
Open Gmsh folder | Open the folder.
Go to bin and click on gmsh icon. |
Gmsh start screen | You can see the Gmsh start screen. |
Cube | Now we will create a cube using Gmsh. |
Diagram | Here you can see the cube with side equal to one unit. |
Gmsh window | Let me switch back to Gmsh.
|
Click Add | Go to Geometry - Elementary entitites - Add. |
Enter the coordinates of the cube | Click on Point. A new window will appear. |
Enter the coordinates | Enter the X,Y and Z coordinates starting with (0 0 0) and press Enter. |
(1 0 0)
|
Enter the second coordinate as (1 0 0) and press Enter.
|
Coordinates | I have entered all the eight coordinates. |
Move the points | Use the left mouse click to move the points. |
8 points visible | You can see all the 8 coordinates as points. |
Join the points by Straight lines | Now, click on Straight line. |
Select start point | It wiil ask for start point .
Select the first point. |
Select end point | It will ask for end point .
Select the second point. |
Straight line | A line will be drawn between the two points.
|
Press q to abort | Press q to abort. |
Define the faces | Now we will define the faces of the cube. |
Click on Plane Surface | Click on Plane surface.
|
Select the edges
appear in red
|
Select the edges of the bottom face first.
|
Face appears with centre lines | You will notice that the the face will appear with dashed centre lines. |
Define the top face | Now define the top face. |
Select the remaining faces | Similarly, define the remaining faces.
|
Define the Volume | Now, we will define the volume of the cube.
|
Select the volume boundary | Select any of the surface boundary and press e to end selection. |
Green dot appears at centre | A yellow dot appears at the centre of the cube, which represents the volume.
|
Define physical groups | Now, we will define the physical groups, which will be used in exporting the geometry to OpenFOAM. |
Define surface first | Go to Physical Group - Add and click on Surface. |
Select the surface boundary | Select the front surface first and press e to end the selection.
|
Select the remaining face | Similarly, select the remaining surfaces.
|
Define the physical volume.
|
Now, we'll define the physical volume.
Press q to abort. |
Save you work | Our cube is complete. Let us save our work. |
Click on save as
|
Go to File - Save as.
|
Slide : Assignment | This brings us to the end of this tutorial.
|
Slide : Summary
|
In this tutorial we learnt :
|
Slide :
About Spoken tutorials |
This video summarizes the Spoken Tutorial project.
If you do not have good bandwidth, you can download and watch it. |
Slide:
About Spoken tutorials |
We conduct workshops using spoken tutorials and give certificates
Please contact us at this URL contact@spoken-tutorial.org |
Slide:
Acknowledgement
|
Spoken Tutorial is funded by NMEICT, MHRD, Government of India. |
About the contributor | The script was created by Gautam Sharma and this is Rahul Joshi from IIT BOMBAY signing off.
Thanks for joining. |