function y=glag_TV(x) % cut TV functional by min(1,1/x) [ny,nx]=size(x); x=x(:); y=ones(ny*nx,1); i=find(x>1); y(i)=1./x(i); y=reshape(y,ny,nx);