# Finite Difference

1. Sep 17, 2006

### Pyrrhus

Difference Equation

Hello, can anyone offer any insight on this equation? . I am very very rusty on solving this type of equations.

$$a_{n+1} - a_{n} = n^2$$

Last edited: Sep 17, 2006
2. Sep 17, 2006

### Cyrus

Never even seen that one before

3. Sep 17, 2006

### 0rthodontist

Use the method of undetermined coefficients.
Homogeneous solution: C, a constant
Particular solution: a quadratic in n
multiply the particular by n so that it shares no terms with the homogeneous, and you get a cubic:
an = An^3 + Bn^2 + Cn + D
Then solve for A, B, C, D. You will need a base case.

Edit: alternatively you could just look up the well-known formula for the sum of the first n squares.

Last edited: Sep 17, 2006
4. Sep 17, 2006

### Pyrrhus

Thanks, exactly what i was looking for.

Last edited: Sep 18, 2006