login
1 - (5/6)*n + (5/2)*n^2 + (10/3)*n^3 + n^4.
1

%I #12 Sep 08 2022 08:45:02

%S 1,7,52,192,507,1101,2102,3662,5957,9187,13576,19372,26847,36297,

%T 48042,62426,79817,100607,125212,154072,187651,226437,270942,321702,

%U 379277,444251,517232,598852,689767,790657,902226,1025202,1160337

%N 1 - (5/6)*n + (5/2)*n^2 + (10/3)*n^3 + n^4.

%H Harvey P. Dale, <a href="/A057675/b057675.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(0)=1, a(1)=7, a(2)=52, a(3)=192, a(4)=507, a(n)=5*a(n-1)- 10*a(n-2)+ 10*a(n-3)-5*a(n-4)+a(n-5). - _Harvey P. Dale_, Apr 28 2016

%F G.f.: (1+2*x+27x^2-8*x^3+2*x^4)/(1-x)^5. - _Vincenzo Librandi_, Apr 30 2016

%t Table[1-(5n)/6+(5n^2)/2+(10n^3)/3+n^4,{n,0,40}] (* or *) LinearRecurrence[ {5,-10,10,-5,1},{1,7,52,192,507},40] (* _Harvey P. Dale_, Apr 28 2016 *)

%t CoefficientList[Series[(1 + 2 x + 27 x^2 - 8 x^3 + 2 x^4)/(1 - x)^5, {x, 0, 33}], x] (* _Vincenzo Librandi_, Apr 30 2016 *)

%o (Magma) [1-(5/6)*n+(5/2)*n^2+(10/3)*n^3+n^4: n in [0..50]]; // _Vincenzo Librandi_, Apr 30 2016

%o (PARI) a(n)=n^4 + 10/3*n^3 + 5/2*n^2 - 5/6*n + 1 \\ _Charles R Greathouse IV_, Apr 30 2016

%K nonn,easy

%O 0,2

%A _N. J. A. Sloane_, Oct 19 2000