“Solve the equations right” Mathematical problem Validation :

Slides:



Advertisements
Similar presentations
CFD Modeling of Wind Farms in Flat and Complex Terrain J. M. Prospathopoulos, E. S. Politis, P. K. Chaviaropoulos K. G. Rados, G. Schepers, D. Cabezon,
Advertisements

CSE 330: Numerical Methods
Computational Modeling for Engineering MECN 6040
Copyright (c) 2004 Brooks/Cole, a division of Thomson Learning, Inc. Chapter 13 Nonlinear and Multiple Regression.
Lectures on CFD Fundamental Equations
Introduction to numerical simulation of fluid flows
Chapter 4 Roots of Equations
Chapter 1 Introduction The solutions of engineering problems can be obtained using analytical methods or numerical methods. Analytical differentiation.
Curve-Fitting Regression
1 Error Analysis Part 1 The Basics. 2 Key Concepts Analytical vs. numerical Methods Representation of floating-point numbers Concept of significant digits.
1 Seventh Lecture Error Analysis Instrumentation and Product Testing.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. by Lale Yurttas, Texas A&M University Chapter 171 Least.
CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4: KFUPM.
AIAA SciTech 2015 Objective The objective of the present study is to model the turbulent air flow around a horizontal axis wind turbine using a modified.
Ch 8.1 Numerical Methods: The Euler or Tangent Line Method
Introduction and Analysis of Error Pertemuan 1
Lecture Objectives Review SIMPLE CFD Algorithm SIMPLE Semi-Implicit Method for Pressure-Linked Equations Define Residual and Relaxation.
CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4: KFUPM CISE301_Topic1.
PROBABILITY (6MTCOAE205) Chapter 6 Estimation. Confidence Intervals Contents of this chapter: Confidence Intervals for the Population Mean, μ when Population.
CISE301_Topic11 CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4:
Curve-Fitting Regression
MECN 3500 Inter - Bayamon Lecture 3 Numerical Methods for Engineering MECN 3500 Professor: Dr. Omar E. Meza Castillo
6. Introduction to Spectral method. Finite difference method – approximate a function locally using lower order interpolating polynomials. Spectral method.
Introduction 1. Similarity 1.1. Mechanism and mathematical description 1.2. Generalized variables 1.3. Qualitative analysis 1.4. Generalized individual.
NCHRP Project Development of Verification and Validation Procedures for Computer Simulation use in Roadside Safety Applications SURVEY OF PRACTITIONERS.
Lecture 4: Statistics Review II Date: 9/5/02  Hypothesis tests: power  Estimation: likelihood, moment estimation, least square  Statistical properties.
Numerical Methods.
Lecture Objectives Review Define Residual and Relaxation SIMPLE CFD Algorithm SIMPLE Semi-Implicit Method for Pressure-Linked Equations.
MECH4450 Introduction to Finite Element Methods Chapter 9 Advanced Topics II - Nonlinear Problems Error and Convergence.
Non-Linear Models. Non-Linear Growth models many models cannot be transformed into a linear model The Mechanistic Growth Model Equation: or (ignoring.
Discretization Methods Chapter 2. Training Manual May 15, 2001 Inventory # Discretization Methods Topics Equations and The Goal Brief overview.
DIMENSIONAL ANALYSIS SECTION 5.
Tokyo 2015 A Workshop on CFD in Ship Hydrodynamics URANS Simulation of Surface Combatant using CFDShip-Iowa V.4 S. Bhushan and F. Stern IIHR-Hydroscience.
Lecture Objectives: Define 1) Reynolds stresses and
Linear Systems Numerical Methods. 2 Jacobi Iterative Method Choose an initial guess (i.e. all zeros) and Iterate until the equality is satisfied. No guarantee.
AIAA th AIAA/ISSMO Symposium on MAO, 09/05/2002, Atlanta, GA 0 AIAA OBSERVATIONS ON CFD SIMULATION UNCERTAINTIES Serhat Hosder, Bernard.
Code verification and mesh uncertainty The goal is to verify that a computer code produces the right solution to the mathematical model underlying it.
Chapter 7: The Distribution of Sample Means
1 CHAP 3 WEIGHTED RESIDUAL AND ENERGY METHOD FOR 1D PROBLEMS FINITE ELEMENT ANALYSIS AND DESIGN Nam-Ho Kim.
A V&V Overview of the 31st Symposium on Naval Hydrodynamics
EEE 431 Computational Methods in Electrodynamics
Objective Numerical methods SIMPLE CFD Algorithm Define Relaxation
Gauss-Siedel Method.
MANE 4240 & CIVL 4240 Introduction to Finite Elements
Lecture Objectives: Review Explicit vs. Implicit
CAD and Finite Element Analysis
© Fluent Inc. 1/10/2018L1 Fluids Review TRN Solution Methods.
Convergence in Computational Science
Introduction to Multigrid Method
Autar Kaw Benjamin Rigsby
Class Notes 18: Numerical Methods (1/2)
Objective Review Reynolds Navier Stokes Equations (RANS)
Lecture Objectives: Advance discretization methods
Objective Unsteady state Numerical methods Discretization
The application of an atmospheric boundary layer to evaluate truck aerodynamics in CFD “A solution for a real-world engineering problem” Ir. Niek van.
AIAA OBSERVATIONS ON CFD SIMULATION UNCERTAINITIES
AIAA OBSERVATIONS ON CFD SIMULATION UNCERTAINTIES
Numerical Analysis Lecture 16.
Convergence in Numerical Science
Objective Numerical methods Finite volume.
Lecture Objectives Review for exam Discuss midterm project
AIAA OBSERVATIONS ON CFD SIMULATION UNCERTAINTIES
Numerical Analysis Lecture13.
topic4: Implicit method, Stability, ADI method
Product moment correlation
SKTN 2393 Numerical Methods for Nuclear Engineers
topic4: Implicit method, Stability, ADI method
Propagation of Error Berlin Chen
CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4: KFUPM CISE301_Topic1.
Numerical Modeling Ramaz Botchorishvili
Presentation transcript:

“Solve the equations right” Mathematical problem Validation : Definitions Verification : “Solve the equations right” Mathematical problem Validation : “Solve the right equations” Science/engineering activity Roache, 1998 1

Verification includes two different activities: - Code Verification Definitions Verification includes two different activities: - Code Verification Guarantee that the computer code does not contain errors (bugs). Error evaluation that requires the knowledge of the exact solution - Solution/calculations Verification Estimate the numerical uncertainty for a numerical solution that has an unkown exact solution (Error estimation) 2

- Assessing the modeling uncertainty of Definitions Validation - Assessing the modeling uncertainty of (a selected aspect of) a mathematical model Needed: the definition of the quantities of interest the selection of a metric to quantify the modeling uncertainty (on-going topic of research) 3

An error is defined as the difference between Definitions − Error vs Uncertainty An error is defined as the difference between a given solution and its “true/exact” value. It has a sign and it requires the knowledge of the “truth” An uncertainty defines an interval that should contain the “true/exact” value with a certain degree of confidence. It is defined with a ∓ 4

- Discretization error Three components of the numerical error behave - Round-off error - Iterative error - Discretization error Three components of the numerical error behave differently with the increase of the number of degrees of freedom (grid refinement) 5

- Due to the finite precision of computers Numerical Error Round-off error: - Due to the finite precision of computers - Decreased by the use of double precision - May be dominant in ill-conditioned problems - It grows with the increase of the number of degrees of freedom (grid refinement) 6

− Round-off error, example: Polynomial interpolation in 2-D (or 3-D) Numerical Error − Round-off error, example: Polynomial interpolation in 2-D (or 3-D) (n+1)2 coefficients determined from (n+1)2 points where fi(xi,yi) is known 7

− Round-off error, example: Polynomial interpolation in 2-D (or 3-D) Numerical Error − Round-off error, example: Polynomial interpolation in 2-D (or 3-D) Coefficients of the polynomial obtained from the solution of a linear systems of algebraic equations First term of the main diagonal : 1 Last term of the main diagonal : xnyn 8

- Non-linear equations (convection in momentum equations) Numerical Error Iterative error: - Non-linear equations (convection in momentum equations) - Decoupling of the equations (turbulence model solved for a given mean velocity field and momentum equations solved with a “known” eddy-viscosity) 9

- Discretization schemes with explicit corrections Numerical Error Iterative error: - Discretization schemes with explicit corrections for the high-order terms - Solution of the systems of algebraic equations with iterative methods (Jacobi, Gauss-Seidel, Conjugate Gradients, GMRES, ...) 10

- In principle, it can be reduced to machine Numerical Error Iterative error: - In principle, it can be reduced to machine accuracy (if there are no problems with the round-off error) - The reduction of the iterative error becomes hardest with the increase of the number of degrees of freedom (grid refinement). Multigrid techniques may avoid problems with the size of the system of algebraic equations to solve 11

- It is important to define (know) the meaning of one iteration Numerical Error Iterative error: - It is important to define (know) the meaning of one iteration - Iterative error estimates based on differences or normalized residuals of the last iteration performed are not reliable - For iterative error estimates, the L∞ norm is a more appropriate choice than the L1and L2 norms 12

- RANS (with eddy-viscosity model) calculation Numerical Error Iterative error: - RANS (with eddy-viscosity model) calculation of the turbulent flow in a channel - Initial velocity field obtained from the specified profiles at the inlet - Solution converged to machine precision (10-14) 13

- Convergence criteria based on the maximum Numerical Error Iterative error: - Convergence criteria based on the maximum difference between consecutive iterations, et - Iterative error obtained from the difference to the solution converged to machine accuracy - Example of iterative errors for the horizontal velocity component, U1 14

Iterative error: Numerical Error Largest iterative error is 2 orders of magnitude larger than et! 15

Discretization error: Numerical Error Discretization error: - Consequence of the transformation of the continuum equation(s) into a system of algebraic equations - It may have a geometric component, which may even be the dominant contribution in domains bounded by surfaces with high curvature 16

Discretization error: - Usually, it is the main contribution to the Numerical Error Discretization error: - Usually, it is the main contribution to the numerical error - Can only be determined with the knowledge of the exact solution - Tends to diminish with the increase of the number of degrees of freedom (grid refinement) - Estimate of the discretization error may be obtained from grid refinement studies 17

Its goal is: check that the code is bug-free Code Verification Its goal is: check that the code is bug-free Does the numerical error tend to zero when the grid refinement / time step tends to zero? Is the observed order of convergence in agreement with the “theoretical order” of the code? M - If not, find out why?!

Error described by a Power Series Expansions Code Verification Error described by a Power Series Expansions fi → Local or functional flow quantity for grid i fexact → Exact solution of local or functional flow quantity eo → Error for cell size zero (supposed to be “0”) a → Constant hi → Typical cell size p → Observed order of grid convergence If

Geometrical Similarity - Typical cell size definition, hi Code Verification Geometrical Similarity - Typical cell size definition, hi

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) - Definition of a typical cell size (single parameter) requires sets of geometrically similar grids - Consider a 1-D problem for - Geometrically similar grids have a single definition of the dimensionless distance (s) as a function of the “dimensionless” node counter (x)

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Sets of 31 grids with 5 ≤ Ncells ≤320

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Similar grids

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Unsimilar grids

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Similar grids

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Unsimilar grids

Geometrical Similarity (a 1-D example) - Error norms: Code Verification Geometrical Similarity (a 1-D example) - Error norms: - eo(f), p and a obtained in the least squares sense from the data of the six finest grids

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Similar grids

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Unsimilar grids

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Unsimilar grids

Geometrical Similarity (a 1-D example) Code Verification Geometrical Similarity (a 1-D example) Unsimilar grids

- In some practical applications, there are no Code Verification Code Verification - In some practical applications, there are no exact solutions available. For example, the Reynolds-averaged Navier-Stokes equations supplemented by a turbulence model do not have any known exact solutions − The Method of Manufactured Solutions (MMS) is a viable alternative to perform Code Verification when analytical solutions are not available. 32

Method of Manufactured Solutions: Choose the calculation domain Code Verification Method of Manufactured Solutions: Choose the calculation domain Choose the analytical solution for the dependent variables of the problem Substitute the chosen solution in the differential equations to determine source terms that guarantee that the selected exact solution satisfies the “new” system of differential equations 33

Solution Verification Solution/Calculations Verification − Exact solution is not available − Numerical error estimation usually assumes that the discretization error is dominant (this requires an iterative error at least two orders of magnitude smaller) − Methods based on grid refinement studies are one of the alternatives for the estimation of the discretization error/uncertainty − Mathematical problem 34

Solution Verification − Estimate the uncertainty, U, of a numerical solution of a flow quantity f for which the exact solution is not known Objective: with a confidence level of 95% Safety factor Error estimate 35

Solution Verification Error described by a Power Series Expansions fi → Local or functional flow quantity for grid i fo → Estimate of the exact solution of local or functional flow quantity dRE → Estimate of the error a → Constant hi → Typical cell size p → Observed order of grid convergence 36

Solution Verification At least 3 grids are required to determine fo, a, p 37

Solution Verification Apparent convergence or divergence for a grid triplet with h2/h1=h3/h2! Convergence ratio : Previous equation can only be used for Monotonic Convergence 0 < R <1  Monotonic Convergence -1 < R <0  Oscillatory Convergence R > 1  Monotonic Divergence R <-1  Oscillatory Divergence 38

Solution Verification Example I Sets of 31 grids with 5 ≤ Ncells ≤320 Geometrically similar grids require L A simple 1-D example

Solution Verification Example I - Determination of solution at x=0.5 - Three grid sets of 21 grids with 5 ≤ Ncells ≤80 a) Equally-spaced geometrically similar grids, Equal b) Stretched geometrically similar grids, Stret c) Stretched non-geometrically similar grids, StretN L Different grid node distributions requiring interpolation (Stret) and with no interpolation (Equal)

Solution Verification Example I Determination of solution at x=0.5 L Disturbance to grid similarity

Solution Verification Example I Determination of solution at x=0.5 L The effect of grid node distribution. The “asymptotic range”

Solution Verification Example I Determination of solution at x=0.5 L The effect of grid node distribution. The asymptotic range

Solution Verification Example I Determination of solution at x=0.5 L Disturbances from lack of geometric similarity

Solution Verification Example I Determination of solution at x=0.5 L

Solution Verification Example I Determination of solution at x=0.5 M Disturbances from interpolation

Solution Verification Example I Determination of solution at x=0.5 M Disturbances from interpolation

Solution Verification Example II - Flow around the KVLCC2 tanker at model and full scale Reynolds number (double-body) - PARNASSOS with SST k-w model - Sets of 6 nearly geometrically similar grids with direct application of no slip condition with y2+<0.6 - Blending between third (b=1) and first-order (b=0) upwind L A “real test case” - Selected flow quantities are resistance coefficients and nominal wake fraction

Solution Verification Example II L High quality grid sets (3 Workshops with the same test case!)

Solution Verification Example II L

Solution Verification Example II Rn=4.6×106 L Numerics, numerics and numerics... Explain the figure KVLCC2 tanker SST k-w model

Solution Verification Example II Rn=2.03×109 L Numerics, numerics and numerics... KVLCC2 tanker SST k-w model

Solution Verification Example II Rn=4.6×106 L Numerics, numerics and numerics... KVLCC2 tanker SST k-w model

Solution Verification Example II Rn=2.03×109 L Numerics, numerics and numerics... KVLCC2 tanker SST k-w model

Solution Verification Example II Rn=4.6×106 L Numerics, numerics and numerics... KVLCC2 tanker SST k-w model

Solution Verification Example II Rn=2.03×109 L Numerics, numerics and numerics... KVLCC2 tanker SST k-w model

Solution Verification Example II M An example of what careless CFD can do... 40 minutes KVLCC2 tanker SST k-w model

Solution Verification Example II Rn=4.6×106 M An example of what careless CFD can do... KVLCC2 tanker SST k-w model

Solution Verification Example II Rn=4.6×106 M An example of what careless CFD can do... KVLCC2 tanker SST k-w model

Goal: Estimate an interval that contains the modeling error, Validation (ASME V&V 20) ASME V&V 20 procedure Goal: Estimate an interval that contains the modeling error, with 95% confidence Needed: a numerical simulation result with uncertainty estimate a corresponding experimental data set with uncertainty estimate L the parameter uncertainty

Goal: Estimate an interval that contains the modeling error, Validation (ASME V&V 20) ASME V&V 20 procedure Goal: Estimate an interval that contains the modeling error, with 95% confidence Comparison error, Validation uncertainty, L

Analysis of the outcome: Validation (ASME V&V 20) ASME V&V 20 procedure Analysis of the outcome: If too big: “Houston, we have a problem...” L If is acceptable: The model is good enough, for this “noise level”

Flow at the propeller plane of a tanker at model scale Validation (ASME V&V 20) Flow at the propeller plane of a tanker at model scale - Double body (no gravity waves) Comparison of axial velocity at the propeller plane RANS equations with an eddy-viscosity model Parameter uncertainty equal to zero 63

Validation (ASME V&V 20) Experimental Numerical Numérico 64

Validation (ASME V&V 20) Usual Comparison 65

Validation (ASME V&V 20) Introduction of experimental uncertainty 66

Validation (ASME V&V 20) Introduction of numerical uncertainty 67

Comparasion of validation error with validation uncertainty Validation (ASME V&V 20) Comparasion of validation error with validation uncertainty 68

Validation (ASME V&V 20) What we want to avoid! 69