hw1_solution
hw1_solution
CH. 2
Problem 1.
→ 𝑥 = 0.0467𝑑
The number of the cones in the region of the highest acuity in eye ≈ 337,000 (from the
discussion in section 2.11)
→ Array size = 580 × 580 elements
Assuming equal spacing between elements
→ 580 elements and 579 spaces on a line 1.5 mm long
1.5 𝑚𝑚
∴ The size of each element = = 1.3 × 10−6
1159
The eye will not detect a dot if its diameter, 𝑑, is such that, 0.467𝑑 < 1.3 × 10−6
→ 𝑑 < 27.83 × 10−6
Problem 5.
See the Fig. 2.3.
14𝑚𝑚 𝑧
= 500𝑚𝑚
35𝑚𝑚
Problem 7.
From eq.2.3-2,
𝑓(𝑥, 𝑦) = 𝑖(𝑥, 𝑦) ∙ 𝑟(𝑥, 𝑦)
2 2
= 𝑘𝑒 −[(𝑥−𝑥0) +(𝑦−𝑦0) ] ∙ 𝑟(𝑥, 𝑦)
Reflectance = 1.0, k = 255, The maximum intensity = 255
If the intensity is quantized using 𝑛 bits,
256
(Resolution) ∆= 2𝑘
256
Since the abrupt change of four level is assumed to be detectable by the eye, ∆= 4 =
2𝑘
→ 𝑘 = 6 bits
𝑘 ≤ 6 bits will produce false contouring
Problem 11.
Let p and q be as shown in the figure at the left side.
(a) S1 and S2 are NOT 4-connected as q is not in the set N4(p)
(b) S1 and S2 are 8-connected as q is in the set N8(p)
(c) S1 and S2 are m-connected as (1) q is in ND(p) and (2)
the set N4(p)∩ N4(q) is empty.
CH. 3
Problem 1.
Let f denote the original image. First subtract the minimum value of f denote fmin from f to yield
a function whose minimum value is 0:
𝑔1 = 𝑓 − 𝑓𝑚𝑖𝑛
Next divide g1 by its maximum value to yield a function in the range [0,1] and multiply the
result by L-1-C to yield a function with values in the range [0, L-1-C]
𝐿−1−𝐶
𝑔= (𝑓 − 𝑓𝑚𝑖𝑛 )
max (𝑓 − 𝑓𝑚𝑖𝑛 )
Finally add C to yield a function in the range [C, L-1]
𝐿−1−𝐶
𝑔= (𝑓 − 𝑓𝑚𝑖𝑛 ) + 𝐶
max(𝑓 − 𝑓𝑚𝑖𝑛 )
Problem 2.
2
(a) General form: 𝑠 = 𝑇(𝑟) = 𝑒 −𝛼𝑟
If 𝑟 = 0, then 𝑠 = 𝐴
→ 𝐴=1
If 𝑟 = 𝐿0 , then 𝑠 = 𝐴/3
𝐴 2
→ = 𝑒 −𝛼𝐿0
3
𝐴 1
𝑙𝑛( ) 𝑙𝑛( ) 1.098
3 3
𝛼=− =− =
𝐿20 𝐿20 𝐿20
1.098 2
− 𝑟
𝐿2
∴ 𝑠 = 𝑇(𝑟) = 𝑒 0
2
(b) General form: 𝑠 = 𝑇(𝑟) = 𝐵(1 − 𝑒 −𝛼𝑟 )
If 𝑟 = 0, then 𝑠 = 0
If 𝑟 = 𝐿0 , then 𝑠 = 𝐵/4
𝐵 2
→ = 𝐵(1 − 𝑒 −𝛼𝐿0 )
4
3
𝑙𝑛( ) 0.288
4
𝛼=− =
𝐿20 𝐿20
0.288 2
− 𝑟
𝐿2
∴ 𝑠 = 𝑇(𝑟) = B(1 − 𝑒 0 )
2
(c) 𝑠 = 𝑇(𝑟) = (𝐷 − 𝐶)(1 − 𝑒 −𝛼𝑟 ) + 𝐶
Problem 3.
1
(a) 𝑠 = 𝑇(𝑟) = 1+(𝑚/𝑟)𝐸
(b)
0, 𝑟 ≤ 𝑚 − 1
(c) 𝑠 = 𝑇(𝑟) = { 0.5, 𝑟 = 𝑚
1, 𝑟 ≥ 𝑚 + 1
If C is the smallest positive number representable in the computer, then any value of
s (> 0) less than C/2 will be called 0 by the computer.
Solve the following equation for E using 𝑚 = 128
1 𝐶
𝐸 <
𝑚 2
1 + [𝑚 − 1]
MATLAB task
% bicubic interpolation
y2=interp2(x, 'cubic');