3tej home
← Games

What is Number Sequence Calculator?

A Number Sequence Calculator computes number sequence from the inputs you provide. It applies the standard formula to the values you enter and returns the result instantly, without sending any data to a server. Generate terms and sums for arithmetic progressions (AP), geometric progressions (GP), and Fibonacci sequences.

Number Sequence Calculator

Arithmetic progression (AP), geometric progression (GP), Fibonacci - terms + sum.

Sequence

Sum

-

Sequence

About the Number Sequence Calculator

A number sequence is an ordered list of numbers generated by a rule. The three most useful and most-tested rules in school and applied maths are the arithmetic progression (constant additive step), the geometric progression (constant multiplicative ratio), and the Fibonacci recurrence (each term is the sum of the previous two). These three families cover most of the sequence questions you meet in algebra, finance (simple and compound interest, annuities), physics (radioactive decay, bouncing-ball heights), biology (population growth), and computer science (algorithm complexity, recursion benchmarks). This calculator generates the first N terms and the total sum for any of the three families given your starting parameters.

All calculation runs locally in JavaScript using 64-bit floating-point arithmetic, so terms above roughly 2 to the 53 (about 9 quadrillion) start to lose precision; for arbitrary-precision work use a computer algebra system.

How the formulas work

Arithmetic Progression (AP)
  nth term: T(n) = a + (n - 1) · d
  Sum:      S(n) = (n / 2) · (2a + (n - 1) · d)

Geometric Progression (GP)
  nth term: T(n) = a · r^(n - 1)
  Sum:      S(n) = a · (1 - r^n) / (1 - r),  r ≠ 1
  Sum to infinity (|r| < 1): S(∞) = a / (1 - r)

Fibonacci
  F(1) = F(2) = 1
  F(n) = F(n - 1) + F(n - 2)
  Sum of first n: S(n) = F(n + 2) - 1
  Limit of F(n+1) / F(n) = φ ≈ 1.618 (golden ratio)

The arithmetic-versus-geometric distinction is the most important one. APs grow at a constant linear rate; GPs grow (or decay) exponentially. Doubling every step is a GP with r equal to 2; gaining one dollar of pay each year is an AP with d equal to 1.

Worked example: a 6 percent annuity

Suppose you invest 1000 dollars at 6 percent annual compound interest. The balance at the end of each year follows a GP with a equal to 1060 (the value after year 1) and r equal to 1.06:

  1. Year 1: 1000 × 1.06 = 1060.
  2. Year 5: T(5) = 1060 × 1.064 = 1060 × 1.262 = 1338.
  3. Year 10: T(10) = 1060 × 1.069 = 1060 × 1.689 = 1791.
  4. Sum across years 1 to 10 (cumulative balance trajectory): S(10) = 1060 × (1 - 1.0610) / (1 - 1.06) = roughly 13971. This is the running total of year-end values, not annuity payments.
  5. Comparison with AP: if the same 1000 grew at simple interest of 6 percent (AP with a equal to 1060, d equal to 60) the year-10 balance is only 1060 plus 9 × 60 = 1600. Compounding adds 191 dollars over a decade.
Result: Compound (GP) growth beats simple (AP) growth by an increasing margin every year. The longer the horizon, the bigger the wedge.

Sequence reference table

FamilyFirst five termsnth-term formulaReal-world use
AP (d=3)2, 5, 8, 11, 14a + (n-1)dSalary increment ladder
AP (d=-2)20, 18, 16, 14, 12a + (n-1)dLinear depreciation
GP (r=2)3, 6, 12, 24, 48a · r^(n-1)Population doubling
GP (r=0.5)16, 8, 4, 2, 1a · r^(n-1)Half-life decay
Fibonacci1, 1, 2, 3, 5F(n-1) + F(n-2)Spiral phyllotaxis, FX retracements
Triangular1, 3, 6, 10, 15n(n+1)/2Handshake problem, pool ball racks

Common pitfalls

  • Off-by-one on n. The nth term uses (n minus 1) as the exponent or multiplier, not n. The 1st term is a, not a plus d. Most school exam errors trace back to this slip.
  • Confusing the term with the sum. T(n) is one number, S(n) is the running total of the first n terms. Both formulas exist; mixing them is a common mistake on quiz problems.
  • Using the wrong sum formula when r equals 1. The GP sum formula divides by (1 minus r). When r is exactly 1 the series is degenerate (each term equals a) and the sum is simply n times a.
  • Assuming any infinite series converges. Only geometric series with absolute r less than 1 converge. The harmonic series 1 plus 1/2 plus 1/3 and so on diverges (it grows without bound) despite the shrinking terms.
  • Floating-point overflow on GPs. A GP with r equal to 2 reaches 2 to the 50 around term 50, which is roughly a quadrillion. After about term 60 standard 64-bit floats lose integer precision; the calculator displays exact integers only up to that limit.
  • Naive recursive Fibonacci. The recurrence F(n) is O(phi^n) if you implement it as straight recursion without memoisation. The calculator uses an iterative bottom-up loop, which is O(n) and fast for n in the thousands.

Frequently asked questions

What is an arithmetic progression and what is its formula?

An arithmetic progression (AP) is a sequence in which every term is the previous term plus a fixed number d called the common difference. The first term is a, the nth term is a plus (n minus 1) times d, and the sum of the first n terms is n divided by 2 multiplied by (2a plus (n minus 1) d). Example: 2, 5, 8, 11, 14 has a equal to 2 and d equal to 3, the 10th term is 2 plus 9 times 3 equal to 29, and the sum of the first 10 terms is 5 times 31 equal to 155.

What is a geometric progression and how does it differ from arithmetic?

A geometric progression (GP) is a sequence in which every term is the previous term multiplied by a fixed number r called the common ratio. The nth term is a times r to the power n minus 1, and the sum of the first n terms is a times (1 minus r to the n) divided by (1 minus r) when r is not 1. APs grow linearly, GPs grow or decay exponentially. The classic example is 3, 6, 12, 24, 48 with a equal to 3 and r equal to 2.

What is the Fibonacci sequence?

The Fibonacci sequence is defined by F1 equal to 1, F2 equal to 1, and F(n) equal to F(n minus 1) plus F(n minus 2) for n at least 3. The first terms are 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144. The ratio of consecutive Fibonacci numbers converges to the golden ratio phi equal to roughly 1.618, which appears in spiral arrangements in pinecones, sunflower seed heads, and nautilus shells. It was introduced to the West in Leonardo of Pisa's Liber Abaci (1202).

When does an infinite geometric series converge?

An infinite geometric series a plus ar plus a r squared plus a r cubed and so on converges to a finite sum if and only if the absolute value of the common ratio r is less than 1. The limit is a divided by (1 minus r). For example 1 plus one half plus one quarter plus one eighth converges to 2 because a equals 1 and r equals one half. If absolute r is at least 1 the series diverges to infinity, so the sum is not defined.

Where do these sequences appear in finance and computing?

Arithmetic progressions describe simple interest, salary increment ladders, and any straight-line growth. Geometric progressions describe compound interest, exponential population growth or decay, half-life of radioactive substances, and the geometric mean used in CAGR. Fibonacci numbers show up in efficient search trees (Fibonacci heaps), foreign-exchange technical analysis (Fibonacci retracements), and dynamic programming benchmarks because of their classic recursive definition.

Last updated 2026-05-28.

IT
India Tools Editorial
Calculators & explainers maintained by the India Tools team.