Menu

Executive Programs

Workshops

Projects

Blogs

Careers

Placements

Student Reviews


For Business


More

Academic Training

Informative Articles

Find Jobs

We are Hiring!


All Courses

Choose a category

Loading...

All Courses

All Courses

logo

Loading...
Executive Programs
Workshops
For Business

Success Stories

Placements

Student Reviews

More

Projects

Blogs

Academic Training

Find Jobs

Informative Articles

We're Hiring!

phone+91 9342691281Log in
  1. Home/
  2. Ramkumar Venkatachalam/
  3. Simulation of Laminar Flow through wedge-shaped pipe using OpenFOAM

Simulation of Laminar Flow through wedge-shaped pipe using OpenFOAM

SIMULATION OF LAMINAR FLOW IN A WEDGE-SHAPED PIPE USING OpenFOAM AIM Our aim is to simulate a laminar flow in a wedge-shaped pipe by writing a Matlab code that can generate a BlockMesh Dict file for computational mesh for any wedge angle and validate the Hagen-Poiseuille equation using OpenFOAM.  THEORY/EQUATIONS/FORMULAE…

  • CFD
  • MATLAB
  • Ramkumar Venkatachalam

    updated on 29 Jan 2022

SIMULATION OF LAMINAR FLOW IN A WEDGE-SHAPED PIPE USING OpenFOAM

  1. AIM

Our aim is to simulate a laminar flow in a wedge-shaped pipe by writing a Matlab code that can generate a BlockMesh Dict file for computational mesh for any wedge angle and validate the Hagen-Poiseuille equation using OpenFOAM. 

  1. THEORY/EQUATIONS/FORMULAE USED

OpenFOAM is an open source CFD package. It is a Finite Volume Method (FVM) based tool as it can handle unstructured mesh as well.

It contains basic predefined solvers which can be used to solve our problem, but we need to make sure that correct solver is chosen.

Structure of OpenFOAM simulations

The important directories for a simulation are as follows,

  1. System – It consists of various files such as Control Dict, BlockMesh Dict, fv schemes, fv solutions. It defines the mesh and discretization schemes for the simulation.
  2. Constant – It consists of various files such as transport properties, boundaries. Polymesh directory is formed after running the blockMesh Dict file.
  3. Time directory – It consists folder named 0 before running the simulation. The 0 folder contains files which defines the initial conditions. After running the simulation, the results at every time intervals are also saved here.

OpenFOAM solver – icoFoam is used for problem involving laminar, transient, incompressible and Newtonian fluid. So it’s suitable for flow in a wedge-shaped pipe problem.

Hagen-Poiseuille Equation

Hagen-Poiseuille equation is a fluidic law to find the head loss (or) pressure drop through a circular pipe under laminar flow conditions.  

                                                                 Hagen-Poiseuille Eq 

Where ΔP is Pressure drop, L is Length of the pipe, R is Radius of the pipe, U is Average Velocity of the flow and µ is Dynamic Viscosity of the fluid.

Fluid chosen for the problem – Water

Reynolds Number –It is a ratio of inertial forces to the viscous forces. It is a dimensionless number used to categorize any fluid where viscosity plays an important role, as viscosity controls the velocity.

                                                             Reynolds

Where Re is Reynolds number, ρ is Density of the fluid, L is Length of the pipe, u is flow speed and µ is Dynamic Viscosity of the fluid.

The dimensionless number is used to determine if a fluid is laminar or turbulent. It is assumed that,

                                             Re ≤ to 2100 is laminar flow.

                                   Re ≥ to 2100 and ≤ to 4000 is Critical flow.

                                             Re ≥ to 4000 is Turbulent flow.

Hydrodynamic Length

For an Internal flow in a cylindrical pipe, flow region can be divided into two phases, initial phase - Hydrodynamic entrance length and then fully developed region as shown in the below figure.

                                  Development_of_fluid_flow_in_the_entrance_region_of_a_pipe

The velocity profile in laminar flow inside a pipe is parabolic in nature. But, initially the velocity profile looks like a straight line as velocity at center and at boundary are equal and parabolic nature can be seen in fully developed region.

So the length of the pipe for the problem is decided based on the Hydrodynamic entrance length, Le.

                                            Entry Length

Analytical Calculation

Diameter = 0.01 m (Assumed)

Total Length of the pipe, L = Le + X = 2 m, where Hydrodynamic entrance length, Le = 1.05 (As per above equation) and for fully developed region X = 0.95 (Assumed)

Dynamic Viscosity of Water = 9.5320e-4 kg/ms

Density of Water = 997 kg/m3

Average Velocity of the flow = 0.20077 m/s

Maximum Velocity of the flow = 0.40155 m/s

Pressure Drop (As per Hagen Poiseuille eq) = 122.48 Pa

     3. OBJECTIVES & PROCEDURE

  1. The main objective is to simulate a laminar flow in wedge-shaped pipe by using OpenFOAM solver and understand the flow behavior at the boundary layer and validate the Hagen-Poiseuille equation by plotting velocity profile at different locations of the wedge-shaped pipe.
  2. In the process, firstly the geometry is created by defining the vertices of a coordinate system in the blockMesh Dict file.
  3. BlockMesh Dict file is created by writing Matlab code, which can generate BlockMesh Dict file for computational mesh for any wedge angle and mesh grading. Three different cases are defined with wedge-angle 4 deg, 3 deg and 2 deg.
  4. After getting the BlockMesh Dict file the Polymesh folder is generated and transport property i.e., kinematic viscosity is defined in the constant directory.
  5. Then the initial and boundary condition are defined as per the problem. The primitive variables such as Velocity and Pressure are calculated using the solver.
  6. Velocity contours and plot are generated and analyzed.                                                                                                                     

     4. NUMERICAL ANALYSIS (Software used – OpenFOAM 4.1)

 Geometric Modeling

The 3D geometry is considered as one complete block and grids are defined only on two axes as the flow with respect to wedge angle is ignored.

3D Geometry – Wedge-shaped Pipe less than 5 deg

                                       Model

Number of Cells                                                    Mesh specification

  1. X axis – 240                                                  Grading Factor on the Y-axis – 0.1
  2. Y axis – 40
  3. Z axis – 1

 Matlab Code for generating BlockMesh Dict file

DotM1

DotM2

DotM3

DotM4

DotM5

DotM6

BLOCKMESH DICT FILE GENERATED FROM MATLAB

blockmesh1

MESHING

Mesh

Boundaries

B1

B2

Boundary Condition

blockmesh2

blockmesh3

Control Dict

Ctrldict1

Ctrldict2

Transport Properties

transportproperties

Initial Condition - Pressure

pres1

pres2

Initial Condition – Velocity

vel1

vel2   

     5. RESULTS  

Velocity Contour of 2 Deg Wedge

Inlet 

2degVelinlet

Outlet

2degVeloutlet

  1. Velocity Plot at 0.005m2deg0.005
  2. Velocity Plot at 0.02m2deg0.02
  3. Velocity Plot at 0.5m2deg0.5
  4. Velocity Plot at 1.5m2deg1.5

Velocity Contour of 3 Deg Wedge

Inlet

3degVelinlet

Outlet

3degVeloutlet

  1. Velocity Plot at 0.005m3deg0.005
  2. Velocity Plot at 0.02m3deg0.02
  3. Velocity Plot at 0.5m3deg0.5
  4. Velocity Plot at 1.5m3deg1.5

Velocity Contour of 4 Deg Wedge

Inlet 

4degVelinlet

Outlet

4degVeloutlet

  1. Velocity Plot at 0.005m4deg0.005
  2. Velocity Plot at 0.02m4deg0.2
  3. Velocity Plot at 0.5m4deg0.5
  4. Velocity Plot at 1.5m4deg1.5

 

     Shear Stress Plot

                                       Shear Stress_4deg

  Velocity profile for the complete pipe

                                      Velocity profile

    6. CONCLUSION

  1. The flow in a wedge-shaped pipe problem is solved for velocity with different wedge angles using icoFoam solver in OpenFOAM.
  2. Graphs shows the velocity profile along the radius of wedge-shaped pipe at x=0.005 m, 0.02 m, 0.5m, 1.5m of wedge angle 2, 3, and 4 deg respectively.
  3. The shear stress on the walls is determined and plotted in post processing using paraview by calculating the velocity gradient and multiplying with the dynamic viscosity.
  4. Graphs show that the velocity at the inlet is more of a straight line but as the flow crosses the hydrodynamic length the velocity profile becomes parabolic and this region is the fully developed region.
  5. The velocity profile and hydrodynamic length are in good corelation with the analytical solution in all three cases of different wedge angles.

Leave a comment

Thanks for choosing to leave a comment. Please keep in mind that all the comments are moderated as per our comment policy, and your email will not be published for privacy reasons. Please leave a personal & meaningful conversation.

Please  login to add a comment

Other comments...

No comments yet!
Be the first to add a comment

Read more Projects by Ramkumar Venkatachalam (31)

Week 5 Challenge : Surface wrap on Automotive Assembly

Objective:

                                                                                           …

calendar

03 Jul 2023 10:49 AM IST

  • ANSA
  • CAE
  • CFD
Read more

Week 4 Challenge : CFD Meshing for BMW car

Objective:

                                                                                           …

calendar

14 Jun 2023 03:46 AM IST

  • ANSA
  • CAE
  • CFD
Read more

Week 3 Challenge : CFD meshing on Turbocharger

Objective:

                                                                                                                  VOLUME MESHING ON A TURBOCHARGER USING ANSA                                                                                                                                          (WEEK-3 CHALLENGE) AIM Our…

calendar

24 Jul 2022 06:35 PM IST

  • ANSA
  • CAE
  • CFD
Read more

Week 2 Challenge : Surface meshing on a Pressure valve

Objective:

                                                                                           …

calendar

10 Jul 2022 04:29 AM IST

  • ANSA
  • CAE
  • CFD
Read more

Schedule a counselling session

Please enter your name
Please enter a valid email
Please enter a valid number

Related Courses

coursecardcoursetype

Post Graduate Program in CFD Solver Development

4.8

119 Hours of Content

coursecard

Introduction to OpenFOAM Development

4.9

18 Hours of Content

coursecardcoursetype

Post Graduate Program in Battery Technology for Mechanical Engineers

4.8

81 Hours of Content

coursecard

Simulation and Design of Power Converters for EV using MATLAB and Simulink

4.9

22 Hours of Content

coursecard

Introduction to Hybrid Electric Vehicle using MATLAB and Simulink

4.8

23 Hours of Content

Schedule a counselling session

Please enter your name
Please enter a valid email
Please enter a valid number

              Do You Want To Showcase Your Technical Skills?
              Sign-Up for our projects.