OFFSET
1,1
MATHEMATICA
a={2, 1, 2}; Print[2]; Print[2]; For[n=3, n<=1000, n++, sum=Plus@@a; If[PrimeQ[sum], Print[sum]]; a=RotateLeft[a]; a[[3]]=sum]
Select[LinearRecurrence[{1, 1, 1}, {2, 1, 2}, 300], PrimeQ] (* Harvey P. Dale, Jul 30 2015 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert Price, Dec 05 2013
EXTENSIONS
More terms from Harvey P. Dale, Jul 30 2015
STATUS
approved