Solve the recurrence relation aₙ = 3aₙ₋₁ - 2aₙ₋₂ with initial conditions

hard JEE-ADVANCED JEE Advanced 2021 3 min read

Question

Solve the recurrence relation an=3an12an2a_n = 3a_{n-1} - 2a_{n-2} with initial conditions a0=1a_0 = 1 and a1=3a_1 = 3.

(JEE Advanced 2021, similar pattern)


Solution — Step by Step

For a linear recurrence an=c1an1+c2an2a_n = c_1 a_{n-1} + c_2 a_{n-2}, assume an=rna_n = r^n and substitute:

rn=3rn12rn2r^n = 3r^{n-1} - 2r^{n-2}

Divide by rn2r^{n-2}:

r2=3r2r^2 = 3r - 2 r23r+2=0r^2 - 3r + 2 = 0
r23r+2=(r1)(r2)=0r^2 - 3r + 2 = (r - 1)(r - 2) = 0

Roots: r1=1r_1 = 1 and r2=2r_2 = 2.

Since the roots are distinct, the general solution is:

an=A1n+B2n=A+B2na_n = A \cdot 1^n + B \cdot 2^n = A + B \cdot 2^n

From a0=1a_0 = 1: A+B20=1    A+B=1A + B \cdot 2^0 = 1 \implies A + B = 1

From a1=3a_1 = 3: A+B21=3    A+2B=3A + B \cdot 2^1 = 3 \implies A + 2B = 3

Subtract: B=2B = 2, so A=1A = -1.

an=2n+11\boxed{a_n = 2^{n+1} - 1}

Verification: a0=21=1a_0 = 2 - 1 = 1 ✓, a1=41=3a_1 = 4 - 1 = 3 ✓, a2=81=7a_2 = 8 - 1 = 7. Check: 3(3)2(1)=73(3) - 2(1) = 7 ✓.


Why This Works

The substitution an=rna_n = r^n works because the recurrence is linear with constant coefficients — each term is a fixed linear combination of previous terms. Exponentials are the “eigenfunctions” of such recurrences, just as they are for linear differential equations.

When the characteristic equation has distinct roots r1r_1 and r2r_2, both r1nr_1^n and r2nr_2^n satisfy the recurrence, and any linear combination Ar1n+Br2nAr_1^n + Br_2^n also satisfies it. The two initial conditions pin down the specific values of AA and BB.

If the roots were equal (repeated root rr), the general solution would be an=(A+Bn)rna_n = (A + Bn)r^n instead — the nn factor appears because we need two linearly independent solutions.


Alternative Method — Generating the sequence and spotting the pattern

Compute a few terms: a0=1,a1=3,a2=7,a3=15,a4=31a_0 = 1, a_1 = 3, a_2 = 7, a_3 = 15, a_4 = 31.

These are 211,221,231,241,2512^1 - 1, 2^2 - 1, 2^3 - 1, 2^4 - 1, 2^5 - 1. The pattern an=2n+11a_n = 2^{n+1} - 1 is clear.

For JEE, if the characteristic equation has nice integer roots, you can often spot the closed form by computing 4-5 terms and looking for a pattern. But the characteristic equation method is the rigorous approach — use it for the proof, and the pattern-spotting to verify. JEE Advanced sometimes gives recurrences where the pattern isn’t obvious, so the systematic method is essential.


Common Mistake

Students sometimes write the characteristic equation incorrectly. For an=3an12an2a_n = 3a_{n-1} - 2a_{n-2}, the equation is r23r+2=0r^2 - 3r + 2 = 0 (move everything to one side). A common error is writing r2+3r2=0r^2 + 3r - 2 = 0 — getting the signs wrong. Always rearrange as an3an1+2an2=0a_n - 3a_{n-1} + 2a_{n-2} = 0, then replace anr2,an1r,an21a_n \to r^2, a_{n-1} \to r, a_{n-2} \to 1.

Want to master this topic?

Read the complete guide with more examples and exam tips.

Go to full topic guide →

Try These Next