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.

Previous Showing 21-30 of 105 results. Next

A052512 Number of rooted labeled trees of height at most 2.

Original entry on oeis.org

0, 1, 2, 9, 40, 205, 1176, 7399, 50576, 372537, 2936080, 24617131, 218521128, 2045278261, 20112821288, 207162957135, 2228888801056, 24989309310961, 291322555295904, 3524580202643155, 44176839081266360, 572725044269255661, 7668896804574138232, 105920137923940473079
Offset: 0

Views

Author

encyclopedia(AT)pommard.inria.fr, Jan 25 2000

Keywords

Comments

Equivalently, number of mappings f from a set of n elements into itself such that f o f (f applied twice) is constant. - Robert FERREOL, Mar 05 2016

Examples

			From _Robert FERREOL_, Mar 05 2016: (Start)
For n = 3 the a(3) = 9 mappings from {a,b,c} into itself are:
f_1(a) = f_1(b) = f_1(c) = a
f_2(c) = b, f_2(b) = f_2(a) = a
f_3(b) = c, f_3(c) = f_3(a) = a
and 6 others, associated to b and c.
(End)
		

Crossrefs

Cf. A000248 (forests with n nodes and height at most 1).
Cf. A000551.

Programs

  • Magma
    m:=25; R:=PowerSeriesRing(Rationals(), m); b:=Coefficients(R!( x*Exp(x*Exp(x)) )); [0] cat [Factorial(n)*b[n]: n in [1..m-1]]; // G. C. Greubel, May 13 2019
    
  • Maple
    spec := [S,{S=Prod(Z,Set(T1)), T2=Z, T1=Prod(Z,Set(T2))},labeled]: seq(combstruct[count](spec,size=n), n=0..20);
    # second Maple program:
    a:= n-> n*add(binomial(n-1, k)*(n-k-1)^k, k=0..n-1);
    seq(a(n), n=0..30);  # Alois P. Heinz, Mar 15 2013
  • Mathematica
    nn=20; a=x Exp[x]; Range[0,nn]! CoefficientList[Series[x Exp[a], {x,0,nn}], x] (* Geoffrey Critzer, Sep 19 2012 *)
  • PARI
    N=33;  x='x+O('x^N);
    egf=x*exp(x*exp(x));
    v=Vec(serlaplace(egf));
    vector(#v+1,n,if(n==1,0,v[n-1]))
    /* Joerg Arndt, Sep 15 2012 */
    
  • Sage
    m = 20; T = taylor(x*exp(x*exp(x)), x, 0, m); [factorial(n)*T.coefficient(x, n) for n in (0..m)] # G. C. Greubel, May 13 2019

Formula

E.g.f.: x*exp(x*exp(x)).
a(n) = n * A000248(n-1). - Olivier Gérard, Aug 03 2012.
a(n) = Sum_{k=0..n-1} n*C(n-1,k)*(n-k-1)^k. - Alois P. Heinz, Mar 15 2013

A007550 Natural numbers exponentiated twice.

Original entry on oeis.org

1, 4, 20, 127, 967, 8549, 85829, 962308, 11895252, 160475855, 2343491207, 36795832297, 617662302441, 11031160457672, 208736299803440, 4169680371133507, 87648971646028515, 1933298000313801349, 44633323736412392093, 1076069422794010119112
Offset: 1

Views

Author

Keywords

Comments

The subsequence of primes (for n = 4, 5, 7) begins: 127, 967, 85829. The subsequence of semiprimes (for n = 2, 6) begins: 4, 8549. - Jonathan Vos Post, Feb 09 2011

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Programs

  • Maple
    exptr:= proc(p) local g; g:= proc(n) option remember; p(n) +add(binomial(n-1, k-1) *p(k) *g(n-k), k=1..n-1) end: end: a:= exptr(exptr(n->n)): seq(a(n), n=1..30); # Alois P. Heinz, Oct 07 2008
  • Mathematica
    a[n_] := Sum[k^(n-k)*Binomial[n, k]*BellB[k], {k, 0, n}]; Table[a[n], {n, 1, 20}] (* Jean-François Alcover, Feb 11 2014, after Olivier Gérard *)

Formula

E.g.f.: exp(G(x) - 1) - 1, where G(x) = exp(x*exp(x)) = e.g.f. for A000248; clarified by Ilya Gutkovskiy, Jun 25 2018
a(n) = sum( k^(n - k) binomial(n,k) bell(k), k = 0..n ). - Olivier Gérard, Oct 24 2007

A135746 E.g.f.: A(x) = Sum_{n>=0} exp(n^2*x) * x^n/n!.

Original entry on oeis.org

1, 1, 3, 16, 137, 1536, 22417, 407884, 8920641, 230576320, 6928080641, 238375169484, 9288784476193, 406150114297552, 19761959813464065, 1062437048084297596, 62727815353861478273, 4045278841893314992896
Offset: 0

Views

Author

Paul D. Hanna, Nov 27 2007

Keywords

Examples

			E.g.f.: A(x) = 1 + x + 3*x^2/2! + 16*x^3/3! + 137*x^4/4! + 1536*x^5/5! + ...
where A(x) = 1 + exp(x)*x + exp(4*x)*x^2/2! + exp(9*x)*x^3/3! + exp(16*x)*x^4/4! + exp(25*x)*x^5/5! + ...
O.g.f.: F(x) = 1 + x + 3*x^2 + 16*x^3 + 137*x^4 + 1536*x^5 + 22417*x^6 + ...
where F(x) = 1 + x/(1-x)^2 + x^2/(1-4*x)^3 + x^3/(1-9*x)^4 + x^4/(1-16*x)^5 + x^5/(1-25*x)^6 + ...
		

Crossrefs

Cf. A000248.

Programs

  • Mathematica
    Flatten[{1, Table[Sum[Binomial[n, k]*k^(2*(n - k)), {k, 0, n}], {n, 1, 25}]}] (* G. C. Greubel, Nov 05 2016 *)
  • PARI
    {a(n)=sum(k=0,n,binomial(n,k)*(k^2)^(n-k))}
    
  • PARI
    {a(n)=n!*polcoeff(sum(k=0,n,exp(k^2*x +x*O(x^n))*x^k/k!),n)}
    
  • PARI
    {a(n)=polcoeff(sum(k=0, n, x^k/(1-k^2*x +x*O(x^n))^(k+1)), n)} \\ Paul D. Hanna, Aug 08 2009

Formula

a(n) = Sum_{k=0..n} C(n,k)*(k^2)^(n-k).
O.g.f.: Sum_{n>=0} x^n/(1 - n^2*x)^(n+1). - Paul D. Hanna, Aug 08 2009
a(n) ~ n^(n + 1/2) * r^(2*n - 3*r + 1/2) / (sqrt(2*n + 3*r) * (n - r)^(n - r + 1/2)), where r = (n/w) * (1 + (w-1)/((2*w^2 + w - 2)/log(w-1) - w + 2)) and w = LambertW(exp(1)*n). - Vaclav Kotesovec, Jul 05 2022

A177208 Numerators of exponential transform of 1/n.

Original entry on oeis.org

1, 1, 3, 17, 19, 81, 8351, 184553, 52907, 1768847, 70442753, 1096172081, 22198464713, 195894185831, 42653714271997, 30188596935106763, 20689743895700791, 670597992748852241, 71867806446352961329, 8445943795439038164379, 379371134635840861537
Offset: 0

Views

Author

Keywords

Comments

b(n) = a(n)/A177209(n) is the sum over all set partitions of [n] of the product of the reciprocals of the part sizes.
Numerators of moments of Dickman-De Bruijn distribution as shown on page 257 of Cellarosi and Sinai. [Jonathan Vos Post, Jan 07 2012]

Examples

			For n=4, there is 1 set partition with a single part of size 4, 4 with sizes [3,1], 3 with sizes [2,2], 6 with sizes [2,1,1], and 1 with sizes [1,1,1,1]; so b(4) = 1/4 + 4/(3*1) + 3/(2*2) + 6/(2*1*1) + 1/(1^4) = 1/4 + 4/3 + 3/4 + 3 + 1 = 19/4.
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), pp. 228-230.
  • Knuth, Donald E., and Luis Trabb Pardo. "Analysis of a simple factorization algorithm." Theoretical Computer Science 3.3 (1976): 321-348. See Eq. (6.6) and (6.7), page 334.

Crossrefs

Programs

  • Maple
    b:= proc(n) option remember; `if`(n=0, 1,
          add(binomial(n-1, j-1)*b(n-j)/j, j=1..n))
        end:
    a:= n-> numer(b(n)):
    seq(a(n), n=0..25); # Alois P. Heinz, Jan 08 2012
  • Mathematica
    b[n_] := b[n] = If[n==0, 1, Sum[Binomial[n-1, j-1]*b[n-j]/j, {j, 1, n}]]; a[n_] := Numerator[b[n]]; Table[a[n], {n, 0, 25}] (* Jean-François Alcover, Feb 21 2017, after Alois P. Heinz *)
  • PARI
    Vec(serlaplace(exp(sum(n=1,30,x^n/(n*n!),O(x^31)))))

Formula

E.g.f. for fractions is exp(f(z)), where f(z) = sum(k>0, z^k/(k*k!)) = integral(0..z,(exp(t)-1)/t dt) = Ei(z) - gamma - log(z) = -Ein(-z). Here gamma is Euler's constant, and Ei and Ein are variants of the exponential integral.
Knuth & Trabb-Pardo (6.7) gives a recurrence. - N. J. A. Sloane, Nov 09 2022

A235328 Number of ordered pairs of endofunctions (f,g) on a set of n elements satisfying f(x) = g(f(f(x))).

Original entry on oeis.org

1, 1, 6, 69, 1336, 39145, 1598256, 85996561, 5872177536, 494848403793, 50333180780800, 6068500612311841, 854434117410352128, 138752719761249646585, 25714777079368557164544, 5389541081414619785888625, 1267387594395443339970052096, 332074775201035547446532113825
Offset: 0

Views

Author

Chad Brewbaker, Mar 26 2014

Keywords

Comments

This also counts pairs (f,g) satisfying f(x) = g(f^{r}(x)) for r > 1. - David Einstein, Nov 18 2016

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; local b; b:=
          proc(m, i) option remember; `if`(m=0, n^i, `if`(i<1, 0,
            add(b(m-j, i-1)*binomial(m, j)*j, j=0..m)))
          end: forget(b):
          b(n$2)
        end:
    seq(a(n), n=0..20);  # Alois P. Heinz, Jul 23 2014
  • Mathematica
    a[n_] := If[n==0, 1, Sum[k! Binomial[n, k] (n k)^(n - k), {k, 1, n}]]
      Table[a[n],{n,20}] (* David Einstein, Oct 10 2016 *)

Formula

a(n) = Sum_{k=1..n} k! * C(n, k) * (n*k)^(n-k). - David Einstein, Oct 10 2016
a(n) = n! * [x^n] 1/(1 - x*exp(n*x)). - Ilya Gutkovskiy, Nov 26 2017
log(a(n)) ~ log(sqrt(2*Pi) * n^(2*n - n/LambertW(exp(1)*n) + 1/2) / (LambertW(exp(1)*n) * exp(n/LambertW(exp(1)*n)) * (LambertW(exp(1)*n) - 1)^(n*(1 - 1/LambertW(exp(1)*n))))). - Vaclav Kotesovec, Feb 20 2022
More precise asymptotics: a(n) ~ sqrt(2*Pi) * (w^2 - w - 1 + 2/w) * exp(n*(1/w^3 - 1/w)) * n^(2*n + n/w^3 - n/w + 1/2) * (w^2 - 1)^(n*(1 + 1/w^3 - 1/w)) * (1 - w^2 + w^3)^(n/w - n - n/w^3 - 1), where w = LambertW(exp(1)*n). - Vaclav Kotesovec, Feb 23 2022

Extensions

a(6)-a(7) from Giovanni Resta, Mar 26 2014
a(8)-a(17) from Alois P. Heinz, Jul 23 2014

A240989 Expansion of e.g.f. exp(x^2 * (exp(x) - 1)).

Original entry on oeis.org

1, 0, 0, 6, 12, 20, 390, 2562, 11816, 105912, 1063530, 8815070, 81342492, 895185876, 9971185406, 112642410090, 1372455608400, 17750397057392, 236950003516626, 3286258330135734, 47688868443593540, 719345273005797900, 11222288509573985382, 181168865439054099266
Offset: 0

Views

Author

Vaclav Kotesovec, Aug 06 2014

Keywords

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[E^(x^2*(E^x-1)), {x, 0, 20}], x] * Range[0, 20]!
  • PARI
    x='x+O('x^30); Vec(serlaplace(exp(x^2*(exp(x) - 1)))) \\ G. C. Greubel, Nov 21 2017
    
  • PARI
    a(n) = n!*sum(k=0, n\3, stirling(n-2*k, k, 2)/(n-2*k)!); \\ Seiichi Manyama, Jul 09 2022
    
  • PARI
    a_vector(n) = my(v=vector(n+1)); v[1]=1; for(i=1, n, v[i+1]=(i-1)!*sum(j=3, i, j/(j-2)!*v[i-j+1]/(i-j)!)); v; \\ Seiichi Manyama, Jul 09 2022

Formula

a(n) ~ exp((n-r^3)/(2+r)-n) * n^(n+1/2) / (r^n * sqrt((2*r^3*(3+r) + n*(1+r)*(4+r))/(2+r))), where r is the root of the equation r^2*((2+r) * exp(r) - 2) = n.
(a(n)/n!)^(1/n) ~ exp(1/(3*LambertW(n^(1/3)/3))) / (3*LambertW(n^(1/3)/3)).
From Seiichi Manyama, Jul 09 2022: (Start)
a(n) = n! * Sum_{k=0..floor(n/3)} Stirling2(n-2*k,k)/(n-2*k)!.
a(0) = 1; a(n) = (n-1)! * Sum_{k=3..n} k/(k-2)! * a(n-k)/(n-k)!. (End)

A009121 Expansion of e.g.f. cosh(exp(x)*x).

Original entry on oeis.org

1, 0, 1, 6, 25, 100, 481, 2954, 20721, 151848, 1146721, 9111982, 77652169, 710421452, 6891125697, 69961213170, 738718169569, 8108554524112, 92647353941569, 1101958783026134, 13616813607795321, 174287243264606388, 2304515271134124577, 31424734896799742170
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    m:=30; R:=PowerSeriesRing(Rationals(), m); b:=Coefficients(R!(Cosh(x*Exp(x)))); [Factorial(n-1)*b[n]: n in [1..m]]; // G. C. Greubel, Jul 26 2018
  • Maple
    a:= n-> add(`if`(k::odd, 0, binomial(n, k)*k^(n-k)), k=0..n):
    seq(a(n), n=0..25);  # Alois P. Heinz, Jan 15 2018
  • Mathematica
    With[{nn=30},CoefficientList[Series[Cosh[Exp[x]*x],{x,0,nn}],x] Range[ 0,nn]!] (* Harvey P. Dale, Dec 28 2015 *)
  • PARI
    first(n) = x='x+O('x^n); Vec(serlaplace(cosh(exp(x)*x))) \\ Iain Fox, Dec 23 2017
    

Extensions

Extended and signs tested by Olivier Gérard, Mar 15 1997
Definition clarified and prior Mathematica program replaced by Harvey P. Dale, Dec 28 2015

A059300 Triangle of idempotent numbers binomial(n,k)*k^(n-k), version 4.

Original entry on oeis.org

1, 1, 2, 1, 6, 3, 1, 12, 24, 4, 1, 20, 90, 80, 5, 1, 30, 240, 540, 240, 6, 1, 42, 525, 2240, 2835, 672, 7, 1, 56, 1008, 7000, 17920, 13608, 1792, 8, 1, 72, 1764, 18144, 78750, 129024, 61236, 4608, 9, 1, 90, 2880, 41160, 272160, 787500, 860160, 262440, 11520, 10
Offset: 0

Views

Author

N. J. A. Sloane, Jan 25 2001

Keywords

Examples

			Triangle begins:
1;
1,  2;
1,  6,   3;
1, 12,  24,    4;
1, 20,  90,   80,    5;
1, 30, 240,  540,  240,   6;
1, 42, 525, 2240, 2835, 672, 7;
...
		

References

  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 91, #43 and p. 135, [3i'].

Crossrefs

There are 4 versions: A059297-A059300. Diagonals give A001788, A036216, A040075, A050982, A002378, 3*A002417, etc. Row sums are A000248.

Programs

  • Magma
    /* As triangle: */ [[Binomial(n+1,n-k+1)*(n-k+1)^k: k in [0..n]]: n in [0.. 15]]; // Vincenzo Librandi, Aug 22 2015
    
  • Mathematica
    t[n_, k_] := Binomial[n + 1, k]*(n - k + 1)^k; Flatten@Table[t[n, k], {n, 0, 9}, {k, 0, n}] (* Arkadiusz Wesolowski, Mar 23 2013 *)
  • PARI
    for(n=0, 25, for(k=0, n, print1(binomial(n+1,k)*(n-k+1)^k, ", "))) \\ G. C. Greubel, Jan 05 2017

Formula

T(n,k) = binomial(n+1,n-k+1)*(n-k+1)^k. - R. J. Mathar, Mar 14 2013

A210725 Triangle read by rows: T(n,k) = number of forests of labeled rooted trees with n nodes and height at most k (n>=1, 0<=k<=n-1).

Original entry on oeis.org

1, 1, 3, 1, 10, 16, 1, 41, 101, 125, 1, 196, 756, 1176, 1296, 1, 1057, 6607, 12847, 16087, 16807, 1, 6322, 65794, 160504, 229384, 257104, 262144, 1, 41393, 733833, 2261289, 3687609, 4480569, 4742649, 4782969, 1, 293608, 9046648, 35464816, 66025360, 87238720, 96915520, 99637120, 100000000
Offset: 1

Views

Author

N. J. A. Sloane, May 09 2012

Keywords

Examples

			Triangle begins:
  1;
  1,    3;
  1,   10,   16;
  1,   41,  101,   125;
  1,  196,  756,  1176,  1296;
  1, 1057, 6607, 12847, 16087, 16807;
  ...
		

Crossrefs

Diagonals include A000248, A000949, A000950, A000951, A000272.

Programs

  • Maple
    f:= proc(k) f(k):= `if`(k<0, 1, exp(x*f(k-1))) end:
    T:= (n, k)-> coeff(series(f(k), x, n+1), x, n) *n!:
    seq(seq(T(n, k), k=0..n-1), n=1..9); # Alois P. Heinz, May 30 2012
    # second Maple program:
    T:= proc(n, h) option remember; `if`(min(n, h)=0, 1, add(
          binomial(n-1, j-1)*j*T(j-1, h-1)*T(n-j, h), j=1..n))
        end:
    seq(seq(T(n, k), k=0..n-1), n=1..10);  # Alois P. Heinz, Aug 21 2017
  • Mathematica
    f[?Negative] = 1; f[k] := Exp[x*f[k-1]]; t[n_, k_] := Coefficient[Series[f[k], {x, 0, n+1}], x, n]*n!; Table[Table[t[n, k], {k, 0, n-1}], {n, 1, 9}] // Flatten (* Jean-François Alcover, Oct 30 2013, after Maple *)
  • Python
    from sympy.core.cache import cacheit
    from sympy import binomial
    @cacheit
    def T(n, h): return 1 if min(n, h)==0 else sum([binomial(n - 1, j - 1)*j*T(j - 1, h - 1)*T(n - j, h) for j in range(1, n + 1)])
    for n in range(1, 11): print([T(n, k) for k in range(n)]) # Indranil Ghosh, Aug 21 2017, after second Maple code

A354553 Expansion of e.g.f. exp( x * exp(x^3) ).

Original entry on oeis.org

1, 1, 1, 1, 25, 121, 361, 3361, 42001, 275185, 1819441, 30777121, 371238121, 3057311401, 44263763545, 801096528961, 9710981323681, 125367419194081, 2643123767954401, 45840730383002305, 646414025466298681, 13258301279836276441
Offset: 0

Views

Author

Seiichi Manyama, Aug 18 2022

Keywords

Crossrefs

Programs

  • PARI
    my(N=30, x='x+O('x^N)); Vec(serlaplace(exp(x*(exp(x^3)))))
    
  • PARI
    a(n) = n!*sum(k=0, n\3, (n-3*k)^k/(k!*(n-3*k)!));

Formula

a(n) = n! * Sum_{k=0..floor(n/3)} (n - 3*k)^k/(k! * (n - 3*k)!).
Previous Showing 21-30 of 105 results. Next