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.

A343698 a(n) is the number of preference profiles in the stable marriage problem with n men and n women such that there are n pairs of soulmates (people who rank each other first).

Original entry on oeis.org

1, 2, 384, 40310784, 7608405715845120, 6419592322744320000000000000, 50709051409862934701619019776000000000000000, 6988904507653043786857875068352862005134308147200000000000000000
Offset: 1

Views

Author

Tanya Khovanova and MIT PRIMES STEP Senior group, May 26 2021

Keywords

Comments

For such profiles, each person has exactly one valid partner: their soulmate. Consequently, there is only one stable matching: where the soulmates are married to each other.
For these profiles, the Gale-Shapley algorithm, whether it is men-proposing or women proposing, ends in one round.
This is a subsequence of A001013.

Examples

			For n = 3, there are 3! = 6 ways to pair the men and women into soulmate pairs, then 2! ways to finish each person's preference profile, making 6 * 2!^6 = 384 ways to set up the preference profiles.
		

Crossrefs

Programs

  • Mathematica
    Table[(n - 1)!^(2 n) n!, {n, 10}]

Formula

a(n) = (n - 1)!^(2n) * n!.

A343700 a(n) is the number of preference profiles in the stable marriage problem with n men and n women such that there are no pairs of people who rank each other first.

Original entry on oeis.org

0, 2, 9984, 28419102720, 175302739963548794880, 5801674463718565478400000000000000, 2113937863028052653298578438638220083200000000000000, 15500609395854457241550377325238753195602871153217230602240000000000000000
Offset: 1

Views

Author

Tanya Khovanova and MIT PRIMES STEP Senior group, May 26 2021

Keywords

Comments

Two people who rank each other first are called soulmates. Thus, this sequence enumerates the profiles without soulmates.
This sequence is in contrast to the sequence A343698 which enumerates profiles with n pairs of soulmates.
The preference profiles with the most stable matchings do not have soulmates.

Examples

			For n=2, suppose A and B are the men and C and D are the women, then the only two possibilities are the following: a) A prefers C, C prefers B, B prefers D, and D prefers A; 2) A prefers D, D prefers B, B prefers C, and C prefers A.
		

Crossrefs

Programs

  • Mathematica
    Table[Total[
      Table[(-1)^i Binomial[n, i]^2 (n - 1)!^(2 i) i! n!^(2 n - 2 i), {i,
        0, n}]], {n, 10}]
  • PARI
    a(n) = sum(i=0, n, ((-1)^i * binomial(n, i)^2 * (n - 1)!^(2*i) * i! * n!^(2*n - 2*i))); \\ Michel Marcus, Jan 20 2023

Formula

a(n) = Sum_{i = 0..n} ((-1)^i * binomial(n, i)^2 * (n - 1)!^(2i) * i! * n!^(2n - 2i)).
a(n) = A350558(n)*A284458(n). - Dan Eilers, Jan 17 2023

A350558 a(n) = (n-1)!^(2n).

Original entry on oeis.org

1, 1, 64, 1679616, 63403380965376, 8916100448256000000000000, 10061319724179153710638694400000000000000, 173335925289013982808975076100021379095592960000000000000000, 79317573895713454077105543742169655162315106629579798748776628224000000000000000000
Offset: 1

Views

Author

Dan Eilers, Feb 15 2022

Keywords

Comments

a(n) is the number of ways to arrange the remaining preferences in the stable marriage problem of order n after the first choice of each participant has been determined. The first choices are often treated separately in order to avoid mutual first choices, or to avoid multiple participants with the same first choice.

Crossrefs

Programs

  • Mathematica
    Table[(n-1)!^(2n),{n,1,9}]

Formula

a(n) = (n-1)!^(2n).
a(n) = A343700(n)/A284458(n).
a(n) = A343698(n)/A000142(n).
a(n) = A343699(n)/((n-1)!*n^2*(n^2-1)).
a(n) = A343699(n)/(A000142(n)*n*(n^2-1)).
Showing 1-3 of 3 results.