Вы находитесь на странице: 1из 1

f = 2000;

T = 1/f;
tmin= 0;
tmax= 10*T;
dt= T/100;
dt1 = 1/1800; %freceunciamenor al FNyquist
dt2 = 1/16000;% frecuencia menor a FNyquist
dt3= 1/2000;% frecuencia igual a FNyquist
t = tmin:dt:tmax;
t1 = tmin:dt1:tmax;
t2 = tmin:dt2:tmax;
t3= tmin:dt3:tmax;
x = sin(2*pi*f*t);
x1 = sin(2*pi*f*t1);
x2 = sin(2*pi*f*t2);
x3= sin(2*pi*f*t3)
subplot(311)
plot(t,x,'r');
hold on
stem(t1,x1);
hold on
plot(t1,x1,'g')
subplot(312)
plot(t,x,'r');
hold on
stem(t2,x2);
subplot(313)
plot(t,x,'r');
hold on
stem(t3,x3);

Вам также может понравиться