Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ hypot(3M) — UnixWare 2.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

cc(1)

matherr(3M)






       hypot(3M)                                                  hypot(3M)


       NAME
             hypot - Euclidean distance function

       SYNOPSIS
             cc [flag ...] file ...  -lm [library ...]
             #include <math.h>
             double hypot(double x, double y);

       DESCRIPTION
             hypot returns

                   sqrt(x * x + y * y)

             taking precautions against unwarranted overflows.

          Errors
             When the correct value would overflow, hypot returns a value
             that will compare equal to +HUGE_VAL and sets errno to ERANGE.

             On systems that support IEEE NaN, if either argument is a
             quiet NaN, that value is returned.  If either argument is a
             signaling NaN, a quiet NaN is returned and the invalid
             operation exception is raised.  In either case, errno is set
             to EDOM.  The only exception is that if one argument is a NaN
             and the other argument is _oo, +oo is returned with no error
             indication.

             If the program was compiled with the -Xt compilation mode, a
             value that will compare equal to HUGE is returned instead of
             HUGE_VAL.  These error handling procedures may be changed with
             the function matherr.

       REFERENCES
             cc(1), matherr(3M)














                           Copyright 1994 Novell, Inc.               Page 1








Typewritten Software • bear@typewritten.org • Edmonds, WA 98026