%
% mexican hat wavelet
%
function x = mexhat( xvec, dil, trans )
%
xsq = ( ( xvec - trans ) / dil ) .^ 2;
const = 2 * pi ^ (-1/4) / sqrt( 3 * dil );
x = const * ( 1 - xsq ) .* exp( - xsq / 2 );
%
