A274538
Number of set partitions of [n] such that each element is contained in a block whose index parity coincides with the parity of the element.
Original entry on oeis.org
1, 1, 1, 2, 3, 7, 14, 39, 95, 304, 865, 3103, 10038, 39773, 143473, 620382, 2461099, 11504723, 49658054, 249102263, 1159930119, 6205900348, 30959905841, 175763987955, 934068692102, 5602484594053, 31563436487785, 199267671153562, 1185224170637619
Offset: 0
a(3) = 2: 13|2, 1|2|3.
a(4) = 3: 13|24, 1|24|3, 1|2|3|4.
a(5) = 7: 135|24, 13|24|5, 15|24|3, 1|24|35, 15|2|3|4, 1|2|35|4, 1|2|3|4|5.
a(6) = 14: 135|246, 13|246|5, 13|24|5|6, 15|246|3, 15|24|3|6, 1|246|35, 1|24|35|6, 15|26|3|4, 15|2|3|46, 1|26|35|4, 1|2|35|46, 1|26|3|4|5, 1|2|3|46|5, 1|2|3|4|5|6.
-
b:= proc(n, m, t) option remember; `if`(n=0, 1, add(
`if`(irem(j, 2)=t, b(n-1, max(m, j), 1-t), 0), j=1..m+1))
end:
a:= n-> b(n, 0, 1):
seq(a(n), n=0..30);
-
b[n_, m_, t_] := b[n, m, t] = If[n == 0, 1, Sum[If[Mod[j, 2] == t, b[n - 1, Max[m, j], 1 - t], 0], {j, 1, m + 1}]];
a[n_] := b[n, 0, 1];
Table[a[n], {n, 0, 30}] (* Jean-François Alcover, May 23 2018, translated from Maple *)
A274868
Number of set partitions of [n] into exactly four blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 2, 7, 14, 35, 70, 155, 310, 651, 1302, 2667, 5334, 10795, 21590, 43435, 86870, 174251, 348502, 698027, 1396054, 2794155, 5588310, 11180715, 22361430, 44731051, 89462102, 178940587, 357881174, 715795115, 1431590230, 2863245995, 5726491990, 11453115051
Offset: 4
a(6) = 7: 13|24|5|6, 15|24|3|6, 1|24|35|6, 15|26|3|4, 15|2|3|46, 1|26|35|4, 1|2|35|46.
a(7) = 14: 137|24|5|6, 13|24|57|6, 157|24|3|6, 15|24|37|6, 17|24|35|6, 1|24|357|6, 157|26|3|4, 15|26|37|4, 157|2|3|46, 15|2|37|46, 17|26|35|4, 1|26|357|4, 17|2|35|46, 1|2|357|46.
-
Drop[CoefficientList[Series[-x^4/((x - 1) (2 x - 1) (x + 1) (2 x^2 - 1)), {x, 0, 36}], x], 4] (* Michael De Vlieger, Jun 15 2021 *)
A274869
Number of set partitions of [n] into exactly five blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 2, 13, 26, 113, 226, 833, 1666, 5649, 11298, 36561, 73122, 230161, 460322, 1424401, 2848802, 8720657, 17441314, 53021969, 106043938, 320925969, 641851938, 1936736529, 3873473058, 11665150225, 23330300450, 70169841937, 140339683874, 421734846737
Offset: 5
a(6) = 2: 1|26|3|4|5, 1|2|3|46|5.
a(7) = 13: 13|24|5|6|7, 15|24|3|6|7, 1|24|35|6|7, 15|26|3|4|7, 15|2|3|46|7, 1|26|35|4|7, 1|2|35|46|7, 17|26|3|4|5, 1|26|37|4|5, 1|26|3|4|57, 17|2|3|46|5, 1|2|37|46|5, 1|2|3|46|57.
A274870
Number of set partitions of [n] into exactly six blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 3, 22, 66, 311, 933, 3632, 10896, 38337, 115011, 381594, 1144782, 3664507, 10993521, 34404964, 103214892, 318365333, 955095999, 2918309966, 8754929898, 26585715663, 79757146989, 241208177496, 723624532488, 2182538747689, 6547616243067, 19713018571138
Offset: 6
a(7) = 3: 17|2|3|4|5|6, 1|2|37|4|5|6, 1|2|3|4|57|6.
a(8) = 22: 13|24|5|6|7|8, 15|24|3|6|7|8, 1|24|35|6|7|8, 15|26|3|4|7|8, 15|2|3|46|7|8, 1|26|35|4|7|8, 1|2|35|46|7|8, 17|26|3|4|5|8, 1|26|37|4|5|8, 1|26|3|4|57|8, 17|2|3|46|5|8, 1|2|37|46|5|8, 1|2|3|46|57|8, 17|28|3|4|5|6, 17|2|3|48|5|6, 17|2|3|4|5|68, 1|28|37|4|5|6, 1|2|37|48|5|6, 1|2|37|4|5|68, 1|28|3|4|57|6, 1|2|3|48|57|6, 1|2|3|4|57|68.
A274871
Number of set partitions of [n] into exactly seven blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 3, 34, 102, 719, 2157, 12260, 36780, 185457, 556371, 2607078, 7821234, 34949443, 104848329, 453798280, 1361394840, 5763944693, 17291834079, 72085646282, 216256938846, 891613471047, 2674840413141, 10940569830060, 32821709490180, 133469376708409
Offset: 7
a(8) = 3: 1|28|3|4|5|6|7, 1|2|3|48|5|6|7, 1|2|3|4|5|68|7.
a(9) = 34: 13|24|5|6|7|8|9, 15|24|3|6|7|8|9, 1|24|35|6|7|8|9, 15|26|3|4|7|8|9, 15|2|3|46|7|8|9, 1|26|35|4|7|8|9, 1|2|35|46|7|8|9, 17|26|3|4|5|8|9, 1|26|37|4|5|8|9, 1|26|3|4|57|8|9, 17|2|3|46|5|8|9, 1|2|37|46|5|8|9, 1|2|3|46|57|8|9, 17|28|3|4|5|6|9, 17|2|3|48|5|6|9, 17|2|3|4|5|68|9, 1|28|37|4|5|6|9, 1|2|37|48|5|6|9, 1|2|37|4|5|68|9, 1|28|3|4|57|6|9, 1|2|3|48|57|6|9, 1|2|3|4|57|68|9, 19|28|3|4|5|6|7, 1|28|39|4|5|6|7, 1|28|3|4|59|6|7, 1|28|3|4|5|6|79, 19|2|3|48|5|6|7, 1|2|39|48|5|6|7, 1|2|3|48|59|6|7, 1|2|3|48|5|6|79, 19|2|3|4|5|68|7, 1|2|39|4|5|68|7, 1|2|3|4|59|68|7, 1|2|3|4|5|68|79.
A274872
Number of set partitions of [n] into exactly eight blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 4, 50, 200, 1519, 6076, 36564, 146256, 770481, 3081924, 14934774, 59739096, 273905827, 1095623308, 4836291512, 19345166048, 83144608885, 332578435540, 1402399388442, 5609597553768, 23330003686119, 93320014744476, 384220628807964, 1536882515231856
Offset: 8
a(8) = 1: 1|2|3|4|5|6|7|8.
a(9) = 4: 19|2|3|4|5|6|7|8, 1|2|39|4|5|6|7|8, 1|2|3|4|59|6|7|8, 1|2|3|4|5|6|79|8.
A274873
Number of set partitions of [n] into exactly nine blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 4, 70, 280, 2919, 11676, 94944, 379776, 2669361, 10677444, 68321994, 273287976, 1640345707, 6561382828, 37643205652, 150572822608, 836008721925, 3344034887700, 18122573826942, 72490295307768, 385781480224959, 1543125920899836, 8099850233307144
Offset: 9
a(9) = 1: 1|2|3|4|5|6|7|8|9.
a(10) = 4: 1|2(10)|3|4|5|6|7|8|9, 1|2|3|4(10)|5|6|7|8|9, 1|2|3|4|5|6(10)|7|8|9, 1|2|3|4|5|6|7|8(10)|9.
A274874
Number of set partitions of [n] into exactly ten blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 5, 95, 475, 5294, 26470, 227294, 1136470, 8351711, 41758555, 277114769, 1385573845, 8568214932, 42841074660, 251848578952, 1259242894760, 7132223195725, 35661115978625, 196428153720067, 982140768600335, 5296485323226634, 26482426616133170
Offset: 10
a(10) = 1: 1|2|3|4|5|6|7|8|9|(10).
a(11) = 5: 1(11)|2|3|4|5|6|7|8|9|(10), 1|2|3(11)|4|5|6|7|8|9|(10), 1|2|3|4|5(11)|6|7|8|9|(10), 1|2|3|4|5|6|7(11)|8|9|(10), 1|2|3|4|5|6|7|8|9(11)|(10).
A274875
Number of set partitions of [2n] into exactly n blocks such that all odd elements are in blocks with an odd index and all even elements are in blocks with an even index.
Original entry on oeis.org
1, 0, 1, 3, 35, 226, 3632, 36780, 770481, 10677444, 277114769, 4882093495, 151410615066, 3238949008872, 116936529884088, 2943848265346408, 121318690777898613, 3513774792447267240, 162794429514873454259, 5332375501915984656921, 274393112247007415104839
Offset: 0
a(2) = 1: 13|24.
a(3) = 3: 13|246|5, 15|246|3, 1|246|35.
a(4) = 35: 135|246|7|8, 137|246|5|8, 13|246|57|8, 137|248|5|6, 137|24|5|68, 13|248|57|6, 13|24|57|68, 157|246|3|8, 15|246|37|8, 157|248|3|6, 157|24|3|68, 15|248|37|6, 15|24|37|68, 17|246|35|8, 1|246|357|8, 17|248|35|6, 17|24|35|68, 1|248|357|6, 1|24|357|68, 157|268|3|4, 157|26|3|48, 15|268|37|4, 15|26|37|48, 157|28|3|46, 157|2|3|468, 15|28|37|46, 15|2|37|468, 17|268|35|4, 17|26|35|48, 1|268|357|4, 1|26|357|48, 17|28|35|46, 17|2|35|468, 1|28|357|46, 1|2|357|468.
A364267
Total number of blocks in all set partitions of [n] such that each element is contained in a block whose index parity coincides with the parity of the element.
Original entry on oeis.org
0, 1, 2, 5, 9, 24, 55, 169, 454, 1567, 4823, 18422, 63609, 265929, 1014266, 4595861, 19143089, 93286964, 420483103, 2189786125, 10601936382, 58688597511, 303349005967, 1776842374930, 9754696729753, 60223101819493, 349624680839546, 2267363687696309
Offset: 0
a(4) = 9 = 2 + 3 + 4: 13|24, 1|24|3, 1|2|3|4.
a(5) = 24 = 2 + 3 + 3 + 3 + 4 + 4 + 5: 135|24, 13|24|5, 15|24|3, 1|24|35, 15|2|3|4, 1|2|35|4, 1|2|3|4|5.
-
b:= proc(n, m, t) option remember; `if`(n=0, m, add(
`if`(irem(j, 2)=t, b(n-1, max(m, j), 1-t), 0), j=1..m+1))
end:
a:= n-> b(n, 0, 1):
seq(a(n), n=0..30);
Showing 1-10 of 10 results.
Comments