Recursive Sequence Calculator
Test cases replayed : 4 of 4 match · Methodology · No outside source listed
Choose a first-order rule aₙ = p·aₙ₋₁ + r or a second-order rule aₙ = p·aₙ₋₁ + q·aₙ₋₂ + r, enter the starting terms, and get any term up to the 50th, the sum of the terms and the first ten terms.
Result
Term aₙ
Sum a₁ + … + aₙ
- First ten terms
Estimate for planning only, not tax, legal, financial or medical advice. This calculator uses the method explained on this page.
This browser did not allow copying. The sentence is in the box below, already selected: copy it with your keyboard or the menu.
How to use this calculator
Fill in the fields in this order; each step takes you to its field.
- Recursive formula: choose First order: aₙ = p·aₙ₋₁ + r or Second order: aₙ = p·aₙ₋₁ + q·aₙ₋₂ + r.
- p, multiplier of aₙ₋₁: enter a number.
- q, multiplier of aₙ₋₂ (second order only): enter a number.
- r, constant added: enter a number.
- First term a₁: enter a number.
- Second term a₂ (second order only): enter a number.
- Term number n (1 to 50): enter a number from 1 to 50.
- Read the result: Term aₙ; the panel also shows Sum a₁ + … + aₙ and First ten terms.
How this calculator works
A recursive formula gives each term from the ones before it. First order: a₁ is given and aₙ = p·aₙ₋₁ + r for n ≥ 2. Second order: a₁ and a₂ are given and aₙ = p·aₙ₋₁ + q·aₙ₋₂ + r for n ≥ 3.
Special cases: in first order, p = 1 is an arithmetic sequence with common difference r and r = 0 is a geometric sequence with ratio p; p = q = 1, r = 0 with a₁ = a₂ = 1 is the Fibonacci sequence (the default).
The terms are computed one after another; values are shown to 4 decimal places, and a term too large to represent shows a dash.
Worked example
| Recursive formula | Second order: aₙ = p·aₙ₋₁ + q·aₙ₋₂ + r |
|---|---|
| p, multiplier of aₙ₋₁ | 1 |
| q, multiplier of aₙ₋₂ (second order only) | 1 |
| r, constant added | 0 |
| First term a₁ | 1 |
| Second term a₂ (second order only) | 1 |
| Term number n (1 to 50) | 10 |
| Term aₙ | 55 |
|---|---|
| Sum a₁ + … + aₙ | 143 |
| First ten terms | 1, 1, 2, 3, 5, 8, 13, 21, 34, 55 |
Frequently asked questions
What is the 10th Fibonacci number?
55, with a₁ = a₂ = 1. The first ten terms are 1, 1, 2, 3, 5, 8, 13, 21, 34, 55.
How do I enter aₙ = 2aₙ₋₁ + 1 with a₁ = 1?
Choose first order, p = 2, r = 1, a₁ = 1. The terms are 1, 3, 7, 15, 31…, that is 2ⁿ − 1.
What is the difference between a recursive and an explicit formula?
A recursive formula needs the previous terms; an explicit formula, such as aₙ = 2ⁿ − 1, gives any term directly from n.