%I #14 Sep 08 2022 08:45:49
%S 1,7,41,215,1041,4767,21001,90055,378881,1572527,6463161,26375895,
%T 107081521,433076287,1746588521,7029269735,28245956961,113370724047,
%U 454644109081,1822061123575,7298700653201,29226175283807
%N Number of ways of partitioning the multiset {1,1,2,3,...,n-1} into exactly four nonempty parts.
%C The number of ways of partitioning the multiset {1, 1, 2, 3, ..., n-1} into exactly two, three and five nonempty parts are given in A083329, A168583 and A168585, respectively.
%H M. Griffiths, I. Mezo, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL13/Griffiths/griffiths11.html">A generalization of Stirling Numbers of the Second Kind via a special multiset</a>, JIS 13 (2010) #10.2.5.
%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (10,-35,50,-24).
%F For a>=4, a(n) = (5*4^(n-3) - 3^(n-1) + 3*2^(n-2) - 2)/3.
%F The shifted exponential generating function is (20e^(4x) - 27e^(3x) + 12e^(2x) - 2e^x)/3.
%F The ordinary generating function is x^4(1-3x+6x^2)/((1-x)(1-2x)(1-3x)(1-4x)).
%p A168584:=n->(5*4^(n-3)-3^(n-1)+3*2^(n-2)-2)/3: seq(A168584(n), n=4..30); # _Wesley Ivan Hurt_, Dec 12 2015
%t f2[n_] := 1/3 (5 4^(n - 3) - 3^(n - 1) + 3 2^(n - 2) - 2); Table[f2[n], {n, 4, 25}]
%t LinearRecurrence[{10,-35,50,-24},{1,7,41,215},30] (* _Harvey P. Dale_, Sep 15 2020 *)
%o (Magma) [(5*4^(n-3)-3^(n-1)+3*2^(n-2)-2)/3: n in [4..30]]; // _Wesley Ivan Hurt_, Dec 12 2015
%Y Cf. A083329, A168583, A168585.
%K nonn,easy
%O 4,2
%A _Martin Griffiths_, Nov 30 2009