Numerical Solution I

Similar documents
A very short introduction to the Finite Element Method

On Multigrid for Phase Field

1. Fast Iterative Solvers of SLE

On Nonlinear Dirichlet Neumann Algorithms for Jumping Nonlinearities

Chapter 1: The Finite Element Method

Chapter 1 Foundations of Elliptic Boundary Value Problems 1.1 Euler equations of variational problems

Numerical Solutions to Partial Differential Equations

Basic Concepts of Adaptive Finite Element Methods for Elliptic Boundary Value Problems

1. Let a(x) > 0, and assume that u and u h are the solutions of the Dirichlet problem:

INTRODUCTION TO FINITE ELEMENT METHODS

Constrained Minimization and Multigrid

AMS 529: Finite Element Methods: Fundamentals, Applications, and New Trends

Scientific Computing WS 2017/2018. Lecture 18. Jürgen Fuhrmann Lecture 18 Slide 1

Multigrid finite element methods on semi-structured triangular grids

Algebraic Multigrid as Solvers and as Preconditioner

Scientific Computing WS 2018/2019. Lecture 15. Jürgen Fuhrmann Lecture 15 Slide 1

INTRODUCTION TO MULTIGRID METHODS

INTRODUCTION TO FINITE ELEMENT METHODS ON ELLIPTIC EQUATIONS LONG CHEN

Numerical Methods for Partial Differential Equations

Hierarchical Parallel Solution of Stochastic Systems

The Plane Stress Problem

A MULTILEVEL SUCCESSIVE ITERATION METHOD FOR NONLINEAR ELLIPTIC PROBLEMS

Lecture 9 Approximations of Laplace s Equation, Finite Element Method. Mathématiques appliquées (MATH0504-1) B. Dewals, C.

Algorithms for Scientific Computing

Capacitance Matrix Method

ITERATIVE METHODS BASED ON KRYLOV SUBSPACES

Goal-oriented error control of the iterative solution of finite element equations

1 Discretizing BVP with Finite Element Methods.

One-dimensional and nonlinear problems

The Discontinuous Galerkin Finite Element Method

FEniCS Course. Lecture 0: Introduction to FEM. Contributors Anders Logg, Kent-Andre Mardal

ITERATIVE METHODS FOR NONLINEAR ELLIPTIC EQUATIONS

A brief introduction to finite element methods

Iterative Methods for Linear Systems

Variational Formulations

Aspects of Multigrid

Numerical methods for PDEs FEM convergence, error estimates, piecewise polynomials

The Conjugate Gradient Method

A MULTIGRID ALGORITHM FOR. Richard E. Ewing and Jian Shen. Institute for Scientic Computation. Texas A&M University. College Station, Texas SUMMARY

Chapter Two: Numerical Methods for Elliptic PDEs. 1 Finite Difference Methods for Elliptic PDEs

An additive average Schwarz method for the plate bending problem

Scientific Computing I

Xingye Yue. Soochow University, Suzhou, China.

Goal-oriented error control of the iterative solution of finite element equations

Iterative methods for positive definite linear systems with a complex shift

LECTURE # 0 BASIC NOTATIONS AND CONCEPTS IN THE THEORY OF PARTIAL DIFFERENTIAL EQUATIONS (PDES)

Numerical Analysis Comprehensive Exam Questions

Numerical Solution of a Coefficient Identification Problem in the Poisson equation

LECTURE 1: SOURCES OF ERRORS MATHEMATICAL TOOLS A PRIORI ERROR ESTIMATES. Sergey Korotov,

A Robust Preconditioner for the Hessian System in Elliptic Optimal Control Problems

Preface to the Second Edition. Preface to the First Edition

Stabilization and Acceleration of Algebraic Multigrid Method

Mathematics Research Report No. MRR 003{96, HIGH RESOLUTION POTENTIAL FLOW METHODS IN OIL EXPLORATION Stephen Roberts 1 and Stephan Matthai 2 3rd Febr

INTERGRID OPERATORS FOR THE CELL CENTERED FINITE DIFFERENCE MULTIGRID ALGORITHM ON RECTANGULAR GRIDS. 1. Introduction

Introduction to Aspects of Multiscale Modeling as Applied to Porous Media

The Mortar Boundary Element Method

An Adaptive Mixed Finite Element Method using the Lagrange Multiplier Technique

SOLVING ELLIPTIC PDES

Adaptive Finite Element Methods Lecture Notes Winter Term 2017/18. R. Verfürth. Fakultät für Mathematik, Ruhr-Universität Bochum

A Framework for Analyzing and Constructing Hierarchical-Type A Posteriori Error Estimators

Solving PDEs with Multigrid Methods p.1

Numerical Solutions to Partial Differential Equations

Chapter 3 Conforming Finite Element Methods 3.1 Foundations Ritz-Galerkin Method

Multigrid Methods for Elliptic Obstacle Problems on 2D Bisection Grids

Geometric Multigrid Methods

Multigrid Methods and their application in CFD

VARIATIONAL AND NON-VARIATIONAL MULTIGRID ALGORITHMS FOR THE LAPLACE-BELTRAMI OPERATOR.

High order, finite volume method, flux conservation, finite element method

New class of finite element methods: weak Galerkin methods

Numerical methods for PDEs FEM convergence, error estimates, piecewise polynomials

Optimal Left and Right Additive Schwarz Preconditioning for Minimal Residual Methods with Euclidean and Energy Norms

Finite Elements. Colin Cotter. February 22, Colin Cotter FEM

Lecture 18 Classical Iterative Methods

Institut für Mathematik

Adaptive algebraic multigrid methods in lattice computations

Partial Differential Equations

Numerik 2 Motivation

Chapter 7 Iterative Techniques in Matrix Algebra

Solving the Stochastic Steady-State Diffusion Problem Using Multigrid

Elliptic Problems / Multigrid. PHY 604: Computational Methods for Physics and Astrophysics II

Numerical Solutions to Partial Differential Equations

Space-time sparse discretization of linear parabolic equations

A note on accurate and efficient higher order Galerkin time stepping schemes for the nonstationary Stokes equations

AMG for a Peta-scale Navier Stokes Code

Subdiffusion in a nonconvex polygon

On solving linear systems arising from Shishkin mesh discretizations

arxiv: v5 [math.na] 1 Sep 2018

Space-time Finite Element Methods for Parabolic Evolution Problems

A Finite Element Method Using Singular Functions for Poisson Equations: Mixed Boundary Conditions

Multigrid Method ZHONG-CI SHI. Institute of Computational Mathematics Chinese Academy of Sciences, Beijing, China. Joint work: Xuejun Xu

Local Inexact Newton Multilevel FEM for Nonlinear Elliptic Problems

arxiv: v2 [math.na] 17 Jun 2010

OUTLINE ffl CFD: elliptic pde's! Ax = b ffl Basic iterative methods ffl Krylov subspace methods ffl Preconditioning techniques: Iterative methods ILU

Overlapping Schwarz preconditioners for Fekete spectral elements

Boundary Value Problems and Iterative Methods for Linear Systems

A simple FEM solver and its data parallelism

Solving Symmetric Indefinite Systems with Symmetric Positive Definite Preconditioners

Lehrstuhl Informatik V. Lehrstuhl Informatik V. 1. solve weak form of PDE to reduce regularity properties. Lehrstuhl Informatik V

ACM/CMS 107 Linear Analysis & Applications Fall 2017 Assignment 2: PDEs and Finite Element Methods Due: 7th November 2017

10 The Finite Element Method for a Parabolic Problem

Transcription:

Numerical Solution I Stationary Flow R. Kornhuber (FU Berlin) Summerschool Modelling of mass and energy transport in porous media with practical applications October 8-12, 2018

Schedule Classical Solutions (Finite Differences) The Conservation Principle (Finite Volumes) Principle of Minimal Energy (Finite Elements) Adaptive Finite Elements (Fast) Solvers for Linear Systems Random Partial Differential Equations

Saturated Groundwater Flow (Darcy Equation) p: pressure S 0 p t = div(k p)+f S 0 = ρg n p 0: specific storage coefficient K = (K 1,K 2,K 3 ) : Ω R 3,3 : hydraulic permeability f = ρgdivk 3 +gf: gravity and source terms

Darcy s equation: Darcy s and Poisson s Equation S 0 = 0: pressure-stable granular structure Poisson s equation: div(k p) = f K R 3,3 constant: K p(x) = p(kx) transformation of variables: p(x) p(kx) =: u(x) u = f Laplace operator: u = 3 i=1 u x i x i = u x1 x 1 +u x2 x 2 +u x3 x 3

Darcy s and Poisson s Equation Darcy s equation: S 0 = 0: pressure-stable granular structure div(k p) = f Poisson s equation: homogeneous soil: K R 3,3 K p(x) = p(kx) transformation of variables: p(x) p(kx) =: u(x) u = f Laplace operator: u = 3 i=1 u x i x i = u x1 x 1 +u x2 x 2 +u x3 x 3

Classical Solution of Poisson s Equation Poisson s equation: Ω R d (bounded domain) u = f on Ω + boundary conditions on Ω boundary conditions (BC): u = g pressure BC (Dirichlet BC, 1. kind) αu+β nu = g transmission BC (Robin BC, 3. kind) Theorem (well-posedness) Assumption: Ω, f, g sufficiently smooth. Assertion: There exists a unique solution u C 2 (Ω) C(Ω) and u depends continuously on f, g.

flux boundary conditions: Ill-Posed Problems n u = g outflow BC (Neumann BC, 2. kind) no uniqueness: u solution = u+c solution for all c R necessary for existence: Ω f dx+ Ω g dσ = 0 (Green s formula) different BCs on disjoint subsets Γ D Γ N Γ R = Ω allowed Caution: Γ D too small, e.g. Γ D = {x 0,x 1,..,x m }, no uniqueness!!

flux boundary conditions: Ill-Posed Problems n u = g outflow BC (Neumann BC, 2. kind) no uniqueness: u solution = u+c solution for all c R necessary for existence: Ω f dx+ Ω g dσ = 0 (Green s formula) different BCs on disjoint subsets Γ D Γ N Γ R = Ω allowed Caution: Γ D too small, e.g. Γ D = {x 0,x 1,..,x m }, no uniqueness!!

flux boundary conditions: Ill-Posed Problems n u = g outflow BC (Neumann BC, 2. kind) no uniqueness: u solution = u+c solution for all c R necessary for existence: Ω f dx+ Ω g dσ = 0 (Green s formula) different BCs on disjoint subsets Γ D Γ N Γ R = Ω allowed Caution: Γ D too small, e.g. Γ D = {x 0,x 1,..,x m }, no uniqueness!!

rectangular mesh with mesh size h: Finite Differences Ω h Ω h o

Finite Difference Approximations x N 1. order forward and backward: x W x Z x O D + 1 U(x Z) = U(x O) U(x Z ) x O x Z x S D 1 U(x Z) = U(x Z) U(x W ) x Z x W δω 2. order central finite differences: ( 2 D 11 U(x Z ) = x O x W D + 1 U(x Z ) D1 U(x Z) )

Finite Difference Discretization (Shortley/Weller) discrete Laplacian: h U(x) = D 11 U(x)+D 22 U(x) discrete problem: h U = f on Ω h, U(x) = g on Ω h linear system: A FD U = b Theorem (Convergence): Assumption: u C 3 (Ω). Assertion: max U(x) u(x) = O(h) x Ω h

piecewise constant permeabilities: Heterogeneous Media K = { k1 x Ω 1 k 2 x Ω 2 Ω = Ω 1 Ω 2 Γ no classical solution of: div(k u) = f on Ω finite difference discretizations lead to interface problems interface problems require finite difference approximations of flux across the interface

piecewise constant permeabilities: Heterogeneous Media K = { k1 x Ω 1 k 2 x Ω 2 Ω = Ω 1 Ω 2 Γ no classical solution of: div(k u) = f on Ω finite difference discretizations lead to interface problems interface problems require finite difference approximations of flux across the interface

Conservation Principle conservation of mass in Ω Ω: K(x) u(x) dσ + f(x) dx = 0 Ω n Ω regularity condition: K u C 1 (Ω) d Green s formula: K(x) Ω n Ω u(x) dσ = div(k(x) u(x)) 1 dx+ K(x) u(x) 1 dx Ω Darcy s equation: Ω div(k(x) u(x))+f(x) dx = 0 Ω Ω

Finite Volumes finite dimensional ansatz space: S h, dim S h = n, v Ω = 0 v S h finite decomposition of Ω into control volumes Ω i : Ω = n i=1 Ω i finite volume discretization: u h S h : K n u h dσ = f dx i = 1,...,n Ω i Ω i linear system: choice of basis: S h = span{ϕ i i = 1,...,n} Au h = b, a ij = K n ϕ j dσ, b i = f dx Ω i Ω i solution: u h = n i=1 u iϕ i, u h = (u i )

Choice of Ansatz Space triangulation: T h = {T T triangle}, Ω = T T h T p q linear finite elements: S h := {v C(Ω) v T linear T T h, v Ω = 0} nodal basis: λ p (q) = δ p,q, p,q N h

Vertex-Centered Finite Volumes control volumes: linear connection of barycenters Ω p p linear system: A FV u h = b FV, u h = p N h u p λ p

Principle of Minimal Energy quadratic energy functional: J(v) = 1 2 a(v,v) l(v), minimization problem: a(v,w) = Ω K v w dx, l(v) = Ω fv dx variational formulation: u H 1 0(Ω) : J(u) J(v) v H 1 0(Ω) u H 1 0(Ω) : J (u)(v) = a(u,v) l(v) = 0 v H 1 0(Ω) weak solution u H 1 0(Ω) (Sobolev space)

Weak Versus Classical Solution regularity condition: K u C 1 (Ω) d Green s formula: 0 = a(u,v) l(v) = Ω (div(k u)+f)v dx+ Ω ( K n u) v dσ suitable choice of test functions v C 1 0(Ω): div(k u) = f on Ω

Ritz-Galerkin Method finite dimensional ansatz space: S h H 1 0(Ω), dim S h = n Ritz-Galerkin method linear system: u h S h : J (u h )(v) = a(u h,v) l(v) = 0 v S h choice of basis: S h = span{ϕ i i = 1,...,n} Au h = b, a ij = a(ϕ j,ϕ i ), b i = l(ϕ i ) solution: u h = n i=1 u iϕ i, u h = (u i )

Finite Element Discretization triangulation: T h = {T T triangle}, Ω = T T h T p q linear finite elements: S h := {v C(Ω) v T linear T T h, v Ω = 0} nodal basis: λ p (q) = δ p,q, p,q N h linear system: A FE u h = b FE

Finite Elements Versus Finite Volumes Theorem (Hackbusch 89) A FV = A FE, b FV b FE 1 = O(h 2 ) Corollary: u FV h u FE h 1 = O(h 2 ), v 2 1 = Ω v 2 + v 2 dx in general: finite volumes: finite element discretization with suitable test functions finite elements: finite volume discretization with suitable numerical flux

Stability maximum principle: u 1 = f 1, u 2 = f 2 on Ω, u 1 = u 2 = 0 on Ω no discrete maximum principle: f 1 f 2 = u 1 u 2 A FE u 1 = b FE 1, A FE u 2 = b FE 2 b FE 1 b FE 2 u 1 u 2 bad angles of triangles might cause oscillations! remedy: Delaunay triangulation T h

Stability maximum principle: u 1 = f 1, u 2 = f 2 on Ω, u 1 = u 2 = 0 on Ω no discrete maximum principle: f 1 f 2 = u 1 u 2 A FE u 1 = b FE 1, A FE u 2 = b FE 2 b FE 1 b FE 2 u 1 u 2 bad angles of triangles might cause oscillations! remedy: Delaunay triangulation T h

Stability maximum principle: u 1 = f 1, u 2 = f 2 on Ω, u 1 = u 2 = 0 on Ω no discrete maximum principle: f 1 f 2 = u 1 u 2 A FE u 1 = b FE 1, A FE u 2 = b FE 2 b FE 1 b FE 2 u 1 u 2 bad angles of triangles might cause oscillations! remedy: Delaunay triangulation T h

Stability maximum principle: u 1 = f 1, u 2 = f 2 on Ω, u 1 = u 2 = 0 on Ω no discrete maximum principle: f 1 f 2 = u 1 u 2 A FE u 1 = b FE 1, A FE u 2 = b FE 2 b FE 1 b FE 2 = u 1 u 2 bad angles of triangles might cause oscillations! remedy: Delaunay triangulation T h

Discretization Error Galerkin orthogonality: a(u u h,v) = 0 v S optimal error estimate: u u h = inf v S h u v, v 2 = a(v,v) (energy norm) ellipticity: α v 1 v β v 1, α,β > 0, v H 1 0(Ω) quasioptimal error estimate: u u h 1 β α inf v S h u v 1 estimate of the discretization error inf u v 1 c u 2 h = O(h), c = c(t h ) v S h

Adaptive Multilevel Methods Mesh T := T 0 Local refinement T := Ref (T ) no Discretization w.r.t. T Multigrid solution Error < TOL yes coarse grid generator finite element discretisation (iterative) algebraic solver a posteriori error estimate local refinement indicators local marking and refinement strategy quasioptimal error estimate: u u j 1 cn 1/d j

Adaptive Multilevel Methods Mesh T := T 0 Local refinement T := Ref (T ) no Discretization w.r.t. T Multigrid solution Error < TOL yes coarse grid generator finite element discretisation (iterative) algebraic solver a posteriori error estimate local refinement indicators local marking and refinement strategy quasioptimal error estimate: u u j 1 cn 1/d j

Phase Transition

Hierarchical A Posteriori Error Estimators extended ansatz space: Q h = S V h (hopefully) better discretization: u Q h Q h : a(u Q h,v) = l(v) v Q h basic idea: u Q h u h 1 u u h 1 algorithmic realization: basis of V h : V h = span{µ e e E h } (quadratic bubbles) weighted residuals: η e = r(µ e) a(µ e,µ e ), r(µ e) = l(µ e ) a(µ e,µ e ), e E h Theorem (Deuflhard, Leinen & Yserentant 88) The saturation assumption: u u Q h 1 q u u h 1, q < 1, implies the error bounds: cη u u h 1 Cη, η = e E h η e

Adaptive Refinement Strategy local errors have local origin (wrong for transport equations!): η e θ = mark all T with T e for red refinement! e e green closures:

Stable Refinement in 3D red refinement: What to do with the remaining octahedron? 2 6 7 5 4 9 3 8 10 1 Learn from crystallography (Bey 91)!

Stable Refinement in 3D red refinement: What to do with the remaining octahedron? 2 6 7 5 4 9 3 8 10 1 Learn from crystallography (Bey 91)!

Linear Algebraic Solvers stiffness matrix A = (a(λ p,λ q )) p,q Nh A is symmetric, positive definite and sparse condition number: 1 o(1) κ(a) = λ max(a) λ min (A) O(h 2 ) A is arbitrarily ill-conditioned for h 0 Corollary: Use iterative solvers for small h or, equivalently, large n (n 20 000 50 000)

Conjugate Gradient (CG) Iteration Underlying idea: inductive construction of an A-orthogonal basis of R n Algorithm (Hestenes und Stiefel, 1952) initialization: U 0 R n, r 0 = b AU 0, e 0 = r 0 iteration: U k+1 = U k +α k e k, α k = r k,r k e k,ae k update: r k r k+1, e k e k+1 error estimate: U U k 2ρ k U U 0, ρ = κ(a) 1 κ(a)+1 Corollary: Slow convergence for κ(a) 1 Vorkonditionierer: B leicht invertierbar, κ(b 1 A) κ(a)

Preconditioned Conjugate Gradient (CG) Iteration Underlying idea: inductive construction of an A-orthogonal basis of R n Algorithm (Hestenes und Stiefel 1952) initialization: U 0 R n, r 0 = B(b AU 0 ), e 0 = r 0 iteration: U k+1 = U k +α k e k, α k = r k,br k e k,ae k update: r k r k+1, e k e k+1 error estimate: U U k 2ρ k U U 0, ρ = κ(ba) 1 κ(ba)+1 Corollary: Fast convergence for κ(ba) 1 preconditioner B: optimal complexity O(n j ) and B A 1

Subspace Correction Methods basic idea: solve many small problems instead of one large problem subspace decomposition: S h = V 0 +V 1 + +V m Algorithm (sucessive subspace correction) Xu 92 w 1 = u k v l V l : a(v l,v) = l(v) a(w l 1,v) v V l w l = w l 1 +v l u k+1 = w m Gauß-Seidel iteration: V p = span{λ p } ρ h = 1 O(h 2 ) Jacobi-iteration: parallel subspace correction ρ h = 1 O(h 2 ) domain decomposition, multigrid,... ρ h ρ < 1 BPXW 93

Multigrid Methods hierarchy of grids (adaptive refinement!): T 0 T 1 T j = T h hierarchy of frequencies: S 0 S 1 S j = S h λ (k) p λ (j) p multilevel decomposition: S h = j k=0 p N k V p (k), V (k) p = span{λ (k) p } multigrid method with Gauß-Seidel smoothing and Galerkin restriction

Poisson s Equation on the Unit Square Ω = (0,1) (0,1), f 1, V(1,0) cycle, symmetric Gauß-Seidel smoother coarse grid T 0 approximate solution convergence rates: j=2 j=3 j=4 j=5 j=6 j=7 ρ j 0.28 0.30 0.31 0.32 0.33 0.33

Approximation History (L-Shaped Domain) levels nodes iterations est. error est. error/n 1/2 j 0 8 0.34985 0.989 1 21 2 0.21165 0.969 2 65 2 0.11978 0.965 3 225 2 0.06441 0.966 4 833 2 0.03427 0.989 5 2.359 2 0.02185 1.061 6 3.320 2 0.01672 0.963 7 4.118 2 0.01505 0.966 8 10.032 2 0.01002 1.003 9 13.377 2 0.00805 0.931 10 16.369 2 0.00742 0.950 11 40.035 2 0.00494 0.989 12 53.188 2 0.00399 0.921 13 64.647 2 0.00371 0.943 14 159.064 2 0.00247 0.986

Uncertain Data uncertainty of permeability, source terms, boundary conditions,... by lack of sufficiently accurate measurements by external sources random Darcy equation: S 0 p t (t,x,θ) = div(k(x,θ) p(t,x,θ))+f(x,θ), θ Θ, probability space (Θ,A,P).

Random Partial Differential Equations random Darcy equation: S 0 p t (t,x,θ) = div(k(x,θ) p(t,x,θ))+f(x,θ) desired statistics of solutions: expectation value E[p] := Θ pdp variance E[(p E[p]) 2 ] probability of particular events P[ p(t,x,θ)dx < 0 for t < 1] Ω

Numerical Approximation of Random PDEs Monte-Carlo Method: (i) generate N independent, P-equidistributed samples θ 1,...,θ N. (ii) compute approximations of the N solutions for the samples θ 1,...,θ N. (iii) compute the corresponding expectation value, variance,... advantage: always feasible and simple disadvantage: convergence rate 1 N = N has to be very large multilevel Monte Carlo methods: solve stochastic problems with deterministic computational cost

Numerical Approximation of Random PDEs Monte-Carlo Method: (i) generate N independent, P-equidistributed samples θ 1,...,θ N. (ii) compute approximations of the N solutions for the samples θ 1,...,θ N. (iii) compute the corresponding expectation value, variance,... advantage: always feasible and simple disadvantage: convergence rate 1 N = N has to be very large Multilevel Monte Carlo methods: solve random PDEs with almost deterministic computational cost!