Morton John Canty mort.canty@gmail.com
Image Analysis, Classification and Change Detection in Remote Sensing Fifth Revised Edition
Solutions to Selected Exercises
CRC PRESS Boca Raton Ann Arbor
London
Tokyo
Contents
1 Images, Arrays and Matrices
1
2 Image Statistics
7
3 Transformations
21
4 Convolutions, Filters and Fields
29
5 Image Enhancement and Correction
35
6 Supervised Classification Part 1
39
7 Supervised Classification Part 2
45
8 Unsupervised Classification
49
9 Change Detection
55
i
1 Images, Arrays and Matrices
Exercise 1 The components of x and y are x1 = ∥x∥ cos θx ,
x2 = ∥x∥ sin θx
y1 = ∥y∥ cos θy ,
y2 = ∥y∥ sin θy .
The angle between the two vectors is θx − θy . The inner product is therefore x⊤ y = ∥x∥∥y∥ cos(θx − θy ) = ∥x∥∥y∥(cos θx cos θy + sin θx sin θy ) = x1 y1 + x2 y2 .
Exercise 2 The outer product of x and y is ⊤
xy =
x1 y1 x2 y1
x1 y2 x2 y2
,
the determinant of which is |xy ⊤ | = x1 y1 x2 y2 − x1 y2 x2 y1 = 0. We can express the second column as in terms of the first: x1 x1 y2 = cy1 x2 x2 by choosing c = y2 /y1 , so thr rank is 1.
Exercise 3 Verifying the identity with random 2 × 2 matrices: import numpy as np A = np . mat ( np . random . rand (2 ,2)) B = np . mat ( np . random . rand (2 ,2)) print ( A * B ). T
1