Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #28 Jan 03 2024 17:58:06
%S 0,0,2,21,60,121,207,321,466,645,861,1117,1416,1761,2155,2601,3102,
%T 3661,4281,4965,5716,6537,7431,8401,9450,10581,11797,13101,14496,
%U 15985,17571,19257,21046,22941,24945,27061,29292,31641,34111,36705
%N a(n) = (n-1)*(n-2)^3 - A003878(n-3), with a(1) = a(2) = 0 and a(3) = 2.
%H G. C. Greubel, <a href="/A075681/b075681.txt">Table of n, a(n) for n = 1..1000</a>
%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (4,-6,4,-1).
%F From _Ralf Stephan_, Mar 13 2003: (Start)
%F a(n) = (1/2)*(n^3 + 7*n^2 - 46*n + 50), for n>3.
%F G.f.: x^3*(2 + 13*x - 12*x^2 - x^3 + x^4)/(1-x)^4. (End)
%F From _G. C. Greubel_, Jan 01 2024: (Start)
%F a(n) = (1/2)*(n^3 + 7*n^2 - 46*n + 50) + (-1)^floor((n+2)/2)*binomial(5 -n,2)*[n<4].
%F E.g.f.: (1/2)*(50 - 38*x + 10*x^2 + x^3)*exp(x) - 25 - 6*x + 3*x^2/2! + x^3/3!. (End)
%p A075681:=n->1/2*n^3+7/2*n^2-23*n+25: (0,0,2,seq(A075681(n), n=4..50)); # _Wesley Ivan Hurt_, Sep 06 2015
%t CoefficientList[Series[x^2 (x^4 -x^3 -12 x^2 +13 x +2)/(1-x)^4, {x, 0, 40}], x] (* _Vincenzo Librandi_, Sep 07 2015 *)
%t LinearRecurrence[{4,-6,4,-1}, {0,0,2,21,60,121,207}, 50] (* _G. C. Greubel_, Jan 03 2024 *)
%o (Magma) [0,0,2] cat [1/2*n^3+7/2*n^2-23*n+25: n in [4..50]]; // _Vincenzo Librandi_, Sep 07 2015
%o (SageMath) [(1/2)*(n^3+7*n^2-46*n+50) +(-1)^((n+2)//2)*binomial(5-n,2)*int(n<4) for n in range(1,51)] # _G. C. Greubel_, Jan 01 2024
%Y Cf. A003878.
%K nonn,easy
%O 1,3
%A _Jon Perry_, Oct 12 2002
%E More terms from _Ralf Stephan_, Mar 13 2003