Anda di halaman 1dari 4

%Sample sinyal input diskrit

n1=[0 : 2];

x1=[1 2 3];

figure(1);

subplot(3, 1, 1);

stem(n1,x1);

xlabel('n1');

ylabel('x1');

title('sinyal pertama');

n1=[0 : 2];

v1=[2 1 3];

subplot(3, 1, 2);

stem(n1,v1);

xlabel('n1');

ylabel('v1');

title('sinyal kedua');

%Step pertama, proses pembalikan sinyal kedua

n1=[-2 : 0];

v1=[3 1 2];

subplot(3, 1, 3);

stem(n1,v1);

xlabel('n1');

ylabel('v1');
title('sinyal kedua yang telah melalui proses pembalikan');

%Step kedua, proses konvolusi

n1=[-2 : 2];

hk=[0 0 2 0 0];

figure(2);

subplot(3, 1, 1);

stem(n1,hk);

xlabel('n1');

ylabel('hk');

title('sinyal pergeseran pertama');

%Step ketiga, proses konvolusi

n1=[-1 : 2];

hk=[0 1 4 0 ];

figure(2);

subplot(3, 1, 2);

stem(n1,hk);

xlabel('n1');

ylabel('hk');

title('sinyal pergeseran kedua');


%Step ketiga, proses konvolusi

n1=[0 : 2];

hk=[3 2 6 ];

figure(2);

subplot(3, 1, 3);

stem(n1,hk);

xlabel('n1');

ylabel('hk');

title('sinyal pergeseran ketiga');

%Step keempat, proses konvolusi

n1=[0 : 3];

hk=[0 6 3 0 ];

figure(3);

subplot(3, 1, 1);

stem(n1,hk);

xlabel('n1');

ylabel('hk');

title('sinyal pergeseran keempat');

%Step kelima proses konvolusi

n1=[0 : 4];

hk=[0 0 9 0 0 ];

figure(3);

subplot(3, 1, 2);
stem(n1,hk);

xlabel('n1');

ylabel('hk');

title('sinyal pergeseran kelima');

%Step keenam, proses konvolusi

n1=[0 : 5];

hk=[0 0 0 0 0 0 ];

figure(3);

subplot(3, 1, 3);

stem(n1,hk);

xlabel('n1');

ylabel('hk');

title('sinyal pergeseran keenam');

Anda mungkin juga menyukai