Vous êtes sur la page 1sur 22

Finite Element Method I

Getting Started

Melanie Ganz
ganz@diku.dk
Department of Computer Science
University of Copenhagen

11. Januar 2010


Getting Started

Before we start on FEM, we should be clear on what you need to


know a bit about

Ordinary Differential Equations (ODEs),


Stress and
Strain.

The basics of ODEs you can find in any math text book and an
introductory lecture to stress and strain from last year’s course,
Physics Based Animation, is uploaded on Absalon.

2
What Is FEM?

FEM is a procedure for obtaining numerical approximations to the


solution of boundary value problems.

3
So What Are Boundary Value Problems?

If we e.g. have two ordinary differential equations (ODEs)

ẋi = vi
Fi
v̇i =
mi

(that could e.g. results from the second law of motion, Fi = mi ẍi ),
then given xi (0), vi (0) we call it an
Initial Value Problem (IVP)
and given xi (0), xi (T ), we call it a
Boundary Value Problem (BVP)

4
Back To What Is FEM?

So FEM is a procedure for obtaining numerical approximations to


the solution of boundary value problems, which are sets of ordinary
differential equations whose solution is subject to certain boundary
conditions.

5
What Is FEM In Detail?

The general idea is to formulate a deformation of a solid or fluid as


a matrix equation of the following form:

Ka = f

Here K is a symmetric, positive definite stiffness matrix, a is a


vector of nodewise displacements and f is a vector of external
forces. The goal of FEM is to solve for a.

6
How do we get there?

How can we get to this mysterious matrix equation?

Ka = f

By e.g. applying the Principle of Virtual Work.

7
Back to the Basics: Work

The definition of mechanical work is given by


Z
W = F · ds,
C

where C is the curve transversed by the object, F is the force vector


acting on the object and s is the position vector of the object.

8
Back to the Basics: Principle of Virtual Work

The Principle of Virtual Work establishes a relation between


variations in internal and external work due to infinitesimal
displacement variations for a deformable body.
Z
Internal work = δT σdΩ (1)

Z Z
External work = δu bdΩ + δuT tdΓ
T
(2)
Ω Γ

Here σ are internal stresses, b are external body forces and t are
the external surface forces, while δ are strains and δu are
displacements. Ω is the volume or area and Γ the boundary of the
elements we consider.

9
Back to the Basics: Principle of Virtual Work

For a general deformable body the Principle of Virtual Work can


then be written as
Z Z Z
δT σdΩ = δuT bdΩ + δuT tdΓ
Ω Ω Γ

(see also Zienkiewicz and Taylor, chapter 3, page 55, eq. 3.47)
This means that arbitrary virtual displacements must lead to
identical variations in internal and external work.

10
From there on

We make the following substitutions in our virtual work equations


(see Zienkiewicz and Taylor, Appendix C):
We approximate the overall displacement
P by the sum of small
displacements at each node u = i Ni ai = Na
We use the definition of strain  = SNa = Ba and
stress σ = D( − 0 ) + σ0 , but set 0 = σ0 = 0.
We remember that (ab)T = b T aT .

11
From there on

This way we get


Z Z Z
T
δaB DBadΩ = δaN bdΩ + δaNT tdΓ
T
Ω Ω Γ

which can be written as


Z Z Z 
T T T
δa B DBdΩa − N bdΩ − N tdΓ = 0
Ω Ω Γ

12
From there on

Since this has to hold for all arbitrary displacements δa we end up


with the solution if
Z Z Z
T
B DBdΩa − N bdΩ − NT tdΓ = 0
T
Ω Ω Γ

This can also be written as

Ka = f,
T T T
R R R
if we define K = ΩB DBdΩ and f = Ω N bdΩ + ΓN tdΓ.

13
How do we do this in practice?

We’ll learn how to do that by a simple example now and in the


exercise this week!

14
A Simple Example

In Zienkiewicz and Taylor we can find a nice example on page 88:

We see a triangle element as it


could also appear in a deformable
body. So let’s try to assemble an
equation like

Ka = f,

for it.

15
A Simple Example
We first need to define
P the displacements u and how to calculate
them as given in u = i Ni ai = Na. You can follow on page 88 of
Zienkiewicz and Taylor how he derives the Ni .

For our example they look like


this:
ai + bi x + ci y
Ni = I
2Atri
where ai = xj ym − xm yj ,bi =
yj − ym ,ci = xm − xj , Atri is the
area of the triangle ijm and I is a
two by two identity matrix.

16
A Simple Example
Next we need to find a way of expressing K.

It is defined as K = Ω BT DBdΩ, but since we only have one


R

element we can drop the integral and get

K = BT DB

Let’s start with B: It is defined as B = SN or per node i as


Bi = SNi . We already know Ni from above. S is according to
the definition of total strain given as
 

0
 ∂x ∂ 
S =  0 ∂y 
∂ ∂
∂y ∂x

17
A Simple Example

Next we look for D: For planar stress in an isotropic material


you can find the elasticity matrix to be
 
1 ν 0
E 
D= ν 1 0 ,
1 − ν2 1−ν
0 0 2

where E is the elastic modulus and ν is Poisson’s ratio.

18
A Simple Example
To get the right hand sideR of our matrixR equation, we need to
calculate f = Ω NT bdΩ + Γ NT tdΓ.
We already know N.
What we need is b. For plane stress that will simply look like

b = (bx , by )T .

The tricky part is now to carry out the integration


f1 = Ω NT bdΩ. (You can see the details on page 96 in
R

Zienkiewicz and Taylor.) Important is that one ends up with


Atri
f e = (fi e , fje , fme )T = − (bx , by , bx , by , bx , by )T ,
3
which means that the total forces acting in the x and y
directions are distributed to the three nodes in equal parts.
19
A Simple Example

The last missing piece is t in f2 = Γ NT tdΓ. t are the


R

external surface forces, like pressure, and they will depend on


the problem we are given. If one e.g. gets the application of a
force acting like gravity on all nodes i, then

t = (0, −ty ).

If we have a force pulling just on e.g. the third node, we can


engineer f2 to sth. like

f 2 = (0, 0, 0, 0, 0, −ty )T .

20
A Simple Example

If you now plug in numbers for the coordinates and the forces, you
end up with a matrix equation

Ka = f,

that you can solve with MatLab.

21
That is It!

Questions?

22