OFFSET
1,1
COMMENTS
A prime-generating polynomial constructed from a 3 X 3 matrix.
LINKS
Index entries for linear recurrences with constant coefficients, signature (5,-10,10,-5,1).
FORMULA
G.f.: -x*(11321*x^4-218*x^3+326*x^2-168*x+43) / (x-1)^5. [Colin Barker, Dec 13 2012]
MATHEMATICA
M = {{0, 1, 0}, {0, 0, 1}, {1, 0, 1}}; v[0] = {41, 43, 47}; v[n_] := v[n] = M.v[n - 1] a = Flatten[Table[If[PrimeQ[Abs[v[n][[1]]]], Abs[v[n][[1]]], {}], {n, 1, 20}]] f[x_] = Expand[InterpolatingPolynomial[a, x]] aout = Table[f[n], {n, 1, 40}]
LinearRecurrence[{5, -10, 10, -5, 1}, {43, 47, 131, 397, 12251}, 30] (* Harvey P. Dale, Aug 01 2021 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Roger L. Bagula, May 05 2006
EXTENSIONS
Edited by N. J. A. Sloane, Jun 26 2009
STATUS
approved