TITLE: If $2^{2k}-x^2\bigm|2^{2k}-1$ then $x=1$
QUESTION [14 upvotes]: This is the $y=2^k$ case of this question.
Suppose that $k\geq1$ and $0<x<2^k$ and $2^{2k}-x^2\bigm|2^{2k}-1$. Is it necessarily the case that $x=1$?
Equivalently: Suppose that there are two positive divisors of $2^{2k}-1$ which average to $2^k$. Is it necessarily the case that these two divisors are $2^k-1$ and $2^k+1$?

REPLY [4 votes]: I continue from Thomas Browning's (the author of the question) answer. We desire to show that
$$nx^2-4(n-1)y^2=1$$
has no solutions. Note that any solution must satisfy $\gcd(nx,y)=1$. We can rewrite the equation as
$$(nx)^2-4n(n-1)y^2=n,$$
so if
$$x^2-4n(n-1)y^2=n$$
has no solutions with $\gcd(x,y)=1$ then we're done. I'm going to prove that using the fact that
$$\frac xy\approx \sqrt{4n(n-1)}\approx 2n$$
and then squeezing the inequalities together and proving that they're too tight to hold. This corner of number theory is called Diophantine Approximation, and I happen to know about it. Start with
$$\sqrt{4n(n-1)}=[2(n-1);\overline{1,4(n-1)}]$$
This is easier to prove backwards. Let
$$t=2(n-1)+\frac 1{1+\frac 1{t+2(n-1)}}$$
and then it's easy to find that the positive solution is $t=\sqrt{4n(n-1)}$.
Also if
$$x^2-dy^2=n$$
then
$$\frac xy=\sqrt{d+\frac n{y^2}}=\sqrt{d}\sqrt{1+\frac n{dy^2}}$$
$$\frac xy-\sqrt{d}<\frac n{2\sqrt{d}y^2}$$
In our case $n>0$ and $d=4n(n-1)$ so
$$0<\frac xy-\sqrt{4n(n-1)}<\frac 1{4y^2\sqrt{1-1/n}}$$
Now from Hardy and Wright intro to number theory page 153:
Theorem 184. If
$$\left|\frac pq -x\right|<\frac 1{2q^2}$$
then $p/q$ is a convergent.
Note that when H&W say convergent they require it to be in lowest terms. Which is true of our previous expression, so $x/y$ is a convergent of $\sqrt{4n(n-1)}$. But the residues $x^2-dy^2$ left by a convergent $\frac xy$ to the continued fraction of $\sqrt d$ are periodic with the same period as the continued fraction itself. You can verify that when $d=4n(n-1)$ the residues are $1$ and $-4(n-1)$.
\begin{align*}
[2(n-1)]&=\frac{2(n-1)}1                   &(2(n-1))^2-4n(n-1)1^2&=-4(n-1)\\
[2(n-1);1]&=\frac{2n-1}1                   &(2n-1)^2-4n(n-1)1^2&=1\\
[2(n-1);1,4(n-1)]&=\frac{8n^2-10n+2}{4n-3} &(8n^2-10n+2)^2-4n(n-1)(4n-3)^2&=-4(n-1)\\
[2(n-1);1,4(n-1),1]&=\frac{8n^2-8n+1}{4n-2}&(8n^2-8n+1)^2-4n(n-1)(4n-2)^2&=1\\
[2(n-1);1,4(n-1),1,4(n-1)]&=\frac{32n^3-56n^2+26n-2}{16n^2-20n+5}&(\dots)^2-4n(n-1)(\dots)^2&=-4(n-1)
\end{align*}
So $n$ can never be a residue, therefore our equation has no solution.