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-6 of 6 results.

A362362 Number of permutations of [n] such that each cycle contains its length as an element.

Original entry on oeis.org

1, 1, 1, 3, 8, 36, 174, 1104, 7440, 62640, 545040, 5649840, 60681600, 748621440, 9518342400, 136758585600, 2009451628800, 32848492723200, 549241915622400, 10066913176320000, 188293339922688000, 3832031198451456000, 79291640831090688000, 1771146970953744384000
Offset: 0

Views

Author

Alois P. Heinz, Jul 05 2023

Keywords

Comments

The cycle lengths are distinct as a consequence of the definition.

Examples

			a(3) = 3: (123), (132), (1)(23).
a(4) = 8: (1234), (1243), (1324), (1342), (1423), (1432), (1)(234), (1)(243).
		

Crossrefs

Programs

  • Maple
    a:= n-> add((n-nops(p))!, p=select(l-> nops(l)=
            nops({l[]}), combinat[partition](n))):
    seq(a(n), n=0..24);
    # second Maple program:
    b:= proc(n, i, p) option remember; `if`(i*(i+1)/2 b(n$3):
    seq(a(n), n=0..24);
  • 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]]];
    a[n_] := b[n, n, n];
    Table[a[n], {n, 0, 24}] (* Jean-François Alcover, Nov 15 2023, from second Maple program *)

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

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

Original entry on oeis.org

1, 1, 1, 3, 3, 9, 29, 57, 135, 615, 2635, 6273, 25151, 82623, 525281, 2941047, 9100709, 38766777, 205155713, 902705793, 7714938567, 52987356783, 204844103977, 1042657233471, 5520661314689, 38159472253821, 211945677298567, 2404720648663335, 19773733727088813
Offset: 0

Views

Author

Alois P. Heinz, Sep 22 2019

Keywords

Comments

Number of partitions of [n] with distinct block sizes such that each block contains exactly one block size as an element. a(5) = 9: 12345, 1235|4, 124|35, 125|34, 12|345, 134|25, 135|24, 13|245, 1|2345.

Crossrefs

Programs

  • Maple
    with(combinat):
    a:= n-> add(multinomial(n-nops(p), map(x-> x-1, p)[], 0), p=map(h->
        permute(h)[], select(l-> nops(l)=nops({l[]}), partition(n)))):
    seq(a(n), n=0..28);
    # second Maple program:
    a:= proc(m) option remember; local b; b:=
          proc(n, i, j) option remember; `if`(i*(i+1)/2>=n,
           `if`(n=0, (m-j)!*j!, b(n, i-1, j)+
            b(n-i, min(n-i, i-1), j+1)/(i-1)!), 0)
          end: b(m$2, 0):
        end:
    seq(a(n), n=0..28);
  • Mathematica
    a[m_] := a[m] = Module[{b}, b[n_, i_, j_] := b[n, i, j] = If[i(i + 1)/2 >= n, If[n == 0, (m - j)! j!, b[n, i - 1, j] + b[n - i, Min[n - i, i - 1], j + 1]/(i - 1)!], 0]; b[m, m, 0]];
    a /@ Range[0, 28] (* Jean-François Alcover, May 10 2020, after 2nd Maple program *)

A363881 Number of partitions of [n] such that no block contains its size as an element.

Original entry on oeis.org

1, 0, 0, 1, 3, 13, 50, 230, 1110, 5787, 32335, 191950, 1206247, 7997702, 55733468, 406952888, 3105706421, 24710573792, 204547052598, 1758110677909, 15663244043627, 144412976181189, 1375896762258868, 13528184875421816, 137098357090429007, 1430440534060723253
Offset: 0

Views

Author

Alois P. Heinz, Jul 17 2023

Keywords

Examples

			a(0) = 1: () the empty partition.
a(3) = 1: 13|2.
a(4) = 3: 124|3, 13|2|4, 14|2|3.
a(5) = 13: 1235|4, 124|35, 124|3|5, 125|34, 125|3|4, 13|245, 13|2|45, 13|2|4|5, 145|2|3, 14|2|35, 14|2|3|5, 15|2|34, 15|2|3|4.
a(6) = 50: 12346|5, 1235|46, 1235|4|6, 1236|45, ..., 15|2|3|4|6, 16|2|35|4, 16|2|3|45, 16|2|3|4|5.
		

Crossrefs

A364207 Number of partitions of [n] such that the minimal element of each block is also its size.

Original entry on oeis.org

1, 1, 0, 1, 0, 0, 3, 1, 0, 0, 60, 45, 53, 24, 7, 12601, 15120, 33390, 55710, 66522, 86037, 37907754, 63130067, 202203684, 511378789, 1421634137, 2566309603, 5855352202, 2064277450957, 4418631559288, 18485494082571, 61020702809287, 232959438927000, 783244248553960
Offset: 0

Views

Author

Alois P. Heinz, Jul 13 2023

Keywords

Comments

The block sizes are distinct as a consequence of the definition.
There are A188431(n) different block size configurations for a given n. - John Tyler Rascoe, Jul 19 2023

Examples

			a(0) = 1: () the empty partition.
a(1) = 1: 1.
a(3) = 1: 1|23.
a(6) = 3: 1|24|356, 1|25|346, 1|26|345.
a(7) = 1: 1|23|4567.
a(10) = 60: 1|25|367|489(10), 1|25|368|479(10), 1|25|369|478(10), ..., 1|28|39(10)|4567, 1|29|38(10)|4567, 1|2(10)|389|4567.
a(14) = 7: 1|23|4568|79(10)(11)(12)(13)(14), 1|23|4569|78(10)(11)(12)(13)(14), 1|23|456(10)|789(11)(12)(13)(14), 1|23|456(11)|789(10)(12)(13)(14), 1|23|456(12)|789(10)(11)(13)(14), 1|23|456(13)|789(10)(11)(12)(14), 1|23|456(14)|789(10)(11)(12)(13).
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(i*(i+1)/2n or i>n-i+1, 0, b(n-i, i-1)*binomial(n-i, i-1))))
        end:
    a:= n-> b(n$2):
    seq(a(n), n=0..33);  # Alois P. Heinz, Jul 22 2023
  • Mathematica
    b[n_, i_] := b[n, i] = If[i(i+1)/2 < n, 0, If[n == 0, 1, b[n, i-1] + If[i > n || i > n-i+1, 0, b[n-i, i-1]*Binomial[n-i, i-1]]]];
    a[n_] := b[n, n];
    Table[a[n], {n, 0, 33}] (* Jean-François Alcover, Oct 20 2023, after Alois P. Heinz *)

A364278 Number of partitions of [n] with distinct block sizes such that no block contains its size as an element.

Original entry on oeis.org

1, 0, 0, 1, 1, 4, 24, 47, 153, 669, 5628, 13554, 61747, 247170, 1539565, 16979571, 53166394, 268393296, 1382097160, 7831424654, 59720804940, 917256305956, 3326800474687, 20441030261195, 112690616749302, 773175024537549, 5164903931159843, 52976603588044961
Offset: 0

Views

Author

Alois P. Heinz, Jul 17 2023

Keywords

Examples

			a(0) = 1: () the empty partition.
a(3) = 1: 13|2.
a(4) = 1: 124|3.
a(5) = 4: 1235|4, 124|35, 125|34, 13|245.
		

Crossrefs

Showing 1-6 of 6 results.