# Inverse functions and differentiation

Rule:
${\displaystyle {\color }(x)={\frac {{\color {(f^{-1})'}}({\color }(x))}}}$

Example for arbitrary ${\displaystyle x_\approx 5.8}$:
${\displaystyle {\color }(x_)={\frac }}$
${\displaystyle {\color {(f^{-1})'}}({\color }(x_))=4~}$

In mathematics, the inverse of a function ${\displaystyle y=f(x)\!}$ is a function that, in some fashion, "undoes" the effect of ${\displaystyle f}$ (see inverse function for a formal and detailed definition). The inverse of ${\displaystyle f}$ is denoted as ${\displaystyle f^{-1}\!}$, where ${\displaystyle f^{-1}(y)=x\!}$ if and only if ${\displaystyle f(x)=y\!}$.

Their two derivatives, assuming they exist, are reciprocal, as the Leibniz notation suggests; that is:

${\displaystyle {\frac }\,\cdot \,{\frac }=1.}$

This relation is obtained by differentiating the equation ${\displaystyle f^{-1}(y)=x\!}$ in terms of x and applying the chain rule, yielding that:

${\displaystyle {\frac }\,\cdot \,{\frac }={\frac }}$

considering that the derivative of x with respect to x is 1.

Writing explicitly the dependence of y on x, and the point at which the differentiation takes place, the formula for the derivative of the inverse becomes (in Lagrange's notation):

${\displaystyle \left[f^{-1}\right]'(a)={\frac (a)\right)}}}$.

This formula holds in general whenever ${\displaystyle f}$ is continuous and injective on an interval I, with ${\displaystyle f}$ being differentiable at ${\displaystyle f^{-1}(a)}$(${\displaystyle \in I\!}$) and where${\displaystyle f'(f^{-1}(a))\neq 0\!}$.[1] The same formula is also equivalent to the expression

${\displaystyle {\mathcal }\left[f^{-1}\right]={\frac {({\mathcal }f)\circ \left(f^{-1}\right)}},}$

where ${\displaystyle {\mathcal }\!}$ denotes the unary derivative operator (on the space of functions) and ${\displaystyle \circ \!}$ denote the binary composition operator.

Geometrically, a function and inverse function have graphs that are reflections, in the line ${\displaystyle y=x\!}$. This reflection operation turns the gradient of any line into its reciprocal.[2]

Assuming that ${\displaystyle f}$ has an inverse in a neighbourhood of ${\displaystyle x}$ and that its derivative at that point is non-zero, its inverse is guaranteed to be differentiable at ${\displaystyle x}$ and have a derivative given by the above formula.

## Examples

• ${\displaystyle \,y=x^}$ (for positive x) has inverse ${\displaystyle x={\sqrt }\!}$ .
${\displaystyle {\frac }=2x{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }};{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }}{\frac }={\frac }}}={\frac }}$
${\displaystyle {\frac }\,\cdot \,{\frac }=2x\cdot {\frac }=1.}$

At ${\displaystyle x=0\!}$, however, there is a problem: the graph of the square root function becomes vertical, corresponding to a horizontal tangent for the square function.

• ${\displaystyle \,y=e^}$ (for real x) has inverse ${\displaystyle \,x=\ln }$ (for positive ${\displaystyle y}$)
${\displaystyle {\frac }=e^{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }};{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }}{\frac }={\frac }}$
${\displaystyle {\frac }\,\cdot \,{\frac }=e^\cdot {\frac }={\frac }}}=1}$

• Integrating this relationship gives
${\displaystyle }(x)=\int {\frac }(x))}}\,+C.}$
This is only useful if the integral exists. In particular we need ${\displaystyle f'(x)}$ to be non-zero across the range of integration.
It follows that a function that has a continuous derivative has an inverse in a neighbourhood of every point where the derivative is non-zero. This need not be true if the derivative is not continuous.

## Higher derivatives

The chain rule given above is obtained by differentiating the identity ${\displaystyle f^{-1}(f(x))=x\!}$ with respect to x. One can continue the same process for higher derivatives. Differentiating the identity twice with respect to x, one obtains

${\displaystyle {\frac y}}}\,\cdot \,{\frac }+{\frac }\left({\frac }\right)\,\cdot \,\left({\frac }\right)=0,}$

that is simplified further by the chain rule as

${\displaystyle {\frac y}}}\,\cdot \,{\frac }+{\frac x}}}\,\cdot \,\left({\frac }\right)^=0.}$

Replacing the first derivative, using the identity obtained earlier, we get

${\displaystyle {\frac y}}}=-{\frac x}}}\,\cdot \,\left({\frac }\right)^.}$

Similarly for the third derivative:

${\displaystyle {\frac y}}}=-{\frac x}}}\,\cdot \,\left({\frac }\right)^-3{\frac x}}}\,\cdot \,{\frac y}}}\,\cdot \,\left({\frac }\right)^}$

or using the formula for the second derivative,

${\displaystyle {\frac y}}}=-{\frac x}}}\,\cdot \,\left({\frac }\right)^+3\left({\frac x}}}\right)^\,\cdot \,\left({\frac }\right)^}$

These formulas are generalized by the Faà di Bruno's formula.

These formulas can also be written using Lagrange's notation. If f and g are inverses, then

${\displaystyle g''(x)={\frac {-f''(g(x))}{[f'(g(x))]^}}}$

## Example

• ${\displaystyle \,y=e^}$ has the inverse ${\displaystyle \,x=\ln y}$. Using the formula for the second derivative of the inverse function,
${\displaystyle {\frac }={\frac y}}}=e^=y{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }};{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }}\left({\frac }\right)^=y^;}$

so that

${\displaystyle {\frac x}}}\,\cdot \,y^+y=0{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }};{\mbox{ }}{\mbox{ }}{\mbox{ }}{\mbox{ }}{\frac x}}}=-{\frac }}}$,

which agrees with the direct calculation.