2D1260: Finite Element Methods. Lecturer: Johan ... 2. project presentation (Mon
12 Dec/Tue 13 Dec) ... Space-time FEM, stabilization, Convection-Diffusion. 9.
Finite Element Methods Lecture 1 Johan Hoffman
[email protected]
Johan Hoffman – KTH – p.1
2D1260: Finite Element Methods Lecturer: Johan Hoffman Assistant Professor (Forskarassistent) Research: Adaptive FEM for CFD, turbulence,...
[email protected] Teaching Assistant: Erik von Schwerin PhD student (Doktorand) Research: Adaptive FEM, Stochastic DE,...
[email protected] www.nada.kth.se/kurser/kth/2D1260
Office Hours: Mon 9-10 (JH), Tue 9-10 (ES)
Johan Hoffman – KTH – p.2
2D1260: Finite Element Methods 9 lectures + 6 excercise sessions Book: Computational Differential Equations Examination: 1. project report (Fri 9 Dec) 2. project presentation (Mon 12 Dec/Tue 13 Dec) 3. written exam (Fri 16 Dec) Project starts Week 3 Mon 14 Nov; 2 parts: 1. computer assignement; the same for everyone 2. extension of the first part chosen by the group
Johan Hoffman – KTH – p.3
Overview: Lectures Introduction, DE, Galerkin’s method
2.
BVP, FE basis functions
3.
Abstract problem, Lax-Milgram Theorem
4.
Interpolation, error estimation, adaptivity
5.
FE software; assembly, mapping, quadrature
6.
IVP, stability, -method, space-time FEM
7.
Adaptivity, error estimation, duality
8.
Space-time FEM, stabilization, Convection-Diffusion
9.
Navier-Stokes, adaptivity, functional output
1.
Johan Hoffman – KTH – p.4
in
(DE)
Differential Equation (DE)
: differential operator : solution : source term : domain where (DE) is valid:
Ordinary Differential Equation (ODE) : Partial Differential Equation (PDE) : u scalar : scalar DE u vector : system of DE
DE : Equation relating derivatives of a function
Johan Hoffman – KTH – p.5
BC: specifying equation on boundary
of the domain
on
in
(BC)
(DE)
Boundary conditions
for all
for all
Neumann boundary condition:
Dirichlet boundary condition:
Examples:
Johan Hoffman – KTH – p.6
is two
This equation smooths the solution: the solution times more differentiable than the source term
Ex: Poisson’s equation
Modeling: gravitation, ground water flow, electrostatics,...
Johan Hoffman – KTH – p.7
for
and
for
BC:
Dirichlet BC
Johan Hoffman – KTH – p.8
for
and
for
BC:
Dirichlet + Neumann BC
Johan Hoffman – KTH – p.9
Ex: Heat equation
This equation smooth the solution over time:
Modeling: heat conduction, pollution,...
Johan Hoffman – KTH – p.10
Ex: Heat equation
Johan Hoffman – KTH – p.11
Ex: Heat equation Osmosis; diffusion through cell membrane
Johan Hoffman – KTH – p.12
Ex: Schrödinger equation
is the wave function in the quantum mechanical model of the motion of an electron orbiting around one proton at the origin.
Johan Hoffman – KTH – p.13
Ex: Black-Scholes equation
This equation is close to the heat equation, with the asset playing the role of the spatial dimension price Modeling: option pricing,...
Johan Hoffman – KTH – p.14
Ex: Linear Elasticity
and the stress
Models the displacement elastic bodies
div
div
Cauchy-Navier’s elasticity equations:
for
Johan Hoffman – KTH – p.15
):
This equation conserves energy (for
Ex: Wave equation
Modeling: wave phenomena, accoustics,...
Johan Hoffman – KTH – p.16
Ex: Wave equation Seismic waves in simulation of California Earthquake
Johan Hoffman – KTH – p.17
is transported (convected) by the .
The solution convection field
Ex: Transport equation
Modeling: Pollution,...
Johan Hoffman – KTH – p.18
Ex: Convection-Diffusion-Reaction
This equation is a combination of transport (convection) by , diffusion with diffusivity , the convection field , of a spieces and reaction with reaction coefficient . Modeling: chemical reactions, pollution,...
Johan Hoffman – KTH – p.19
Ex: Convection-Diffusion-Reaction Chernobyl 1986; simulation by SMHI
Johan Hoffman – KTH – p.20
Ex: Maxwell equations
magnetic field,
current density
electric field,
Johan Hoffman – KTH – p.21
Ex: Maxwell equations Magnetic field around a coil.
Johan Hoffman – KTH – p.22
Ex: Stokes equations
velocity and
pressure
Modeling: low velocity flow phenomena
Johan Hoffman – KTH – p.23
Ex: Stokes equations Groundwater flow
Johan Hoffman – KTH – p.24
Ex: Navier-Stokes equations
velocity and
pressure
Modeling: flow phenomena, weather prediction, blood flow,...
Johan Hoffman – KTH – p.25
Ex: Navier-Stokes equations
Johan Hoffman – KTH – p.26
Vorticity
Ex: Navier-Stokes equations around wheel.
Johan Hoffman – KTH – p.27
Vorticity
Ex: Navier-Stokes equations around a full car.
Johan Hoffman – KTH – p.28
Vorticity
Ex: Navier-Stokes equations around a full car.
Johan Hoffman – KTH – p.29
Ex: Navier-Stokes equations Blood flow in artery.
Johan Hoffman – KTH – p.30
Function spaces to DE
and
in
)
and all functions
(for all real numbers
in a certain class
is a vector space (linear space):
A function space
look for approximate solutions of functions: FUNCTION SPACE
Often impossible to find exact solutions
Functional Analysis: linear algebra for function spaces
Johan Hoffman – KTH – p.31
Hölder inequality:
-norm:
max-norm:
orthogonal:
Cauchy-Schwarz inequality: and
(size of )
-norm:
Inner product (scalar product):
Linear Algebra for Function spaces
Johan Hoffman – KTH – p.32
)
so that the error is small:
Determine
in a function space
Seek approximate solution with “simple” basis functions:
Approximation methods
Examples of spaces : trigonometric functions (Fourier), polynomials (Newton, Lagrange), piecewise polynomials (Finite Element Methods)
Johan Hoffman – KTH – p.33
such that
the function space
is orthogonal to all
:
The residual of the exact solution functions:
The RESIDUAL: is orthogonal to all testfunctions GALERKIN ORTHOGONALITY
Galerkin method: Find
Galerkin method
Johan Hoffman – KTH – p.34
,
for
linear system of equations
Solve for
Galerkin method
Johan Hoffman – KTH – p.35
Galerkin method spectral method (trigonomatric b.f.), p-method (global polynomial b.f.), h-method (piecewise polynomial b.f.),...
FEM: piecewise polynomial functions on a mesh in 1d
Johan Hoffman – KTH – p.36
Galerkin method
FEM: computational mesh in 3d (www.geuz.org/gmsh)
Johan Hoffman – KTH – p.37
Finite Element Methods FEM: piecewise polynomials 1. basis functions are almost orthogonal (local support) 2. basis functions are simple to differentiate and integrate 3. applicable to general geometry ϕ 1
i−1
ϕ
i
ϕ
i+1
x x i−2
x i−1
xi
x i+1
x i+2
Johan Hoffman – KTH – p.38
Dirichlet Boundary conditions:
Example
boundary nodes h i=x i−xi−1 interior nodes I i=(x i−1,x i) x x2
x i−1
xi
xM+1 =1
x1
x 0=0
continuous piecewise linear functions on a mesh
Johan Hoffman – KTH – p.39
for
,
:
Integration by parts
nodal basis for
Example
Variational form:
weak form of DE
Johan Hoffman – KTH – p.40
for
, Vector
Linear system of equations for :
Galerkin (cG(1)): Find
Matrix
Example
:
Johan Hoffman – KTH – p.41
Goal of FEM course Construct Finite Element Methods for general DE (ODE and PDE). Analyze stability of DE, and the corresponding FEM solution. Analyze the error in the FEM approximation. Construct adaptive FEM methods. Learn the structure of FEM software.
Johan Hoffman – KTH – p.42