LDEXP(3) NetBSD Library Functions Manual LDEXP(3)NAME

ldexp,ldexpf,ldexpl-- multiply floating-point number by integral power of 2LIBRARY

Math Library (libm, -lm)SYNOPSIS

#include <math.h>doubleldexp(double x,int exp);floatldexpf(float x,int exp);long doubleldexpl(long double x,int exp);DESCRIPTION

Theldexp() family of functions computex* 2^expfor a real floating-point numberx.RETURN VALUES

The functions return the value ofxtimes 2 raised to the powerexp. Otherwise the following may occur: 1. IfxisNaN, aNaNis returned. 2. Ifexpis zero orxis either ħ 0 or ħoo,xis returned. 3. If the call would cause an overflow, a range error occurs and either ħHUGE_VAL, ħHUGE_VALF, or ħHUGE_VALL is returned, depending on the sign ofxand the type of the return value. 4. If an underflow would be caused by the correct value, and the value is not representable, either 0.0 or an implementation- defined value is returned.SEE ALSO

frexp(3), math(3), modf(3)STANDARDS

The described functions conform to ISO/IEC 9899:1999 (``ISO C99''). NetBSD 9.1 March 17, 2016 NetBSD 9.1

Powered by man-cgi (2024-08-26). Maintained for NetBSD by Kimmo Suominen. Based on man-cgi by Panagiotis Christias.