login
A036264
Third differences of primes.
3
-1, 2, -4, 4, -4, 4, 0, -6, 8, -6, 0, 4, 0, -2, -4, 8, -6, 0, 6, -6, 4, 0, -6, 2, 4, -4, 4, 8, -20, 12, -6, 12, -16, 12, -4, -2, 4, -2, -4, 12, -16, 10, -4, 12, -10, -8, 6, 4, 0, -6, 12, -12, 4, 0, -4, 8, -6, 0, 10, -4, -14, 8, 4, 8, -18, 12, -12, 10, 0, 0, -4, 2
OFFSET
1,2
FORMULA
a(n) = -prime(n) + 3*prime(n+1) - 3*prime(n+2) + prime(n+3) = A036263(n+1)-A036263(n). - Robert G. Wilson v, Dec 19 2012
MATHEMATICA
Differences[ Prime@ Range@ 85, 3] (* Robert G. Wilson v, Dec 19 2012 *)
PROG
(PARI) A036264_upto(N=99) = (D(v)=v[^1]-v[^-1])(D(D(primes(N+3)))) \\ M. F. Hasler, Oct 15 2024
(PARI) apply( {A036264(n)=[prime(n+k)|k<-[0..3]]*[-1, 3, -3, 1]~}, [1..99]) \\ M. F. Hasler, Oct 15 2024
CROSSREFS
Cf. A064149 (indices of zeros in this sequence).
Sequence in context: A330601 A088680 A143194 * A105192 A345438 A203638
KEYWORD
sign,changed
STATUS
approved