数字图像处理_第二版中文版(冈萨雷斯)习题答案.pdf

上传人:蓝**** 文档编号:90991614 上传时间:2023-05-19 格式:PDF 页数:91 大小:1.33MB
返回 下载 相关 举报
数字图像处理_第二版中文版(冈萨雷斯)习题答案.pdf_第1页
第1页 / 共91页
数字图像处理_第二版中文版(冈萨雷斯)习题答案.pdf_第2页
第2页 / 共91页
点击查看更多>>
资源描述

《数字图像处理_第二版中文版(冈萨雷斯)习题答案.pdf》由会员分享,可在线阅读,更多相关《数字图像处理_第二版中文版(冈萨雷斯)习题答案.pdf(91页珍藏版)》请在taowenge.com淘文阁网|工程机械CAD图纸|机械工程制图|CAD装配图下载|SolidWorks_CaTia_CAD_UG_PROE_设计图分享下载上搜索。

1、数字图像处理第二版中文版冈萨雷斯习题答案Digital Image ProcessingSecond EditionProblem SolutionsStudent SetRafael C.GonzalezRichard E.WoodsPrentice HallUpper Saddle River,NJ history10 9 8 7 6 5 4 3 2 1Copyright c 1992-2002 by Rafael C.Gonzalez and Richard E.Woods1PrefaceThis abbreviated manual contains detailed solution

2、s to all problems marked with a starin Digital Image Processing,2nd Edition.These solutions can also bedownloaded fromthe book web site().2Solutions(Students)Problem 2.1The diameter,x,of the retinal image corresponding to the dot is obtained from similartriangles,as shown in Fig.P2.1.That is,(d=2)0:

3、2=(x=2)0:014which gives x=0:07d.From the discussion in Section 2.1.1,and taking some libertiesofinterpretation,wecanthinkofthefoveaasasquaresensorarrayhavingontheorderof337,000 elements,which translates into an array of size 580580 elements.Assumingequal spacing between elements,this gives 580 eleme

4、nts and 579 spaces on a line 1.5mm long.The size of each element and each space is then s=(1:5mm)=1;159=1:3106m.If the size(on the fovea)of the imaged dot is less than the size of a singleresolution element,we assume that the dot will be invisible to the eye.In other words,the eye will not detect a

5、dot if its diameter,d,is such that 0:07(d)1:3 106m,ord:0if D(u;v)D0+W2(b)Butterworth bandpass filter:HBbp(u;v)=1 11+hD(u;v)WD2(u;v)D20i2n=hD(u;v)WD2(u;v)D20i2n1+hD(u;v)WD2(u;v)D20i2n:26Chapter 5 Solutions(Students)(c)Gaussian bandpass filter:HGbp(u;v)=1 1 e12D2(u;v)D20D(u;v)W2#=e12D2(u;v)D20D(u;v)W2

6、:Problem 5.14We proceed as follows:F(u;v)=ZZ11f(x;y)ej2(ux+vy)dxdy=ZZ11Asin(u0 x+v0y)ej2(ux+vy)dxdy:Using the exponential definition of the sine function:sin=12jej ejgives usF(u;v)=jA2ZZ11hej(u0 x+v0y)ej(u0 x+v0y)iej2(ux+vy)dxdy=jA2ZZ11ej2(u0 x=2+v0y=2)ej2(ux+vy)dxdyjA2ZZ11ej2(u0 x=2+v0y=2)ej2(ux+vy

7、)dxdy:These are the Fourier transforms of the functions1 ej2(u0 x=2+v0y=2)and1 ej2(u0 x=2+v0y=2)respectively.The Fourier transform of the 1 gives an impulse at the origin,and theexponentials shift the origin of the impulse,as discussed in Section 4.6.1.Thus,F(u;v)=jA2hu u02;v v02u+u02;v+v02i:Problem

8、 5.16From Eq.(5.5-13),g(x;y)=ZZ11f(;)h(x ;y )dd:Problem 5.1827It is given that f(x;y)=(x a);so f(;)=(a):Then,using the impulseresponse given in the problem statement,g(x;y)=ZZ11(a)e(x)2+(y)2dd=ZZ11(a)e(x)2e(y)2dd=Z11(a)e(x)2dZ11e(y)2d=e(xa)2Z11e(y)2dwhere we used the fact that the integral of the im

9、pulse is nonzero only when =a:Next,we note thatZ11e(y)2d=Z11e(y)2dwhich is in the form of a constant times a Gaussian density with variance 2=1=2 orstandard deviation =1=p2.In other words,e(y)2=p2(1=2)1p2(1=2)e(1=2)(y)2(1=2)#:The integral from minus to plus infinity of the quantity inside the bracke

10、ts is 1,sog(x;y)=pe(xa)2which is a blurred version of the original image.Problem 5.18Following the procedure in Section 5.6.3,H(u;v)=ZT0ej2ux0(t)dt=ZT0ej2u(1=2)at2dt=ZT0ejuat2dt=ZT0cos(uat2)j sin(uat2)dt=rT22uaT2C(puaT)jS(puaT)whereC(x)=r2TZx0cost2dt28Chapter 5 Solutions(Students)andS(x)=r2Zx0sint2d

11、t:These are Fresnel cosine and sine integrals.They can be found,for example,the Hand-book of Mathematical Functions,by Abramowitz,or other similar reference.Problem 5.20Measure the average value of the background.Set all pixels in the image,except thecross hairs,to that gray level.Denote the Fourier

12、 transform of this image by G(u;v).Since the characteristics of the cross hairs are given with a high degree of accuracy,we can construct an image of the background(of the same size)using the backgroundgray levels determined previously.We then construct a model of the cross hairs in thecorrect locat

13、ion(determined from he given image)using the provided dimensions andgray level of the crosshairs.Denote by F(u;v)the Fourier transform of this new image.Theratio G(u;v)=F(u;v)is an estimate of the blurring function H(u;v).In thelikelyevent of vanishing values in F(u;v),we can construct a radially-li

14、mited filter using themethod discussed in connection with Fig.5.27.Becausewe know F(u;v)and G(u;v),and an estimate of H(u;v),we can also refine our estimate of the blurring functionby substituting G and H in Eq.(5.8-3)and adjusting K to get as close as possible to agoodresultfor F(u;v)theresultcan b

15、eevaluated visually bytaking theinverseFouriertransform.The resulting filter in either case can then be used to deblur the image of theheart,if desired.Problem 5.22This is a simple plugin problem.Its purpose is to gain familiarity with the various termsof the Wiener filter.From Eq.(5.8-3),HW(u;v)=1H

16、(u;v)jH(u;v)j2jH(u;v)j2+K#wherejH(u;v)j2=H(u;v)H(u;v)=22(u2+v2)2e422(x2+y2):Then,HW(u;v)=p2(u2+v2)e222(x2+y2)22(u2+v2)2e422(x2+y2)+K#:Problem 5.2529Problem 5.25(a)It is given thatF(u;v)2=jR(u;v)j2jG(u;v)j2:From Problem 5.24,F(u;v)2=jR(u;v)j2hjH(u;v)j2jF(u;v)j2+jN(u;v)j2i:ForcingF(u;v)2to equal jF(u;

17、v)j2givesR(u;v)=jF(u;v)j2jH(u;v)j2jF(u;v)j2+jN(u;v)j2#1=2:Problem 5.27The basic idea behind this problem is to use the camera and representative coins tomodel the degradation process and then utilize the results in an inverse filter operation.The principal steps are as follows:1.Select coins as clos

18、e as possible in size and content as the lost coins.Select a back-ground that approximates the texture and brightness of the photos of the lost coins.2.Set up the museum photographic camera in a geometry as close as possible to giveimages that resemble the images of the lost coins(this includes payi

19、ng attention toillumination).Obtain a few test photos.To simplify experimentation,obtain a TVcamera capable of giving images that resemble the test photos.This can be done byconnecting the camera to an image processing system and generating digital images,which will be used in the experiment.3.Obtai

20、n sets of images of each coin with different lens settings.The resulting imagesshould approximate the aspect angle,size(in relation to the area occupied by thebackground),and blur of the photos of the lost coins.4.The lens setting for each image in(3)is a model of the blurring process for thecorresp

21、onding image of a lost coin.For each such setting,remove the coin andbackground and replace them with a small,bright dot on a uniform background,or other mechanism to approximate an impulse of light.Digitize the impulse.ItsFourier transform is the transfer function of the blurring process.5.Digitize

22、 each(blurred)photo of a lost coin,and obtain its Fourier transform.At thispoint,we have H(u;v)and G(u;v)for each coin.6.Obtain an approximation to F(u;v)by using a Wiener filter.Equation(5.8-3)isparticularly attractive because it gives an additional degree of freedom(K)for ex-perimenting.30Chapter

23、5 Solutions(Students)7.Theinverse Fourier transformof each approximateF(u;v)gives the restored image.In general,several experimental passes of these basic steps with various differentsettings and parameters are required to obtain acceptable results in a problem suchas this.6Solutions(Students)Proble

24、m 6.2Denote by c the given color,and let its coordinates be denoted by(x0;y0).The distancebetween c and c1isd(c;c1)=h(x0 x1)2+(y0y1)2i1=2:Similarly the distance between c1and c2d(c1;c2)=h(x1x2)2+(y1 y2)2i1=2:The percentage p1of c1in c isp1=d(c1;c2)d(c;c1)d(c1;c2)100:The percentage p2of c2is simply p

25、2=100 p1.In the preceding equation we see,for example,that when c=c1,then d(c;c1)=0 and it follows that p1=100%and p2=0%.Similarly,when d(c;c1)=d(c1;c2);it follows that p1=0%andp2=100%.Values in between are easily seen to follow from these simple relations.Problem 6.4Use color filters sharply tuned

26、to the wavelengths of the colors of the three objects.Thus,with a specific filter in place,only the objects whose color corresponds to thatwavelength will produce a predominant response on the monochrome camera.A mo-torized filter wheel can be used to control filter position from a computer.If one o

27、f thecolors is white,then the response of the three filters will be approximately equal andhigh.If one of thecolors is black,the response of the three filters will be approximatelyequal and low.Problem 6.6For the image given,the maximum intensity and saturation requirement means that the32Chapter 6

28、Solutions(Students)RGB component values are 0 or 1.We can create the following table with 0 and 255representing black and white,respectively:Table P6.6ColorRGBMono RMono GMono BBlack000000Red10025500Yellow1102552550Green01002550Cyan0110255255Blue00100255Magenta1012550255White111255255255Gray0.50.50.

29、5128128128Thus,we get the monochrome displays shown in Fig.P6.6.Figure P6.6Problem 6.8(a)All pixel values in the Red image are 255.In the Green image,the first column isall 0s;the second column all 1s;and so on until the last column,which is composed ofall 255s.In the Blue image,the first row is all

30、 255s;the second row all 254s,and soon until the last row which is composed of all 0s.Problem 6.10Equation(6.2-1)reveals thateach componentof theCMYimage is afunction of asinglecomponent of the corresponding RGB imageC is a function of R,M of G,and Y ofB.For clarity,we will use a prime to denote the

31、 CMY components.From Eq.(6.5-6),Problem 6.1233we know thatsi=krifor i=1;2;3(for the R,G,and B components).And from Eq.(6.2-1),we knowthat the CMY components corresponding to the riand si(which we are denoting withprimes)areri=1 riandsi=1 si:Thus,ri=1 riandsi=1 si=1 kri=1 k(1 ri)so thatsi=kri+(1 k):P

32、roblem 6.12Using Eqs.(6.2-2)through(6.2-4),we get the results shown in Table P6.12.Table P6.12ColorRGBHSIMono HMono SMono IBlack000000Red100010.33025585Yellow1100.1710.6743255170Green0100.3310.338525585Cyan0110.510.67128255170Blue0010.6710.3317025585Magenta1010.8310.67213255170White111010255Gray0.50

33、.50.500.50128Note that,in accordance with Eq.(6.2-2),hue is undefined when R=G=B since=cos100.In addition,saturation is undefined when R=G=B=0 since Eq.(6.2-3)yields S=1 3 min(0)30=1 00.Thus,we get the monochrome display shownin Fig.P6.12.Problem 6.1435Problem 6.18Using Eq.(6.2-3),we see that the ba

34、sic problem is that many different colors have thesame saturation value.This was demonstrated in Problem 6.12,where pure red,yellow,green,cyan,blue,and magenta all had a saturation of 1.That is,as long as any one ofthe RGB components is 0,Eq.(6.2-3)yields a saturation of 1.Consider RGB colors(1,0,0)

35、and(0,0.59,0),which represent a red and a green.The HSI triplets for these colors per Eq.(6.4-2)through(6.4-4)are(0,1,0.33)and(0.33,1,0.2),respectively.Now,the complements of the beginning RGB values(seeSection 6.5.2)are(0,1,1)and(1,0.41,1),respectively;the corresponding colors arecyan and magenta.T

36、heir HSI values per Eqs.(6.4-2)through(6.4-4)are(0.5,1,0.66)and(0.83,0.48,0.8),respectively.Thus,for the red,a starting saturation of 1 yieldedthe cyan“complemented”saturation of 1,while for the green,a starting saturation of1 yielded the magenta“complemented”saturation of 0.48.That is,the same star

37、tingsaturation resulted in two different“complemented”saturations.Saturation alone is notenough information to compute the saturation of the complemented color.Problem 6.20The RGB transformations for a complement from Fig.6.33(b)are:si=1 riwhere i=1;2;3(for the R,G,and B components).But from the def

38、inition of theCMY space in Eq.(6.2-1),we know that the CMY components corresponding to riandsi,which we will denote using primes,areri=1 risi=1 siThus,ri=1 riandsi=1 si=1 (1 ri)=1 (1(1 ri)so thats=1 ri36Chapter 6 Solutions(Students)Problem 6.22Based on the discussion is Section 6.5.4 and with refere

39、nce to the color wheel in Fig.6.32,we can decrease the proportion of yellow by(1)decreasing yellow,(2)increasingblue,(3)increasing cyan and magenta,or(4)decreasing red and green.Problem 6.24The conceptually simplest approach is to transform every input image to the HSI colorspace,perform histogram s

40、pecification per the discussion in Section 3.3.2 on the inten-sity(I)component only(leaving H and S alone),and convert the resulting intensitycomponent with the original hue and saturation components back to the starting colorspace.Problem 6.27(a)The cube is composed of 6 intersecting planes in RGB

41、space.The general equationfor such planes isazR+bzG+czB+d=0where a,b,c,and d are parameters and the zs are the components of any point(vector)z in RGB space lying on the plane.If an RGB point z does not lie on the plane,andits coordinates are substituted in the preceding equation,then equation will

42、give either apositive or a negative value;it will not yield zero.We say that z lies on the positive ornegative side of the plane,depending on whether the result is positive or negative.Wecan change the positive side of a plane by multiplying its coefficients(except d)by 1.Suppose that we test the po

43、int a given in the problem statement to see whether it is onthe positive or negative side each of the six planes composing the box,and change thecoefficients of any plane for which the result is negative.Then,a will lie on the positiveside of all planes composing the bounding box.In fact all points

44、inside the boundingbox will yield positive values when their coordinates are substituted in the equations ofthe planes.Points outside the box will give at least one negative or zero value.Thus,the method consists of substituting an unknown color point in the equations of all sixplanes.If all the res

45、ults are positive,the point is inside the box;otherwise it is outsidethe box.A flow diagram is asked for in the problem statement to make it simpler toevaluate the students line of reasoning.7Solutions(Students)Problem 7.2A mean approximation pyramid is formed by forming 2 2 block averages.Since the

46、starting image is of size 4 4,J=2,and f(x;y)is placed in level 2 of the meanapproximation pyramid.The level 1 approximation is(by taking 2 2 block averagesover f(x;y)and subsampling):3:55:511:513:5#and the level 0 approximation is similarly 8.5.The completed mean approximationpyramid is2666641234567

47、89101112131415163777753:55:511:513:5#h8:5i:Since no interpolation filtering is specified,pixel replication is used in the generation ofthe mean prediction residual pyramid levels.Level 0 of the prediction residual pyramidis the lowest resolution approximation,8.5.The level 2 prediction residual is o

48、btainedby upsampling the level 1 approximation and subtracting it from the level 2(originalimage).Thus,we get266664123456789101112131415163777752666643:53:55:55:53:53:55:55:511:511:513:513:511:511:513:513:5377775=2666642:51:52:51:51:52:51:52:52:51:52:51:51:52:51:52:5:37777538Chapter 7 Solutions(Stud

49、ents)Similarly,the level 1 prediction residual is obtained by upsampling the level 0 approxi-mation and subtracting it from the level 1 approximation to yield3:55:511:513:5#8:58:58:58:5#=5335#:The mean prediction residual pyramid is therefore2666642:51:52:51:51:52:51:52:52:51:52:51:51:52:51:52:53777

50、755335#8:5:Problem 7.3The number of elements in a J+1 level pyramid is bounded by 4/3(see Section 7.1.1):22J1+1(4)1+1(4)2+1(4)J#4322Jfor J 0.We can generate the following table:Table P7.3JPyramid ElementsCompression Ratio011155=4=1:2522121=16=1:312538585=86=1:328.14=3=1:33All but the trivial case(J=

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 教育专区 > 高中资料

本站为文档C TO C交易模式,本站只提供存储空间、用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。本站仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知淘文阁网,我们立即给予删除!客服QQ:136780468 微信:18945177775 电话:18904686070

工信部备案号:黑ICP备15003705号© 2020-2023 www.taowenge.com 淘文阁