% program file lab2009102901.m
clear all;
clf;
tf = 1;
dt = 0.01;
t =0:dt:1;
x1 = cos(2*pi*10*t);
x2 = cos(2*pi*35*t);
fs1 = 2*35;
xc = x1+x2;
ts1 = 1/fs1;
n1 = 0/ts1:1:tf/ts1;
x1_n = cos(2*pi*10*ts1)+cos(2*pi*35*n1*ts1);
subplot(411);
plot(t,x1,'r');
grid;
subplot(412);
plot(t,x2,'g');
grid;
subplot(413);
plot(t,xc,'g');
grid;
subplot(414);
stem(n1,x1_n,'b');
沒有留言:
張貼留言