function l = laplacian(u,g,m)
% This function accepts a function $u$ stored as a vector of length
% $3^(m+1)$ and a conformal factor $g$ of the same length, and computes
% the g-laplacian of u.
%
% size of u = 3^(m+1)
% size of g = 3^(m+1)

l = u ;

for k = 1:3^(m+1)
  l(k) = 3/2*5^m*ptlaplacian(u,g,k,m) ;
end