Does there exist any odd integer $n \geq 3$ and $n$ distinct prime numbers $p_1 , p_2, \cdots p_n$ such that all $p_i + p_{i+1} (i = 1,2,\cdots , n$ and $p_{n+1} = p_{1})$ are perfect squares?
Problem
Source: CWMO 2011 Q5
Tags: modular arithmetic, number theory, prime numbers, number theory unsolved
22.05.2012 09:34
No. Suppose there did exist such distinct primes. Then all the squares are divisible by $4$, except possibly two consecutive ones which are $1$ modulo $4$, so $\sum_{k=1}^n (-1)^k \left(p_k+p_{k+1}\right)=-2p_1$ is divisible by $4$ if $p_1\neq 2$, which cannot be, so $p_1=2$. But then $p_2=3 \pmod 4$, $p_3=1\pmod 4$,...,$p_{n-1}=3\pmod 4, p_n=1\pmod 4$, hence $p_n+p_1=3\pmod 4$ is a perfect square, contradiction.
22.05.2012 15:34
Alternatively: Assume $p_1<p_2<\ldots <p_n$ Let $p_i+p_{i+1}=a_i^2$ where indices are taken modulo $n$. Then adding them all up, we get $2(p_1+p_2+\ldots +p_n)=a_1^2+a_2^2+\ldots +a_n^2$ If all of $p_i$ are odd, then $p_1+p_2+\ldots +p_n$ is odd too so $LHS=2\pmod{4}$. Since all $p_i$ are odd, all $a_i$ are even, so $RHS=0\pmod{4}$, a contradiction. So $p_1=2$. Then $4+2(p_2+\ldots +p_n)=a_1^2+a_2^2+\ldots +a_n^2$. Now $p_i>2$ for $i>1$ so all $p_i$ are odd apart from $p_1=2$. Therefore, $a_1$ and $a_n$ are odd while all other $a_i$ are even. Then $RHS=a_1^2+a_n^2=1+1=2\pmod{4}$. But since $p_2+\ldots +p_n$ is even, $LHS=0\pmod{4}$ so again a contradiction, and so no such $n$ exists.
21.07.2012 12:19
Am I wrong? It is clear that $ p_i=1,3 $ (mod 4), and, because $ p_i+p_{i+1} =0 $ (mod 4), we obtain that $p_1 = p_n$ (mod 4), so $p_1+p_n=2$ (mod 4), so the answer is no.
21.07.2012 12:30
You are just repeating half of the solutions above. In plain language, you start with all the primes being odd; then you notice their residues modulo $4$ must alternate between $1$ and $3$; but, because $n$ is odd, that cannot happen. Which leaves the case when one of the primes is $2$, that you never considered (although both full solutions above your attempt contained this in plain view). By my lights, a very poor contribution ...
21.07.2012 13:53
Thank you, I didn't pay attention.
21.07.2012 17:36
I've just realised: assuming $p_1<p_2<\ldots <p_n$ is bogus and is not even used. Instead, just assume $\min (p_1,p_2,\ldots ,p_n)=p_1$ and everything is fine.
02.05.2024 13:30