Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ cabs(3m) — Ultrix/UWS 4.2 VAX

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

exp(3m)

hypot(3m)  —  VAX

Name

hypot, cabs − Euclidean distance

Syntax

#include <math.h>

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

double cabs(z)
struct {double x,y;} z;

Description

The hypot and cabs functions return

sqrt(x*x + y*y),

taking precautions against unwarranted overflows. 

Return Values

The hypot and cabs functions return HUGE_VAL and sets errno to ERANGE when the correct value would overflow. 

Environment

When your program is compiled using the System V environment, if the correct value would overflow, hypot returns HUGE and sets errno to ERANGE. 

These error-handling procedures may be changed with the function matherr(.).

The cabs subroutine does not exist in the System V environment. For sqrt, see exp(.).

See Also

exp(3m)

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