login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Natural numbers for which all sums Sum_{i=1..u} K(i/n) (with u ranging from 1 to n) are nonnegative, where K(i/n) is Kronecker symbol of i and n.
0

%I #5 Jul 11 2013 04:19:31

%S 1,2,3,4,6,7,9,10,11,12,14,15,16,23,24,25,26,27,30,31,34,35,36,38,39,

%T 42,44,47,48,49,54,55,56,58,59,62,63,64,66,71,74,75,76,79,81,82,83,86,

%U 87,94,95,96,100,103,106,108,110,111,114,119,120,121,130,131

%N Natural numbers for which all sums Sum_{i=1..u} K(i/n) (with u ranging from 1 to n) are nonnegative, where K(i/n) is Kronecker symbol of i and n.

%o (PARI) firstdiving(n) = {s=0;for(k=1,n,s=s+kronecker(k,n);if(s<0,return(k)));return(0)}

%o for(n=1,500,if((0==firstdiving(n)),print1(n,", ")))

%Y Subsets: A095100, A095102 (gives the prime terms). Cf. A227196-A227198.

%K nonn

%O 1,2

%A _Antti Karttunen_, Jul 06 2013