---
abstract: |
    We generalise and improve a result of Stoll, Walsh and Yuan by showing that there are at most two solutions in coprime positive integers of the equation in the title when $b=p^{m}$ where $m$ is a non-negative integer, $p$ is prime, $(a,p)=1$, $a^{2}+p^{2m}$ not a perfect square and $x^{2}- \left( a^{2}+p^{2m} \right) y^{2}=-1$ has an integer solution. This result is best possible. We also obtain best possible results for all positive integer solutions when $m=1$ and $2$.

    When $b$ is an arbitrary square with $(a,b)=1$ and $a^{2}+b^{2}$ not a perfect square, we are able to prove there are at most three solutions in coprime positive integers provided $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-1$ has an integer solution and $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-b^{2}$ has only one family of solutions. Our proof is based on a novel use of the hypergeometric method that may also be useful for other problems.
address: 'London, UK'
author:
- Paul M Voutier
title: 'Sharp bounds on the number of solutions of $X^{2}-\left( a^{2}+b^{2} \right) Y^{4}=-b^{2}$'
---

Introduction
============

Diophantine equations of the form $aX^{2}-bY^{4}=c$ are linked to several important areas in number theory. They are a quartic model of elliptic curves, for example. They are also associated with squares in binary recurrence sequences too.

Ljunggren (see [@L1; @L2; @L3; @L4] for some of his many results) made significant contributions to the study of the integer solutions of such equations, especially when $a$, $b$ are positive integers and $c=\pm 1,
\pm 2, \pm 4$. They have been the subject of much attention since then too (see, for example, Akhtari’s result [@Akh] and the references there). For other values of $c$, the study of such equations appears to be much more difficult.

In 2009, Stoll, Walsh and Yuan [@SWY] showed that for any non-negative integer $m$, there are at most three solutions in odd positive integers to $$X^{2} - \left( 1+2^{2m} \right) Y^{4} = -2^{2m}.$$

Here we generalise, and improve, their result to the equation $$\label{eq:2}
X^{2} - \left( a^{2}+b^{2} \right) Y^{4} = -b^{2},$$ under the conditions stated in our theorems below.

\[thm:1.1\] Let $a$, $m$ and $p$ be non-negative integers with $a \geq 1$, $p$ a prime, $\gcd \left( a,p^{m} \right)=1$ and $a+p^{2m}$ not a perfect square. Suppose $x^{2}- \left( a^{2}+p^{2m} \right) y^{2}=-1$ has a solution. Then $\eqref{eq:2}$ has at most two coprime positive integer solutions.

Note that the conditions in Theorem \[thm:1.1\] are always satisfied for $a=1$ and $p=2$, so the results here to include, and improve, the results in [@SWY].

\[rem:1\] Theorem \[thm:1.1\] is best possible. One can find infinitely many examples of $a,m$ and $p$ such that there are two solutions in coprime positive integers.

Example 1: let $b$ be any odd positive integer not divisible by $5$ and $a=\left( b^{2}-5 \right)/4$. Then we have the obvious solution, $(a,1)$, of . The fundamental solution of the negative Pell equation here is $\left( a+2, 1 \right)$, so $\left( a+\sqrt{a^{2}+b^{2}} \right) \left( (a+2) + \sqrt{a^{2}+b^{2}} \right)^{2}$ gives rise, after simplifying, to another solution, $\left( \left( b^{6}+5b^{4}+15b^{2}-5 \right)/16, \left( b^{2}+1 \right) /2 \right)$, of .

Example 2: let $b$ be any odd positive integer and $a=\left( 5b^{2}-1 \right)/4$. also has two solutions.

In addition to the obvious solution, $(a,1)$, of , we also have the following solution, $\left( \left( 3125b^{6}+625b^{4}+75b^{2}-1 \right)/16, \left( 25b^{2}+1 \right)/2 \right)$.

Of course, it would be satisfying to remove the condition that the coordinates of the integer solutions be coprime. We have not been able to do that in the same generality as in Theorems \[thm:1.1\], but we have been able to prove the following.

\[cor:1.1\] Let $a$, $m$ and $p$ be positive integers with $a \geq 1$, $m=1,2$, $p$ a prime, $\gcd \left( a,p \right)=1$ and $a^{2}+p^{2m}$ not a perfect square. Suppose $x^{2}- \left( a^{2}+p^{2m} \right) y^{2}=-1$ has a solution. Then $\eqref{eq:2}$ has at most three positive integer solutions.

(of Corollary \[cor:1.1\]) From Theorem \[thm:1.1\], we know there are at most two coprime solutions.

If there is a solution with $\gcd(x,y) \neq 1$, then for both $m=1$ and $m=2$, we can remove the common factors to get $-1$ on the right-hand side. We can now appeal to Theorem D of [@Chen1] to show there is at most one such solution.

Corollary \[cor:1.1\] is also best possible.

We can use Example 1 in Remark \[rem:1\] to see this. Suppose $b$ there is a perfect square, $b=b_{1}^{2}$. In addition to the two solutions given in Remark \[rem:1\], we also have the solution $\left( \left( b^{3}+3b \right)/4, b_{1} \right)$.

We only found one example with $b$ prime and three solutions, namely $a=31$, $b=5$ with the solutions $(31, 1)$, $(785, 5)$, $(3076289, 313)$.

It is natural to wonder what happens when $p^{m}$ is replaced by any positive integer $b$. Our technique here can be used to show that Theorem \[thm:1.1\] and Corollary \[cor:1.1\] are both true if we replace $p^{m}$ with $2p^{m}$. The proof is nearly identical to what follows, so we have not pursued this here.

We are also able to prove the following result.

\[thm:1.2\] Let $a$ and $b$ be relatively prime positive integers such that $a^{2}+b^{2}$ is not a perfect square. Suppose $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-1$ has a solution and that all coprime integer solutions $(x,y)$ to the quadratic equation $$\label{eq:quad-eqnc}
x^{2} - \left( a^{2}+b^{2} \right)y^{2}=-b^{2}$$ are given by $$\label{eq:14c}
x+y \sqrt{a^{2}+b^{2}} = \pm \left( \pm a + \sqrt{a^{2}+b^{2}} \right)
\alpha^{2k}, \hspace{1.0mm} k \in {\mathbb{Z}},$$ where $\alpha = \left( T_{1}+U_{1} \sqrt{a^{2}+b^{2}} \right)/2$ and $\left( T_{1},U_{1} \right)$ is the minimum solution of the equation $x^{2}-\left( a^{2}+b^{2} \right)y^{2}=-4$ in positive integers.

Then $\eqref{eq:2}$ has at most three coprime positive integer solutions.

We have not been able to find any equations satisfying these conditions that have three solutions, so we believe that there are at most two coprime solutions of such equations too.

It would also be of interest to eliminate the condition that $x^{2}- \left( a^{2}+p^{2m} \right) y^{2}=-1$ has a solution. However, we have not been able to do so. The obstacle is that Lemma \[lem:3.2aa\] is no longer true without that condition. An example where this fails is provided in the remark after Lemma \[lem:3.2aa\].

Diophantine Approximation via Hypergeometric Functions
======================================================

Recall that by an [*effective irrational measure*]{} for an irrational number, $\alpha$, we mean an inequality of the form $$\left| \alpha - \frac{p}{q} \right|>\frac{c}{|q|^{\mu}},$$ for all $p/q \in {\mathbb{Q}}$ with $\gcd(p,q)=1$ and $|q|>Q$, where $c$, $Q$ and $\mu$ are all effectively computable.

By Liouville’s famous result [@Liou], where he constructed the first examples of numbers proven to be transcendental, we have such effective irrational measures for algebraic numbers of degree $n$, with $\mu=n$. But for most applications we require $\mu<n$.

We can use the hypergeometric method to obtain effective irrationality measures that improve on Liouville’s result for the algebraic numbers that arise here. However, that does not suffice for us to prove our theorem. The problem here arises not because of the exponent, $\mu$, in the effective irrationality measure, but because the constant, $c(\alpha)$, is too large. Upon investigating this further, we found that we can complete the proof of Theorem \[thm:1.1\] if we use not the effective irrationality measures from the hypergeometric method, but rather consider more carefully the actual results that we obtain from the use of hypergeometric functions.

The means of doing so is the following lemma.

\[lem:2.1\] Let $\theta \in {\mathbb{C}}$ and let ${\mathbb{K}}$ be an imaginary quadratic field. Suppose that there exist $k_{0},\ell_{0} > 0$ and $E,Q > 1$ such that for all non-negative integers $r$, there are algebraic integers $p_{r}$ and $q_{r}$ in ${\mathbb{K}}$ with $\left| q_{r} \right| < k_{0}Q^{r}$ and $\left| q_{r} \theta - p_{r} \right| \leq \ell_{0}E^{-r}$ satisfying $p_{r}q_{r+1} \neq p_{r+1}q_{r}$.

For any algebraic integers $p$ and $q$ in ${\mathbb{K}}$, let $r_{0}$ be the smallest positive integer such that $|q|<E^{r_{0}}/ \left( 2 \ell_{0} \right)$.

[(a)]{} We have $$\left| q\theta - p \right| 
> \frac{1}{2k_{0}Q^{r_{0}+1}}.$$

[(b)]{} When $p/q \neq p_{r}/q_{r}$, we have $$\left| q\theta - p \right| 
> \frac{1}{2k_{0}Q^{r_{0}}}.$$

We can improve the constants here somewhat, replacing $1/\left( 2k_{0} \right)$ in both parts by $\left( 1-1/E \right)/k_{0}$ and defining $r_{0}$ by $\left( Q-1/E  \right)/\left( Q-1 \right)\ell_{0}|q|<E^{r_{0}}$.

This would be helpful when reducing the size of $c$ here is important. This would have reduced the size of the bound on $a^{2}+b^{2}$ in Case 3 of Lemma \[lem:thm\] below. But as the remaining calculation to finish the proof of Lemma \[lem:thm\] is so quick, we have not pursued this here.

The proof is identical to that of Lemma 6.1 of [@V2] except at the end of the proof we do not convert the lower bounds into ones involving $|q|^{-(\kappa+1)}$.

Construction of Approximations
------------------------------

\

Let $t, u_{1}$ and $u_{2}$ be rational integers with $t<0$. We let $u=\left( u_{1}+u_{2}\sqrt{t} \right)/2$ be an algebraic integer in ${\mathbb{K}}={\mathbb{Q}}\left( \sqrt{t} \right)$ with $\sigma(u)=\left( u_{1}-u_{2}\sqrt{t} \right)/2$ as its algebraic (and complex) conjugate. Put $\omega = u/\sigma(u)$ and write $\omega=e^{i\varphi}$, where $-\pi<\varphi \leq \pi$. For any real number $\nu$, we shall put $\omega^{\nu}= e^{i\nu\varphi}$.

Suppose that $\alpha, \beta$ and $\gamma$ are complex numbers and $\gamma$ is not a non-positive integer, ${}_{2}F_{1}(\alpha, \beta, \gamma, z)$ shall denote the classical (or Gauss) hypergeometric function of the complex variable $z$.

For positive integers $m$ and $n$ with $0 < m < n$, $(m,n) = 1$ and $r$ a non-negative integer, we put $\nu=m/n$ and $$X_{m,n,r}(z)={}_{2}F_{1}(-r-\nu, -r, 1-\nu, z), \quad
Y_{m,n,r}=z^{r}X_{m,n,r} \left(z^{-1} \right)$$ and $$\begin{aligned}
R_{m,n,r}(z) &= \frac{\Gamma(r+1+\nu)}{r!\Gamma(\nu)} \int_{1}^{z} (1-t)^{r}(t-z)^{r}t^{-r-1+\nu}dt \\
&= (z-1)^{2r+1} \frac{\nu \cdots (r+\nu)}{(r+1) \cdots (2r+1)} 
           {} _{2}F_{1} \left( r+1-\nu, r+1; 2r+2; 1-z \right),\end{aligned}$$ where $0$ is not on the path of integration from $1$ to $z$.

We collect here some facts about these functions that we will require.

\[lem:2.2\] [(a)]{} Suppose that $|\omega-1|<1$. We have $$\omega^{\nu}Y_{m,n,r}(\omega)-X_{m,n,r}(\omega)=R_{m,n,r}(\omega).$$

[(b)]{} We have $$X_{m,n,r}(\omega)Y_{m,n,r+1}(\omega) \neq X_{m,n,r+1}(\omega)Y_{m,n,r}(\omega).$$

[(c)]{} If $|\omega|=1$ and $|\omega-1|<1$, then $$\left| R_{m,n,r}(\omega) \right|
\leq \frac{\Gamma(r+1+\nu)}{r!\Gamma(\nu)} |\varphi| \left| 1-\sqrt{\omega} \right|^{2r}.$$

[(d)]{} If $|\omega|=1$ and $|\omega-1|<1$, then $$\left| X_{m,n,r}(\omega) \right| = \left| Y_{m,n,r}(\omega) \right|
< 1.072\frac{r!\Gamma(1-\nu)}{\Gamma(r+1-\nu)} \left| 1 + \sqrt{\omega} \right|^{2r}.$$

[(e)]{} For $|\omega|=1$ and ${\operatorname{Re}}(\omega) \geq 0$, we have $$\left| {} _{2}F_{1} \left( r+1-\nu, r+1; 2r+2; 1-\omega \right) \right| \geq 1,$$ with the minimum value occurring at $\omega=1$.

Part (a) is established in the proof of Lemma 2.3 of [@Chen1].

Part (b) is Lemma 4 of [@Baker].

Part (c) is Lemma 2.5 of [@Chen1].

Part (d) is a slight refinement of Lemma 7.3(a) of [@V2]. In the proof of that lemma, we showed that in our notation here $$\left| X_{m,n,r}(\omega) \right|
\leq \frac{4}{\left| 1 + \sqrt{w} \right|^{2}} \frac{\Gamma(1-m/n) \, r!}{\Gamma(r+1-m/n)}
\left| 1+\sqrt{\omega} \right|^{2r}.$$

Since $\omega$ is on the unit circle, we can write $1+\sqrt{\omega}=1+w_{1} \pm \sqrt{1-w_{1}^{2}}i$, where $0 \leq w_{1} \leq 1$. Here we have $|\theta|<\pi/3$ in order that $|\omega-1|<1$ holds. Hence $w_{1}=\cos(\theta/2)>\cos(\pi/6)$, and so $$\frac{4}{\left| 1 + \sqrt{w} \right|^{2}}<1.072.$$

For part (e), we use Pochammer’s integral (see equation (1.6.6) of [@Sl]), along with the transformation $t=1/s$, to write $$\begin{aligned}
{}_{2} F_{1} \left( a,b; c; z \right)
&=\frac{\Gamma(c)}{\Gamma(b)\Gamma(c-b)} \int_{1}^{\infty} (s-1)^{c-b-1}s^{a-c}(s-z)^{-a}ds \\
&=\frac{\Gamma(c)}{\Gamma(b)\Gamma(c-b)} \int_{0}^{\infty} s^{c-b-1}(s+1)^{a-c}(s+1-z)^{-a}ds.\end{aligned}$$

Thus $${}_{2} F_{1} \left( a,b; c; 1-z \right)
=\frac{\Gamma(c)}{\Gamma(b)\Gamma(c-b)} \int_{0}^{\infty} s^{c-b}(s+1)^{a-c}(s+z)^{-a}ds/s$$ and our problem becomes one of showing that the absolute value of the function $$\int_{0}^{\infty} t^{\alpha} (t+1)^{-\beta}(t+z)^{-\gamma}\frac{dt}{t}$$ with $\alpha, \beta, \gamma>0$ and $\beta+\gamma>\alpha$ attains its minimum in $\Omega=\{z:|z|=1, z\notin[-1,0]\}$ at $z=1$.

Note that here we have $\alpha=c-b$, $\beta=c-a$ and $\gamma=a$.

We can change the integration path to any path that avoids the singularities of the integrand, i.e., any path that stays in the open angle bounded by the rays $\{-\tau z:\tau>0\}$ and $\{-\tau:\tau>0\}$ containing the positive semi-axis. So we will change it to the ray $\{\tau\sqrt{z}: \tau>0\}$. Thus out integral becomes $$\int_{0}^{\infty} \left( \sqrt{z} t \right)^{\alpha}
\left( \sqrt{z}t+1 \right)^{-\beta} \left( \sqrt{z}t+z \right)^{-\gamma}
\frac{dt}{t}
=
z^{(\alpha-\beta-\gamma)/2}
\int_{0}^{\infty} t^{\alpha}
\left( t+1/\sqrt{z} \right)^{-\beta} \left( t+z/\sqrt{z} \right)^{-\gamma}
\frac{dt}{t}.$$

Putting $w=1/\sqrt{z}$ and recalling that $|z|=1$, we have $$\left| z^{(\alpha-\beta-\gamma)/2}
\int_{0}^{\infty} t^{\alpha}
\left( t+1/\sqrt{z} \right)^{-\beta} \left( t+z/\sqrt{z} \right)^{-\gamma}
\frac{dt}{t} \right|
=
\left| \int_{0}^{\infty} t^{\alpha}
\left( t+w \right)^{-\beta} \left( t+wz \right)^{-\gamma}
\frac{dt}{t} \right|,$$ so the problem is reduced to establishing the following:\
let $w,z' \in {\mathbb{C}}$, ${\operatorname{Re}}(w), {\operatorname{Re}}(z')>0$ and $z'w \in {\mathbb{R}}_{+}$. Then $$\left|\int_0^\infty t^\alpha(t+w)^{-\beta}(t+z')^{-\gamma}\frac {dt}t\right|\ge
\left|\int_0^\infty t^\alpha(t+|w|)^{-\beta}(t+|z'|)^{-\gamma}\frac {dt}t\right|\,.$$

Since $c=2a$, $|z|=1$ and our definition of $w$, here we have $\beta=\gamma$ and $z'=z/\sqrt{z}=\sqrt{\bar{z}}$, this is immediate because the integrand on the left is then positive and obviously greater than the one on the right.

Since $|w|=|z'|=1$, we have $$\left|\int_0^\infty t^\alpha(t+|w|)^{-\beta}(t+|z'|)^{-\gamma}\frac {dt}t\right|
=\left|\int_0^\infty t^\alpha(t+1)^{-\beta}(t+1)^{-\gamma}\frac {dt}t\right|,$$ which shows the integral attains its minimum at $z=1$, as stated.

We let $D_{n,r}$ denote the smallest positive integer such that $D_{n,r} X_{m,n,r}(x) \in {\mathbb{Z}}[x]$ for all $m$ as above. For $d \in {\mathbb{Z}}$, we define $N_{d,n,r}$ to be the largest integer such that $\left( D_{n,r}/ N_{d,n,r} \right)X_{m,n,r}\left( 1-\sqrt{d}\,x \right)
\in {\mathbb{Z}}\left[ \sqrt{d} \right] [x]$, again for all $m$ as above. We will use $v_{p}(x)$ to denote the largest power of a prime $p$ which divides into the rational number $x$. We put $$\label{eq:ndn-defn}
{\mathcal{N}}_{d,n} =\prod_{p|n} p^{\min(v_{p}(d)/2, v_{p}(n)+1/(p-1))}.$$

In what follows, we shall restrict our attention to $m=1$, $n=4$ (so $\nu=1/4$) and $t=-1$.

\[lem:2.4\] We have $$\label{eq:cndn-defn}
\frac{\Gamma(3/4) \, r!}{\Gamma(r+3/4)} \frac{D_{4,r}}{N_{d,4,r}}
<{\mathcal{C}}_{4,1} \left( \frac{e^{1.68}}{{\mathcal{N}}_{d,4}} \right)^{r}
\text{ and } \hspace*{1.0mm}
\frac{\Gamma(r+5/4)}{\Gamma(1/4)r!} \frac{D_{4,r}}{N_{d,4,r}}
< {\mathcal{C}}_{4,2} \left( \frac{e^{1.68}}{{\mathcal{N}}_{d,4}} \right)^{r}$$ for all non-negative integers $r$, where ${\mathcal{C}}_{4,1}=0.83$, ${\mathcal{C}}_{4,2}=0.2$ and ${\mathcal{D}}_{4}=e^{1.68}$.

From Lemma 7.4(c) of [@V2], we have $$\max \left( 1, \frac{\Gamma(3/4) \, r!}{\Gamma(r+3/4)},
4\frac{\Gamma(r+5/4)}{\Gamma(1/4)r!} \right)
\frac{D_{4,r}}{N_{d,4,r}} < 100 \left( \frac{e^{1.64}}{{\mathcal{N}}_{d,4}} \right)^{r}$$

However, the value $100$ results in us requiring a lot of computation to complete the proof of our theorem here. Therefore, we seek a smaller value at the expense of replacing $1.64$ by a larger value, whose value has less of an impact on our proof. For $r \geq 156$, $100\exp(1.64r)<0.2\exp(1.68r)$, so we compute directly the left-hand sides of for $r \leq 155$. We find that the maximum values of the left-hand sides of divided by $\exp(1.68r)$ both occur for $r=3$.The lemma follows.

Put $$p_{r}'=\frac{D_{4,r}}{N_{d,4,r}} X_{1,4,r}(\omega) \left(  \frac{u_{1}-u_{2}i}{2} \right) ^{r}, \quad
q_{r}'=\frac{D_{4,r}}{N_{d,4,r}} Y_{1,4,r}(\omega) \left( \frac{u_{1}-u_{2}i}{2} \right)^{r},$$ and $$R_{r}'=\frac{D_{4,r}}{N_{d,4,r}} R_{1,4,r}(\omega) \left( \frac{u_{1}-u_{2}i}{2} \right)^{r},$$ where $r$ is any non-negative integer and $d$ will be determined below.

By the definitions of $D_{4,r}$ and $N_{d,4,r}$, we easily observe that $p_{r}'$ and $q_{r}'$ are algebraic integers of ${\mathbb{Q}}(i)$. We can see that as follows. $X_{1,4,r}(z)$ is a polynomial of degree $r$ and $$p_{r}' = \frac{D_{1,4,r}}{N_{d,4,r}} X_{1,4,r}(\omega) \left(  \frac{u_{1}-u_{2}i}{2} \right)^{r}
= \frac{D_{1,4,r}}{N_{d,4,r}} X_{r} \left( 1-u_{2}i \frac{2}{u_{1}-u_{2}i} \right) \left( \frac{u_{1}-u_{2}i}{2} \right)^{r}.$$

So with $d=u_{2}^{2}$, we have $p_{r}'$ is an algebraic integer of ${\mathbb{Q}}(i)$.

The analogous expression for $q_{r}'$ shows that it is also an algebraic integer.

In fact, there may be some further common factors. As in [@V3], put $$\begin{aligned}
g_{1}  & = \gcd \left( u_{1}, u_{2} \right), \\
g_{2}  & = \gcd \left( u_{1}/g_{1}, t \right)=1,\\
g_{3}  & = \left\{
             \begin{array}{ll}
                 1 & \mbox{if $t \equiv 1 \bmod 4$ and $\left( u_{1}-u_{2} \right)/g_{1} \equiv 0 \bmod 2$}, \\
                 2 & \mbox{if $t \equiv 3 \bmod 4$ and $\left( u_{1}-u_{2} \right)/g_{1} \equiv 0 \bmod 2$},\\
                 4 & \mbox{otherwise,}
             \end{array}
             \right. \\
        & = \left\{
             \begin{array}{ll}
                 2 & \mbox{if $\left( u_{1}-u_{2} \right)/g_{1} \equiv 0 \bmod 2$},\\
                 4 & \mbox{otherwise,}
             \end{array}
             \right. \\
g      & = g_{1}\sqrt{g_{2}/g_{3}}.\end{aligned}$$

Then we can put $$\label{eq:7}
p_{r}=\frac{D_{4,r}}{N_{d,4,r}} X_{1,4,r}(\omega) \left(  \frac{u_{1}-u_{2}i}{2g} \right) ^{r}, \quad
q_{r}=\frac{D_{4,r}}{N_{d,4,r}} Y_{1,4,r}(\omega) \left( \frac{u_{1}-u_{2}i}{2g} \right)^{r},$$ and $$R_{r}=\frac{D_{4,r}}{N_{d,4,r}} R_{1,4,r}(\omega) \left( \frac{u_{1}-u_{2}i}{2g} \right)^{r},$$ where $$d=\left( u-\sigma(u) \right)^{2}/g^{2} = u_{2}^{2}t/g^{2} = -u_{2}^{2}/g^{2}.$$

Since $\left( u_{1}-u_{2}i \right)/g$ is an algebraic integer, the argument above still applies to show that $p_{r}$ and $q_{r}$ are algebraic integers.

So in Lemma \[lem:2.4\], we can take $$Q = \frac{{\mathcal{D}}_{4} \left| u_{1} + \sqrt{u_{1}^{2}+u_{2}^{2}} \right|}{|g|{\mathcal{N}}_{d,4}}$$ and $$\label{eq:k-UB}
k_{0}<1.072{\mathcal{C}}_{4,1}<0.89.$$

We also have $$E = \frac{|g|{\mathcal{N}}_{d,4} \left| u_{1} + \sqrt{u_{1}^{2}+u_{2}^{2}} \right|}{{\mathcal{D}}_{4}u_{2}^{2}}$$ and $$\ell_{0}={\mathcal{C}}_{4,2}|\varphi|=0.2|\varphi|.$$

Other Preliminary Lemmas
========================

\[lem:3.1\] Let $a$, $m$ and $p$ be positive integers with $a \geq 1$ and $p$ a prime. Put $b=p^{m}$ or $b=2p^{m}$ and suppose that $\gcd \left( a,b \right)=1$ and $a^{2}+b^{2}$ not a perfect square. Furthermore, suppose that $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-1$ has an integer solution. All coprime integer solutions $(x,y)$ to the quadratic equation $$\label{eq:quad-eqnc-dup}
x^{2} - \left( a^{2}+b^{2} \right)y^{2}=-b^{2}$$ are given by $$\label{eq:14c-dup}
x+y \sqrt{a^{2}+b^{2}} = \pm \left( \pm a + \sqrt{a^{2}+b^{2}} \right)
\alpha^{2k}, \hspace{1.0mm} k \in {\mathbb{Z}},$$ where $\alpha = \left( T_{1}+U_{1} \sqrt{a^{2}+b^{2}} \right)/2$ and $\left( T_{1},U_{1} \right)$ is the minimum solution of the equation $x^{2}-\left( a^{2}+b^{2} \right)y^{2}=-4$ in positive integers.

The condition that $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-1$ has an integer solution is not required here, but will be needed required for Lemma \[lem:3.2aa\]. Here we can replace $\alpha^{2}$ by $T+U \sqrt{a^{2}+b^{2}}$ where $\left( T,U \right)$ is the minimum solution of the equation $x^{2}-\left( a^{2}+b^{2} \right)y^{2}=1$ in positive integers.

The proof uses the fact that for $\beta, \gamma \in {\mathcal{O}}_{{\mathbb{K}}}$ for some number field, ${\mathbb{K}}$, we have $(\beta)=(\gamma)$ if and only if $\beta=\gamma\epsilon$ where $\epsilon$ is a unit in ${\mathcal{O}}_{{\mathbb{K}}}$. In what follows, we let ${\mathbb{K}}= {\mathbb{Q}}\left( \sqrt{a^{2}+b^{2}} \right)$.

First suppose that $b=p^{m}$ with $p \neq 2$.

Since the Legendre symbol $\left( a^{2}+b^{2} / p \right)=\left( a^{2} / p \right)=1$ if $p \neq 2$ and $a^{2}+b^{2} \equiv 1 \bmod 8$ if $p=2$ (since $b^{2} \geq 8$ by our assumption), we know there is a prime ideal, ${\mathfrak{p}}$ in ${\mathcal{O}}_{{\mathbb{K}}}$, such that $(p)={\mathfrak{p}}\bar{{\mathfrak{p}}}$, where $\bar{{\mathfrak{p}}}=\left\{ a_{1}-b_{1}\sqrt{a^{2}+b^{2}}: a_{1}+b_{1}\sqrt{a^{2}+b^{2}}
\in {\mathfrak{p}}\right\}$. Let $(x,y)$ be any relatively prime solution of and consider $x+y \sqrt{a^{2}+b^{2}}$. It has norm $-b^{2}=-p^{2m}$, so it is a member of $(p)^{2m}$. Since $x$ and $y$ are relatively prime, we must have either $x+y \sqrt{a^{2}+b^{2}} \in {\mathfrak{p}}^{2m}$ or $x+y \sqrt{a^{2}+b^{2}} \in \bar{{\mathfrak{p}}}^{2m}$. Note that it cannot be a member of ${\mathfrak{p}}^{m_{1}} \bar{{\mathfrak{p}}}^{2m-m_{1}}$ for $1 \leq m_{1}<2m$, as such an ideal would have a power of $(p)$ as a factor and hence $x$ and $y$ would no longer be relatively prime – it is here where we need the assumption that $p \neq 2$.

Without loss of generality, let us suppose that $x+y \sqrt{a^{2}+b^{2}} \in {\mathfrak{p}}^{2m}$ and also that $a+\sqrt{a^{2}+b^{2}} \in {\mathfrak{p}}^{2m}$. The proofs for the other cases follow by the fact that the other factor of $(p)$ is $\bar{{\mathfrak{p}}}$, the conjugate of ${\mathfrak{p}}$.

Since $\left( a+\sqrt{a^{2}+b^{2}} \right)$, $\left( x+y\sqrt{a^{2}+b^{2}} \right)$ and ${\mathfrak{p}}^{2m}$ all have norm $b^{2}$ and $a+\sqrt{a^{2}+b^{2}}, x+y \sqrt{a^{2}+b^{2}}
\in {\mathfrak{p}}^{2m}$, it follows that ${\mathfrak{p}}^{2m} = \left( a+\sqrt{a^{2}+b^{2}} \right)
= \left( a+\sqrt{a^{2}+b^{2}} \right)$. Therefore, $x+y \sqrt{a^{2}+b^{2}}$ must be a unit of norm $1$ times $a+\sqrt{a^{2}+b^{2}}$ and the result follows.

If $p=2$, we also need to consider the possibility that it is a member of $x+y \sqrt{a^{2}+b^{2}} \in {\mathfrak{p}}\bar{{\mathfrak{p}}}^{2m-1}$ or $x+y \sqrt{a^{2}+b^{2}} \in {\mathfrak{p}}^{2m-1} \bar{{\mathfrak{p}}}$. As above, we may suppose that $x+y \sqrt{a^{2}+b^{2}} \in {\mathfrak{p}}\bar{{\mathfrak{p}}}^{2m-1}$ and also that $a+\sqrt{a^{2}+b^{2}} \in {\mathfrak{p}}\bar{{\mathfrak{p}}}^{2m-1}$. The same argument as above now holds to show that the lemma holds in this case too.

We now consider $b=2p^{m}$. We may assume that $p \neq 2$, since the case of $p=2$ is covered above. Here $b^{2} \equiv 4 \bmod 8$ and hence $a^{2}+b^{2}
\equiv 5 \bmod 8$. Here $(2)$ is a prime ideal in ${\mathcal{O}}_{{\mathbb{K}}}$ and, as shown above, $(p)$ splits into the product of two prime ideals, ${\mathfrak{p}}$ and $\bar{{\mathfrak{p}}}$, which are conjugates of each other. Let $(x,y)$ be any relatively prime solution of and consider $x+y \sqrt{a^{2}+b^{2}}$. It has norm $-b^{2}=-4p^{2m}$. Since $x$ and $y$ are relatively prime, we must have either $x+y \sqrt{a^{2}+b^{2}} \in (2){\mathfrak{p}}^{m}$ or $x+y \sqrt{a^{2}+b^{2}} \in (2) \bar{{\mathfrak{p}}}^{m}$. As above, it cannot be a member of $(2){\mathfrak{p}}^{m_{1}} \bar{{\mathfrak{p}}}^{2m-m_{1}}$ for $1 \leq m_{1}<2m$.

Arguing as above, the result now follows.

\[lem:3.2aa\] Let $a$ and $b$ be relatively prime positive integers such that $a^{2}+b^{2}$ is not a perfect square. Suppose that all coprime positive integer solutions of $\eqref{eq:quad-eqnc}$ are given by $\eqref{eq:14c}$ and that $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-1$ has an integer solution.

If $(X,Y) \neq (a,1)$ is a coprime positive integer solution to $$X^{2} - \left( a^{2}+b^{2} \right)Y^{4}=-b^{2},$$ then $$\pm X \pm bi = \left( a+bi \right) \left( r \pm si \right)^{4},
\quad Y=r^{2}+s^{2},$$ where $r,s \in {\mathbb{Z}}$ with $\gcd(r,s)=1$ and $s>r>0$.

Note that we can also express the solution $(X,Y)=(a,1)$ in this form, but with $r=1$ and $s=0$ (i.e., we remove the condition that $s>0$).

The condition that $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-1$ has an integer solution is required here. It arises in the proof as it implies that any solution $(X,Y)$ of $X^{2} - \left( a^{2}+b^{2} \right) Y^{4}=-b^{2}$ comes from an even power of $\alpha$. This provides us with the representations in that play a key role in obtaining the desired representation.

For $k \geq 0$, we define $T_{k}$ and $U_{k}$ by $$\alpha^{k} = \frac{T_{k} + U_{k} \sqrt{a^{2}+b^{2}}}{2}.$$

Note that $T_{k}, U_{k} \in {\mathbb{Z}}$ and $T_{k} \equiv U_{k} \bmod 2$, with $T_{k} \equiv U_{k} \equiv 1 \bmod 2$ only possible if $a^{2}+b^{2} \equiv 1 \bmod 4$.

Therefore, by expanding , a solution in coprime positive integers $(X,Y) \neq (a,1)$ to $X^{2}-\left( a^{2}+b^{2} \right)Y^{4}=-b^{2}$ arises from $$X+Y^{2}\sqrt{a^{2}+b^{2}} = \left( \pm a + \sqrt{a^{2}+b^{2}} \right)
\left( \frac{T_{2k}+U_{2k}\sqrt{a^{2}+b^{2}}}{2} \right)$$ and so such a solution is equivalent to $$\label{eq:15}
2X= \left( a^{2}+b^{2} \right) U_{2k} \pm aT_{2k}, \quad 2Y^{2}=T_{2k} \pm aU_{2k}$$ for some $k \geq 1$. Note we need $k \neq 0$ since $(X,Y) \neq (a,1)$.

We now show that the expressions for $X$ and $Y^{2}$ in are actually positive.

Since $T_{2k}^{2}-\left( a^{2}+b^{2} \right)U_{2k}^{2}=1$, we have $T_{2k}>\sqrt{a^{2}+b^{2}}U_{2k}>aU_{2k}$. Hence $Y^{2}>0$ is satisfied.

From $T_{2k}^{2}-\left( a^{2}+b^{2} \right)U_{2k}^{2}=1$, we have $\left( a^{2}+b^{2} \right)U_{2k}-T_{2k}^{2}/U_{2k}=-1/U_{2k}$ and $T_{2k}>\sqrt{a^{2}+b^{2}}U_{2k}$. So we have $$\left( a^{2}+b^{2} \right)U_{2k}-aT_{2k}
>\left( a^{2}+b^{2} \right)U_{2k}-T_{2k}\sqrt{a^{2}+b^{2}}
>\left( a^{2}+b^{2} \right)U_{2k}-T_{2k}^{2}/U_{2k}=-1/U_{2k}.$$

Since $U_{2k} \geq 1$ and $\left( a^{2}+b^{2} \right)U_{2k}-aT_{2k} \in {\mathbb{Z}}$, it follows that $\left( a^{2}+b^{2} \right)U_{2k}-aT_{2k} \geq 0$.

If $\left( a^{2}+b^{2} \right)U_{2k}-aT_{2k}=0$ held, then since $\gcd(a,b)=1$, any prime divisor of $a^{2}+b^{2}$ must divide $T_{2k}$. But then $T_{2k}^{2}-\left( a^{2}+b^{2} \right)U_{2k}^{2}=1$ would be impossible.

Therefore $\left( a^{2}+b^{2} \right)U_{2k}-aT_{2k}>0$, and as a result $\left( a^{2}+b^{2} \right) U_{2k} \pm aT_{2k}>0$ holds. So $X$ is also positive, as required.

Notice that this tells us that $$2X+2Y^{2}\sqrt{a^{2}+b^{2}} = -\left( \pm a + \sqrt{a^{2}+b^{2}} \right)
\left( T_{2k}+U_{2k}\sqrt{a^{2}+b^{2}} \right)$$ is not possible.

Also, corresponding to $k<0$, $$2X+2Y^{2}\sqrt{a^{2}+b^{2}} = \left( \pm a + \sqrt{a^{2}+b^{2}} \right)
\left( T_{2k}-U_{2k}\sqrt{a^{2}+b^{2}} \right)$$ gives us $2X=\pm aT_{2k}-\left( a^{2}+b^{2} \right) U_{2k}$ and $2Y^{2}=T_{2k} \mp aU_{2k}$. But from our argument above, we see that this value of $X$ can never be positive. Hence all the solutions must come from .

Now we use the expressions arising from to prove the lemma.

Note that $$\begin{aligned}
\alpha^{2k} & = & \frac{T_{2k} + U_{2k} \sqrt{a^{2}+b^{2}}}{2}
= \left( \frac{T_{k} + U_{k} \sqrt{a^{2}+b^{2}}}{2} \right)^{2} \\
& = & \frac{T_{k}^{2}+\left(a^{2}+b^{2} \right) U_{k}^{2}
+2T_{k}U_{k} \sqrt{a^{2}+b^{2}}}{4}.\end{aligned}$$

Thus $$\label{eq:my-2}
T_{2k}=\frac{T_{k}^{2}+\left(a^{2}+b^{2} \right) U_{k}^{2}}{2}
\quad \text{ and } \quad
U_{2k}=T_{k}U_{k}.$$

Since $T_{k} \equiv U_{k} \bmod 2$ and $T_{k} \equiv U_{k} \equiv 1 \bmod 2$ only if $a^{2}+b^{2} \equiv 1 \bmod 4$, we see that $T_{2k}, U_{2k} \in {\mathbb{Z}}$, $T_{2k} \equiv U_{2k} \bmod 2$ and $T_{2k} \equiv U_{2k} \equiv 1 \bmod 2$ only if $a^{2}+b^{2} \equiv 1 \bmod 4$. Also notice from the expression for $2X$ in that if $a^{2}+b^{2} \equiv 1 \bmod 4$ and $T_{2k} \equiv U_{2k} \equiv 1 \bmod 2$, then we must have $a$ odd and hence $b$ even. Otherwise, the right-hand side of the expression for $2X$ is odd.

By the expressions in for $T_{2k}$ and $U_{2k}$, implies that $$(2Y)^{2}=T_{k}^{2}+\left( a^{2}+b^{2} \right)U_{k}^{2} \pm 2aT_{k}U_{k}
= \left( T_{k} \pm aU_{k} \right)^{2} + \left( bU_{k} \right)^{2}.$$

Our statements above about the parity of $a$, $b$, $T_{k}$ and $U_{k}$ imply that both $T_{k} \pm aU_{k}$ and $bU_{k}$ are always even. Therefore, $$\label{eq:my-3aa}
Y^{2}=
\left( \frac{T_{k} \pm aU_{k}}{2} \right)^{2} + \left( \frac{bU_{k}}{2} \right)^{2}.$$

Observe that $\gcd \left( Y+\left( T_{k} \pm aU_{k} \right)/2, Y-\left( T_{k} \pm aU_{k} \right)/2 \right)$ divides $\left( T_{k} \pm aU_{k} \right)$ and $bU_{k}/2$. Since $\left( T_{k}+aU_{k} \right) \left( T_{k}-aU_{k} \right)/4= \left( bU_{k}/2 \right)^{2} \pm 1$, and $T_{k}+aU_{k}$ and $T_{k}-aU_{k}$ have the same parity, it follows that $\gcd \left( T_{k} \pm aU_{k}, bU_{k}/2 \right)$ divides $2$. Thus $\gcd \left( Y+\left( T_{k} \pm aU_{k} \right)/2,
Y-\left( T_{k} \pm aU_{k} \right)/2 \right)$ divides $2$.

We consider each of the possibilities for this gcd now.

If $\gcd \left( Y+\left( T_{k} \pm aU_{k} \right)/2, Y-\left( T_{k} \pm aU_{k} \right)/2 \right)=1$, then there are positive integers $b_{1}, b_{2}$, $r_{1}$ and $s_{1}$ satisfying $\gcd \left( b_{1}, b_{2} \right)=\gcd \left( r_{1}, s_{1} \right)=1$ such that $b_{1}b_{2}=b$, $r_{1}s_{1}=U_{k}$ and $$\label{eq:16a}
Y+\left( T_{k} \pm aU_{k} \right)/2=b_{1}^{2}s_{1}^{2}, \quad
Y-\left( T_{k} \pm aU_{k} \right)/2=b_{2}^{2}r_{1}^{2} \quad \text{ and } \quad
b_{1}s_{1}>b_{2}r_{1}.$$

If $\gcd \left( Y+\left( T_{k} \pm aU_{k} \right)/2, Y-\left( T_{k} \pm aU_{k} \right)/2 \right)=2$, then both $Y+\left( T_{k} \pm aU_{k} \right)/2$ and $Y-\left( T_{k} \pm aU_{k} \right)/2$ are twice a square. So we have $$\label{eq:16b}
Y+\left( T_{k} \pm aU_{k} \right)/2=2b_{1}^{2}s_{1}^{2}, \quad
Y-\left( T_{k} \pm aU_{k} \right)/2=2b_{2}^{2}r_{1}^{2} \quad \text{ and } \quad
b_{1}s_{1}>b_{2}r_{1},$$ where $\gcd \left( b_{1}, b_{2} \right)=\gcd \left( r_{1}, s_{1} \right)=1$, and either $2b_{1}b_{2}=b$, $r_{1}s_{1}=U_{k}$; or $b_{1}b_{2}=b$ and $2r_{1}s_{1}=U_{k}$.

In the first case, subtracting the two expressions in and substituting for $U_{k}$, we obtain $$U_{k}=r_{1}s_{1} \quad \text{ and } \quad T_{k}=b_{1}^{2}s_{1}^{2}-b_{2}^{2}r_{1}^{2} \mp ar_{1}s_{1}.$$

We have $T_{k}^{2}- \left( a^{2}+b^{2} \right) U_{k}^{2}=\pm 4$. However, the proof is the same for both cases, so we consider only $T_{k}^{2}- \left( a^{2}+b^{2} \right) U_{k}^{2}=4$ here.

Substituting the above expressions for $T_{k}$ and $U_{k}$ into $T_{k}^{2}- \left( a^{2}+b^{2} \right) U_{k}^{2}=4$ and then simplifying leads to the equation $$b_{2}^{4}r_{1}^{4} \pm 2ab_{2}^{2}r_{1}^{3}s_{1}-3b^{2}r_{1}^{2}s_{1}^{2}
\mp 2ab_{1}^{2}r_{1}s_{1}^{3}+b_{1}^{4}s_{1}^{4}=4.$$

Multiplying both sides by $2bi$, we obtain $$\label{eq:my-3}
(a+bi) \left( b_{2}r_{1} \pm b_{1}s_{1}i \right)^{4}
-(a-bi) \left( b_{2}r_{1} \mp b_{1}s_{1}i \right)^{4}=32bi.$$

We can write $$\begin{aligned}
&   & (a+bi) \left( b_{2}r_{1} \pm b_{1}s_{1}i \right)^{4}
+(a-bi) \left( b_{2}r_{1} \mp b_{1}s_{1}i \right)^{4} \\
& = & 8a \left( T_{k}^{2}+\left( a^{2}+b^{2} \right)U_{k}^{2} \right)
-16 \left( a^{2}+b^{2} \right)T_{k}U_{k} = 32X,\end{aligned}$$ the last equality follows from applying to our expression for $X$ from with the signs there all positive.

Combining this with yields $$16X+16bi= (a+bi) \left( b_{2}r_{1} \pm b_{1}s_{1}i \right)^{4}.$$

Had we considered $T_{k}^{2}- \left( a^{2}+b^{2} \right) U_{k}^{2}=-4$ above, we would have found that $$16X-16bi= (a-bi) \left( b_{2}r_{1} \pm b_{1}s_{1}i \right)^{4}.$$

We noted above that $b_{2}r_{1}$ and $b_{1}s_{1}$ have the same parity. Therefore, $b_{2}r_{1} \pm b_{1}s_{1}i$ is divisible by $1 \pm i$, say $b_{2}r_{1} \pm b_{1}s_{1}i=(1 \pm i)(r+si)$ for some integers $r$ and $s$ with $\gcd(r,s)=1$ and $s>r>0$ (since $b_{1}s_{1}>b_{2}r_{1}$ from ). The expression in the lemma for both $4X+4bi$ and $4X-4bi$ follow.

From the expression for $4X+4bi$, we obtain $$16 \left( X^{2}+b^{2} \right)
= 16\left( a^{2}+b^{2} \right) \left( r^{2}+s^{2} \right)^{4},$$ but we also have $16 \left( X^{2}+b^{2} \right)=16\left( a^{2}+b^{2} \right)Y^{4}$. The expression in the lemma for $2Y$ follows.

When the signs appearing in are negative, a nearly identical argument to the above leads to $$-4X\pm 4bi= (a+bi) \left( b_{2}r_{1}-b_{1}s_{1}i \right)^{4}, \quad b_{1}b_{2}=b,
\quad \gcd \left( r_{1},s_{1} \right)=1.$$

As above, this completes the proof of this lemma.

Next, in Lemma \[lem:3.3\] below, we establish a gap principle separating possible solutions of . We need a few additional lemmas to help us first. Lemma \[lem:3.4\](b) will also play a key role in the proof of Theorem \[thm:1.1\] too.

\[lem:3.4\] Suppose that $a$ and $b$ are relatively prime positive integers and $(X,Y)$ is a coprime positive integer solution of $x^{2}- \left( a^{2}+b^{2} \right)y^{4}=-b^{2}$ with $Y>1$.

[(a)]{} $Y$ is only divisible by primes, $p \equiv 1 \bmod 4$. As a consequence, if $Y>1$, then $Y \geq 5$ and if $Y>5$, then $Y \geq 13$.

[(b)]{} Let $a$ and $b$ be as in the statement of Theorem $\ref{thm:1.2}$. Then $Y>b/2$.

[(c)]{} Let $a$, $m$ and $p$ be as in the statement of Theorem $\ref{thm:1.1}$ and put $b=p^{m}$, then $Y>b^{2}/4$. If $p \neq 2$, then $Y>b^{2}/2$.

The additional conditions in parts (b) and (c) are required. Without them, the lower bound for $Y$ in part (b) does not hold in general.

E.g., if $b$ is an element of the recurrence sequence, $b_{0}=-3$, $b_{1}=4$, $b_{n+2}=50b_{n+1}-b_{n}$ for $n \geq 0$, then $\left( 1+b^{2} \right) 5^{4}-b^{2}=624b^{2}+625$ is a perfect square and $(X,Y)=\left( \sqrt{624b^{2}+625}, 5 \right)$ is a solution of the diophantine equation for $a=1$ and such values of $b$. Hence $Y$ stays fixed as $b$ grows.

Also note that the bound in part (b) is nearly best-possible. For any odd $b' \equiv 0,2,8 \bmod 10$ with $b'>2$, put $b=(b')^{2}-1$, $a=(b')^{3}/4-3b'/2$, then $(x,y)= \left( b' \left( b'^6+4b'^{4}+5b'^{2}+10 \right)/4,
b+2 \right)$ is a solution of . So it appears that the correct bound is $Y>b$.

The bound in part (c) is best-possible for $b$ odd, as can be seen by considering Example 1 in Remark \[rem:1\].

\(a) If $Y=2k$, then we are seeking solutions of $X^{2}=16k^{4}a^{2} + \left( 16k^{4}-1 \right)b^{2}$. Since $\gcd(a,b)=1$, if $a$ is even, then $b$ is odd and $16k^{4}a^{2} + \left( 16k^{4}-1 \right)b^{2} \equiv 3 \bmod 4$. This implies that $X^{2} \equiv 3 \bmod 4$, which is not possible, so there are no solutions with $Y$ even in this case. If $b$ is even, then $X$ is even, but that violates our assumption that $\gcd(X,Y)=1$.

Suppose $Y=pk$, where $p$ is an odd prime. Then we have $X^{2}=a^{2}p^{4}k^{4}+ \left( p^{4}k^{4}-1 \right) b^{2}$. Thus $X^{2} \equiv -b^{2} \bmod p$. If $b \equiv 0 \bmod p$, then $X \equiv 0 \bmod p$, which is not allowed by our assumption that $X$ and $Y$ are relatively prime. For such $b$, $X^{2} \equiv -b^{2} \bmod p$ is not solvable if $p \equiv 3 \bmod 4$, as required.

\(b) and (c) Recall from the proof of Lemma \[lem:3.2aa\] that we have either $$Y+\left( T_{k} \pm aU_{k} \right)/2=b_{1}^{2}s_{1}^{2} \quad \text{ and } \quad
Y-\left( T_{k} \pm aU_{k} \right)/2=b_{2}^{2}r_{1}^{2}$$ with $\gcd \left( b_{1}, b_{2} \right)=1$, $\gcd \left( r_{1}, s_{1} \right)=1$ and $b_{1}b_{2}=b$; or $$Y+\left( T_{k} \pm aU_{k} \right)/2=2b_{1}^{2}s_{1}^{2} \quad \text{ and } \quad
Y-\left( T_{k} \pm aU_{k} \right)/2=2b_{2}^{2}r_{1}^{2}$$ where $\gcd \left( b_{1}, b_{2} \right)=\gcd \left( r_{1}, s_{1} \right)=1$ and $2b_{1}b_{2}=b$.

These relations are and .

If $k=1$, then adding these expressions we have three possibilities.

First, if $$Y+\left( T_{k} \pm aU_{k} \right)/2=b_{1}^{2}s_{1}^{2} \quad \text{ and } \quad
Y-\left( T_{k} \pm aU_{k} \right)/2=b_{2}^{2}r_{1}^{2}$$ with $\gcd \left( b_{1}, b_{2} \right)=1$ and $b_{1}b_{2}=b$, then $$2Y=b_{1}^{2}s_{1}^{2}+b_{2}^{2}r_{1}^{2} = b_{1}^{2}s_{1}^{2}+\left( b/b_{1} \right)^{2}r_{1}^{2}.$$

Differentiating this expression with respect to $b_{1}$, we find that the derivative is only zero for $b_{1}$ positive if $b_{1}=\sqrt{r_{1}b/s_{1}}$. Here we have $2Y=2r_{1}s_{1}b \geq 2b$.

If $b_{1}=1$, then we have $2Y=s_{1}^{2}+b^{2}r_{1}^{2}$. So $2Y \geq b^{2}+1 \geq 2b$. Similarly, if $b_{1}=b$, then we also have $2Y \geq 2b$.

Furthermore, if $b=p^{m}$ is a prime power, then either $b_{1}=b$ or $b_{2}=b$. Here we obtain $2Y>b^{2}$.

Second, if $$Y+\left( T_{k} \pm aU_{k} \right)/2=2b_{1}^{2}s_{1}^{2} \quad \text{ and } \quad
Y-\left( T_{k} \pm aU_{k} \right)/2=2b_{2}^{2}r_{1}^{2}$$ with $\gcd \left( b_{1}, b_{2} \right)=1$ and $2b_{1}b_{2}=b$, then $$2Y=2b_{1}^{2}s_{1}^{2}+2b_{2}^{2}r_{1}^{2}=2b_{1}^{2}s_{1}^{2}+2 \left( b/ \left( 2b_{1} \right) \right)^{2}r_{1}^{2}.$$

Differentiating this expression with respect to $b_{1}$, we find that the derivative is only zero for $b_{1}$ positive if $b_{1}=\sqrt{r_{1}b/\left( 2s_{1} \right)}$. Here we have $2Y=2r_{1}s_{1}b \geq 2b$.

If $b_{1}=1$, then we have $2Y=2s_{1}^{2}+b^{2}r_{1}^{2}/2$. Since $b$ is even, we have $b \geq 2$ and so $2Y \geq b^{2}/2+2 \geq 2b$. Similarly, if $b_{1}=b/2$, then we also have $2Y \geq 2b$.

Furthermore, if $b=p^{m}$ is a prime power, then either $b_{1}=b/2$ or $b_{2}=b/2$. Here we obtain $2Y>2b^{2}/4$.

This completes the proof for $k=1$.

Now we consider $k>1$. If $a=U_{1}=1$, then we have $T_{1}^{2}-\left( 1+b^{2} \right) =-4$. This is only possible if $T_{1}=1$ and $b=2$. Using Magma, we find that there are no integer solutions of $X^{2}-5Y^{4}=-4$ with $Y>1$. Hence we can ignore this case and assume that $aU_{1} \geq 2$. Here we have $T_{1}^{2} \geq b^{2}$. Combining this with , we have $$Y^{2}= \left( T_{k} \pm aU_{k} \right)^{2}4 + \left( bU_{k}/2 \right)^{2}
\geq \left( bU_{2}/2 \right)^{2}=b^{2}T_{1}^{2}U_{1}^{2} \geq b^{4}.$$

This argument holds since $\left\{ U_{k} \right\}$ satisfies the recurrence sequence $U_{k+2}=2T_{1}U_{k+1}+U_{k}$ and $T_{1} \geq 1$, from the minimal polynomial for $\alpha$, so $U_{k} \geq U_{2}$ for $k \geq 2$.

Thus $Y \geq b^{2}$.

\[lem:3.2bb\] Let $\omega=e^{i\theta}$ with $-\pi < \theta \leq \pi$ and put $\omega^{1/4}=e^{i\theta/4}$. If $$0 < \left| \omega^{1/4} - z \right| <c_{1},$$ for some $z \in {\mathbb{C}}$ with $|z|=1$ and $0 < c_{1} < 1$, then $$\left| \omega - z^{4} \right|
> c_{2} \left| \omega^{1/4} - z \right|,$$ where $c_{2}=\left( 2-c_{1}^{2} \right) \sqrt{4-c_{1}^{2}}$.

We can write $$\left| \omega - z^{4} \right|
= \left| \omega^{1/4} - z \right|
  \times \prod_{k=1}^{3} \left| \omega^{1/4} - e^{2\pi ik/4}z \right|.$$

Multiplying by $\omega^{-1/4}$ and expanding the resulting expression, the product above equals $$\prod_{k=1}^{3} \left| e^{2\pi ik/4-i\theta/4}z-1 \right|
= \left| e^{3i\varphi}+e^{2i\varphi}+e^{i\varphi}+1 \right|,$$ for some $-\pi < \varphi \leq \pi$. Squaring this quantity and simplifying, we obtain $$8\cos^{2}(\varphi) \left( \cos(\varphi)+1 \right).$$

If $\left| \omega^{1/4} - z \right|=c_{1}$, we have $2-2\cos(\varphi)=c_{1}^{2}$ and the lemma follows under this assumption by a routine substitution. Since $c_{2}$ is a decreasing function of $c_{1}$, the lemma also holds in general.

\[lem:3.3\] Under the same assumptions as in Theorem $\ref{thm:1.1}$, suppose that $\left( X_{1},Y_{1} \right)$ and $\left( X_{2},Y_{2} \right)$ are two solutions in coprime positive integers to with $Y_{2}>Y_{1}>1$. Then $$Y_{2}>7.98\frac{a^{2}+b^{2}}{b^{2}} Y_{1}^{3}.$$

By Lemma \[lem:3.2aa\], there are integers $r_{1}, s_{1}, r_{2}, s_{2}$ such that $$\pm 4X_{j} \pm 4bi = \left( a+bi \right) \left( r_{j} \pm s_{j} i \right)^{4},
\quad 2Y_{j}=r_{j}^{2}+s_{j}^{2}, \hspace{1.0mm} \text{$j=1,2$}.$$

We will assume that $$\label{eq:3.2}
4X_{1} \pm 4bi = \left( a+bi \right) \left( r_{1} + s_{1} i \right)^{4},
\quad
4X_{2} \pm 4bi = \left( a+bi \right) \left( r_{2} + s_{2} i \right)^{4},$$ as the argument for the other cases is exactly the same. It follows that $$\label{eq:3.3}
\left( a+bi \right) \left( r_{j}+s_{j}i \right)^{4}
- \left( a-bi \right) \left( r_{j}-s_{j}i \right)^{4}
= \pm 8bi, \quad \text{($j=1,2$)}.$$

Putting $\omega = \left( a-bi \right) / \left( a+bi \right)$, by Lemma \[lem:3.4\](a) and , we have $$\label{eq:3.4}
\left| \omega - \left( \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right)^{4} \right|
=\left| \frac{\pm 8bi}{\left( a+bi \right)\left( r_{j}-s_{j}i \right)^{4}} \right|
= \frac{8b}{\sqrt{a^{2}+b^{2}} 4Y_{j}^{2}}
< 2/25.$$

For $j=1,2$, let $\zeta_{4}^{(j)}$ be the $4$-th root of unity such that $$\left| \omega^{1/4} - \zeta_{4}^{(j)} \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right|
= \min_{0 \leq k \leq 3} \left| \omega^{1/4} - \zeta_{4}^{k} \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right|.$$

From , we immediately have $$\left| \omega^{1/4} - \zeta_{4}^{(j)} \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right|
< (2/25)^{1/4},$$ for $j=1,2$. In fact, we will show that this quantity is even smaller.

Applying Lemma \[lem:3.2bb\] with $c_{1}=(2/25)^{1/4}$, we can take $c_{2}=3.31$. Combining this with , we obtain $$\left| \omega^{1/4} - \zeta_{4}^{(j)} \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right|
< (2/25)/3.31<0.025.$$

Applying Lemma \[lem:3.2bb\] again, now with $c_{1}=0.025$, we obtain $$\label{eq:20}
\left| \omega - \left( \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right)^{4} \right|
> 3.998 \left| \omega^{1/4} - \zeta_{4}^{(j)} \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right|$$ and $$\label{eq:3.6}
\left| \omega^{1/4} - \zeta_{4}^{(j)} \frac{r_{j}+s_{j}i}{r_{j}-s_{j}i} \right|
<0.5003 \frac{b}{\sqrt{a^{2}+b^{2}} Y_{j}^{2}}.$$

Hence $$\begin{aligned}
\label{eq:3.7}
\left| \zeta_{4}^{(1)} \frac{r_{1}+s_{1}i}{r_{1}-s_{1}i} - \zeta_{4}^{(2)} \frac{r_{2}+s_{2}i}{r_{2}-s_{2}i} \right|
& \leq \left| \omega^{1/4} - \zeta_{4}^{(1)} \frac{r_{1}+s_{1}i}{r_{1}-s_{1}i} \right|
+ \left| \omega^{1/4} - \zeta_{4}^{(2)} \frac{r_{2}+s_{2}i}{r_{2}-s_{2}i} \right| \nonumber \\
& < 0.5003 \frac{b}{\sqrt{a^{2}+b^{2}} Y_{1}^{2}} + 0.5003 \frac{b}{\sqrt{a^{2}+b^{2}} Y_{2}^{2}}.\end{aligned}$$

Next we obtain a lower bound for this same quantity.

If $$\zeta_{4}^{(1)} \frac{r_{1}+s_{1}i}{r_{1}-s_{1}i}
=\zeta_{4}^{(2)} \frac{r_{2}+s_{2}i}{r_{2}-s_{2}i},$$ then from our expression for $Y_{j}$ in Lemma \[lem:3.2aa\] $$\zeta_{4}^{(1)}\frac{\left( r_{1}+s_{1}i \right)^{2}}{2Y_{1}}
= \zeta_{4}^{(2)} \frac{\left( r_{2}+s_{2}i \right)^{2}}{2Y_{2}},$$ so $$\frac{\left( r_{1}+s_{1}i \right)^{4}}{4Y_{1}^{2}}
= \pm \frac{\left( r_{2}+s_{2}i \right)^{4}}{4Y_{2}^{2}}.$$

From , it follows that $$\left( X_{1} \pm bi \right) Y_{2}^{2} = \pm \left( X_{2} \pm bi \right) Y_{1}^{2}.$$

Comparing the imaginary parts of both sides of this equation, we find that $Y_{1}=Y_{2}$, but this contradicts our assumption that $Y_{2}>Y_{1}$.

Let $x+yi= \left( r_{1}-s_{1}i \right) \left( r_{2}+s_{2}i \right)$. We can write $$\left| \zeta_{4}^{(1)} \frac{r_{1}+s_{1}i}{r_{1}-s_{1}i} - \zeta_{4}^{(2)} \frac{r_{2}+s_{2}i}{r_{2}-s_{2}i} \right|
= \frac{2\zeta_{4}^{(1)}x-\left( \zeta_{4}^{(1)}+\zeta_{4}^{(2)} \right)( x+yi)}
{\left( r_{1}-s_{1}i \right) \left( r_{2}-s_{2}i \right)}.$$

Regardless of the values of $\zeta_{4}^{(1)}$ and $\zeta_{4}^{(2)}$, we always have $(1+i)| \left( \zeta_{4}^{(1)} + \zeta_{4}^{(2)} \right)$. Hence $1+i$ always divides the numerator of the above expression. Also notice that since $2Y_{j}=r_{j}^{2}+s_{j}^{2}$ is even, we have $r_{j} \equiv s_{j} \bmod 2$, so $x$ and $y$ must both be even and $$\left| \zeta_{4}^{(1)} \frac{r_{1}+s_{1}i}{r_{1}-s_{1}i} - \zeta_{4}^{(2)} \frac{r_{2}+s_{2}i}{r_{2}-s_{2}i} \right|
\geq \frac{2|1+i|}{\left| {\left( r_{1}-s_{1}i \right) \left( r_{2}-s_{2}i \right)} \right|}
=\frac{\sqrt{2}}{\sqrt{Y_{1}Y_{2}}}.$$

Combining this with , we have $$\frac{\sqrt{2}}{\sqrt{Y_{1}Y_{2}}}
< 0.5003 \frac{b}{\sqrt{a^{2}+b^{2}}}
\left( \frac{1}{Y_{1}^{2}} + \frac{1}{Y_{2}^{2}} \right).$$

From $Y_{2}>Y_{1}$, this immediately gives us $$\frac{\sqrt{2}}{\sqrt{Y_{1}Y_{2}}}
< 0.5003 \frac{b}{\sqrt{a^{2}+b^{2}}}\frac{2}{Y_{1}^{2}},$$ so $$Y_{2}>1.997\frac{a^{2}+b^{2}}{b^{2}} Y_{1}^{3}>1.997Y_{1}^{3}.$$

We can use this gap principle to improve its constant term. Applying Lemma \[lem:3.4\](a), $$Y_{2}^{2}>3.988Y_{1}^{6} \geq 2490Y_{1}^{2}$$ yielding $$\frac{\sqrt{2}}{\sqrt{Y_{1}Y_{2}}}
< 0.5003 \frac{b}{\sqrt{a^{2}+b^{2}}} \frac{1.0005}{Y_{1}^{2}}$$ and finally $$Y_{2}>7.98\frac{a^{2}+b^{2}}{b^{2}} Y_{1}^{3}.$$ completing our proof.

Proof of Theorem \[thm:1.1\]
============================

\[lem:thm\] Let $a$ and $b$ be relatively prime positive integers such that $a^{2}+b^{2}$ is not a perfect square.

Suppose $x^{2}- \left( a^{2}+b^{2} \right) y^{2}=-1$ has a solution and that all coprime integer solutions $(x,y)$ to the quadratic equation $\eqref{eq:quad-eqnc}$ are given by $\eqref{eq:14c}$.

Then $\eqref{eq:2}$ has at most one solution, $\left( X, Y \right)$, in coprime positive integers solutions with $Y>b^{2}/2$.

Suppose that $\left( X_{1}, Y_{1} \right)$ and $\left( X_{2}, Y_{2} \right)$ are two coprime positive integer solutions to with $Y_{2}>Y_{1}>b^{2}/2$ and that the assumptions in the statement of the lemma hold.

From Lemma \[lem:3.4\](a), we obtain $$\label{eq:25}
X_{1}^{2}= \left( a^{2}+b^{2} \right) Y_{1}^{4}-b^{2}
> \left( a^{2}+b^{2} \right) \left( Y_{1}^{4}-1 \right)
> 0.9984 \left( a^{2}+b^{2} \right) Y_{1}^{4},$$ and so $$\label{eq:26}
\sqrt{X_{1}^{2}+b^{2}}= \sqrt{\left(a^{2}+b^{2}\right) Y_{1}^{4}}
< 1.001 X_{1}.$$

By Lemma \[lem:3.2aa\], there are integers $r_{1},s_{1},r_{2},s_{2}$ such that $$\pm X_{j} \pm bi = (a+bi) \left( r_{j} \pm s_{j} i \right)^{4}, \hspace{1.0mm}
Y_{j}=r_{j}^{2}+s_{j}^{2}, \hspace{1.0mm} \gcd \left( r_{j}, s_{j} \right)=1,
\hspace{1.0mm} s_{j}>r_{j}>0,$$ for $j=1,2$.

We will assume that $$X_{1} \pm bi = (a+bi) \left( r_{1} + s_{1} i \right)^{4}, \quad
X_{2} \pm bi = (a+bi) \left( r_{2} + s_{2} i \right)^{4},$$ as the argument is identical in the other three cases. Thus $$(a+bi) \left( r_{j} + s_{j} i \right)^{4}
- (a-bi) \left( r_{j} - s_{j} i \right)^{4}
=2i{\operatorname{Im}}\left( X_{j} \pm bi \right)
= \pm 2bi$$ for $j=1,2$.

Applying this for $j=2$ and using our expressions above for $X_{1} \pm bi$ and $Y_{1}$, we have $$\begin{aligned}
& & \left( X_{1} \pm bi \right) \left( r_{1} - s_{1} i \right)^{4}\left( r_{2} + s_{2} i \right)^{4}
- \left( X_{1} \mp bi \right) \left( r_{1} + s_{1} i \right)^{4}\left( r_{2} - s_{2} i \right)^{4} \\
& = & (a+bi) \left( r_{1}^{2} + s_{1}^{2} \right)^{4} \left( r_{2} + s_{2} i \right)^{4} 
- (a-bi) \left( r_{1}^{2} + s_{1}^{2} \right)^{4} \left( r_{2} - s_{2} i \right)^{4} \\
& = & \left( r_{1}^{2} + s_{1}^{2} \right)^{4} \left( (a+bi) \left( r_{2} + s_{2} i \right)^{4}
- (a-bi) \left( r_{2} - s_{2} i \right)^{4} \right)
= 2i \left( r_{1}^{2} + s_{1}^{2} \right)^{4} {\operatorname{Im}}\left( X_{2} \pm bi \right) \\
& = & \pm 2bY_{1}^{4}i.\end{aligned}$$

Letting $$x+yi= \left( r_{1}-s_{1}i \right) \left( r_{2}+s_{2}i \right),$$ we have $$\label{eq:27}
|f(x,y)|=\left| \left( X_{1} \pm bi \right) (x+yi)^{4} - \left( X_{1} \mp bi \right)(x-yi)^{4} \right|
=2bY_{1}^{4}.$$

Put $$\omega = \frac{X_{1} \pm bi}{X_{1} \mp bi}$$ and let $\zeta_{4}$ be the $4$-th root of unity such that $$\left| \omega^{1/4} - \zeta_{4} \frac{x-yi}{x+yi} \right|
= \min_{0 \leq k \leq 3} \left| \omega^{1/4} - e^{2k\pi i/4} \frac{x-yi}{x+yi} \right|.$$

From , our expressions for $x+yi$, $X_{1}$ and $Y_{1}$ and (which implies that $\left| X_{1} \pm bi \right|^{2} =X_{1}^{2}+b^{2}=\left( a^{2}+b^{2} \right)Y_{1}^{4}$), we have $$\left| \omega - \left( \frac{x-yi}{x+yi} \right)^{4} \right|
= \frac{2bY_{1}^{4}}{\left| X_{1} \mp bi \right| \left| r_{1} \mp s_{1}i \right|^{4}\left| r_{2} \mp s_{2}i \right|^{4}}
=\frac{2b}{\sqrt{a^{2}+b^{2}} Y_{2}^{2}}$$

By Lemma \[lem:3.4\](a) and Lemma \[lem:3.3\], $Y_{2} >7.98Y_{1}^{3}>7.98 \cdot 5^{3}$. So $Y_{2} \geq 998$. Then $$\left| \omega^{1/4} - \zeta_{4} \frac{x-yi}{x+yi} \right| < \left( 2/Y_{2}^{2} \right)^{1/4}
<0.04.$$

Thus we can apply Lemma \[lem:3.2bb\] with $c_{1}=0.04$ to find that $$\label{eq:29}
\frac{2b}{\sqrt{a^{2}+b^{2}} Y_{2}^{2}}
= \left| \omega - \left( \frac{x-yi}{x+yi} \right)^{4} \right|
> 3.99 \left| \omega^{1/4} - \zeta_{4} \frac{x-yi}{x+yi} \right|.$$

In what follows, we shall require a lower bound for this last quantity. To derive such a bound we shall use the lower bounds in Lemma \[lem:2.1\] with a sequence of good approximations $p_{r}/q_{r}$ obtained from the hypergeometric functions. So we collect here the required quantities.

Let $u_{1}=2X_{1}$ and $u_{2}=\pm 2b$. Since $\gcd(a,b)=\gcd \left( X_{1}, Y_{1} \right)=1$, we have $g_{1}=2$. If $ab \equiv 1 \bmod 2$, then $g_{3}=2$, otherwise $g_{3}=4$. Therefore, $g=\sqrt{2}$ and $d=2b^{2}$ if $ab \equiv 1 \bmod 2$, while $g=1$ and $d=4b^{2}$ otherwise.

Therefore, $${\mathcal{N}}_{d,n}=2^{\min \left( v_{2}(d)/2, v_{2}(4)+1 \right)}
=2^{\min \left( v_{2}(d)/2, 3 \right)}.$$

If $ab$ is odd, then ${\mathcal{N}}_{d,4}=\sqrt{2}$. If $a$ is even and $b$ is odd, then ${\mathcal{N}}_{d,4}=2$. If $b=2$, then ${\mathcal{N}}_{d,4}=4$. If $b=2^{m}$ with $m \geq 2$, then ${\mathcal{N}}_{d,4}=8$.

Thus $8 \geq |g|{\mathcal{N}}_{d,4} \geq 2$ and from Lemma \[lem:2.4\] we have $$Q=\frac{e^{1.68} \left| 2X_{1}+2\sqrt{X_{1}^{2}+b^{2}}\right|}{|g|{\mathcal{N}}_{d,4}}
< e^{1.68} \left| X_{1}+\sqrt{X_{1}^{2}+b^{2}}\right|.$$

From , we also have $X_{1}<\sqrt{X_{1}^{2}+b^{2}}=\sqrt{a^{2}+b^{2}} Y_{1}^{2}$, so $$\label{eq:Q-UB2}
Q<e^{1.68} \cdot 2 \sqrt{a^{2}+b^{2}} Y_{1}^{2}
<10.74\sqrt{a^{2}+b^{2}} Y_{1}^{2}.$$

Similarly, we have $$E = \frac{|g|{\mathcal{N}}_{d,4} \left| u_{1} + \sqrt{u_{1}^{2}+u_{2}^{2}} \right|}{{\mathcal{D}}_{4}u_{2}^{2}}
> \frac{2 \left| 2X_{1}+2\sqrt{X_{1}^{2}+b^{2}} \right|}{e^{1.68} \cdot 4b^{2}}.$$

From , $$\label{eq:E-LB}
E > \frac{\left( 1+\sqrt{0.9984} \right)\sqrt{a^{2}+b^{2}} Y_{1}^{2}}{e^{1.68}b^{2}}
> \frac{0.372\sqrt{a^{2}+b^{2}} Y_{1}^{2}}{b^{2}}.$$

By Lemma \[lem:3.4\](a), $Y_{1} \geq 5$, so $E>1$, as required for its use with Lemma \[lem:2.1\]. Also $Q\geq e^{1.68}\left| X_{1}+\sqrt{X_{1}^{2}+b^{2}} \right|/4>1$, again as needed for Lemma \[lem:2.1\].

Recall from that we take $k_{0}=0.89$.

Since $\omega = \left( X_{1} \pm bi \right)^{2}/ \left( X_{1}^{2}+b^{2} \right)$, we have $\left| \tan \left( \varphi \right) \right| = 2b/X_{1}$. From $|\varphi| \leq |\tan (\varphi)|$, we can take $$\label{eq:ell-UB}
\ell_{0}={\mathcal{C}}_{4,2}|\varphi|=0.4b/X_{1}.$$

From Lemma \[lem:3.4\](a) we have $$X_{1}^{2}=\left( a^{2}+b^{2} \right)Y_{1}^{4}-b^{2}
>\left( Y_{1}^{4}-1 \right) b^{2} \geq 624b^{2},$$ which yields $|\varphi| \leq \left| \tan(\varphi) \right|=2b/X_{1}<2\sqrt{1/624}<0.081$. Therefore the condition $|\omega-1|<1$ in Lemma \[lem:2.2\] is satisfied too.

Let $p=x-yi$ and $q=x+yi=\left( r_{1}-s_{1}i \right) \left( r_{2}+s_{2}i \right)$.

We are now ready to deduce the required contradiction from the assumption that there are two coprime solutions $\left( X_{1}, Y_{1} \right)$ and $\left( X_{2}, Y_{2} \right)$ to with $Y_{2}>Y_{1}>b^{2}/2$. We will consider three cases according to the value of $r_{0}$ defined in Lemma \[lem:2.1\].

[**Case 1:**]{} $r_{0}=1$ and $q_{1}\zeta_{4}p \neq qp_{1}$.

In this case, by , we have $$\begin{aligned}
\frac{2b}{\sqrt{a^{2}+b^{2}} \, Y_{2}^{2}}
&= \left| \omega - \left( \frac{p}{q} \right)^{4} \right|
> 3.99 \left| \omega^{1/4} - \zeta_{4} \frac{p}{q} \right| \\
&> \frac{3.99}{2k_{0}Q\sqrt{Y_{1}Y_{2}}}
> \frac{3.99}{2 \cdot 0.89 \cdot 10.74 \sqrt{a^{2}+b^{2}} Y_{1}^{2}\sqrt{Y_{1}Y_{2}}},\end{aligned}$$ where the second inequality comes from Lemma \[lem:2.1\](b) applied with $r_{0}=1$ and $|p|=\sqrt{Y_{1}Y_{2}}$, and the last inequality comes and . Thus we obtain $$Y_{2}^{3} < 92b^{2}Y_{1}^{5}.$$

On the other hand, we have $Y_{2}^{3}>508Y_{1}^{9}$ by Lemma \[lem:3.3\], thus we get $Y_{1}^{4}<b^{2}/5$. But Lemma \[lem:3.4\](a) and our assumption that $Y_{1}>b^{2}/2$ imply that $Y_{1}^{4} > 5^{3}b^{2}/2$. Thus we cannot have two solutions with $Y_{2}>Y_{1}>1$ in this case.

[**Case 2:**]{} $r_{0}=1$ and $q_{1}\zeta_{4}p= qp_{1}$.

From the definitions of $p_{1}$ and $q_{1}$ in , along with Lemma \[lem:2.2\] parts (a) and (e) and $Y_{11,4,1}(\omega)=(3\omega+5)/3$, we have $$\begin{aligned}
\left| \omega^{1/4} - \zeta_{4} \frac{p}{q} \right|
&= \frac{1}{q_{1}} \left| q_{1}\omega^{1/4} - p_{1} \right|
= \left| \frac{N_{d,4,1}}{D_{1,r} Y_{1,4,1}(\omega) \left( \frac{u_{1}-u_{2}i}{2g} \right)} \right| \left| \frac{D_{4,1}}{N_{d,4,1}} R_{1,4,1}(\omega) \left( \frac{u_{1}-u_{2}i}{2g} \right) \right| \\
&= \left| \frac{N_{d,4,1}}{D_{1,r} Y_{1,4,1}(\omega) \left( \frac{u_{1}-u_{2}i}{2g} \right)} \right| \left| \frac{D_{4,1}}{N_{d,4,1}} (\omega-1)^{3} \frac{(1/4)(5/4)}{2 \cdot 3} 
           {} _{2}F_{1} \left( 7/4, 2; 4; 1-\omega \right) \left( \frac{u_{1}-u_{2}i}{2g} \right) \right| \\ 
& \geq \left| \frac{N_{d,4,1}}{D_{1,r} Y_{1,4,1}(\omega) \left( \frac{u_{1}-u_{2}i}{2g} \right)} \right| \left| \frac{D_{4,1}}{N_{d,4,1}} (\omega-1)^{3} \frac{(1/4)(5/4)}{2 \cdot 3} 
           \left( \frac{u_{1}-u_{2}i}{2g} \right) \right| \\ 
& = \left| \frac{5(\omega-1)^{3}}{96Y_{1,4,1}(\omega)} \right| = \left| \frac{5(\omega-1)^{3}}{32(3\omega+5)} \right|.\end{aligned}$$

Since $3\omega+5=\left( 8X_{1} \mp 2bi \right)/\left( X_{1} \mp bi \right)$, we have $$\frac{(\omega-1)^{3}}{(3\omega+5)}
=-\frac{4b^{3}i}{\left( 4X_{1} \mp bi \right)\left( X_{1} \mp bi \right)^{2}}.$$ so by , $$\left| \frac{(\omega-1)^{3}}{(3\omega+5)} \right|
=\frac{4b^{3}}{\sqrt{16X_{1}^{2}+b^{2}}\left( X_{1}^{2}+b^{2} \right)}
> \frac{b^{3}}{\left( a^{2}+b^{2} \right)^{3/2}Y_{1}^{6}}.$$

Therefore, $$\left| \omega^{1/4} - \zeta_{4} \frac{p}{q} \right|
\geq \frac{0.156b^{3}}{\left( a^{2}+b^{2} \right)^{3/2}Y_{1}^{6}},$$ so $$\frac{2b}{\sqrt{a^{2}+b^{2}} \, Y_{2}^{2}}
> 3.7\frac{0.156b^{3}}{\left( a^{2}+b^{2} \right)^{3/2}Y_{1}^{6}}
> \frac{0.62b^{3}}{\left( a^{2}+b^{2} \right)^{3/2}Y_{1}^{6}}.$$

This inequality, along with our gap principle in Lemma \[lem:3.3\] implies that $$\left( \frac{2}{0.62} \right)^{2} \frac{\left( a^{2}+b^{2} \right)^{2}}{b^{4}} Y_{1}^{12}>Y_{2}^{4}
>7.98^{4} \frac{\left( a^{2}+b^{2} \right)^{4}}{b^{8}} Y_{1}^{12}.$$

This implies that $$0.0027>\left( \frac{2}{0.62 \cdot 63} \right)^{2} 
>\frac{\left( a^{2}+b^{2} \right)^{2}}{b^{4}}>1,$$ which is impossible. Hence we cannot have two coprime solutions with $Y_{2}>Y_{1}>b^{2}/2$ in Case 2.

[**Case 3:**]{} $r_{0}>1$.

Here we establish a stronger gap principle here for $Y_{1}$ and $Y_{2}$ than the one in Lemma \[lem:3.3\]. We then use this to obtain a contradiction with Lemma \[lem:2.1\](a). Here the gap principle is simpler to obtain as we can appeal to the definition of $r_{0}$ in Lemma \[lem:2.1\]. From that definition we have $$|q| \geq E^{r_{0}-1} / \left( 2\ell_{0} \right).$$

Recall too that $q=x+yi$ so that $|q|=\sqrt{Y_{1}Y_{2}}$. Thus $$\sqrt{Y_{1}Y_{2}} \geq E^{r_{0}-1} / \left( 2\ell_{0} \right).$$

From , and , $$\sqrt{Y_{1}Y_{2}}
> \frac{X_{1}}{0.8b} \left( \frac{0.372\sqrt{a^{2}+b^{2}} Y_{1}^{2}}{b^{2}} \right)^{r_{0}-1}
> \frac{1.248\sqrt{a^{2}+b^{2}}Y_{1}^{2}}{b} \left( \frac{0.372\sqrt{a^{2}+b^{2}} Y_{1}^{2}}{b^{2}} \right)^{r_{0}-1}.$$

Therefore, $$\label{eq:y2UB-case3}
Y_{2} > 11.25 \cdot 0.138^{r_{0}} \left( a^{2}+b^{2} \right)^{r_{0}} b^{2-4r_{0}}
Y_{1}^{4r_{0}-1}.$$

From equation , Lemma \[lem:2.1\](a) and $|x+yi|=\sqrt{Y_{1}Y_{2}}$, we have $$\label{eq:32}
\frac{2b}{\sqrt{a^{2}+b^{2}} Y_{2}^{2}}
> 3.99 \left| \omega^{1/4} - \zeta_{4} \frac{x-yi}{x+yi} \right|
> \frac{3.99}{2k_{0}Q^{r_{0}+1}\sqrt{Y_{1}Y_{2}}}.$$

Applying and , we obtain $$\frac{2b}{\sqrt{a^{2}+b^{2}} Y_{2}^{2}}
> \frac{3.99}{2 \cdot 0.89 \left( 10.74\sqrt{a^{2}+b^{2}} Y_{1}^{2} \right)^{r_{0}+1}\sqrt{Y_{1}Y_{2}}},$$ so $$\frac{(3.56b)^{2}}{3.99^{2}} 10.74^{2r_{0}+2}
\left( a^{2}+b^{2} \right)^{r_{0}} Y_{1}^{4r_{0}+5}
>Y_{2}^{3}.$$

We will simplify this to $$\label{eq:y2LB-case3}
92b^{2} \cdot 116^{r_{0}}
\left( a^{2}+b^{2} \right)^{r_{0}} Y_{1}^{4r_{0}+5}
>Y_{2}^{3}.$$

We now combine and , obtaining $$92b^{2} \cdot 116^{r_{0}}
\left( a^{2}+b^{2} \right)^{r_{0}} Y_{1}^{4r_{0}+5}
>
1420 \cdot b^{6-12r_{0}} \cdot 0.0026^{r_{0}}
\left( a^{2}+b^{2} \right)^{3r_{0}} Y_{1}^{12r_{0}-3}.$$

Applying the assumption that $Y_{1}>b^{2}/2$ and simplifying, we have $$0.0646 \left( \frac{44,620}{\left( a^{2}+b^{2} \right)^{2}} \right)^{r_{0}}
> b^{4-12r_{0}} Y_{1}^{8r_{0}-8}
> b^{4r_{0}-12} 2^{-8r_{0}+8}.$$

That is, $$0.000253 \left( \frac{11,423,000}{\left( a^{2}+b^{2} \right)^{2}} \right)^{r_{0}}
> b^{4r_{0}-12}.$$

For $r_{0} \geq 2$, we have $$0.000253 \frac{b^{4}}{\left( a^{2}+b^{2} \right)^{4}} \left( 11,423,000 \right)^{2} > 1.$$

This is never satisfied for $a^{2}+b^{2} \geq 181,700$.

We could attempt to address the outstanding values of $a$ and $b$ by using the `IntegralQuarticPoints()` function within MAGMA, but the number of equations is quite large. Instead we proceed as follows.

Suppose that $Y_{1} \geq \max \left( 1700, b^{2}/2 \right)$. From , $$X_{1}^{2}>0.9984 \left( a^{2}+b^{2} \right) Y_{1}^{4}
\geq 0.9984 \left( a^{2}+b^{2} \right) 1700 \left( b^{2}/2 \right)^{3}
> 212b^{6}.$$

For such $X_{1}$, we have $$E^{2}> \left( \frac{2 \left| 2X_{1}+2\sqrt{X_{1}^{2}+b^{2}} \right|}{e^{1.68} \cdot 4b^{2}} \right)^{2}
>\frac{64X_{1}^{2}}{e^{3.36} \cdot 16b^{4}}
>\frac{64 \cdot 212b^{6}}{e^{3.36} \cdot 16b^{4}}>29.4b^{2}.$$

In addition, we have $$\frac{Q}{E}<\left( 10.74\sqrt{a^{2}+b^{2}} Y_{1}^{2} \right) \frac{b^{2}}{0.372\sqrt{a^{2}+b^{2}} Y_{1}^{2}}
< 29b^{2}.$$

Thus $$E^{3}>Q.$$

Therefore, $$Q^{r_{0}-2}<E^{3(r_{0}-2)} = E^{-3}E^{3(r_{0}-1)} \leq E^{-3} \left( 2\ell_{0}|q| \right)^{3}
=E^{-3} \left( \frac{0.8b}{X_{1}} \sqrt{Y_{1}Y_{2}} \right)^{3}$$

From , we have $$\frac{2b}{\sqrt{a^{2}+b^{2}} Y_{2}^{2}}
> \frac{3.99}{2k_{0}Q^{r_{0}+1}\sqrt{Y_{1}Y_{2}}}.
=\frac{3.99X_{1}^{3}}{1.78Q^{3}E^{-3} \left( 0.8b \sqrt{Y_{1}Y_{2}} \right)^{3}\sqrt{Y_{1}Y_{2}}}.$$

We saw above that $Q/E<29b^{2}$, so $$\frac{2b}{\sqrt{a^{2}+b^{2}}}
>\frac{3.99X_{1}^{3}}{1.78 \cdot 29^{3}b^{6} \left( 0.8b \sqrt{Y_{1}} \right)^{3}\sqrt{Y_{1}}}.$$

Combining this with , we find that $$1.25 \cdot 10^{8} b^{20} Y_{1}^{4}> \left( a^{2}+b^{2} \right) X_{1}^{6}
> \left( a^{2}+b^{2} \right) \left( 0.9984 \left( a^{2}+b^{2} \right) Y_{1}^{4} \right)^{3}.$$

Thus $$\label{eq:y1-UB}
1.26 \cdot 10^{8} \frac{b^{20}}{\left( a^{2}+b^{2}\right)^{4}}>Y_{1}^{8}.$$

We then calculated all coprime pairs $(a,b)$ such that $a^{2}+b^{2}<181,700$ and that had a solution $(X,Y)$ with $Y \geq 2$ and either $Y<1700$ or holding.

We found 35 such pairs, $(a,b)$. Of these, for the following 12 the negative Pell equation is solvable and there is only one family of solutions of the associated quadratic equation: $(a,b)=(1,1),(1,3),(3,7),(9,7),(11,3)$, $(11,7),(18,43),(19,9)$, $(29,11)$, $(29,17),(31,5),(41,13)$.

We solved each of these $12$ equations using MAGMA (version V2.23-9) and its\
`IntegralQuarticPoints()` function. No further coprime solutions were found for any of these equations.

Proof of Theorem \[thm:1.1\]
----------------------------

If $\left( X_{1},Y_{1} \right)$ is a coprime positive integer solution of $x^{2} - \left( a^{2}+b^{2} \right)y^{4}=-b^{2}$ with $Y_{1}>1$, then $Y_{1}>b^{2}/2$ by Lemma \[lem:3.4\](b). Therefore, we can apply Lemma \[lem:thm\] to show that there is no other solution $(X,Y)$ with $Y>b^{2}/2$.

Thus this theorem holds.

Proof of Theorem \[thm:1.2\]
----------------------------

If $\left( X_{1},Y_{1} \right)$ and $\left( X_{2},Y_{2} \right)$ are coprime positive integer solutions of $x^{2} - \left( a^{2}+b^{2} \right)y^{4}=-b^{2}$ with $Y_{2}>Y_{1}>1$, then $Y_{2}>7.98b^{3}$ by Lemma \[lem:3.3\]. Therefore, we can apply Lemma \[lem:thm\] to show that there is no solution $(X,Y)$, other than $\left( X_{2},Y_{2} \right)$, with $Y>b^{2}/2$. Thus this theorem holds.

[10]{} S. Akhtari, The Diophantine equation $aX^{4}-bY^{2} = 1$, [*Journal für die reine und angewandte Mathematik*]{} [**630**]{} (2009), 33–57.

A. Baker, Rational approximations to $\sqrt[3]{2}$ and other algebraic numbers, [*Quarterly J. Math. Oxford*]{} [**15**]{} (1964), 375–383.

Chen Jian Hua, P. Voutier, Complete solution of the diophantine equation $X^{2}+1=dY^{4}$ and a related family of quartic Thue equations, [*J. Number Theory*]{} [**62**]{} (1997), 71–99.

J. Liouville, Sur des classes très-étendues de quantités dont la valeur n’est ni algébrique, ni même réductible à des irrationnelles algébriques, [*C. R. Acad. Sci. Paris*]{}, Sér. A 18 (1844) 883–885.

W. Ljunggren, Zur Theorie der Gleichung $x^{2}+1=Dy^{4}$, [*Avh. Norsk. Vid. Akad. Oslo*]{} (1942) 1–27.

W. Ljunggren, Über die Gleichung $x^{4}-Dy^{2}=1$, [*Arch. Math. Naturv.*]{} 45 (1942), no. 5.

W. Ljunggren, Ein Satz über die Diophantische Gleichung $Ax^{2}-By^{4}=C$ ($C=1,2,4$), [*Tolfte Skand. Matemheikerkongressen, Lund, 1953*]{}, 188–194 (1954).

W. Ljunggren, On the Diophantine equation $Ax^{4}-By^{2}=C$ ($C=1,4$), [*Math. Scand.*]{} 21 (1967) 149–158.

L. J. Slater, [*Generalized Hypgergeometric Functions*]{}, Cambridge Univ. Press, 1966.

M. Stoll, P. G. Walsh and P. Yuan, The Diophantine equation $X^{2}-\left( 2^{2m}+1 \right) Y^{4} = -2^{2m}$ II, [*Acta Arith.*]{} [**139**]{} (2009), 57–63.

P. M. Voutier, Thue’s Fundamentaltheorem, I: The General Case, [*Acta Arith.*]{} [**143**]{} (2010), 101–144.

P. M. Voutier, Thue’s Fundamentaltheorem, II: Further Refinements and Examples, [*J. Number Theory*]{} [**160**]{} (2016) 215–236.
