# Evaluate $\int x^2\ln (1+x) \, dx$ as a power series: why is just $n$ ok?

This is a different question than the previous one I posed pertaining to the same textbook problem. I do not understand the justification in step seven for the exponent not changing. If you add $$1$$ to all the numbers that make up the set of $$n$$, then you must cancel out this effect by turning every $$n$$ into $$n-1$$ so that the series remains the exact same. You must have $$(-1)^{n-1}$$. What am I missing?

• It doesn't make sense. The first term of the series in $(6)$ is $x^4/4$ while the first term in $(7)$ is $-x^4/4$. – Fimpellizieri Nov 9 '19 at 5:00

The alternative Maclaurin expansion of $$\ln (1+x)$$ is: $$\ln (1+x)=\sum_{n=1}^{\infty} \frac{(-1)^{n+1}x^n}{n}=\sum_{n=1}^{\infty} \frac{(-1)^{n-1}x^n}{n}.$$ Note: The sum starts from $$n=1$$ already.
Hence: $$\int x^2\sum_{n=1}^\infty \frac{(-1)^{n+1}x^n}{n} dx=\int \sum_{n=1}^\infty \frac{(-1)^{n+1}x^{n+2}}{n} dx=\\ C+\sum_{n=1}^\infty \frac{(-1)^{n+1}x^{n+3}}{n(n+3)}=C+\sum_{n=1}^\infty \frac{(-1)^{n-1}x^{n+3}}{n(n+3)}.$$
You're right it's not correct as currently stated. Since there's a specific note about not changing the exponent of $$(-1)^{n}$$, the author obviously was aware of this issue. Perhaps the textbook author intended to, but forgot, to change the "$$C +$$" part to "$$C -$$" (i.e., effectively moved a factor of $$-1$$ outside of the summation)? This would be a minimal mistake to have made, even though the final comment doesn't seem to completely fit this potential scenario. Also, it makes more sense, at least to me, to use $$n-1$$ as an exponent rather than changing the $$+$$ of the summation terms to a $$-$$.
\begin{align} & \sum_{n=0}^5 x^{n+4} \quad \text{(starting with n=0)} \\[10pt] = {} & x^4 + x^5 + x^6 + x^7 + x^8 + x^9 \\[10pt] = {} & \sum_{n=1}^6 x^{n+3} \quad \text{(starting with n=1)} \end{align} "Fimpellizieri" is right: A sign change was neglected. The exponent in $$(-1)^n$$ should also have changed by $$1.$$