Systematic workflow for fluid dynamics analysis from problem setup to validation
A comprehensive, systematic approach to computational fluid dynamics (CFD) and analytical fluid mechanics problems.
This workflow guides you through complete fluid dynamics analysis, from initial problem formulation through validation. It ensures rigorous treatment of governing physics, appropriate model selection, and proper verification of results.
Physical Domain:
Domain Size Considerations:
Reynolds Number Analysis:
Re = ρVL/μ = VL/ν
Where:
- ρ: density
- V: characteristic velocity
- L: characteristic length
- μ: dynamic viscosity
- ν: kinematic viscosity
Flow Regime Classification:
Mach Number Analysis:
Ma = V/c
Where:
- V: flow velocity
- c: speed of sound = √(γRT)
Compressibility Classification:
Froude Number (free surface flows):
Fr = V/√(gL)
Strouhal Number (unsteady flows):
St = fL/V
Prandtl Number (heat transfer):
Pr = ν/α = μcp/k
Grashof Number (natural convection):
Gr = gβΔTL³/ν²
Incompressible:
∇·V = 0
Compressible:
∂ρ/∂t + ∇·(ρV) = 0
Incompressible, Newtonian fluid:
ρ(∂V/∂t + V·∇V) = -∇p + μ∇²V + ρg
Component form (Cartesian):
ρ(∂u/∂t + u∂u/∂x + v∂u/∂y + w∂u/∂z) = -∂p/∂x + μ(∂²u/∂x² + ∂²u/∂y² + ∂²u/∂z²) + ρgₓ
ρ(∂v/∂t + u∂v/∂x + v∂v/∂y + w∂v/∂z) = -∂p/∂y + μ(∂²v/∂x² + ∂²v/∂y² + ∂²v/∂z²) + ρgᵧ
ρ(∂w/∂t + u∂w/∂x + v∂w/∂y + w∂w/∂z) = -∂p/∂z + μ(∂²w/∂x² + ∂²w/∂y² + ∂²w/∂z²) + ρgᵣ
Compressible form:
ρ(∂V/∂t + V·∇V) = -∇p + ∇·τ + ρg
Where stress tensor:
τᵢⱼ = μ(∂uᵢ/∂xⱼ + ∂uⱼ/∂xᵢ) + λ(∇·V)δᵢⱼ
For compressible flows:
ρcp(∂T/∂t + V·∇T) = ∇·(k∇T) + Φ + Q
Where:
Total energy form:
∂(ρE)/∂t + ∇·(ρEV) = -∇·(pV) + ∇·(k∇T) + ∇·(τ·V)
Reynolds-Averaged Navier-Stokes (RANS): Decompose variables: u = ū + u'
Reynolds Stress Tensor:
τᵢⱼᴿᴬᴺˢ = -ρu'ᵢu'ⱼ
Closure Models Decision Tree:
START
│
├─ Simple geometry, equilibrium turbulence?
│ └─ YES → k-ε Standard
│
├─ Wall-bounded flow, adverse pressure gradient?
│ └─ YES → k-ω SST (Menter)
│
├─ Separated flow, vortex shedding?
│ └─ YES → k-ω SST or Transition SST
│
├─ Swirling flow, rotation?
│ └─ YES → Reynolds Stress Model (RSM)
│
├─ High accuracy needed, large-scale unsteadiness?
│ └─ YES → Large Eddy Simulation (LES)
│
└─ Research, turbulence structure critical?
└─ YES → Direct Numerical Simulation (DNS)
Model Comparison:
| Model | Advantages | Limitations | Best Use Cases |
|---|---|---|---|
| k-ε Standard | Robust, well-validated | Poor near walls, separated flows | Industrial flows, simple geometries |
| k-ε Realizable | Better for separated flows | Still needs wall functions | Complex geometries, separation |
| k-ω Standard | Good near walls | Sensitive to freestream | Wall-bounded flows |
| k-ω SST | Excellent all-around | Higher computational cost | Aerodynamics, adverse gradients |
| Spalart-Allmaras | One equation, efficient | Calibrated for aerospace | Airfoils, external aerodynamics |
| RSM | Captures anisotropy | 5-7 equations, complex | Swirling, rotating flows |
| LES | Resolves large eddies | Very expensive | Unsteady flows, acoustics |
| DNS | No modeling errors | Extremely expensive | Fundamental research, Re < 10⁴ |
Velocity Inlet:
Calculating turbulence quantities:
k = 3/2(UI)²
ε = C_μ^(3/4) k^(3/2) / l
ω = k^(1/2) / (C_μ^(1/4) l)
Where C_μ = 0.09
Pressure Inlet:
Mass Flow Inlet:
Pressure Outlet:
Outflow:
Outlet Distance Requirement:
No-Slip Wall (standard):
Slip Wall:
Wall Function Approach: For turbulent flows, use wall functions when:
y⁺ = ρu_τy/μ
u_τ = √(τ_w/ρ) [friction velocity]
Near-Wall Resolution Requirements:
| Approach | y⁺ first cell | Total prism layers | Growth rate |
|---|---|---|---|
| Wall Functions | 30-300 | 3-5 | 1.2-1.3 |
| Low-Re Model | y⁺ < 1 | 10-20 | 1.1-1.2 |
| Enhanced Wall Treatment | y⁺ < 5 | 8-15 | 1.15-1.25 |
Moving Wall:
Symmetry:
Periodic:
Volume of Fluid (VOF):
Level Set Method:
Mesh Types:
| Mesh Type | Advantages | Disadvantages | Best For |
|---|---|---|---|
| Structured (Hexahedral) | Efficient, accurate | Complex geometry difficult | Simple domains, channels |
| Unstructured (Tetrahedral) | Flexible geometry | More cells needed | Complex CAD geometries |
| Hybrid (Prism + Tet) | Best of both | Requires careful setup | Most CFD applications |
| Polyhedral | Fewer cells, stable | Specialized mesher | Industrial CFD |
Mesh Quality Metrics:
Grid Independence Study:
Refinement ratio: r = 1.5 to 2.0
Test at least 3 mesh levels:
- Coarse: N cells
- Medium: r²N cells
- Fine: r⁴N cells
Check convergence of key outputs:
- Forces (drag, lift)
- Pressures at critical points
- Flow rates
Richardson Extrapolation:
f_exact ≈ f_fine + (f_fine - f_coarse)/(r^p - 1)
Where p is the order of accuracy
Critical y⁺ ranges:
Viscous sublayer: y⁺ < 5
Buffer layer: 5 < y⁺ < 30
Log-layer: 30 < y⁺ < 300
Outer layer: y⁺ > 300
First cell height calculation:
y = y⁺μ/(ρu_τ)
For flat plate:
u_τ ≈ U∞√(C_f/2)
C_f = 0.058Re_L^(-0.2) [turbulent]
Estimating y for desired y⁺:
Example: Airfoil at Re = 1×10⁶, V = 50 m/s
1. Estimate C_f ≈ 0.0037
2. u_τ = 50√(0.0037/2) = 2.15 m/s
3. For y⁺ = 1: y = 1×1.5e-5/(1.225×2.15) ≈ 5.7e-6 m
First cell: 5.7 μm
CFL Condition (Courant-Friedrichs-Lewy):
CFL = VΔt/Δx ≤ CFL_max
For explicit schemes: CFL < 1
For implicit schemes: CFL < 10-20 (stability)
CFL < 1-5 (accuracy)
Time step calculation:
Δt = CFL × Δx_min / V_max
Temporal Resolution for Unsteady Features:
Dual Time Stepping:
Pressure-Velocity Coupling:
| Algorithm | Type | Advantages | Use Cases |
|---|---|---|---|
| SIMPLE | Segregated | Memory efficient | Steady state |
| SIMPLEC | Segregated | Faster convergence | Steady/transient |
| PISO | Segregated | Transient accuracy | Highly unsteady |
| Coupled | Fully-coupled | Robust, fast | Compressible, complex |
Momentum Discretization:
Pressure Interpolation:
Residual Monitoring:
Continuity: < 1e-4
Velocity: < 1e-4
Turbulence: < 1e-4
Energy: < 1e-6
Additional Convergence Checks:
Convergence plots should show:
Purpose: Stabilize solution, prevent divergence
Typical values (SIMPLE):
Pressure: 0.3
Momentum: 0.7
Turbulence (k): 0.8
Turbulence (ε,ω): 0.8
Energy: 0.9
Adjustment strategy:
Essential Visualizations:
Velocity Contours/Vectors:
Pressure Distribution:
Streamlines/Pathlines:
Vorticity:
Wall Shear Stress:
Turbulence Quantities:
Pressure and Viscous Forces:
F_pressure = ∫∫ p·n dA
F_viscous = ∫∫ τ·n dA
F_total = F_pressure + F_viscous
Non-dimensional Coefficients:
C_D = D/(½ρV²A) [Drag coefficient]
C_L = L/(½ρV²A) [Lift coefficient]
C_M = M/(½ρV²AL) [Moment coefficient]
Pressure Coefficient:
C_p = (p - p_∞)/(½ρV²)
Friction Coefficient:
C_f = τ_w/(½ρV²)
Verification (Solving equations right):
GCI = F_s |ε|/(r^p - 1)
Where:
- F_s = safety factor (1.25 for 3+ grids)
- ε = (f_fine - f_coarse)/f_fine
- r = refinement ratio
- p = order of accuracy
Validation (Solving right equations):
Analytical Solutions:
Experimental Data:
Benchmark Cases:
Validation Metrics:
Mean Absolute Error:
MAE = (1/N)Σ|φ_CFD - φ_exp|
Root Mean Square Error:
RMSE = √[(1/N)Σ(φ_CFD - φ_exp)²]
Coefficient of Determination:
R² = 1 - Σ(φ_exp - φ_CFD)²/Σ(φ_exp - φ̄_exp)²
START: Define Problem
│
├─ Calculate Re = ρVL/μ
│
├─ Re < 1 (Stokes flow)
│ └─ Use: Creeping flow equations
│
├─ 1 < Re < 100 (Low Re)
│ └─ Use: Laminar NS, full domain
│
├─ Re < 2300 (Internal)
│ └─ Use: Laminar NS
│
├─ 2300 < Re < 4000 (Transitional)
│ └─ Use: Transition models (γ-Re_θ)
│
├─ Re > 4000 (Turbulent)
│ ├─ Calculate Ma = V/c
│ │
│ ├─ Ma < 0.3
│ │ └─ Incompressible RANS
│ │
│ ├─ 0.3 < Ma < 1
│ │ └─ Compressible RANS
│ │
│ └─ Ma > 1
│ └─ Compressible + shock capturing
│
└─ Unsteady features?
├─ YES → Calculate St = fL/V
│ ├─ St > 0.1 → Use URANS or LES
│ └─ St < 0.1 → RANS may suffice
└─ NO → RANS sufficient
START: Turbulent Flow Confirmed
│
├─ Computational Budget?
│
├─ VERY HIGH (Research)
│ └─ Use DNS (if Re allows)
│
├─ HIGH
│ ├─ Massively separated?
│ │ └─ YES → LES (WALE, Smagorinsky)
│ │
│ └─ NO → URANS with fine mesh
│
└─ MODERATE (Engineering)
│
├─ Flow Type?
│
├─ EXTERNAL (Aero/Hydro)
│ ├─ Pressure gradient?
│ │ ├─ ADVERSE → k-ω SST
│ │ └─ FAVORABLE → Spalart-Allmaras
│ │
│ └─ Separation likely? → k-ω SST
│
├─ INTERNAL (Pipes, Channels)
│ ├─ Simple geometry → k-ε Standard
│ ├─ Complex, bends → k-ε Realizable
│ └─ Heat transfer → k-ω SST
│
├─ ROTATING/SWIRLING
│ └─ RSM (Reynolds Stress Model)
│
└─ TRANSITIONAL
└─ γ-Re_θ Transition SST
START: Domain Defined
│
├─ Geometry Complexity?
│
├─ SIMPLE (Rectangular, cylindrical)
│ └─ Structured hexahedral
│ └─ O-grid for cylinders
│
├─ MODERATE
│ └─ Hybrid mesh
│ ├─ Prism layers at walls
│ └─ Hex/tet in core
│
└─ COMPLEX (CAD geometry)
└─ Unstructured
├─ Prism layers at walls (always)
└─ Tet or poly in core
│
├─ Boundary Layer Resolution?
│
├─ WALL FUNCTIONS (y⁺ = 30-300)
│ ├─ First cell: y⁺ ≈ 50
│ ├─ Prism layers: 3-5
│ └─ Growth rate: 1.2-1.3
│
└─ NEAR-WALL RESOLUTION (y⁺ < 1)
├─ First cell: y⁺ < 1
├─ Prism layers: 10-20
├─ Growth rate: 1.1-1.2
└─ At least 10 cells in boundary layer
│
└─ Refinement Zones?
├─ Wake regions: 2-3× density
├─ Shear layers: graded refinement
├─ Recirculation: fine mesh
└─ Free stream: coarse OK
Diagnosis:
Solutions:
Diagnosis:
Solutions:
Diagnosis:
Solutions:
Always start with problem physics:
Build mesh systematically:
Start simple, add complexity:
Monitor everything:
Validate rigorously:
Report uncertainty:
Foundational Texts:
Validation Databases:
Best Practice Guidelines: