28
Lecture 16 Cramer’s Rule, Eigenvalue and Eigenvector Shang-Hua Teng

Lecture 16 Cramer’s Rule, Eigenvalue and Eigenvector Shang-Hua Teng

  • View
    238

  • Download
    2

Embed Size (px)

Citation preview

Lecture 16Cramer’s Rule, Eigenvalue and

Eigenvector

Shang-Hua Teng

Determinants and Linear SystemCramer’s Rule

333231

232221

131211

33323

23222

13121

1

33323

23222

13121

3

2

1

333231

232221

131211

3

2

1

3

2

1

333231

232221

131211

det

det

10

01

00

aaa

aaa

aaa

aab

aab

aab

x

aab

aab

aab

x

x

x

aaa

aaa

aaa

b

b

b

x

x

x

aaa

aaa

aaa

Cramer’s Rule

• If det A is not zero, then Ax = b has the unique solution

ni

A

aabaax niii

,...,2,1

det

],,,,,det[ 111

Cramer’s Rule for Inverse

nji

A

CA ji

ij

,...,2,1,

det1

A

aaeaaA niji

ij det

],,,,,det[ 1111 Proof:

Where Does Matrices Come From?

Graphs in Scientific Computing

Resource Allocation Graph

Road Map

Matrices Representation of graphs

Adjacency matrix: ( ) , # edgesij ijA a a ij

Adjacency Matrix:

01001

10100

01011

00101

10110

A

1

2

34

5

edgean not is j)(i, if 0

edgean is j)(i, if 1ijA

Matrix of GraphsAdjacency Matrix:• If A(i, j) = 1: edge exists

Else A(i, j) = 0.

0101

0000

1100

00101 2

34

1

-3

3

2 4

01001

12100

01311

00121

10113

L

1

2

34

5

Laplacian of Graphs

Matrix of Weighted GraphsWeighted Matrix:• If A(i, j) = w(i,j): edge exists

Else A(i, j) = infty.

032

0

430

101 2

34

1

-3

3

2 4

Random walks

How long does it take to get completely lost?

Random walks Transition Matrix

1

2

345

6

02

1

4

100

2

13

10

4

1000

3

1

2

10

2

1

3

10

004

10

3

10

004

1

2

10

2

13

1000

3

10

P

Markov Matrix

• Every entry is non-negative

• Every column adds to 1

• A Markov matrix defines a Markov chain

Other Matrices

• Projections

• Rotations

• Permutations

• Reflections

Term-Document Matrix• Index each document (by human or by

computer)– fij counts, frequencies, weights, etc

m term

2 term

1 term

n docdoc21 doc

21

22221

1 1211

mnmm

n

n

fff

fff

fff

• Each document can be regarded as a point in m dimensions

Document-Term Matrix• Index each document (by human or by

computer)– fij counts, frequencies, weights, etc

m doc

2 doc

1 doc

n term2 term1 term

21

22221

1 1211

mnmm

n

n

fff

fff

fff

• Each document can be regarded as a point in n dimensions

Term Occurrence Matrix

c1 c2 c3 c4 c5 m1 m2 m3 m4 human 1 0 0 1 0 0 0 0 0 interface 1 0 1 0 0 0 0 0 0 computer 1 1 0 0 0 0 0 0 0 user 0 1 1 0 1 0 0 0 0 system 0 1 1 2 0 0 0 0 0 response 0 1 0 0 1 0 0 0 0 time 0 1 0 0 1 0 0 0 0 EPS 0 0 1 1 0 0 0 0 0 survey 0 1 0 0 0 0 0 0 1 trees 0 0 0 0 0 1 1 1 0 graph 0 0 0 0 0 0 1 1 1 minors 0 0 0 0 0 0 0 1 1

Matrix in Image Processing

Random walks

How long does it take to get completely lost?

0

0

0

0

0

1

Random walks Transition Matrix

1

2

345

6

0

0

0

0

0

1

02

1

4

100

2

13

10

4

1000

3

1

2

10

2

1

3

10

004

10

3

10

004

1

2

10

2

13

1000

3

10

100

P