1LOG(3) Linux Programmer's Manual LOG(3)
2
3
4
6 log, logf, logl - natural logarithmic function
7
9 #include <math.h>
10
11 double log(double x);
12 float logf(float x);
13 long double logl(long double x);
14
15 Link with -lm.
16
18 The log() function returns the natural logarithm of x.
19
21 The log() function can return the following errors:
22
23 EDOM The argument x is negative.
24
25 ERANGE The argument x is zero. The log of zero is not defined (minus
26 infinity).
27
29 SVr4, 4.3BSD, C89. The float and long double variants are C99 require‐
30 ments.
31
33 cbrt(3), clog(3), log1p(3), sqrt(3)
34
35
36
37 2002-07-27 LOG(3)