Translations of this page?:



    #include <cmath>
    double frexp( double num, int* exp );

The function frexp() is used to decompose num into two parts: a mantissa between 0.5 and 1 (returned by the function) and an exponent returned as exp. Scientific notation works like this:

     num = mantissa * (2 ^ exp)

C++ also provides the following overloaded forms:

    #include <cmath>
    float frexp( float num, int* exp ); // same as frexpf() in C99
    long double frexp( long double num, int* exp ); // same as frexpl() in C99

Related Topics: ldexp, modf

• • • IndexRecent changesRSScc