Introduction
Interpolation is adding samples between the existing vector values. By doing so sample rate of the signal or surely increase hence it is referred as up sampling UP the signal.
Most used approach way to insert approximate values of two samples for adding in between vector values. And most used techniques are nearest, linear,spline,cubic
Position Exponential vector to be UP sampled
clc;
clear all;
n=input('enter length of input sample sequence:');
l=input('enter the value of up-sampling factor:');
m=0:n-1;
a=input('enter the value of base of exponent function:');
x=a.^m;
Now UP Sampling
y=zeros(1,l*length(x));
y([1:l:length(y)])=x;
%figure,plot(x);
%figure,plot(y);
figure,stem(m,x);xlabel({'Time n';'(a)'});ylabel('Amplitude');title('Interpolation input');
figure,stem(m,y(1:length(x)));xlabel({'Time n';'(b)'});ylabel('Amplitude');title('upsampled output');
UP Sampling MATLAB Function ( Resample )
xi=x;
yi = resample(xi,l,1);
figure,stem(m,yi(1:length(x)));xlabel({'Time n';'(b)'});ylabel('Amplitude');title('upsampled output using matlab function');
Input
Output