%I #14 Aug 04 2019 11:41:05
%S 0,0,1,0,1,2
%N Number of undirected circular permutations tau(1), ..., tau((p_n-1)/2) of 1, ..., (p_n-1)/2 such that the (p_n-1)/2 numbers tau(1)^2 + tau(2)^2, tau(2)^2 + tau(3)^2, ..., tau((p_n-3)/2)^2 + tau((p_n-1)/2)^2, tau((p_n-1)/2)^2 + tau(1)^2 give all the (p_n-1)/2 quadratic residues modulo p_n, where p_n is the n-th prime.
%C Conjecture: a(n) > 0 for all n > 6. In other words, for any prime p = 2*n+1 > 13, there is a circular permutation a_1, ..., a_n of the n quadratic residues modulo p such that a_1+a_2, a_2+a_3, ..., a_{n-1}+a_n, a_n+a_1 give all the n quadratic residues modulo p.
%C Zhi-Wei Sun also made the following general conjecture:
%C Let F be a finite field with |F| = q = 2*n+1 > 13. Let S = {a^2: a is a nonzero element of F} and T = (F\{0})\S. Then there is a circular permutation a_1, ..., a_n of S such that {a_1+a_2, ..., a_{n-1}+a_n, a_n+a_1} = S (or T). Also, there exists a circular permutation b_1, ..., b_n of S with {b_1-b_2, ..., b_{n-1}-b_n, b_n-b_1} = S (or T).
%H Zhi-Wei Sun, <a href="http://arxiv.org/abs/1309.1679">Some new problems in additive combinatorics</a>, preprint, arXiv:1309.1679 [math.NT], 2013-2014.
%e a(5) = 1 due to the circular permutation (1,2,4,3,5). Note that 1^2+2^2, 2^2+4^2, 4^2+3^2, 3^2+5^2, 5^2+1^2 give the 5 quadratic residues modulo p_5 = 11.
%e a(7) = 1 due to the circular permutation (1,5,8,6,4,3,2,7).
%e a(8) = 2 due to the circular permutations
%e (1,2,4,8,3,6,7,5,9) and (1,4,3,7,9,2,8,6,5).
%t (* A program to compute required circular permutations for n = 8. Note that p_8 = 19. To get "undirected" circular permutations, we should identify a circular permutation with the one of the opposite direction. Thus a(8) is half of the number of circular permutations yielded by this program. *)
%t V[i_]:=Part[Permutations[{2,3,4,5,6,7,8,9}],i]
%t m=0
%t Do[If[Union[Table[Mod[If[j==0,1,Part[V[i],j]]^2+If[j<8,Part[V[i],j+1],1]^2,19],{j,0,8}]]!=Union[Table[Mod[k^2,19],{k,1,9}]],Goto[aa]]; m=m+1;Print[m,":"," ",1," ",Part[V[i],1]," ",Part[V[i],2]," ",Part[V[i],3]," ",Part[V[i],4]," ",Part[V[i],5]," ",Part[V[i],6]," ",Part[V[i],7]," ",Part[V[i],8]];Label[aa];Continue,{i,1,8!}]
%Y Cf. A229038.
%K nonn,more,hard
%O 3,6
%A _Zhi-Wei Sun_, Oct 02 2013
|