- #1
mgma
- 1
- 0
Hello,
and
I need to simulate a camera given it's Modulation Transfer Function (MTF), which is a polynomial f(x). The expression for the MTF is:
y = 2E-08x4 + 0.0008x2 - 0.464x + 1.0076
(with x the spatial frequency in number of cycles/mm).
In order to simulate the effect of the lens in each image, I have to apply the following algorithm:
I don't understand how I should obtain the frequency image corresponding to the MTF. I think I should calculate a matrix with horizontal and vertical frequencies:
MTFi,j = h(fx,fy)
However, the polynomial expression that I have for the MTF is a function of only one variable, the spatial frequency x.
f(x) = 2E-08x4 + 0.0008x2 - 0.464x + 1.0076
How should I build the elements MTFi,j of the two-dimensional MTF matrix from this MTF function f(x)?
I think I should have two spatial frequencies fx and fy to calculate the MTF frequency image, but the MTF is given as function of a single spatial frequency by camera manufacturers.
Thanks in advance,
Miguel
Homework Statement
and
Homework Equations
I need to simulate a camera given it's Modulation Transfer Function (MTF), which is a polynomial f(x). The expression for the MTF is:
y = 2E-08x4 + 0.0008x2 - 0.464x + 1.0076
(with x the spatial frequency in number of cycles/mm).
In order to simulate the effect of the lens in each image, I have to apply the following algorithm:
- Compute the 2D Fast Fourier Transform (FFT) of the input image
- Compute the frequency image corresponding to the MTF (I think this should be done only once, at the beginning)
- Multiply the two frequency images obtained (Complex FFT * MTF)
- Inverse the image obtained (with inverse FFT) to compute the final image
The Attempt at a Solution
I don't understand how I should obtain the frequency image corresponding to the MTF. I think I should calculate a matrix with horizontal and vertical frequencies:
MTFi,j = h(fx,fy)
However, the polynomial expression that I have for the MTF is a function of only one variable, the spatial frequency x.
f(x) = 2E-08x4 + 0.0008x2 - 0.464x + 1.0076
How should I build the elements MTFi,j of the two-dimensional MTF matrix from this MTF function f(x)?
I think I should have two spatial frequencies fx and fy to calculate the MTF frequency image, but the MTF is given as function of a single spatial frequency by camera manufacturers.
Thanks in advance,
Miguel