A conjecture for primes $p\equiv\pm1\pmod5$

For any prime $$p\equiv\pm1\pmod5$$, we can write $$p$$ uniquely in the form $$x_p^2+3x_py_p+y_p^2$$ with $$x_p,y_p\in\mathbb Z$$ and $$x_p>y_p>0$$.

I have the following conjecture.

Conjecture. We have $$\lim_{N\to+\infty}\frac{\sum_{p\le N\atop p\equiv\pm1\pmod5}(3x_p^2+2x_py_p)} {\sum_{p\le N\atop p\equiv\pm1\pmod5}(3y_p^2+2x_py_p)}=4.\tag{*}$$

I have checked this conjecture via computation. For example, \begin{align}\sum_{p\le 2\times10^9\atop p\equiv\pm1\pmod5}(3x_p^2+2x_py_p)=&88916125007243531, \\\sum_{p\le 2\times10^9\atop p\equiv\pm1\pmod5}(3y_p^2+2x_py_p)=&22228898519387861, \\\frac{88916125007243531}{22228898519387861}\approx&4.000023885.\end{align}

Similarly, any prime $$p\equiv1\pmod3$$ can be written uniquely as $$u_p^2+u_pv_p+v_p^2$$ with $$u_p,v_p\in\mathbb Z$$ and $$u_p>v_p>0$$, and I observe that $$\lim_{N\to+\infty}\frac{\sum_{p\le N\atop p\equiv1\pmod3}(u_p^2+2u_pv_p)} {\sum_{p\le N\atop p\equiv1\pmod3}(v_p^2+2u_pv_p)}=2.$$ This is essentially provable in view of Hecke's equidistribution theorem.

QUESTION. How to prove the equality $$(*)$$?

• Note that the conjecture involves the real quadratic field $\mathbb Q(\sqrt5)$, not an imaginary quadratic field. Dec 23 '19 at 4:08
• Hecke's theorem applies to all number fields (with the proper interpretation). In particular, it implies your conjecture. See my response below. Dec 23 '19 at 5:52

Let us consider $$\mathbb{Q}(\sqrt{5})$$ as a subfield of $$\mathbb{R}$$. Let us also consider the positive fundamental unit $$\epsilon:=(1+\sqrt{5})/2$$, whose square generates the group of totally positive units. The conditions on $$x_p$$, $$y_p$$ can be rewritten as $$p=x_p^2+3x_py_p+y_p^2\qquad\Longleftrightarrow\qquad p=(x_p+\epsilon^2 y_p)(x_p+\epsilon^{-2} y_p),$$ $$x_p+\epsilon^{-2} y_p By Hecke's theorem, $$\log(x_p+\epsilon^2 y_p)$$ is equidistributed in $$[\log(p^{1/2}),\log(p^{1/2}\epsilon)]$$, cf. Example 3 in Ch. XV, §5 of Lang: Algebraic number theory. From here we get by a similar argument as in my response here that $$\lim_{N\to+\infty}\frac{\sum_{p\le N\atop p\equiv\pm1\pmod5}(3x_p^2+2x_py_p)} {\sum_{p\le N\atop p\equiv\pm1\pmod5}(3y_p^2+2x_py_p)} =\frac{\int_0^1 (3x(t)^2+2x(t)y(t))\,dt}{\int_0^1 (3y(t)^2+2x(t)y(t))\,dt},$$ where the real functions $$x,y:[0,1]\to\mathbb{R}$$ are defined by the equations $$\epsilon^{-1}x(t)+\epsilon y(t)=\epsilon^{-t}\qquad\text{and}\qquad \epsilon x(t)+\epsilon^{-1}y(t)=\epsilon^t.$$ Solving for $$x(t)$$ and $$y(t)$$, the ratio of the two integrals turns out to be exactly $$4$$. This proves $$(\ast)$$.