cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A140890 a(n) = sum of primes in {10*n-9, 10*n-7, 10*n-3, 10*n-1}.

Original entry on oeis.org

10, 60, 52, 68, 131, 112, 128, 223, 172, 97, 420, 113, 127, 407, 149, 308, 330, 352, 181, 780, 0, 211, 679, 472, 241, 508, 532, 548, 564, 293, 307, 941, 0, 668, 696, 712, 367, 752, 772, 397, 810, 419, 421, 1303, 892, 457, 1391, 479, 487, 990, 1012, 0, 1044, 0
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jul 06 2008

Keywords

Examples

			a(1) = 3 + 7 = 10.
a(11) = 101 + 103 + 107 + 109 = 420.
a(21) = 0 (there are no primes in {201, 203, 207, 209}).
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=Plus@@Select[10n-{9,7,3,1},PrimeQ]; Table[f[n],{n,60}] (* Ray Chandler, Feb 20 2009 *)
  • PARI
    a(n)=(10*n-9)*isprime(10*n-9) + (10*n-7)*isprime(10*n-7) + (10*n-3)*isprime(10*n-3) + (10*n-1)*isprime(10*n-1) \\ M. F. Hasler, Jun 15 2008

Formula

a(n) = (10n-9) isprime (10n-9) + (10n-7) isprime (10n-7) + (10n-3) isprime (10n-3) + (10n-1) isprime (10n-1), where isprime = A010051. - M. F. Hasler, Jun 15 2008

Extensions

Corrected and extended by Ray Chandler, Feb 20 2009