Mathematical Methods for Physics and Engineering : A Comprehensive Guide

(lu) #1

NUMERICAL METHODS


and orthogonal over the interval− 1 ≤x≤1, as discussed in subsection 18.1.2.


Therefore, in order to use their properties, the integral between limitsaandbin


(27.34) has to be changed to one between the limits−1 and +1. This is easily


done with a change of variable fromxtozgiven by


z=

2 x−b−a
b−a

,

so thatIbecomes


I=

b−a
2

∫ 1

− 1

g(z)dz, (27.41)

in whichg(z)≡f(x).


Thenintegration pointsxifor ann-point Gauss–Legendre integration are

given by the zeros ofPn(x), i.e. thexiare such thatPn(xi) = 0. The integrandg(x)


is mimicked by the (n−1)th-degree polynomial


G(x)=

∑n

i=1

Pn(x)
(x−xi)Pn′(xi)

g(xi),

which coincides withg(x) at each of the pointsxi,i=1, 2 ,...,n. To see this it


should be noted that


lim
x→xk

Pn(x)
(x−xi)Pn′(xi)

=δik.

It then follows, to the extent thatg(x) is well reproduced byG(x), that


∫ 1

− 1

g(x)dx≈

∑n

i=1

g(xi)
Pn′(xi)

∫ 1

− 1

Pn(x)
x−xi

dx. (27.42)

The expression

w(xi)≡

1
Pn′(xi)

∫ 1

− 1

Pn(x)
x−xi

dx

can be shown, using the properties of Legendre polynomials, to be equal to


wi=

2
(1−x^2 i)|Pn′(xi)|^2

,

which is thus the weighting to be attached to the factorg(xi) in the sum (27.42).


The latter then becomes
∫ 1


− 1

g(x)dx≈

∑n

i=1

wig(xi). (27.43)

In fact, because of the particular properties of Legendre polynomials, it can be

shown that (27.43) integrates exactly any polynomial of degree up to 2n−1. The


error in the approximate equality is of the order of the 2nth derivative ofg,and

Free download pdf