Stanford PSAAP CenterMulti-Physics Adjoints and Solution Verification
Karthik DuraisamyFrancisco Palacios
Juan AlonsoThomas Taylor
Predictive Science: Verification and Error Budgets
Certification,QMU
Real world problem
Numerical Errors
Uncertainties
Use
Quantifying numerical / discretization errors is a necessary first step to quantify sources of uncertainty. Controlling numerical errors is necessary to achieve certification.
Computational budget must be balanced between addressing numerical and UQ errors.
Mathematical Model
Assumptions + Modeling
Numerical solution
Discretization
Key Accomplishments
• Full Discrete Adjoint Solver for Compressible RANS Equations with turbulent combustion
Fully integrated with flow solver Massively parallel Robust Convergence
• Application to variety of PSAAP center problems including full Scramjet combustor
• New developments Stochastic adjoints Hybrid adjoints Robust grids for UQ
Capability Case Typ. Verific. Validation Mesh conv
Error Est
GoalAdapt
UQ Loop
Inviscid Disc / BC
Ringleb 2D Analytic
InviscidDisc/Shocks
hyshot/1D comb model
2D DLR
Table lookup Shock-ind Comb
2D Numeric
Viscous Disc Lam SBLI 2D 6th Order Hakkinen
Turbulence STBLI 2D LES-Morgan
Turbulence Shock train 2D LES-Morgan
Turbulence UQ Expt 2D/3D Eaton/LES
Turbulence Cold Hyshot 2D DLR
Turb+Comb React Mix Layer
2D
Turb+Comb Hyshot 3D DLR
Use of Adjoints in V & V
RANS + Combustion: Governing equations 5 Flow equations
2 Turbulence model equations
+
+
3 Combustion model equations (FPVA), Peters 2000; Terrapon 2010
+
Equations of state
+
Material properties
Table lookup(Functions of transported variables and pressure)
The Discrete Adjoint Equations
Conserved Variables
Flow Equations
Adjoint Equations
Computed using Automatic Differentiation, so can be arbitrarily complexNote: Interpolation operators can also be differentiated
Non-zero elements in Jacobian:33x10x10xN[For 3D structured mesh]
Contours of
Sample QoI : Shock crossing point in UQ Experiment
n=2: QoI = 2.1362e-01n=4: QoI = 2.1161e-01n=8: QoI = 2.1146e-01
Truly unstructured grids with shocks and thin features result in very poorly conditioned systems
Original system : Preconditioned GMRES not effective
Iterative solution: More robust
Adjoint Equations : Solution
Exact or approximate Jacobians
Laminar SBLI @ Rex = 3x105
Air: V=1800 m/s,T= 1550 K
H2: V=1500 m/s,T= 300 K
Splitter plate
QoI
OH MassFraction
Pressure
K-w SST withFPVA model on a mesh of 5000 CVs
Supersonic Combustion model problem
Supersonic Combustion model problem:
Exact Jacobians : CFL ~ 1000+Approx Jacobians : CFL ~ 0.1
Full Adjoint
Frozen turbulence
Governing equation and functional on Error estimate on
Goal oriented Error estimation
Have also extended it to estimate and control stochastic errors
(Venditti & Darmofal)
Test 1: Shock-Turbulent Boundary Layer Interaction
Reference Error: 3.1 e-04
LES RANS
Incoming BL: Mach number = 2.28, Rϑ = 1500, Shock deflection angle = 8o
Adapive Mesh refinement QoI: Integrated pressure on lower wall
2.5 % flagged 5 % flagged 25 % flagged
Gradient based
Adjoint based
Forebody Ramp Inlet/Isolator Combustor Nozzle/Afterbody
Fuel Injection
FlowMach ~8
Application to Scramjet Combustion
Air 1800 m/s, 1300 K, 1.2 bar
H2
300K, 5 bar (total)
Wall pressures
Upper wall Lower wall
Adjoint Solution QoI : avg pressure at Comb exit (lower wall)
24 hrs, 840 procs:Local LU preconditioning + GMRES
Adjoint Error estimates QoI : avg pressure at Comb exit (lower wall)
QoI : 282.58 kPa ; Error estimate: 2.76 kPa (0.98%)
Goal oriented refinement QoI : Stagnation pressure at Nozzle exit
Goal oriented mesh refinement : Results
Baseline meshAdapted mesh
GoverningEquations
DiscreteGoverningEquations
LinearizedGoverningEquations
HybridAdjoint
Equations
Discretized Adjoint
Equations
DiscretizeLinearize
Discretize
Discretize
Linearize
Linearize
ContinuousAdjoint
Equations
Equations that are difficult/impossible
analytically
Equations with existing analytical
formulations/code
Towards a hybrid adjoint
Towards a hybrid adjoint
Discrete
Continuous
Hybrid
Development + – ±
Compatibility with discretized PDE
+ – ?
Compatibility with continuous PDE
– + ?
Surface formulation for gradients
– + ?
Arbitrary functionals
+ – +
Non-differentiability
+ – +
Computational cost
– + ?
Flexibility in solution
– + ±
See Tom Taylor Poster
Adjoint Solver Status & Applications
• A full discrete adjoint implementation (using automatic differentiation) has been developed & verfied in Joe for the compressible RANS equations with the following features
Turbulence (k-w, SST and SA models) Multi-species mixing Combustion with FPVA • Capabilities are used in different applications in PSAAP Estimation of numerical errors
Mesh adaptation Robust grids for UQ
Estimation and control of uncertainty propagation errors Sensitivity and risk analysis (acceleration of MC sampling) (Q. Wang)
Balance of Errors and uncertainties (J. Witteveen)• Continuous adjoint also available in Joe for the compressible laminar NS
equations• A new hybrid adjoint formulation developed and applied to idealized problems• Massively parallel implementation available using MUM and PETSC