function f = gaussian2d(x,y,mu,Sigma)
  % Calculated the 2-dimmensional Gaussian density at many points.
  % x and y must be matrices of the same shape. The result is also of the
  % same shape, and holds the corresponding density values.
  [n,m] = size(x) ;
  f = multigaussian([reshape(x,n*m,1) reshape(y,n*m,1)],reshape(mu,1,2),Sigma);
  f = reshape(f,n,m);