Computational Fluid Dynamics
Computational Fluid Dynamics
1. Why does the stream function automatically satisfy the continuity equation for
incompressible flow?
Ans: - The stream function, denoted typically as ψ, inherently satisfies the continuity equation for
incompressible flow because of the way it is defined. In incompressible flow, the continuity equation
u v
states that the divergence of the velocity field must be zero, which implies + = 0 . Where, u and
x y
v are the velocity components in the direction of x and y axis.
The stream function is introduced to automatically enforce this condition by defining the velocity
components in terms of its partial derivatives. Specifically, u = and v = − substituting these
y x
u v
expressions into the continuity equation, + =0
x y
u v
+ =0
x y
+ − =0
x y y x
2 2
− =0
xy yx
2 2
=
xy yx
Which is identically zero because partial derivatives commute.
Thus, the use of the stream function ensures that the continuity equation is satisfied without the need
for additional constraints, making it a convenient mathematical tool in fluid dynamics for two-
dimensional, incompressible flows.
2. What is the relationship between the stream function and velocity components in 2D
incompressible flow?
Ans: - In two-dimensional incompressible flow, the stream function ψ(x,y) is a scalar field that is
directly related to the velocity components u and v of the flow. The relationship between the stream
function and the velocity components arises from the definition of ψ in terms of its partial derivatives.
The stream function is defined such that:
u= and v = −
y x
where u and v are the velocity components in the x- and y-directions, respectively. These definitions
ensure that the continuity equation for incompressible flow is automatically satisfied.
The continuity equation for incompressible flow is given by:
u v
+ =0
x y
The stream function also has a physical interpretation: the difference in the value of ψ between two
points corresponds to the volumetric flow rate (per unit depth in the z-direction) passing between those
points. Lines of constant ψ, known as streamlines, represent the flow direction at every point in the
field, and the flow is always tangent to these lines. This makes the stream function an invaluable tool
for visualizing and analysing two-dimensional incompressible flow.
= v
Where, v = ( u, v ) is the velocity vector, and ∇ is the del operator and defined by
ˆ ˆ
= iˆ + j +k .
x y z
For a two-dimensional flow in the x-y plane, the vorticity has only one non-zero component (in the z-
direction), given by
v u
= −
x y
v u
Where, represents the rate of change of the y-component of velocity (v) in the x-direction and
x y
represents the rate of change of the x-component of velocity (u) in the y-direction.
This expression quantifies the tendency of the fluid to spin about the z-axis in the x-y plane. If ω>0, the
fluid exhibits counterclockwise rotation, while ω<0 corresponds to clockwise rotation.
5. Deduce the Poisson equation using vorticity and the stream function.
Ans: - The stream function ψ(x,y) is related to the velocity components u and v through the following
definitions:
u= and v = −
y x
The vorticity ω for two-dimensional flow is defined as the curl of the velocity field, which in terms of
u and v is:
v u
= −
x y
substituting the expressions for u and v from the stream function, we get:
= − −
x x y y
= − +
x x y y
2 2 2 2
= − 2 + 2 = − 2 + 2
x y x y
Using Laplacian operator in two dimensions
= −2
Thus, the negative multiple of Laplacian of stream function ψ is vorticity ω. This is the Poisson equation
for the stream function ψ, where ω is the vorticity of the flow. The Poisson equation relates the stream
function to the vorticity, showing that the stream function is influenced by the distribution of vorticity
in the flow. In fluid dynamics, this equation plays an important role in determining the velocity field of
the flow when the vorticity distribution is known.
D
= + u = v + u
2
Dt t
D
where: ω is the vorticity, u is the velocity vector field, ν is the kinematic viscosity, is the material
Dt
derivative, which represents the rate of change of vorticity as seen by a fluid particle.
The terms of Vorticity transport equation are as follows: -
Convective Term: The term u represents the convective transport of vorticity. It describes how
vorticity is carried along by the fluid flow, i.e., how the motion of fluid elements influences the
distribution of vorticity in the flow.
Diffusion Term: The term v 2 represents the diffusion of vorticity due to the fluid's viscosity.
Viscosity causes vorticity to spread out over time, smoothing out rotational features in the flow and
decreasing local vorticity intensity.
Production Term: The term u represents the generation or destruction of vorticity due to the
divergence of the velocity field. This term is typically zero in incompressible flow (where ∇⋅u=0), but
in compressible flows, it can contribute to vorticity generation.
Temporal Evolution: The first term on the left-hand side, , describes the rate of change of vorticity
t
with respect to time at a fixed point in space.
7. In the vorticity transport equation, what does the term (𝑢⋅∇)𝜔 represent?
Ans: - The term (u⋅∇)ω in the vorticity transport equation represents the advection or convection of
vorticity by the fluid flow. This term describes how the vorticity is carried or transported along with
the motion of the fluid. In fluid dynamics, the velocity field u dictates the movement of fluid particles,
and this term accounts for how vorticity, a measure of the fluid's rotational motion, moves with those
particles as they flow through space.
The operator (u⋅∇) is the convective derivative, often referred to as the material derivative when acting
on any field like velocity or vorticity. When applied to vorticity ω, this term essentially describes the
rate at which vorticity changes from the perspective of a moving fluid element. For instance, if a fluid
element is moving into a region with higher or lower vorticity, the term (u⋅∇)ω will quantify how the
vorticity distribution changes as the fluid element moves.
This term plays a crucial role in the dynamics of vortices and rotational structures within the flow. In
the context of turbulence or vortex dynamics, it describes how vortices can be advected by the large-
scale flow, potentially leading to stretching, bending, or merging of vortex lines. The advection of
vorticity can also influence the formation of new vortices or the dissipation of existing ones, depending
on the nature of the flow.
Thus, the term (u⋅∇)ω encapsulates the movement of rotational motion within the fluid, influenced by
the local velocity field. It highlights how the fluid's overall flow pattern can redistribute vorticity across
the domain, affecting the evolution of the flow's vorticity field over time.
U
+F = S
t
where: U represents the conserved variables (e.g., density, momentum, energy), F is the flux tensor
(flux of conserved quantities), S represents source terms (e.g., body forces, heat sources).
This form has distinct advantages in both theoretical and practical contexts, particularly in
computational fluid dynamics (CFD).
Physical Consistency and Conservation
The conservative form explicitly enforces the conservation laws:
U
CV t
dV +
CV
( )
F nˆ dA = SdV
CV
( )
Interface flux evaluation: The fluxes F nˆ across control volume faces can be computed explicitly,
ensuring conservation within each volume.
Arbitrary geometries: The integral form adapts well to complex geometries and unstructured meshes,
making it versatile for real-world problems.
Handling Discontinuities (Shocks and Contact Surfaces)
The conservative form is essential for problems involving shocks or other discontinuities:
Shock-capturing: Conservation laws are valid across discontinuities when solved in conservative form.
This allows schemes like upwind methods or Riemann solvers to handle shocks accurately.
Entropy consistency: Conservative forms align with physical entropy conditions, ensuring solutions
are physically meaningful.
For example, in compressible flows (e.g., supersonic jets), the flux-based conservative form ensures
that shocks are modelled correctly without unphysical oscillations.
Robustness in Multiphase and Reactive Flows
In multiphase or chemically reacting flows, the conservative form: Naturally handles interfacial
dynamics and phase changes, as fluxes track the transfer of conserved quantities and Ensures
conservation of species or enthalpy in chemical reactions.
Compatibility with Modern Numerical Schemes
Modern numerical methods in CFD are designed to work with conservative forms:
Finite volume schemes: Directly solve the flux-conservative integral form.
High-resolution methods: Methods like MUSCL (Monotone Upstream-centred Schemes for
Conservation Laws) and WENO (Weighted Essentially Non-Oscillatory) rely on flux evaluations for
stability and accuracy.
Adaptive mesh refinement (AMR): Conservative forms adapt seamlessly to changing resolution,
maintaining conservation across refined/coarsened regions.
Facilitation of Numerical Solutions in CFD
1. Accurate Flux Evaluation: Conservative forms focus on flux computation at control volume
interfaces, making them directly compatible with numerical flux evaluation techniques like
Riemann solvers.
2. Stability and Convergence: Conservation ensures numerical schemes remain stable, particularly
for compressible flows where improper handling of fluxes can lead to unphysical solutions.
3. Boundary Conditions: Conservative forms simplify the imposition of physical boundary
conditions (e.g., inflow, outflow, no-slip) because fluxes represent physically interpretable
quantities.
4. Scalability: The conservative form enables efficient parallelization and scaling of CFD simulations,
as flux calculations are local to control volume interfaces.
10. Distinguish between conservative and non-conservative forms of fluid dynamic equations
Ans: - Conservative form is
U
+F = S
t
where: U represents the conserved variables (e.g., density, momentum, energy), F is the flux tensor
(flux of conserved quantities), S represents source terms (e.g., body forces, heat sources). While non-
conservative form is
Q
t
( )
+ A Q Q = S
( )
where: Q : Primitive variables (e.g., velocity, pressure, density), A Q : Coefficients matrix or Jacobian
of the flux terms.
11. What do you mean by Normalization of system and how does normalization of systems help
in understanding the flow dynamics across different regimes?
Ans: -
Normalization of Systems in Fluid Dynamics
Normalization is the process of scaling a system’s variables (such as velocity, time, and length) to non-
dimensional quantities that provide insight into the behaviour of the system across different scales or
regimes. In fluid dynamics, this is particularly useful for understanding flow behaviour across different
regimes (e.g., low Mach number flows, high Reynolds number flows, etc.) and simplifying complex
equations. By removing units, normalization enables comparison across systems with varying physical
parameters, making it easier to recognize universal patterns and trends.
Normalized (or non-dimensional) quantities often represent dimensionless groups, such as:
• Reynolds number (Re) for flow turbulence,
• Mach number (Ma) for compressibility effects,
• Prandtl number (Pr) for heat transfer characteristics.
These dimensionless groups are crucial for understanding flow dynamics across different flow regimes,
providing insight into scaling behaviour and controlling factors.
Benefits of Normalization in Understanding Flow Dynamics Across Regimes
1. Reveals Dominant Forces: By normalizing the governing equations (e.g., Navier-Stokes
equations), dimensionless numbers highlight which physical forces (inertial, viscous, pressure, etc.)
dominate the flow. This helps in identifying whether a flow is dominated by inertia (turbulence),
viscosity (laminar flow), or pressure differences (compressible effects).
2. Enables Comparison Across Different Systems: Normalization allows for the comparison of
similar flows in different systems, even if the absolute values of velocity, length, and other
parameters differ significantly. This can aid in understanding how small-scale laboratory
experiments relate to large-scale natural phenomena or industrial applications.
3. Scalability of Results: Normalized results allow for the extrapolation of findings from one set of
conditions to another. By solving the problem for a normalized flow (e.g., a flow with a certain
Reynolds number), one can predict how the system will behave at a different scale or under different
physical conditions.
4. Simplifies Governing Equations: By reducing the number of variables and transforming them into
dimensionless groups, the governing equations become simpler, more tractable, and often lead to
generalized solutions that apply across different regimes.
Unit-2
Long and short answer type questions
1. Explain how boundary conditions are incorporated in finite difference schemes for PDEs.
Ans: -Boundary conditions are incorporated in finite difference schemes for PDEs by modifying the
finite difference equations at the boundaries to enforce the prescribed conditions. Depending on the type
of boundary condition, the incorporation method varies:
Dirichlet Boundary Conditions
Definition: The solution is specified at the boundary, e.g., u ( a ) = ua , where a is the boundary point.
Implementation: Replace the finite difference equation at the boundary with the specified value. For
example, if u(0)=, then u0=0 is directly used in the computations.
Neumann Boundary Conditions
Definition: The derivative of the solution is specified at the boundary, e.g., u′(a)=g.
Implementation: Use a finite difference approximation for the derivative at the boundary. For example,
u1 − u0
for u ' ( 0 ) = g , modify the boundary equation to incorporate this relation.
u
Robin (Mixed) Boundary Conditions
Implementation: Combine finite difference approximations for u and u′ into a single equation. For
u1 − u0
example, u0 + = g.
u
Periodic Boundary Conditions
Definition: The solution values at the two ends of the domain are equal, e.g., u(a)=u(b).
Implementation: Relate the values at one boundary to the opposite boundary. For example, replace u0
with un and vice versa in the finite difference equations.
General Steps for Incorporation:
1. Modify Equations at the Boundary: Replace or adjust the finite difference equations at the
boundary points according to the type of boundary condition.
2. Update the Matrix/System: When solving a system of equations, the boundary conditions are
included in the system matrix or the right-hand side vector.
3. Consistency Check: Ensure that the boundary conditions align with the interior finite
difference scheme for smooth transitions.
2. What is the significance of the Courant-Friedrichs-Lewy (CFL) condition?
Ans: - The Courant-Friedrichs-Lewy (CFL) condition is a critical stability criterion in numerical
methods for solving partial differential equations, particularly for explicit finite difference schemes. It
establishes a relationship between the time step, spatial grid size, and wave propagation speed, ensuring
that numerical computations remain stable and physically meaningful.
The CFL condition is rooted in the principle that information, such as wavefronts or disturbances,
should not propagate faster in the numerical scheme than it does in the physical system being modelled.
If the condition is violated, numerical instabilities can arise, leading to unrealistic or divergent solutions.
For example, in hyperbolic PDEs, where wave propagation plays a central role, adhering to the CFL
condition ensures that the numerical domain of dependence matches the physical domain of
dependence.
This condition does not guarantee convergence or accuracy, but it is a necessary requirement for stability
in many explicit methods. Implicit methods, on the other hand, are less restricted by the CFL condition,
allowing larger time steps, albeit with increased computational effort. The CFL condition thus
influences the choice of numerical methods and the parameters used, balancing accuracy, stability, and
computational efficiency.
"A consistent finite difference scheme for a well-posed linear initial value problem is convergent
if and only if it is stable."
It contains the following terms;
• Consistency: The numerical scheme accurately approximates the governing differential
equation. This is typically measured by the truncation error, which must tend to zero as the grid
sizes (Δx,Δt) approach zero.
• Stability: The numerical solution does not grow unboundedly as the computation progresses,
ensuring that errors introduced at each step do not amplify uncontrollably.
• Convergence: The numerical solution approaches the exact solution of the differential equation
as the grid is refined (Δx,Δt→0).
Significance:
The theorem establishes a direct connection between stability and convergence for consistent schemes,
simplifying the analysis of numerical methods. By ensuring consistency and stability, one can guarantee
that a finite difference scheme will provide accurate results. Stability is typically verified using
techniques like the von Neumann stability analysis.
Convergence is a critical aspect of the accuracy of a numerical scheme. A convergent method ensures
that as computational resolution increases, the numerical errors (truncation errors, round-off errors, etc.)
diminish, and the computed solution aligns with the exact solution of the governing equations.
The rate of convergence is often quantified by comparing solutions at successive refinements of the grid
or time step, with higher-order methods typically converging faster than lower-order ones. For
convergence to occur, the numerical method must also be consistent (accurately approximating the
differential equation) and stable (controlling the growth of errors). These three properties—consistency,
stability, and convergence—are interconnected and collectively determine the reliability of a numerical
method, as highlighted by the Lax equivalence theorem.
du u ( xi +1 ) − u ( xi )
dx xi x
Backward difference
du u ( xi ) − u ( xi −1 )
dx xi x
Central difference
du u ( xi +1 ) − u ( xi −1 )
dx xi 2x
For multidimensional problems or problems with fine spatial grids, the resulting system of equations
can become very large, leading to significant demands on memory and processing power. Additionally,
constructing and solving these systems may require sophisticated numerical techniques, such as sparse
matrix solvers or preconditioning, further adding to the complexity.
Despite these challenges, implicit methods are often preferred for their stability and ability to handle
larger time steps, making them more suitable for stiff equations or problems requiring long-term
simulations. However, the trade-off between computational cost and stability must be carefully
considered when choosing an implicit method.
Unit-3
Long and short answer type questions
1. What are the assumptions underlying the stream function equation for steady flow?
Ans: - The assumptions underlying the stream function equation for steady flow are as follows:
Incompressible Flow: The flow is assumed to be incompressible, meaning the density of the fluid is
constant throughout the flow. This assumption leads to the requirement that the divergence of the
velocity field is zero, ∇⋅v=0. The stream function automatically satisfies this condition for two-
dimensional flow, ensuring mass conservation.
Steady Flow: The flow is assumed to be steady, meaning the fluid's velocity at any given point does not
change with time. The stream function equation for steady flow describes the flow at a fixed point in
time, where the velocity field is time-independent.
Two-Dimensional Flow: The flow is assumed to be two-dimensional, which means the flow variables
(velocity components, pressure, etc.) vary only in the two spatial directions (typically x and y). In this
case, the stream function is a function of x and y only, ψ=ψ(x,y), and it simplifies the analysis compared
to three-dimensional flow.
Irrotational or Rotational Flow: While the stream function can be used for both irrotational and
rotational flow, in many cases, it is applied to irrotational flow, where the vorticity (the curl of the
velocity field) is zero. This assumption simplifies the analysis, as it leads to the possibility of
representing the flow as a potential flow, where the velocity field can be derived from a scalar potential
function.
No External Forces: The stream function equation often assumes that there are no external forces acting
on the fluid, such as body forces (gravity, electromagnetic forces) or surface forces, which would
otherwise complicate the equations governing the flow.
Constant Fluid Properties: The fluid properties, such as viscosity, are assumed to be constant (i.e., the
fluid is homogenous and its properties do not change spatially or with time). This is important for
deriving simplified forms of the governing equations, such as the Navier-Stokes equations for steady,
incompressible flow.
Continuity of the Flow: The fluid is assumed to flow continuously and without discontinuities, meaning
the velocity field is smooth and continuous across the flow domain. This assumption ensures that the
stream function exists and is well-defined across the entire domain.
2. Explain the concept of grid refinement in the context of numerical solutions for advective-
diffusion equations.
Ans: - Grid refinement in the context of numerical solutions for advective-diffusion equations refers
to the process of increasing the resolution of the computational grid in order to improve the accuracy
of the solution, especially in regions with steep gradients or sharp features like boundary layers or
discontinuities. The advective-diffusion equation is a partial differential equation that models the
transport of a substance due to both advection (convection) and diffusion, and numerical solutions
often require careful treatment of the grid to capture these effects accurately.
The concept and its significance are given in the following points;
Improvement of Solution Accuracy
Grid refinement involves reducing the grid spacing (i.e., increasing the number of grid points) to obtain
a finer resolution of the solution. This improves the accuracy of the numerical solution because smaller
grid cells allow the model to capture finer details of the solution, such as sharp fronts or steep gradients
in concentration.
For the advective-diffusion equation, where the solution can change rapidly (especially in the presence
of high advection or strong diffusion), coarse grids may fail to resolve these variations, leading to
inaccurate predictions.
Handling Steep Gradients
In advection-dominated problems, large gradients can occur in the solution, particularly near shock
fronts or in boundary layers, where the substance concentration changes rapidly over a short distance.
On coarse grids, these steep gradients may not be properly resolved, and numerical errors can
accumulate.
By refining the grid in these regions, the numerical method can better capture these steep changes,
reducing errors and improving the overall solution quality.
Enhancing Stability
In some cases, refining the grid can also improve the stability of numerical schemes. For instance,
advection schemes may suffer from numerical diffusion or oscillations when using a coarse grid. A
finer grid can mitigate these issues, allowing for better resolution of the flow dynamics and improving
stability.
However, this is only true if the numerical scheme is properly designed to handle smaller grid sizes
without introducing instability.
Adaptive Grid Refinement
Adaptive grid refinement is an advanced technique where the grid is dynamically refined in regions
of the domain that need more resolution (for example, where sharp gradients are detected) and
coarsened elsewhere to save computational resources.
This approach allows for more efficient simulations by focusing computational effort on the most
critical regions, improving both accuracy and computational efficiency.
Trade-offs Between Accuracy and Computation
While grid refinement increases accuracy, it also increases the computational cost. Finer grids require
more points to solve, leading to increased memory and computational time. Therefore, the choice of
grid resolution involves a trade-off between accuracy and computational efficiency.
For large or complex problems, this trade-off must be carefully balanced, and adaptive refinement
methods can be helpful in managing computational resources while maintaining accuracy.
Impact on the Numerical Scheme
The numerical method used to solve the advective-diffusion equation also influences the need for grid
refinement. For example, higher-order schemes (like finite volume or spectral methods) can provide
more accurate results on coarser grids compared to lower-order methods, potentially reducing the need
for fine grid refinement.
However, some schemes, such as those that focus on capturing the advection term accurately (e.g.,
upwind schemes), may still benefit from grid refinement, particularly in regions of high velocity or
sharp concentration changes.
Convergence of the Solution
Grid refinement also plays a role in the convergence of the numerical solution. As the grid is refined
(i.e., as the grid spacing is reduced), the numerical solution should converge to the exact solution of the
advective-diffusion equation, assuming the scheme is consistent and stable.
By refining the grid, one can perform a convergence study to ensure that the solution is approaching
the true physical behaviour, especially in critical regions.
3. How does the Courant-Friedrichs-Lewy (CFL) condition affect numerical solutions for
advection-dominated problems?
Ans: -
Effect of the CFL Condition on Numerical Solutions
• Advection-Diffusion Problems
In advection-diffusion problems (where both advection and diffusion contribute to the solution), the
CFL condition still applies, but it becomes more complex because diffusion can act to smooth out
gradients and reduce the need for stringent time step control. In advection-dominated cases, the
advection term dominates the solution, so the time step needs to be carefully controlled according to
the CFL condition to avoid instability or loss of accuracy.
Unit-4
Long and short answer type questions
1. Velocity components: These describe the speed and direction of the fluid at each point in space
and time. In three-dimensional flow, the velocity is expressed in terms of its components u, v,
and www (in the x, y, and z directions, respectively).
2. Pressure: The pressure p is a scalar quantity that represents the normal force per unit area
exerted on the fluid.
3. Density: The density ρ of the fluid describes how much mass is contained in a unit volume. In
some cases, for incompressible flows, the density is assumed to be constant.
4. Temperature (optional): In thermal fluid dynamics, the temperature T can also be considered
a primitive variable, especially in problems involving heat transfer.