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”).
%I #11 Nov 24 2024 01:43:22
%S 0,0,0,1,0,1,0,0,2,-1,1,1,0,0,0,2,-1,1,1,-1,1,0,0,2,1,0,1,0,-3,4,0,2,
%T -2,3,-1,0,1,0,0,2,-2,3,0,1,-3,0,3,1,0,0,2,-2,2,0,0,2,-1,1,1,-2,-1,4,
%U 1,0,-3,3,-1,3,0,0,0,1,0,1,0,0,2,-1,0,3,-2
%N a(n) = prime(n-1) - floor((prime(n-2) + prime(n-1) + prime(n)) / 3).
%H Bill McEachen, <a href="/A375010/b375010.txt">Table of n, a(n) for n = 3..10002</a>
%e For n=500001 a(n) = 7368787 - floor((7368743 + 7368787 + 7368791)/3) = 14.
%t seq[len_] := (#[[2]] - Floor[Total[#]/3]) & /@ Partition[Prime[Range[len]], 3, 1]; seq[100] (* _Amiram Eldar_, Jul 27 2024 *)
%K sign,easy,changed
%O 3,9
%A _Bill McEachen_, Jul 27 2024