# Integrating rational function by multiplying with a high-power polynomial term

When evaluating the integral $$\int \frac{x^2 + 8}{x^3 + 9x} \textrm{d}x$$, WolframAlpha gave an interesting step-by-step suggestion. Here is the suggested method:

$$\int \frac{x^2 + 8}{x^3 + 9x} \textrm{d}x = \int \frac{x^{17} + 8x^{15}}{x^{18} + 9x^{16}} \textrm{d}x=\frac{1}{18} \int \frac{18(x^{17} + 8x^{15})}{x^{18} + 9x^{16}} \textrm{d}x$$

Let $$u = x^{18}+9x^{16} \implies \textrm{d}u=(18x^{17}+144x^{15}) \, \textrm{d}x = 18(x^{17} + 8x^{15}) \, \textrm{d}x$$

$$\frac{1}{18} \int \frac{\textrm{d}u}{u} = \frac{1}{18} \log \vert u \vert + C$$

This indeed works, giving the correct answer (after substituting $$x$$ back and simplifying). But I've never seen this kind of an integration technique, and I'm wondering if there's a name for this method and perhaps a systematic way of determining which degree of polynomial to use? (The polynomial in this example happened to be $$x^{15}$$, something that I would've never though of)

I'm not sure what this method is called, but we can explore how to use it in general.

Consider integrals of the general form, $$\int \frac{a x^{n+k}+bx^{n}}{cx^{n+k+1}+dx^{n+1}}\textrm{d}x$$

We will pick $$u = x^{p}\cdot(cx^{n+k+1} +dx^{n+1})$$ and want $$\textrm{d}u = C x^p\cdot(ax^{n+k}+bx^n)$$ for some constants $$C$$ and $$p$$.

Note that we have $$\textrm{d}u = c\cdot(n+k+p+1) x^{n+k+p} + d\cdot(n+p+1) x^{n+p}$$

So we want to choose $$C$$ and $$p$$ such that, $$C\cdot a = c\cdot(n+k+p+1), ~~~C\cdot b = d\cdot(n+p+1)$$

In your example, $$n=0$$, $$k=2$$, $$a=c=1$$, $$b=8$$, and $$d=9$$ so we would solve, $$C = (0+2+p+1) = p+3, ~~~ C\cdot 8 = 9\cdot(0+p+1) = 9p+9$$

This is a linear system in two variables which you can solve to find $$p=15$$ and $$C=18$$.

Note that we could have the denominator have a degree more than one above the numerator and do a similar process to solve.

• Quick note, I think you're missing an $x$ from the $d$ term in $u=x^p \cdot (c x^{n+k+1}+d^{n+1})$. But thank you, very interesting answer. And thanks especially for taking the time to do it in general. – imas145 Jan 7 at 17:04