

A140365


a(n) = sum of primes in {6*n5, 6*n1}.


0



5, 18, 30, 42, 29, 31, 78, 90, 53, 59, 61, 138, 73, 162, 89, 0, 198, 210, 222, 0, 0, 258, 137, 139, 149, 151, 157, 330, 173, 179, 181, 191, 390, 199, 0, 211, 0, 450, 462, 239, 241, 251, 257, 263, 269, 271, 558, 283, 293, 0, 0, 618, 630, 0, 0, 331, 337, 347, 702
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,1


LINKS



FORMULA

a(n) = (6n5)*isprime(6n5) + (6n1)*isprime(6n1), where isprime = A010051.  M. F. Hasler, Jun 15 2008


EXAMPLE

6*11  5 = 61 is prime, but 6*11  1 = 65 is not prime, so a(11) = 61.


MAPLE

a:= n> add(i, i=select(isprime, [6*n5, 6*n1])):


PROG

(PARI) a(n)=(6*n5)*isprime(6*n5)+(6*n1)*isprime(6*n1) \\ M. F. Hasler, Jun 15 2008
(Python)
from sympy import isprime
def a(n): return sum(k*isprime(k) for k in {6*n5, 6*n1})


CROSSREFS



KEYWORD

nonn


AUTHOR



EXTENSIONS



STATUS

approved



