MATLAB : Sampling

t=0:.0001:.05;
n=1:1:200;
x=5*sin(2*pi*fk*t);
fs=input('Enter sampling freq : ');
ts=1/fs;
subplot(3,1,1);
plot(t,x);
t=0:ts:.05;
y=5*sin(2*pi*100*t);
subplot(3,1,2);
stem(y);
subplot(3,1,3);
plot(t,y);

0 comments: