# When should the antiderivative of a rational function be defined as a piecewise function?

I'm doing basic problems on antiderivatives and there seems to be an inconsistency in my book.

The instructions for these problems are:

Find the most general antiderivative of the function.

Number 11 is:

11. $f(x) = \dfrac{10}{x^9}$

So, I naturally wrote down $F(x) = -\dfrac{5}{4x^8} + C$.

The solution manual says this is wrong. The function has domain $(-\infty, 0) \cup (0, \infty)$, so $F(x) = \begin{cases} -\dfrac{5}{4x^8}+C_1 & \text{if } x < 0 \\ -\dfrac{5}{4x^8}+C_2 & \text{if } x > 0 \end{cases}$

Okay, I thought. That makes sense.

I then come to number 13, which is:

13. $f(x) = \dfrac{u^4 + 3\sqrt{u}}{u^2}$.

I figured the domain is $(-\infty, 0) \cup (0, \infty)$, so I wrote down $F(x) = \begin{cases} \frac{1}{3}u^3-6u^{-1/2}+C_1 & \text{if } u > 0 \\ \frac{1}{3}u^3-6u^{-1/2}+C_2 & \text{if } u < 0 \end{cases}$.

Well, the solution book doesn't mention the domain and just says $F(x) = \frac{1}{3}u^3-6u^{-1/2}+C$.

I later realized that the $\sqrt{u}$ in the numerator and the $u^2$ in the denominator must limit the domain to the positive numbers, so the antiderivative doesn't need to be defined for anything but positive numbers. So, okay, I think I get it.

Next number 19 is:

19. $f(x) = \dfrac{x^5-x^3+2x}{x^4} = x - \dfrac{1}{x} + \dfrac{2}{x^3}$

So, again, since the domain appears to be $(-\infty, 0) \cup (0, \infty)$, I wrote down $F(x) = \begin{cases} \frac{1}{2}x^2 - \ln|x| - \dfrac{1}{x^2} + C_1 & \text{if } x > 0 \\ \frac{1}{2}x^2 - \ln|x| - \dfrac{1}{x^2} + C_2 & \text{if } x < 0 \end{cases}$.

But the book again doesn't mention the domain and just says that $F(x) = \frac{1}{2}x^2 - \ln|x| - \dfrac{1}{x^2} + C$.

I am confused. This doesn't seem consistent, especially between #11 and #19. Why is my answer not right for #19?

-
Unless I'm missing something, I think you're right. You can chose a different constant for each piece (connected component) of the domain. –  Joel Cohen Sep 5 '11 at 20:25
The person who wrote out the solutions presumably thought that the absolute value sign takes care of the problem. It doesn't. Congratulations on reading with care. –  André Nicolas Sep 5 '11 at 20:32
Okay, thanks guys! I was mostly wondering if I had a misunderstanding about functions and their domains. –  Matt Gregory Sep 5 '11 at 20:39
Some solution writers wouldn't have been so careful on #11. Might the solutions to #11 and #19 have been written by different people? –  Jonas Meyer Sep 5 '11 at 20:39
I assume $u$ and $x$ are supposed to be the same variable? You shouldn't use both in the same equation. –  Robert Israel Sep 5 '11 at 21:17

The person who wrote out the solution may have thought that putting absolute value signs around $x$ takes care of the problem. It doesn't. Congratulations on reading with care.
The answer for Question $19$ ought to be something like $$F(x) = \begin{cases} \frac{1}{2}x^2 - \ln x - \dfrac{1}{x^2} + C_1 & \text{if } x > 0 \\ \frac{1}{2}x^2 - \ln(-x) - \dfrac{1}{x^2} + C_2 & \text{if } x < 0 \end{cases}.$$