The Islamic University of Gaza Faculty of Engineering Civil Engineering Department
description
Transcript of The Islamic University of Gaza Faculty of Engineering Civil Engineering Department
The Islamic University of GazaFaculty of Engineering
Civil Engineering Department
Numerical Analysis ECIV 3306
Chapter 22
Integration of Equations
Gauss Quadrature
• Gauss quadrature implements a strategy of positioning any two points on a curve 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.
Two points Gauss-Legendre Formula• Assume that the two Integration points are xo and x1 such that:
• The object of Gauss quadrature is to determine the equations of the form:
• c0 and c1 are constants, the function arguments x0 and x1 are unknowns…….(4 unknowns)
)()( 1100 xfcxfcI
Two points Gauss-Legendre Formula
• Thus, four unknowns to be evaluated require four conditions.
• If this integration is exact for a constant, 1st order, 2nd order, and 3rd order functions:
1
1
31100
1
1
21100
1
11100
1
11100
0)()(
32)()(
0)()(
21)()(
dxxxfcxfc
dxxxfcxfc
dxxxfcxfc
dxxfcxfc
Two points Gauss-Legendre Formula
• Solving these 4 equations, we can determine c1, c2, x1 and x2.
31
31 ffI
5773503.03
1
5773503.03
1:are pointsn Integratio The
1:are factors weightingThe
1
0
10
x
x
cc
Two points Gauss-Legendre Formula• Since we used limits for the previous integration from –1 to 1
and the actual limits are usually from a to b, then we need first to transform both the function and the integration from the x-system to the xd-system
1ax1bx
d2
abdx
2ab
2abx
f(x)
x
a b
f(xo)
f(x1)
xo x1 -1 1
f()
Higher-Points Gauss-Legendre Formula
)(.....)()()(
)(
nn2211
n
1iii
1
1i
fcfcfcfcI
:points Gauss n usingdfI
Multiple Points Gauss-LegendrePoints Weighting factor Function argument Exact
for 2 1.0 -0.577350269 up to
3rd 1.0 0.577350269 degree
3 0.5555556 -0.774596669 up to 5th
0.8888889 0.0 degree0.5555556 0.774596669
4 0.3478548 -0.861136312 up to 7th
0.6521452 -0.339981044 degree0.6521452 0.3399810440.3478548 0.861136312
6 0.1713245 -0.932469514 up to 11th
0.3607616 -0.661209386 degree0.4679139 -0.2386191860.4679139 0.2386191860.3607616 0.6612093860.1713245 0.932469514
Gauss Quadrature - Example
Find the integral of: f(x) = 0.2 + 25 x – 200 x2 + 675 x3 – 900 x4 + 400 x5
Between the limits 0 to 0.8 using:
– 2 points integration points (ans. 1.822578)
– 3 points integration points (ans. 1.640533)
Improper Integral• Improper integrals can be evaluated by making a change
of variable that transforms the infinite range to one that is finite,
b
A
b A
b
a
a
b
dxxfdxxfdxxf
abdtt
ft
dxxf
)()()(
011)(/1
/12
A
A
dtt
ft
dxxf0
/12
11)(Can be evaluated by Newton-Cotes closed formula
Improper Integral - Examples
• .
• .
• .
dtt
dtt
ttxx
dx
5.0
0
5.0
0 2
2 211
2/11)(1
)2(
dyyedyyedyye yyy
2
22
0
2
0
2 sin sin sin
dttet
dyye ty 2/1
0
2/12
2
2 )/1(sin1 sin
dyyedyyedyye yyy
2
2
2
2
dtet
dyye ty 2/1
0
/13
2 1
Multiple Integration
dydxyxfId
cy
b
ax
),(
• Double integral:
Multiple Integration using Gauss Quadrature Technique
• .
• .
• . ddf
2ab
2cddydxyxfI
1
1
1
1
d
cy
b
ax
),(),(
1ax1bx &
d2
abdx2
ab2
abx
&
1cx1dy &
d2
cddy2
cd2
cdy
&
Multiple Integration using Gauss Quadrature Technique
Now we can use the Gauss Quadrature technique:
If we use two points Gauss Formula:
n
1jjiij
n
1i
fcc2
ab2
cdI ),(
)}],(),({
)},(),({[
31
31fc
31
31fcc
31
31fc
31
31fcc
2ab
2cdI
212
211
2
1jjijj
2
1i
fcc2
ab2
cdI ),(
2
1jj2j1j 3
1fc3
1fcc2
ab2
cdI )],(),([
Double integral - Example
72222),( 22 yxxxyyxT
• Compute the average temperature of a rectangular heated plate which is 8m long in the x direction and 6 m wide in the y direction. The temperature is given as:
• (Use 2 segment applications of the trapezoidal rule in each dimension)
Double integral - Example
6667.58)86/(2816,28163/1
56)86/(2688,2688)2(
)72222( 6
0
8
0
22
avg
avg
TIruleSimpson
TInrulelTrapezoidaMultiple
dxdyyxxxyI
HW: Use two points Gauss formula to solve the problem