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

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A102066 Sum of the first n primes, mod 6. 0
 2, 5, 4, 5, 4, 5, 4, 5, 4, 3, 4, 5, 4, 5, 4, 3, 2, 3, 4, 3, 4, 5, 4, 3, 4, 3, 4, 3, 4, 3, 4, 3, 2, 3, 2, 3, 4, 5, 4, 3, 2, 3, 2, 3, 2, 3, 4, 5, 4, 5, 4, 3, 4, 3, 2, 1, 0, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 3, 2, 3, 2, 1, 2, 3, 4, 3, 2, 3, 2, 3, 2, 3, 2, 3, 4, 3 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,1 COMMENTS Curiosity, it takes almost 60 terms before 1 and 0 appear. Stability arises from near equal (often alternating) occurrences of p mod 6 = 1 and p mod 6 = 5. REFERENCES H. L. Nelson, "Prime Sums", J. Rec. Math., 14 (1981), 205-206. LINKS Table of n, a(n) for n=1..86. FORMULA sum(p(n)) mod 6. EXAMPLE a(5) = 4 since (2+3+5+7+11) mod 6 = 4. MATHEMATICA Mod[Accumulate[Prime[Range[120]]], 6] (* Harvey P. Dale, Jun 19 2014 *) PROG (PARI) a(n) = sum(i=1, n, prime(i)) % 6 \\ Michel Marcus, Jul 12 2013 CROSSREFS Cf. A007504, A103208. Sequence in context: A299212 A249018 A235052 * A279404 A072970 A276320 Adjacent sequences: A102063 A102064 A102065 * A102067 A102068 A102069 KEYWORD easy,nonn AUTHOR Alan Sutcliffe (alansut(AT)ntlworld.com), Dec 28 2004 EXTENSIONS More terms from Harvey P. Dale, Jun 19 2014 STATUS approved

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

Last modified September 26 15:54 EDT 2023. Contains 365660 sequences. (Running on oeis4.)