4

According to OEIS Sequence A002476 (https://oeis.org/A002476), it says that all primes of the form $6n+1$ can be written in the form: $x^2 - xy + 7y^2$ with $x$ and $y$ non-negative. I was wondering if anyone had a proof of this.

Thanks!

Hamed
  • 6,793

1 Answers1

5

We can write $$ x^2-xy+7y^2=\Big(x-\frac{1+3\sqrt{-3}}{2}y\Big)\Big(x-\frac{1-3\sqrt{-3}}{2}y\Big) $$

so (since $\mathbb{Q}(\sqrt{-3})$ is a PID) determining which primes can be written in the form $x^2-xy+7y^2$ reduces to the question of which primes split in $\mathbb{Q}(\sqrt{-3})$.

If $p$ is an odd prime, then $p$ splits in $\mathbb{Q}(\sqrt{-3})$ if and only if $(\frac{-3}{p})=1$. By quadratic reciprocity we have $$ \Big(\frac{-3}{p}\Big)=\Big(\frac{-1}{p}\Big)\Big(\frac{3}{p}\Big)=\Big(\frac{p}{3}\Big) $$ hence $(\frac{-3}{p})=1$ if and only if $p\equiv 1$ (mod $3$). Since $p$ is odd, this means that $p$ splits in $\mathbb{Q}(\sqrt{-3})$ if and only if $p\equiv 1$ (mod $6$).

This of course leaves out the case $p=2$, but for this note that if $x^2-xy+7y^2$ is even then both $x$ and $y$ must be even, in which case $x^2-xy+7y^2$ must be divisible by $4$.

carmichael561
  • 53,688
  • Can you explain why every prime that splits in $\mathbb Q(\sqrt{-3})$ must split into factors of the given form? I feel like some discussion of class numbers or just some simple local argument is missing here. There seems to be constraints modulo $3$ that are being glossed over. And what about the non-negativity of $x,y$? – Erick Wong Jul 01 '16 at 17:39
  • Good point, I should mention that the class number is $1$. I didn't think about the non-negativity, but I imagine that this can be dealt with by multiplying by an appropriate unit. – carmichael561 Jul 01 '16 at 17:56