Revision as of 22:35, 1 July 2009 by Mmohdasr (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

function y=convolution(x,h);

x=input('Please enter the input for x'); h=input('Please enter the input for h');

x1=length(x); h1=length(h);

X=[x,zeros(1,y1)] H=[y,zeros(1,x1)]

for n=1:x1+y1-1

y(n)=0;

for m=1:x1

if(n-m+1>0) y(n)=y(n)+X(m)*H(n-m+1);

else; end; end; end;

Alumni Liaison

Have a piece of advice for Purdue students? Share it through Rhea!

Alumni Liaison