OFFSET
1,1
COMMENTS
k must be congruent to 1 (mod 3) for (k^3 + k + 1)/3 to be an integer. - Michael B. Porter, Apr 07 2010
LINKS
J. Mulder, Table of n, a(n) for n = 1..40000
EXAMPLE
(1 + 4 + 4^3)/3 = 23.
MATHEMATICA
f[n_]:=(1+n+n^3)/3; lst={}; Do[If[PrimeQ[f[n]], AppendTo[lst, f[n]]], {n, 7!}]; lst
Select[Table[(n^3+n+1)/3, {n, 400}], PrimeQ] (* Harvey P. Dale, Aug 28 2012 *)
PROG
(PARI) for(n=0, 200, m=3*n+1; if(isprime((m^3+m+1)/3), print((m^3+m+1)/3))) \\ Michael B. Porter, Apr 07 2010
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Joseph Stephan Orlovsky, Jul 29 2009
STATUS
approved