


HYPOT(3M)             MATHEMATICAL LIBRARY              HYPOT(3M)



NAME
     hypot - Euclidean distance

SYNOPSIS
     #include <math.h>

     double hypot(x, y)
     double x, y;

DESCRIPTION
     hypot() returns

          sqrt(x*x + y*y) ,

     taking precautions against unwarranted IEEE exceptions.   On
     IEEE   overflow,   hypot()  may  also  set  errno  and  call
     matherr(3M).  hypot(+-oo, y) is +oo for any y, even  a  NaN,
     and is exceptional only for a signaling NaN.

     hypot(_x,_y) and atan2(_y,_x) (see trig(3M)) convert rectangular
     coordinates  (_x,_y)  to polar (_r,_t_h); hypot() computes _r, the
     modulus or radius.

SEE ALSO
     trig(3M), matherr(3M)






























Sun Release 4.1   Last change: 22 November 1987                 1



