1 Iterative Methods For Linear Systems 2 Eigenvalues and Eigenvectors
1 Iterative Methods For Linear Systems 2 Eigenvalues and Eigenvectors
Consider the linear system Ax = b, with det A = 0. We use the splitting A = L + D + U , where
D is diagonal, L is stricly lower triangular and U is strictly upper triangular. Here strictly
means that the diagonal entries are zero.
1.1
2.1
Power Method
Let z (0) be an initial vector (it is usual to take z (0) = (1, . . . , 1)T ). The Power Method is then
Method of Jacobi
Assume that the diagonal elements of A are dierent from zero. A step of the method of Jacobi
is given by
1
(k+1)
(k)
=
aij xj + bi , i = 1, 2, . . . , n.
xi
aii
y (k) =
z (k+1) = Ay (k) ,
(y (k) )T Ay (k)
= (y (k) )T z (k+1) .
k =
(y (k) )T y (k)
j=i
1.2
Method of Gauss-Seidel
Assume that the diagonal elements of A are dierent from zero. A step of the method of
Gauss-Seidel is given by
1
(k+1)
(k+1)
(k)
=
aij xj
aij xj + bi , i = 1, 2, . . . , n.
xi
aii
j<i
j>i
Under suitable conditions, the sequence {k }k converges to the eigenvalue with the largest
modulus, and {y (k) }k (or {z (k) }k ) converges to the corresponding eigenvector.
2.2
Method of Jacobi
Let A be a real n-by-n symmetric matrix. Assume we are in the k-th step of the Jacobi method
and, to simplify the notation, we dene B = Ak .
Assume that we have chosen two indices (p, q) such that bpq = 0 and we want to rotate in
this plane such that the new matrix satises bpq = bqp = 0. The angle of rotation is given by
If we write the method as x(k+1) = BGS x(k) + c, then BGS = (L + D)1 U and c = (L + D)1 b.
1.3
Assume that the diagonal elements of A are dierent from zero. A step of the method of SOR,
with parameter , is given by
1
(k)
(k+1)
(k)
=
aij xj
aij xj + bi ,
ri
aii
j<i
(k+1)
xi
(k)
xi
cot(2) =
bpp bqq
,
2bpq
which means that the angle can be chosen in the interval ( 4 , 4 ). Then, it is not dicult to
nd explicit expressions for c = cos and s = sin :
If bpp = bqq , then = sign(bpq ), c =
2
2
and s =
2
2 .
If bpp = bqq , then = sign[bpq (bpp bqq )], d = (bpp bqq )2 + 4b2pq
ji
1
|bpp bqq | 2
1
1+
c=
,
2
d
(k)
ri .
z (k)
,
z (k) 2
and
1
|bpp bqq | 2
1
1
s=
.
2
d
2.3
QR factorization
2
vT v
vv T ,
is a Householder matrix.
Approximation
4.1
Orthogonal polynomials
Rn ,
1. Given a vector x
there is a Householder matrix Pv such that Pv x e1 . The vector
v is obtained as follows:
= x2 .
dened on the real vector space of continuous functions CR0 ([a, b]). The recurrence
2
i1 (x),
i+1 (x) = (x i+1 )i (x) i+1
v = x.
If = 0, = x1 + sign(x1 ), vj = 1 vj (j = 2, . . . , n).
v1 = 1.
i+1 =
xi , i
,
i , i
2
=
i+1
i = 0, 1, . . . , n 1,
0
i , i
i1 , i1
if i = 0,
if i = 1, 2, . . . , n 1,
produces the family of orthogonal polynomials such that i is a monic polynomial of degree i.
4.1.1
Legendre polynomials
The Legendre polynomials Pn are orthogonal polynomials for the scalar product
1
f (x)g(x) dx,
f, g =
w = AT v.
A = A + vwT .
Pn (x) =
= vT2 v .
w = Av.
A = A + wv T .
We will refer to this algorithm as A = postmult.h(A, v).
4. The QR algorithm can be written, in compact form, as follows. Let A be a m-by-n matrix
(m n):
FOR j = 1 to n
v(j : m) = householder(A(j : m, j)
A(j : m, j : n) = premult.h(A(j : m, j : n), v(j : m))
IF j < m
A(j + 1 : m, j) = v(j + 1 : m)
ENDIF
ENDFOR
dn 2
1
(x 1)n ,
2n (n!) dxn
2
They satisfy Pn , Pn =
and, for n 0,
2n + 1
2n + 1
n
xPn (x)
Pn1 (x),
Pn+1 (x) =
n+1
n+1
4.1.2
P1 (x) 0,
P0 (x) 1.
f (xi )g(xi ),
i=0
{Pn,m }m
n=0
xi = 1 +
2i
,
m
i = 0, 1, . . . , m.
1/2
4(n + 1)2 1
m
,
n,m =
n + 1 (m + 1)2 (n + 1)2
n = 1, 2, . . .
n,m =
n,m
.
n1,m
4.2
Periodic functions
f () =
a0
aj cos j + bj sin j,
+
2
tn+1 = tn + hn ,
j=1
x
n+1 = x
n + hn f (tn , x
n ).
where
a0 =
4.2.1
f () d,
aj =
f () cos j d,
bj =
f () sin j d.
tn+1 = tn + hn ,
n + hn f (tn+1 , x
n+1 ).
x
n+1 = x
Discrete case
f (i )g(i ),
i =
i=0
2i
,
m+1
5.1
i = 0, 1, . . . , m.
f () =
a0
aj cos j + bj sin j,
+
2
j=1
where
m
a0 =
2
f (i ),
m+1
i=0
aj =
2
f (i ) cos ji ,
m+1
i=0
bj =
n ; tn , x
n ).
x
n+1 = (h
2
f (i ) sin ji .
m+1
i=0
1
1
k2 = f (t+ h, x+ hk1 ),
2
2
1
1
k3 = f (t+ h, x+ hk2 ),
2
2
k4 = f (t+h, x+hk3 ).