Geometric Sequences

A geometric sequence is a sequence with an initial term, a1 and a common ration, r, where each term after the initial term is obtained by multiplying the previous term by the ratio (a1 cannot be zero, and r cannot be zero or one). In a geometric sequence, if we know the first term and the ratio, we can determine the nth term by the formula an = a1*rn - 1 Similarly, if we know the first term and the ratio, we can determine the sum of the first n terms in a geometric sequence by the formula:

Sn =
a1(1 - rn)
1 - r