[go: up one dir, main page]

login
A375010
a(n) = prime(n-1) - floor((prime(n-2) + prime(n-1) + prime(n)) / 3).
0
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, -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, 1, 0, -3, 3, -1, 3, 0, 0, 0, 1, 0, 1, 0, 0, 2, -1, 0, 3, -2
OFFSET
3,9
EXAMPLE
For n=500001 a(n) = 7368787 - floor((7368743 + 7368787 + 7368791)/3) = 14.
MATHEMATICA
seq[len_] := (#[[2]] - Floor[Total[#]/3]) & /@ Partition[Prime[Range[len]], 3, 1]; seq[100] (* Amiram Eldar, Jul 27 2024 *)
CROSSREFS
Sequence in context: A284606 A284019 A286135 * A142475 A051556 A330166
KEYWORD
sign,easy
AUTHOR
Bill McEachen, Jul 27 2024
STATUS
approved