login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A271273 Number of set partitions of [n] into m blocks such that at least one pair of distinct cyclically consecutive blocks (b,c) = (b,(b mod m)+1) exists having no pair of numbers (i,j) = (i,(i mod n)+1) with i member of b and j member of c. 3

%I #8 Feb 15 2017 11:50:22

%S 0,0,0,0,2,16,93,503,2736,15397,90556,558245,3607387,24409819,

%T 172696471,1275310652,9813238958,78548445033,652960116962,

%U 5628482431333,50236822145840,463647958566143,4419123858908203,43445718995990792,440083379418080388,4588225614805060248

%N Number of set partitions of [n] into m blocks such that at least one pair of distinct cyclically consecutive blocks (b,c) = (b,(b mod m)+1) exists having no pair of numbers (i,j) = (i,(i mod n)+1) with i member of b and j member of c.

%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Partition_of_a_set">Partition of a set</a>

%F a(n) = A000110(n) - A271272(n).

%e a(4) = 2: 13|2|4, 1|24|3.

%e a(5) = 16: 124|3|5, 12|35|4, 134|2|5, 135|2|4, 13|25|4, 13|2|45, 13|2|4|5, 14|23|5, 1|235|4, 14|2|3|5, 15|24|3, 1|245|3, 1|24|3|5, 1|25|34, 1|25|3|4, 1|2|35|4.

%p b:= proc(n, i, m, l) option remember; `if`(n=0,

%p `if`(l=[] or {l[]}={1} or i=m and {subsop(1=1, l)[]}=

%p {1}, 1, 0), add(b(n-1, j, max(m, j), `if`(l=[], [1],

%p `if`(j=m+1, subsop(1=0, `if`(j=i+1, [l[],1], [l[],0])),

%p `if`(j=i+1 or j=1 and i=m, subsop(j=1, l), l)))), j=1..m+1))

%p end:

%p a:= n-> combinat[bell](n)-b(n, 0$2, []):

%p seq(a(n), n=0..18);

%t b[n_, i_, m_, l_] := b[n, i, m, l] = If[n == 0, If[l == {} || Union[l] == {1} || i == m && Union@ReplacePart[l, 1 -> 1] == {1}, 1, 0], Sum[b[n-1, j, Max[m, j], If[l == {}, {1}, If[j == m+1, ReplacePart[If[j == i+1, Append[l, 1], Append[l, 0]], 1 -> 0], If[j == i+1 || j == 1 && i == m, ReplacePart[l, j -> 1], l]]]], {j, 1, m+1}]]; a[n_] := BellB[n]-b[n, 0, 0, {}]; Table[a[n], {n, 0, 18}] (* _Jean-François Alcover_, Feb 15 2017, translated from Maple *)

%Y Cf. A000110, A185983, A271271, A271272.

%K nonn

%O 0,5

%A _Alois P. Heinz_, Apr 03 2016

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 13:11 EDT 2024. Contains 371913 sequences. (Running on oeis4.)