Professional Documents
Culture Documents
Formation OpenFOAM Advanced 100
Formation OpenFOAM Advanced 100
OpenFOAM tutorial
Discover it, tame it, use it
Advanced turorial
by Victor Pozzobon
(victor.pozzobon@centralesupelec.fr)
50 cm
Air
injections
4 5
frontAndBack
walls
3
2
0 1
26th December 2016 Pozzobon Victor 11
Ex. 1: Bubble reactor – A new mesh
⃗g
Obstacle
40 mm
10 mm
26th December 2016 Pozzobon Victor 38
Ex. 3: Rising bubble – Copying a
case
● Go to your 'run' directory:
run
● Copy an existing case:
cp -r Ex2 Ex3
● Move to the case directory:
cd Ex3
● Clean the case directory:
foamListTimes -rm
4 5
40 mm
3
2
0 1 10 mm
26th December 2016 10 mm Pozzobon Victor 40
Ex. 3: Rising bubble – Modifying
mesh
● Build the mesh:
blockMesh
7 6
4 5
40 mm
3
2
0 1 10 mm
26th December 2016 Pozzobon Victor 41
Ex. 3: Rising bubble – topoSetDict
gedit system/fvSolution
t = 0.10 s
● Set initial/boundary
conditions for ozone:
cp 0/p_rgh 0/O3
gedit 0/O3
1 cm
Axis
Outlet
Inlet
5°
Front and
Back
Wall
26th December 2016 Pozzobon Victor 68
Ex. 5: Turbulent pipe – Case
creation
● Reach 'run' directory:
run
● Copy an existing case:
cp -r First/Tutorial/Cases/Folder/Ex5 Ex5
● Go to the new case directory:
cd Ex5
● Clean the case directory:
foamListTimes -rm
5 cm
InletB
A=0
26th December 2016 Pozzobon Victor
25 cm 80
Ex. 6: Turbulent mixing length –
Solver creation
● Reach 'run' directory:
run
● Move to solver directory:
cd solvers
●
Copy simpleFoam:
cp -r $FOAM_APP/solvers/incompressible/simpleFoam .
mv simpleFoam simpleChemFoam
● Move to the new solver directory:
cd simpleChemFoam
Accessing turbulent
viscosity
Mesh refinement on
the two sides of the
x axis