Calculating the first terms in a series of partial sums (KristaKingMath)