Let $a_{1}, a_{2}, a_{3}, \ldots$ be the terms of an arithmetic sequence, and let $q$ be a positive number different from 1. What is the sum of the first $n$ terms of the sequence

$$
A_{k}=k \cdot q^{a_{k}}
$$
I. solution. Using the usual notation for an arithmetic sequence,

$$
a_{k}=a+(k-1) d, \quad A_{k}=k q^{a+(k-1) d}
$$

When deriving the formula for the sum of a geometric sequence, it proved useful to multiply the sum by $q$ and then take the difference of the resulting two sequences. Let's try this idea now. Multiply the sequence $S_{n}$ by $q^{d}$, which is a positive number different from 1 unless $d \neq 0$. (If $d=0$, the sequence turns into an arithmetic sequence, and its sum is easy to determine.)

$$
\begin{gathered}
S_{n}=q^{a}+2 q^{a+d}+3 q^{a+2 d}+\ldots+n q^{a+(n-1) d} \\
q^{d} S_{n}=q^{a+d}+2 q^{a+2 d}+3 q^{a+3 d}+\ldots+n q^{a+n d}
\end{gathered}
$$

Subtracting the second sum from the first, after factoring out, we get

$$
S_{n}\left(1-q^{d}\right)=q^{a}\left(1+q^{d}+q^{2 d}+\ldots+q^{(n-1) d}-n q^{n d}\right)
$$

Applying the known summation formula for the geometric sequence in the parentheses, we obtain the following expression:

$$
S_{n}=\frac{q^{a}}{1-q^{d}}\left(\frac{1-\left(q^{d}\right)^{n}}{1-q^{d}}-n q^{n d}\right)=\frac{q^{a}}{\left(1-q^{d}\right)^{2}}\left(1-(n+1) q^{n d}+n q^{(n+1) d}\right)
$$

László Gyimesi (Budapest, Piarist High School, 4th grade)

II. solution. Let's introduce the following additional notations: $q^{d}=x$ and $q^{a}=r$, then

$$
S_{n}=r+2 r x+3 r x^{2}+\ldots+r n x^{n-1}=r\left(1+2 x+3 x^{2}+\ldots+n x^{n-1}\right)
$$

The observation that the $k x^{k-1}$ term is the derivative of $x^{k}$ means that the sum $1+2 x+3 x^{2}+\ldots+n x^{n-1}$ is the derivative of the sum $P(x)=x+x^{2}+\ldots+x^{n}$. Therefore, based on the identity

$$
P(x)=x+x^{2}+\ldots+x^{n}=\frac{x^{n+1}-x}{x-1}
$$

(hence $x \neq 1$), the derivative of the sum is equal to the derivative of the expression on the right side. According to known differentiation rules,

$$
P_{n}^{\prime}(x)=\frac{\left[(n+1) x^{n}-1\right](x-1)-\left(x^{n+1}-x\right)}{(x-1)^{2}}=\frac{1-(n+1) x^{n}+n x^{n+1}}{(1-x)^{2}}
$$

Multiplying this by $r=q^{a}$ and substituting $x=q^{d}$, we arrive at the result obtained in the previous solution.

III. solution. Keeping the notations used in the previous solution, let's write the $r$-th part of the sum $S_{n}$ and denote it by $F_{n}$:

$$
F_{n}=1+2 x+3 x^{2}+\ldots+n x^{n-1}
$$

This sum can also be determined as follows: let

$$
\begin{aligned}
& f_{1}=x^{n-1} \\
& f_{2}=x^{n-1}+x^{n-2} \\
& f_{3}=x^{n-1}+x^{n-2}+x^{n-3} \\
& \cdot \cdot \cdot \cdot \cdot \cdot \cdot \cdot \cdot \cdot \cdot \\
& f_{n}=x^{n-1}+x^{n-2}+x^{n-3}+\ldots+x^{2}+x+1
\end{aligned}
$$

then it is obviously

$$
F_{n}=f_{1}+f_{2}+\ldots+f_{n}
$$

The sum $f_{k}(k=1,2, \ldots, n)$ is the sum of the first $k$ terms of a geometric sequence whose first term is $x^{n-1}$ and common ratio is $y=\frac{1}{x}=\frac{1}{q^{d}} \neq 1$.

Thus, based on the relationship for a geometric sequence,

$$
f_{k}=x^{n-1} \frac{y^{k}-1}{y-1}=c y^{k}-c
$$

where $c$ temporarily denotes the expression $\frac{x^{n-1}}{y-1}$. Using this and the relationship $\left({ }^{*}\right)$,

$$
F_{n}=c\left(y+y^{2}+\ldots+y^{n}\right)-n c=c y \frac{y^{n}-1}{y-1}-n c
$$

can be written, and from this, substituting $y=\frac{1}{x}$ and $c$, we arrive at the result $P_{n}^{\prime}(x)$ obtained in the previous solution.