# List of logarithmic identities

In mathematics, many logarithmic identities exist. The following is a compilation of the notable of these, many of which are used for computational purposes.

## Trivial identities

 ${\displaystyle \log _{b}(1)=0}$ because ${\displaystyle b^{0}=1}$, given that b doesn't equal 0 ${\displaystyle \log _{b}(b)=1}$ because ${\displaystyle b^{1}=b}$

## Cancelling exponentials

Logarithms and exponentials with the same base cancel each other. This is true because logarithms and exponentials are inverse operations—much like the same way multiplication and division are inverse operations, and addition and subtraction are inverse operations.

${\displaystyle b^{\log _{b}(x)}=x{\text{ because }}{\mbox{antilog}}_{b}(\log _{b}(x))=x}$
${\displaystyle \log _{b}(b^{x})=x{\text{ because }}\log _{b}({\mbox{antilog}}_{b}(x))=x}$[1][2]

Both of the above are derived from the following two equations that define a logarithm:

${\displaystyle b^{c}=x\iff \log _{b}(x)=c}$

Substituting c in the left equation gives blogb(x) = x, and substituting x in the right gives logb(bc) = c. Finally, replace c with x.

## Using simpler operations

Logarithms can be used to make calculations easier. For example, two numbers can be multiplied just by using a logarithm table and adding. These are often known as logarithmic properties, which are documented in the table below.[1][3] The first three operations below assume that x = bc and/or y = bd, so that logb(x) = c and logb(y) = d. Derivations also use the log definitions x = blogb(x) and x = logb(bx).

 ${\displaystyle \log _{b}(xy)=\log _{b}(x)+\log _{b}(y)}$ because ${\displaystyle b^{c}\cdot b^{d}=b^{c+d}}$ ${\displaystyle \log _{b}({\tfrac {x}{y}})=\log _{b}(x)-\log _{b}(y)}$ because ${\displaystyle {\tfrac {b^{c}}{b^{d}}}=b^{c-d}}$ ${\displaystyle \log _{b}(x^{d})=d\log _{b}(x)}$ because ${\displaystyle (b^{c})^{d}=b^{cd}}$ ${\displaystyle \log _{b}\left({\sqrt[{y}]{x}}\right)={\frac {\log _{b}(x)}{y}}}$ because ${\displaystyle {\sqrt[{y}]{x}}=x^{1/y}}$ ${\displaystyle x^{\log _{b}(y)}=y^{\log _{b}(x)}}$ because ${\displaystyle x^{\log _{b}(y)}=b^{\log _{b}(x)\log _{b}(y)}=(b^{\log _{b}(y)})^{\log _{b}(x)}=y^{\log _{b}(x)}}$ ${\displaystyle c\log _{b}(x)+d\log _{b}(y)=\log _{b}(x^{c}y^{d})}$ because ${\displaystyle \log _{b}(x^{c}y^{d})=\log _{b}(x^{c})+\log _{b}(y^{d})}$

Where ${\displaystyle b}$, ${\displaystyle x}$, and ${\displaystyle y}$ are positive real numbers and ${\displaystyle b\neq 1}$, and ${\displaystyle c}$ and ${\displaystyle d}$ are real numbers.

The laws result from canceling exponentials and the appropriate law of indices. Starting with the first law:

${\displaystyle xy=b^{\log _{b}(x)}b^{\log _{b}(y)}=b^{\log _{b}(x)+\log _{b}(y)}\Rightarrow \log _{b}(xy)=\log _{b}(b^{\log _{b}(x)+\log _{b}(y)})=\log _{b}(x)+\log _{b}(y)}$

The law for powers exploits another of the laws of indices:

${\displaystyle x^{y}=(b^{\log _{b}(x)})^{y}=b^{y\log _{b}(x)}\Rightarrow \log _{b}(x^{y})=y\log _{b}(x)}$

The law relating to quotients then follows:

${\displaystyle \log _{b}{\bigg (}{\frac {x}{y}}{\bigg )}=\log _{b}(xy^{-1})=\log _{b}(x)+\log _{b}(y^{-1})=\log _{b}(x)-\log _{b}(y)}$

${\displaystyle \log _{b}{\bigg (}{\frac {1}{y}}{\bigg )}=\log _{b}(y^{-1})=-\log _{b}(y)}$

Similarly, the root law is derived by rewriting the root as a reciprocal power:

${\displaystyle \log _{b}({\sqrt[{y}]{x}})=\log _{b}(x^{\frac {1}{y}})={\frac {1}{y}}\log _{b}(x)}$

## Changing the base

${\displaystyle \log _{b}a={\frac {\log _{10}(a)}{\log _{10}(b)}}}$

This identity is useful to evaluate logarithms on calculators. For instance, most calculators have buttons for ln and for log10, but not all calculators have buttons for the logarithm of an arbitrary base.

Consider the equation ${\displaystyle b^{c}=a}$
Take logarithm base ${\displaystyle d}$ of both sides: ${\displaystyle \log _{d}b^{c}=\log _{d}a}$
Simplify and solve for ${\displaystyle c}$: ${\displaystyle c\log _{d}b=\log _{d}a}$
${\displaystyle c={\frac {\log a}{\log b}}}$
Since ${\displaystyle c=\log _{b}a}$, then ${\displaystyle \log _{b}a={\frac {\log _{d}a}{\log _{d}b}}}$

This formula has several consequences:

${\displaystyle \log _{b}a={\frac {1}{\log _{a}b}}}$
${\displaystyle \log _{b^{n}}a={{\log _{b}a} \over n}}$
${\displaystyle b^{\log _{a}d}=d^{\log _{a}b}}$
${\displaystyle -\log _{b}a=\log _{b}\left({1 \over a}\right)=\log _{1 \over b}a}$

${\displaystyle \log _{b_{1}}a_{1}\,\cdots \,\log _{b_{n}}a_{n}=\log _{b_{\pi (1)}}a_{1}\,\cdots \,\log _{b_{\pi (n)}}a_{n},}$

where ${\displaystyle \scriptstyle \pi }$ is any permutation of the subscripts 1, ..., n. For example

${\displaystyle \log _{b}w\cdot \log _{a}x\cdot \log _{d}c\cdot \log _{d}z=\log _{d}w\cdot \log _{b}x\cdot \log _{a}c\cdot \log _{d}z.}$

### Summation/subtraction

The following summation/subtraction rule is especially useful in probability theory when one is dealing with a sum of log-probabilities:

${\displaystyle \log _{b}(a+c)=\log _{b}a+\log _{b}\left(1+{\frac {c}{a}}\right)}$
${\displaystyle \log _{b}(a-c)=\log _{b}a+\log _{b}\left(1-{\frac {c}{a}}\right)}$

Note that the subtraction identity is not defined if ${\displaystyle a=c}$, since the logarithm of zero is not defined. Also note that, when programming, ${\displaystyle a}$ and ${\displaystyle c}$ may have to be switched on the right hand side of the equations if ${\displaystyle c>>a}$ to avoid losing the "1 +" due to rounding errors. Many programming languages have a specific log1p(x) function that calculates ${\displaystyle \log _{e}(1+x)}$ without underflow (when ${\displaystyle x}$ is small).

More generally:

${\displaystyle \log _{b}\sum \limits _{i=0}^{N}a_{i}=\log _{b}a_{0}+\log _{b}\left(1+\sum \limits _{i=1}^{N}{\frac {a_{i}}{a_{0}}}\right)=\log _{b}a_{0}+\log _{b}\left(1+\sum \limits _{i=1}^{N}b^{\left(\log _{b}a_{i}-\log _{b}a_{0}\right)}\right)}$

### Exponents

A useful identity involving exponents:

${\displaystyle x^{\frac {\log(\log(x))}{\log(x)}}=\log(x)}$

or more universally:

${\displaystyle x^{\frac {\log(a)}{\log(x)}}=a}$

### Other/Resulting Identities

${\displaystyle {\frac {1}{{\frac {1}{\log _{x}(a)}}+{\frac {1}{\log _{y}(a)}}}}=\log _{xy}(a)}$
${\displaystyle {\frac {1}{{\frac {1}{\log _{x}(a)}}-{\frac {1}{\log _{y}(a)}}}}=\log _{\frac {x}{y}}(a)}$

## Inequalities

Based on [4] , [5] and [6]

${\displaystyle {\frac {x}{1+x}}\leq \ln(1+x)\leq {\frac {x(6+x)}{6+4x}}\leq x{\mbox{ for all }}-1
{\displaystyle {\begin{aligned}{\frac {2x}{2+x}}&\leq 3-{\sqrt {\frac {27}{3+2x}}}\leq {\frac {x}{\sqrt {1+x+x^{2}/12}}}\\&\leq \ln(1+x)\leq {\frac {x}{\sqrt {1+x}}}\leq {\frac {x}{2}}{\frac {2+x}{1+x}}\\&{\mbox{ for }}0\leq x{\mbox{, reverse for }}-1

All are accurate around ${\displaystyle x=0}$, but not for large numbers.

## Calculus identities

### Limits

${\displaystyle \lim _{x\to 0^{+}}\log _{a}(x)=-\infty \quad {\mbox{if }}a>1}$
${\displaystyle \lim _{x\to 0^{+}}\log _{a}(x)=\infty \quad {\mbox{if }}0
${\displaystyle \lim _{x\to \infty }\log _{a}(x)=\infty \quad {\mbox{if }}a>1}$
${\displaystyle \lim _{x\to \infty }\log _{a}(x)=-\infty \quad {\mbox{if }}0
${\displaystyle \lim _{x\to 0^{+}}x^{b}\log _{a}(x)=0\quad {\mbox{if }}b>0}$
${\displaystyle \lim _{x\to \infty }{\frac {\log _{a}(x)}{x^{b}}}=0\quad {\mbox{if }}b>0}$

The last limit is often summarized as "logarithms grow more slowly than any power or root of x".

### Derivatives of logarithmic functions

${\displaystyle {d \over dx}\ln x={1 \over x},}$
${\displaystyle {d \over dx}\log _{b}x={1 \over x\ln b},}$

Where ${\displaystyle x>0}$, ${\displaystyle b>0}$, and ${\displaystyle b\neq 1}$.

### Integral definition

${\displaystyle \ln x=\int _{1}^{x}{\frac {1}{t}}dt}$

### Integrals of logarithmic functions

${\displaystyle \int \log _{a}x\,dx=x(\log _{a}x-\log _{a}e)+C}$

To remember higher integrals, it is convenient to define

${\displaystyle x^{\left[n\right]}=x^{n}(\log(x)-H_{n})}$

where ${\displaystyle H_{n}}$ is the nth harmonic number:

${\displaystyle x^{\left[0\right]}=\log x}$
${\displaystyle x^{\left[1\right]}=x\log(x)-x}$
${\displaystyle x^{\left[2\right]}=x^{2}\log(x)-{\begin{matrix}{\frac {3}{2}}\end{matrix}}x^{2}}$
${\displaystyle x^{\left[3\right]}=x^{3}\log(x)-{\begin{matrix}{\frac {11}{6}}\end{matrix}}x^{3}}$

Then

${\displaystyle {\frac {d}{dx}}\,x^{\left[n\right]}=nx^{\left[n-1\right]}}$
${\displaystyle \int x^{\left[n\right]}\,dx={\frac {x^{\left[n+1\right]}}{n+1}}+C}$

## Approximating large numbers

The identities of logarithms can be used to approximate large numbers. Note that logb(a) + logb(c) = logb(ac), where a, b, and c are arbitrary constants. Suppose that one wants to approximate the 44th Mersenne prime, 232,582,657 −1. To get the base-10 logarithm, we would multiply 32,582,657 by log10(2), getting 9,808,357.09543 = 9,808,357 + 0.09543. We can then get 109,808,357 × 100.09543 ≈ 1.25 × 109,808,357.

Similarly, factorials can be approximated by summing the logarithms of the terms.

## Complex logarithm identities

The complex logarithm is the complex number analogue of the logarithm function. No single valued function on the complex plane can satisfy the normal rules for logarithms. However, a multivalued function can be defined which satisfies most of the identities. It is usual to consider this as a function defined on a Riemann surface. A single valued version, called the principal value of the logarithm, can be defined which is discontinuous on the negative x axis, and is equal to the multivalued version on a single branch cut.

### Definitions

In what follows, a capital first letter is used for the principal value of functions, and the lower case version is used for the multivalued function. The single valued version of definitions and identities is always given first, followed by a separate section for the multiple valued versions.

ln(r) is the standard natural logarithm of the real number r.
Arg(z) is the principal value of the arg function; its value is restricted to (-π, π]. It can be computed using Arg(x+iy)= atan2(y, x).
Log(z) is the principal value of the complex logarithm function and has imaginary part in the range (-π, π].
${\displaystyle \operatorname {Log} (z)=\ln(|z|)+i\operatorname {Arg} (z)}$
${\displaystyle e^{\operatorname {Log} (z)}=z}$

The multiple valued version of log(z) is a set, but it is easier to write it without braces and using it in formulas follows obvious rules.

log(z) is the set of complex numbers v which satisfy ev = z
arg(z) is the set of possible values of the arg function applied to z.

When k is any integer:

${\displaystyle \log(z)=\ln(|z|)+i\arg(z)}$
${\displaystyle \log(z)=\operatorname {Log} (z)+2\pi ik}$
${\displaystyle e^{\log(z)}=z}$

### Constants

Principal value forms:

${\displaystyle \operatorname {Log} (1)=0}$
${\displaystyle \operatorname {Log} (e)=1}$

Multiple value forms, for any k an integer:

${\displaystyle \log(1)=0+2\pi ik}$
${\displaystyle \log(e)=1+2\pi ik}$

### Summation

Principal value forms:

${\displaystyle \operatorname {Log} (z_{1})+\operatorname {Log} (z_{2})=\operatorname {Log} (z_{1}z_{2}){\pmod {2\pi i}}}$
${\displaystyle \operatorname {Log} (z_{1})-\operatorname {Log} (z_{2})=\operatorname {Log} (z_{1}/z_{2}){\pmod {2\pi i}}}$

Multiple value forms:

${\displaystyle \log(z_{1})+\log(z_{2})=\log(z_{1}z_{2})}$
${\displaystyle \log(z_{1})-\log(z_{2})=\log(z_{1}/z_{2})}$

### Powers

A complex power of a complex number can have many possible values.

Principal value form:

${\displaystyle {z_{1}}^{z_{2}}=e^{z_{2}\operatorname {Log} (z_{1})}}$
${\displaystyle \operatorname {Log} {\left({z_{1}}^{z_{2}}\right)}=z_{2}\operatorname {Log} (z_{1}){\pmod {2\pi i}}}$

Multiple value forms:

${\displaystyle {z_{1}}^{z_{2}}=e^{z_{2}\log(z_{1})}}$

Where k1, k2 are any integers:

${\displaystyle \log {\left({z_{1}}^{z_{2}}\right)}=z_{2}\log(z_{1})+2\pi ik_{2}}$
${\displaystyle \log {\left({z_{1}}^{z_{2}}\right)}=z_{2}\operatorname {Log} (z_{1})+z_{2}2\pi ik_{1}+2\pi ik_{2}}$