# Is there any formula to find the nth element in a sequence where common difference (d) is varying with a constant rate?

To explain my question, here is an example.

Below is an AP:

2, 6, 10, 14....n

Calculating the nth term in this sequence is easy because we have a formula. The common difference (d = 4) in AP is constant and that's why the formula is applicable, I think.

5, 12, 21, 32....n

Here, the difference between two consecutive elements is not constant, but it too has a pattern which all of you may have guessed. Taking the differences between its consecutive elements and formimg a sequence results in an AP. For the above example, the AP looks like this:

5, 7, 9, 11.....n

So given a sequence with "uniformly varying common difference" , is there any formula to calculate the nth term of this sequence?

• Where does the 0 come from? If the first difference is common, then the explicit form is linear. If the second difference is common, then the explicit form is quadratic. And so on... Jun 30, 2016 at 15:50
• So first differences is 7,9,11,... and the second differences are 2,2,2,.... So you will have a quadratic. Jun 30, 2016 at 15:51
• How to find the nth term then? Is there a formula that makes things easier?
– user351231
Jun 30, 2016 at 15:55
• You say you are not very good at maths, but if you (re)discovered this concept - second differences - then I would say that you have good mathematical insight. Jun 30, 2016 at 15:57
• There is Vandermonde Interpolation (which is more relatable to in middle/high school) and Lagrange Interpolation. Alternatively there is this guy (ckrao.wordpress.com/2012/02/28/…). Jun 30, 2016 at 16:00

Here's how you can find this with a difference table:

$\color{red}{5}\;\;\; 12\;\;\;21 \;\;\;32\;\cdots$

$\;\;\color{red}{7}\;\;\;\;9\;\;\;\;11\;\cdots$

$\;\;\;\;\color{red}{2}\;\;\;\;2\;\;\;\cdots$

$\hspace{.33 in}0$

So $\displaystyle a_n=\color{red}{5}\dbinom{n-1}{0}+\color{red}{7}\dbinom{n-1}{1}+\color{red}{2}\dbinom{n-1}{2}=5+7(n-1)+2\frac{(n-1)(n-2)}{2}=\color{blue}{n^2+4n}$

Well the explicit form aka the nth term is a quadratic... $A_n=an^2+bn+c$

Use the points from your sequence to find $a,b, \text{ and } c$

For example you can use the points $(0,2), (1,6) , \text{ and } (2,10)$.

• You should have a single power in the second term. Jun 30, 2016 at 16:00
• Thanks, I didn't notice I put a square there. Jun 30, 2016 at 16:01