# Confirmation of Proof: $\pi_n + p_a + p_b \geqslant \sum_{i=1}^4 x_i$.

I was messing around with numbers and I made the following conjecture:

Conjecture:

Let $\pi_n$ be the $n^{\text{th}}$ perfect number; $p_a$ be the prime after $\pi_n$ and $p_b$ be the prime before $\pi_n$. Then, one may always see that\begin{align}\pi_n^{ \ \ 2}+p_a^{ \ \ 2}+p_b^{ \ \ 2}&=\sum_{i=1}^4x_i^{ \ 2}\tag{\exists x_i\in\mathbb{Z}^+} \\ \Leftrightarrow \pi_n + p_a + p_b&\geqslant\sum_{i=1}^4x_i\tag{with equality \Leftrightarrow n = 1}\end{align} (Developed this conjecture from here.)

Does anybody know how to prove /disprove this? I know that by Lagrange's Four-Square Theorem, the first equality is true. However, I am not particularly good at inequalities, strict and nonstrict. I know that every perfect number is of the form $2^{q-1}\left(2^q-1\right)$ for a prime $q$ and for all primes $2^q-1$, thus far. (It is not proven whether or not there exists an odd perfect number, which would mean that $2^{q-1}$ does not divide that, supposing it exists).

Thus, $\pi_n^{ \ \ 2} = 4^{q-1}(4^q - 2^{q+1}+1)$ but this does not really help me. So, I made a new substitution: $$\pi_n = (2^q-1)^2 - \sum_{i=1}^{2^{q-1}-1}(4k-1).\tag{provable by induction}$$ This looks much more appropriate to work with. Squaring this and simplifying, \begin{align}\pi_n^{ \ \ 2} &= \left((2^q-1)^2-\frac 13(3\cdot 2^q-4^q-2)\right)^2 \\ &=\cdots \tag{lots of working out}\\ &= 4^{q-1}(2^q-1)^2.\end{align} But this is exactly what we had before (also proving that it is a perfect number).

What do I do in order to (dis)prove my conjecture?

• It's Lagrange's Theorem, not Langrange's, @user477343. – Jose Arnaldo Bebita-Dris May 10 '18 at 3:51
• @JoseArnaldoBebitaDris sorry about that. I'm not the best at english... so thank you :) – Mr Pie May 10 '18 at 3:52

Your conjecture is not true. In general, there are large number of ways to represent $N$ as sum of four squares as $N$ gets larger ($O(N\sqrt N)$, see Jacobi's Four Square theorem for this. One can conjecture that, some of them will be sufficiently similar to each other and make the sum $\sum_{i=1}^4x_i$ big enough.
For example, Let $n=3$. $\pi_n=496$, $p_a=491$, $p_b=499$, and $LHS=736098$. With a help of computer, I could find$$\pi_n^2+p_a^2+p_b^2=445^2+441^2+434^2+394^2$$ and this is counterexample to your conjecture.
Edit: Also, there exists counterexample for $n=2$ and $n=1$. $$28^2+23^2+29^2=26^2+25^2+23^2+18^2$$ $$6^2+5^2+7^2=7^2+6^2+4^2+3^2$$ Your link only shows one of the numerous ways to represent $N$ as sum of four squares, which is probably computed by the way same as the proof of Lagrange's Four square theorem.
• According to my computer, $$n=2\Rightarrow \pi_n^{ \ \ 2}+p_a^{ \ \ 2}+p_b^{ \ \ 2} = 40^2 + 19^2 + 12^2 + 7^2$$ and $$n=3\Rightarrow \pi_n^{ \ \ 2}+p_a^{ \ \ 2}+p_b^{ \ \ 2} = 613^2+582^2+113^2+54^2$$ so... I think perhaps there might be more solutions, interestingly enough, and of which as you said. – Mr Pie May 9 '18 at 21:29
• Hahah woops. I forgot to accept this as an answer. Congratulations! $$(+1) \ \ \color{green}{\checkmark}$$ – Mr Pie May 12 '18 at 13:06