What is the inverse function of $f(x) = x^5 + 2x^3 + x - 1?$ I have no idea how to find the inverse of a polynomial, so I would greatly appreciate it if someone could show me the steps to solving this problem. Thank you in advance!

  • 2
    $\begingroup$ Even Mathematica can't find inverse function, but you can be confident - inverse function does exist $\endgroup$
    – Norbert
    Commented Oct 10, 2012 at 21:42
  • 11
    $\begingroup$ Your polynomial is increasing, and its range is all reals, so there is an inverse. Finding a pleasant expression for the inverse is another matter. But one can find information about the derivative of the inverse without knowing a formula. $\endgroup$ Commented Oct 10, 2012 at 22:05
  • $\begingroup$ I think, it's very hard. Is it homework? Or where is this problem from? $\endgroup$
    – Berci
    Commented Oct 10, 2012 at 22:21
  • $\begingroup$ This question has been asked before, albeit in greater detail. Most likely we're having trouble answering it because we're missing this information: math.stackexchange.com/questions/85226/… $\endgroup$ Commented Dec 15, 2012 at 3:42
  • $\begingroup$ @Gyu Eun Lee That has the same equation, so maybe is why Jaden M. asked this question, but the question you linked looks like a homework problem that asks for the inverse of particular numbers and the derivative of the inverse at a particular number, but specifically avoids the much harder problem of finding an explicit formula for the inverse, which is what this question asks. $\endgroup$
    – Mr. Nichan
    Commented Mar 3 at 18:26

5 Answers 5


This is an experimental way of working out the inverse.

We can treat the polynomial like an expansion \begin{equation} f(x) = -1 + x + 0x^2 + 2x^3 + 0x^4 + x^5 + 0x^6 + 0x^7 + \cdots \end{equation} then we can perform a Series Reversion on this to give the inverse series (as an infinite expansion) \begin{equation} f^{-1}(x) = (1+x) -2(1+x)^3 +11(1+x)^5-80(1+x)^7+665(1+x)^9-\cdots \end{equation} at a glance this doesn't seem to helpful, but if we search the coefficients in the OEIS we seem to get a hit! It would appear (conjecture) that the general coefficient is then \begin{equation} a(n) = \binom{5n+1}{n}\frac{(-1)^n}{2n+1} \end{equation} and we could write that \begin{equation} f^{-1}(x) = \sum_{n=0}^\infty \binom{5n+1}{n}\frac{(-1)^n}{2n+1}(x+1)^{2n+1} \end{equation} if we evaluate that in Mathematica, it gives \begin{equation} f^{-1}(x)=(1+x)\;_4F_3\left(\frac{2}{5},\frac{3}{5},\frac{4}{5},\frac{6}{5}\bigg|\frac{3}{4},\frac{5}{4},\frac{6}{4}\bigg|-\frac{5^5}{4^4}(1+x)^2 \right) \end{equation} a generalised hypergeometric function. If we plot the composition of these two i.e $f(f^{-1}(x))$ or $f^{-1}(f(x))$ the plot seems to indicate \begin{equation} f(f^{-1}(x))=f^{-1}(f(x))=x \end{equation} of course this is not a proof, and evaluating the inverse function may become numerically unstable if $x$ becomes too large.

  • 4
    $\begingroup$ I don't understand why this isn't the accepted answer. This is brilliant and helped me check the stability of some IIR filters for nonuniformly spaced samples that I have been building. $\endgroup$
    – The Dude
    Commented May 26, 2022 at 17:03

Generally, you say $y=$ your polynomial and solve for $x$. Fifth degree polynomials are generally not solvable. The general approach for a quadratic would be essentially the quadratic formula. Given $y=ax^2+bx+c$, you find $x=\frac {-b \pm \sqrt{b^2-4a(c-y)}}{2a}$. You need to pick one sign to get a function.

  • $\begingroup$ Thank you! I will try it again. $\endgroup$
    – Jaden M.
    Commented Oct 10, 2012 at 23:47
  • $\begingroup$ The solution that is expected to be x = f(y) does not contain y. Substitute c by c-y ? $\endgroup$
    – h22
    Commented Nov 23, 2018 at 8:02
  • $\begingroup$ @h22: yes, that is correct. Thanks $\endgroup$ Commented Nov 23, 2018 at 15:07

As others indicated, there is no algebraic formula for the inverse function $f^{-1}$. The inverse functions exists (since $f$ is increasing), but there are serious algebraic obstructions to solving $y=x^5 + 2x^3 + x - 1$ for $x$.

But we can find particular values of $f^{-1}$ and of its derivative. For example, to find $f^{-1}(3)$ we would just have to note that $f(1)=3$. Therefore, $f^{-1}(3)=1$. (The number $3$ is lucky here; if asked about $f^{-1}(4)$, one would need a numerical method, e.g., a calculator.)

Also, the inverse function theorem can be used to find the derivative of $f^{-1}$ at $3$: $$ (f^{-1})'(3) = \frac{1}{f'(1)} = \frac{1}{5+6+1} = \frac{1}{12} $$

Related question.


You need to solve the equation

$$x^5 + 2x^3 + x - 1=y$$ for $x$. Unfortunately, such quintic equations are known to have no closed-form solution in general, and this one does not escape the rule.

Anyway, there is a little backdoor, as a quintic can be (after painful computation) reduced to the form known as Bring Quintic Form


Under this particular form, the solutions of $x$ in terms of $a$ are called the Bring radicals of $a$. So if you accept this special univariate function in your toolbox, then you can invert the quintic polynomials.

The cases of linear, quadratic, cubic and quartic polynomials can be solved with the usual functions, with increasing difficulty.


The original question seems to have come from a homework problem which does NOT require explicitly finding the inverse of a polynomial; however, since this page is one of the first things that pop up when you search for how to find the inverse of a polynomial function, and a general method for this WAS asked for, this general question is what I will discuss. Also, I realize that, until I discuss numerical methods at the bottom, I'm just repeating what others have said with more explanation.

Solving a polynomial

$y = p(x) = a_{0} + a_{1}x + a_{2}x^2 + ... + a_{n}x^n$

for x is equivalent to solving the equation

$p(x) - y = 0$


$a_{n}x^n + a_{n-1}x^n-1 + ... + a_{1}x + (a_0 - y) = 0$

for x, i.e., to getting the zeros of the polynomial on the left as a function of y. (That is, for each value of y, we treat y as a constant and find the zeros of the polynomial, so in the general case of polynomials on the complex numbers, this is a function from complex numbers (any value of y) to sets of complex numbers (the up to n possible complex x values that satisfy this equation for that value of y). Using map notation and set-builder notation:

$X: \mathbb{C} \rightarrow \wp(\mathbb{C}): X(y) = \{x \in \mathbb{C} | p(x) - y = 0\}$

The specific case of a polynomial that is invertible on real numbers (and therefore of odd number order, incidentally) corresponds to a case where, for any real number y, X(y) has exactly one element which is a real number. $p^{-1}$ is then the function that maps each real number y to that one real number element of X(y). In addition to this multi-function interpretation using sets, any function can be made invertible by changing the domain and range, though the domain and range will be switched in the inverse.

What all this means is that you can definitely find an equation (albeit a nasty one) for the inverses of polynomials of degree up to 4, but some (I think "almost all") polynomials of degree 5 or above probably don't have an inverse that can be written in terms of addition, subtraction, multiplication, division, and rational number exponents (which can be created from radicals and multiplication). This latter result I'm guessing is a corollary to the Abel-Ruffini theorem or some variation on it, which says there is no general equation for the roots of polynomials of degree 5 or above using only the arithmetic operations described above. You should look at it yourself for more details because I'm not familiar with the details.

For degree 0 polynomials (constant functions):


x is irrelevent, so:

$X(a_{0}) = \mathbb{C}$, and

$\forall y \in \mathbb{C}, y ≠ a_{0} \implies X(y) = \emptyset$

For degree 1 polynomials (linear/affine equations):

$y=a_{0} + a_{1}x$

the most basic algebra shows that

$X(y) = \{ \frac{y - a_{0}}{a_{1}} \}$

For degree 2 polynomials (quadratic equations):

$y=a_{0} + a_{1}x + a_{2}x^2$

one can use the quadratic formula to find that

$X(y) = \left\{ \frac{-a_{1} - \sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)}}{2a_{2}}, \frac{ -a_{1} + \sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)} }{2a_{2}} \right\} = \frac{-a_{1} \pm \sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)}}{2a_{2}} = \frac{-a_{1} + \sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)}}{2a_{2}}$

That last expression $\left(\frac{-a_{1} + \sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)}}{2a_{2}}\right)$ is equal to the others if we adopt the convention that an nth root of a complex number is actually the SET of all complex numbers whose nth power is what is under the radical, and that putting a set into an algebraic equations gives its image under the function represented by that expression, or, if that image would be a set of sets, the set of elements of elements of that set of sets, so, if

$S = \sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)} = \left\{ -\sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)}, +\sqrt{a_{1}^2 - 4a_{2}(a_{0} - y)} \right\}$, then

$\frac{-a_{1} + S}{2a_{2}} = \{ \frac{-a_{1} + s}{2a_{2}} | s \in S \}$, and, for example, if T is some set, then

$\sqrt[3]{\frac{f(y) + T}{g(y)}} = \{ z \in \mathbb{C} | \exists t \in T$ such that $z^3 = \frac{f(y) + t}{g(y)}\}$,

recalling that y is treated as an already known complex number, since these sets are values of X(y) for some y. This is formally useful to simplify the notation of the cubic and quartic cases, but perhaps you can understand it better with intuition than with my explanation.

For degree 3 polynomials (cubic equations):

$y = a_{0} + a_{1}x + a_{2}x^2 + a_{3}x^3$, so

$0 = (a_{0} - y) + a_{1}x + a_{2}x^2 + a_{3}x^3$

One could use the much more complicated cubic equation. This is known for often giving answers in strange forms that are hard to simplify, however, sometimes it's not that bad, especially if you do it by steps and $Δ_{1}^2(y) - 4Δ_{0}^3$ is always positive in the region of interest:

$X(y) = -\frac{1}{3a_{3}}\left(a_{2} + \sqrt[3]{\frac{(2a_{2}^3 - 9a_{3}a_{2}a_{1} + 27a_{3}^2 (a_{0} - y)) \pm \sqrt{(2a_{2}^3 - 9a_{3}a_{2}a_{1} + 27a_{3}^2 (a_{0} - y))^2 - 4(a_{2}^2 - 3a_{3}a_{1})^3}}{2}} + \frac{a_{2}^2 - 3a_{3}a_{1}}{\sqrt[3]{\frac{(2a_{2}^3 - 9a_{3}a_{2}a_{1} + 27a_{3}^2 (a_{0} - y)) \pm \sqrt{(2a_{2}^3 - 9a_{3}a_{2}a_{1} + 27a_{3}^2 (a_{0} - y))^2 - 4(a_{2}^2 - 3a_{3}a_{1})^3}}{2}}}\right)$

I got this from the following way of breaking it down Wikipedia used (where I have substituded my coefficients in place of their "a","b","c", and "d"). Obviously you could check other sources, or even just Wikipedia in case I copied it wrong.

$Δ_{0} = a_{2}^2 - 3a_{3}a_{1}$

$Δ_{1}(y) = 2a_{2}^3 - 9a_{3}a_{2}a_{1} + 27a_{3}^2 (a_{0} - y)$

$C(y) = \sqrt[3]{\frac{Δ_{1}(y) \pm \sqrt{Δ_{1}^2(y) - 4Δ_{0}^3}}{2}} = \sqrt[3]{\frac{(2a_{2}^3 - 9a_{3}a_{2}a_{1} + 27a_{3}^2 (a_{0} - y)) \pm \sqrt{(2a_{2}^3 - 9a_{3}a_{2}a_{1} + 27a_{3}^2 (a_{0} - y))^2 - 4(a_{2}^2 - 3a_{3}a_{1})^3}}{2}}$

$X(y) = -\frac{1}{3a_{3}}(a_{2} + C(y) + \frac{Δ_{0}}{C(y)}) = -\frac{1}{3a_{3}} \left( a_{2} + \sqrt[3]{\frac{Δ_{1}(y) \pm \sqrt{Δ_{1}^2(y) - 4Δ_{0}^3}}{2}} + \frac{Δ_{0}}{\sqrt[3]{\frac{Δ_{1}(y) \pm \sqrt{Δ_{1}^2(y) - 4Δ_{0}^3}}{2}}} \right)$

There are other ways of solving cubic equations as well. For example, there is one using trigonometric functions that I think is supposed to be neater (or at least use only real numbers for real number roots) in cases the cubic equation using radicals can't be simplified to and a+bi form. Wikipedia writes it for a "depressed" cubic equation ($t^3+pt+q=0$), which can be formed from any cubic equation using a change of variable:


Finding the inverse of a cubic equation is necessary to eliminate the parameter from the curves generated by cubic splines (e.g., cubic Bezier splines), which is the reason I looked this question up.

There is also a quartic formula — for solving general degree 4 polynomials (quartic equations) — and this is even worse in terms of how complicated it is, but I don't think any new concepts will be revealed by writing it out, so I won't today. (Maybe I will add it later.) You can look it up yourself if you want to use it.

As I mentioned, the cubic and quartic formulas give hard-to-simplify equations for these roots (and thus for inverses of cubic and quartic equations), and there are no such equations for higher degree polynomials (at least not using just the basic arithmetic functions previously described). Also, in practice, even nth roots are just approximated using numerical methods (usually by a computer nowadays). Thus, for practical purposes, it might be better to explore numerical methods:

First of all, note that plugging in any value of $x$ gives you a value of $y$. Thus, you know one of the elements of $X(y)$ for that particular value of $y$, and, if $y=f(x)$ where you know $f $is invertible, then you know $f^{-1}(y) = x$. If you just want a reasonably smooth graph of $f^{-1}$ or $X$ (in the non-invertable case) in a particular (x,y) region (so you don't care about (x,y) pairs where either x or y, and most notably x, is out of the region of interest), then you can do something like the following: Evaluate y=f(x) for a regular grid of x values (like using x=(0.00, 0.01, 0.02, 0.03, ... 0.98, 0.99, 1.00) to find f(x) = (f(0.00), f(0.01), ..., f(1.00)), using MatLab-like notation for a graph with x values from 0 to 1). Then, if two adjacent y values are far apart, then you can check more x values between those two y values until you achieve the desired density of y values. (Since polynomials are continuous, you will always eventually reach the desired density by repeating this.)

To approximate the value of the inverse at a particular point (i.e., find x for a particular y), we could round to the nearest y value in grid like that found above if we had one. However, a more standard method is to use "Newton's Method", which is to use the following recurrence relation:

$x_{n+1} = x_{n} - \frac{f(x_{n})}{f'(x_{n})}$

Since $f$ is polynomial, $f'$ is easy to find. (If it wasn't we would replace it with a numerical approximation, making this the "Secant Method".) For polynomials in general, Newton's method does not always converge to a zero of the polynomial (though it always does if your initial guess (called $x_{0}$ or $x_{1}$) is close enough to the zero), and even if it does, it can only converge to one zero, which depends on your initial guess. However, in the special case of inverting a polynomial which is invertible on real numbers, we ALMOST have the conditions to ensure it always converges. (The one problem is that the derivative could equal zero at an isolated point, even if the polynomial is invertible.) Formally:

If $f: \mathbb{R} \rightarrow \mathbb{R}$ is a function whose derivative is continuous on (all of) $\mathbb{R}$ and is either always positive or always negative, and

$\forall n \in \mathbb{Z^+}, x_{n}$ is a function $\mathbb{R} \rightarrow \mathbb{R}$ such that

$\forall y \in \mathbb{R}, x_{1}(y) \in \mathbb{R}$, and

$\forall y \in \mathbb{R}, \forall n \in \mathbb{Z^+}, x_{n+1}(y) = x_{n}(y) - \frac{f(x_{n}(y)) - y}{f'(x_{n}(y))}$, then

$\forall y \in \mathbb{R}, f^{-1}(y) = \lim \limits_{n \to \infty} x_n(y)$

Normally, you don't try to explicitly calculate this limit, which I suspect would just amount to trying to find $f^{-1}(y)$ analytically in a way that makes this recursion irrelevant, but rather we just have a computer evaluate $x_{n}(y)$ for successive values of n until adjacent values get close enough together. Proving what maximum possible error a particular stopping condition for Newton's Algorithm gives is a numerical analysis topic I don't have the source to discuss right now, but is probably mentioned in any introductory text on the subject.

Another method of finding zeros specifically in the case where you know a range where exactly one zero is in is the bisection method, which is basically a binary search (if you know any computer science). Similar to this and to the secant method is the false position, or regula falsi, method.

Notation that might need explanation (just guessing based on thinking about the expertise of people who might ask or look up this question):

If $f$ is a function, then $f^2(y) = (f(y))^2$, e.g., $Δ_{1}^2(y) = (Δ_{1}(y))^2$. Cubes of functions are written the same way; however, $f^{-1}(y)$ refers to the inverse function of f evaluated at y, so $f^{-1}(y) ≠ (f(y))^{-1}$ in most cases.

$\forall$ is "for all" or "for any"

$\exists$ is "there exists at least one"

$\exists!$ is "there exists one and only one" (used below)

$\implies$ means logically implies/entails

$x \in S$ means x is an element of the set S.

$\mathbb{Z^+}$ is positive integers

$\mathbb{R}$ is real numbers

$\mathbb{C}$ is complex numbers

I use $f: A \to B: f(x) = ...$ to mean f is a "function" or "map" or "mapping" from the set A (it's domain) to the set B (it's codomain), i.e., $\forall x \in A, \exists! y \in B$ such that $f(x) = y$, and, specifically, $\forall x \in A, f(x) = ...$

$\wp(S)$ is the set of all subsets of a set S, including S itself and the empty set ($\emptyset$). This is called the power set of S, and the range of of X is actually a much smaller set than this, but it's okay for the codomain of the function to be larger than the function's actual range ("range" = the values that are actually f(x) for some x in it's domain). That just means the function is not "surjective"/"onto".

$\{x \in S | P(x)\}$ is the subset of S containing only those elements such that the predicate P is true for that element. This is called "set-builder notation". E.g., the range of the function $f: A \to B$ is the set $\{y \in B | \exists x \in A$ such that y = f(x)$\}$.

$f'$ is the derivative of f, i.e., a function related to f which gives the rate of change of f(x) as x changes, i.e., the slope of y=f(x) at a the point (x,y). Based on the homework problem I think this question may have come from, I'm sure the original asker knows this one already.

It is worth noting, though, that $f'$ is a specific function from $\mathbb{R} \to \mathbb{R}$ — the rate of change of the f(z) as WHATEVER z is changes, proportional to the change in z, formally, $f'(z) = \lim \limits_{h \to 0}\frac{f(z+h) - f(z)}{h}$ — so $f'(x_{n}(y)) = \frac{df(x_{n}(y))}{dx_{n}(y)}$ NOT $\frac{df(x_{n}(y))}{dy}$ or anything else. (I just used another notation for derivatives, alluding to their being ratios of infinitessimals or limits of ratios, as described in the formal definition I gave.)

  • $\begingroup$ I always write answers that are too long, because I get absorbed when I'm answering the question, but then I don't want to spend just as long going through all the stuff I already bothered to write deciding which parts are worth deleting to improve readability and declutter the page. $\endgroup$
    – Mr. Nichan
    Commented Mar 3 at 22:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .