Everything

logb / logbf / logbl


Extracts the exponent of d in internal floating-point representation, as a floating-point value.

[Format]

#include <math.h>

double logb(double d);

float logbf(float d);

long double logbl(long double d);

[Parameters]

d Value of which exponent is to be extracted

[Return values]

Normal: Signed exponent of d

Abnormal: Range error: Returns –HUGE_VAL, –HUGE_VALF, or –HUGE_VALL depending on the function.

[Remarks]

A range error may occur if d is 0.

d is always assumed to be normalized.