So I've been given this problem to solve (pretend it's a fraction or click the link to see the question please)
$$\int \frac{-26e^x-144}{e^{2x} + 13e^x + 36}dx$$
and I got this far:
$$-2\int\frac{13e^x + 72}{e^{2x} + 13e^x + 36}dx$$
The next step is a simple u-substitution which I am unable to do. I looked to a step-by-step calculator for help, and what I see is
$$\int\frac{13u+ 72}{u(u^2 + 13u + 36)}du$$
But I'm confused. Where did the extra $u$ come from?
I'm guessing that its like in the situation where you have $\int \cos(2θ)dθ$ and you have $u = 2θ$ and $du = 2dθ$, but there is no extra 2, so the end result is $\frac{1}{2}\int\cos(u)du$.
But I thought you could only do that with constants! You don't just add an extra $x^2$ when you need it. As thus, you shouldn't be able to add an extra $e^x$ just because you need it. Or am I missing something?
Let $f(z) = P(z)/Q(z)$ be a rational function in $z$ (that is to say, it is the quotient of two polynomials where $Q$ is not the zero polynomial). Then $$\int f(e^x) \, dx = \int \frac{f(e^x)}{e^x} \cdot e^x \, dx,$$ and with the substitution $u = e^x$, $du = e^x \, dx$, we obtain $$\int f(e^x) \, dx = \int \frac{f(u)}{u} \, du.$$ Since $f(u)$ is a rational function, so is $f(u)/u$. In your case, we have $$f(z) = \frac{-26z -144}{z^2 + 13z + 36},$$ hence $$\frac{f(u)}{u} = \frac{-26u - 144}{u(u^2 + 13u + 36)}.$$ After factoring a constant of $-2$ from the numerator, you get the result you mentioned.