A271744 Number of set partitions of [n] such that 5 is the largest element of the last block.
30, 59, 139, 365, 1039, 3149, 10039, 33365, 114799, 406589, 1475239, 5460965, 20550559, 78375629, 302129239, 1174610165, 4597146319, 18085554269, 71434828039, 283020552965, 1123932750079, 4471296246509, 17811907987639, 71027855481365, 283452201569839
Offset: 5
Links
- Alois P. Heinz, Table of n, a(n) for n = 5..1000
- Wikipedia, Partition of a set
- Index entries for linear recurrences with constant coefficients, signature (10,-35,50,-24).
Crossrefs
Column k=5 of A271466.
Programs
-
Magma
I:=[30,59,139,365,1039]; [n le 5 select I[n] else 10*Self(n-1)-35*Self(n-2)+50*Self(n-3)-24*Self(n-4): n in [1..30]]; // Vincenzo Librandi, Apr 13 2016
-
Mathematica
Join[{30}, LinearRecurrence[{10, -35, 50, -24}, {59, 139, 365, 1039}, 30]] (* Vincenzo Librandi, Apr 13 2016 *)
-
PARI
Vec(x^5*(30 - 241*x + 599*x^2 - 460*x^3 + 24*x^4) / ((1 - x)*(1 - 2*x)*(1 - 3*x)*(1 - 4*x)) + O(x^40)) \\ Colin Barker, Dec 24 2017
Formula
G.f.: x^5*(24*x^4-460*x^3+599*x^2-241*x+30)/Product_{j=1..4} (j*x-1).
From Colin Barker, Dec 24 2017: (Start)
a(n) = 8 + 13*2^(n-5) + 7*3^(n-5) + 4^(n-5) for n>5.
a(n) = 10*a(n-1) - 35*a(n-2) + 50*a(n-3) - 24*a(n-4) for n>9.
(End)