Documentation

math.hypot() function

The math.hypot() function returns the square root of p*p + q*q, taking care to avoid overflow and underflow.

Output data type: Float

import "math"

math.hypot(p: 2.0, q: 5.0)

// Returns 5.385164807134505

Parameters

p

The p value used in the operation.

Data type: Float

q

The q value used in the operation.

Data type: Float

Special cases

math.hypot(p: ±Inf, q:q) // Returns +Inf
math.hypot(p:p, q: ±Inf) // Returns +Inf
math.hypot(p: NaN, q:q)  // Returns NaN
math.hypot(p:p, q: NaN)  // Returns NaN

New! Cloud or OSS?

InfluxDB OSS 2.0 now generally available!

InfluxDB OSS 2.0 is now generally available and ready for production use. See the InfluxDB OSS 2.0 release notes.

For information about upgrading to InfluxDB OSS 2.0, see: