Jed Thompson
1 min readMar 8, 2017

--

It’s a neat problem, and you’re not the first to think so!

I found it easiest to write the equation as a²-b²c = 1. Then it’s clear that for fixed c, this is a quadratic Diophantine equation problem. At this point I searched Diophantine equation examples to see if anyone had solved this particular one already. It turns out the answer is yes, both in India in the 1100s and later in the 1600s by Fermat and Lagrange. The equation is called Pell’s equation, and is known to have infinitely many solutions (a, b) for c not a perfect square. A general algorithm is given at https://en.wikipedia.org/wiki/Pell%27s_equation.

--

--