Sie sind auf Seite 1von 6

Ralf Hitpmair Num. of Ell. and Parab. Bound. Value Prob.

WS 05/06

Serie 4

Context: Galerkin approximation.


Theoretical Exercises: 1.–2.
Practical Exercise: 3.

1. (1D-Hermitian finite elements)


We consider the problem:


 Find u ∈ H 1 (]0; 1[) such that:

−u 00 + u = f, with f ∈ L 2 (]0; 1[), (1)


 u 0 (0) = u 0 (1) = 0.

(a) Write the variational formulation

Find u ∈ V such that a(u, v) = f(v), ∀v ∈ V, (2)

and show that problem (1) has a unique solution.


(b) For VN ⊂ H 1 ([0; 1]), show that the following problem has a unique solution:

Find u N ∈ VN such that a(u N , v N ) = f(v N ), ∀v N ∈ VN . (3)

(c) We define the mesh M:


n oM ii − 1 i h
M = Ki with K i = ; . (4)
i=1 M M

 K
i
i−1 i

  M
0 M M 1= M

We introduce the following local discreet space:

VN (K ) = P3 (K ), ∀K ∈ M. (5)
We consider the system of linear forms of V K i D K i = {β K1 i , β K2 i , β K3 i , β K4 i } defined
by: 
 i −1


 β K1 i (v) = v( ),

 n

 1 i −1
 2 lim v 0 ( + x),
 β K i (v) =

N x→0 + N
(6)
 β 3 (v) = v( i ),



 Ki

 n

 1 i
 4
 β K i (v) = lim v 0 ( + x).
N x→0− N
Show that D K i is unisolvent (D K i is a basis of (VK i )0 ).
(d) Find the local shape functions {b 1K i , b2K i , b3K i , b4K i } associated to the local degrees
of freedom D K i .
Hint: Find blK i ∈ P3 (K i ) such that β Kk i (blK i ) = δk,l , for all k, l = 1, ..., 4.
(e) Show that matching local degrees of freedom at a node ensures

v N ∈ VN = {v N ∈ C 1 ([0; 1]) / v N |K ∈ VN (K ), ∀K ∈ M}. (7)

j
(f) Prove that the global degrees of freedom {b N }2N
j =1 arising from the above local
degrees of freedom are:
i 1 i
β N2i (v N ) = v N ( ), β N2i+1 (v N ) = v N 0 ( ), ∀i = 0, ..., N . (8)
N N N
2N+2
What are the global shape functions {biN }i=1 ?
(g) Compute the stiffness matrix S:
Z 1
j
S j,i = (biN )0 (x) (b N )0 (x) d x (9)
0

and the mass matrix M


Z 1
j
M j,i = biN (x) b N (x) d x. (10)
0

2. Let K ⊂ R2 be a triangle with the vertices a1 , a2 , a3 , then we denote by ω1 , ω2 , ω3


its inner angles.

a3

ω2

ω3 
a2
ω1

a1

! ! !
a11 a21 a31
a1 := , a2 := , a3 := . (11)
a12 a22 a32

The barycentric coordinates λ1 (x), λ2 (x), λ3 (x) at the point x ∈ R2 , which are given
by
! !
1 x1 − a21 a22 − a32
λ1 (x) := · ,
2|K | x2 − a22 a31 − a21
! !
1 x1 − a31 a32 − a12
λ2 (x) := · ,
2|K | x2 − a32 a11 − a31
! !
1 x1 − a11 a12 − a22
λ3 (x) := · ,
2|K | x2 − a12 a21 − a11

can be used to define the element shape functions b1 (x), b2 (x), b3 (x) for piecewise
linear finite elements

b1K (x) := λ1 (x), b2K (x) := λ2 (x), b3K (x) := λ3 (x), (12)

on each element. For piecewise linear finite elements the element stiffness matrix A K
for the Laplacian is given by
Z
ij j
A K := ∇biK · ∇b K (1 ≤ i, j ≤ 3).
K

(a) Show that the sum over all entries of a row or a column of the local stiffness matrix
equals zero.
(b) Show that the following equations hold true
Z
1
∇b1K · ∇b2K = − cotan(ω3 ) ,
2
K
Z
1
∇b1K · ∇b3K = − cotan(ω2 ) ,
2
K
Z
1
∇ b2K · ∇b3K = − cotan(ω1 ) .
2
K

(c) Show that the following equation holds true


 
α2 + α 3 −α3 −α2
1

α3 + α 1 −α1


A =
2 
sym. α 1 + α2

where α1 := cotan(ω1 ), α2 := cotan(ω2 ) and α3 := cotan(ω3 ).

3. On the square
 = {(x, y) ∈ R2 / 0 6 x 6 1, 0 6 y 6 1}, (13)
we consider the problem

1
 Find u ∈ H0 () such that:

Z Z
(14)

 ∇u∇v = f v,
 
with
f (x, y) = 13π 2 sin (3π x) sin (2π y). (15)
To compute a numerical approximation, we introduce the following discreet space:
0
S2,0 (M) = {v ∈ C 0 () / v|∂ ≡ 0, v|K ∈ P2 (K ) ∀K ∈ M}. (16)
where M is a triangular mesh of  (see the following figure for an example)
The numerical approximation u N of the exact solution u is the unique solution of the
following problem:

0
 Find u N ∈ S2,0 (M) such that:

Z Z
0
(17)

 ∇u N · ∇v N = f v N , ∀v N ∈ S2,0 (M).
 
Write a MATLAB code which computes and plots the approximate numerical soluti-
on.
One can refer to the appendix for more informations.
Practical exercise: the solution is due on Tuesday January 9.

Tutorial: Thursday 10–11 HG E5, Starting time: Thursday, 3.10

Coordinators: Sébastien Tordeux, HG J16.1, tordeux@math.ethz.ch, Harish Kumar Kaus-


hik, HG G56, harish@math.ethz.ch

Testat requirement: 50% of the theoretical exercises and 50% practical exercises (MAT-
LAB) should be solved.
Appendix: Quadratic finite elements
Linear finite elements you can find at the following adress MATLAB files which solves
0 (K ):
the same problem with V N (K ) = S1,0
http://www.sam.math.ethz.ch/ tordeux/LFE
mainLFE : computes and draws the solution
assemMat_LFE : assembles the galerkin matrix
STIMA_Lapl_LFE : computes the local stiffness matrix
assemLoad_LFE : assembles the right hand side
assemDir_LFE : takes into account the Dirichlet boundary condition
plot_LFE : plots a (linear by element) function
3
Local shape function. Let K be an element of M, {ai }i=1 3
be its vertices and {mi }i=1 be
the midpoints of the edges.


a3

m 1

m2
 a 2

 m 3

a1

We define the six local degrees of freedom (the β i are forms of P3 (K ))


( 1
β K (v) = v(a1K ), β K2 (v) = v(a2K ), β K3 (v) = v(a3K ),
(18)
β K4 (v) = v(m1K ), β K5 (v) = v(m2K ), β K6 (v) = v(m3K ).

A nice way to express the local shape functions associated to these degrees of freedom
3
consists in introducing the barycentric coordinates {λi }i=1 uniquely defined by the relati-
ons:
X3 X 3
i
x = λi (x) a K with λi (x) = 1. (19)
i=1 i=1
The local shape functions are then given by:
 1
 b K (x) = λ1 (x) (2λ1 (x) − 1),





 b2K (x) = λ2 (x) (2λ2 (x) − 1),



 b3 (x) = λ3 (x) (2λ3 (x) − 1),
K
(20)


 b4K (x) = 4 λ2 (x) λ3 (x),



 b5K (x) = 4 λ1 (x) λ3 (x),



 6
b K (x) = 4 λ1 (x) λ2 (x).

The local stiffness matrix A K ∈ R6×6 is the following:


Z
i, j j
AK = ∇biK ∇b K . (21)
K

Hint: to compute the local stiffness matrix, one can use the following formula:
Z
2 α 1 ! α2 ! α3 !
λα1 1 λα2 2 λα3 3 = |K | . (22)
K (α1 + α2 + α3 + 2)!

Das könnte Ihnen auch gefallen