login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


A080378
Residues mod 4 of the n-th difference between consecutive primes.
15
1, 2, 2, 0, 2, 0, 2, 0, 2, 2, 2, 0, 2, 0, 2, 2, 2, 2, 0, 2, 2, 0, 2, 0, 0, 2, 0, 2, 0, 2, 0, 2, 2, 2, 2, 2, 2, 0, 2, 2, 2, 2, 2, 0, 2, 0, 0, 0, 2, 0, 2, 2, 2, 2, 2, 2, 2, 2, 0, 2, 2, 2, 0, 2, 0, 2, 2, 2, 2, 0, 2, 0, 2, 2, 0, 2, 0, 0, 0, 2, 2, 2, 2, 2, 0, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 2, 0, 2, 2, 2, 2, 2, 2, 2, 2
OFFSET
1,2
LINKS
FORMULA
a(n) = A001223(n) mod 4.
MATHEMATICA
Table[Mod[Prime[w+1]-Prime[w], 4], {w, 1, 256}]
Mod[Differences[Prime[Range[200]]], 4] (* Zak Seidov, Jun 26 2015 *)
PROG
(Python)
from sympy import prime
def A080378(n): return (prime(n+1)-prime(n))&3 # Chai Wah Wu, Jul 07 2022
CROSSREFS
Sequences related to the differences between successive primes: A001223 (Delta(p)), A028334, A080378, A104120, A330556-A330561.
Sequence in context: A050314 A316344 A122157 * A243865 A120439 A248512
KEYWORD
nonn
AUTHOR
Labos Elemer, Mar 04 2003
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 21 04:06 EDT 2024. Contains 376079 sequences. (Running on oeis4.)