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

A053529 a(n) = n! * number of partitions of n.

Original entry on oeis.org

1, 1, 4, 18, 120, 840, 7920, 75600, 887040, 10886400, 152409600, 2235340800, 36883123200, 628929100800, 11769069312000, 230150688768000, 4833164464128000, 105639166144512000, 2464913876705280000, 59606099200327680000, 1525429559126753280000, 40464026199993876480000
Offset: 0

Views

Author

N. J. A. Sloane, Jan 16 2000

Keywords

Comments

Commuting permutations: number of ordered pairs (g, h) in Sym(n) such that gh = hg.
Equivalently sum of the order of all normalizers of all cyclic subgroups of Sym(n). - Olivier Gérard, Apr 04 2012
From Gus Wiseman, Jan 16 2019: (Start)
Also the number of Young tableaux with distinct entries from 1 to n, where a Young tableau is an array obtained by replacing the dots in the Ferrers diagram of an integer partition of n with positive integers. For example, the a(3) = 18 tableaux are:
123 213 132 312 231 321
.
12 21 13 31 23 32
3 3 2 2 1 1
.
1 2 1 3 2 3
2 1 3 1 3 2
3 3 2 2 1 1
(End)

References

  • R. P. Stanley, Enumerative Combinatorics, Cambridge, Vol. 2, 1999; see Problem 5.12, solution.

Crossrefs

Column k=2 of A362827.
Sequences counting pairs of functions from an n-set to itself: A053529, A181162, A239749-A239785, A239836-A239841.

Programs

  • Magma
    a:= func< n | NumberOfPartitions(n)*Factorial(n) >; [ a(n) : n in [0..25]]; // Vincenzo Librandi, Jan 17 2019
    
  • Maple
    seq(count(Permutation(n))*count(Partition(n)),n=1..20); # Zerinvary Lajos, Oct 16 2006
    with(combinat): A053529 := proc(n): n! * numbpart(n) end: seq(A053529(n), n=0..20); # Johannes W. Meijer, Jul 28 2016
  • Mathematica
    Table[PartitionsP[n] n!, {n, 0, 20}] (* T. D. Noe, Jun 19 2012 *)
  • PARI
    N=66; x='x+O('x^N); Vec(serlaplace(exp(sum(k=1, N, x^k/(1-x^k)/k)))) \\ Joerg Arndt, Apr 16 2010
    
  • PARI
    N=66; x='x+O('x^N); Vec(serlaplace(sum(n=0, N, x^n/prod(k=1,n,1-x^k)))) \\ Joerg Arndt, Jan 29 2011
    
  • PARI
    a(n) = n!*numbpart(n); \\ Michel Marcus, Jul 28 2016
    
  • Python
    from math import factorial
    from sympy import npartitions
    def A053529(n): return factorial(n)*npartitions(n) # Chai Wah Wu, Jul 10 2023

Formula

E.g.f: Sum_{n>=0} x^n/(Product_{k=1..n} 1-x^k) = exp(Sum_{n>=1} (x^n/n)/(1-x^n)). - Joerg Arndt, Jan 29 2011
a(n) = Sum{k=1..n} (((n-1)!/(n-k)!)*sigma(k)*a(n-k)), n > 0, and a(0)=1. See A274760. - Johannes W. Meijer, Jul 28 2016
a(n) ~ sqrt(Pi/6)*exp(sqrt(2/3)*Pi*sqrt(n))*n^n/(2*exp(n)*sqrt(n)). - Ilya Gutkovskiy, Jul 28 2016

A181162 Number of commuting functions: the number of ordered pairs (f,g) of functions from {1..n} to itself such that fg=gf (i.e., f(g(i))=g(f(i)) for all i).

Original entry on oeis.org

1, 1, 10, 141, 2824, 71565, 2244096, 83982199, 3681265792, 186047433225, 10716241342240, 697053065658411, 50827694884298784, 4129325095108122637, 371782656333674104624, 36918345387693628911375, 4025196918605160943576576, 479796375191949916361466897
Offset: 0

Views

Author

Jeffrey Norden, Oct 07 2010

Keywords

Comments

Also, the total number of endomorphisms of all directed graphs on n labeled vertices with outdegree of each vertex equal 1. - Max Alekseyev, Jan 09 2015
Seems to be relatively hard to compute for large n. (a(n)-n^n)/2 is always an integer, since it gives the number of unordered pairs of distinct commuting functions.
a(n) is divisible by n as proved by Holloway and Shattuck (2015).
From Joerg Arndt, Jul 21 2014: (Start)
Multiply fg=gf from the right by f to obtain fgf=gff, and use f(gf)=f(fg)=ffg to see ffg=gff; iterate to see f^k g = g f^k for all k>=1; by symmetry g^k f = f g^k holds as well.
More generally, if X and Y are words of length w over the alphabet {f,g}, then X = Y (as functional composition) whenever both words contain j symbols f and k symbols g (and j+k=w). (End)
Functions with the same mapping pattern have the same number of commuting functions, so there is no need to check every pair. - Martin Fuller, Feb 01 2015

Examples

			The a(2) = 10 pairs of maps [2] -> [2] are:
01:  [ 1 1 ]  [ 1 1 ]
02:  [ 1 1 ]  [ 1 2 ]
03:  [ 1 2 ]  [ 1 1 ]
04:  [ 1 2 ]  [ 1 2 ]
05:  [ 1 2 ]  [ 2 1 ]
06:  [ 1 2 ]  [ 2 2 ]
07:  [ 2 1 ]  [ 1 2 ]
08:  [ 2 1 ]  [ 2 1 ]
09:  [ 2 2 ]  [ 1 2 ]
10:  [ 2 2 ]  [ 2 2 ]
- _Joerg Arndt_, Jul 22 2014
		

Crossrefs

A053529 is a similar count for permutations. A254529 is for permutations commuting with functions.

Programs

  • Mathematica
    (* This brute force code allows to get a few terms *)
    a[n_] := a[n] = If[n == 0, 1, Module[{f, g, T}, T = Tuples[Range[n], n]; Table[f = T[[j, #]]&; g = T[[k, #]] &; Table[True, {n}] == Table[f[g[i]] == g[f[i]], {i, n}], {j, n^n}, {k, n^n}] // Flatten // Count[#, True]&]];
    Table[Print[n, " ", a[n]]; a[n], {n, 0, 5}] (* Jean-François Alcover, Sep 24 2022 *)

Extensions

a(11)-a(20) from Martin Fuller, Feb 01 2015

A239749 Number of ordered pairs of functions f,g on a set of n elements into itself satisfying f(f(x)) = g(f(g(x))).

Original entry on oeis.org

1, 1, 6, 87, 2056, 69605, 3201696, 190933435
Offset: 0

Views

Author

Chad Brewbaker, Mar 26 2014

Keywords

Examples

			a(0) = a(1) = 1 since there is only one endofunction for n=0 or 1 and the equation is satisfied trivially. For n=2, each endofunction f on {1,2} is represented by [f(1),f(2)]. The list of a(2) = 6 pairs (f,g) which satisfy the equation is ([1,1], [1,1]), ([1,1], [1,2]), ([1,2], [1,2]), ([1,2], [2,1]), ([2,2], [1,2]), ([2,2], [2,2]). - _Michael Somos_, Mar 26 2014
		

Crossrefs

Extensions

a(6)-a(7) from Giovanni Resta, Mar 26 2014

A255525 1/n! times the number of ordered pairs of permutation functions f,g on n elements where f(g(g(x))) = g(f(f(x))).

Original entry on oeis.org

1, 1, 1, 1, 2, 3, 4, 4, 6, 9, 13, 17, 27, 31, 42, 57, 83, 104
Offset: 0

Views

Author

Paul Boddington, Feb 24 2015

Keywords

Comments

The fact that A239836(n) is a multiple of n! follows from a general result in group theory due to Solomon.

Crossrefs

Cf. A239836.

Formula

a(n) = A239836(n)/n!.

A277337 Number of pairs of functions (f,g) from a set of n elements into itself that are generalized reflexive inverses of each other.

Original entry on oeis.org

1, 1, 6, 87, 2056, 71145, 3355956, 203899087, 15451934016, 1419181414929, 154796303577700, 19713331210664751, 2891162097251141616, 482733064744447450297, 90871916094948544512516, 19125402877558442317308975, 4467829768503489097383022336, 1151133088512781095709101702177, 325279313240363190497696752254276
Offset: 0

Views

Author

David Einstein, Oct 09 2016

Keywords

Comments

The number of pairs of functions (f,g) from a set of n elements into itself such that f(g(f(x))) = f(x) and g(f(g(x))) = g(x).

Examples

			For n=2 the a(2)=6 solutions are
1: [1,1] [1,1]
2: [1,1] [2,2]
3: [2,2] [1,1]
4: [2,2] [2,2]
5: [1,2] [1,2]
6: [2,1] [2,1]
		

Crossrefs

Programs

  • Mathematica
    Flatten[{1, Table[Sum[n!*Binomial[n, k]*k^(2*(n-k))/(n-k)!, {k, 1, n}], {n, 1, 20}]}] (* Vaclav Kotesovec, Oct 21 2016 *)
  • PARI
    a(n) = sum(k = 1, n, n! / (n - k)! * binomial(n, k) * k^(2 * (n - k) ) ); \\ Joerg Arndt, Oct 10 2016

Formula

a(n) = Sum_{k=0..n} ((n! / (n - k)!) * C(n, k) * k^(2 * (n - k))).

Extensions

a(0)=1 prepended by Alois P. Heinz, Oct 20 2016
Showing 1-5 of 5 results.