# Does the expression $x^4 +y^4$ take on all values in $\mathbb{Z}/p\mathbb{Z}$?

As the title asks: does there exist $$N$$ such that, for any prime $$p$$ larger than $$N$$, the expression $$x^4 +y^4$$ takes on all values in $$\mathbb{Z}/p\mathbb{Z}$$?

I have been thinking about this problem for days, but I failed to solve it. Does anyone know whether this is true, or does anyone know any partial results about it?

Partial results:
If $$p=4k+3$$, it easily works
if $$p=4k+1$$, if $$g$$ is a primitive root modulo $$p$$, and $$A_i = \left\{ g^k : k \equiv i \pmod{4} \right\}$$, then at least three of $$A_i (i=0,1,2,3)$$ must be expressed.

• I'm not sure whether you're using $\mathbb{Z}_p$ to denote the ring of $p$-adics or for $\mathbf{Z}/p\mathbf{Z}$. – YCor Apr 1 '20 at 13:32
• @YCor I'm not sure that matters, in the light of Hensel's lemma...by which I suspect that if the statement holds for $\mathbb{Z}/p\mathbb{Z}$, then it holds for $\mathbb{Z}_p$. – Franka Waaldijk Apr 1 '20 at 13:39
• @FrankaWaaldijk sure but it would matter in the way to formulate an answer. – YCor Apr 1 '20 at 13:43
• Ok, I get you now :-) – Franka Waaldijk Apr 1 '20 at 13:43
• Actually it is quite important whether $\mathbb{Z}_p$ means the $p$-adic integers or the finite field. In the latter case the answer is yes, but not in the former case. The problem is that $x^4 + y^4 = p$ has a solution in the $p$-adics if and only if $p$ is split in the $8$th cyclotomic field (i.e. $p \equiv 1 \bmod 8$). The easiest way I know how to prove it over a finite field is via the Hasse-Weil theorem, but probably there is an elementary approach. – Daniel Loughran Apr 1 '20 at 14:34

emtom has found the right reference, but there is a more explicit result in that book (Ireland and Rosen, A Classical Introduction to Modern Number Theory). In fact, Theorem 5 of Chapter 8 (on page 103) directly implies that the number $$N = N_{p,\alpha}$$ of solutions to $$x^4+y^4=\alpha$$ in $$\mathbb{F}_p$$ satisfies the inequality $$\left| N - p \right| \leq M_0 + M_1 p^{1/2}$$ for some $$M_0$$ and $$M_1$$ that are described explicitly in the statement of the theorem (and from that description it easily follows they can be bounded in a way that is independent of $$p$$ or $$\alpha$$).
It then automatically follows that for sufficiently large $$p$$, we will have $$N_{p,\alpha}>0$$ for all $$\alpha$$. In other words, for sufficiently large $$p$$, the expression $$x^4+y^4$$ assumes all values of $$\mathbb{F}_p$$ as $$x$$ and $$y$$ run through $$\mathbb{F}_p$$.
Expanding on a comment, the curve $$X^4+Y^4=aZ^4$$ (for $$a\ne0$$) has genus $$3$$. So the Hasse-Weil bound says $$N_p(a) := \#\bigl\{ [X,Y,Z]\in\mathbb P^2(\mathbb F_p) : X^4+Y^4=aZ^4 \bigr\}$$ satisfies $$\bigl| N_p(a) - p - 1 \bigr| \le 2g\sqrt{p} = 6\sqrt{p}.$$ Thus $$N_p(a) \ge p + 1 - 6\sqrt{p}.$$ There are at most $$4$$ points with $$Z=0$$, so $$\#\bigl\{ (X,Y) \in\mathbb A^2(\mathbb F_p) : X^4+Y^4=a \bigr\} \ge p-3-6\sqrt{p}.$$ So you'll always have a solution provided $$p\ge3+6\sqrt{p}$$, which means that there is always a solution provided $$p\ge43$$.
• By adding a numerical computation, it seems to hold for all $p \geq 31$. For $p=29$, we get e.g. that there are no $x,y \in \mathbb{F}_{29}$ such that $x^4+y^4=4$. – RP_ Apr 1 '20 at 18:42
• @RP That makes sense, I took the worst possible case that there are 4 $\mathbb F_p$ rational points at infinity, but for many values of $p$, there will be less. It ultimately depends on whether $-1$ is a square root, and whether it is a fourth root. – Joe Silverman Apr 1 '20 at 18:57
Not exactly an answer, but in exercise $$18$$ in page $$106$$ of Ireland and Rosen's A Classical Introduction to Modern Number theory it states: Let $$p\equiv 1\mod 4$$ and let $$p=A^2+B^2$$ where we fix $$A$$ by requiring that $$A\equiv 1\mod 4$$. Then $$N=\#\{(x,y)\in\mathbb{F}_p^2\mid x^4+y^4=1\}$$ satisfies $$N=p-3-6A$$ if $$p\equiv1\mod 8$$ and $$N=p+1+2A$$ if $$p\equiv5\mod 8$$.