<s>[INST] Expansion of $S=\frac{{nx^{n+1}-(n+1)x^{n}+1}}{(x-1)^2}$ Expand;
$S=\frac{{nx^{n+1}-(n+1)x^{n}+1}}{(x-1)^2}$
See solution, Also I am looking for an advance method if exists.
 [/INST] We can also see that $$S =\frac{nx^{n+1}-(n+1)x^n+1}{(x-1)^2} $$ $$\implies S(1-x)=\frac{(n+1)x^n-nx^{n+1}-1}{x-1}=\frac{(x-1)[1+x+x^2…x^{n-1}-nx^n]}{x-1}=[1+x+x^2+…x^{n-1}-nx^n]$$ $$S=\frac{1+x+x^2…x^{n-1}-nx^n}{1-x}=[1+x+x^2+…][1+x+x^2+…x^{n-1}-nx^n] = ?$$
</s>