%I #24 May 22 2019 21:04:03
%S 1,6,1709,9268549,295887993624,34155922905682979,
%T 10893033763705794846727,8064519699524417149584982475,
%U 12261371699318896159811165091392898,34949877647533654983311522321749656046802,174047342897498341701547082125166096889157924610,1431472607165249058159939223685478666695036430843693596
%N a(n) = total number of partitions of [1, 2, ..., k] into exactly n blocks, each of size 1, 2, ..., 6, for 0 <= k <= 6n.
%C Also, number of scenarios in the Gift Exchange Game when a gift can be stolen at most 5 times. - _N. J. A. Sloane_, Jan 25 2017
%H Alois P. Heinz, <a href="/A149187/b149187.txt">Table of n, a(n) for n = 0..100</a>
%H Moa Apagodu, David Applegate, N. J. A. Sloane, and Doron Zeilberger, <a href="http://arxiv.org/abs/1701.08394">Analysis of the Gift Exchange Problem</a>, arXiv:1701.08394 [math.CO], 2017.
%H Moa Apagodu, David Applegate, N. J. A. Sloane, and Doron Zeilberger, <a href="/A144416/a144416.txt">On-Line Appendix I to "Analysis of the gift exchange problem"</a>, giving Type D recurrences for G_1(n) through G_15(n) (see A001515, A144416, A144508, A144509, A149187, A281358-A281361)
%H Moa Apagodu, David Applegate, N. J. A. Sloane, and Doron Zeilberger, <a href="/A144416/a144416_1.txt">On-Line Appendix II to "Analysis of the gift exchange problem"</a>, giving Type C recurrences for G_1(n) through G_15(n) (see A001515, A144416, A144508, A144509, A149187, A281358-A281361)
%H David Applegate and N. J. A. Sloane, <a href="http://arxiv.org/abs/0907.0513">The Gift Exchange Problem</a>, arXiv:0907.0513 [math.CO], 2009.
%p with(combinat):
%p b:= proc(n, i, t) option remember; `if`(t*i<n, 0,
%p `if`(n=0, `if`(t=0, 1, 0), add(b(n-i*j, i-1, t-j)*
%p multinomial(n, n-i*j, i$j)/j!, j=0..min(t, n/i))))
%p end:
%p a:= n-> add(b(k, 6, n), k=0..6*n):
%p seq(a(n), n=0..20); # _Alois P. Heinz_, Sep 17 2015
%t multinomial[n_, k_List] := n!/Times @@ (k!); b[n_, i_, t_] := b[n, i, t] = If[t*i < n, 0, If[n == 0, If[t == 0, 1, 0], Sum[b[n-i*j, i-1, t-j]* multinomial[n, Prepend[Array[i&, j], n-i*j]]/j!, {j, 0, Min[t, n/i]}]]]; a[n_] := Sum[b[k, 6, n], {k, 0, 6*n}]; Table[a[n], {n, 0, 20}] (* _Jean-François Alcover_, Dec 06 2016 after _Alois P. Heinz_ *)
%o (PARI) {a(n) = sum(i=n, 6*n, i!*polcoef(sum(j=1, 6, x^j/j!)^n, i))/n!} \\ _Seiichi Manyama_, May 22 2019
%Y Cf. A144512.
%Y The gift scenarios sequences when a gift can be stolen at most s times, for s = 1..9, are A001515, A144416, A144508, A144509, A149187, A281358, A281359, A281360, A281361.
%K nonn
%O 0,2
%A _N. J. A. Sloane_, May 13 2009