x =

To restore the image, it needs to be deblurred in either spatial or frequency domain. While it is hard to deconvolve the image in spatial domain, it is relatively easy to do so in frequency domain, by dividing the spectrum of the blurred image by H(u,v), the spectrum of the blurring function. The only problem is that H(u,v) is a sinc function with periodic zero values. The information corresponding to such frequencies is lost during the blurring process (caused by multiplication by zero). The following is the restored image obtained by:

- clean up isolated noise (if any) by median filter (left image below).
- obtain spectra G(u,v) and H(u,v), the Fourier transform of image g(x,y) and h(x,y) respectively.
- deblur image: if |H(u,v)|>0 then F(u,v)=G(u,v)/H(u,v), else F(u,v)=0 (info is lost)
- obtain restored image f(x,y) by inverse Fourier transform of F(u,v) (middle image below).
- clean up vertical lines in the image (caused by H(u,v)=0) by median filter.
- stretch the image to the full gray level scale (right image below).