File Exchange

image thumbnail

Time-domain Sinc Interpolation (Resampling)

version 2.0.0.1 (20.9 KB) by Dr. Erol Kalkan, P.E.
Time-domain SINC resampling (interpolation) function with a simple example

27 Downloads

Updated 13 Nov 2020

View Version History

View License

A robust interpolation function using a SINC kernel to convolve the original input time series in order to get resampled time series. A simple example is provided in comment section to illustrate how resampleSINC works. See also resampleFDZP for frequency domain zero padding (FDZP) resampling.

Cite As

Dr. Erol Kalkan, P.E. (2021). Time-domain Sinc Interpolation (Resampling) (https://www.mathworks.com/matlabcentral/fileexchange/59027-time-domain-sinc-interpolation-resampling), MATLAB Central File Exchange. Retrieved .

Comments and Ratings (9)

Sukhjiwan Pannu

Dr. Erol Kalkan, P.E.

Thanks Jonas, I will add it.

Jonas Buron

The matlab function 'sinc', which you are using for this resampling function, requires the Signal processing toolbox or the Symbolic math toolbox. Please add that to the requirements.

Thanks
Jonas Buron

Thanks Adam for your note. Say y has a length of 200 and m is 4. Then, with your formulation, u becomes 797. However it should be 800. Also, when I apply your suggested change for u, it creates a shift in the resampled record.

Adam

I would recommend this for the first line to get a more intuitive final sampling:

u = linspace( 1, length(y), ( length(y) - 1 ) * m + 1);

This would mean with e.g. m = 4 you still get samples at the original points, in addition to multiples of 0.25.

Dr. Erol Kalkan, P.E.

I fixed the code to eliminate the delay. I have also included a demo file.

Tamir Friedrich

A note to the author:
The resampled signal accumulates a delay. Note that both signals starts at 0,0, and end up with a delay.
Could you explain the source of the delay? Can you think of a way to eliminate it?
Thanks, TF

Tamir Friedrich

Works well, great help. Thanks.
A note: the sampling rate dt does not impact performance. I assume that the provided signal is Nyquist sampled.

Ugur Koysuren

That's what I was looking for. Thank you, sir!

MATLAB Release Compatibility
Created with R2012b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!