OFFSET
1,1
COMMENTS
The composition of functions k(x) factors. k(x) = (x^2 + x + 41)*(c^2*x^2 + (c^2 + 2*c)*x + c^2*41 + c + 1). So k(x) is the product of two integers greater than one and thus composite.
REFERENCES
John Stillwell, Elements of Number Theory, Springer, 2003, page 3.
LINKS
Matt C. Anderson A prime producing polynomial writeup
MAPLE
maxn:=1000:
A:={}:
for n from 1 to maxn do
g:=n^2+n+41:
if isprime(g)=false then
A:=A union {n}:
end if:
end do:
# The set A contains values n such that n^2+n+41 is composite and n < maxn.
c:=1:
x:=-1:
p:=41:
q:=c*x^2-(c+1)*x+c*p:
A2:=A:
while q < maxn do
while q < maxn do
A2:=A2 minus {q}:
A2:=A2 minus {c*x^2+(c+1)*x+c*p}:
x:=x+1:
q:=c*x^2-(c+1)*x+c*p:
end do:
c:=c+1:
x:=-1:
q:=c*x^2-(c+1)*x+c*p:
end do:
A2;
MATHEMATICA
Reap[For[n=1, n<700, n++, If[!PrimeQ[n^2+n+41], If[Reduce[c>0 && n == c*x^2+(c+1)*x+41*c , {c, x}, Integers] === False, Sow[n]]]]][[2, 1]] (* Jean-François Alcover, Apr 30 2014 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Matt C. Anderson, Dec 07 2011
STATUS
approved