OFFSET
1,1
FORMULA
a(n) =If Prime Abs[a(n-1)+Prime[n-1]+1]
MATHEMATICA
a[0] = 2; a[1] = 7; a[2] = 13; a[n_] := a[n] = Abs[a[n - 1] - Prime[n - 1] + 1] a0 = Flatten[Table[If[PrimeQ[a[n]], a[n], {}], {n, 0, 100}]]
CROSSREFS
KEYWORD
nonn,uned
AUTHOR
Roger L. Bagula, Jul 01 2007
STATUS
approved