login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

a(n) = (prime(n-k) + prime(n)) mod 4, where k = (1/2)*(prime(n+1) - prime(n)).
0

%I #9 Nov 17 2018 22:16:10

%S 1,0,2,2,0,2,0,0,0,2,2,2,0,0,2,0,0,2,2,2,2,2,0,0,2,0,2,0,0,0,0,0,0,0,

%T 0,0,2,2,2,0,2,0,2,2,0,2,2,2,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,0,2,2,0,0,

%U 2,2,0,0,2,2,2,0,0,0,0,0,2,0,0,2,2,0,0,2,0,2,0,2,2,2,2,0,2,2,2,2,0,0,0,0,0

%N a(n) = (prime(n-k) + prime(n)) mod 4, where k = (1/2)*(prime(n+1) - prime(n)).

%t Do[k = (Prime[n+1] - Prime[n])/2; Print[Mod[Prime[n-k]+Prime[n], 4]], {n, 3, 100}] (* _Ryan Propper_, Oct 07 2005 *)

%K nonn

%O 2,3

%A _Yasutoshi Kohmoto_, Jan 27 2005

%E More terms from _Ryan Propper_ and _David Wasserman_, Oct 07 2005