Everything

ilogb / ilogbf / ilogbl


Extracts the exponent of d.

[Format]

#include <math.h>

long ilogb(double d);

long ilogbf(float d);

long ilogbl(long double d);

[Parameters]

d Value of which exponent is to be extracted

[Return values]

Normal: Exponential function value of d

d is ∞: INT_MAX

d is not-a-number: FP_ILOGBNAN

d is 0: FP_ILOGBNAN

Abnormal: d is 0 and a range error has occurred: FP_ILOGB0

[Remarks]

A range error may occur if d is 0.