Courses
Courses for Kids
Free study material
Offline Centres
More
Store Icon
Store

Recurrence Relation in Discrete Mathematics

Reviewed by:
ffImage
hightlight icon
highlight icon
highlight icon
share icon
copy icon

How to Solve Recurrence Relation with Formula and Examples

The concept of Recurrence Relation plays a key role in mathematics and is widely applicable to both real-life situations and exam scenarios. If you want to master topics in sequences, series, problem-solving, and even programming algorithms, understanding recurrence relations is essential. Vedantu makes these concepts simple with clear explanations and step-by-step examples.


What Is Recurrence Relation?

A recurrence relation is defined as an equation that recursively defines a sequence where each term is given as a function of one or more previous terms. You’ll find this concept applied in areas such as discrete mathematics, computer science (for algorithm analysis), and sequence patterns like the Fibonacci series. In simple words, if you know some starting values, a recurrence lets you work out the rest of the sequence step-by-step.


Key Formula for Recurrence Relation

Here’s the standard formula: \( a_n = f(a_{n-1}, a_{n-2}, ..., a_{n-k}) \)

For example, the classic Fibonacci sequence is defined by the recurrence:

\( F(n) = F(n-1) + F(n-2), \) with \( F(0) = 0, F(1) = 1 \)


Types of Recurrence Relations

Type Description Example
Linear Homogeneous Depends only on previous terms, combined linearly, and equals zero. \( a_n = 2a_{n-1} - a_{n-2} \)
Linear Non-Homogeneous Includes an extra function (like n or a constant). \( a_n = a_{n-1} + 3 \)
Nonlinear Recurrence Involves powers, roots, products, or divides. \( a_n = a_{n-1} \times a_{n-2} \)
Divide and Conquer Type Used in algorithms, splits problems into parts. \( T(n) = 2T(n/2) + n \) (Merge Sort)

Cross-Disciplinary Usage

Recurrence relation is not only useful in Maths but also plays an important role in Physics, Computer Science, and daily logical reasoning. Students preparing for JEE, Olympiads, or even school-level coding questions will find their understanding tested with recurrence concepts, especially when analyzing recursive algorithms or proving sequence formulas.


Step-by-Step Illustration

Let’s see how to solve a simple linear recurrence relation:

Example: Solve the recurrence \( a_n = a_{n-1} + 2 \), with \( a_1 = 3 \).

  1. Start with the initial condition:
    \( a_1 = 3 \)

  2. Calculate next terms step-by-step:
    \( a_2 = a_1 + 2 = 3 + 2 = 5 \)
    \( a_3 = a_2 + 2 = 5 + 2 = 7 \)
    \( a_4 = a_3 + 2 = 7 + 2 = 9 \)

  3. Notice the pattern: The sequence increases by 2 each time. The closed-form is \( a_n = 2n + 1 \).

How to Solve Recurrence Relations

There are several methods to solve recurrence relation problems in maths:

  • Iteration (repeatedly expand to observe the sequence)
  • Substitution (guess the formula, prove by induction)
  • Using the Characteristic Equation (for linear cases)
  • Master Theorem (for divide and conquer recurrences in algorithms)

Let’s solve \( T(n) = 2T(n/2) + n \) with \( T(1) = 1 \) (like Merge Sort):

1. Each time, the problem is divided into 2 parts of size n/2 and you spend n time to merge.

2. If you expand a couple of levels:

\( T(n) = 2T(n/2) + n \)
\( = 2[2T(n/4) + n/2] + n = 4T(n/4) + 2n + n = 4T(n/4) + 3n \)

3. Continue until you hit the base case.

4. In general, result: \( T(n) = O(n \log n) \) (using the Master Theorem).

Speed Trick or Exam Shortcut

For certain types of recurrence relation, like linear with constant differences, you can quickly spot the answer by recognizing patterns. For "add c every time", the sequence goes up by c – so in the form \( a_n = a_1 + (n-1)c \).

Example Trick: If you see \( a_n = a_{n-1} + 5, a_1 = 2 \), then \( a_{10} = 2 + 9 \times 5 = 47 \).


More tricks and pattern spotting are regularly taught in Vedantu’s live classes, making competitive exam prep easier!


Try These Yourself

  • Write the first five terms defined by \( a_n = 3a_{n-1} - 2 \) with \( a_1 = 1 \).
  • Find the closed-form for \( b_n = b_{n-1} + 4 \) with \( b_1 = 2 \).
  • Solve \( T(n) = 2T(n-1) + 1, T(1) = 1 \).

Frequent Errors and Misunderstandings

  • Forgetting the initial conditions when solving a recurrence relation.
  • Mixing up recurrence relations with direct formulas.
  • Using the wrong method (e.g., Master Theorem for non-divide-and-conquer problems).

Relation to Other Concepts

The idea of Recurrence Relation connects closely with topics such as Fibonacci Sequence and Master Theorem. Mastering recurrence also builds the foundation for understanding difference equations, recursion in programming, and sequences in higher algebra.


Classroom Tip

A quick way to remember Recurrence Relation is to treat it as a "recipe" for generating sequences: start with initial values, then follow the recipe at each step. Vedantu’s teachers use lots of visuals and flowcharts to show how each value is built from earlier ones, making it less confusing!


We explored Recurrence Relations — from definition, types and formulas to worked examples and exam shortcuts. Continue practicing and using Vedantu’s interactive worksheets to become confident in using recurrence relations for maths, computer science, and beyond.


To learn more, check out these related topics:


FAQs on Recurrence Relation in Discrete Mathematics

1. What is a recurrence relation in mathematics?

A recurrence relation is an equation that defines each term of a sequence using one or more previous terms. It expresses a sequence recursively instead of giving a direct formula.

For example:

  • aₙ = aₙ₋₁ + 3 with a₁ = 2
This means each term is 3 more than the previous one. Recurrence relations are widely used in discrete mathematics, algorithms, and sequence analysis.

2. What is the general form of a recurrence relation?

The general form of a recurrence relation is aₙ = f(aₙ₋₁, aₙ₋₂, …, aₙ₋k), where each term depends on previous terms.

Here:

  • aₙ is the current term
  • aₙ₋₁, aₙ₋₂, … are previous terms
  • k is the order of the recurrence relation
To uniquely determine the sequence, initial conditions like a₀ or a₁ must also be given.

3. What is the difference between a recurrence relation and an explicit formula?

A recurrence relation defines a term using previous terms, while an explicit formula gives a direct expression for the nth term.

For example:

  • Recurrence: aₙ = aₙ₋₁ + 2, a₁ = 1
  • Explicit: aₙ = 2n − 1
The explicit formula allows you to compute any term directly without calculating earlier terms.

4. How do you solve a first-order linear recurrence relation?

A first-order linear recurrence relation of the form aₙ = r aₙ₋₁ is solved using exponential patterns.

If a₀ is given, the solution is:

  • aₙ = a₀ rⁿ
Example:
  • If aₙ = 2aₙ₋₁, a₀ = 3
  • Then aₙ = 3·2ⁿ
This type commonly appears in geometric sequences.

5. What is a homogeneous recurrence relation?

A homogeneous recurrence relation is one in which all terms depend only on previous sequence terms and not on external functions.

Example:

  • aₙ − 3aₙ₋₁ + 2aₙ₋₂ = 0
There is no extra constant or function on the right-hand side. These are commonly solved using characteristic equations.

6. What is a non-homogeneous recurrence relation?

A non-homogeneous recurrence relation includes an additional term that does not depend on previous sequence values.

Example:

  • aₙ − 2aₙ₋₁ = 5
The constant 5 makes it non-homogeneous. These are solved by finding the complementary solution and a particular solution.

7. What is the Fibonacci recurrence relation?

The Fibonacci recurrence relation is defined as Fₙ = Fₙ₋₁ + Fₙ₋₂ with F₀ = 0 and F₁ = 1.

This means each term is the sum of the two preceding terms:

  • F₂ = 1
  • F₃ = 2
  • F₄ = 3
The Fibonacci sequence appears in combinatorics, computer science, and natural growth patterns.

8. How do you find the characteristic equation of a recurrence relation?

The characteristic equation is formed by replacing aₙ with rⁿ in a linear homogeneous recurrence relation.

For example:

  • Given aₙ − 3aₙ₋₁ + 2aₙ₋₂ = 0
  • Assume solution aₙ = rⁿ
  • Characteristic equation: r² − 3r + 2 = 0
Solving gives r = 1, 2, leading to the general solution aₙ = C₁·1ⁿ + C₂·2ⁿ.

9. What is the order of a recurrence relation?

The order of a recurrence relation is the number of previous terms used to define the current term.

Examples:

  • aₙ = aₙ₋₁ + 4 → Order 1
  • aₙ = aₙ₋₁ + aₙ₋₂ → Order 2
The highest backward step (largest subscript difference) determines the order.

10. What are recurrence relations used for?

Recurrence relations are used to model sequences, algorithms, and discrete processes where each step depends on previous steps.

Common applications include:

  • Analysis of algorithms (time complexity)
  • Modeling population growth
  • Financial calculations like compound interest
  • Combinatorics and counting problems
They are fundamental in discrete mathematics and computer science.