

A219674


a(n) = smallest prime not included earlier such that a(n4) + a(n3) + a(n2) + a(n1) + a(n) is a prime, with a(1)=1, a(2)=3, a(3)=5, and a(4)=7.


0



1, 3, 5, 7, 13, 19, 17, 11, 23, 31, 67, 41, 29, 43, 47, 37, 71, 53, 61, 59, 73, 101, 79, 89, 97, 83, 109, 113, 107, 151, 127, 103, 131, 149, 137, 139, 163, 173, 157, 179, 167, 181, 193, 191, 197, 229, 199, 223, 239, 227, 241, 233, 211, 251, 257, 271, 269, 313, 263
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,2


LINKS

Table of n, a(n) for n=1..59.


MATHEMATICA

f[s_List] := Block[{pn = s[[4]] + s[[3]] + s[[2]] + s[[1]], p = 2}, While[ MemberQ[s, p]  ! PrimeQ[p + pn], p = NextPrime@ p]; Append[s, p]]; Nest[f, {1, 3, 5, 7}, 55]


CROSSREFS

Cf. A073653.
Sequence in context: A227531 A079481 A291867 * A075571 A077133 A164642
Adjacent sequences: A219671 A219672 A219673 * A219675 A219676 A219677


KEYWORD

easy,nonn


AUTHOR

Robert G. Wilson v, Nov 28 2012


STATUS

approved



