Quant Memo
Advanced

Nested Radicals and Infinite Fractions

An expression that repeats itself forever — a square root inside a square root inside a square root, or a fraction inside a fraction inside a fraction — can be evaluated by setting it equal to a variable and solving the equation it satisfies.

Prerequisites: The Substitution That Collapses the Algebra

What is 2+2+2+2+\sqrt{2 + \sqrt{2 + \sqrt{2 + \sqrt{2 + \cdots}}}}, with the pattern continuing forever? There's no bottom layer to start computing from — every attempt to evaluate it from the inside out just finds another identical square root waiting underneath. The trick is to stop trying to compute it layer by layer and instead notice that the whole infinite expression looks exactly like itself, one layer in.

The idea: self-similarity gives you an equation

If an infinite expression xx contains a copy of itself nested one level down, you can replace that inner copy with xx itself and solve the resulting finite equation. This works because the expression is defined as a limit of a repeating pattern — assuming that limit exists and is well-behaved, the value one layer down is the same value the whole tower converges to.

For the nested radical above, let x=2+2+2+x = \sqrt{2+\sqrt{2+\sqrt{2+\cdots}}}. Everything under the first square root is again 22 plus the same infinite radical, so:

x=2+x.x = \sqrt{2+x} .

In plain English: peeling off just the outermost square root leaves exactly the same infinite pattern underneath, so the whole thing satisfies an equation relating it to itself — an infinite object reduced to solving one algebraic equation.

Worked example 1: solving the nested radical

Square both sides of x=2+xx=\sqrt{2+x}: x2=2+xx^2 = 2+x, i.e. x2x2=0x^2 - x - 2 = 0, which factors as (x2)(x+1)=0(x-2)(x+1)=0, giving x=2x=2 or x=1x=-1. Since a square root is never negative, discard x=1x=-1: the infinite nested radical equals exactly 22. Sanity check by computing a few layers by hand: 21.41\sqrt{2}\approx1.41, 2+1.411.85\sqrt{2+1.41}\approx1.85, 2+1.851.96\sqrt{2+1.85}\approx1.96 — climbing steadily toward 22, consistent with the algebraic answer.

Worked example 2: the golden ratio as an infinite fraction

Evaluate x=1+11+11+11+x = 1 + \cfrac{1}{1+\cfrac{1}{1+\cfrac{1}{1+\cdots}}}. The pattern one layer down is again the same infinite fraction, so x=1+1xx = 1 + \dfrac{1}{x}. Multiplying through by xx: x2=x+1x^2 = x+1, i.e. x2x1=0x^2-x-1=0, which by the quadratic formula gives x=1+521.618x = \dfrac{1+\sqrt5}{2} \approx 1.618 — the golden ratio, discarding the negative root since the fraction is built from positive terms. This is the same self-similarity trick applied to a continued fraction instead of a nested radical, and it's the standard way the golden ratio shows up as "the number that equals one plus its own reciprocal."

x = √(2 + √(2 + √(2 + ...))) inner copy = whole thing x = √(2 + x) solve: x² - x - 2 = 0 → x = 2
The infinite expression contains a copy of itself one layer down, turning an unbounded computation into one finite equation to solve.

When an infinite nested expression looks like itself one layer in, set xx equal to the whole thing, substitute xx for the inner copy, and solve the resulting equation. Always discard roots that violate the expression's own constraints (negative under a square root, wrong sign from context).

This method silently assumes the infinite expression actually converges. For most well-behaved nested radicals and continued fractions built from positive terms it does, but the technique can produce a spurious finite answer for a sequence that in fact diverges — worth a quick numerical sanity check of the first few layers, as in the worked example.

Related concepts

Practice in interviews

Further reading

  • Engel, Problem-Solving Strategies, ch. 1
ShareTwitterLinkedIn