function filterspec=initgammatones(lf,hf,n,fs)
%INITGAMMATONES Returns a structure containing the initial
% conditions for a bank of gammatone filters.
%
%    filterspec=initgammatones(lf,hf,n,fs)
%
%  where lh,hf are low and high centre frequencies of the bank, in Hz
%        n is the number of filters
%        fs is the sampling frequency
%
%

cf=MakeErbCFs(lf,hf,n);
wcf=2*pi*cf;						% radian frequency
tpt=(2*pi)/fs;
bw=erb(cf)*bwcorrection;
a0=exp(-bw*tpt);
filterspec.ec = wcf/fs;
filterspec.p=zeros(4,n); 
filterspec.q=zeros(4,n);
filterspec.a = [4*a0; -6*(a0.^2); 4*(a0.^3); -(a0.^4)];
filterspec.a5 = 4*(a0.^2);
filterspec.gain = ((tpt*bw).^4)/3;
filterspec.tim = 0;
filterspec.cf = cf;

