math.ldexp() function
The math.ldexp()
function is the inverse of math.frexp()
.
It returns frac × 2**exp
.
Output data type: Float
import "math"
math.ldexp(frac: 0.5, exp: 6)
// Returns 32.0
Parameters
frac
The fraction used in the operation.
exp
The exponent used in the operation.
Special cases
math.ldexp(frac: ±0, exp:exp) // Returns ±0
math.ldexp(frac: ±Inf, exp:exp) // Returns ±Inf
math.ldexp(frac: NaN, exp:exp) // Returns NaN
Was this page helpful?
Thank you for your feedback!
Support and feedback
Thank you for being part of our community! We welcome and encourage your feedback and bug reports for Flux and this documentation. To find support, use the following resources:
InfluxDB Cloud customers can contact InfluxData Support.