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 *)

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

Original entry on oeis.org

1, 1, 2, 3, 6, 10, 27, 55, 171, 475, 1555, 4915, 20023, 68243, 288024, 1213828, 5435935, 23966970, 121432923, 578757824, 3130381590, 16427772974, 91877826663, 519546134163, 3199523135912, 18868494152257, 120274458082095, 772954621249540, 5219747666882153
Offset: 0

Views

Author

Alois P. Heinz, Sep 22 2019

Keywords

Comments

Number of partitions of [n] whose block sizes are nondecreasing when blocks are ordered by their minima and these minima are {1..k} (for some k <= n). a(5) = 10: 12345, 13|245, 14|235, 15|234, 1|2345, 1|24|35, 1|25|34, 1|2|345, 1|2|3|45, 1|2|3|4|5.

Crossrefs

Programs

  • Maple
    with(combinat):
    a:= n-> add(multinomial(n-nops(p), map(
        x-> x-1, p)[], 0), p=partition(n)):
    seq(a(n), n=0..28);
    # second Maple program:
    b:= proc(n, i, p) option remember; `if`(n=0, p!, `if`(i<2, 0,
          b(n, i-1, p)) +b(n-i, min(n-i, i), p-1)/(i-1)!)
        end:
    a:= n-> b(n$3):
    seq(a(n), n=0..28);
  • Mathematica
    b[n_, i_, p_] := b[n, i, p] = If[n == 0, p!, If[i < 2, 0, b[n, i - 1, p]] + b[n - i, Min[n - i, i], p - 1]/(i - 1)!];
    a[n_] := b[n, n, n];
    a /@ Range[0, 28] (* Jean-François Alcover, May 01 2020, from 2nd Maple program *)

A364281 Number of permutations of [n] with distinct cycle lengths such that each cycle contains exactly one cycle length as an element.

Original entry on oeis.org

1, 1, 1, 4, 10, 48, 252, 1584, 10800, 93600, 823680, 8588160, 93381120, 1158312960, 14805504000, 215028172800, 3159494553600, 51973589606400, 873152856576000, 16058241239040000, 300754643245056000, 6159522883497984000, 127439374149255168000
Offset: 0

Views

Author

Alois P. Heinz, Jul 17 2023

Keywords

Examples

			a(3) = 4: (123), (132), (13)(2), (1)(23).
a(4) = 10: (1234), (1243), (1324), (1342), (1423), (1432), (124)(3),
   (142)(3), (1)(234), (1)(243).
		

Crossrefs

Programs

  • Maple
    a:= proc(m) option remember; local b; b:=
          proc(n, i, p) option remember; `if`(i*(i+1)/2
    				
  • Mathematica
    a[m_] := a[m] = Module[{b}, b[n_, i_, p_] := b[n, i, p] = If[i(i+1)/2 < n, 0, If[n == 0, p!*(m - p)!, b[n, i - 1, p] + b[n - i, Min[n - i, i - 1], p - 1]]]; b[m, m, m]];
    Table[a[n], {n, 0, 24}] (* Jean-François Alcover, Oct 21 2023, after Alois P. Heinz *)

Formula

Conjecture: a(n) ~ exp(1) * (n-1)!. - Vaclav Kotesovec, May 23 2025
Showing 1-3 of 3 results.