This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A242266 #18 Aug 05 2019 04:41:09 %S A242266 0,1,1,1,1,1,2,2,3,2,1,3,2,2,3,3,2,3,3,1,3,2,3,3,5,2,2,6,2,4,1,3,2,3, %T A242266 5,2,2,2,6,6,6,7,2,6,4,4,4,5,6,5,6,3,1,3,7,9,9,2,5,2,2,6,4,5,6,6,4,3, %U A242266 8,3,6,6,7,5,6,9,8,6,4,4 %N A242266 a(n) = |{0 < g < prime(n): g is a primitive root mod prime(n) with g = sum_{j=1..k} prime(j) for some k > 0}|. %C A242266 Conjecture: (i) a(n) > 0 for all n > 1. In other words, for any odd prime p, there is a positive integer k such that the sum of the first k primes is not only a primitive root modulo p but also smaller than p. %C A242266 (ii) For any n > 1, there is a number k among 1, ..., n such that sum_{j=1..k}(-1)^(k-j)*prime(j) is a primitive root modulo prime(n). %C A242266 We have verified parts (i) and (ii) for n up to 700000 and 250000 respectively. Note that prime(700000) > 10^7. %H A242266 Zhi-Wei Sun, <a href="/A242266/b242266.txt">Table of n, a(n) for n = 1..10000</a> %H A242266 Zhi-Wei Sun, <a href="http://arxiv.org/abs/1405.0290">Notes on primitive roots modulo primes</a>, arXiv:1405.0290 [math.NT], 2014. %e A242266 a(4) = 1 since prime(1) + prime(2) = 2 + 3 = 5 is a primitive root modulo prime(4) = 7 with 5 < 7. %e A242266 a(7) = 2 since prime(1) = 2 and prime(1) + prime(2) + prime(3) = 2 + 3 + 5 = 10 are not only primitive roots modulo prime(7) = 17 but also smaller than 17. %e A242266 a(53) = 1 since sum_{j=1..10} prime(j) = 129 is a primitive root modulo prime(53) = 241 with 129 < 241. %t A242266 f[0]=0 %t A242266 f[n_]:=Prime[n]+f[n-1] %t A242266 dv[n_]:=Divisors[n] %t A242266 Do[m=0;Do[If[f[k]>=Prime[n],Goto[cc]];Do[If[Mod[f[k]^(Part[dv[Prime[n]-1],i]),Prime[n]]==1,Goto[aa]],{i,1,Length[dv[Prime[n]-1]]-1}];m=m+1;Label[aa];Continue,{k,1,n}];Label[cc];Print[n," ",m];Continue,{n,1,80}] %Y A242266 Cf. A000040, A008347, A007504, A236966, A239957, A241476, A241504, A241516, A242248, A242250, A242277. %K A242266 nonn %O A242266 1,7 %A A242266 _Zhi-Wei Sun_, May 09 2014