Chapter 12 Part 1-Digital Image Processing-Solution Manual, Exercises of Digital Image Processing

This solution manual is for problems related Digital Image processing course. This was recommended by Prof. Anwar Malik at Bengal Engineering and Science University. It includes: Covariance, Matrices, Bayes, Decision, Boundary, Function, Probability, Theory, Argument

Typology: Exercises

2011/2012

Uploaded on 07/23/2012

ganpati
ganpati 🇮🇳

4.1

(30)

56 documents

1 / 4

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
112
CHAPTER 12. PROBLEM SOLUTIONS
Because the covariance matrices are not equal, it follows from Eq. (12.2-26) that
d1(x)=1
2ln(0.25)1
2)xT'20
02
(x0
=1
2ln(0.25)(x2
1+x2
2)
and
d2(x)=1
2ln(4.00)1
2)xT'0.5 0
00.5
(x0
=1
2ln(4.00)1
4(x2
1+x2
2)
where the term lnP(ωj)was not included because it is the same for both deci-
sion functions in this case. The equation of the Bayes decision boundary is
d(x)=d1(x)d2(x)=1.39 3
4(x2
1+x2
2)=0.
(b) Figure P12.8 shows a plot of the boundary.
Problem 12.10
From basic probability theory,
p(c)=
x
p(c/x)p(x).
For any pattern belonging to class ωj,p(c/x)=p(ωj/x). Therefore,
p(c)=
x
p(ωj/x)p(x).
Substituting into this equation the formula p(ωj/x)=p(xj)p(ωj)/p(x)gives
p(c)=
x
p(xj)p(ωj).
Because the argument of the summation is positive, p(c)is maximized by maxi-
mizing p(xj)p(ωj)for each j.Thatis,ifforeachxwe compute p(xj)p(ωj)
for j=1,2,...,W, and use the largest value each time as the basis for selecting
the class from which xcame, then p(c)will be maximized. Since p(e)=1p(c),
the probability of error is minimized by this procedure.
pf3
pf4

Partial preview of the text

Download Chapter 12 Part 1-Digital Image Processing-Solution Manual and more Exercises Digital Image Processing in PDF only on Docsity!

112 CHAPTER 12. PROBLEM SOLUTIONS

Because the covariance matrices are not equal, it follows from Eq. (12.2-26) that

d 1 ( x ) = −

ln(0.25) −

x T

x

ln(0.25) − (x 21 + x 22 )

and

d 2 ( x ) = −

ln(4.00) −

x T

x

ln(4.00) −

(x 21 + x 22 )

where the term lnP( ω j ) was not included because it is the same for both deci- sion functions in this case. The equation of the Bayes decision boundary is

d ( x ) = d 1 ( x ) − d 2 ( x ) = 1.39 −

(x 12 + x 22 ) = 0.

(b) Figure P12.8 shows a plot of the boundary.

Problem 12.

From basic probability theory,

p (c ) =

x

p (c / x )p ( x ).

For any pattern belonging to class ω j , p (c / x ) = p ( ω j / x ). Therefore,

p (c ) =

x

p ( ω j / x )p ( x ).

Substituting into this equation the formula p ( ω j / x ) = p ( x j )p ( ω j ) / p ( x ) gives

p (c ) =

x

p ( x j )p ( ω j ).

Because the argument of the summation is positive, p (c ) is maximized by maxi- mizing p ( x j )p ( ω j ) for each j. That is, if for each x we compute p ( x j )p ( ω j ) for j = 1, 2, ..., W , and use the largest value each time as the basis for selecting the class from which x came, then p (c ) will be maximized. Since p (e ) = 1 − p (c ), the probability of error is minimized by this procedure.

Problem 12.

We start by taking the partial derivative of J with respect to w :

J w

y sgn( w T^ y ) − y

where, by definition, sgn( w T^ y ) = 1 if w T^ y > 0, and sgn( w T^ y ) = −1 otherwise. Substituting the partial derivative into the general expression given in the prob- lem statement gives

w (k + 1 ) = w (k ) + c 2

y ( k ) − y ( k )sgn w ( k )T^ y ( k )

where y (k ) is the training pattern being considered at the k th iterative step. Sub- stituting the definition of the sgn function into this result yields

w (k + 1 ) = w (k ) + c

0 if w ( k )T^ y ( k ) y (k ) otherwise

where c > 0 and w ( 1 ) is arbitrary. This expression agrees with the formulation given in the problem statement.

Problem 12.

The single decision function that implements a minimum distance classifier for two classes is of the form

d (^) i j ( x ) = x T^ ( m i − m j ) −

( m Ti m i − m Tj m j ).

Thus, for a particular pattern vector x , when d (^) i j ( x ) > 0, x is assigned to class ω 1 and, when d (^) i j ( x ) < 0, x is assigned to class ω 2. Values of x for which d (^) i j ( x ) = 0 are on the boundary (hyperplane) separating the two classes. By letting w = ( m i − m j ) and w (^) n + 1 = − 12 ( m Ti m i − m Tj m j ), we can express the above decision function in the form d ( x ) = w T^ x − w (^) n + 1.

This is recognized as a linear decision function in n dimensions, which is imple- mented by a single layer neural network with coefficients

w (^) k = (m (^) i k − m (^) j k ) k = 1, 2,... , n

and

θ = w (^) n + 1 = −

( m Ti m i − m Tj m j ).

Figure P12.

as we move further down the tree). We prove that k (^) a c ≥ min[k (^) ab , k (^) b c ] by con- tradiction. For k (^) a c ≤ min[k (^) ab , k (^) b c ] to hold, shape A has to separate from shape C before (1) shape A separates from shape B, and (2) before shape B separates from shape C , otherwise k (^) ab ≤ k (^) a c or k (^) b c ≤ k (^) a c , which automatically vio- lates the condition k (^) a c < min[k (^) ab , k (^) b c ]. But, if (1) has to hold, then Fig. P12. shows the only way that A can separate from C before separating from B. This, however, violates (2), which means that the condition k (^) a c < min[k (^) ab , k (^) b c ] is vi- olated (we can also see this in the figure by noting that k (^) a c = k (^) b c which, since k (^) b c < k (^) ab , violates the condition). We use a similar argument to show that if (2) holds then (1) is violated. Thus, we conclude that it is impossible for the condition k (^) a c < min[k (^) ab , k (^) b c ] to hold, thus proving that k (^) a c ≥ min[k (^) ab , k (^) b c ] or, equivalently, that D(A,C ) ≤ max[D(A, B ), D(B,C )].