%
%  convolution problems for homework 3
%
  t1 = [-2:0.01:10];
  t2 = [-5:0.01:5];
%
  x1 = exp(-0.5*t1).*unit_step(t1,0);
  x2 = 2*unit_triangle(t2,-1,3);
%  
  [y,ty] = convolve(t1,x1,t2,x2);
%  
  figure;
  orient tall
  subplot(3,1,1); plot(t1,x1); grid; ylabel('x_1(t)'); title('Problem 8b');
  subplot(3,1,2); plot(t2,x2); grid; ylabel('x_2(t)'); 
  subplot(3,1,3); plot(ty,y);grid; xlabel('Time (sec)'); ylabel('y(t)');
