Difference between revisions of "OpenFOAM/C3/Turbulent-Flow-in-a-Lid-driven-Cavity/English"
Rahuljoshi (Talk | contribs) |
Rahuljoshi (Talk | contribs) |
||
Line 66: | Line 66: | ||
− | Turbulence modelling | + | '''Turbulence modelling''' |
− | Knowledge of how to solve flow in a Lid driven cavity | + | Knowledge of how to solve flow in a '''Lid driven cavity''' |
Line 93: | Line 93: | ||
− | Please make a note this problem is already set up in | + | Please make a note this problem is already set up in |
− | + | '''pisoFoam '''solver in OpenFoam directory. | |
− | And we are solving this for a Reynolds number Re =10000 | + | The boundary conditions are Lid velocity , '''U =1m/s''' |
+ | |||
+ | |||
+ | And we are solving this for a Reynolds number '''Re =10000''' | ||
|- | |- | ||
Line 132: | Line 135: | ||
− | Now type cd tutorials and press enter | + | Now type '''cd tutorials''' and press enter |
− | type cd incompressible and press enter | + | type '''cd incompressible''' and press enter |
− | type cd pisoFoam (Note that F here is capital ) and press enter | + | type '''cd pisoFoam''' (Note that F here is capital ) and press enter |
|- | |- | ||
Line 151: | Line 154: | ||
− | Our problem is setup inside ras folder which is called as reynolds averaged stress | + | Our problem is setup inside '''ras''' folder which is called as '''reynolds averaged stress''' |
Line 158: | Line 161: | ||
|- | |- | ||
| style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| Cavity folder | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| Cavity folder | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| Our folder name is cavity. | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| Our folder name is '''cavity'''. |
− | Now type cd ras and press enter | + | Now type '''cd ras''' and press enter |
Line 170: | Line 173: | ||
− | type cd cavity and press enter | + | type '''cd cavity''' and press enter |
Line 180: | Line 183: | ||
0 folder | 0 folder | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| In this you will see three folders 0,constant and system. | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| In this you will see three folders''' 0,constant and system'''. |
− | The initial conditions are specified within the files in the '0' directory. | + | The initial conditions are specified within the files in the ''''0'''' directory. |
− | Let us take a look at the files in the '0' directory. | + | Let us take a look at the files in the ''''0'''' directory. |
|- | |- | ||
Line 204: | Line 207: | ||
| style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| Type the following command | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| Type the following command | ||
− | cd 0 and press enter | + | '''cd 0''' and press enter |
Line 210: | Line 213: | ||
− | You can see files named as epsilon, k, nut, nutilda,p,R and U. | + | You can see files named as '''epsilon, k, nut, nutilda,p,R and U'''. |
Line 219: | Line 222: | ||
− | On Simulating flow in a channel using OpenFoam | + | On '''Simulating flow in a channel''' using OpenFoam |
Line 238: | Line 241: | ||
− | To do this type cd constant and press enter | + | To do this type '''cd constant''' and press enter |
|- | |- | ||
Line 245: | Line 248: | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| In this you will see the polyMesh folder containing the geometry | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| In this you will see the '''polyMesh''' folder containing the geometry |
− | of the case inside blockMeshDict | + | of the case inside '''blockMeshDict''' |
Line 254: | Line 257: | ||
− | In this you will see two more files named RASProperties and turbulenceProperties | + | In this you will see two more files named '''RASProperties''' and''' turbulenceProperties''' |
Line 261: | Line 264: | ||
|- | |- | ||
| style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| RASProperties | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| RASProperties | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| In the terminal type gedit RASProperties and press enter. | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| In the terminal type''' gedit RASProperties''' and press enter. |
Line 267: | Line 270: | ||
− | Which is kept as kepsilon | + | Which is kept as '''kepsilon''' |
Line 274: | Line 277: | ||
|- | |- | ||
| style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| turbulentProperties | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| turbulentProperties | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| in the terminal now type gedit turbulentproperties and press enter | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| in the terminal now type '''gedit turbulentproperties''' and press enter |
Line 283: | Line 286: | ||
− | Simulation type for this case is kept as RASModel | + | Simulation type for this case is kept as '''RASModel''' |
|- | |- | ||
Line 295: | Line 298: | ||
− | The transportModel we are using here is Newtonian | + | The '''transportModel '''we are using here is '''Newtonian''' |
− | Viscosity is kept as 1 e raise to -4 | + | Viscosity is kept as '''1 e raise to -4''' |
Line 314: | Line 317: | ||
− | and look at the blockMeshDict file | + | and look at the '''blockMeshDict''' file |
Line 342: | Line 345: | ||
− | To do this in the teminal window type blockMesh and press Enter | + | To do this in the teminal window '''type blockMesh''' and press Enter |
Line 352: | Line 355: | ||
− | To do this in the terminal type 'pisoFoam' and press enter | + | To do this in the terminal type '''pisoFoam''' and press enter |
Line 362: | Line 365: | ||
|- | |- | ||
| style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| Post-processing the results in paraview | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:none;padding:0.097cm;"| Post-processing the results in paraview | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| Iterations will stop at the end of the time step. | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| '''Iterations''' will stop at the end of the time step. |
Line 381: | Line 384: | ||
Change the drop down menu from solid color to U | Change the drop down menu from solid color to U | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| On the left hand side in the Object Inspector menu click on Apply | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| On the left hand side in the '''Object Inspector menu''' click on '''Apply''' |
− | You can see the lid driven cavity geometry. | + | You can see the '''lid driven cavity''' geometry. |
− | A common visualisation is surface plots. | + | A common visualisation is '''surface plots'''. |
Line 393: | Line 396: | ||
− | from the drop down menu change from solid color to U | + | from the drop down menu change from '''solid color to U''' |
|- | |- | ||
Line 400: | Line 403: | ||
Toggle on the color legend | Toggle on the color legend | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| On top of the paraview window you can see the VCR control | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| On top of the paraview window you can see the '''VCR control''' |
Line 409: | Line 412: | ||
− | Also toggle on the color legend on the left hand side top | + | Also '''toggle on''' the '''color legend''' on the left hand side top |
Line 425: | Line 428: | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| To visualise the stream lines | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| To visualise the '''stream lines''' |
Line 431: | Line 434: | ||
− | Go to Filters > Common > Stream | + | Go to '''Filters > Common > Stream Tracer'''s |
Line 444: | Line 447: | ||
− | You can also change the orientation in which the stream lines are viewed. | + | You can also change the '''orientation''' in which the stream lines are viewed. |
Line 450: | Line 453: | ||
− | You can see the seed type | + | You can see the''' seed type''' |
Line 456: | Line 459: | ||
− | and change the seed type from point source to line source | + | and change the seed type from''' point source to line source''' |
|- | |- | ||
Line 493: | Line 496: | ||
| style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| You can also plot the velocity along the x and y axis using plot over line | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| You can also plot the velocity along the x and y axis using plot over line | ||
− | To do this go to Filter > Data Analysis > Plot over line | + | To do this go to '''Filter > Data Analysis > Plot over line''' |
− | Save the data as .(dot) csv file from file menu | + | Save the data as''' .(dot) csv''' file from file menu |
Click on save data | Click on save data | ||
Line 506: | Line 509: | ||
For Re= 10000 | For Re= 10000 | ||
− | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| You can plot this data in libreoffice spreadsheet or any other plotting software of your choice | + | | style="border-top:none;border-bottom:0.05pt solid #000000;border-left:0.05pt solid #000000;border-right:0.05pt solid #000000;padding:0.097cm;"| You can plot this data in '''libreoffice spreadsheet '''or any other plotting software of your choice |
Let me switch back to the slides | Let me switch back to the slides | ||
− | The results obtained can be validated by results obtained by Ghia et.al for Reynolds No , Re= 10000 | + | The results obtained can be '''validated''' by results obtained by '''Ghia et.al for Reynolds No , Re= 10000''' |
|- | |- |
Revision as of 10:47, 28 February 2013
Tutorial: Turbulent flow in a lid driven cavity
Script : Chaitanya Talnikar, Shekhar Mishra , Rahul Joshi
Narration : Rahul Joshi
Keywords: Video tutorial ,CFD,Turbulent Flow in Lid driven cavity,OpenFOAM.
|
|
Slide 1:
|
Hello and welcome to the spoken tutorial on modelling turbulent flow in a Lid Driven Cavity using OpenFOAM
|
Slide 2:
|
In this tutorial I will show you
|
Slide 3:
|
To record this tutorial I am using Linux operating system Ubuntu 12.04
|
Slide 4 :
|
To practice this tutorial you should have some basic knowledge of
|
Demo:
Set up working Directory
|
This problem is identical in geometry and boundary
|
Slide 5: Solver | We will be using the Transient solver for incompressible,
|
Steps in setting up the problem | Now let me open the terminal window
|
In the terminal window
|
In the terminal window type run and press enter
|
Two Folders les and ras
|
Now type ls and press enter
|
Cavity folder | Our folder name is cavity.
|
Boundary and Initial conditions
|
In this you will see three folders 0,constant and system.
|
Inside the 0 folder
|
Type the following command
cd 0 and press enter
|
Let us view the constant folder | Now type cd .. and press enter
|
PolyMesh folder and fluid property files
|
In this you will see the polyMesh folder containing the geometry
|
RASProperties | In the terminal type gedit RASProperties and press enter.
|
turbulentProperties | in the terminal now type gedit turbulentproperties and press enter
|
TransportModel
|
In the terminal window type cd ..
and press enter.
|
Do ot change the blockMeshDict file
|
We are not changing the geometry in this case
|
Meshing the geometry
|
We are done with the setup
|
Running the solver : pisoFoam | Now we can run the solver
|
Post-processing the results in paraview | Iterations will stop at the end of the time step.
|
View the geometry
|
On the left hand side in the Object Inspector menu click on Apply
|
Click on the Play button on VCR control for animation
|
On top of the paraview window you can see the VCR control
|
Visualise the streamlines
|
To visualise the stream lines
|
Streamlines on top of the | On the left hand side in Object inspector menu click on Apply.
|
Plot streamlines about X, Y and Z axis
|
X, Y and Z axis are visible select any one of these axis
|
Plot data over line
|
You can also plot the velocity along the x and y axis using plot over line
To do this go to Filter > Data Analysis > Plot over line Save the data as .(dot) csv file from file menu Click on save data |
Plot the results
For Re= 10000 |
You can plot this data in libreoffice spreadsheet or any other plotting software of your choice
Let me switch back to the slides The results obtained can be validated by results obtained by Ghia et.al for Reynolds No , Re= 10000 |
Slide :
Summary |
Thats all we have in this tutorial
Let us summarise In this tutorial we learnt Turbulent Flow in a Lid Driven Cavity And plotting streamlines in paraView This brings us to the end of the tutorial |
Slide : Assignment | As an assignment
Modify the grid size of the cavity Change it to (100 100 1) Visualise the results in paraview using streamlines |
The video available at this URL:
http://spoken-tutorial.org/What_is_a_Spoken_Tutorial It summarizes the Spoken Tutorial project. If you do not have good bandwidth, you can download and watch it. | |
The Spoken Tutorial Project Team
-Conducts workshops using spoken tutorials -Gives certificates to those who pass an online test -For more details, please write to us at contacts@spoken-tutorial.org | |
Spoken Tutorials are part of Talk to a Teacher project,
It is supported by the National Mission on Education through ICT, MHRD, Government of India. This project is coordinated by http://spoken-tutorial.org More information on the same is available at the following URL link http://spoken-tutorial.org/NMEICT-Intro | |
About the contributor | The script is contributed by Shekhar Mishra and Chaitanya talnikar
This is Rahul Joshi from IIT BOMBAY signing off. Thanks for joining |