# Derivatives of Logarithmic Functions

Derivatives of Logarithmic Functions are mainly based on the Chain Rule. However we can generalize it for any differentiable function with Logarithmic function. The differentiation of log is only under the base \(e\) but we can differentiate under other bases too.

## Derivative of \(\ln {x}\)

\[\frac{d}{dx} \ln {x} = \frac{1}{x}\]

Now we will prove this from first principles.

From First principles \(\frac{d}{dx} f(x) = \displaystyle \lim_{h \rightarrow 0} {\dfrac{f(x+h)-f(x)}{h}}\).

Now let \(f(x) = \ln{x}\)

\[\begin{align} \dfrac{\text{d}}{\text{d}x}f(x) & = \lim_{h \rightarrow 0} {\dfrac{\ln(x+h) - \ln{x}}{h}} \\ & = \lim_{h \rightarrow 0} {\dfrac{\frac{x}{h}\ln(1 + \frac{h}{x})}{x} } \\ & = \lim_{h \rightarrow 0} {\dfrac{\ln{(1 + \frac{h}{x})^{\frac{x}{h}}}}{x}} \\ & = \lim_{h \rightarrow 0} {\dfrac{\ln{e}}{x}} \\ & = \dfrac{1}{x} \end{align}\]

Find the derivative of \(\ln {x}\) at \(x = 2\).

\[ \dfrac{\text{d}}{\text{d}x} \ln {x} = \dfrac{1}{x}\]

Hence

\[ \dfrac{\text{d}}{\text{d}x} \ln x \Bigg |_{x=2}= \dfrac{1}{2} ~~~_\square\]

Differentiate \(\ln 5x\)

Solution 1:Using the chain ruleLet \(f(x) = \ln x\) and \(g(x) = 5x\). Then we are asked to find \(( f \circ g ) '\).

Using chain rule we know that \(( f \circ g ) ' = ( f' \circ g) \times g' . \)

\(f' \circ g = \dfrac{1}{5x}\) and \(g'(x) = 5\).

Therefore, \(( f \circ g ) ' = \dfrac{1}{5x} \times 5 = \dfrac{1}{x}.\)

Solution 2Using properties of logarithms.We know the property of logarithms \(\log_a b + \log_a c = \log_a bc\).

Using this property,

\[ \ln 5x = \ln x + \ln 5\]

If we differentiate both sides, we see that

\[\dfrac{\text{d}}{\text{d}x} \ln 5x = \dfrac{\text{d}}{\text{d}x} \ln x\]

since differentiation of \(\ln 5\) which is a constant, is \( 0\)

We have seen that \(\dfrac{\text{d}}{\text{d}x} \ln x = \dfrac{1}{x}\), and this is the answer to this question. \(_\square\)

Generalization:For any positive real number \(p\), we can conclude \(\dfrac{\text{d}}{\text{d}x} \ln px = \dfrac{1}{x}\). Note that the derivative is independent of \(p\). This can be proven by writing \(p\) instead of \(5\) in the above solutions.

## Derivative of \(\log_{a}x\)

If \(a\) is a positive real number, and \(a \neq 1\), then \[\dfrac{\text{d}}{\text{d}x}\log_{a} {x} = \dfrac{1}{x \ln {a}}\]

We will use base changing formula to change the base of the logarithm to \(e\).

\[\log_{a}{x} = \dfrac{\ln{x}}{\ln{a}} \\ \dfrac{\text{d}}{\text{d}x}\log_{a}x = \dfrac{\text{d}}{\text{d}x} \dfrac{\ln{x}}{\ln{a}} \]

Since \(\dfrac{1}{\ln{a}}\) is a constant,

\[ \dfrac{\text{d}}{\text{d}x} \dfrac{\ln x}{\ln a} = \dfrac{1}{\ln a} \dfrac{\text{d}}{\text{d}x} \ln x = \dfrac{1}{x \ln{a}} ~~~~_\square\]

**For any other type of Log derivative we use the base changing formula**

## Derivative of \(\ln{f(x)}\)

Since this is a composite funciton, we can differentiate it using chain rule.

\[\dfrac{\text{d}}{\text{d}x}\ln(f(x)) = \dfrac{f'(x)}{f(x)} \]

Now we will start with \(g(x) = \ln (f(x))\)

To find its derivative we will substitute \(u = f(x)\).

\[\text{Now the derivative changes to } g(x) = \log{u} \\ So, \quad g'(x) = \frac{d}{dx}\log{u} = \frac{du}{dx} \times \frac{d}{du} \ln{u} \\ g'(x) = \dfrac{f'(x)}{f(x)}\]

Find the derivative of \(\ln(x^2 + 4)\).

Using theorem derivative of \(\ln(f(x))\) = \(\dfrac{f'(x)}{f(x)}\).

In this question \(f(x) = x^2 +4\) so \(f'(x) = 2x\).

Hence \(\dfrac{d}{dx}\log(x^2 + 4) = \dfrac{2x}{x^2 +4}\)

**Cite as:**Derivatives of Logarithmic Functions.

*Brilliant.org*. Retrieved from https://brilliant.org/wiki/derivative-of-logarithmic-functions/