function [ out ] = PhaseMat(input)
    dum = reshape(input,length(input(:)),1);
    out = phase(dum);
    out = reshape(out,size(input,1),size(input,2));

end

