otf2psf() - Image Processing
PSF = otf2psf(OTF) computes
the inverse Fast Fourier Transform (IFFT) of the optical transfer
function (OTF) array and creates a point-spread function (PSF), centered
at the origin. By default, the PSF is the same
size as the OTF.PSF = otf2psf(OTF, OUTSIZE) converts
the OTF array into a PSF array,
where OUTSIZE specifies the size of the output
point-spread function. The size of the output array must not exceed
the size of the OTF array in any dimension.To center the PSF at the origin, otf2psf circularly
shifts the values of the output array down (or to the right) until
the (1,1) element reaches the central position, then it crops the
result to match dimensions specified by OUTSIZE.Note that this function is used in image convolution/deconvolution
when the operations involve the FFT.
Syntax
PSF = otf2psf(OTF)PSF = otf2psf(OTF, OUTSIZE)
Example
PSF = fspecial('gaussian',13,1);
OTF = psf2otf(PSF,[31 31]); % PSF --> OTF
PSF2 = otf2psf(OTF,size(PSF)); % OTF --> PSF2
subplot(1,2,1); surf(abs(OTF)); title('|OTF|');
axis square; axis tight
subplot(1,2,2); surf(PSF2); title('Corresponding PSF');
axis square; axis tight
Output / Return Value
Limitations
Alternatives / See Also
Reference