Overview

Vieta Jumping (also called root flipping) is an advanced technique where we perform fermats's infinite descent with the usual goal of showing there exists finite solutions to a diophantine equations however with a twist where the descent is performed on the roots of a quadriatic expression where the roots are usually the solutions to the equation. The roots are found by vieta and hence the name 'Vieta Jumping'.

Key Idea

First we have a diophantine equation which is symmetric and we want to perform the vita jump on it. Let us represent this by f(a,b)=kf(a,b)=k with degree 2. Degree 1 is left out as that will result a linear diophantine equation which can be solved by standard methods. Now we can form a quadriatic equation with either aa or bb as the subject and kk as the value of the diophantine equation.

One such example is shown below

a2−(kb) a+(b2−k)=0a^2 - (kb)\,a + (b^2 - k) = 0

We know that any quadriatic equation has 2 roots. Hence we know there is another solution to the equation we constructed before. Let the equations subject be represented by tt where the roots of it are aa and xx.

t2−(kb) t+(b2−k)=0t^2 - (kb)\,t + (b^2 - k) = 0

Clearly xx is also a value that satisfies f(x,b)=kf(x,b)=k. A important step is to make sure that x<ax < a, x∈Zx \in \mathbb{Z} and that x>0x>0 which can be proven using simple inequalities(We find the value of xx via vieta's relations). Else we cannot perform a descent.

Okay we got (x,b)(x,b) as a solution, now what? well we can again make the quadriatic equation but this time with bb as the subject! and there will be no problems since the equation is symmetric in the first place. This is sufficient to show a descent and after that we continue with the standard fermat's descent to find the solutions, prove the solution set is finite or for contradiction. (The most popular is contradiction, which is outlined below)

Steps to Reproduce

Here is the standard structure of a Vieta Jumping argument (This is only for reference and not for forced memorisation):

  1. Define kk. Let k=f(a,b)k = f(a,b) where ff is the expression asserted to be an integer (or a specific value).
  2. Fix kk, take the minimal pair. Among all pairs (a,b)(a, b) of positive integers with f(a,b)=kf(a, b) = k, choose the one minimizing a+ba + b (or just aa after WLOG a≥ba \geq b).
  3. Form the quadratic. Rearrange the equation into a quadratic in aa: the existing value aa is one root.
  4. Produce the second root. Let xx be the other root. By Vieta's sum formula, x=(something)−a∈Zx = (\text{something}) - a \in \mathbb{Z}.
  5. Show x>0x > 0. Use the product formula xa=(constant)xa = (\text{constant}). If kk is not a perfect square or if the constant is positive, show x≠0x \neq 0; rule out x<0x < 0 separately.
  6. Show x<ax < a. Use the assumption a≥ba \geq b and the product formula: x=b2−ka≤a2−ka<ax = \frac{b^2 - k}{a} \leq \frac{a^2 - k}{a} < a.
  7. Conclude. The pair (x,b)(x, b) satisfies the same relation with x+b<a+bx + b < a + b, contradicting minimality. Hence no such pair exists (or kk must equal the forced value).

Worked Examples

Example 1 (IMO 1988 Problem 6). Let a,ba, b be positive integers such that ab+1∣a2+b2ab + 1 \mid a^2 + b^2. Prove that a2+b2ab+1\dfrac{a^2 + b^2}{ab + 1} is a perfect square.

Proof. Let k=a2+b2ab+1k = \dfrac{a^2+b^2}{ab+1}. We want to show kk is always a perfect square.

Suppose for contradiction that kk is a fixed positive integer that is not a perfect square, and that there exists at least one pair (a,b)(a,b) of non-negative integers with a2+b2ab+1=k\frac{a^2+b^2}{ab+1} = k. Pick the pair (a,b)(a, b) with a≥b≥0a \geq b \geq 0 that minimizes aa.

Rewrite the equation as a2+b2=k(ab+1)a^2 + b^2 = k(ab + 1), then rearrange into a quadratic in aa:

a2−kb a+(b2−k)=0a^2 - kb\,a + (b^2 - k) = 0

The value aa is one root. Let xx be the other root. By Vieta's formulas:

  • Sum: x+a=kbx + a = kb, so x=kb−a∈Zx = kb - a \in \mathbb{Z}.
  • Product: x⋅a=b2−kx \cdot a = b^2 - k, so x=b2−kax = \dfrac{b^2 - k}{a}.

Since xx is an integer satisfying the same quadratic, the pair (x,b)(x, b) satisfies x2−kbx+(b2−k)=0x^2 - kbx + (b^2 - k) = 0, which means x2+b2=k(xb+1)x^2 + b^2 = k(xb + 1), i.e., x2+b2xb+1=k\frac{x^2 + b^2}{xb + 1} = k — so (x,b)(x, b) is also a valid solution, provided x≥0x \geq 0 and xb+1>0xb + 1 > 0.

x≠0x \neq 0: If x=0x = 0, then xa=b2−k=0xa = b^2 - k = 0, so k=b2k = b^2, contradicting our assumption that kk is not a perfect square.

x≥0x \geq 0: Suppose x<0x < 0. Then x2+b2=k(xb+1)x^2 + b^2 = k(xb + 1). The left side is positive. We need xb+1>0xb + 1 > 0, i.e., x>−1/bx > -1/b — but xx is a negative integer, so x≤−1x \leq -1, giving xb≤−b≤0xb \leq -b \leq 0, so xb+1≤1xb + 1 \leq 1. Combined with x2+b2>0x^2 + b^2 > 0, we need xb+1>0xb + 1 > 0, i.e., xb≥0xb \geq 0. Since x<0x < 0 and b≥1b \geq 1, this is impossible. So x≥0x \geq 0, and since x≠0x \neq 0, we have x>0x > 0.

x<ax < a: Since a≥b≥1a \geq b \geq 1:

x=b2−kax = \frac{b^2 - k}{a}

We need to show this is less than aa. Note k≥1k \geq 1, so b2−k≤b2−1<b2≤a2b^2 - k \leq b^2 - 1 < b^2 \leq a^2, giving x=b2−ka<a2a=ax = \frac{b^2-k}{a} < \frac{a^2}{a} = a.

But then (x,b)(x, b) is a valid pair achieving the same kk, with x<ax < a — contradicting the minimality of aa. Therefore, no non-perfect-square value of kk is achievable, and kk must be a perfect square. ■\blacksquare

Example 2. Let a,ba, b be positive integers with ab∣a2+b2+1ab \mid a^2 + b^2 + 1. Show that a2+b2+1ab=3\dfrac{a^2 + b^2 + 1}{ab} = 3.

Proof. Let k=a2+b2+1abk = \frac{a^2+b^2+1}{ab}. First handle the diagonal: if a=ba = b, then a2∣2a2+1a^2 \mid 2a^2 + 1, so a2∣1a^2 \mid 1, forcing a=b=1a = b = 1 and k=3k = 3. Now assume a>b≥1a > b \geq 1 and pick the minimal-sum pair.

Rearrange as a quadratic in aa:

a2−kb a+(b2+1)=0a^2 - kb\,a + (b^2 + 1) = 0

The value aa is one root; let xx be the other. By Vieta's:

  • Sum: x=kb−a∈Zx = kb - a \in \mathbb{Z}.
  • Product: xa=b2+1>0xa = b^2 + 1 > 0.

Since xa=b2+1>0xa = b^2 + 1 > 0 and a>0a > 0, we have x>0x > 0.

x<ax < a: Since a>ba > b:

x=b2+1a<b2+1b=b+1b≤b+1≤ax = \frac{b^2 + 1}{a} < \frac{b^2 + 1}{b} = b + \frac{1}{b} \leq b + 1 \leq a

So (x,b)(x, b) is a valid pair with x<ax < a, contradicting minimality — unless no such pair with a>ba > b exists. The descent terminates when a=ba = b, which forces k=3k = 3 as shown above. Therefore k=3k = 3 for all valid pairs. ■\blacksquare

Common Pitfalls

Forgetting to prove x>0x > 0. The extremal argument only produces a contradiction if the new solution is a valid pair of positive integers. Always prove x>0x > 0, or handle x=0x = 0 as an explicit base case.

Skipping a=ba = b. The bound x<ax < a uses a>ba > b. The equality case a=ba = b must always be checked first, this often forces the answer immediately.

Not verifying the new pair satisfies the relation. Check that (x,b)(x, b) (not just (a,b)(a, b)) satisfies the original equation before claiming it's a valid smaller solution.

Negative variables. The extremal principle requires a+ba + b to be bounded below. If the problem allows negative integers, the descent has no floor. Establish that any solution can be transformed to a positive one before applying the method.

Practice Problems

StatusSourceProblem NameDifficultyTags
Berkeley Math CircleHard
Show TagsInfinite descent / root flipping, Techniques: modulo, size analysis, order analysis, inequalities
Berkeley Math CircleHard
Show TagsInfinite descent / root flipping, Pell's equations, Quadratic fields
Berkeley Math Circle Monthly Contest 2Hard
Show TagsComplex numbers, Infinite descent / root flipping, Techniques: modulo, size analysis, order analysis, inequalities
BAMOHard
Show TagsGreatest common divisors (gcd), Infinite descent / root flipping, Linear and quadratic inequalities, Recurrence relations
Berkeley Math CircleHard
Show TagsCartesian coordinates, Infinite descent / root flipping, Techniques: modulo, size analysis, order analysis, inequalities
USA IMOHard
Show TagsGreatest common divisors (gcd), Infinite descent / root flipping, Pell's equations, Recurrence relations, Techniques: modulo, size analysis, order analysis, inequalities
Harvard-MIT Mathematics TournamentHard
Show TagsFactorization techniques, Infinite descent / root flipping, Polynomial operations, Techniques: modulo, size analysis, order analysis, inequalities
IMOHard
Show TagsGreatest common divisors (gcd), Infinite descent / root flipping, Polynomial operations
Team Selection Test 2009Hard
Show TagsInfinite descent / root flipping, Techniques: modulo, size analysis, order analysis, inequalities, Vieta's formulas
Berkeley Math Circle: Monthly Contest 5Hard
Show TagsInfinite descent / root flipping, Vieta's formulas
February 2017Hard
Show TagsInfinite descent / root flipping, Quadratic functions, Techniques: modulo, size analysis, order analysis, inequalities
Berkeley Math CircleHard
Show TagsInfinite descent / root flipping, Invariants / monovariants
HMMT February 2019Hard
Show TagsFloors and ceilings, Infinite descent / root flipping, Recurrence relations, Telescoping series, Vieta's formulas
MathNetHard
Show TagsQuadratic functions, Vieta's formulas
Berkeley Math Circle Take-Home Contest #1Hard
Show TagsComplex numbers, Roots of unity, Vieta's formulas
Berkeley Math Circle Monthly Contest 5Hard
Show TagsPolynomial operations, Symmetric functions, Vieta's formulas
Berkeley Math Circle Monthly Contest 8Hard
Show TagsQuadratic functions, Vieta's formulas
Berkeley Math CircleHard
Show TagsGreatest common divisors (gcd), Techniques: modulo, size analysis, order analysis, inequalities, Vieta's formulas
Berkeley Math Circle Monthly Contest 1Hard
Show TagsComplex numbers, Recurrence relations, Symmetric functions, Vieta's formulas
HMMT 1998Hard
Show TagsVieta's formulas
Harvard-MIT Math TournamentHard
Show TagsLinear and quadratic inequalities, Pigeonhole principle, Quadratic functions, Vieta's formulas
Harvard-MIT Math TournamentHard
Show TagsGreatest common divisors (gcd), Vieta's formulas
Berkeley Math CircleHard
Show TagsPolynomial operations, Symmetric functions, Vieta's formulas
Harvard-MIT Math TournamentHard
Show TagsVieta's formulas
Harvard-MIT Math TournamentHard
Show TagsPolynomial operations, Vieta's formulas

Module Progress:

Join the Discord Community!

Stuck on a problem, or don't understand a module? Join the Discord and get help with your doubts while making more math friends.