|
NAMElog , logf ,
logl , log10 ,
log10f , log10l ,
log2 , log2f ,
log2l , log1p ,
log1pf , log1pl —
logarithm functions
LIBRARYMath Library (libm, -lm)SYNOPSIS#include <math.h>
double
float
long double
double
float
long double
double
float
long double
double
float
long double
DESCRIPTIONThelog (), logf (), and
logl () functions compute the natural logarithm of
x.
The The RETURN VALUESThese functions return the requested logarithm; the logarithm of 1 is +0. An attempt to take the logarithm of ±0 results in a divide-by-zero exception, and -infinity is returned. Otherwise, attempting to take the logarithm of a negative number results in an invalid exception and a return value of NaN.SEE ALSOexp(3), ilogb(3), math(3), pow(3)STANDARDSThelog (), logf (),
logl (), log10 (),
log10f (), log10l (),
log2 (), log2f (),
log2l (), log1p (),
log1pf (), and log1pl ()
functions conform to ISO/IEC 9899:1999
(“ISO C99”).
HISTORYThelog () function first appeared in
Version 1 AT&T UNIX;
log10 () in Version 7 AT&T
UNIX; log1p () in
4.3BSD.
Visit the GSP FreeBSD Man Page Interface. |