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-10 of 22 results. Next

A055775 a(n) = floor(n^n / n!).

Original entry on oeis.org

1, 1, 2, 4, 10, 26, 64, 163, 416, 1067, 2755, 7147, 18613, 48638, 127463, 334864, 881657, 2325750, 6145596, 16263866, 43099804, 114356611, 303761260, 807692034, 2149632061, 5726042115, 15264691107, 40722913454, 108713644516
Offset: 0

Views

Author

Henry Bottomley, Jul 12 2000

Keywords

Comments

Stirling's approximation for n! suggests that this should be about e^n/sqrt(pi*2n). Bill Gosper has noted that e^n/sqrt(pi*(2n+1/3)) is significantly better.
n^n/n! = A001142(n)/A001142(n-1), where A001142(n) is product{k=0 to n} C(n,k) (where C() is a binomial coefficient). - Leroy Quet, May 01 2004
There are n^n distinct functions from [n] to [n] or sequences on n symbols of length n, the number of those sequences having n distinct symbols is n!. So the probability P(n) of bijection is n!/n^n. The expected value of the number of functions that we pick until we found a bijection is the reciprocal of P(n), or n^n/n!. - Washington Bomfim, Mar 05 2012

Examples

			a(5)=26 since 5^5=3125, 5!=120, 3125/120=26.0416666...
		

Crossrefs

Programs

Formula

a(n) = floor(A000312(n)/A000142(n)).

Extensions

More terms from James Sellers, Jul 13 2000

A303489 Square array A(n,k), n >= 0, k >= 1, read by antidiagonals: A(n,k) = n! * [x^n] 1/(1 - k*x)^(n/k).

Original entry on oeis.org

1, 1, 1, 1, 1, 6, 1, 1, 8, 60, 1, 1, 10, 105, 840, 1, 1, 12, 162, 1920, 15120, 1, 1, 14, 231, 3640, 45045, 332640, 1, 1, 16, 312, 6144, 104720, 1290240, 8648640, 1, 1, 18, 405, 9576, 208845, 3674160, 43648605, 259459200, 1, 1, 20, 510, 14080, 375000, 8648640, 152152000, 1703116800, 8821612800
Offset: 0

Views

Author

Ilya Gutkovskiy, Apr 24 2018

Keywords

Examples

			Square array begins:
      1,      1,       1,       1,       1,       1,  ...
      1,      1,       1,       1,       1,       1,  ...
      6,      8,      10,      12,      14,      16,  ...
     60,    105,     162,     231,     312,     405,  ...
    840,   1920,    3640,    6144,    9576,   14080,  ...
  15120,  45045,  104720,  208845,  375000,  623645,  ...
=========================================================
A(1,1) = 1;
A(2,1) = 2*3 = 6;
A(3,1) = 3*4*5 = 60;
A(4,1) = 4*5*6*7 = 840;
A(5,1) = 5*6*7*8*9 = 15120, etc.
...
A(1,2) = 1;
A(2,2) = 2*4 = 8;
A(3,2) = 3*5*7 = 105;
A(4,2) = 4*6*8*10 = 1920;
A(5,2) = 5*7*9*11*13 = 45045, etc.
...
A(1,3) = 1;
A(2,3) = 2*5 = 10;
A(3,3) = 3*6*9 = 162;
A(4,3) = 4*7*10*13 = 3640;
A(5,3) = 5*8*11*14*17 = 104720, etc.
...
		

Crossrefs

Columns k=1..5 give A000407, A113551, A303486, A303487, A303488.
Main diagonal gives A061711.

Programs

  • Mathematica
    Table[Function[k, n! SeriesCoefficient[1/(1 - k x)^(n/k), {x, 0, n}]][j - n + 1], {j, 0, 9}, {n, 0, j}] // Flatten
    Table[Function[k, Product[k i + n, {i, 0, n - 1}]][j - n + 1], {j, 0, 9}, {n, 0, j}] // Flatten
    Table[Function[k, k^n Pochhammer[n/k, n]][j - n + 1], {j, 0, 9}, {n, 0, j}] // Flatten

Formula

A(n,k) = Product_{j=0..n-1} (k*j + n).

A291699 a(n) = n^n*(2*n)!/(n!*(n + 1)!).

Original entry on oeis.org

1, 1, 8, 135, 3584, 131250, 6158592, 353299947, 23991418880, 1883638417518, 167960000000000, 16772331868538246, 1854655886442627072, 225005916687384753700, 29718395534545380311040, 4245313393689422607421875, 652233889532678001886494720, 107247390031799133661006687830
Offset: 0

Views

Author

Ilya Gutkovskiy, Aug 30 2017

Keywords

Crossrefs

Main diagonal of A290605.

Programs

  • Maple
    seq(n^n*(2*n)!/n!/(n+1)!, n=0..50); # Robert Israel, Aug 30 2017
  • Mathematica
    Join[{1}, Table[n^n (2 n)!/(n! (n + 1)!), {n, 1, 17}]]
    Table[SeriesCoefficient[2/(1 + Sqrt[1 - 4 n x]), {x, 0, n}], {n, 0, 17}]
    Table[SeriesCoefficient[1/(1 + ContinuedFractionK[-n x, 1, {i, 1, n}]), {x, 0, n}], {n, 0, 17}]
  • PARI
    a(n)=binomial(2*n,n)/(n+1)*n^n \\ Charles R Greathouse IV, Oct 23 2023

Formula

a(n) = [x^n] 2/(1 + sqrt(1 - 4*n*x)).
a(n) = [x^n] 1/(1 - n*x/(1 - n*x/(1 - n*x/(1 - n*x/(1 - n*x/(1 - ...)))))), a continued fraction.
a(n) = n! * [x^n] (BesselI(0,2*n*x) - BesselI(1,2*n*x))*exp(2*n*x).
a(n) = n^n*binomial(2*n,n)/(n + 1).
a(n) = A000312(n)*A000108(n).
a(n) = A290605(n,n).
a(n) ~ 4^n*n^(n-3/2)/sqrt(Pi).

A152684 a(n) is the number of top-down sequences (F_1, F_2, ..., F_n) whereas each F_i is a labeled forest on n nodes, containing i directed rooted trees. F_(i+1) is proper subset of F_i.

Original entry on oeis.org

1, 2, 18, 384, 15000, 933120, 84707280, 10569646080, 1735643790720, 362880000000000, 94121726392108800, 29658516531078758400, 11159820050604594969600, 4942478402320838374195200, 2544989406021562500000000000, 1507645899890367707813511168000
Offset: 1

Views

Author

Fabian Nedic, Dec 10 2008

Keywords

Examples

			a(1) = 1^(1-2)*(1!) = 1.
a(2) = 2^(2-2)*(2!) = 2.
a(3) = 3^(3-2)*(3!) = 18.
		

References

  • Miklos Bona, Introduction to Enumerative Combinatorics, McGraw Hill 2007, Page 276.

Crossrefs

Programs

  • Magma
    [Factorial(n-1)*n^(n-1): n in [1..20]]; // G. C. Greubel, Nov 28 2022
    
  • Maple
    a:= proc(n) option remember; `if`(n=1, 1,
          a(n-1)*(n/(n-1))^(n-3)*n^2)
        end:
    seq(a(n), n=1..20);  # Alois P. Heinz, May 16 2013
  • Mathematica
    Table[n^(n - 1) (n - 1)!, {n, 1, 16}]  (* Geoffrey Critzer, May 10 2013 *)
  • SageMath
    [factorial(n-1)*n^(n-1) for n in range(1,21)] # G. C. Greubel, Nov 28 2022

Formula

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

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

Original entry on oeis.org

1, 2, 17, 352, 13505, 830126, 74717857, 9263893892, 1513712421377, 315230799073690, 81499084718806001, 25612081645835777192, 9615370149488574778177, 4250194195208050117007942, 2184834047906975645398282625, 1292386053018890618812398220876
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 18 2019

Keywords

Crossrefs

Programs

  • Magma
    [Factorial(n)*&+[Binomial(n,k)*n^(n-k)/Factorial(k):k in [0..n]]:n in [0..15]]; // Marius A. Burtea, Dec 18 2019
  • Mathematica
    Join[{1}, Table[n! Sum[Binomial[n, k] n^(n - k)/k!, {k, 0, n}], {n, 1, 15}]]
    Join[{1}, Table[n^n n! LaguerreL[n, -1/n], {n, 1, 15}]]
    Table[n! SeriesCoefficient[Exp[x/(1 - n x)]/(1 - n x), {x, 0, n}], {n, 0, 15}]
  • PARI
    a(n) = n! * sum(k=0, n, binomial(n,k) * n^(n-k)/k!); \\ Michel Marcus, Dec 18 2019
    

Formula

a(n) = n! * [x^n] exp(x/(1 - n*x)) / (1 - n*x).
a(n) = Sum_{k=0..n} binomial(n,k)^2 * n^k * k!.
a(n) ~ sqrt(2*Pi) * BesselI(0,2) * n^(2*n + 1/2) / exp(n). - Vaclav Kotesovec, Dec 18 2019

A131182 Table T(n,k) = n!*k^n, read by upwards antidiagonals.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 2, 2, 1, 0, 6, 8, 3, 1, 0, 24, 48, 18, 4, 1, 0, 120, 384, 162, 32, 5, 1, 0, 720, 3840, 1944, 384, 50, 6, 1, 0, 5040, 46080, 29160, 6144, 750, 72, 7, 1, 0, 40320, 645120, 524880, 122880, 15000, 1296, 98, 8, 1, 0, 362880, 10321920, 11022480, 2949120, 375000, 31104, 2058, 128, 9, 1
Offset: 0

Views

Author

Philippe Deléham, Sep 25 2007

Keywords

Comments

For k>0, T(n,k) is the n-th moment of the exponential distribution with mean = k. - Geoffrey Critzer, Jan 06 2019
T(n,k) is the minimum value of Product_{i=1..n} Sum_{j=1..k} r_j[i] where each r_j is a permutation of {1..n}. For the maximum value, see A331988. - Chai Wah Wu, Sep 01 2022

Examples

			The (inverted) table begins:
k=0: 1, 0,   0,    0,      0,       0, ... (A000007)
k=1: 1, 1,   2,    6,     24,     120, ... (A000142)
k=2: 1, 2,   8,   48,    384,    3840, ... (A000165)
k=3: 1, 3,  18,  162,   1944,   29160, ... (A032031)
k=4: 1, 4,  32,  384,   6144,  122880, ... (A047053)
k=5: 1, 5,  50,  750,  15000,  375000, ... (A052562)
k=6: 1, 6,  72, 1296,  31104,  933120, ... (A047058)
k=7: 1, 7,  98, 2058,  57624, 2016840, ... (A051188)
k=8: 1, 8, 128, 3072,  98304, 3932160, ... (A051189)
k=9: 1, 9, 162, 4374, 157464, 7085880, ... (A051232)
Main diagonal is 1, 1, 8, 162, 6144, 375000, ... (A061711).
		

Crossrefs

Main diagonal gives A061711.

Programs

  • Maple
    T:= (n,k)-> n!*k^n:
    seq(seq(T(d-k, k), k=0..d), d=0..12);  # Alois P. Heinz, Jan 06 2019
  • Python
    from math import factorial
    def A131182_T(n, k): # compute T(n, k)
        return factorial(n)*k**n # Chai Wah Wu, Sep 01 2022

Formula

From Ilya Gutkovskiy, Aug 11 2017: (Start)
G.f. of column k: 1/(1 - k*x/(1 - k*x/(1 - 2*k*x/(1 - 2*k*x/(1 - 3*k*x/(1 - 3*k*x/(1 - ...))))))), a continued fraction.
E.g.f. of column k: 1/(1 - k*x). (End)

A137268 Triangle T(n, k) = k! * (k+1)^(n-k), read by rows.

Original entry on oeis.org

1, 2, 2, 4, 6, 6, 8, 18, 24, 24, 16, 54, 96, 120, 120, 32, 162, 384, 600, 720, 720, 64, 486, 1536, 3000, 4320, 5040, 5040, 128, 1458, 6144, 15000, 25920, 35280, 40320, 40320, 256, 4374, 24576, 75000, 155520, 246960, 322560, 362880, 362880
Offset: 1

Views

Author

Roger L. Bagula, Mar 12 2008

Keywords

Comments

Essentially the same as A104001.

Examples

			Triangle begins as:
    1;
    2,     2;
    4,     6,     6;
    8,    18,    24,     24;
   16,    54,    96,    120,    120;
   32,   162,   384,    600,    720,     720;
   64,   486,  1536,   3000,   4320,    5040,    5040;
  128,  1458,  6144,  15000,  25920,   35280,   40320,   40320;
  256,  4374, 24576,  75000, 155520,  246960,  322560,  362880,  362880;
  512, 13122, 98304, 375000, 933120, 1728720, 2580480, 3265920, 3628800, 3628800;
		

Crossrefs

Programs

  • Magma
    [Factorial(k)*(k+1)^(n-k): k in [1..n], n in [1..12]]; // G. C. Greubel, Nov 28 2022
    
  • Mathematica
    T[n_, k_]:= k!*(k+1)^(n-k);
    Table[T[n, k], {n, 12}, {k, n}]//Flatten
  • SageMath
    def A137268(n,k): return factorial(k)*(k+1)^(n-k)
    flatten([[A137268(n,k) for k in range(1,n+1)] for n in range(14)]) # G. C. Greubel, Nov 28 2022

Formula

J(b, n) = (b+1)^(n-b)*b! if n > b, otherwise n! (notation of Chung and Graham).
From G. C. Greubel, Nov 28 2022: (Start)
T(n, k) = k! * (k+1)^(n-k).
T(n, n-2) = 2*A074143(n), n > 1.
T(2*n, n) = A152684(n).
T(2*n, n-1) = A061711(n).
T(2*n+1, n+1) = A066319(n). (End)

Extensions

Edited by G. C. Greubel, Nov 28 2022

A231601 Number of permutations of [n] avoiding ascents from odd to even numbers.

Original entry on oeis.org

1, 1, 1, 4, 8, 54, 162, 1536, 6144, 75000, 375000, 5598720, 33592320, 592950960, 4150656720, 84557168640, 676457349120, 15620794116480, 140587147048320, 3628800000000000, 36288000000000000, 1035338990313196800, 11388728893445164800, 355902198372945100800
Offset: 0

Views

Author

Alois P. Heinz, Nov 11 2013

Keywords

Examples

			a(0) = 1: ().
a(1) = 1: 1.
a(2) = 1: 21.
a(3) = 4: 132, 213, 231, 321.
a(4) = 8: 1324, 2413, 2431, 3241, 4132, 4213, 4231, 4321.
a(5) = 54: 13245, 13254, 13524, ..., 54213, 54231, 54321.
a(6) = 162: 132465, 132546, 132645, ..., 654213, 654231, 654321.
		

Crossrefs

Column k=0 of A231777.
Bisection gives: A061711 (even part).

Programs

  • Maple
    a:= n-> ceil(n/2)!*ceil(n/2)^floor(n/2):
    seq(a(n), n=0..30);

Formula

a(n) = ceiling(n/2)! * ceiling(n/2)^floor(n/2).
a(n) = A081123(n+1) * A110138(n).

A062871 a(n) is the integer part of the geometric mean of n! and n^n.

Original entry on oeis.org

1, 1, 2, 12, 78, 612, 5795, 64425, 822470, 11856945, 190494094, 3374719083, 65351559893, 1373320643022, 31124359701926, 756718320351008, 19645797269948963, 542437979097898912, 15871685747774947592
Offset: 0

Views

Author

Olivier Gérard, Jun 26 2001

Keywords

Crossrefs

Programs

  • Mathematica
    Floor[Sqrt[n!*n^n]]
  • PARI
    a(n)={sqrtint(n! * n^n)} \\ Harry J. Smith, Aug 12 2009
    
  • Python
    from math import isqrt, factorial
    def A062871(n): return isqrt(factorial(n)*n**n) # Chai Wah Wu, Jun 19 2024

A274844 The inverse multinomial transform of A001818(n) = ((2*n-1)!!)^2.

Original entry on oeis.org

1, 8, 100, 1664, 34336, 843776, 24046912, 779780096, 28357004800, 1143189536768, 50612287301632, 2441525866790912, 127479926768287744, 7163315850315825152, 431046122080208896000, 27655699473265974050816, 1884658377677216933085184
Offset: 1

Views

Author

Johannes W. Meijer, Jul 27 2016

Keywords

Comments

The inverse multinomial transform [IML] transforms an input sequence b(n) into the output sequence a(n). The IML transform inverses the effect of the multinomial transform [MNL], see A274760, and is related to the logarithmic transform, see A274805 and the first formula.
To preserve the identity MNL[IML[b(n)]] = b(n) for n >= 0 for a sequence b(n) with offset 0 the shifted sequence b(n-1) with offset 1 has to be used as input for the MNL.
In the a(n) formulas, see the examples, the cumulant expansion numbers A127671 appear.
We observe that the inverse multinomial transform leaves the value of a(0) undefined.
The Maple programs can be used to generate the inverse multinomial transform of a sequence. The first program is derived from a formula given by Alois P. Heinz for the logarithmic transform, see the first formula and A001187. The second program uses the e.g.f. for multivariate row polynomials, see A127671 and the examples. The third program uses information about the inverse of the inverse of the multinomial transform, see A274760.
The IML transform of A001818(n) = ((2*n-1)!!)^2 leads quite unexpectedly to A005411(n), a sequence related to certain Feynman diagrams.
Some IML transform pairs, n >= 1: A000110(n) and 1/A000142(n-1); A137341(n) and A205543(n); A001044(n) and A003319(n+1); A005442(n) and A000204(n); A005443(n) and A001350(n); A007559(n) and A000244(n-1); A186685(n+1) and A131040(n-1); A061711(n) and A141151(n); A000246(n) and A000035(n); A001861(n) and A141044(n-1)/A001710(n-1); A002866(n) and A000225(n); A000262(n) and A000027(n).

Examples

			Some a(n) formulas, see A127671:
a(0) = undefined
a(1) = (1/0!) * (1*x(1))
a(2) = (1/1!) * (1*x(2) - x(1)^2)
a(3) = (1/2!) * (1*x(3) - 3*x(2)*x(1) + 2*x(1)^3)
a(4) = (1/3!) * (1*x(4) - 4*x(3)*x(1) - 3*x(2)^2 + 12*x(2)*x(1)^2 - 6*x(1)^4)
a(5) = (1/4!) * (1* x(5) - 5*x(4)*x(1) - 10*x(3)*x(2) + 20*x(3)*x(1)^2 + 30*x(2)^2*x(1) -60*x(2)*x(1)^3 + 24*x(1)^5)
		

References

  • Richard P. Feynman, QED, The strange theory of light and matter, 1985.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, 1995, pp. 18-23.

Crossrefs

Programs

  • Maple
    nmax:=17: b := proc(n): (doublefactorial(2*n-1))^2 end: c:= proc(n) option remember; b(n) - add(k*binomial(n, k)*b(n-k)*c(k), k=1..n-1)/n end: a := proc(n): c(n)/(n-1)! end: seq(a(n), n=1..nmax); # End first IML program.
    nmax:=17: b := proc(n): (doublefactorial(2*n-1))^2 end: t1 := log(1+add(b(n)*x^n/n!, n=1..nmax+1)): t2 := series(t1, x, nmax+1): a := proc(n): n*coeff(t2, x, n) end: seq(a(n), n=1..nmax); # End second IML program.
    nmax:=17: b := proc(n): (doublefactorial(2*n-1))^2 end: f := series(exp(add(t(n)*x^n/n, n=1..nmax)), x, nmax+1): d := proc(n): n!*coeff(f, x, n) end: a(1):=b(1): t(1):= b(1): for n from 2 to nmax+1 do t(n) := solve(d(n)-b(n), t(n)): a(n):=t(n): od: seq(a(n), n=1..nmax); # End third IML program.
  • Mathematica
    nMax = 22; b[n_] := ((2*n-1)!!)^2; c[n_] := c[n] = b[n] - Sum[k*Binomial[n, k]*b[n-k]*c[k], {k, 1, n-1}]/n; a[n_] := c[n]/(n-1)!; Table[a[n], {n, 1, nMax}] (* Jean-François Alcover, Feb 27 2017, translated from Maple *)

Formula

a(n) = c(n)/(n-1)! with c(n) = b(n) - Sum_{k=1..n-1}(k*binomial(n, k)*b(n-k)*c(k)), n >= 1 and a(0) = undefined, with b(n) = A001818(n) = ((2*n-1)!!)^2.
a(n) = A000079(n-1) * A005411(n), n >= 1.
Showing 1-10 of 22 results. Next