You are on page 1of 9

FINITE ELEMENT METHOD

NUMERICAL INTERGRATION
Differentiation and Integration are the two basic processes of calculus. One or both of these
processes will generally be encountered in application where models are described in terms of
rates. It is always possible to determine an analytic form of a derivative for a given function.
However, in some case the analytical form is very complicated, and a numerical approximation of
the derivative may be sufficient for the desired degree of accuracy.
For the function which are described only in terms of tabulated data. Numerical differentiation is
the only means of computing a derivative.

INTEGRATION is the process of finding a function, given its derivative, is called anti-
differentiation (or integration). If F'(x) = f(x), we say F(x) is an anti-derivative of f(x)
Integrals arise when we wish to determine the change in a quantity ‘y’ whose rate of change with
respect to another variable ‘x’ is described as a function f(x). If we have a relation

dy/dx = f (x) …………… (1)

The change in y from ya at x equal to xa to yb at x equal to xb is written as

a ∫b dy = a∫b f (x) dx ………… (2)

yb – ya = a ∫b f (x) dx ……… (3)

The relation in equation (1) is a simple form of an ordinary differential equation. Its solution is
described by definite integral in equation (2). The integration process is a summation process of
the quantity f(x) dx as the area bounded under curve of the function f(x) with height f(x) and width
an infinitesimally small width dx. The definite integral in equation (2) is sum of all such areas for
‘x’ values from xa to xb.
Numerical Integration is used to integrate tabulated functions or to integrate functions whose
integrals are either impossible or very difficult to solve analytically.

1
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
GAUSSIAN QUADRATURE RULE
Consider the definite integral a ∫b f(x) dx
Which is solved by Gaussian Quadrature rule since this method will give better accurate solution
when compared to any other numerical method.

Gauss quadrature implements a strategy of positioning any two points on a curve as shown in the
figure 1 to define a straight line that would balance the positive and negative errors. Hence, the
area evaluated under this straight line provides an improved estimate of the integral.

Figure 1
Consider the problem of numerically evaluating one dimensional definite integral of the form
I= a ∫b f(x) dx ……… (1)
We frequently come across the limits of integral in actual problem varying from a to b. But in
Finite Element Analysis the problems are formulated using natural coordinates systems whose
value varies from -1 to +1.
Thus, one method of dealing with this is to transform the actual problem to one which does have
the limit from -1 to +1 as
I= a ∫b f(x) dx = a∫b f() d ……… (2)
As the limits of integral a to b in x domain of equation (1) has to be changed/mapped onto  domain
from -1 to +1 by means of the transformation given by
x = (b-a)/2 + (b+a)/2 ………. (3) and dx = (b-a)d/2 ………….. (4)
In which x and dx as in equation (3) and (4) is replaced by  and d in second integral of equation
(2).
2
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
Then Gaussian Formula is expressed in the form
n
I = ∫abf(x) dx = ∫-1+1 f() d = ∑ Wg f(g)……… (5)
g=1

= W1f(1) + W2f(2) + W3f(3) + W4f(4) + W5f(5) + ……. + Wnf(xn) ………..(6)


Where W1, W2, W3…....Wn are weight functions and 1, 2, 3 …… n are Gaussian Points.
Get the definite integration of f() in the limit -1 to +1 using linear combinations of coefficient ci
and evaluated function value f(i) at the point i
Appropriate values of the points i and Wi depend on the choice of n
Where f() = c0 + c1 +c22 + c33 +…….cnn ...(7)
By choosing the quadrature point 1 ,… n as the nth-degree Gaussian polynomial, and by using
the appropriate coefficients, the integration formula is exact for polynomials of degree up to 2n-1

Let us consider the n-point approximation


+1 n
I = ∫abf(x) dx = ∫ f() d = ∑ Wg f(g)
-1 g=1

I = W1f(1) + W2f(2) + W3f() + W4f(4) + W5f(5) +……. + Wnf(n) …… (8)


The concept behind Gaussian Quadrature rule is to select the ‘n’ Gaussian point and ‘n’ weight
functions such that equation (8) provides an exact solution for the polynomials f() as large a
degree as possible. Then the method will work well if is not a polynomial.
Now considering 3-point approximation
Then from equation (7) we have f() = c0 + c1 +c22 + c33 …… (9)
+1 +1 +1 +1
Then ∫ f()dx = ∫ [c0+c1+c22+c33]d = c0[] +(c1/2)[2]-1+1+(c2/3)[3]-1+1+(c3/4)[4]
-1 -1 -1 -1

Substituting the limits we get


+1
∫ f()dx = 2c0+2c2/3 where as c1 and c3 are zero
-1

Considering the integrals independently term by them we have


c0d = c0[]-1+1 =2c0 ……… (10)
c1d=(c1/2)[2]-1+1=(c1/2)[12-(-1)2]=(c1/2)(0)=0..(11)
c22d=(c2/3)[3]-1+1=(c2/3)[13-(-1)3]=(c1/3)[1+1 = 2c2/3 ………(12)
c33d= (c3/4)[4]-1+1=(c3/4)[14-(-1)4]=(c1/3)[1-1] = 0 ………… (13)

3
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
For 3-point approximation from equation (9) we have
2 3
f() = c0 + c1 +c2 + c3
+1 +1 2 3
I= ∫ f()d = ∫ [c0 + c1 +c2 + c3 ]d
-1 -1

= W1f(1) + W2f(2) + W3f(3)


2 3 2 3 2 3
= W1[c0+c11+c21 +c31 ]+W2[c0+c12+c22 +c32 ]+W3[c0+c13+c23 +c33 ] …… (14)

Equation (14) can also be written as


I = c0 [W1+W2+W3]+c1[W11+W22+W33] + c2 [W112+W222+W332] + c3
[W+W223+W333] ……(15)
Now depending upon the order of the polynomial such as when n=1 function is linear, when n=2
function is quadratic and when n=3 function is cubic.
In order to learn how the method works, we shall discuss one point and two point approximations

ONE POINT FORMULA: According to Gaussian Quadrature rule equation (8) will work for
polynomial having degree equal to (2n-1) thus when n = 1 we have 2x1-1=1 i.e. a linear function
can be easily evaluated. Thus for linear function f() = c0 + c1 …….. (16)
When we substitute equation (16) in to equation (15)
+1 +1
Then ∫ f() d = ∫ (c0 + c1) d = c0W1 + c1W11 ….(17)
-1 -1
+1
From equation (10) and (11) we have ∫ c0d = c0[]-1+1 =2c0 ……… (10)
-1
+1
∫ c1d=(c1/2)[2]-1+1=(c1/2)[12-(-1)2]=(c1/2)(0)=0 ……..(11)
-1

From equation (17) 2c0 + 0 = W1(c0+c11) ………… (18)


From equation (18) we have 2c0 + 0 = W1c0+ W1c11 …… (19)
Thus, equating the coefficient of c0and c1 we have 2c0 = W1c0 Thus W1 = 2 ………. (20)
0 = W1c11 since W1 = 2 we have 2c11 = 0 since c1 is constant which cannot be equal to zero
then 1 should be equal to zero i.e. 1 = 0 .............. (21)
Thus, for one-point formula W1 = 2 and 1 = 0

4
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
TWO POINT FORMULA
Let us consider with n = 2 then according to Gaussian Quadrature rule equation (9) will work for
polynomial having degree equal to (2n-1) = 2x2-1=3
Then f () = c0 + c1 + c22 + c33…….. (22)

+1
The Gaussian Integral is I = ∫ f ()d = W1f(1) + W2f(2) …….. (23)
-1

When we substitute equation (22) in to equation (23)


+1 +1
Then ∫ f() d = ∫ (c0+c1 + c22 + c33) dx
-1 -1

= c0[W1+W2]+c1[W11+W22]+c2[W112+W222] + c3[W113+W223] ……(24)

Integral of the function c0+c1x + c2x2 + c3x3 are evaluated in equation (10), (11), (12) and (13) as
Considering the integrals independently term by them we have
+1
∫ c0dx = c0[x]-1+1 =2c0 ……… (10)
-1
+1
∫ c1xdx = (c1/2)[x2]-1+1 = (c1/2)[12-(-1)2] = (c1/2)(0) = 0 ………...(11)
-1
+1
∫ c2x2dx = (c2/3)[x3]-1+1 = (c2/3)[13-(-1)3] = (c1/3)[1+1] = 2c2/3 ………(12)
-1
+1
∫ c3x3dx = (c3/4)[x4]-1+1 = (c3/4)[14-(-1)4] = (c1/3)[1-1] = 0 ………… (13)
-1

From equation (10), (11), (12), (13) and (24), we have


2c0 = c0[W1+W2] …….. (25)
0c1 = c1[W11+W22] …….. (26)
2c2/3 = c2[W112+W222] …….. (27)
0c3 = c3[W113+W223] …….. (28)
Above four equations can know be written as
2 = [W1+W2] …….. (29)
0 = [W11+W22] …….. (30)
2/3 = [W112+W222] …….. (31)
0 = [W113+W223] …….. (32)

5
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
Equations (29), (30), (31) and (32) have a unique solution given as
1 = -1/√3 W1 = 1.0
2 = +1/√3 W2 = 1.0
In which 1 and 2 are the Gaussian Points and
W1 and W2 are the weight function.
In similar manner 3-Point Gaussian formula can be derived.
Thus for 3-Point Gaussian formula can be derived.
1 = -√(3/5) = -√0.6 W1 = 5/9 = 0.55556
2 = 0 W2 = 8/9 = 0.88889
3 = +√(3/5) = +√0.6 W3 = 5/9 = 0.55556
In which 1 , 2 and 3 are the Gaussian Points and W1 , W2 and W3 are the weight functions
Depending upon ‘n’ Wi and F(i) are tabulated
Gaussian Quadrature Table

n  W n  W
i i i i

1 0 2 1 0 2
2 - 1/√3 1.0 OR 2 -√0.33 1.0
+ 1/√3 1.0 +√0.33 1.0
3 -√3/5 5/9 3 -√0.6 0.55556
0 8/9 0 0.88889
+√3/5 5/9 +√0.6 0.55556

6
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
SOLUTION OF SOME NUMERICAL EXAMPLE PROBLEMS USING
GAUSSIAN QUADRATURE RULE
1
Example – 1: Solve by Gaussian Quadrature Rule ∫ 1/(1+x2) dx
0

Exact Solution by definite Integration


1
I = ∫ 1/(1+x2) dx = Tan-1(x) = Tan-1(1) - Tan-1(0) = 0.7854
0

Changing the limits of Integration ∫ab f (x) dx = ∫-1+1 f () d

Where x = [(b-a) + (b+a)]/2 then dx = [(b-a) d/2

Here a = 0 and b = 1 Since x = (b-a)/2 + (b + a)/2 dx = [(b-a)d]/2

Thus x = 0.5  + 0.5 dx = 0.5 d

1 1 1
I = ∫ 1/(1+x2) dx = ∫ [1/{1+(0.5+0.5)2}]0.5d I = 1/2 ∫ f() d
0 -1 -1

Where f() = 1 /{1+0.25(+1)2}

One-point formula 1 = 0 and W1 = 2


b
∫ f(x) dx = 1/2 [ f (1) W1 ] = 1/2 * [1 /{1+0.25(+1)2}]*2 = 0.8000
a

Two-point formula
1 = -1/√3 and W1 = 1 2= +1/√3 and W2 = 1 and f() = 1 /{1+0.25(+1)2}
1 2
I=½∫ f() d= 1/2 [ ∑ g=1 f(g) Wg ] = 1/2 [ f(1) W1 + f(2) W2 ]
-1

1/2 *[ [1 /{1+0.25(- 1/√3+ 1)2}]*1 + [1 /{1+0.25( 1/√3+ 1)2}]*1] = 0.7869

Three-point formula
1 = -√0.6 and W1 = 5/9, 2 = 0 and W2 = 8/9 and 3 = +√0.6 and W3 = 5/9

Where f() = 1 /{1+0.25(+1)2}


1 +1 3
I=½∫ f() d = 1/2 ∫ f() d = 1/2 ∑ f(g)Wg =1/2[ f(1)W1 + f(2)W2 + f(2)W2]
-1 -1 g=1

= ½[ [1/{1+0.25(-√0.6+1)2}]*5/9]+[1/{1+0.25(0+1)2}]*8/9]+[1/{1+0.25(+√0.6+1)2}]*5/9]]

= 0.7854
7
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
1
Example – 2 : Solve by Gaussian Quadrature Rule ∫ 1/(1+x) dx
0

Exact Solution by definite Integration


1 1
I = ∫ 1/(1+x)dx = [ln(1+x)] = ln(1+1) - ln(1+0) = 0.6931
0 0

By Gaussian Quadrature Rule


b +1
Changing the limits of Integration ∫ f (x) dx = ∫ f () d
a -1
Where x = [(b-a) + (b+a)]/2 then dx = [(b-a)d/2

Here a = 0 and b = 1 Since x = (b-a)/2 + (b + a)/2 dx = [(b-a)d]/2

Thus x = 0.5  + 0.5 dx = 0.5 d

1 +1 1
I = ∫ 1/(1+x2) dx = ∫ [1/{1+(0.5+0.5)}]0.5d = ½ ∫ f() d Where f() = 1/{1+0.5(+1)}
0 -1 -1

One-point formula 1 = 0 and W1 = 2


b +1
∫ f (x) dx = ½ ∫ f () d = 1/2 [ f (1) W1 ] = 1/2 * [1 /{1+0.5(+1)}]*2 = 0.6667
a -1

Two-point formula
1 = -1/√3 and W1 = 1 2= +1/√3 and W2 = 1 and f() = 1 /{1+0.5(+1)}
b +1 2
∫ f (x) dx = ½ ∫ f () d = 1/2 [ ∑ g=1 f(g) Wg ] = 1/2 [ f(1) W1 + f(2) W2 ]
a -1

1/2 *[ [1 /{1+0.5(- 1/√3+ 1)}]*1 + [1 /{1+0.5( 1/√3+ 1)}]*1] = 0.6923

Three-point formula
1 = -√0.6 and W1 = 5/9, 2 = 0 and W2 = 8/9 and 3 = +√0.6 and W3 = 5/9

Where f() = 1 /{1+0.5(+1)}


b +1 3
I = 1/2 ∫ f(x) dx = 1/2 ∫ f() d = 1/2 ∑ f(g)Wg =1/2[ f(1)W1 + f(2)W2 + f(2)W2]
a -1 g=1

= ½[ [1/{1+0.5(-√0.6+1)}]*5/9]+[1/{1+0.5(0+1)}]*8/9]+[1/{1+0.5(+√0.6+1)}]*5/9]]

= 0.6931

It is observed the error in the results decreases as the number of Gaussian point are increased
and it is found that from the three point Gaussian formula the results are accurate up to the
fourth decimal place.
8
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru
FINITE ELEMENT METHOD
1
Example – 3: Solve by Gaussian Quadrature Rule ∫ [3ex + x2 + 1/(x+2)] dx
-1

Exact Solution by definite Integration


+1 +1 +1 +1
I=∫ [3e +2+1/(+2)] = 3[e]-1 + [/3]-1 +[ ln(+2)] -1
-1

= 3[e(+1) – e(-1)] + [1-(-1)]/3 + [ln(1+2)-ln(-1+2)] = 7.0512+0.6667+1.0986 = 8.8165

By Gaussian Quadrature Rule


Changing the limits of Integration is not required since the limits are from -1 to +1. Hence
1 1
replacing x by  we have ∫ [3e + 2 + 1/(+2)] d = ∫ f() d
-1 -1

Where f () = [3e + 2 + 1/(+2)]

One-point formula 1 = 0 and W1 = 2


+1
I= ∫ f () d = [ f (1) W1 ] = [3e + 2 + 1/(+2)]*2 = 7.000
-1

Two-point formula
1 = -1/√3 and W1 = 1 2= +1/√3 and W2 = 1 and f() = [3e + 2 + 1/(+2)]
b +1 +1 2
∫ f (x)dx = ∫ [3e + 2 + 1/(+2)] = ∫ f () d = ∑ g=1 f(g) Wg = f(1) W1 + f(2) W2
a -1 -1

[3e(-1/√3) + (-1/√3)2 + 1/((-1/√3)+2)]*1 + [3e(1/√3) + (1/√3)2 + 1/((1/√3)+2)]*1 = 8.7857

Three-point formula
1 = -√0.6 and W1 = 5/9, 2 = 0 and W2 = 8/9 and 3 = +√0.6 and W3 = 5/9

Where f() = f() = [3e + 2 + 1/(+2)]


b +1 +1 3
∫ f (x)dx = ∫ [3e + 2 + 1/(+2)] = ∫ f () d = ∑ f(g) Wg = f(1) W1+f(2)W2+f(3)W3
a -1 -1 g=1

= [3e(-√0.6) + (-√0.6)2 + 1/((-√0.6)+2)]*[5/9] + [3e(0) + (0)2 + 1/(0+2)]*[8/9] + [3e(√0.6) + (√0.6)2 +


1/((√0.6)+2)]*[5/9]
= 8.8157
It is observed the error in the results decreases as the number of Gaussian point are increased
and it is found that from the three point Gaussian formula the results are accurate up to the
fourth decimal place.
9
Dr. Jagadish. T, Former Professor and Head, Department of Mechanical Engineering, BIT, Bengaluru
Presently Director, Research and Development, DHIO Research and Engineering Pvt. Ltd., Bengaluru

You might also like