Simple way to compute the finite sum $\sum\limits_{k=1}^{n-1}k\cdot x^k$ I'm looking for an elementary method for computing a finite geometric-like sum,
$$\sum_{k=1}^{n-1} k\cdot3^k$$
I have a calculus-based solution: As a more general result, I replace $3$ with $x$ and denote the sum by $f(x)$. Then
$$f(x) = \sum_{k=1}^{n-1} k\cdot x^k = x\sum_{k=1}^{n-1}k\cdot x^{k-1} = x\frac{\mathrm d}{\mathrm dx}\left[\sum_{k=1}^{n-1}x^k + C\right]$$
for some constant $C$. I know that
$$\sum_{k=1}^{n-1}x^k = \frac{x-x^n}{1-x}$$
so it follows that
$$\begin{align}
f(x) &= x\frac{\mathrm d}{\mathrm dx}\left[\frac{x-x^n}{1-x}+C\right] \\[1ex]
&= x\cdot\frac{(1-x)\left(1-nx^{n-1}\right) + x-x^n}{(1-x)^2} \\[1ex]
&= \frac{x-nx^n(1-x)-x^{n+1}}{(1-x)^2}
\end{align}$$
which means the sum I started with is
$$\sum_{k=1}^{n-1}k\cdot3^k = \frac{3+2n\cdot3^n-3^{n+1}}4$$
I am aware of but not particularly adept with summation by parts, and I was wondering if there was another perhaps simpler method I can employ to get the same result?
 A: Hint:
Take $S = 3 + 2 \cdot 3^2 + \ldots + (n-1)3^{n-1}$ then $3S = 3^2 + 2\cdot 3^3 + \ldots + (n-2)3^{n-1} + (n-1)3^n$
Then $3S - S = -3 + ( 3^2 + 3^3 + \ldots + 3^{n-1}) + (n-1) 3^n$
The expression in bracket is geometric series.
A: Hint:
It suffices to notice that
$$S:=\sum_{k=1}^{n-1} k\cdot3^k=\sum_{k=0}^{n-2} (k+1)\cdot3^{k+1}=3\sum_{k=1}^{n-1} (k+1)\cdot3^k+3-n\cdot3^n=3S+\text{terms}.$$
Now subtract the RHS from three times the LHS (which gives you twice the LHS), simplify and fiddle with the terms.
A: Factor out a $3$:
\begin{align}S=\sum_{k=1}^n k \cdot3^k & = 3\sum_{k=1}^n k \cdot3^{k-1}\\ 
&=3\sum_{j=0}^{n-1} (j+1) \cdot3^{j}\\ 
&=3(\sum_{j=0}^{n-1} j \cdot3^{j}+\sum_{j=0}^{n-1} 3^{j})\\ 
&=3(S-n\cdot3^n+\sum_{j=0}^{n-1} 3^{j})\\ 
\end{align}
Now you can solve for $S$, and everything else is known
A: Let $$S=\sum_{k=1}^{n-1} k\cdot3^k$$
Then $$3S=\sum_{k=1}^{n-1} k\cdot3^{k+1}$$
Subtracting , we get $$2S=\sum_{k=1}^{n-1} k\cdot3^{k+1}-\sum_{k=1}^{n-1} k\cdot3^k$$
$$2S=(1.3^2+2.3^3+3.3^4+\cdots+(n-1)3^n)-(3+2\cdot3^2 + 3\cdot3^3+\cdots+(n-1)3^{n-1})$$
$$-2S=(3+2\cdot3^2+3\cdot3^3+\cdots+(n-1)3^{n-1})-(1\cdot3^2 + 2\cdot3^3 + 3\cdot3^4+\cdots+(n-1)3^n))$$
$$-2S=3+(2-1)3^2+(3-2)3^3+\cdots+((n-1)-(n-2))3^{n-1})-(n-1)3^n$$
$$-2S=3+3^2+3^3+3^4+\cdots+3^{n-1}-(n-1)3^n$$
$$2S=(n-1)3^n-3\frac{3^{n-1}-1}{3-1}$$
$$2S=(n-1)3^n-\frac{3}{2}({3^{n-1}-1})$$
$$S=\frac{2(n-1)3^n-3({3^{n-1}-1})}{4}$$
This type of series is called $\text{ Arithmetico-Geometric Series }$ https://en.wikipedia.org/wiki/Arithmetico%E2%80%93geometric_sequence
