Compute $f^{(2020)}(0)$ Problem :
Let
$$f(x)=\frac{x}{(x+1)(1-x^2)}$$
Then find $f^{(2020)}(0)$.

My Attempt :
From partial fraction decomposition,
$$f(x)=\frac{1}{4(1-x)}+\frac{1}{4(x+1)}-\frac{1}{2(x+1)^2}$$
and,
$$\frac{1}{1-x}=\sum_{n=0}^\infty x^n,\quad \frac{1}{1+x}=\sum_{n=0}^\infty (-1)^nx^n, \quad\frac{1}{(1+x)^2}=\sum_{n=1}^\infty (-1)^{n+1}nx^{n-1}=\sum_{n=0}^\infty(-1)^n(n+1)x^n$$
From these,
$$f(x)=\sum_{n=0}^\infty \frac{x^n}{4}+\sum_{n=0}^\infty \frac{(-1)^nx^n}{4}+\sum_{n=0}^\infty\frac{(-1)^{n+1}(n+1)x^n}{2} \\ =\sum_{n=0}^\infty\frac{x^n+(-1)^nx^n+(-1)^{n+1}(n+1)x^n}{4} \\ =\sum_{n=0}^\infty\frac{(1+(-1)^n+(-1)^{n+1}(n+1))x^n}{4}$$
$f^{(2020)}(0)=(2020)!\times a_{2020}$ where $f(x)=\sum a_nx^n$
In this case, $a_n = 1+(-1)^n+(-1)^{n+1}(n+1), a_{2020}=-2019$ but there is no same answer.
Where did I make a mistake?
 A: You have$$\sum_{n=0}^\infty\left(\frac{x^n}{4}+\frac{(-1)^nx^n}{4}+\frac{(-1)^{n+1}(n+1)x^n}2\right)=\sum_{n=0}^\infty\frac{1+(-1)^n+\color{red}2(-1)^{n+1}(n+1)}4x^n$$So, the coefficient of $x^{2020}$ is $-1010$. In other words, $f^{(2020)}(0)=-1010\times2020!$.
A: Since the other responses have dissected the OP's (i.e. original poster's) work, I can give an alternative approach.
$\underline{\text{Preliminary Results}}$
$\displaystyle f(u) = u^{-1} \implies f^{(2020)}(u) = [(2020)!] \times u^{-2021}.$
$\displaystyle f(u) = u^{-2} \implies f^{(2020)}(u) = [(-2) \times (-3) \times \cdots (-2021)] \times u^{-2022}$ 
$\displaystyle = [(2021)!] \times u^{-2022}.$

From the OP's work:
$$f(x) = \left[~\left(\frac{-1}{4}\right) \times \left(\frac{1}{x-1}\right) ~\right] 
~+~ ~\left[~\left(\frac{1}{4}\right) \times \left(\frac{1}{x+1}\right) ~\right]
~+~ ~\left[~\left(\frac{-1}{2}\right) \times \left(\frac{1}{x+1}\right)^2 ~\right].$$
Let $~\displaystyle u = (x - 1), v = (x + 1) \implies 
\frac{du}{dx} = 1 = \frac{dv}{dx}.$
Then
$$f(x) = \left[(-1/4)u^{-1}\right] + \left[(1/4)v^{-1}\right] + \left[(-1/2)v^{-2}\right].$$
Using the preliminary results, you have that
$$f^{(2020)}(x) = [(2020)!] ~~\times $$
$$\left\{ ~\left[(-1/4)u^{-2021}\right] ~+~ \left[(1/4)v^{-2021}\right] 
~+~ \left[(-1/2)(2021)v^{-2022}\right] ~\right\}.$$
At $~x = 0,~$ you have that $~u = -1, ~v = +1.$
Therefore,
$$f^{(2020)}(x=0) = [(2020)!] ~~\times $$
$$\left\{ ~\left[(-1/4)(-1)\right] ~+~ \left[(1/4)(+1)\right] 
~+~ \left[(-1/2)(2021)(+1)\right] ~\right\}$$
$$= [(2020)!] \times \left\{ ~(1/4) + (1/4) - \left[(1/2)(2021)\right] ~\right\}$$
$$= [(2020)!] \times (-1010).$$
A: A bit tricky
$$f(x)=\frac{x}{(x+1)(1-x^2)}$$ Integrate $$g(x)=\int f(x)\,dx=\frac{1}{4} \left(\frac{2}{x+1}-\log (1-x)+\log (x+1)\right)$$
$$g(x)=\frac 12 +\sum_{n=1}^\infty \frac{(-1)^n (2 n-1)+1}{4 n} x^n$$ Differentitate
$$f(x)=g'(x)=\sum_{n=1}^\infty \frac{(-1)^n (2 n-1)+1}{4} x^{n-1}$$
Now, to make $x^{n-1}=x^{2020}$, $n=2021$ and then the coefficient of $x^{2020}$ is $-1010$.
Just multiply by $2020!$
A: We have
$$f(x) = \frac14 \cdot \frac{1}{1-x}
+ \frac14 \cdot \frac{1}{1 + x}
+ \frac12 \cdot \left(\frac{1}{1 + x}\right)'.$$
By observing the first several derivatives to see the pattern:
$$\left(\frac{1}{1-x}\right)' = \frac{1}{(1-x)^2}, 
\left(\frac{1}{1-x}\right)'' = \frac{2}{(1-x)^3},
\left(\frac{1}{1-x}\right)''' = \frac{3}{(1-x)^4}, \cdots$$
$$\left(\frac{1}{1+x}\right)' = \frac{-1}{(1+x)^2}, 
\left(\frac{1}{1+x}\right)'' = \frac{2}{(1+x)^3},
\left(\frac{1}{1+x}\right)''' = \frac{-3}{(1+x)^4}, \cdots$$
we have
$$\left(\frac{1}{1-x}\right)^{(n)}
= \frac{n!}{(1-x)^{n+1}}$$
and
$$\left(\frac{1}{1+x}\right)^{(n)}
= \frac{(-1)^n n!}{(1+x)^{n+1}}.$$
Thus, we have
$$f^{(n)}(x) = \frac14 \cdot \frac{n!}{(1-x)^{n+1}}
+ \frac14 \cdot \frac{(-1)^n n!}{(1+x)^{n+1}} + \frac12 \cdot \frac{(-1)^{n+1} (n+1)!}{(1+x)^{n+2}} $$
and
$f^{(2020)}(0) = -1010 \cdot 2020!$.
