Given a seqence $(a_0,a_1,a_2\dots,a_n,\dots)$ where $a_n = \binom{n}{2}$,so I can get the the following form:
$$f(x)=\sum_{i=0}^{\infty}a_ix^i=\sum_{i=0}^{\infty}\binom{i}{2}x^i \\ =\sum_{i=2}^{\infty} \frac{1}{2} *i * (i - 1) * x^i \\ =\frac{1}{2}\sum_{i=0}^{\infty}(i+2)*(i+1)*x^{i+2} \\ =\frac{1}{2}x^2\sum_{i=0}^{\infty}(i+2)*(i+1)*x^{i} $$ The latter term can be obtained by taking the second derivative with respect to $\sum_{i=0}^{\infty}x^i$ or $\sum_{i=2}^{\infty}x^i$
But these two formulas correspond to different closed forms,which are $\frac{1}{1-x}$ and$\frac{x^2}{1-x}$,and they lead to different answer of this question. So I wonder which one is right and why.
Thanks!