This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A202018 #91 May 12 2025 05:38:49 %S A202018 41,43,47,53,61,71,83,97,113,131,151,173,197,223,251,281,313,347,383, %T A202018 421,461,503,547,593,641,691,743,797,853,911,971,1033,1097,1163,1231, %U A202018 1301,1373,1447,1523,1601,1681,1763,1847,1933,2021,2111,2203,2297,2393 %N A202018 a(n) = n^2 + n + 41. %C A202018 Euler's famous prime-generating polynomial; a(0) through a(39) are all prime. %D A202018 John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See p. 225. %D A202018 Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See pp. 138-139, 145. %H A202018 Reinhard Zumkeller, <a href="/A202018/b202018.txt">Table of n, a(n) for n = 0..10000</a> %H A202018 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Prime-GeneratingPolynomial.html">Prime-Generating Polynomial</a>. %H A202018 <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (3,-3,1). %F A202018 a(n) = A005846(n) for n < 41, a(41) = A145292(1); %F A202018 Union of A005846 (primes) and A145292 (composites); %F A202018 a(n) = A002378(n) + 41. %F A202018 a(a(n) + n) = a(n)*a(n+1). - _Vladimir Shevelev_, Jul 16 2012 (This identity holds for all sequences of the form n^2 + n + c, _Joerg Arndt_, Jul 17 2012). %F A202018 a(0) = 41 and for n > 0, a(n) = a(n-1) + 2*n. - _Jean-Christophe Hervé_, Sep 27 2014 %F A202018 From _Colin Barker_, Sep 28 2014: (Start) %F A202018 a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3). %F A202018 G.f.: (41*x^2 - 80*x + 41) / (1-x)^3. (End) %F A202018 a(n) = 2*a(n-1) - a(n-2) + 2. - _Vincenzo Librandi_, Mar 04 2016 %F A202018 E.g.f.: (x^2 + 2*x + 41)*exp(x). - _Robert Israel_, Mar 10 2016 %F A202018 Sum_{n>=0} 1/a(n) = tanh(sqrt(163)*Pi/2)*Pi/sqrt(163). - _Amiram Eldar_, May 12 2025 %p A202018 A202018:=n->n^2+n+41: seq(A202018(n), n=0..50); # _Wesley Ivan Hurt_, Sep 28 2014 %t A202018 Table[n^2 + n + 41, {n, 0, 49}] (* _Alonso del Arte_, Dec 08 2011 *) %o A202018 (Haskell) %o A202018 a202018 = (+ 41) . a002378 %o A202018 (PARI) a(n)=n^2+n+41 \\ _Charles R Greathouse IV_, Dec 08 2011 %o A202018 (Magma) [n^2 + n + 41 : n in [0..50]]; // _Wesley Ivan Hurt_, Sep 28 2014 %o A202018 (Scala) (0 to 49).map((n: Int) => n * n + n + 41) // _Alonso del Arte_, Nov 29 2018 %o A202018 (Sage) [n^2+n+41 for n in range(50)] # _G. C. Greubel_, Dec 04 2018 %o A202018 (GAP) List([0..50], n -> n^2 +n+41); # _G. C. Greubel_, Dec 04 2018 %Y A202018 Cf. A060566, A010051, A000040, A002808. %Y A202018 Cf. A002378, A005846, A145292. %Y A202018 Cf. A056561. %K A202018 nonn,easy %O A202018 0,1 %A A202018 _Reinhard Zumkeller_, Dec 08 2011