cnv - calculate the circulant convolution function between two images using multiplication in Fourier space.
output = cnv(image, ref, center=True)
- input image, can be either real or Fourier
- second input image, can be either real or Fourier.
- if set to True (default), the origin of the result is at the center; if set to False, the origin is at (0,0), the option is much faster, but the result is difficult to use
- circulant convolution function between image and ref. Real. The origin of the convolution function (term cnv(0,0,0)) is located at (int[n/2], int[n/2], int[n/2]) in 3D, (int[n/2], int[n/2]) in 2D, and at int[n/2] in 1D.
Calculation of the circulant convolution function between image f and reference image g is performed in Fourier space as `hat(f)hat(g)`
- In real space, this corresponds to:
`n = -(n_x)/2, ..., (n_x)/2`
Note: for image size nx and object size m, the circulant cnv is valid only within `+//- (n_x-m/2)` pixels from the origin. More distant cnv values are corrupted by the "wrap around" artifacts.
Pratt, W. K., 1992. Digital image processing. Wiley, New York.
Author / Maintainer
Pawel A. Penczek
- category 1
- category 2
- works for most people, has been tested; test cases/examples available.
None. It is perfect.