HYPOT(S) XENIX System V HYPOT(S)
Name
hypot, cabs - Determines Euclidean distance.
Syntax
#include <math.h>
double hypot (x, y)
double x, y;
double cabs (z)
struct {double x, y;} z;
Description
hypot and cabs return:
sqrt(x*x + y*y)
Both take precautions against unwarranted overflows.
See Also
sqrt in exp(S), matherr(S)
Diagnostics
When the correct value reaches overflow, hypot returns a
HUGE value and sets errno to ERANGE.
These error-handling procedures may be changed with the
matherr(S) function.
Notes
These routines must be linked by using the -lm linker
option.
Page 1 (printed 8/7/87)