# How to represent nonuniform resampling of signal using math functions?

I am working on optical coherence tomography algorithm. In main pipeline I should use nonuniform resampling to eliminate transformation of optical signal in IR-spectrometer (that signal disperses by prism\diffraction grating almost linearly in $$\lambda$$-space, but in order to use further FFT we need to have signal linear in $$k$$-space, $$k=2\pi/\lambda$$). After resampling I apply FFT to obtain the response in length domain. Fourier transform connects length domain and wavenumber domain. But after spectrometer we have signal in wavenumber domain and this is why we need to resample signal.

But now I need to estimate some parameters of our spectrometer such as central, minimum, maximum lambda and the lambda-step between two neighboring pixels of charge coupled device (CCD). This stage is called as calibration. We use reference optical signal from laser or special device producing light with well known simple frequensies and we need to match the output signal from CCD to the right reference scale. I want to try to use regression. For this reason I need to find whether nonuniform resampling can be represented as a combination of simple math functions in order to form smooth cost function for optimization problem.

If I am wrong what should I do instead?

EDIT:

The picture can show the process of signal obtaining. If we give an input signal like sine wave we need to obtaing a couple of peaks after FFT which are related to special phase-distanse $$x$$. But CCD can be put arbitrary in spectrometer and Idon't know accordance between pixels and wavelengths so I need to find out it.

I used this code in Matlab to resample the signal. But can I represent it using pure math functions?

function signal_in_k = resample(signal_in_lambda, lambda_min, lambda_max, N)
lambda_space = linspace(lambda_min, lambda_max, N);
k_space = 2*pi/lambda_space;

k_min = 2*pi/lambda_max;
k_max = 2*pi/lambda_min;
k_space_even = linspace(k_min, k_max, N);

f_interp = interp1d(k_space , signal_in_lambda);
signal_in_k = f_interp(k_space_even);
end

• Hi, I'm not familiar with the terminology of optical coherence tomography – so, I don't know what kind of resampling you do. Could you define what your "I use nonuniform resampling" is, exactly? Generally, sensible resamplers should approximate the time-continuous function that perfect reconstruction of both the input and output signal should yield – and assuming the usual requirements on sampled signals, these are smooth. In that sense, resampling is exactly the math formula you'd write down to define exactly the kind of resampling you do Commented Jun 23, 2023 at 6:53
• I promise, though, that very few people here know what properties of your CCD you are referring to. Signal processors here, not physicists :) Commented Jun 23, 2023 at 6:54
• Thank you for answering, @MarcusMüller. CCD is charge-coupled device placed into the spectrometer. In front of CCD there is a diffraction grating which disperses optical signal linearly in lambda (wavelength space). It is kind of optical fourier transformation. But with wrong space because for fourier transform we need to have dispersion linear in k-space (wavenumbers). So signal linear in k-space can be directly transformed in euclidean space using simple fourier transform. But after spectrometer we have signal linear in lambda-space (lambda=2*pi/k). Commented Jun 23, 2023 at 7:21
• Fine with that math, but what exactly is the nonuniform resampling there? That's a description of what goes in and out, and not of the algorithm, so I'm not sure your question is answerable without you telling us what kind of resampler you're employing there, or what the optimization goals of that resampler are! Got a link to a book/explanation/definion/library you're using? Commented Jun 23, 2023 at 7:25
• It means that if we have sine-like original optical signal, after spectrometer it becomes chirped-like signal. If we apply FFT we won't obtain only one peak related to original sine. To fix the situation we can resample signal before fft to correct in order to have only one peak after fft. This is quite simple opeartion. But I don't know how to represent resampling with continuous math functions. Commented Jun 23, 2023 at 7:26