%I #46 Oct 29 2024 19:06:55
%S 1,3,21,91,273,651,1333,2451,4161,6643,10101,14763,20881,28731,38613,
%T 50851,65793,83811,105301,130683,160401,194923,234741,280371,332353,
%U 391251,457653,532171,615441,708123,810901,924483,1049601,1187011,1337493,1501851,1680913
%N a(n) = (n^2 - n + 1)*(n^2 + n + 1).
%C Main diagonal of A082039. - _Paul Barry_, Apr 02 2003
%C The base of the natural logarithms e = 2*Sum_{n>=0} 1/(a(n)*n!) and zeta(2) = Pi^2/6 = 1 + 2*Sum_{n>=1} (-1)^(n+1)/(a(n)*n^2). - _Peter Bala_, Jan 20 2008
%H Harry J. Smith, <a href="/A059826/b059826.txt">Table of n, a(n) for n = 0..1000</a>
%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (5,-10,10,-5,1).
%F a(n) = n^4+n^2+1. - _Paul Barry_, Apr 02 2003
%F a(n) = (n^2-n+1) * (n^2+n+1) = A002061(n) * A002061(n+1), products of two consecutive central polygonal numbers. a(n) = (n^6-1)/(n^2-1), n>1. a(n) = (n^5-n^4+n^3-n^2+n-1)/(n-1) = A062159(n)/(n-1), n>1. - _Alexander Adamchuk_, Apr 12 2006
%F O.g.f.: (-1+2*x-16*x^2-6*x^3-3*x^4) / (x-1)^5. - _R. J. Mathar_, Feb 26 2008
%F a(n) = A219069(n,1), for n > 0. - _Reinhard Zumkeller_, Nov 11 2012
%F a(n+2) = (n^2+3n+3) * (n^2+5n+7) = (t(n)+t(n+2)) * (t(n+1)+t(n+3)), where t=A000217 are triangular numbers. For n>=1, a(n+2) = t(2*t(n+2)+t(n)) -t(t(n)-1). - _J. M. Bergot_, Nov 29 2012
%F 4*a(n) = (n^2+n+1)^2+(n^2-n+1)^2+(n^2+n-1)^2+(n^2-n-1)^2. [_Bruno Berselli_, Jul 03 2014]
%F a(n) = A002061(n^2). - _Franklin T. Adams-Watters_, Aug 01 2014
%F Sum_{n>=0} 1/a(n) = 1/2 + sqrt(3)*Pi*tanh(sqrt(3)*Pi/2)/6. - _Amiram Eldar_, Feb 14 2021
%p with(combinat): seq(fibonacci(3,n)+n^4, n=0..40); # _Zerinvary Lajos_, May 25 2008
%t Table[n^4 + n^2 + 1, {n, 0, 50}] (* _Wesley Ivan Hurt_, Jun 09 2014 *)
%o (PARI) { for (n=0, 1000, f=n^2 + 1; write("b059826.txt", n, " ", (f - n)*(f + n)); ) } \\ _Harry J. Smith_, Jun 29 2009
%o (Magma) [n^4+n^2+1 : n in [0..50]]; // _Wesley Ivan Hurt_, Jun 09 2014
%Y Cf. A002061, A062159.
%Y Main diagonal of A082039.
%K nonn,easy,changed
%O 0,2
%A _N. J. A. Sloane_, Feb 24 2001