Let
denote the kth term of the sequence. Then

where d is the common difference between consecutive terms in the sequence and a₁ is the first term.
The sum of the first n terms is

From the formula for
, we get




So we have
, and
so that
.
Then the nth term in the sequence is
