summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2009-09-01 07:53:37 (GMT)
committerGeorg Brandl <georg@python.org>2009-09-01 07:53:37 (GMT)
commit018ad1c949d15152e00b714fa020a798ba16c574 (patch)
tree7637a5dcaba4d5334e4478d18eaf1a41ea424011
parenta88fd7603b35e5a7324f0eb9b49bd32feda4b2a7 (diff)
downloadcpython-018ad1c949d15152e00b714fa020a798ba16c574.zip
cpython-018ad1c949d15152e00b714fa020a798ba16c574.tar.gz
cpython-018ad1c949d15152e00b714fa020a798ba16c574.tar.bz2
#6765: hint that log(x, base) is not very sophisticated.
-rw-r--r--Doc/library/math.rst9
1 files changed, 6 insertions, 3 deletions
diff --git a/Doc/library/math.rst b/Doc/library/math.rst
index 4d566a5..96ea91a 100644
--- a/Doc/library/math.rst
+++ b/Doc/library/math.rst
@@ -166,8 +166,10 @@ Power and logarithmic functions
.. function:: log(x[, base])
- Return the logarithm of *x* to the given *base*. If the *base* is not specified,
- return the natural logarithm of *x* (that is, the logarithm to base *e*).
+ With one argument, return the natural logarithm of *x* (to base *e*).
+
+ With two arguments, return the logarithm of *x* to the given *base*,
+ calculated as ``log(x)/log(base)``.
.. versionchanged:: 2.3
*base* argument added.
@@ -183,7 +185,8 @@ Power and logarithmic functions
.. function:: log10(x)
- Return the base-10 logarithm of *x*.
+ Return the base-10 logarithm of *x*. This is usually more accurate
+ than ``log(x, 10)``.
.. function:: pow(x, y)