##### cppreference.com

##### Search

Create account

##### Namespaces

- Page
- Discussion

##### Variants

##### Views

- View
- Edit
- History

##### Actions

# ldexp

From cppreference.com
< c‎ | numeric‎ | math

Defined in header `<math.h>` |  |
float ldexpf( float arg, int exp ); |  | (since C99)
double ldexp( double arg, int exp ); |  |
long double ldexpl( long double arg, int exp ); |  | (since C99)

Multiplies an floating point value `arg` by 2 raised to power `exp`.

### [edit] Parameters

arg | - | floating point value
exp | - | integer value

### [edit] Return value

Returns `arg×2exp`

If the result is too large for the underlying type, range error occurs and HUGE_VAL is returned.

### [edit] See also

frexp | decomposes a number into significand and a power of 2 (function) [edit]
scalbn scalbln (C99)(C99) | multiplies a number by FLT_RADIX raised to a power (function) [edit]
C++ documentation for ldexp

Retrieved from "http://en.cppreference.com/mwiki/index.php?title=c/numeric/math/ldexp&oldid=66450"