How can I find the interpolation error when I use INTERP in the Signal Processing Toolbox?

조회 수: 2 (최근 30일)
I was wondering if there was a way to calculate interpolation error when using INTERP in the Signal Processing Toolbox.

채택된 답변

MathWorks Support Team
MathWorks Support Team 2009년 6월 27일
One way to find the interpolation error given the following:
t = 0:0.001:1; % Time vector
x = sin(2*pi*30*t) + sin(2*pi*60*t);
r = 4;
y = interp(x,r);
is to use:
e = x - y(1:r:end);
"e" is the difference between the original data, "x", and the interpolated data, "y", at the original discrete times.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Interpolation에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by