%%%%%%%%%%%%%%%%%%%%% Hyperbolic distance %%%%%%%%%%%%%%%%%%%%% % % HDIST % Usage: HDIST(x,y) % Inputs: x,y points inside or on the unit circle % % Outputs: the hyperbolic distance between x and y function h = hdist(x,y) b = abs((y-x)/(1-conj(x)*y)); h = log((1+b)/(1-b));