cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-3 of 3 results.

A326493 Sum of multinomials M(n-k; p_1-1, ..., p_k-1), where p = (p_1, ..., p_k) ranges over all partitions of n into distinct parts (k is a partition length).

Original entry on oeis.org

1, 1, 1, 2, 2, 5, 9, 21, 38, 146, 322, 902, 3106, 8406, 35865, 123321, 393691, 1442688, 7310744, 23471306, 129918661, 500183094, 2400722981, 9592382321, 47764284769, 280267554944, 1247781159201, 7620923955225, 36278364107926, 189688942325418, 1124492015730891
Offset: 0

Views

Author

Alois P. Heinz, Sep 22 2019

Keywords

Comments

Number of partitions of [n] such that each block contains its size as an element. So the block sizes have to be distinct. a(6) = 9: 123456, 12|3456, 1345|26, 1346|25, 1456|23, 1|23456, 1|24|356, 1|25|346, 1|26|345.

Crossrefs

Programs

  • Maple
    with(combinat):
    a:= n-> add(multinomial(n-nops(p), map(x-> x-1, p)[], 0),
            p=select(l-> nops(l)=nops({l[]}), partition(n))):
    seq(a(n), n=0..30);
    # second Maple program:
    b:= proc(n, i, p) option remember; `if`(i*(i+1)/2 b(n$3):
    seq(a(n), n=0..31);
  • Mathematica
    b[n_, i_, p_] := b[n, i, p] = If[i(i+1)/2 < n, 0, If[n==0, p!, b[n, i-1, p] + b[n-i, Min[n-i, i-1], p-1]/(i-1)!]];
    a[n_] := b[n, n, n];
    a /@ Range[0, 31] (* Jean-François Alcover, Dec 09 2020, after Alois P. Heinz *)

A364279 Number of permutations of [n] with distinct cycle lengths such that no cycle contains its length as an element.

Original entry on oeis.org

1, 0, 0, 1, 2, 12, 86, 546, 4284, 39588, 416988, 4378848, 54297504, 695592000, 9840307680, 149031686880, 2387863575360, 40338090711360, 736126007279040, 13938942123429120, 279358800902737920, 5894877845100625920, 129943826126987765760, 2985640822908446976000
Offset: 0

Views

Author

Alois P. Heinz, Jul 17 2023

Keywords

Examples

			a(3) = 1: (13)(2).
a(4) = 2: (124)(3), (142)(3).
a(5) = 12: (1235)(4), (1253)(4), (1325)(4), (1352)(4), (1523)(4), (1532)(4), (124)(35), (142)(35), (125)(34), (152)(34), (13)(245), (13)(254).
		

Crossrefs

A364282 Number of partitions of [n] with distinct block sizes such that each block contains exactly one block size different from its own as an element.

Original entry on oeis.org

1, 0, 0, 1, 1, 4, 11, 24, 52, 226, 969, 2281, 8960, 29898, 193202, 1075509, 3346852, 14280775, 75858992, 332978617, 2839114204, 19507400962, 75453432614, 383685116089, 2030801987312, 14025840725149, 77948290561659, 884660446815877, 7273497958681824
Offset: 0

Views

Author

Alois P. Heinz, Jul 17 2023

Keywords

Examples

			a(3) = 1: 13|2.
a(4) = 1: 124|3.
a(5) = 4: 1235|4, 124|35, 125|34, 13|245.
a(6) = 11: 12346|5, 1235|46, 1236|45, 1256|34, 14|2356, 145|2|36, 14|256|3, 146|2|35, 15|246|3, 16|245|3, 156|2|34.
		

Crossrefs

Programs

  • Maple
    f:= proc(n) option remember; `if`(n<2, 1-n, (n-1)*(f(n-1)+f(n-2))) end:
    a:= proc(m) option remember; local b; b:=
          proc(n, i, p) option remember; `if`(i*(i+1)/2
    				
Showing 1-3 of 3 results.