% DWT
% This function computes the forward discrete wavelet transform of a given 
% given input vector f.  The vector f must be a column vector.

function F=dwt(c0,c1,f)

%fprintf('here\n')
%fprintf('N=%d\n',size(f,1))

N=size(f,1);

if N>2 
F=[dwt(c0,c1,Lfilt(c0,c1,N)*f);Hfilt(c0,c1,N)*f];

else
F=[Lfilt(c0,c1,N)*f;Hfilt(c0,c1,N)*f;F];
end
