This is an elementary question about something way outside my area of expertise. A well-known observation due to Euler is that the polynomial $P(x)=x^2+x+41$ takes on only prime values for the first 40 integer values of $x$ starting with $x=0$, namely the values $41,43,47,53,61,71,83,\cdots,1601$. In particular this gives a rather long sequence of primes such that the differences between successive terms form an arithmetic progression, namely $2,4,6,\cdots$, which is a consequence of $P(x)$ being quadratic. All this is related to the fact that the discriminant of $x^2+x+41$ is $-163$ and the field ${\mathbb Q}(\sqrt{-163})$ has class number 1.

Suppose one asks about the next 40 values of $P(x)$ after the value $P(40)=41^2$. We have $P(41)=1763=41\cdot 43$, also not a prime. After this the next two values $P(42)=1847$ and $P(43)=1933 $ are primes. Then comes $P(44)=2021=43\cdot 47$, then four primes, then $P(49)=2491=47\cdot 53$, then six primes, then $P(56)=3233=53\cdot 61$, then eight primes, then $P(65)=4331=61\cdot 71$, then ten primes, then $P(76)=5893=71\cdot 83$. The next four values are prime as well for $x=77,\ 78,\ 79,\ 80$, completing the second forty values. But then the pattern breaks down and one has $P(81)=6683=41\cdot 163$. Thus, before the breakdown, not only do we get sequences of $2,\ 4,\ 6,\ 8,\ 10$ primes but the non-prime values are the products of two successive terms in the original sequence of prime values $41,\ 43,\ 47,\ 53,\ 61,\ \cdots$. There is a simple explanation for this last fact, the easily-verified identity $P(40+n^2)=P(n-1)P(n)$, so when $n=1,2,3,\cdots$ we get $P(41)=P(0)P(1)=41\cdot 43$, $P(44)=P(1)P(2)=43\cdot47$, etc. However, this does not explain why the intervening values of $P(x)$ should be prime.

I've done an online search to find where this might be discussed, without success, so my question is, what is a reference for this curious behavior of the second 40 values of $P(x)$ (or anything related)? I'm also a little puzzled by the identity for $P(40+x^2)$, though perhaps it comes from the norm function in ${\mathbb Q}(\sqrt{-163})$.