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 11-20 of 47 results. Next

A061206 a(n) = total number of occurrences of the consecutive pattern 1324 in all permutations of [n+3].

Original entry on oeis.org

1, 10, 90, 840, 8400, 90720, 1058400, 13305600, 179625600, 2594592000, 39956716800, 653837184000, 11333177856000, 207484333056000, 4001483566080000, 81096733605888000, 1723305589125120000, 38318206628782080000, 889833909490606080000, 21543347282404147200000
Offset: 1

Views

Author

Melvin J. Knight (knightmj(AT)juno.com), May 30 2001

Keywords

Comments

a(n) is the number of sequences of n+3 balls colored with at most n colors such that exactly four balls are the same color as some other ball in the sequence. - Jeremy Dover, Sep 27 2017

Examples

			a(4)=840 because 4*(7!)/24 = 4*7*6*5 = 840.
		

Crossrefs

Programs

  • Magma
    [n*Factorial(n+3)/24: n in [1..20]]; // Vincenzo Librandi, Oct 11 2011
    
  • Maple
    a := n -> n!*binomial(-n,4): seq(a(n),n=1..20); # Peter Luschny, Apr 29 2016
  • Mathematica
    Array[# (# + 3)!/24 &, 20] (* or *) Array[#!*Binomial[-#, 4] &, 20] (* Michael De Vlieger, Sep 30 2017 *)
  • PARI
    a(n) = n*(n+3)!/24; \\ Altug Alkan, Oct 08 2017
  • Sage
    [binomial(n,4)*factorial (n-3) for n in range(4, 21)] # Zerinvary Lajos, Jul 07 2009
    

Formula

a(n) = n*(n+3)!/24.
If we define f(n,i,x) = Sum_{k=i..n} Sum_{j=i..k} binomial(k,j)*Stirling1(n,k)*Stirling2(j,i) * x^(k-j), then a(n-3) = (-1)^n*f(n,4,-2), (n >= 4). - Milan Janjic, Mar 01 2009
E.g.f.: x/(1-x)^5. (This was initiated by e-mail exchange with Gary Detlefs.) - Wolfdieter Lang, May 28 2010
a(n) = ((n+4)!/6) * Sum_{k=1..n} (k+2)!/(k+4)!. - Gary Detlefs, Aug 05 2010
a(n) = Sum_{k>0} k * A264173(n+3,k). - Alois P. Heinz, Nov 06 2015
a(n) = n!*binomial(-n,4). - Peter Luschny, Apr 29 2016
From Amiram Eldar, Sep 24 2022: (Start)
Sum_{n>=1} 1/a(n) = 118/3 - 16*e - 4*gamma + 4*Ei(1), where gamma is Euler's constant (A001620) and Ei(1) is the exponential integral at 1 (A091725).
Sum_{n>=1} (-1)^(n+1)/a(n) = 2/3 - 8/e + 4*gamma - 4*Ei(-1), where -Ei(-1) is the negated exponential integral at -1 (A099285). (End)

Extensions

More terms from Jason Earls, Jun 12 2001
Corrected by Zerinvary Lajos, Jul 07 2009
More precise definition from Alois P. Heinz, Nov 06 2015

A229837 Decimal expansion of Sum_{n>=1} 1/(n*n!).

Original entry on oeis.org

1, 3, 1, 7, 9, 0, 2, 1, 5, 1, 4, 5, 4, 4, 0, 3, 8, 9, 4, 8, 6, 0, 0, 0, 8, 8, 4, 4, 2, 4, 9, 2, 3, 1, 8, 3, 7, 9, 7, 4, 9, 0, 1, 2, 4, 5, 7, 9, 2, 7, 8, 3, 9, 9, 2, 8, 4, 0, 4, 6, 1, 1, 9, 6, 9, 9, 7, 6, 4, 6, 1, 0, 7, 7, 5, 6, 1, 3, 9, 4, 8, 2, 6, 1, 1, 9, 5, 3, 6, 4, 6, 8, 3, 4, 3, 9, 2, 2, 0, 7
Offset: 1

Views

Author

Jean-François Alcover, Oct 01 2013

Keywords

Examples

			1.3179021514544038948600088442492318379749012457927839928404611969976461...
		

Crossrefs

Programs

  • Maple
    evalf(Ei(1)-gamma,120); # Vaclav Kotesovec, May 10 2015
  • Mathematica
    RealDigits[ ExpIntegralEi[1] - EulerGamma, 10, 100] // First
  • PARI
    -Euler-real(eint1(-1)) \\ Charles R Greathouse IV, Oct 01 2013

Formula

Sum_{n >= 1} 1/(n*n!) = Ei(1)-gamma where Ei is the exponential integral and gamma is Euler's constant.
Also pFq(1,1; 2,2; 1) where pFq is the generalized hypergeometric function.
Also li(e)-gamma, e being the Euler constant (A001113) and li the logarithmic integral function. - Stanislav Sykora, May 09 2015
Continued fraction expansion: Ei(1) - gamma = 1/(1 - 1^3/(5 - 2^3/(11 -...-(n-1)^3/(n^2+n-1) -...))). See A061572. - Peter Bala, Feb 01 2017
From Amiram Eldar, Aug 01 2020: (Start)
Equals Sum_{k>=1} H(k)*k/(k+1)!, where H(k) = A001008(k)/A002805(k) is the k-th harmonic number.
Equals Integral_{x=0..1} (exp(x) - 1)/x dx.
Equals -Integral_{x=0..1} exp(x)*log(x) dx.
Equals -Integral_{x=1..e} log(log(x)) dx. (End)
Equals e * Sum_{k>=1} (-1)^(k+1)*H(k)/k!, where H(k) = A001008(k)/A002805(k) is the k-th harmonic number. - Amiram Eldar, Jun 25 2021

A062199 Second (unsigned) column sequence of triangle A062140 (generalized a=4 Laguerre).

Original entry on oeis.org

1, 12, 126, 1344, 15120, 181440, 2328480, 31933440, 467026560, 7264857600, 119870150400, 2092278988800, 38532804710400, 746943599001600, 15205637551104000, 324386934423552000, 7237883474325504000, 168600109166641152000, 4093235983656787968000
Offset: 0

Views

Author

Wolfdieter Lang, Jun 19 2001

Keywords

Comments

a(n) is the total number of ascending runs of length 5 over all permutations of {1,2,...,n+5}. a(1) = 12 because we have: [1,2,3,4,6,5], [1,2,3,5,6,4], [1,2,4,5,6,3], [1,3,4,5,6,2], [2,1,3,4,5,6], [2,3,4,5,6,1], [3,1,2,4,5,6], [4,1,2,3,5,6], [5,1,2,3,4,6], [6,1,2,3,4,5], and [1,2,3,4,5,6] which has two runs of length 5. - Geoffrey Critzer, Feb 21 2014

Crossrefs

Cf. A001720 (first column of A062140), A264781.

Programs

  • Magma
    [Binomial(n, 5)*Factorial(n-4): n in [5..25]]; // Vincenzo Librandi, Feb 23 2014
    
  • Mathematica
    Table[Sum[n!/5!, {i, 5, n}], {n, 5, 21}] (* Zerinvary Lajos, Jul 12 2009 *)
    With[{nn=20},CoefficientList[Series[(1+5x)/(1-x)^7,{x,0,nn}],x] Range[ 0,nn]!] (* Harvey P. Dale, Nov 10 2016 *)
  • PARI
    x='x+O('x^30); Vec(serlaplace((1+5*x)/(1-x)^7)) \\ G. C. Greubel, Feb 07 2018
  • Sage
    [binomial(n,5)*factorial (n-4) for n in range(5, 22)] # Zerinvary Lajos, Jul 07 2009
    

Formula

E.g.f.: (1+5*x)/(1-x)^7.
a(n) = A062140(n+1, 1) = (n+1)!*binomial(n+5, 5).
If we define f(n,i,x)= Sum(Sum(binomial(k,j)*Stirling1(n,k)*Stirling2(j,i)*x^(k-j),j=i..k),k=i..n) then a(n-1)=(-1)^(n-1)*f(n,1,-6), (n>=1). [Milan Janjic, Mar 01 2009]
a(n) = Sum_{k>0} k * A264781(n+5,k). - Alois P. Heinz, Nov 24 2015
Assuming offset 1: a(n) = -n!*binomial(-n,5). - Peter Luschny, Apr 29 2016
From Amiram Eldar, Sep 24 2022: (Start)
Sum_{n>=0} 1/a(n) = 1565/12 - 50*e - 5*gamma + 5*Ei(1), where gamma is Euler's constant (A001620) and Ei(1) is the exponential integral at 1 (A091725).
Sum_{n>=0} (-1)^n/a(n) = -125/12 + 20/e + 5*gamma - 5*Ei(-1), where -Ei(-1) is the negated exponential integral at -1 (A099285). (End)

Extensions

More terms from Vincenzo Librandi, Feb 23 2014

A052582 a(n) = 2*n*n!.

Original entry on oeis.org

0, 2, 8, 36, 192, 1200, 8640, 70560, 645120, 6531840, 72576000, 878169600, 11496038400, 161902540800, 2440992153600, 39230231040000, 669529276416000, 12093372555264000, 230485453406208000, 4622513815535616000, 97316080327065600000, 2145819571211796480000
Offset: 0

Views

Author

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

Keywords

Comments

Total number of pairs (a_i,a_(i+1)) in all permutations on [n] such that a_i,a_(i+1) are consecutive integers. - David Callan, Nov 04 2003
Number of permutations of {1,2,...,n+2} such that there is exactly one entry between the entries 1 and 2. Example: a(2)=8 because we have 1324, 1423, 2314, 2413, 3142, 4132, 3241 and 4231. - Emeric Deutsch, Apr 06 2008
Number of permutations of 0 to n distinct letters (ABC...) 1 times ("-" (0), A (1), AB (1-1), ABC (1-1-1), ABCD (1-1-1-1 )etc...) and one after the other to resemble motif:( "-",... BB (0-2), ABB (1-2-0), AABB (2-2-0-0), AAABB (3-2-0-0-0) AAAABB (4-2-0-0-0-0), AAAAABB (5-2-0-0-0-0-0), AAAAAABB (6-2-0-0-0-0-0-0), etc... 0 fixed point (or free fixed point). Example: if ABC (1-1-1) and motif ABB (1-2-0) then 2 * 0 (free) fixed point, if ABCD (1-1-1-1), and motif AABB (2-2-0-0) then 8 * 0 (free) fixed point, if ABCDE (1-1-1-1-1), and motif AAABB (3-2-0-0-0), then 36 * 0 (free) fixed point, if ABCDEF (1-1-1-1-1-1), and motif AAAABB (4-2-0-0-0-0), then 192 * 0 (free) fixed point, if ABCDEFG (1-1-1-1-1-1-1), and motif AAAAABB (5-2-0-0-0-0-0), then 1200 * 0 (free) fixed point, etc... - Zerinvary Lajos, Dec 07 2009

Crossrefs

Programs

  • Haskell
    a052582 n = a052582_list !! n
    a052582_list =  0 : 2 : zipWith
       div (zipWith (*) (tail a052582_list) (drop 2 a000290_list)) [1..]
    -- Reinhard Zumkeller, Nov 12 2011
  • Maple
    spec := [S,{S=Prod(Sequence(Z),Sequence(Z),Union(Z,Z))},labeled]: seq(combstruct[count](spec,size=n), n=0..20);
  • Mathematica
    a[ n_] := If[ n<0, 0, n! SeriesCoefficient[ 2 x / (1 - x)^2, {x, 0, n}]]; (* Michael Somos, Oct 20 2011 *)
    a[ n_] := If[ n<0, 0, 2 n n!]; (* Michael Somos, Oct 20 2011 *)
  • PARI
    {a(n) = if( n<0, 0, 2 * n * n!)}; /* Michael Somos, Oct 20 2011 */
    

Formula

E.g.f.: 2*x / (1 - x)^2.
Recurrence: {a(0)=0, a(1)=2, (-n^2-2*n-1)*a(n)+a(n+1)*n=0.}.
a(n) = A138770(n+2,1). - Emeric Deutsch, Apr 06 2008
a(n) = A001339(n) - A007808(n). - Michael Somos, Oct 20 2011
a(n) = (a(n-1)^2 - 2 * a(n-2)^2 + a(n-2) * a(n-3) - 4 * a(n-1) * a(n-3)) / (a(n-2) - a(n-3)) if n>2. - Michael Somos, Oct 20 2011
a(n) = 2*n*n!. - Gary Detlefs, Sep 16 2010
a(n+1) = a(n) * (n+1)^2 / n. - Reinhard Zumkeller, Nov 12 2011
0 = a(n)*(+a(n+1) -4*a(n+2) +a(n+3)) +a(n+1)*(+2*a(n+1) -a(n+3)) + a(n+2)*(+a(n+2)) if n>=0. - Michael Somos, Jun 26 2017
From Amiram Eldar, Feb 14 2021: (Start)
Sum_{n>=1} 1/a(n) = (Ei(1) - gamma)/2 = (A091725 - A001620)/2, where Ei(x) is the exponential integral.
Sum_{n>=1} (-1)^(n+1)/a(n) = (gamma - Ei(-1))/2 = (A001620 + A099285)/2. (End)
a(n) = 2 * A001563(n). - Alois P. Heinz, Sep 03 2024

A001755 Lah numbers: a(n) = n! * binomial(n-1, 3)/4!.

Original entry on oeis.org

1, 20, 300, 4200, 58800, 846720, 12700800, 199584000, 3293136000, 57081024000, 1038874636800, 19833061248000, 396661224960000, 8299373322240000, 181400588328960000, 4135933413900288000, 98228418580131840000, 2426819753156198400000, 62288373664342425600000
Offset: 4

Views

Author

Keywords

References

  • Louis Comtet, Advanced Combinatorics, Reidel, 1974, p. 156.
  • John Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 44.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Column 4 of A008297.
Column m=4 of unsigned triangle A111596.
Cf. A053495.

Programs

  • Magma
    [Factorial(n-1)*Binomial(n, 4)/6: n in [4..30]]; // G. C. Greubel, May 10 2021
  • Maple
    A001755 := n-> n!*binomial(n-1,3)/4!;
  • Mathematica
    Table[n!Binomial[n-1, 3]/4!, {n, 4, 25}] (* T. D. Noe, Aug 10 2012 *)
  • Sage
    [binomial(n,4)*factorial (n-1)/6 for n in range(4, 21)] # Zerinvary Lajos, Jul 07 2009
    

Formula

E.g.f.: ((x/(1-x))^4)/4!.
If we define f(n,i,x) = Sum_{k=i..n} (Sum_{j=i..k} (binomial(k,j) * Stirling1(n,k) * Stirling2(j,i) * x^(k-j) ) ) then a(n) = (-1)^n*f(n,4,-4), (n>=4). - Milan Janjic, Mar 01 2009
D-finite with recurrence (-n+4)*a(n) +n*(n-1)*a(n-1)=0. - R. J. Mathar, Jan 06 2021
From Amiram Eldar, May 02 2022: (Start)
Sum_{n>=4} 1/a(n) = 12*(Ei(1) - gamma + 2*e) - 80, where Ei(1) = A091725, gamma = A001620, and e = A001113.
Sum_{n>=4} (-1)^n/a(n) = 156*(gamma - Ei(-1)) - 96/e - 88, where Ei(-1) = -A099285. (End)

Extensions

More terms from Barbara Haas Margolius (margolius(AT)math.csuohio.edu), Feb 12 2001

A001777 Lah numbers: a(n) = n! * binomial(n-1, 4)/5!.

Original entry on oeis.org

1, 30, 630, 11760, 211680, 3810240, 69854400, 1317254400, 25686460800, 519437318400, 10908183686400, 237996734976000, 5394592659456000, 126980411830272000, 3101950060425216000, 78582734864105472000, 2062796790182768640000, 56059536297908183040000
Offset: 5

Views

Author

Keywords

References

  • Louis Comtet, Advanced Combinatorics, Reidel, 1974, p. 156.
  • John Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 44.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Column 5 of A008297. Cf. A053495.
Column m=5 of unsigned triangle A111596.

Programs

  • Maple
    A001777 := n-> n!*binomial(n-1,4)/5!;
  • Mathematica
    Table[n! Binomial[n - 1, 4]/5!, {n, 5, 20}] (* T. D. Noe, Aug 10 2012 *)
  • Sage
    [binomial(n,5)*factorial (n-1)/factorial (4) for n in range(5, 21)] # Zerinvary Lajos, Jul 07 2009

Formula

E.g.f.: ((x/(1-x))^5)/5!.
If we define f(n,i,x) = sum(sum(binomial(k,j)*Stirling1(n,k)*Stirling2(j,i)*x^(k-j),j=i..k),k=i..n) then a(n+1)=(-1)^n*f(n,4,-6), (n>=4). - Milan Janjic, Mar 01 2009
From Amiram Eldar, May 02 2022: (Start)
Sum_{n>=5} 1/a(n) = 20*(Ei(1) - gamma) - 200*e + 1555/3, where Ei(1) = A091725, gamma = A001620, and e = A001113.
Sum_{n>=5} (-1)^(n+1)/a(n) = 1460*(gamma - Ei(-1)) - 880/e - 2515/3, where Ei(-1) = -A099285. (End)

Extensions

More terms from Barbara Haas Margolius (margolius(AT)math.csuohio.edu)

A052571 E.g.f. x^3/(1-x)^2.

Original entry on oeis.org

0, 0, 0, 6, 48, 360, 2880, 25200, 241920, 2540160, 29030400, 359251200, 4790016000, 68497228800, 1046139494400, 16999766784000, 292919058432000, 5335311421440000, 102437979291648000, 2067966706950144000
Offset: 0

Views

Author

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

Keywords

Comments

For n >= 3, a(n) = number whose factorial base representation (A007623) begins with digit {n-2} followed by n-1 zeros. Viewed in that base, this sequence looks like this: 0, 0, 0, 100, 2000, 30000, 400000, 5000000, 60000000, 700000000, 8000000000, 90000000000, A00000000000, B000000000000, ... (where "digits" A and B stand for placeholder values 10 and 11 respectively). - Antti Karttunen, May 07 2015

Crossrefs

Column 5 of A257503 (apart from zero terms. Equally, row 5 of A257505).
Cf. sequences with formula (n + k)*n! listed in A282466.

Programs

  • Magma
    [0,0] cat [n*(n+1)*(n+2)*Factorial(n): n in [0..20]]; // Vincenzo Librandi, Oct 11 2011
    
  • Maple
    spec := [S,{S=Prod(Z,Z,Z,Sequence(Z),Sequence(Z))},labeled]: seq(combstruct[count](spec,size=n), n=0..20);
    [seq (n*(n+1)*(n+2)*n!,n=0..17)]; # Zerinvary Lajos, Nov 25 2006
    a:=n->add((n!),j=1..n-2):seq(a(n), n=0..21); # Zerinvary Lajos, Aug 27 2008
    G(x):=x^3/(1-x)^2: f[0]:=G(x): for n from 1 to 21 do f[n]:=diff(f[n-1],x) od: x:=0: seq(f[n],n=0..19); # Zerinvary Lajos, Apr 01 2009
  • Mathematica
    Table[Sum[n!, {i, 3, n}], {n, 0, 19}] (* Zerinvary Lajos, Jul 12 2009 *)
    With[{nn=20},CoefficientList[Series[x^3/(1-x)^2,{x,0,nn}],x] Range[0,nn]!] (* Harvey P. Dale, Feb 27 2025 *)
  • Scheme
    (define (A052571 n) (if (< n 2) 0 (* (- n 2) (A000142 n)))) ;; Antti Karttunen, May 07 2015

Formula

E.g.f.: x^3/(-1+x)^2.
Recurrence: {a(1)=0, a(0)=0, a(2)=0, a(3)=6, (1-n^2)*a(n)+(-2+n)*a(n+1)=0}.
For n >= 2, a(n) = (n-2)*n!.
a(n+2) = n*(n+1)*(n+2)*n!. - Zerinvary Lajos, Nov 25 2006
a(n) = 3*A090672(n-2) = 6*A005990(n-2). - Zerinvary Lajos, May 11 2007
From Amiram Eldar, Jan 14 2021: (Start)
Sum_{n>=3} 1/a(n) = 9/4 - e - gamma/2 + Ei(1)/2 = 9/4 - A001113 - (1/2)*A001620 + (1/2)*A091725.
Sum_{n>=3} (-1)^(n+1)/a(n) = -1/4 + gamma/2 - Ei(-1)/2 = -1/4 + (1/2)*A001620 + (1/2)*A099285. (End)

A062148 Second (unsigned) column sequence of triangle A062138 (generalized a=5 Laguerre).

Original entry on oeis.org

1, 14, 168, 2016, 25200, 332640, 4656960, 69189120, 1089728640, 18162144000, 319653734400, 5928123801600, 115598414131200, 2365321396838400, 50685458503680000, 1135354270482432000, 26538906072526848000, 646300418472124416000, 16372943934627151872000
Offset: 0

Views

Author

Wolfdieter Lang, Jun 19 2001

Keywords

Examples

			a(3) = (3+1)! * binomial(3+6,6) = 24 * 84 = 2016. - _Indranil Ghosh_, Feb 24 2017
		

Crossrefs

Cf. A001725 (first column of A062138).
Appears in the third left hand column of A167556 multiplied by 120. - Johannes W. Meijer, Nov 12 2009

Programs

  • Magma
    [Factorial(n+1)*Binomial(n+6,6): n in [0..30]]; // G. C. Greubel, Feb 06 2018
  • Mathematica
    Table[Sum[n!/6!, {i, 6, n}], {n, 6, 21}] (* Zerinvary Lajos, Jul 12 2009 *)
  • PARI
    a(n)=(n+1)!*binomial(n+6,6) \\ Indranil Ghosh, Feb 24 2017
    
  • Python
    import math
    f=math.factorial
    def C(n,r):return f(n)/f(r)/f(n-r)
    def A062148(n): return f(n+1)*C(n+6,6) # Indranil Ghosh, Feb 24 2017
    

Formula

E.g.f.: (1+6*x)/(1-x)^8.
a(n) = A062138(n+1, 1) = (n+1)!*binomial(n+6, 6).
If we define f(n,i,x)= Sum_{k=i..n}(Sum_{j=i..k}(binomial(k,j) *Stirling1(n,k)* Stirling2(j,i)*x^(k-j))) then a(n-1) = (-1)^(n-1) * f(n,1,-7), (n>=1). - Milan Janjic, Mar 01 2009
Assuming offset 1: a(n) = n!*binomial(-n,6). - Peter Luschny, Apr 29 2016
From Amiram Eldar, Sep 24 2022: (Start)
Sum_{n>=0} 1/a(n) = 5477/10 - 204*e - 6*gamma + 6*Ei(1), where gamma is Euler's constant (A001620) and Ei(1) is the exponential integral at 1 (A091725).
Sum_{n>=0} (-1)^n/a(n) = 403/10 - 120/e + 6*gamma - 6*Ei(-1), where -Ei(-1) is the negated exponential integral at -1 (A099285). (End)

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

Original entry on oeis.org

0, 2, 16, 120, 960, 8400, 80640, 846720, 9676800, 119750400, 1596672000, 22832409600, 348713164800, 5666588928000, 97639686144000, 1778437140480000, 34145993097216000, 689322235650048000, 14597412049059840000, 323575967087493120000, 7493338185184051200000
Offset: 1

Views

Author

N. J. A. Sloane, Dec 18 2003

Keywords

Comments

a(n) = Sum_{pi in Symm(n)} Sum_{i=1..n} |pi(i)-i|, i.e., the total displacement of all letters in all permutations on n letters.
a(n) = number of entries between the entries 1 and 2 in all permutations of {1,2,...,n+1}. Example: a(2)=2 because we have 123, 1(3)2, 213, 2(3)1, 312, 321; the entries between 1 and 2 are surrounded by parentheses. - Emeric Deutsch, Apr 06 2008
a(n) = Sum_{k=0..n-1} k*A138770(n+1,k). - Emeric Deutsch, Apr 06 2008
a(n) is also the number of peaks in all permutations of {1,2,...,n+1}. Example: a(3)=16 because the permutations 1234, 4123, 3124, 4312, 2134, 4213, 3214, and 4321 have no peaks and each of the remaining 16 permutations of {1,2,3,4} has exactly one peak. - Emeric Deutsch, Jul 26 2009
a(n), for n>=2, is the number of (n+2)-node tournaments that have exactly one triad. Proven by Kadane (1966), see link. - Ian R Harris, Sep 26 2022

References

  • D. Daly and P. Vojtechovsky, Displacement of permutations, preprint, 2003.

Crossrefs

Programs

  • Magma
    [(n^2-1)*Factorial(n)/3: n in [1..25]]; // Vincenzo Librandi, Oct 11 2011
  • Mathematica
    nn=20;Drop[Range[0,nn]!CoefficientList[Series[ x^3/3/(1-x)^2,{x,0,nn}],x],2]  (* Geoffrey Critzer, Mar 04 2013 *)

Formula

a(n) = A052571(n+2)/3 = 2*A005990(n). - Zerinvary Lajos, May 11 2007
a(n) = (n+3)! * Sum_{k=1..n} (k+1)!/(k+3)!, with offset 0. - Gary Detlefs, Aug 05 2010
E.g.f.: (x^3 - 3*x^2)/(3*(x-1)^3). - Geoffrey Critzer, Mar 04 2013
From Amiram Eldar, May 14 2022: (Start)
Sum_{n>=2} 1/a(n) = (3/2)*(Ei(1) - gamma) - 3*e + 27/4, where Ei(1) = A091725, gamma = A001620, and e = A001113.
Sum_{n>=2} (-1)^n/a(n) = (3/2)*(gamma - Ei(-1)) - 3/4, where Ei(-1) = -A099285. (End)

A001810 a(n) = n!*n*(n-1)*(n-2)/36.

Original entry on oeis.org

0, 0, 0, 1, 16, 200, 2400, 29400, 376320, 5080320, 72576000, 1097712000, 17563392000, 296821324800, 5288816332800, 99165306240000, 1952793722880000, 40311241850880000, 870722823979008000, 19645683716026368000, 462251381553561600000, 11325158848062259200000
Offset: 0

Views

Author

Keywords

Comments

a(n) is the total number of 3-2-1 patterns in all permutations on [n]. This is because there are n! permutations, binomial(n,3) triples in each one and the probability that a given triple of entries in a random permutation form a 3-2-1 pattern (or any other specified pattern of length 3) is 1/6. - David Callan, Oct 26 2006
Old name was "Coefficients of Laguerre polynomials".

Examples

			G.f. = x^3 + 16*x^4 + 200*x^5 + 2400*x^6 + 29400*x^7 + 376320*x^8 + ...
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 799.
  • Cornelius Lanczos, Applied Analysis. Prentice-Hall, Englewood Cliffs, NJ, 1956, p. 519.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Magma
    [Factorial(n)*n*(n-1)*(n-2)/36: n in [0..20]]; // G. C. Greubel, May 16 2018
  • Maple
    [seq(n!*n*(n-1)*(n-2)/36,n=0..30)];
    with(combstruct):ZL:=[st, {st=Prod(left, right), left=Set(U, card=r+1), right=Set(U, card=1)}, labeled]: subs(r=2, stack): seq(count(subs(r=2, ZL), size=m), m=0..20) ; # Zerinvary Lajos, Feb 07 2008
  • Mathematica
    Table[n! n*(n-1)*(n-2)/36, {n, 0, 20}] (* T. D. Noe, Aug 10 2012 *)
  • PARI
    for(n=0,20, print1(n!*n*(n-1)*(n-2)/36, ", ")) \\ G. C. Greubel, May 16 2018
    
  • Sage
    [factorial(m) * binomial(m, 3) / 6 for m in range(22)]  # Zerinvary Lajos, Jul 05 2008
    

Formula

a(n) = -A021009(n, 3), n >= 0. a(n) = ((n!/3!)^2)/(n-3)!, n >= 3.
E.g.f.: x^3/(3!*(1-x)^4).
If we define f(n,i,x) = Sum_{k=i..n} Sum_{j=i..k} binomial(k,j) * Stirling1(n,k) * Stirling2(j,i) * x^(k-j) then a(n) = (-1)^(n-1) * f(n,3,-4), (n >= 3). - Milan Janjic, Mar 01 2009
a(n) = Sum_{k>0} k * A263771(n,k). - Alois P. Heinz, Oct 27 2015
From Amiram Eldar, May 02 2022: (Start)
Sum_{n>=3} 1/a(n) = 9*(2*e + gamma - Ei(1) - 4), where e = A001113, gamma = A001620, and Ei(1) = A091725.
Sum_{n>=3} (-1)^(n+1)/a(n) = 63*(gamma - Ei(-1)) - 36*(1/e + 1), where Ei(-1) = -A099285. (End)

Extensions

Edited by N. J. A. Sloane, Apr 12 2014
Previous Showing 11-20 of 47 results. Next