Challenge

Prandtl Meyer Shock problem

STEADY STATE 2D SIMULATION OF PRANDTL MEYER EXPANSION FAN USING CONVERGE CFD

(WEEK-5 CHALLENGE)

  1. AIM

Our aim is to setup a steady state 2D simulation of Prandtl Meyer shock flow for subsonic and supersonic velocity in converge with different sub grid scaling, simulate it using Cygwin terminal and post process in Paraview and compare the results.

  1. THEORY/EQUATIONS/FORMULAE USED

Structure of CONVERGE CFD simulations

The basic steps for a simulation are as follows,

  1. Pre-processing [Converge Studio v3.0] – It is a leading CFD package for simulating 3D fluid flow. It is a user friendly interface which provides high productivity and easy-to-use workflows. Its features includes autonomous meshing, state of the art physical models, robust chemistry solver, and the ability easily accommodate complex moving geometries.
  2. Solving [Cygwin] – It is a large collection of GNU and Open Source tools which provide functionality similar to a Linux distributionon Windows.
  3. Post-processing [ParaView 5.9.0] – It includes analyzing the results by plotting the results as charts, contour, and exporting the data, also validating the results both qualitatively and quantitatively.

Shock Waves

Shock waves are strong pressure waves in any elastic medium such as air, water or a solid substance. It is produced by supersonic aircrafts, explosion, lightning or other phenomena which create violent changes in pressure.

How Shock Waves are created?

In subsonic conditions, the sound waves will travel faster that the flow particles and hit the obstacle in front and the information is passed on to the following flow particles so that the particles change the path smoothly.

But in supersonic condition, the flow particles travel faster than the speed of sound so there is no information the on the obstacle due to which the it hits the obstacle and then the returning and oncoming particles collide each other and create shock waves.

If the shock waves are perpendicular to the flow direction then it is called as normal shock wave. If it is inclined at an angle then it is called as Oblique shock waves. A shock wave is when lots of energy comes from a very small spot and shakes the material around it.

A shock wave can move through any material. An earthquake is a shockwave traveling through the ground. Shock waves can also be felt in the water. A shock wave is affected by the materials it travels through, and different materials have different effects. A thick material, like water, might help the shock wave travel further, whereas a thin material, like air, would not. This is similar to the way that sound waves are affected by what they move through, but sound waves and shock waves are not the same. The above plot shows how the pressure varies with time for a shock wave and expansion wave.

Prandtl Meyer Expansion Fan

A supersonic expansion fan, technically known as Prandtl–Meyer expansion fan, a two-dimensional shock wave, is a centered expansion process that occurs when a supersonic flow i.e., at a Mach number more than 1 turns around a convex corner.

This fan consists of an infinite number of Mach waves, diverging from a sharp corner. When a flow turns around a smooth and circular corner, these waves can be extended backwards to meet at a point.

Each wave in the expansion fan turns the flow gradually (in small steps). It is physically impossible for the flow to turn through a single "shock" wave because this would violate the second law of thermodynamics.

Across the expansion fan, the flow accelerates (velocity increases) and the Mach number increases, while the static pressure, temperature and density decrease. Since the process is isentropic, the stagnation properties (e.g. the total pressure and total temperature) remain constant across the fan.

The theory was described by Theodor Meyer on his thesis dissertation in 1908, along with his advisor Ludwig Prandtl.

Shock Flow Boundary Conditions

The boundary conditions in general are defined in many ways namely Dirichlet, Neumann, Robin, Mixed, and Cauchy.

  1. Dirichlet – we specify the exact value of the function for example inlet velocity, pressure or temperature.
  2. Neumann – we specify how the value of the function at the boundary is changing along the normal direction of the boundary i.e., the derivative of the function.
  3. Robin – It is a linear combination of Dirichlet and Neumann applied to the boundaries when the Neumann condition varies with respect to the condition specified by the Dirichlet.
  4. Mixed – It involves the mixture of both Dirichlet and Neumann applied to different boundaries of the fluid domain.
  5. Cauchy – It allows us to impose both Dirichlet and Neumann to be applied simultaneously at a boundary.

Note - Dirichlet and Neumann are predominantly used boundary condition types.

In Prandtl–Meyer expansion fan problem where the supersonic flow, shocks are involved the boundaries are defined in a certain way such as

  1. Inlet – We should assign Dirichlet boundary condition for all parameters such as pressure, velocity, temperature as we need to define the free stream as supersonic flow conditions.
  2. Outlet – We should assign Neumann boundary condition for all parameters such as pressure, velocity, temperature as we looking for the results and unaware of the condition at the outlet. These values are calculated numerically by extrapolation using the values within the fluid domain. Also the supersonic flow involves abrupt changes in parameters.
  3. Walls – Walls can be assigned as fixed with slip condition as the supersonic flow is in viscid in nature.
  4. Front and Back Sides – The front and back sides are defined as 2D in our case as the flow gradients in the third dimension is negligible compared to the other two dimensions also we want it to be 2D flow simulation.

Adaptive Mesh Refinement

The adaptive mesh refinement is a common strategy for significant numerical investigation, a method of adapting the accuracy of a solution within certain sensitive or turbulent regions of simulation, dynamically and during the time the solution is being calculated.

Usually when the equations are solved numerically to find solutions, the fluid domain grid size, and quantity are predefined. There are many problems in numerical analysis, however, do not require a uniform precision in the numerical grids for computational simulation, and would be better suited if specific areas of fluid domain is precisely discretized spatially to add precision to the solution and capture important physical phenomena.

Adaptive mesh refinement provides such a dynamic programming environment for adapting the precision of the numerical computation based on the requirements of a computation problem in specific areas of multi-dimensional graphs which need precision while leaving the other regions of the multi-dimensional graphs at lower levels of precision and resolution.

This dynamic technique of adapting computation precision to specific requirements has been accredited to Marsha Berger, Joseph Oliger, and Phillip Colella who developed an algorithm for dynamic gridding called local adaptive mesh refinement.

Problem – Prandtl Meyer Expansion Fan

The challenge includes steady state 2D simulation of Prandtl Meyer Shock flow for subsonic and supersonic inlet velocity with different sub grid scaling and to compare the results.

Mesh Size - dx = dy = dz = 0.8 m

Adaptive Mesh Refinement – Max Embedding level – 2, Sub grid scale – 0.1, 0.05, 0.03

  1. PROCEDURE
  • Firstly all the softwares are downloaded and installed in the system.
  • Geometry is imported in converge studio, boundary is flagged, and boundaries are checked for normals and orientation is done as per the requirement and finally diagnosis check is carried out to check for any errors such as intersections, open edges, non-manifold edges, overlapping triangles etc.
  • Case setup is done using setup wizard, then the input files are exported to a specific directory and also converge executable application are also copied into the directory.
  • The simulation is run using Cygwin commands and post converted the output files so that it is compatible for post processing in Paraview.
  1. NUMERICAL ANALYSIS
    • Geometric Model

The geometry file (.stl) is imported in Converge Studio and scaled in meters as per the figure given below.

Geometry

Fig: Scaling the domain

  • Mesh

Fig: Mesh

  • Boundaries

Fig: Boundaries of the domain

  • Case Set-up
  • In Materials tab, materials – Air, species – O2, N2 and global transport parameters are selected.

  • In Simulation Parameters tab, Run parameters such as Solver type, Simulation Mode and Gas flow Solver are set. In Misc. Tab uncheck the shared memory and check the steady state monitor.

  • Steady State monitors are created as by specifying the target type as boundaries and target as outlet for the problem with 20000 minimum numbers of cycles to be executed.

  • Simulation time parameters such as total number of cycles, time step, CFL limits etc are set as shown in the figure below.

  • Solver parameters such as the Navier stokes solver type, equations preconditions type, solver controls are set.

  • Boundary Conditions and Initial Conditions

Zone

Type

Boundary Condition

Additional conditions

(if any)

Inlet

Velocity Inlet

Inlet Velocity – 100 m/s and

678 m/s

Steady State,

Density Based

Inlet Pressure – 101000 Pa

Inlet Temperature – 286 K

Outlet

Neumann Boundary

Neumann Boundary

Top and Bottom Wall

Fixed Wall

Slip

Front and Back

2D

2D

  • Regions and Initialization – Fluid domain is created and the Species is added to the fluid domain.

  • Turbulence Modelling – No Turbulence Model is required as flow is supersonic which is in-viscid in nature so no Reynolds stresses term.
  • Base Grid – Mesh sizes are entered as per the problem and AMR is done with SGS embed type based on temperature criterion.

  • Post Variable Selection - Select all the necessary variables and the location that needs to be checked while post processing.

  • Output Files – Output files writing time intervals, restart files are set as per the requirement.

  • After the setup is done click on “Validate all” option to check for any issues with the case setup. If everything is correct then green tick will appear for all tabs as shown in the figure below. Once the Setup is done, export the input files.

  • With input and executable files, navigate to the specific directory in Cygwin and run the simulation using "exe -n 4 converge.exe restricted </dev/null> logfile &"
  • After the run is completed Post convert the output files using “exe -n 4 post_convert.exe” into binary inline vtk format.
  • Using the vtm group files, post processing is done in ParaView in order to study the results.
  1. RESULTS

Case 1 (Inlet Velocity – 100 m/s, Sub-grid Scale – 0.1)

Fig: Mesh Fig: Total Cell Count

Fig: Mass Flow Rate Plot

Fig: Total Pressure Plot Fig: Pressure Contour

Fig: Average Density Plot Fig: Density Contour

Fig: Average Temperature Plot Fig: Temperature Contour

Fig: Average Velocity Plot Fig: Velocity Contour

Fig: Mach number Plot

Animation Link

Mesh - https://youtu.be/46D4egztMpM

Temperature - https://youtu.be/GOrPR1dRbvg

Case 2A (Inlet Velocity – 678 m/s, Sub-grid Scale – 0.1)

Fig: Mesh Fig: Total Cell Count

Fig: Mass Flow Rate Plot

Fig: Total Pressure Plot Fig: Pressure Contour

Fig: Average Density Plot Fig: Density Contour

Fig: Average Temperature Plot Fig: Temperature Contour

Fig: Average Velocity Plot Fig: Velocity Contour

Fig: Mach number Plot

Animation Link

Mesh - https://youtu.be/pxYbzZHDUbM

Temperature - https://youtu.be/wAq7Fesj3Kc

Case 2B (Inlet Velocity – 678 m/s, Sub-grid Scale – 0.05)

Fig: Mesh Fig: Total Cell Count

Fig: Mass Flow Rate Plot

Fig: Total Pressure Plot Fig: Pressure Contour

Fig: Average Density Plot Fig: Density Contour

Fig: Average Temperature Plot Fig: Temperature Contour

Fig: Average Velocity Plot Fig: Velocity Contour

Fig: Mach number Plot

Animation Link

Mesh - https://youtu.be/6Covnv6nEco

Temperature – https://youtu.be/jUfKIlJc8Go

Case 2C (Inlet Velocity – 678 m/s, Sub-grid Scale – 0.03)

Fig: Mesh Fig: Total Cell Count

Fig: Mass Flow Rate Plot

Fig: Total Pressure Plot Fig: Pressure Contour

Fig: Average Density Plot Fig: Density Contour

Fig: Average Temperature Plot Fig: Temperature Contour

Fig: Average Velocity Plot Fig: Velocity Contour

Fig: Mach number Plot

Animation Link

Mesh - https://youtu.be/OY0TGWWY3OU

Temperature - https://youtu.be/x5hXy-j7en4

6. CONCLUSION

  • The steady state 2D Prandtl Meyer Expansion flow simulation is carried out for subsonic and supersonic velocity for different sub grid scale criterion and noticed that the solution got converged around 20000 cycles.
  • Plots of average velocity, Mach number, total pressure, average density, average temperature and mass flow rate at the inlet and outlet regions are compared.
  • Adaptive Mesh Refinement is used along with base grid size of 0.8 m for all cases with embed type - sub grid scale, max embed level – 2, sub grid criterion based on temperature – 0.1, 0.05, 0.03.
  • The total cell count for all 4 cases keeps changing according to the temperature increment as shown in the animation respectively. The cell count for case 1, 2, 3 and 4 are around 5800, 5300, 7800, and 11600 respectively.
  • Decrease in the sub grid criterion value increases the cell count which in turn increases the accuracy of expansion fan and the Mach waves.
  • Supersonic inlet velocity cases show the Prandtl Meyer Expansion Fan at the convex corner and the location of Mach waves precisely.
  • Leading edge mach wave is proportional to inlet mach number and trailing edge mach wave is proportional to outlet mach number.
  • Due to the Prandtl Meyer Expansion Fan, the flow gets expanded undergoes abrupt changes, and the physical quantity plot shows that for all 3 supersonic cases the average density, temperature, total pressure decreases and the average velocity, Mach number increases across the expansion fan.
  • For subsonic case, we can clearly see that there is no expansion fan created at the corner but the origin of mach wave can be observed.
  • We can see that the AMR is an important method for the understanding the problem involving supersonic flow, Prandtl Meyer Expansion Fan, etc as the shock waves can be seen clearly and hence we can conclude that the computational simulation results are in good agreement and the underlying physics is visible clearly.

7. REFERENCES

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.