$$p^2+q^2=((2q+1)^2+q+1)^2+1$$ How do I find integer solutions to this equation? I've already found $(p,q)=(11,1)$. How do I go about finding new ones?
2026-04-06 23:25:37.1775517937
On
How to find all integer solutions of $p^2+q^2=((2q+1)^2+q+1)^2+1$
187 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
2
There are 2 best solutions below
3
On
For $q \geq 21,$ $$ (4q^2 + 5 q + 1)^2 < p^2 < (4q^2 + 5q + 2)^2 $$ because $$ q \geq 21 \Longrightarrow 41 q^2 > 40 q^2 + 20 q + 5 $$ Therefore $$ (4q^2 + 5 q + 1) < p < (4q^2 + 5q + 2) $$ and $p$ cannot be an integer.
Should be something similar for negative $q.$
Yes, $$ q \leq -3 \Longrightarrow 0 < 7 q^2 + 20 q + 5, $$ so both sides of the inequality work. Also, we get the necessary $4 q^2 + 5 q> 0$ when $q \leq -3.$
Here is page 268 in Mordell's book, Diophantine Equations. He gives the few examples where all solutions can be found (but no inequalities apply) in the following pages.

$$\begin{align}p^2+q^2&=((2q+1)^2+q+1)^2+1\\\implies p^2+q^2&=16q^4+40q^3+41q^2+20q+5 \\\implies p^2&=16q^4+40q^3+40q^2+20q+5\end{align}$$
So for an integer $q$ if $16q^4+40q^3+40q^2+20q+5$ is a perfect square, then you will get integer solutions for your equation.
So $(11,1)$ and $(1,-1)$ are solutions, others may exist.