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 1370 results. Next

A134980 a(n) = Sum_{k=0..n} binomial(n,k)*n^(n-k)*A000110(k).

Original entry on oeis.org

1, 2, 10, 77, 799, 10427, 163967, 3017562, 63625324, 1512354975, 40012800675, 1166271373797, 37134022033885, 1282405154139046, 47745103281852282, 1906411492286148245, 81267367663098939459, 3683790958912910588623, 176937226305157687076779
Offset: 0

Views

Author

Vladeta Jovovic, Feb 04 2008

Keywords

Comments

Main diagonal of array "The first r-Bell numbers", p.3 of Mezo, A108087. - Jonathan Vos Post, Sep 25 2009
Number of partitions of [2n] where at least n blocks contain their own index element. a(2) = 10: 134|2, 13|24, 13|2|4, 14|23, 1|234, 1|23|4, 14|2|3, 1|24|3, 1|2|34, 1|2|3|4. - Alois P. Heinz, Jan 07 2022

Crossrefs

Main diagonal of A108087.
Cf. A000110.

Programs

  • Maple
    with(combinat): a:= n-> add(binomial(n, k)*n^(n-k)*bell(k), k=0..n):
    seq(a(n), n=0..20); # Emeric Deutsch, Mar 02 2008
    # Alternate:
    g:= proc(n) local S;
      S:= series(exp(exp(x)+n*x-1),x,n+1);
    n!*coeff(S,x,n);
    end proc:
    map(g, [$0..30]); # Robert Israel, Sep 29 2017
    # third Maple program:
    b:= proc(n, k) option remember; `if`(n=0, 1,
          k*b(n-1, k)+ b(n-1, k+1))
        end:
    a:= n-> b(n$2):
    seq(a(n), n=0..20);  # Alois P. Heinz, Aug 04 2021
  • Mathematica
    a[n_] := n!*SeriesCoefficient[Exp[Exp[x] + n*x - 1], {x, 0, n}]; Array[a, 19, 0] (* Jean-François Alcover, Sep 28 2017, after Ilya Gutkovskiy *)
    Join[{1}, Table[Sum[Binomial[n,k]*n^(n-k)*BellB[k], {k,0,n}], {n,1,20}]] (* Vaclav Kotesovec, Jun 09 2020 *)
  • Sage
    def A134980(n):
        return add(binomial(n, k)*n^(n-k)*bell_number(k) for k in (0..n))
    [A134980(n) for n in (0..18)]  # Peter Luschny, May 05 2013

Formula

a(n) = exp(-1)*Sum_{k>=0} (n+k)^n/k!.
E.g.f.: A(x) = exp(-1)*Sum_{k>=0} (1+k*x)^k/k!.
a(n) = Sum_{k=0..n} Stirling1(n,k)*A000110(n+k). - Vladeta Jovovic, Nov 08 2009
a(n) = n! * [x^n] exp(exp(x) + n*x - 1). - Ilya Gutkovskiy, Sep 26 2017
a(n) ~ exp(exp(1) - 1) * n^n. - Vaclav Kotesovec, Jun 09 2020

Extensions

More terms from Emeric Deutsch, Mar 02 2008

A091768 Similar to Bell numbers (A000110).

Original entry on oeis.org

1, 2, 6, 22, 92, 426, 2150, 11708, 68282, 423948, 2788230, 19341952, 141003552, 1076787624, 8589843716, 71404154928, 617151121998, 5535236798058, 51426766394244, 494145546973656, 4903432458931118, 50181840470551778, 529009041574922566
Offset: 0

Views

Author

Jon Perry, Mar 06 2004

Keywords

Comments

Equals row sums of triangle A163946. - Gary W. Adamson, Aug 06 2009

Examples

			The Bell numbers can be generated by;
1
1 2
2 3 5
5 7 10 15
where the Bell numbers are the last entry on each line. This last entry is the first entry on the next line and then the last two entries of the previous column are added, e.g. 7=5+2, 10=7+3, 15=10+5.
This version adds ALL of the entries in the previous column to the new entry.
1
1 2
2 4 6
6 10 16 22
where 10=6+2+1+1, 16=10+2+4, 22=16+6
		

Crossrefs

Close to A074664
Cf. A000110 (Bell Numbers), A033184, A000108, A163946.

Programs

  • Mathematica
    nmax=21; b = ConstantArray[0,nmax]; b[[1]]=1; Do[b[[n+1]] = Binomial[2*n, n]/(n+1) + Sum[b[[k+1]]*Binomial[2*n-k-1, n-k-1]*(k+2)/(n+1),{k,0,n-1}],{n,1,nmax-1}]; b (* Vaclav Kotesovec, Mar 13 2014 *)
  • PARI
    v=vector(20); for (i=1,20,v[i]=vector(i)); v[1][1]=1; for (i=2,20, v[i][1]=v[i-1][i-1]; for (j=2,i, v[i][j]=v[i][j-1]+sum(k=j-1,i-1,v[k][j-1]))); for (i=1,20,print1(","v[i][i]))
    
  • PARI
    a(n)=binomial(2*n,n)/(n+1)+sum(k=0,n-1,a(k)*binomial(2*n-k-1,n-k-1)*(k+2)/(n+1)) \\ Paul D. Hanna, Aug 13 2008
    
  • PARI
    a(n)=local(A=1+x*O(x^n),C=serreverse(x-x^2+x^2*O(x^n))/x); for(i=0,n,A=C+x*C^2*subst(A,x,x*C));polcoeff(A,n) \\ Paul D. Hanna, Aug 13 2008

Formula

From Paul D. Hanna, Aug 13 2008: (Start)
G.f. satisfies: (1-x)*A(x-x^2) = 1 + x*A(x).
G.f. satisfies: A(x) = C(x) + x*C(x)^2*A(x*C(x)), where C(x) is the Catalan function (A000108).
a(n) = A000108(n) + Sum_{k=0..n-1} a(k)*C(2*n-k-1,n-k-1)*(k+2)/(n+1) for n>=0; eigensequence (shift left) of the Catalan triangle A033184. (End)

Extensions

More terms from Vincenzo Librandi, Mar 15 2014

A224417 Least prime p such that sum_{k=0}^n B_k*x^{n-k} is irreducible modulo p, where B_k refers to the Bell number A000110(k).

Original entry on oeis.org

2, 3, 2, 11, 3, 2, 193, 113, 2, 29, 71, 167, 19, 3, 7, 13, 199, 5, 101, 59, 13, 41, 3, 359, 7, 11, 2, 31, 197, 139, 3, 59, 2, 139, 83, 37, 23, 193, 587, 199, 67, 47, 401, 41, 571, 73, 1063, 229, 1163, 47, 53, 239, 347, 223, 577, 499, 271, 269, 11, 179
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 06 2013

Keywords

Comments

Conjecture: a(n) < 4n^2-1 for all n>0.

Examples

			a(5) = 3 since the polynomial sum_{k=0}^5 B_5*x^{5-k} = x^5+x^4+2*x^3+5*x^2+15*x+52 is irreducible modulo 3 but reducible modulo 2.
Note also that a(7) = 193 < 4*7^2-1 = 195.
		

Crossrefs

Programs

  • Mathematica
    A[n_,x_]:=A[n,x]=Sum[BellB[k]*x^(n-k),{k,0,n}]
    Do[Do[If[IrreduciblePolynomialQ[A[n,x],Modulus->Prime[k]]==True,Print[n," ",Prime[k]];Goto[aa]],{k,1,PrimePi[4n^2-2]}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,100}]

A305846 Inverse Weigh transform of the Bell numbers (A000110).

Original entry on oeis.org

1, 2, 3, 11, 34, 138, 610, 2976, 15612, 87905, 526274, 3334988, 22270254, 156173299, 1146640394, 8791427525, 70227355786, 583283756678, 5027823752930, 44903579714037, 414877600876638, 3959945233249877, 38996757506464858, 395749369601741015, 4134132167178705732
Offset: 1

Views

Author

Alois P. Heinz, Jun 11 2018

Keywords

Crossrefs

Programs

  • Maple
    g:= proc(n) option remember; `if`(n=0, 1,
          add(binomial(n-1, j-1)*g(n-j), j=1..n))
        end:
    b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<1, 0,
          add(binomial(a(i), j)*b(n-i*j, i-1), j=0..n/i)))
        end:
    a:= proc(n) option remember; g(n)-b(n, n-1) end:
    seq(a(n), n=1..30);
  • Mathematica
    g[n_] := g[n] = If[n == 0, 1,
         Sum[Binomial[n-1, j-1]*g[n-j], {j, 1, n}]];
    b[n_, i_] := b[n, i] = If[n == 0, 1, If[i < 1, 0,
         Sum[Binomial[a[i], j]*b[n - i*j, i - 1], {j, 0, n/i}]]];
    a[n_] := a[n] = g[n] - b[n, n - 1];
    Table[a[n], {n, 1, 30}] (* Jean-François Alcover, Mar 10 2022, after Alois P. Heinz *)

Formula

Product_{k>=1} (1+x^k)^a(k) = Sum_{n>=0} Bell(n) * x^n.

A066562 Smallest Bell number (A000110) divisible by n, if such a number exists, otherwise 0.

Original entry on oeis.org

1, 2, 15, 52, 5, 4140, 203, 0, 4140, 4140, 10293358946226376485095653, 4140, 52, 51724158235372, 15, 0, 4506715738447323, 4140, 21147, 4140, 21147, 1052928518014714166107781298021583534928402714242132, 4140, 0, 115975, 52, 82864869804, 51724158235372, 203, 4140
Offset: 1

Views

Author

Amarnath Murthy, Dec 17 2001

Keywords

Comments

No Bell number is divisible by 8. - John W. Layman, Jan 02 2002

Crossrefs

Programs

  • Mathematica
    b[ n_ ] := Nest[ Factor[ D[ #1, x ] ] &, Exp[ Exp[ x - 1 ] - 1 ], n ] /. (x -> 1); Do[ k = 1; While[ c = b[ k ]; !IntegerQ[ c/n ], k++ ]; Print[ c ], {n, 1, 7} ]

Extensions

More terms from John W. Layman, Jan 02 2002
More terms from David Wasserman, Mar 31 2008

A168407 E.g.f.: Sum_{n>=0} (exp(2^n*x) - 1)^n/n!, an analog of the Bell numbers (A000110).

Original entry on oeis.org

1, 2, 20, 712, 91920, 44874784, 85939843136, 660213878210688, 20540390859740217600, 2592165941692975372042752, 1324271564605167892188248409088, 2730585827960928853182474922961668096
Offset: 0

Views

Author

Paul D. Hanna, Nov 25 2009, Nov 25 2009, Feb 16 2010

Keywords

Examples

			E.g.f.: A(x) = 1 + 2*x + 20*x^2/2! + 712*x^3/3! + 91920*x^4/4! +...
A(x) = 1 + (exp(2*x) - 1) + (exp(4*x) - 1)^2/2! + (exp(8*x) - 1)^3/3! +...+ (exp(2^n*x) - 1)^n/n! +...
a(n) = coefficient of x^n/n! in Bell(x)^(2^n) where Bell(x) = exp(exp(x)-1):
Bell(x) = 1 + x + 2*x^2/2! + 5*x^3/3! + 15*x^4/4! + 52*x^5/5! + 203*x^6/6! +...+ A000110(n)*x^n/n! +...
		

Crossrefs

Programs

  • Mathematica
    Table[BellB[n, 2^n], {n, 0, 15}] (* Vaclav Kotesovec, Jul 02 2025 *)
  • PARI
    {a(n)=local(infnty=n^4+10);round(exp(-2^n)*sum(k=0,infnty,(2^k*k)^n/k!))}
    
  • PARI
    {a(n)=n!*polcoeff(sum(k=0,n,(exp(2^k*x +x*O(x^n))-1)^k/k!),n)}
    
  • PARI
    {a(n)=n!*polcoeff(exp(2^n*(exp(x +x*O(x^n))-1)),n)}
    
  • PARI
    {S2(n,k)=(1/k!)*sum(i=0,k,(-1)^(k-i)*binomial(k,i)*i^n)}
    {a(n)=sum(k=0,n,S2(n,k)*2^(n*k))}
    
  • PARI
    {a(n)=polcoeff(sum(k=0,n,(2^k*x)^k/prod(j=1,k,1-j*2^k*x+x*O(x^n))),n)}

Formula

a(n) = exp(-2^n) * Sum_{k>=0} (2^k*k)^n/k!.
a(n) = [x^n/n! ] B(x)^(2^n), where B(x) = exp(exp(x) - 1) is the e.g.f. of the Bell numbers.
a(n) = Sum_{k=0..n} S2(n,k) * 2^(n*k), where S2(n,k) = A008277(n,k) are the Stirling numbers of the second kind.
G.f.: A(x) = Sum_{n>=0} 2^(n^2) * x^n / [Product_{k=1..n} (1 - k*2^n*x)].
a(n) ~ 2^(n^2). - Vaclav Kotesovec, Jul 02 2025

A038559 a(n) = 2*A040027(n-1) + Bell(n), where Bell = A000110.

Original entry on oeis.org

1, 3, 4, 11, 33, 114, 445, 1923, 9078, 46369, 254297, 1487896, 9239135, 60615819, 418583924, 3032405831, 22979752405, 181697363626, 1495586215841, 12789423056183, 113415288869750, 1041244540823413, 9881851825756365, 96811870321650792, 977851660102425867
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Maple
    A038559 := proc(n)
        2*A040027(n-1)+combinat[bell](n) ;
    end proc: # R. J. Mathar, Dec 20 2013
    alias(PS = ListTools:-PartialSums):
    A038559List := proc(len) local a, k, P, T; a := 3; P := [1]; T := [1];
    for k from 1 to len-1 do
       T := [op(T), a]; P := PS([a, op(P)]); a := P[-1] od;
    T end: A038559List(25); # Peter Luschny, Mar 28 2022
  • Mathematica
    a[0] = 1; a[1] = 3; a[n_] := a[n] = Sum[Binomial[n - 1, k - 1]*a[n - k], {k, n}];
    Array[a, 30, 0] (* Paolo Xausa, Sep 17 2024 *)
    Module[{a = 3, p = {1}}, Join[{1, a}, Table[a = Last[p = Accumulate[Prepend[p, a]]], 28]]] (* Paolo Xausa, Sep 17 2024, after Peter Luschny *)

Formula

a(0) = 1, a(1) = 3; a(n) = Sum_{k=1..n} binomial(n-1,k-1) * a(n-k). - Ilya Gutkovskiy, Jul 10 2020

A064299 a(n) = B(n)*C(n), where B(n) are Bell numbers (A000110) and C(n) are Catalan numbers (A000108).

Original entry on oeis.org

1, 1, 4, 25, 210, 2184, 26796, 376233, 5920200, 102816714, 1947916100, 39890416020, 876478739164, 20537052247300, 510548782729680, 13407568735200525, 370553407586717490, 10742998644116921160, 325786278993936753300, 10307990595756667951830
Offset: 0

Views

Author

Karol A. Penson, Sep 05 2001

Keywords

Comments

From Joerg Arndt, Oct 22 2012: (Start)
Number of strings of length 2*n of up to n different types t(k) of balanced parentheses, where the first appearance of type t(k) must precede the appearance of t(k+1) for all k
For example, from the 5 parenthesis string of length 3
1: ()()(); 2: ()(()); 3: (())(); 4: (()()); 5: ((())).
we obtain the B(3) * C(3) = 5 * 5 = 25 strings
1: ()()(), ()()[], ()[](), ()[][], ()[]{};
2: ()(()), ()([]), ()[()], ()[[]], ()[{}];
3: (())(), (())[], ([])(), ([])[], ([]){};
4: (()()), (()[]), ([]()), ([][]), ([]{});
5: ((())), (([])), ([()]), ([[]]), ([{}]).
(End)

Crossrefs

Row sums of A253180.

Programs

  • Maple
    with(combinat):
    ctln:= proc(n) option remember; binomial(2*n, n)/(n+1) end:
    a:= n-> bell(n)*ctln(n):
    seq(a(n), n=0..25);  # Alois P. Heinz, Mar 23 2015
  • Mathematica
    a[n_] := BellB[n]*CatalanNumber[n]; Table[a[n], {n, 0, 25}] (* Jean-François Alcover, Feb 25 2017 *)
  • Python
    from itertools import count, accumulate, islice
    def A064299_gen(): # generator of terms
        yield from (1,1)
        blist, b, m = (1,2), 1, 1
        for n in count(1):
            blist = list(accumulate(blist, initial=(b:=blist[-1])))
            yield b*(m := m*(4*n+2)//(n+2))
    A064299_list = list(islice(A064299_gen(),20)) # Chai Wah Wu, Jun 22 2022
  • Sage
    [bell_number(i)*catalan_number(i) for i in range(17)] # Zerinvary Lajos, Mar 14 2009
    

Formula

Integral representation as n-th moment of a positive function on a positive half-axis, in Maple notation: a(n) = int(x^n*sum(sqrt((4*k-x)/x)*Heaviside(4*k-x)/(k*k!), k = 1..infinity)/(2*Pi*exp(1)), x = 0..infinity); this representation is unique.

A099977 Bisection of Bell numbers, A000110.

Original entry on oeis.org

1, 5, 52, 877, 21147, 678570, 27644437, 1382958545, 82864869804, 5832742205057, 474869816156751, 44152005855084346, 4638590332229999353, 545717047936059989389, 71339801938860275191172
Offset: 0

Author

N. J. A. Sloane, Nov 19 2004

Keywords

Crossrefs

Programs

  • Maple
    G:=series(exp(exp(x)-1),x=0,50): seq((2*n-1)!*coeff(G,x^(2*n-1)),n=1..18);
  • Python
    from itertools import accumulate, islice
    def A099977_gen(): # generator of terms
        yield 1
        blist, b = (1,2), 1
        while True:
            for _ in range(2):
                blist = list(accumulate(blist, initial=(b:=blist[-1])))
            yield b
    A099977_list = list(islice(A099977_gen(),30)) # Chai Wah Wu, Jun 22 2022

Formula

E.g.f.: exp(-1)*Sum_{n>=0} n*exp(n^2*x)/n!. - Vladeta Jovovic, Aug 24 2006
a(n) = exp(-1) * Sum_{k>=0} k^(2*n+1)/k!. - Ilya Gutkovskiy, Jun 13 2019

Extensions

More terms from Emeric Deutsch, Dec 07 2004

A135085 a(n) = A000110(2^n).

Original entry on oeis.org

1, 2, 15, 4140, 10480142147, 128064670049908713818925644, 172134143357358850934369963665272571125557575184049758045339873395
Offset: 0

Author

Thomas Wieder, Nov 18 2007, Nov 19 2007

Keywords

Comments

Number of set partitions of all subsets of a set, Bell(2^n).

Examples

			Let S={1,2,3,...,n} be a set of n elements and let SU be the set of all subsets of S including the empty set. The number of elements of SU is |SU| = 2^n. Now form all possible set partitions from SU including the empty set. This gives a set W and its number of elements is |W| = sum((stirling2(2^n,k)), k=0..2^n) = Bell(2^n).
For S={1,2} we have SU = { {}, {1}, {2}, {1,2} } and W =
{
{{{}}, {1}, {2}, {1, 2}},
{{2}, {1, 2}, {{}, {1}}},
{{1}, {1, 2}, {{}, {2}}},
{{1}, {2}, {{}, {1, 2}}},
{{{}}, {1, 2}, {{1}, {2}}},
{{{1}, {2}}, {{}, {1, 2}}},
{{1, 2}, {{}, {1}, {2}}},
{{{}}, {2}, {{1}, {1, 2}}},
{{{1}, {1, 2}}, {{}, {2}}},
{{2}, {{}, {1}, {1, 2}}},
{{{}}, {1}, {{2}, {1, 2}}},
{{{2}, {1, 2}}, {{}, {1}}},
{{1}, {{}, {2}, {1, 2}}},
{{{}}, {{1}, {2}, {1, 2}}},
{{{}, {1}, {2}, {1, 2}}}
}
and |W| = 15.
		

Crossrefs

Programs

  • Maple
    ZahlDerMengenAusMengeDerZerlegungenEinerMenge:=proc() local n,nend,arg,k,w; nend:=5; for n from 0 to nend do arg:=2^n; w[n]:=sum((stirling2(arg,k)), k=0..arg); od; print(w[0],w[1],w[2],w[3],w[4],w[5],w[6],w[7],w[8],w[9],w[10]); end proc;
  • Mathematica
    Table[BellB[2^n],{n,0,10}] (* Geoffrey Critzer, Jan 03 2014 *)
  • Python
    from sympy import bell
    def A135085(n): return bell(2**n) # Chai Wah Wu, Jun 22 2022

Formula

a(n) = |W| = Sum_{k=0..2^n} Stirling2(2^n,k) = Bell(2^n), where Stirling2(n) is the Stirling number of the second kind and Bell(n) is the Bell number.
a(n) = exp(-1) * Sum_{k>=0} k^(2^n)/k!. - Ilya Gutkovskiy, Jun 13 2019
Previous Showing 21-30 of 1370 results. Next