login
a(n) = p modulo prime(n+1), where p is the least prime greater than 4 and not congruent to any previous a(k) modulo prime(k+1).
0

%I #4 Oct 19 2017 03:14:28

%S 2,2,6,8,5,9,4,4,21,10,15,29,27,41,29,35,8,63,18,14,14,48,78,56,66,1,

%T 31,37,31,104,96,1,85,97,12,151,151,151,133,139,163,145,145,139,187,

%U 54,211,217,18,32,26,36,235,217,211,259,54,72,86,108,128,72,74,78,92,222,192

%N a(n) = p modulo prime(n+1), where p is the least prime greater than 4 and not congruent to any previous a(k) modulo prime(k+1).

%o (PARI) { p=vector(1000,i,prime(i+1)); p[1]=0;cp=3; while (cp<500, i=1;while (p[i]==0,i++); x=p[i]%cp; print1(","x); for (j=1,1000,if (p[j]%cp==x,p[j]=0)); cp=nextprime(cp+1)) }

%K nonn

%O 1,1

%A _Jon Perry_, Apr 06 2004

%E Edited by _Don Reble_, Nov 07 2005