Skip to content
ME-505 · FEM/CFD Lab/Quick Revision Short Notes

FEM/CFD Lab (ME-505) - Unit 4 Short Notes

UNIT 4: ADVANCED ANALYSIS & SPECIALIZED APPLICATIONS (FEM/CFD Lab)

This unit covers the practical execution of complex simulations, moving beyond basic linear static analysis to dynamic, nonlinear, and coupled problems. The focus is on proper setup, solver selection, result interpretation, and validation.


4.1 Pre-Processing for Complex Models

4.1.1 Advanced Meshing Strategies
  • Adaptive Mesh Refinement (AMR): Automatically refines mesh in regions with high solution gradients (e.g., shock waves, stress concentrations) during/after initial solve iterations. Crucial for CFD turbulence and nonlinear FEM.

  • Boundary Layer Mesh (Inflation Layers): Orthogonal, stretched cells normal to walls to resolve steep velocity/temperature gradients without excessive cell count. Governed by y+ value for turbulent flows.

  • Mesh Quality Metrics:

    | Metric | Ideal Value | Problem if Poor | | :--- | :--- | :--- | | Skewness | 0 (Equilateral) | >0.9 causes solution errors, divergence | | Aspect Ratio | ~1 (Square) | >10:1 reduces accuracy, especially in boundary layers | | Orthogonal Quality | 1 (Perfect) | <0.1 leads to poor convergence | | Jacobian Ratio | 1 | Detects distorted/inverted elements |

  • Mesh Independence Study: Procedure to ensure results are not mesh-dependent.

    1. Solve on a coarse mesh.

    2. Systematically refine mesh (e.g., double element count).

    3. Compare key results (e.g., max stress, drag coefficient).

    4. Stop when change in result is < 1-5%.

[!TIP] Exam Focus: Be prepared to define each mesh metric and explain why a poor aspect ratio harms a boundary layer solution.

4.1.2 Defining Realistic Physics & Coupling
  • Multi-Physics Coupling:

    • Fluid-Structure Interaction (FSI): Fluid pressure loads deform structure; deformed structure changes fluid domain.

    • Thermo-Mechanical: Temperature field induces thermal strain $$\displaystyle \epsilon_{th} = \alpha \Delta T $$, generating stress.

  • Advanced Material Models:

    • Hyperelasticity: For rubbers/elastomers (Mooney-Rivlin, Ogden models). Requires stress-stretch experimental data.

    • Plasticity: Yield Criterion (von Mises, Tresca), Hardening Law (isotropic, kinematic). Input via true stress-strain curve.

    • Creep: Time-dependent deformation at high temperature (Norton's law: $$\displaystyle \dot{\epsilon} = A \sigma^n $$).

  • User-Defined Functions (UDFs)/Expressions: Custom code/expressions for:

    • Time-varying boundary conditions (e.g., $$\displaystyle P(t) = P_0 \sin(\omega t) $$).

    • Spatially varying material properties.

    • Custom source terms in governing equations.


4.2 Solver Configuration & Advanced Solution Techniques

4.2.1 Solver Selection & Settings
  • Direct vs. Iterative Solvers:

    | Solver Type | Memory Use | Speed | Best For | | :--- | :--- | :--- | :--- | | Direct (e.g., MUMPS, PARDISO) | Very High | Predictable | Small-medium models, linear problems, stress recovery | | Iterative (e.g., CG, GMRES) | Low-Moderate | Variable, scalable | Very large models, nonlinear problems, CFD |

  • Implicit vs. Explicit Dynamics:

    • Implicit: Unconditionally stable for large time steps $\Delta t$. Requires solving $$\displaystyle \mathbf{K} \Delta \mathbf{u} = \mathbf{R} $$ each step. Computationally expensive per step. Used for static, quasi-static, slow dynamics.

    • Explicit: Conditionally stable ($$\displaystyle \Delta t < \Delta t_{crit} $$). No matrix inversion. Very fast per step. Used for high-speed impact, crash, explosion.

    • Critical time step (Explicit): $$\displaystyle \Delta t_{crit} = \frac{L}{c} $$, where $L$ is smallest element dimension, $c$ is wave speed.

  • Time-Stepping:

    • Automatic: Solver adjusts $\Delta t$ to meet convergence.

    • Fixed: User-defined $\Delta t$ (essential for harmonic analysis, prescribed motion).

    • Convergence Criteria: $$\displaystyle \frac{\| \Delta \mathbf{u} \|}{\| \mathbf{u} \|} < \epsilon_{u} $$ (displacement), $$\displaystyle \frac{\| \Delta \mathbf{R} \|}{\| \mathbf{R} \|} < \epsilon_{r} $$ (residual).

4.2.2 Handling Nonlinearities
  • Newton-Raphson Method: Iterative solution for $$\displaystyle \mathbf{R}(\mathbf{u}) = \mathbf{0} $$.

$$\mathbf{K}_T^{(i)} \Delta \mathbf{u}^{(i)} = -\mathbf{R}^{(i)}$$

where $$\displaystyle \mathbf{K}_T $$ is the **tangent stiffness matrix**. Update: $$\displaystyle \mathbf{u}^{(i+1)} = \mathbf{u}^{(i)} + \Delta \mathbf{u}^{(i)} $$.

\boxed{\text{Converges quadratically near solution if good tangent stiffness.}}
  • Arc-Length Method: For post-buckling or snap-through problems where load-displacement curve turns back ( softening). Controls both load and displacement magnitude along an arc in $\{\mathbf{u}, \lambda\}$ space.

  • Load Steps & Substeps: Divide total load into increments. Substeps within a load step help convergence in highly nonlinear regions.

4.2.3 CFD-Specific Solver Settings
  • Turbulence Models:

    • RANS (Reynolds-Averaged): k-ε (free shear flows), k-ω SST (adverse pressure gradients, near walls).

    • LES (Large Eddy): Resolves large scales, models small scales. Computationally expensive.

  • Pressure-Velocity Coupling:

    • SIMPLE: For steady-state. Uses pressure correction equation.

    • PISO: For transient. Pressure correction done multiple times per timestep for better stability.

  • Discretization Schemes:

    • Advection (Convective Term): Upwind (stable, 1st order diffusive), QUICK (2nd order, may oscillate), Central Differencing (2nd order, unstable at high Pe).

    • Diffusion Term: Usually 2nd order central.

[!TIP] Common Pitfall: Using 1st order upwind for advection in a complex recirculating flow gives overly diffused (smoothed) results. Always check scheme order.


4.3 Core Advanced Analysis Types (Lab Exercises)

4.3.1 Transient Dynamic Analysis (FEM)
  • Modal Superposition: For linear systems. Solve eigenvalue problem $$\displaystyle (\mathbf{K} - \omega^2 \mathbf{M})\boldsymbol{\phi} = 0 $$ to get modes $$\displaystyle \boldsymbol{\phi}_i $$ and frequencies $$\displaystyle f_i $$. Response $$\displaystyle \mathbf{u}(t) = \sum_i \boldsymbol{\phi}_i q_i(t) $$. Fast for many time steps.

  • Full Transient: Direct integration (e.g., Newmark-$\beta$). Solves $$\displaystyle \mathbf{M}\ddot{\mathbf{u}} + \mathbf{C}\dot{\mathbf{u}} + \mathbf{K}\mathbf{u} = \mathbf{F}(t) $$ at each $\Delta t$. Handles large nonlinearities.

  • Load Types: Impulse (force-time history), Harmonic ($$\displaystyle F_0 \sin \omega t $$), Base excitation.

4.3.2 Nonlinear Static & Quasi-Static Analysis (FEM)
  • Large Deformation (Geometric Nonlinearity): Updates stiffness matrix each iteration (Updated Lagrangian). Includes stress stiffening (tension stiffening) and initial stress effects.

  • Contact Analysis:

    • Types: Frictional (Coulomb law: $f \leq \mu N$), Frictionless, Bonded.

    • Detection: Augmented Lagrangian or Penalty method.

    • Key Settings: Contact stiffness, penetration tolerance, contact stabilization (damping).

  • Material Nonlinearity: Define true stress-plastic strain curve after yield. Isotropic hardening expands yield surface; kinematic hardening translates it.

4.3.3 Advanced Steady-State & Transient CFD
  • External Aerodynamics: Far-field boundaries (pressure outlet, symmetry, velocity inlet). Wall functions for high-Re turbulent flows.

  • Conjugate Heat Transfer (CHT): Couples fluid convection with solid conduction. Requires matching thermal boundary conditions at fluid-solid interface.

  • Rotating Machinery: Use Moving Reference Frame (MRF) for steady-state approximation or Sliding Mesh for true transient interaction.

4.3.4 Introduction to Multi-Physics / Coupled Problems
  • Fluid-Structure Interaction (FSI):

    • One-Way: Fluid solution → pressure load on structure. Structure deformation ignored in fluid.

    • Two-Way: Bidirectional data transfer per time step. Requires partitioned (separate solvers) or monolithic (single system) approach.

  • Thermo-Mechanical: Sequential or coupled. Thermal expansion strain $$\displaystyle \epsilon_{th} = \alpha (T - T_{ref}) $$ added to mechanical strain.

  • Piezo-Electric: Mechanical stress $\sigma$ generates electric displacement $D$; electric field $E$ generates strain $S$. Governed by coupled constitutive equations.


4.4 Post-Processing, Validation & Interpretation

4.4.1 Advanced Result Visualization
  • CFD: Pathlines (steady flow), Streamlines (instantaneous), Particle Tracks (transient with inertia). Iso-Surfaces (e.g., constant temperature, Q-criterion for vortices).

  • FEM: Deformation Scaled (for clarity), Vector Plots (displacement, stress), Section Views.

  • Animation: Essential for transient dynamics (vibration modes, flow separation).

4.4.2 Quantitative Data Extraction
  • Probes/Points: Monitor variable (P, T, u) at a point vs. time.

  • Lines/Paths: Create XY plot (e.g., pressure drop along pipe length, temperature profile across wall).

  • Surfaces/Bodies: Calculate integrals:

    • Total heat flux: $\iint \mathbf{q} \cdot d\mathbf{A}$

    • Mass flow rate: $\iint \rho \mathbf{v} \cdot d\mathbf{A}$

    • Reaction force/moment: $\iint \boldsymbol{\sigma} \cdot d\mathbf{A}$

  • Derived Values: Drag coefficient $$\displaystyle C_D = \frac{2F_D}{\rho U^2 A} $$, Nusselt number $$\displaystyle Nu = \frac{hL}{k} $$.

4.4.3 Validation & Error Assessment
  • Comparison Levels:

    1. Analytical: Exact solutions for simplified cases (e.g., Couette flow, cantilever tip deflection).

    2. Experimental/Reference Data: Published benchmark results (e.g., NACA airfoil $$\displaystyle C_p $$ distribution).

    3. Code-to-Code: Compare with another trusted solver.

  • Error Sources:

    • Discretization Error: Due to finite mesh (estimated via mesh refinement).

    • Modeling Error: Simplified physics, boundary conditions.

    • Iterative Error: Incomplete convergence (check residual history).

    • Round-off Error: Negligible for double precision.

[!TIP] Lab Report Must: Always include a mesh sensitivity plot showing key result vs. element count to justify final mesh choice.


4.5 Troubleshooting & Best Practices in the Lab

4.5.1 Common Error Messages & Debugging
Error Message Likely Cause First Diagnostic Step
"Solution did not converge" Nonlinear: bad initial guess, too large load step. CFD: high under-relaxation, poor initial field. Check residual/convergence plot. Reduce load/CFL number.
"Negative volume/element distortion" Excessive mesh distortion in large deformation/contact. Check mesh quality metrics (skewness, Jacobian). Enable contact stabilization or mesh adaptivity.
"Divergence detected" (CFD) Unstable numerics: high Reynolds, bad boundary conditions, high under-relaxation factors. Reduce under-relaxation factors (e.g., pressure 0.3, momentum 0.7). Use first-order scheme temporarily. Check inlet turbulence parameters.
"Singular matrix" Unconstrained rigid body motion (FEM), bad contact setup, zero viscosity (CFD). Check boundary conditions (apply displacement/constraint). Verify contact pair definition.
4.5.2 Best Practices for Reliable Simulations
  1. Start Simple: Validate setup on a 2D axisymmetric or simplified 3D case before full model.

  2. Mesh Sensitivity is Mandatory: Never trust results from a single mesh.

  3. Scale Consistently: Ensure all inputs (geometry, material props, BCs) use compatible units (SI recommended: kg, m, s, Pa).

  4. Document Everything: Record solver settings, convergence criteria, mesh stats, assumptions. This is critical for lab reports and viva.

  5. Monitor Key Variables: Plot residuals, reaction forces, and key probe values during solve to catch divergence early.

  6. Use Appropriate Linear Solver: For large nonlinear problems, iterative solvers often outperform direct solvers in memory and time.

[!TIP] Golden Rule: Garbage In, Garbage Out (GIGO). The most sophisticated solver cannot compensate for a poorly meshed model, incorrect boundary conditions, or an inappropriate physics model. Always question your input first.

Go to where you left off?

Quick Add to Notes

Save questions, your own notes and screenshots into notes filed by unit. It takes a free account.

Create free account

Have an account? Log in