Solve Diophantine equation $a^2+5ab+3b^2-c^2=0$

158 Views Asked by At

Solve Diophantine equation $a^2+5ab+3b^2-c^2=0$

My thoughts are to express it as $(pa+qb)^2 = c^2 $and then solve it as Pell's equation.

One solution is $(1,9,17)$.I don't know whether it is a fundamental solution or not, since I haven't yet figured out the arrangement into pell's equation form.

2

There are 2 best solutions below

1
On BEST ANSWER

Consider rational solutions to:

$$x^2+5xy+3y^2=1.\tag1$$

We have $(-1,0)$ is a rational solution.

If $p,q$ are relatively prime integers, there are usually two values $t$ such that $(-1+pt,qt)=(-1,0)+t(p,q)$ is a solution, one with $t=0.$

$$\begin{align}0&=(-1+pt)^2+5(-1+pt)qt+3(qt)^2-1\\&=-2pt+p^2t^2-5qt+5pqt^2+3q^2t^2\\&=t(\left(p^2+5pq+3q^2)t-(2p+5q)\right) \end{align}$$

So $t=0$ or $t=\frac{2p+5q}{p^2+5pq+3q^2}.$

The. $$(x,y)=\left(\frac{p^2-3q^2}{p^2+5pq+3q^2},\frac{2pq+5q^2}{p^2+5pq+3q^2}\right)$$

And you get $$(a,b,c)=(p^2-3q^2,2pq+5q^2,p^2+5pq+3q^2).\tag2$$

If $(p,q)=(2,1)$ you get your solution $(1,9,17).$

This won't give primitive solutions, in general. When $(p,q)=(5,-2)$ then $(a,b,c)=(-13,0,-13),$ for example.

If $\gcd(p,q)=1,$ we can show $\gcd(a,b)=1$ or $13.$ It can only be $13$ if $p\equiv 4q\pmod{13}.$


This finds all solutions because there is no non-zero solutions with $c=0.$ This is because, for integers $a,b:$

$$(2a+5b)^2-13b^2=4(a^2+5ab+3b^2)\neq 0$$ unless $(a,b)=(0,0).$


You can get all primitive roots from $p,q$ with $\gcd(p,q)=1$ by using $(2)$ if $p\not\equiv 4q\pmod{13}$ and using $$(a,b,c)=\left(\frac{p^2-3q^2}{13},\frac{2pq+5q^2}{13},\frac{p^2+5pq+3q^2}{13}\right)\tag{3}$$ when $p\equiv 4q\pmod{13}.$ $(3)$ is just $(2)$ with the common factor of $13$ factored out.

6
On

As @thomas-andrews pointed out it can be expressed as

$(2a + 5b)^2 -13b^2 = (2c)^2$

which is generalised Pell's equation form $x^2 -dy^2 = N$

which we can tackle by say Lagrange's algorithm of generalized pell's

PS: Computationally speaking I am not sure whether iterating over all $p,q$ in eq 2 of @thomas-andrews is more efficient or solving $c$ number of generalized pell's equations. Will update the answer once I have the clarity.