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

A038156 a(n) = n! * Sum_{k=1..n-1} 1/k!.

Original entry on oeis.org

0, 0, 2, 9, 40, 205, 1236, 8659, 69280, 623529, 6235300, 68588311, 823059744, 10699776685, 149796873604, 2246953104075, 35951249665216, 611171244308689, 11001082397556420, 209020565553571999, 4180411311071440000, 87788637532500240021, 1931350025715005280484
Offset: 0

Views

Author

Keywords

Comments

Related to number of operations of addition and multiplication to evaluate a determinant of order n by cofactor expansion - see A026243.
Also number of operations needed to create all permutations of n distinct elements using Algorithm L (lexicographic permutation generation) from Knuth's The Art of Computer Programming, Vol. 4, chapter 7.2.1.2. Sequence gives number of comparisons required to find j in step L2 (see answer to exercise 5). - Hugo Pfoertner, Jan 24 2003
For n>1, the number of possible ballots where there are n candidates and voters may identify their top m most preferred ones, where 0 < m < n. - Shaye Horwitz, Jun 28 2011
For n > 1, a(n) is the expected number of comparisons required to sort a random list of n distinct elements using the "bogosort" algorithm. - Andrew Slattery, Jun 02 2022
The number of permutations of all proper nonempty subsets of an n element set. - P. Christopher Staecker, May 09 2024

Examples

			a(2) = floor((2.718... - 1)*2) - 1 = 3 - 1 = 2,
a(3) = floor((2.718... - 1)*6) - 1 = 10 - 1 = 9.
		

References

  • D. E. Knuth: The Art of Computer Programming, Volume 4, Fascicle 2. Generating All Tuples and Permutations, Addison-Wesley, 2005.

Crossrefs

Programs

Formula

a(n) = floor((e-1)*n!) - 1.
a(0) = a(1) = 0, a(n) = n*(a(n-1) + 1) for n>1. - Philippe Deléham, Oct 16 2009
E.g.f.: (exp(x) - 1)*x/(1 - x). - Ilya Gutkovskiy, Jan 26 2017
a(n) = A002627(n)-1, n>=1. - R. J. Mathar, Jan 03 2018
a(n) = A000522(n)-n!-1, n>=1. - P. Christopher Staecker, May 09 2024

Extensions

a(28) ff. corrected by Georg Fischer, Apr 11 2020

A056542 a(n) = n*a(n-1) + 1, a(1) = 0.

Original entry on oeis.org

0, 1, 4, 17, 86, 517, 3620, 28961, 260650, 2606501, 28671512, 344058145, 4472755886, 62618582405, 939278736076, 15028459777217, 255483816212690, 4598708691828421, 87375465144740000, 1747509302894800001, 36697695360790800022, 807349297937397600485
Offset: 1

Views

Author

Henry Bottomley, Jun 20 2000

Keywords

Comments

For n >= 2 also operation count to create all permutations of n distinct elements using Algorithm L (lexicographic permutation generation) from Knuth's The Art of Computer Programming, Vol. 4, chapter 7.2.1.2. Sequence gives number of loop repetitions of the j search loop in step L2. - Hugo Pfoertner, Feb 06 2003
More directly: sum over all permutations of length n-1 of the product of the length of the first increasing run by the value of the first position. The recurrence follows from this definition. - Olivier Gérard, Jul 07 2011
This sequence shares divisibility properties with A000522; each of the primes in A072456 divide only a finite number of terms of this sequence. - T. D. Noe, Jul 07 2005
This sequence also represents the number of subdeterminant evaluations when calculation a determinant by Laplace recursive method. - Reinhard Muehlfeld, Sep 14 2010
Also, a(n) equals the number of non-isomorphic directed graphs of n+1 vertices with 1 component, where each vertex has exactly one outgoing edge, excluding loops and cycle graphs. - Stephen Dunn, Nov 30 2019

Examples

			a(4) = 4*a(3) + 1 = 4*4 + 1 = 17.
Permutations of order 3 .. Length of first run * First position
123..3*1
132..2*1
213..1*2
231..2*2
312..1*3
321..1*3
a(4) = 3+2+2+4+3+3 = 17. - _Olivier Gérard_, Jul 07 2011
		

References

  • D. E. Knuth: The Art of Computer Programming, Volume 4, Combinatorial Algorithms, Volume 4A, Enumeration and Backtracking. Pre-fascicle 2B, A draft of section 7.2.1.2: Generating all permutations. Available online; see link.

Crossrefs

Cf. A079751 (same recursion formula, but starting from a(3)=0), A038155, A038156, A080047, A080048, A080049.
Equals the row sums of A162995 triangle (n>=2). - Johannes W. Meijer, Jul 21 2009
Cf. A070213 (indices of primes).

Programs

  • Haskell
    a056542 n = a056542_list !! (n-1)
    a056542_list = 0 : map (+ 1) (zipWith (*) [2..] a056542_list)
    -- Reinhard Zumkeller, Mar 24 2013
    
  • Magma
    [n le 2 select n-1 else n*Self(n-1)+1: n in [1..20]]; // Bruno Berselli, Dec 13 2013
  • Mathematica
    tmp=0; Join[{tmp}, Table[tmp=n*tmp+1, {n, 2, 100}]] (* T. D. Noe, Jul 12 2005 *)
    FoldList[ #1*#2 + 1 &, 0, Range[2, 21]] (* Robert G. Wilson v, Oct 11 2005 *)

Formula

a(n) = floor((e-2)*n!).
a(n) = A002627(n) - n!.
a(n) = A000522(n) - 2*n!.
a(n) = n! - A056543(n).
a(n) = (n-1)*(a(n-1) + a(n-2)) + 2, n > 2. - Gary Detlefs, Jun 22 2010
1/(e - 2) = 2! - 2!/(1*4) - 3!/(4*17) - 4!/(17*86) - 5!/(86*517) - ... (see A002627 and A185108). - Peter Bala, Oct 09 2013
E.g.f.: (exp(x) - 1 - x) / (1 - x). - Ilya Gutkovskiy, Jun 26 2022

Extensions

More terms from James Sellers, Jul 04 2000

A073333 Decimal expansion of 1/(e - 1) = Sum_{k >= 1} exp(-k).

Original entry on oeis.org

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

Views

Author

Robert G. Wilson v, Aug 22 2002

Keywords

Comments

The value of the general continued fraction with the partial numerators (A000027) and the partial denominators (A000027). The value of the fractional limit of the numerators (A000166) and the denominators (A002467). Abs(A002467/(e-1)-A000166)->0. - Seiichi Kirikami, Oct 30 2011

Examples

			0.581976706869326424385002005109011558546869301075396136266787059648...
		

References

  • Calvin C. Clawson, Mathematical Mysteries: The Beauty and Magic of Numbers, Springer, 2013. See p. 225.
  • Wolfram Research, Mathematica, Version 4.1.0.0, Help Browser, under the function NSumExtraTerms

Crossrefs

Programs

  • Magma
    1/(Exp(1) - 1); // G. C. Greubel, Apr 09 2018
  • Maple
    h:=x->sum(1/exp(n),n=1..x); evalf[110](h(1500)); evalf[110](h(4000));
  • Mathematica
    RealDigits[N[Sum[Exp[-n], {n, 1, Infinity}], 120]][[1]]
    RealDigits[1/(E - 1), 10, 120][[1]] (* Eric W. Weisstein, May 08 2013 *)
  • PARI
    suminf(k=1,exp(-k)) \\ Charles R Greathouse IV, Oct 04 2011
    
  • PARI
    1/(exp(1)-1) \\ Charles R Greathouse IV, Oct 04 2011
    

Formula

Equals 1/(exp(1)-1). - Joseph Biberstine (jrbibers(AT)indiana.edu), Nov 03 2004
Also the unique real solution to log(1+x) - log(x) = 1. Equals 1-1/(1+1/(exp(1)-2)). Continued fraction is [0:1, 1, 2, 1, 1, 4, 1, 1, 6, 1, 1, 8, 1, 1, 10, ...]. - Gerald McGarvey, Aug 14 2004
Equals Sum_{n>=0} B_n/n!, where B_n is a Bernoulli number. - Fredrik Johansson, Oct 18 2006
1/(e-1) = 1/(1+2/(2+3/(3+4/(4+5/(5+...(continued fraction)))))). - Philippe Deléham, Mar 09 2013
Equals Integral_{x=0..oo} floor(x)*exp(-x). - Jean-François Alcover, Mar 20 2013
From Peter Bala, Oct 09 2013: (Start)
Equals (1/2)*Sum_{n >= 0} 1/sinh(2^n). (Gould, equation 22).
Define s(n) = Sum_{k = 1..n} 1/k! for n >= 1. Then 1/(e - 1) = 1 - Sum_{n >= 1} 1/( (n+1)!*s(n)*s(n+1) ) is a rapidly converging series of rationals (see A194807). Equivalently, 1/(e - 1) = 1 - 1!/(1*3) - 2!/(3*10) - 3!/(10*41) - ..., where [1, 3, 10, 41, ... ] is A002627.
We also have the alternating series 1/(e - 1) = 1!/(1*1) - 2!/(1*4) + 3!/(4*15) - 4!/(15*76) + ..., where [1, 1, 4, 15, 76, ...] is A002467. (End)
From Vaclav Kotesovec, Oct 13 2018: (Start)
Equals A185393 - 1.
Equals -LambertW(exp(1/(1 - exp(1))) / (1 - exp(1))).
Equals -1 - LambertW(-1, exp(1/(1 - exp(1))) / (1 - exp(1))). (End)
From Gleb Koloskov, Sep 03 2021: (Start)
Equals (coth(1/2)-1)/2 = (A307178-1)/2.
Equals 1/2 + 2*Integral_{x=0..oo} sin(x)/(exp(2*Pi*x)-1) dx.
Equals 1/2 + (1/Pi)*Integral_{x=0..1} sin(log(x)/(2*Pi))/(x-1) dx. (End)
Equals -lim_{n->oo} zeta(1-n, n)*n^(1 - n). - Vaclav Kotesovec and Peter Luschny, Nov 05 2021
Equals Integral_{x=0..1} floor(-log(x)) dx (see Redmond link). - Amiram Eldar, Oct 03 2023
Equals 1/2 + Sum_{k>=2} tanh(1/2^k)/2^k. - Antonio Graciá Llorente, Jan 21 2024

Extensions

Entry revised by N. J. A. Sloane, Apr 07 2006

A092582 Triangle read by rows: T(n,k) is the number of permutations p of [n] having length of first run equal to k.

Original entry on oeis.org

1, 1, 1, 3, 2, 1, 12, 8, 3, 1, 60, 40, 15, 4, 1, 360, 240, 90, 24, 5, 1, 2520, 1680, 630, 168, 35, 6, 1, 20160, 13440, 5040, 1344, 280, 48, 7, 1, 181440, 120960, 45360, 12096, 2520, 432, 63, 8, 1, 1814400, 1209600, 453600, 120960, 25200, 4320, 630, 80, 9, 1
Offset: 1

Views

Author

Emeric Deutsch and Warren P. Johnson (wjohnson(AT)bates.edu), Apr 10 2004

Keywords

Comments

Row sums are the factorial numbers (A000142). First column is A001710.
T(n,k) = number of permutations of [n] in which 1,2,...,k is a subsequence but 1,2,...,k,k+1 is not. Example: T(4,2)=8 because 1324, 1342, 1432, 4132, 3124, 3142, 3412 and 4312, are the only permutations of [4] in which 12 is a subsequence but 123 is not. - Emeric Deutsch, Nov 12 2004
T(n,k) is the number of deco polyominoes of height n with k cells in the last column. (A deco polyomino is a directed column-convex polyomino in which the height, measured along the diagonal, is attained only in the last column). - Emeric Deutsch, Jan 06 2005
T(n,k) is the number of permutations p of [n] for which the smallest i such that p(i)Emeric Deutsch, Feb 23 2008
Adding columns 2,4,6,... one obtains the derangement numbers 0,1,2,9,44,... (A000166). See the Bona reference (p. 118, Exercises 41,42). - Emeric Deutsch, Feb 23 2008
Matrix inverse of A128227*A154990. - Mats Granvik, Feb 08 2009
Differences in the columns of A173333 which counts the n-permutations with an initial ascending run of length at least k. - Geoffrey Critzer, Jun 18 2017
The triangle with each row reversed is A130477. - Michael Somos, Jun 25 2017

Examples

			T(4,3) = 3 because 1243, 1342 and 2341 are the only permutations of [4] having length of first run equal to 3.
     1;
     1,    1;
     3,    2,   1;
    12,    8,   3,   1;
    60,   40,  15,   4,  1;
   360,  240,  90,  24,  5,  1;
  2520, 1680, 630, 168, 35,  6,  1;
  ...
		

References

  • M. Bona, Combinatorics of Permutations, Chapman&Hall/CRC, Boca Raton, Florida, 2004.

Crossrefs

Programs

  • GAP
    Flat(List([1..11],n->Concatenation([1],List([1..n-1],k->Factorial(n)*k/Factorial(k+1))))); # Muniru A Asiru, Jun 10 2018
    
  • Magma
    A092582:= func< n,k | k eq n select 1 else k*Factorial(n)/Factorial(k+1) >;
    [A092582(n,k): k in [1..n], n in [1..12]]; // G. C. Greubel, Sep 06 2022
    
  • Mathematica
    Drop[Drop[Abs[Map[Select[#, # < 0 &] &, Map[Differences, nn = 10; Range[0, nn]! CoefficientList[Series[(Exp[y x] - 1)/(1 - x), {x, 0, nn}], {x, y}]]]], 1], -1] // Grid (* Geoffrey Critzer, Jun 18 2017 *)
  • PARI
    {T(n, k) = if( n<1 || k>n, 0, k==n, 1, n! * k /(k+1)!)}; /* Michael Somos, Jun 25 2017 */
    
  • SageMath
    def A092582(n,k): return 1 if (k==n) else k*factorial(n)/factorial(k+1)
    flatten([[A092582(n,k) for k in (1..n)] for n in (1..12)]) # G. C. Greubel, Sep 06 2022

Formula

T(n, k) = n!*k/(k+1)! for k
Inverse of:
1;
-1, 1;
-1, -2, 1;
-1, -2, -3, 1;
-1, -2, -3, -4, 1;
... where A002260 = (1; 1,2; 1,2,3; ...). - Gary W. Adamson, Feb 22 2012
T(2n,n) = A092956(n-1) for n>0. - Alois P. Heinz, Jun 19 2017
From Alois P. Heinz, Dec 17 2021: (Start)
Sum_{k=1..n} k * T(n,k) = A002627(n).
|Sum_{k=1..n} (-1)^k * T(n,k)| = A055596(n) for n>=1. (End)
From G. C. Greubel, Sep 06 2022: (Start)
T(n, 1) = A001710(n).
T(n, 2) = 2*A001715(n) + [n=2]/3, n >= 2.
T(n, 3) = 3*A001720(n) + [n=3]/4, n >= 3.
T(n, 4) = 4*A001725(n) + [n=4]/5, n >= 4.
T(n, n-1) = A000027(n-1).
T(n, n-2) = A005563(n-1), n >= 3. (End)
Sum_{k=0..n} (k+1) * T(n,k) = A000522(n). - Alois P. Heinz, Apr 28 2023

A194807 Decimal expansion of 1/(e-2).

Original entry on oeis.org

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

Author

Martin Janecke, May 06 2012

Keywords

Comments

The value of the continued fraction 1+1/(2+2/(3+3/(4+4/(5+5/(6+6/(...)))))).

Examples

			1.392211191177332814376552878479816528373978385315...
		

Crossrefs

Cf. A073333 (1/(e-1)), A002627, A185108.

Programs

  • Magma
    1/(Exp(1) - 2); // G. C. Greubel, Apr 09 2018
  • Mathematica
    RealDigits[1/(E - 2), 10, 105][[1]] (* T. D. Noe, May 07 2012 *)
    Fold[Function[#2 + #2/#1], 1, Reverse[Range[100]]] // N[#, 105]& // RealDigits // First (* Jean-François Alcover, Sep 19 2014 *)
  • PARI
    default(realprecision,110);
    1/(exp(1)-2)
    \\ Joerg Arndt, May 07 2012
    

Formula

Define s(n) = Sum_{k = 2..n} 1/k! for n >= 2. Then 1/(e - 2) = 2! - Sum_ {n >= 2} 1/( (n+1)!*s(n)*s(n+1) ) is a rapidly converging series of rationals. Cf. A073333. Equivalently, 1/(e - 2) = 2! - 2!/(1*4) - 3!/(4*17) - 4!/(17*86) - ..., where [1, 4, 17, 86, ... ] is A056542. Cf. A002627 and A185108. - Peter Bala, Oct 09 2013

A130147 a(0)=1. a(n+1) = a(floor(n/a(n))) + 1.

Original entry on oeis.org

1, 2, 2, 3, 3, 3, 3, 3, 3, 3, 4, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 4, 5, 4, 4, 4, 4, 4, 5, 4, 5, 5, 5, 5, 5, 4, 5, 4, 5, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5
Offset: 0

Author

Leroy Quet, Aug 02 2007

Keywords

Comments

Records occur at 0,1,3,10,41,206,1237,8660,69281,623530,6235301, which appears to be A002627. See A132424 for a related sequence. - John W. Layman, Aug 20 2007

Crossrefs

See A130193 for "ceiling" version.

Programs

  • Maple
    a[0]:=1: for n from 0 to 110 do a[n+1]:=1+a[floor(n/a[n])] end do: seq(a[n],n=0..110); # Emeric Deutsch, Aug 19 2007
  • Mathematica
    a[0] = 1; a[n_] := a[n] = 1 + a[Floor[(n - 1)/a[n - 1]]]; Array[a, 105, 0] (* Michael De Vlieger, Sep 03 2017 *)

Extensions

More terms from Emeric Deutsch and John W. Layman, Aug 19 2007

A185108 a(0)=0; for n>0, a(n) = (n+2)*a(n-1) + 1.

Original entry on oeis.org

0, 1, 5, 26, 157, 1100, 8801, 79210, 792101, 8713112, 104557345, 1359245486, 19029436805, 285441552076, 4567064833217, 77640102164690, 1397521838964421, 26552914940324000, 531058298806480001, 11152224274936080022
Offset: 0

Author

Olivier Gérard, Nov 02 2012

Keywords

Crossrefs

Programs

  • Magma
    [n le 1 select 0 else (n+1) * Self(n-1) + 1: n in [1..20]]; // Vincenzo Librandi, Dec 22 2012
  • Mathematica
    RecurrenceTable[{a[0]==0, a[n]==(n+2)*a[n-1] + 1}, a, {n, 20}] (* Vincenzo Librandi, Dec 23 2012 *)
    nxt[{n_,a_}]:={n+1,a(n+3)+1}; NestList[nxt,{0,0},20][[;;,2]] (* Harvey P. Dale, Aug 03 2023 *)

Formula

a(n) = e*Gamma(n+3,1)-(5/2)*(n+2)!, where Gamma(a,x) is the incomplete gamma function. [Bruno Berselli, Dec 24 2012]
Recurrence: a(n) = (n+3)*a(n-1) - (n+1)*a(n-2). - Vaclav Kotesovec, Aug 13 2013
a(n) ~ (exp(1)-5/2)*sqrt(2*Pi)*exp(-n)*n^(n+5/2). - Vaclav Kotesovec, Aug 13 2013
From Peter Bala, Oct 09 2013: (Start)
a(n) = A000522(n+2) - 5/2*(n + 2)! = (n + 2)!*( (sum {k = 0..n + 2} 1/k!) - 5/2 ).
a(n) = floor((n + 2)!*(e - 5/2)).
E.g.f.: ((x^2 - 4*x + 5)*exp(x) - 5)/(1 - x)^3 = x + 5*x^2/2! + 26*x^3/3! + ....
1/(e - 5/2) = 3! - 3!/(1*5) - 4!/(5*26) - 5!/(26*157) - 6!/(157*1100) - .... (see A002627, A056542). (End)

Extensions

Edited by Vincenzo Librandi and N. J. A. Sloane, Dec 24 2012

A186754 Triangle read by rows: T(n,k) is the number of permutations of {1,2,...,n} having k increasing cycles (0<=k<=n). A cycle (b(1), b(2), ...) is said to be increasing if, when written with its smallest element in the first position, it satisfies b(1) < b(2) < b(3) < ... .

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 1, 1, 3, 1, 5, 5, 7, 6, 1, 23, 36, 25, 25, 10, 1, 129, 234, 166, 110, 65, 15, 1, 894, 1597, 1316, 686, 385, 140, 21, 1, 7202, 12459, 10893, 5754, 2611, 1106, 266, 28, 1, 65085, 111451, 97287, 54559, 22428, 8841, 2730, 462, 36, 1, 651263, 1116277, 963121, 554670, 229405, 80871, 26397, 6000, 750, 45, 1
Offset: 0

Author

Emeric Deutsch, Feb 26 2011

Keywords

Examples

			T(3,0) = 1 because we have (132).
T(4,2) = 7 because we have (1)(234), (13)(24), (12)(34), (123)(4), (124)(3), (134)(2), and (14)(23).
Triangle starts:
   1;
   0,  1;
   0,  1,  1;
   1,  1,  3,  1;
   5,  5,  7,  6,  1;
  23, 36, 25, 25, 10, 1;
		

Crossrefs

Programs

  • Maple
    G := exp((t-1)*(exp(z)-1))/(1-z); Gser := simplify(series(G, z = 0, 16)): for n from 0 to 10 do P[n] := sort(expand(factorial(n)*coeff(Gser, z, n))) end do: for n from 0 to 10 do seq(coeff(P[n], t, j), j = 0 .. n) end do; # yields sequence in triangular form
    # second Maple program:
    b:= proc(n) option remember; expand(`if`(n=0, 1, add(
          b(n-i)*binomial(n-1, i-1)*(x+(i-1)!-1), i=1..n)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..degree(p)))(b(n)):
    seq(T(n), n=0..10);  # Alois P. Heinz, Sep 25 2016
  • Mathematica
    b[n_] := b[n] = Expand[If[n==0, 1, Sum[b[n-i]*Binomial[n-1, i-1]*(x + (i-1)! - 1), {i, 1, n}]]]; T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, Exponent[p, x]}]][b[n]]; Table[T[n], {n, 0, 10}] // Flatten (* Jean-François Alcover, Oct 04 2016, after Alois P. Heinz *)

Formula

E.g.f.: G(t,z) = exp((t-1)*(exp(z)-1))/(1-z).
The 4-variate e.g.f. H(u,v,w,z) of the permutations of {1,2,...,n} with respect to size (marked by z), number of fixed points (marked by u), number of increasing cycles of length >=2 (marked by v), and number of nonincreasing cycles (marked by w) is given by H(u,v,w,z) = exp(u*z+v*(exp(z)-1-z)+w*(1-exp(z)))/(1-z)^w. Remark: the nonincreasing cycles are necessarily of length >=3. We have: G(t,z) = H(t,t,1,z).
Sum_{k=0..n} T(n,k) = n!.
T(n,0) = A186755(n).
Sum_{k=0..n} k*T(n,k) = A002627(n).

A286286 a(0) = 0; thereafter, a(n) = (2*n-1)*a(n-1) + 1.

Original entry on oeis.org

0, 1, 4, 21, 148, 1333, 14664, 190633, 2859496, 48611433, 923617228, 19395961789, 446107121148, 11152678028701, 301122306774928, 8732546896472913, 270708953790660304, 8933395475091790033, 312668841628212651156, 11568747140243868092773
Offset: 0

Author

N. J. A. Sloane, May 15 2017

Keywords

Crossrefs

Conjectured to give indices of records in A132424.
Cf. A001147, A002627 (similar sequence), A000522, A060196.

Programs

  • Mathematica
    NestList[{(2 #2 - 1) #1 + 1, #2 + 1} & @@ # &, {0, 1}, 19][[All, 1]] (* Michael De Vlieger, Dec 10 2021 *)

Formula

a(n) = (2*n-1)!! * Sum_{k=1..n} 1/(2*k-1)!!. - Seiichi Manyama, Sep 02 2017
a(n) = floor((2*n-1)!!*A060196), for n > 0. - Peter McNair, Dec 10 2021
From Peter Bala, Feb 09 2024: (Start)
a(n) = 2*n*a(n-1) - (2*n - 3)*a(n-2) with a(0) = 0 and a(1) = 1.
The double factorial numbers (2*n-1)!! = A001147(n) satisfy the same recurrence, leading to the generalized continued fraction expansion Limit_{n -> oo} a(n)/(2*n-1)!! = Sum_{k >= 1} 1/(2*k-1)!! = A060196 = 1/(1 - 1/(4 - 3/(6 - 5/(8 - 7/(10 - 9/(12 - ... )))))). (End)

A076571 Binomial triangle based on factorials.

Original entry on oeis.org

1, 1, 2, 2, 3, 5, 6, 8, 11, 16, 24, 30, 38, 49, 65, 120, 144, 174, 212, 261, 326, 720, 840, 984, 1158, 1370, 1631, 1957, 5040, 5760, 6600, 7584, 8742, 10112, 11743, 13700, 40320, 45360, 51120, 57720, 65304, 74046, 84158, 95901, 109601
Offset: 0

Author

Henry Bottomley, Oct 19 2002

Keywords

Examples

			Rows start:
    1;
    1,   2;
    2,   3,   5;
    6,   8,  11,  16;
   24,  30,  38,  49,  65;
  120, 144, 174, 212, 261, 326;
		

Crossrefs

Right hand columns include A000522, A001339, A001340, A001341, A001342.
Cf. A002627 (row sums), A099022.

Programs

  • Magma
    A076571:= func< n,k| (&+[Binomial(k,j)*Factorial(n-j): j in [0..k]]) >;
    [A076571(n,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Oct 05 2023
    
  • Mathematica
    A076571[n_, k_]:= n!*Hypergeometric1F1[-k,-n,1];
    Table[A076571[n,k], {n,0,12}, {k,0,n}]//Flatten (* G. C. Greubel, Oct 05 2023 *)
  • SageMath
    def A076571(n,k): return sum(binomial(k,j)*factorial(n-j) for j in range(k+1))
    flatten([[A076571(n,k) for k in range(n+1)] for n in range(13)]) # G. C. Greubel, Oct 05 2023

Formula

T(n, k) = Sum_{j=0..k} binomial(k, j)*(n-j)!.
T(n, k) = T(n, k-1) + T(n-1, k-1) with T(n, 0) = n!.
T(n, n) = A000522(n).
Sum_{k=0..n} T(n, k) = A002627(n+1).
From G. C. Greubel, Oct 05 2023: (Start)
T(n, k) = n! * Hypergeometric1F1([-k], [-n], 1).
T(2*n, n) = A099022(n). (End)
Previous Showing 11-20 of 44 results. Next