function pinco=pulse(x,icase)
if icase==1
  pinco=sin(2*pi*x);
elseif icase==2
  a=.2; b=.1;
  for i=1:length(x)
    if abs(x(i)-b)<a
      pinco(i)=exp(-(x(i)-b)^2/((x(i)-b)^2-a^2)^2);
    else
      pinco(i)=0;
    end
  end
end
