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

A000142 Factorial numbers: n! = 1*2*3*4*...*n (order of symmetric group S_n, number of permutations of n letters).

Original entry on oeis.org

1, 1, 2, 6, 24, 120, 720, 5040, 40320, 362880, 3628800, 39916800, 479001600, 6227020800, 87178291200, 1307674368000, 20922789888000, 355687428096000, 6402373705728000, 121645100408832000, 2432902008176640000, 51090942171709440000, 1124000727777607680000
Offset: 0

Views

Author

Keywords

Comments

The earliest publication that discusses this sequence appears to be the Sepher Yezirah [Book of Creation], circa AD 300. (See Knuth, also the Zeilberger link.) - N. J. A. Sloane, Apr 07 2014
For n >= 1, a(n) is the number of n X n (0,1) matrices with each row and column containing exactly one entry equal to 1.
This sequence is the BinomialMean transform of A000354. (See A075271 for definition.) - John W. Layman, Sep 12 2002 [This is easily verified from the Paul Barry formula for A000354, by interchanging summations and using the formula: Sum_k (-1)^k C(n-i, k) = KroneckerDelta(i,n). - David Callan, Aug 31 2003]
Number of distinct subsets of T(n-1) elements with 1 element A, 2 elements B, ..., n - 1 elements X (e.g., at n = 5, we consider the distinct subsets of ABBCCCDDDD and there are 5! = 120). - Jon Perry, Jun 12 2003
n! is the smallest number with that prime signature. E.g., 720 = 2^4 * 3^2 * 5. - Amarnath Murthy, Jul 01 2003
a(n) is the permanent of the n X n matrix M with M(i, j) = 1. - Philippe Deléham, Dec 15 2003
Given n objects of distinct sizes (e.g., areas, volumes) such that each object is sufficiently large to simultaneously contain all previous objects, then n! is the total number of essentially different arrangements using all n objects. Arbitrary levels of nesting of objects are permitted within arrangements. (This application of the sequence was inspired by considering leftover moving boxes.) If the restriction exists that each object is able or permitted to contain at most one smaller (but possibly nested) object at a time, the resulting sequence begins 1,2,5,15,52 (Bell Numbers?). Sets of nested wooden boxes or traditional nested Russian dolls come to mind here. - Rick L. Shepherd, Jan 14 2004
From Michael Somos, Mar 04 2004; edited by M. F. Hasler, Jan 02 2015: (Start)
Stirling transform of [2, 2, 6, 24, 120, ...] is A052856 = [2, 2, 4, 14, 76, ...].
Stirling transform of [1, 2, 6, 24, 120, ...] is A000670 = [1, 3, 13, 75, ...].
Stirling transform of [0, 2, 6, 24, 120, ...] is A052875 = [0, 2, 12, 74, ...].
Stirling transform of [1, 1, 2, 6, 24, 120, ...] is A000629 = [1, 2, 6, 26, ...].
Stirling transform of [0, 1, 2, 6, 24, 120, ...] is A002050 = [0, 1, 5, 25, 140, ...].
Stirling transform of (A165326*A089064)(1...) = [1, 0, 1, -1, 8, -26, 194, ...] is [1, 1, 2, 6, 24, 120, ...] (this sequence). (End)
First Eulerian transform of 1, 1, 1, 1, 1, 1... The first Eulerian transform transforms a sequence s to a sequence t by the formula t(n) = Sum_{k=0..n} e(n, k)s(k), where e(n, k) is a first-order Eulerian number [A008292]. - Ross La Haye, Feb 13 2005
Conjecturally, 1, 6, and 120 are the only numbers which are both triangular and factorial. - Christopher M. Tomaszewski (cmt1288(AT)comcast.net), Mar 30 2005
n! is the n-th finite difference of consecutive n-th powers. E.g., for n = 3, [0, 1, 8, 27, 64, ...] -> [1, 7, 19, 37, ...] -> [6, 12, 18, ...] -> [6, 6, ...]. - Bryan Jacobs (bryanjj(AT)gmail.com), Mar 31 2005
a(n+1) = (n+1)! = 1, 2, 6, ... has e.g.f. 1/(1-x)^2. - Paul Barry, Apr 22 2005
Write numbers 1 to n on a circle. Then a(n) = sum of the products of all n - 2 adjacent numbers. E.g., a(5) = 1*2*3 + 2*3*4 + 3*4*5 + 4*5*1 +5*1*2 = 120. - Amarnath Murthy, Jul 10 2005
The number of chains of maximal length in the power set of {1, 2, ..., n} ordered by the subset relation. - Rick L. Shepherd, Feb 05 2006
The number of circular permutations of n letters for n >= 0 is 1, 1, 1, 2, 6, 24, 120, 720, 5040, 40320, ... - Xavier Noria (fxn(AT)hashref.com), Jun 04 2006
a(n) is the number of deco polyominoes of height n (n >= 1; see definitions in the Barcucci et al. references). - Emeric Deutsch, Aug 07 2006
a(n) is the number of partition tableaux of size n. See Steingrimsson/Williams link for the definition. - David Callan, Oct 06 2006
Consider the n! permutations of the integer sequence [n] = 1, 2, ..., n. The i-th permutation consists of ncycle(i) permutation cycles. Then, if the Sum_{i=1..n!} 2^ncycle(i) runs from 1 to n!, we have Sum_{i=1..n!} 2^ncycle(i) = (n+1)!. E.g., for n = 3 we have ncycle(1) = 3, ncycle(2) = 2, ncycle(3) = 1, ncycle(4) = 2, ncycle(5) = 1, ncycle(6) = 2 and 2^3 + 2^2 + 2^1 + 2^2 + 2^1 + 2^2 = 8 + 4 + 2 + 4 + 2 + 4 = 24 = (n+1)!. - Thomas Wieder, Oct 11 2006
a(n) is the number of set partitions of {1, 2, ..., 2n - 1, 2n} into blocks of size 2 (perfect matchings) in which each block consists of one even and one odd integer. For example, a(3) = 6 counts 12-34-56, 12-36-45, 14-23-56, 14-25-36, 16-23-45, 16-25-34. - David Callan, Mar 30 2007
Consider the multiset M = [1, 2, 2, 3, 3, 3, 4, 4, 4, 4, ...] = [1, 2, 2, ..., n x 'n'] and form the set U (where U is a set in the strict sense) of all subsets N (where N may be a multiset again) of M. Then the number of elements |U| of U is equal to (n+1)!. E.g. for M = [1, 2, 2] we get U = [[], [2], [2, 2], [1], [1, 2], [1, 2, 2]] and |U| = 3! = 6. This observation is a more formal version of the comment given already by Rick L. Shepherd, Jan 14 2004. - Thomas Wieder, Nov 27 2007
For n >= 1, a(n) = 1, 2, 6, 24, ... are the positions corresponding to the 1's in decimal expansion of Liouville's constant (A012245). - Paul Muljadi, Apr 15 2008
Triangle A144107 has n! for row sums (given n > 0) with right border n! and left border A003319, the INVERTi transform of (1, 2, 6, 24, ...). - Gary W. Adamson, Sep 11 2008
Equals INVERT transform of A052186 and row sums of triangle A144108. - Gary W. Adamson, Sep 11 2008
From Abdullahi Umar, Oct 12 2008: (Start)
a(n) is also the number of order-decreasing full transformations (of an n-chain).
a(n-1) is also the number of nilpotent order-decreasing full transformations (of an n-chain). (End)
n! is also the number of optimal broadcast schemes in the complete graph K_{n}, equivalent to the number of binomial trees embedded in K_{n} (see Calin D. Morosan, Information Processing Letters, 100 (2006), 188-193). - Calin D. Morosan (cd_moros(AT)alumni.concordia.ca), Nov 28 2008
Let S_{n} denote the n-star graph. The S_{n} structure consists of n S_{n-1} structures. This sequence gives the number of edges between the vertices of any two specified S_{n+1} structures in S_{n+2} (n >= 1). - K.V.Iyer, Mar 18 2009
Chromatic invariant of the sun graph S_{n-2}.
It appears that a(n+1) is the inverse binomial transform of A000255. - Timothy Hopper, Aug 20 2009
a(n) is also the determinant of a square matrix, An, whose coefficients are the reciprocals of beta function: a{i, j} = 1/beta(i, j), det(An) = n!. - Enrique Pérez Herrero, Sep 21 2009
The asymptotic expansions of the exponential integrals E(x, m = 1, n = 1) ~ exp(-x)/x*(1 - 1/x + 2/x^2 - 6/x^3 + 24/x^4 + ...) and E(x, m = 1, n = 2) ~ exp(-x)/x*(1 - 2/x + 6/x^2 - 24/x^3 + ...) lead to the factorial numbers. See A163931 and A130534 for more information. - Johannes W. Meijer, Oct 20 2009
Satisfies A(x)/A(x^2), A(x) = A173280. - Gary W. Adamson, Feb 14 2010
a(n) = G^n where G is the geometric mean of the first n positive integers. - Jaroslav Krizek, May 28 2010
Increasing colored 1-2 trees with choice of two colors for the rightmost branch of nonleaves. - Wenjin Woan, May 23 2011
Number of necklaces with n labeled beads of 1 color. - Robert G. Wilson v, Sep 22 2011
The sequence 1!, (2!)!, ((3!)!)!, (((4!)!)!)!, ..., ((...(n!)!)...)! (n times) grows too rapidly to have its own entry. See Hofstadter.
The e.g.f. of 1/a(n) = 1/n! is BesselI(0, 2*sqrt(x)). See Abramowitz-Stegun, p. 375, 9.3.10. - Wolfdieter Lang, Jan 09 2012
a(n) is the length of the n-th row which is the sum of n-th row in triangle A170942. - Reinhard Zumkeller, Mar 29 2012
Number of permutations of elements 1, 2, ..., n + 1 with a fixed element belonging to a cycle of length r does not depend on r and equals a(n). - Vladimir Shevelev, May 12 2012
a(n) is the number of fixed points in all permutations of 1, ..., n: in all n! permutations, 1 is first exactly (n-1)! times, 2 is second exactly (n-1)! times, etc., giving (n-1)!*n = n!. - Jon Perry, Dec 20 2012
For n >= 1, a(n-1) is the binomial transform of A000757. See Moreno-Rivera. - Luis Manuel Rivera Martínez, Dec 09 2013
Each term is divisible by its digital root (A010888). - Ivan N. Ianakiev, Apr 14 2014
For m >= 3, a(m-2) is the number hp(m) of acyclic Hamiltonian paths in a simple graph with m vertices, which is complete except for one missing edge. For m < 3, hp(m)=0. - Stanislav Sykora, Jun 17 2014
a(n) is the number of increasing forests with n nodes. - Brad R. Jones, Dec 01 2014
The factorial numbers can be calculated by means of the recurrence n! = (floor(n/2)!)^2 * sf(n) where sf(n) are the swinging factorials A056040. This leads to an efficient algorithm if sf(n) is computed via prime factorization. For an exposition of this algorithm see the link below. - Peter Luschny, Nov 05 2016
Treeshelves are ordered (plane) binary (0-1-2) increasing trees where the nodes of outdegree 1 come in 2 colors. There are n! treeshelves of size n, and classical Françon's bijection maps bijectively treeshelves into permutations. - Sergey Kirgizov, Dec 26 2016
Satisfies Benford's law [Diaconis, 1977; Berger-Hill, 2017] - N. J. A. Sloane, Feb 07 2017
a(n) = Sum((d_p)^2), where d_p is the number of standard tableaux in the Ferrers board of the integer partition p and summation is over all integer partitions p of n. Example: a(3) = 6. Indeed, the partitions of 3 are [3], [2,1], and [1,1,1], having 1, 2, and 1 standard tableaux, respectively; we have 1^2 + 2^2 + 1^2 = 6. - Emeric Deutsch, Aug 07 2017
a(n) is the n-th derivative of x^n. - Iain Fox, Nov 19 2017
a(n) is the number of maximum chains in the n-dimensional Boolean cube {0,1}^n in respect to the relation "precedes". It is defined as follows: for arbitrary vectors u, v of {0,1}^n, such that u = (u_1, u_2, ..., u_n) and v = (v_1, v_2, ..., v_n), "u precedes v" if u_i <= v_i, for i=1, 2, ..., n. - Valentin Bakoev, Nov 20 2017
a(n) is the number of shortest paths (for example, obtained by Breadth First Search) between the nodes (0,0,...,0) (i.e., the all-zeros vector) and (1,1,...,1) (i.e., the all-ones vector) in the graph H_n, corresponding to the n-dimensional Boolean cube {0,1}^n. The graph is defined as H_n = (V_n, E_n), where V_n is the set of all vectors of {0,1}^n, and E_n contains edges formed by each pair adjacent vectors. - Valentin Bakoev, Nov 20 2017
a(n) is also the determinant of the symmetric n X n matrix M defined by M(i,j) = sigma(gcd(i,j)) for 1 <= i,j <= n. - Bernard Schott, Dec 05 2018
a(n) is also the number of inversion sequences of length n. A length n inversion sequence e_1, e_2, ..., e_n is a sequence of n integers such that 0 <= e_i < i. - Juan S. Auli, Oct 14 2019
The term "factorial" ("factorielle" in French) was coined by the French mathematician Louis François Antoine Arbogast (1759-1803) in 1800. The notation "!" was first used by the French mathematician Christian Kramp (1760-1826) in 1808. - Amiram Eldar, Apr 16 2021
Also the number of signotopes of rank 2, i.e., mappings X:{{1..n} choose 2}->{+,-} such that for any three indices a < b < c, the sequence X(a,b), X(a,c), X(b,c) changes its sign at most once (see Felsner-Weil reference). - Manfred Scheucher, Feb 09 2022
a(n) is also the number of labeled commutative semisimple rings with n elements. As an example the only commutative semisimple rings with 4 elements are F_4 and F_2 X F_2. They both have exactly 2 automorphisms, hence a(4)=24/2+24/2=24. - Paul Laubie, Mar 05 2024
a(n) is the number of extremely unlucky Stirling permutations of order n+1; i.e., the number of Stirling permutations of order n+1 that have exactly one lucky car. - Bridget Tenner, Apr 09 2024

Examples

			There are 3! = 1*2*3 = 6 ways to arrange 3 letters {a, b, c}, namely abc, acb, bac, bca, cab, cba.
Let n = 2. Consider permutations of {1, 2, 3}. Fix element 3. There are a(2) = 2 permutations in each of the following cases: (a) 3 belongs to a cycle of length 1 (permutations (1, 2, 3) and (2, 1, 3)); (b) 3 belongs to a cycle of length 2 (permutations (3, 2, 1) and (1, 3, 2)); (c) 3 belongs to a cycle of length 3 (permutations (2, 3, 1) and (3, 1, 2)). - _Vladimir Shevelev_, May 13 2012
G.f. = 1 + x + 2*x^2 + 6*x^3 + 24*x^4 + 120*x^5 + 720*x^6 + 5040*x^7 + ...
		

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. 833.
  • A. T. Benjamin and J. J. Quinn, Proofs that really count: the art of combinatorial proof, M.A.A. 2003, id. 125; also p. 90, ex. 3.
  • Florian Cajori, A History of Mathematical Notations, Dover edition (2012), pars. 448-449.
  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See pp. 64-66.
  • Jan Gullberg, Mathematics from the Birth of Numbers, W. W. Norton & Co., NY & London, 1997, §4.1 Symbols Galore, p. 106.
  • Douglas R. Hofstadter, Fluid concepts & creative analogies: computer models of the fundamental mechanisms of thought, Basic Books, 1995, pages 44-46.
  • A. N. Khovanskii. The Application of Continued Fractions and Their Generalizations to Problem in Approximation Theory. Groningen: Noordhoff, Netherlands, 1963. See p. 141 (10.19).
  • D. E. Knuth, The Art of Computer Programming, Vol. 3, Section 5.1.2, p. 23. [From N. J. A. Sloane, Apr 07 2014]
  • J.-M. De Koninck and A. Mercier, 1001 Problèmes en Théorie Classique des Nombres, Problème 693 pp. 90, 297, Ellipses Paris 2004.
  • A. P. Prudnikov, Yu. A. Brychkov, and O. I. Marichev, "Integrals and Series", Volume 1: "Elementary Functions", Chapter 4: "Finite Sums", New York, Gordon and Breach Science Publishers, 1986-1992.
  • R. W. Robinson, Counting arrangements of bishops, pp. 198-214 of Combinatorial Mathematics IV (Adelaide 1975), Lect. Notes Math., 560 (1976).
  • Sepher Yezirah [Book of Creation], circa AD 300. See verse 52.
  • 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).
  • Jerome Spanier and Keith B. Oldham, "Atlas of Functions", Hemisphere Publishing Corp., 1987, chapter 2, pages 19-24.
  • D. Stanton and D. White, Constructive Combinatorics, Springer, 1986; see p. 91.
  • Carlo Suares, Sepher Yetsira, Shambhala Publications, 1976. See verse 52.
  • David Wells, The Penguin Dictionary of Curious and Interesting Numbers, Penguin Books, 1987, pp. 102.

Crossrefs

Factorial base representation: A007623.
Complement of A063992. - Reinhard Zumkeller, Oct 11 2008
Cf. A053657, A163176. - Jonathan Sondow, Jul 26 2009
Cf. A173280. - Gary W. Adamson, Feb 14 2010
Boustrophedon transforms: A230960, A230961.
Cf. A233589.
Cf. A245334.
A row of the array in A249026.
Cf. A001013 (multiplicative closure).
For factorials with initial digit d (1 <= d <= 9) see A045509, A045510, A045511, A045516, A045517, A045518, A282021, A045519; A045520, A045521, A045522, A045523, A045524, A045525, A045526, A045527, A045528, A045529.

Programs

  • Axiom
    [factorial(n) for n in 0..10]
    
  • GAP
    List([0..22],Factorial); # Muniru A Asiru, Dec 05 2018
    
  • Haskell
    a000142 :: (Enum a, Num a, Integral t) => t -> a
    a000142 n = product [1 .. fromIntegral n]
    a000142_list = 1 : zipWith (*) [1..] a000142_list
    -- Reinhard Zumkeller, Mar 02 2014, Nov 02 2011, Apr 21 2011
    
  • Julia
    print([factorial(big(n)) for n in 0:28]) # Paul Muljadi, May 01 2024
  • Magma
    a:= func< n | Factorial(n) >; [ a(n) : n in [0..10]];
    
  • Maple
    A000142 := n -> n!; seq(n!,n=0..20);
    spec := [ S, {S=Sequence(Z) }, labeled ]; seq(combstruct[count](spec,size=n), n=0..20);
    # Maple program for computing cycle indices of symmetric groups
    M:=6: f:=array(0..M): f[0]:=1: print(`n= `,0); print(f[0]); f[1]:=x[1]: print(`n= `, 1); print(f[1]); for n from 2 to M do f[n]:=expand((1/n)*add( x[l]*f[n-l],l=1..n)); print(`n= `, n); print(f[n]); od:
    with(combstruct):ZL0:=[S,{S=Set(Cycle(Z,card>0))},labeled]: seq(count(ZL0,size=n),n=0..20); # Zerinvary Lajos, Sep 26 2007
  • Mathematica
    Table[Factorial[n], {n, 0, 20}] (* Stefan Steinerberger, Mar 30 2006 *)
    FoldList[#1 #2 &, 1, Range@ 20] (* Robert G. Wilson v, May 07 2011 *)
    Range[20]! (* Harvey P. Dale, Nov 19 2011 *)
    RecurrenceTable[{a[n] == n*a[n - 1], a[0] == 1}, a, {n, 0, 22}] (* Ray Chandler, Jul 30 2015 *)
  • PARI
    a(n)=prod(i=1, n, i) \\ Felix Fröhlich, Aug 17 2014
    
  • PARI
    {a(n) = if(n<0, 0, n!)}; /* Michael Somos, Mar 04 2004 */
    
  • Python
    for i in range(1, 1000):
        y = i
        for j in range(1, i):
           y *= i - j
        print(y, "\n")
    
  • Python
    import math
    for i in range(1, 1000):
        math.factorial(i)
        print("")
    # Ruskin Harding, Feb 22 2013
    
  • Sage
    [factorial(n) for n in (1..22)] # Giuseppe Coppoletta, Dec 05 2014
    
  • Scala
    (1: BigInt).to(24: BigInt).scanLeft(1: BigInt)( * ) // Alonso del Arte, Mar 02 2019
    

Formula

Exp(x) = Sum_{m >= 0} x^m/m!. - Mohammad K. Azarian, Dec 28 2010
Sum_{i=0..n} (-1)^i * i^n * binomial(n, i) = (-1)^n * n!. - Yong Kong (ykong(AT)curagen.com), Dec 26 2000
Sum_{i=0..n} (-1)^i * (n-i)^n * binomial(n, i) = n!. - Peter C. Heinig (algorithms(AT)gmx.de), Apr 10 2007
The sequence trivially satisfies the recurrence a(n+1) = Sum_{k=0..n} binomial(n,k) * a(k)*a(n-k). - Robert FERREOL, Dec 05 2009
D-finite with recurrence: a(n) = n*a(n-1), n >= 1. n! ~ sqrt(2*Pi) * n^(n+1/2) / e^n (Stirling's approximation).
a(0) = 1, a(n) = subs(x = 1, (d^n/dx^n)(1/(2-x))), n = 1, 2, ... - Karol A. Penson, Nov 12 2001
E.g.f.: 1/(1-x). - Michael Somos, Mar 04 2004
a(n) = Sum_{k=0..n} (-1)^(n-k)*A000522(k)*binomial(n, k) = Sum_{k=0..n} (-1)^(n-k)*(x+k)^n*binomial(n, k). - Philippe Deléham, Jul 08 2004
Binomial transform of A000166. - Ross La Haye, Sep 21 2004
a(n) = Sum_{i=1..n} ((-1)^(i-1) * sum of 1..n taken n - i at a time) - e.g., 4! = (1*2*3 + 1*2*4 + 1*3*4 + 2*3*4) - (1*2 + 1*3 + 1*4 + 2*3 + 2*4 + 3*4) + (1 + 2 + 3 + 4) - 1 = (6 + 8 + 12 + 24) - (2 + 3 + 4 + 6 + 8 + 12) + 10 - 1 = 50 - 35 + 10 - 1 = 24. - Jon Perry, Nov 14 2005
a(n) = (n-1)*(a(n-1) + a(n-2)), n >= 2. - Matthew J. White, Feb 21 2006
1 / a(n) = determinant of matrix whose (i,j) entry is (i+j)!/(i!(j+1)!) for n > 0. This is a matrix with Catalan numbers on the diagonal. - Alexander Adamchuk, Jul 04 2006
Hankel transform of A074664. - Philippe Deléham, Jun 21 2007
For n >= 2, a(n-2) = (-1)^n*Sum_{j=0..n-1} (j+1)*Stirling1(n,j+1). - Milan Janjic, Dec 14 2008
From Paul Barry, Jan 15 2009: (Start)
G.f.: 1/(1-x-x^2/(1-3x-4x^2/(1-5x-9x^2/(1-7x-16x^2/(1-9x-25x^2... (continued fraction), hence Hankel transform is A055209.
G.f. of (n+1)! is 1/(1-2x-2x^2/(1-4x-6x^2/(1-6x-12x^2/(1-8x-20x^2... (continued fraction), hence Hankel transform is A059332. (End)
a(n) = Product_{p prime} p^(Sum_{k > 0} floor(n/p^k)) by Legendre's formula for the highest power of a prime dividing n!. - Jonathan Sondow, Jul 24 2009
a(n) = A053657(n)/A163176(n) for n > 0. - Jonathan Sondow, Jul 26 2009
It appears that a(n) = (1/0!) + (1/1!)*n + (3/2!)*n*(n-1) + (11/3!)*n*(n-1)*(n-2) + ... + (b(n)/n!)*n*(n-1)*...*2*1, where a(n) = (n+1)! and b(n) = A000255. - Timothy Hopper, Aug 12 2009
Sum_{n >= 0} 1/a(n) = e. - Jaume Oliver Lafont, Mar 03 2009
a(n) = a(n-1)^2/a(n-2) + a(n-1), n >= 2. - Jaume Oliver Lafont, Sep 21 2009
a(n) = Gamma(n+1). - Enrique Pérez Herrero, Sep 21 2009
a(n) = A173333(n,1). - Reinhard Zumkeller, Feb 19 2010
a(n) = A_{n}(1) where A_{n}(x) are the Eulerian polynomials. - Peter Luschny, Aug 03 2010
a(n) = n*(2*a(n-1) - (n-1)*a(n-2)), n > 1. - Gary Detlefs, Sep 16 2010
1/a(n) = -Sum_{k=1..n+1} (-2)^k*(n+k+2)*a(k)/(a(2*k+1)*a(n+1-k)). - Groux Roland, Dec 08 2010
From Vladimir Shevelev, Feb 21 2011: (Start)
a(n) = Product_{p prime, p <= n} p^(Sum_{i >= 1} floor(n/p^i)).
The infinitary analog of this formula is: a(n) = Product_{q terms of A050376 <= n} q^((n)_q), where (n)_q denotes the number of those numbers <= n for which q is an infinitary divisor (for the definition see comment in A037445). (End)
The terms are the denominators of the expansion of sinh(x) + cosh(x). - Arkadiusz Wesolowski, Feb 03 2012
G.f.: 1 / (1 - x / (1 - x / (1 - 2*x / (1 - 2*x / (1 - 3*x / (1 - 3*x / ... )))))). - Michael Somos, May 12 2012
G.f. 1 + x/(G(0)-x) where G(k) = 1 - (k+1)*x/(1 - x*(k+2)/G(k+1)); (continued fraction, 2-step). - Sergei N. Gladkovskii, Aug 14 2012
G.f.: W(1,1;-x)/(W(1,1;-x) - x*W(1,2;-x)), where W(a,b,x) = 1 - a*b*x/1! + a*(a+1)*b*(b+1)*x^2/2! - ... + a*(a+1)*...*(a+n-1)*b*(b+1)*...*(b+n-1)*x^n/n! + ...; see [A. N. Khovanskii, p. 141 (10.19)]. - Sergei N. Gladkovskii, Aug 15 2012
From Sergei N. Gladkovskii, Dec 26 2012: (Start)
G.f.: A(x) = 1 + x/(G(0) - x) where G(k) = 1 + (k+1)*x - x*(k+2)/G(k+1); (continued fraction).
Let B(x) be the g.f. for A051296, then A(x) = 2 - 1/B(x). (End)
G.f.: 1 + x*(G(0) - 1)/(x-1) where G(k) = 1 - (2*k+1)/(1-x/(x - 1/(1 - (2*k+2)/(1-x/(x - 1/G(k+1) ))))); (continued fraction). - Sergei N. Gladkovskii, Jan 15 2013
G.f.: 1 + x*(1 - G(0))/(sqrt(x)-x) where G(k) = 1 - (k+1)*sqrt(x)/(1-sqrt(x)/(sqrt(x)-1/G(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Jan 25 2013
G.f.: 1 + x/G(0) where G(k) = 1 - x*(k+2)/( 1 - x*(k+1)/G(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Mar 23 2013
a(n) = det(S(i+1, j), 1 <= i, j <=n ), where S(n,k) are Stirling numbers of the second kind. - Mircea Merca, Apr 04 2013
G.f.: G(0)/2, where G(k) = 1 + 1/(1 - x*(k+1)/(x*(k+1) + 1/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, May 24 2013
G.f.: 2/G(0), where G(k) = 1 + 1/(1 - 1/(1 - 1/(2*x*(k+1)) + 1/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, May 29 2013
G.f.: G(0), where G(k) = 1 + x*(2*k+1)/(1 - x*(2*k+2)/(x*(2*k+2) + 1/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 07 2013
a(n) = P(n-1, floor(n/2)) * floor(n/2)! * (n - (n-2)*((n+1) mod 2)), where P(n, k) are the k-permutations of n objects, n > 0. - Wesley Ivan Hurt, Jun 07 2013
a(n) = a(n-2)*(n-1)^2 + a(n-1), n > 1. - Ivan N. Ianakiev, Jun 18 2013
a(n) = a(n-2)*(n^2-1) - a(n-1), n > 1. - Ivan N. Ianakiev, Jun 30 2013
G.f.: 1 + x/Q(0), m=+2, where Q(k) = 1 - 2*x*(2*k+1) - m*x^2*(k+1)*(2*k+1)/( 1 - 2*x*(2*k+2) - m*x^2*(k+1)*(2*k+3)/Q(k+1) ); (continued fraction). - Sergei N. Gladkovskii, Sep 24 2013
a(n) = A245334(n,n). - Reinhard Zumkeller, Aug 31 2014
a(n) = Product_{i = 1..n} A014963^floor(n/i) = Product_{i = 1..n} A003418(floor(n/i)). - Matthew Vandermast, Dec 22 2014
a(n) = round(Sum_{k>=1} log(k)^n/k^2), for n>=1, which is related to the n-th derivative of the Riemann zeta function at x=2 as follows: round((-1)^n * zeta^(n)(2)). Also see A073002. - Richard R. Forberg, Dec 30 2014
a(n) ~ Sum_{j>=0} j^n/e^j, where e = A001113. When substituting a generic variable for "e" this infinite sum is related to Eulerian polynomials. See A008292. This approximation of n! is within 0.4% at n = 2. See A255169. Accuracy, as a percentage, improves rapidly for larger n. - Richard R. Forberg, Mar 07 2015
a(n) = Product_{k=1..n} (C(n+1, 2)-C(k, 2))/(2*k-1); see Masanori Ando link. - Michel Marcus, Apr 17 2015
Sum_{n>=0} a(n)/(a(n + 1)*a(n + 2)) = Sum_{n>=0} 1/((n + 2)*(n + 1)^2*a(n)) = 2 - exp(1) - gamma + Ei(1) = 0.5996203229953..., where gamma = A001620, Ei(1) = A091725. - Ilya Gutkovskiy, Nov 01 2016
a(2^n) = 2^(2^n - 1) * 1!! * 3!! * 7!! * ... * (2^n - 1)!!. For example, 16! = 2^15*(1*3)*(1*3*5*7)*(1*3*5*7*9*11*13*15) = 20922789888000. - Peter Bala, Nov 01 2016
a(n) = sum(prod(B)), where the sum is over all subsets B of {1,2,...,n-1} and where prod(B) denotes the product of all the elements of set B. If B is a singleton set with element b, then we define prod(B)=b, and, if B is the empty set, we define prod(B) to be 1. For example, a(4)=(1*2*3)+(1*2)+(1*3)+(2*3)+(1)+(2)+(3)+1=24. - Dennis P. Walsh, Oct 23 2017
Sum_{n >= 0} 1/(a(n)*(n+2)) = 1. - Multiplying the denominator by (n+2) in Jaume Oliver Lafont's entry above creates a telescoping sum. - Fred Daniel Kline, Nov 08 2020
O.g.f.: Sum_{k >= 0} k!*x^k = Sum_{k >= 0} (k+y)^k*x^k/(1 + (k+y)*x)^(k+1) for arbitrary y. - Peter Bala, Mar 21 2022
E.g.f.: 1/(1 + LambertW(-x*exp(-x))) = 1/(1-x), see A258773. -(1/x)*substitute(z = x*exp(-x), z*(d/dz)LambertW(-z)) = 1/(1 - x). See A075513. Proof: Use the compositional inverse (x*exp(-x))^[-1] = -LambertW(-z). See A000169 or A152917, and Richard P. Stanley: Enumerative Combinatorics, vol. 2, p. 37, eq. (5.52). - Wolfdieter Lang, Oct 17 2022
Sum_{k >= 1} 1/10^a(k) = A012245 (Liouville constant). - Bernard Schott, Dec 18 2022
From David Ulgenes, Sep 19 2023: (Start)
1/a(n) = (e/(2*Pi*n)*Integral_{x=-oo..oo} cos(x-n*arctan(x))/(1+x^2)^(n/2) dx). Proof: take the real component of Laplace's integral for 1/Gamma(x).
a(n) = Integral_{x=0..1} e^(-t)*LerchPhi(1/e, -n, t) dt. Proof: use the relationship Gamma(x+1) = Sum_{n >= 0} Integral_{t=n..n+1} e^(-t)t^x dt = Sum_{n >= 0} Integral_{t=0..1} e^(-(t+n))(t+n)^x dt and interchange the order of summation and integration.
Conjecture: a(n) = 1/(2*Pi)*Integral_{x=-oo..oo}(n+i*x+1)!/(i*x+1)-(n+i*x-1)!/(i*x-1)dx. (End)
a(n) = floor(b(n)^n / (floor(((2^b(n) + 1) / 2^n)^b(n)) mod 2^b(n))), where b(n) = (n + 1)^(n + 2) = A007778(n+1). Joint work with Mihai Prunescu. - Lorenzo Sauras Altuzarra, Oct 18 2023
a(n) = e^(Integral_{x=1..n+1} Psi(x) dx) where Psi(x) is the digamma function. - Andrea Pinos, Jan 10 2024
a(n) = Integral_{x=0..oo} e^(-x^(1/n)) dx, for n > 0. - Ridouane Oudra, Apr 20 2024
O.g.f.: N(x) = hypergeometric([1,1], [], x) = LaplaceTransform(x/(1-x))/x, satisfying x^2*N'(x) + (x-1)*N(x) + 1 = 0, with N(0) = 1. - Wolfdieter Lang, May 31 2025

A008290 Triangle T(n,k) of rencontres numbers (number of permutations of n elements with k fixed points).

Original entry on oeis.org

1, 0, 1, 1, 0, 1, 2, 3, 0, 1, 9, 8, 6, 0, 1, 44, 45, 20, 10, 0, 1, 265, 264, 135, 40, 15, 0, 1, 1854, 1855, 924, 315, 70, 21, 0, 1, 14833, 14832, 7420, 2464, 630, 112, 28, 0, 1, 133496, 133497, 66744, 22260, 5544, 1134, 168, 36, 0, 1, 1334961, 1334960, 667485, 222480, 55650, 11088, 1890, 240, 45, 0, 1
Offset: 0

Views

Author

Keywords

Comments

This is a binomial convolution triangle (Sheffer triangle) of the Appell type: (exp(-x)/(1-x),x), i.e., the e.g.f. of column k is (exp(-x)/(1-x))*(x^k/k!). See the e.g.f. given by V. Jovovic below. - Wolfdieter Lang, Jan 21 2008
The formula T(n,k) = binomial(n,k)*A000166(n-k), with the derangements numbers (subfactorials) A000166 (see also the Charalambides reference) shows the Appell type of this triangle. - Wolfdieter Lang, Jan 21 2008
T(n,k) is the number of permutations of {1,2,...,n} having k pairs of consecutive right-to-left minima (0 is considered a right-to-left minimum for each permutation). Example: T(4,2)=6 because we have 1243, 1423, 4123, 1324, 3124 and 2134; for example, 1324 has right-to-left minima in positions 0-1,3-4 and 2134 has right-to-left minima in positions 0,2-3-4, the consecutive ones being joined by "-". - Emeric Deutsch, Mar 29 2008
T is an example of the group of matrices outlined in the table in A132382--the associated matrix for the sequence aC(0,1). - Tom Copeland, Sep 10 2008
A refinement of this triangle is given by A036039. - Tom Copeland, Nov 06 2012
This triangle equals (A211229(2*n,2*k)) n,k >= 0. - Peter Bala, Dec 17 2014

Examples

			exp((y-1)*x)/(1-x) = 1 + y*x + (1/2!)*(1+y^2)*x^2 + (1/3!)*(2 + 3*y + y^3)*x^3 + (1/4!)*(9 + 8*y + 6*y^2 + y^4)*x^4 + (1/5!)*(44 + 45*y + 20*y^2 + 10*y^3 + y^5)*x^5 + ...
Triangle begins:
       1
       0      1
       1      0     1
       2      3     0     1
       9      8     6     0    1
      44     45    20    10    0    1
     265    264   135    40   15    0   1
    1854   1855   924   315   70   21   0  1
   14833  14832  7420  2464  630  112  28  0 1
  133496 133497 66744 22260 5544 1134 168 36 0 1
...
From _Peter Bala_, Feb 13 2017: (Start)
The infinitesimal generator has integer entries given by binomial(n,k)*(n-k-1)! for n >= 2 and 0 <= k <= n-2 and begins
   0
   0  0
   1  0  0
   2  3  0  0
   6  8  6  0 0
  24 30 20 10 0 0
...
It is essentially A238363 (unsigned and omitting the main diagonal), A211603 (with different offset) and appears to be A092271, again without the main diagonal. (End)
		

References

  • Ch. A. Charalambides, Enumerative Combinatorics, Chapman & Hall/CRC, Boca Raton, Florida, 2002, p. 173, Table 5.2 (without row n=0 and column k=0).
  • R. L. Graham, D. E. Knuth and O. Patashnik, Concrete Mathematics. Addison-Wesley, Reading, MA, 1990, p. 194.
  • Arnold Kaufmann, Introduction à la combinatorique en vue des applications, Dunod, Paris, 1968. See p. 92.
  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 65.

Crossrefs

Mirror of triangle A098825.
Cf. A080955.
Cf. A000012, A000142 (row sums), A000354.
Cf. A170942. Sub-triangle of A211229.
T(2n,n) gives A281262.

Programs

  • Haskell
    a008290 n k = a008290_tabl !! n !! k
    a008290_row n = a008290_tabl !! n
    a008290_tabl = map reverse a098825_tabl
    -- Reinhard Zumkeller, Dec 16 2013
  • Maple
    T:= proc(n,k) T(n, k):= `if`(k=0, `if`(n<2, 1-n, (n-1)*
          (T(n-1, 0)+T(n-2, 0))), binomial(n, k)*T(n-k, 0))
        end:
    seq(seq(T(n, k), k=0..n), n=0..12);  # Alois P. Heinz, Mar 15 2013
  • Mathematica
    a[0] = 1; a[1] = 0; a[n_] := Round[n!/E] /; n >= 1 size = 8; Table[Binomial[n, k]a[n - k], {n, 0, size}, {k, 0, n}] // TableForm (* Harlan J. Brothers, Mar 19 2007 *)
    T[n_, k_] := Subfactorial[n-k]*Binomial[n, k]; Table[T[n, k], {n, 0, 10}, {k, 0, n}] // Flatten (* Jean-François Alcover, Jul 12 2017 *)
    T[n_, k_] := If[n<1, Boole[n==0 && k==0], T[n, k] = T[n-1, k-1] + T[n-1, k]*(n-1-k) + T[n-1, k+1]*(k+1)]; (* Michael Somos, Sep 13 2024 *)
    T[0, 0]:=1; T[n_, 0]:=T[n, 0]=n  T[n-1, 0]+(-1)^n; T[n_, k_]:=T[n, k]=n/k T[n-1, k-1];
    Flatten@Table[T[n, k], {n, 0, 9}, {k, 0, n}] (* Oliver Seipel, Nov 26 2024 *)
  • PARI
    {T(n, k) = if(k<0 || k>n, 0, n!/k! * sum(i=0, n-k, (-1)^i/i!))}; /* Michael Somos, Apr 26 2000 */
    

Formula

T(n, k) = T(n-1, k)*n + binomial(n, k)*(-1)^(n-k) = T(n, k-1)/k + binomial(n, k)*(-1)^(n-k)/(n-k+1) = T(n-1, k-1)*n/k = T(n-k, 0)*binomial(n, k) = A000166(n-k)*binomial(n,k) [with T(0, 0) = 1]; so T(n, n) = 1, T(n, n-1) = 0, T(n, n-2) = n*(n-1)/2 for n >= 0.
Sum_{k=0..n} T(n, k) = Sum_{k=0..n} k * T(n, k) = n! for all n > 0, n, k integers. - Wouter Meeussen, May 29 2001
From Vladeta Jovovic, Aug 12 2002: (Start)
O.g.f. for k-th column: (1/k!)*Sum_{i>=k} i!*x^i/(1+x)^(i+1).
O.g.f. for k-th row: k!*Sum_{i=0..k} (-1)^i/i!*(1-x)^i. (End)
E.g.f.: exp((y-1)*x)/(1-x). - Vladeta Jovovic, Aug 18 2002
E.g.f. for number of permutations with exactly k fixed points is x^k/(k!*exp(x)*(1-x)). - Vladeta Jovovic, Aug 25 2002
Sum_{k=0..n} T(n, k)*x^k is the permanent of the n X n matrix with x's on the diagonal and 1's elsewhere; for x = 0, 1, 2, 3, 4, 5, 6 see A000166, A000142, A000522, A010842, A053486, A053487, A080954. - Philippe Deléham, Dec 12 2003; for x = 1+i see A009551 and A009102. - John M. Campbell, Oct 11 2011
T(n, k) = Sum_{j=0..n} A008290(n, j)*k^(n-j) is the permanent of the n X n matrix with 1's on the diagonal and k's elsewhere; for k = 0, 1, 2 see A000012, A000142, A000354. - Philippe Deléham, Dec 13 2003
T(n,k) = Sum_{j=0..n} (-1)^(j-k)*binomial(j,k)*n!/j!. - Paul Barry, May 25 2006
T(n,k) = (n!/k!)*Sum_{j=0..n-k} ((-1)^j)/j!, 0 <= k <= n. From the Appell type of the triangle and the subfactorial formula.
T(n,0) = n*Sum_{j=0..n-1} (j/(j+1))*T(n-1,j), T(0,0)=1. From the z-sequence of this Sheffer triangle z(j)=j/(j+1) with e.g.f. (1-exp(x)*(1-x))/x. See the W. Lang link under A006232 for Sheffer a- and z-sequences. - Wolfdieter Lang, Jan 21 2008
T(n,k) = (n/k)*T(n-1,k-1) for k >= 1. See above. From the a-sequence of this Sheffer triangle a(0)=1, a(n)=0, n >= 1 with e.g.f. 1. See the W. Lang link under A006232 for Sheffer a- and z-sequences. - Wolfdieter Lang, Jan 21 2008
From Henk P. J. van Wijk, Oct 29 2012: (Start)
T(n,k) = T(n-1,k)*(n-1-k) + T(n-1,k+1)*(k+1) for k=0 and
T(n,k) = T(n-1,k-1) + T(n-1,k)*(n-1-k) + T(n-1,k+1)*(k+1) for k>=1.
(End)
T(n,k) = A098825(n,n-k). - Reinhard Zumkeller, Dec 16 2013
Sum_{k=0..n} k^2 * T(n, k) = 2*n! if n > 1. - Michael Somos, Jun 06 2017
From Tom Copeland, Jul 26 2017: (Start)
The lowering and raising operators of this Appell sequence of polynomials P(n,x) are L = d/dx and R = x + d/dL log[exp(-L)/(1-L)] = x-1 + 1/(1-L) = x + L + L^2 - ... such that L P(n,x) = n P(n-1,x) and R P(n,x) = P(n+1,x).
P(n,x) = (1-L)^(-1) exp(-L) x^n = (1+L+L^2+...)(x-1)^n = n! Sum_{k=0..n} (x-1)^k / k!.
The formalism of A133314 applies to the pair of entries A008290 and A055137.
The polynomials of this pair P_n(x) and Q_n(x) are umbral compositional inverses; i.e., P_n(Q.(x)) = x^n = Q_n(P.(x)), where, e.g., (Q.(x))^n = Q_n(x).
For more on the infinitesimal generator, noted by Bala below, see A238385. (End)
Sum_{k=0..n} k^m * T(n,k) = A000110(m)*n! if n >= m. - Zhujun Zhang, May 24 2019
Sum_{k=0..n} (k+1) * T(n,k) = A098558(n). - Alois P. Heinz, Mar 11 2022
From Alois P. Heinz, May 20 2023: (Start)
Sum_{k=0..n} (-1)^k * T(n,k) = A000023(n).
Sum_{k=0..n} (-1)^k * k * T(n,k) = A335111(n). (End)
T(n,k) = A145224(n,k)+A145225(n,k), refined by even and odd perms. - R. J. Mathar, Jul 06 2023

Extensions

Comments and more terms from Michael Somos, Apr 26 2000 and Christian G. Bower, Apr 26 2000

A019774 Decimal expansion of sqrt(e).

Original entry on oeis.org

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

Views

Author

Keywords

Comments

Also where x^(x^(-2)) is a maximum. - Robert G. Wilson v, Oct 22 2014
e^(1/2) maximizes the value of x^(c/(x^2)) for any real positive constant c, and minimizes for it for a negative constant, on the range x > 0. - A.H.M. Smeets, Aug 16 2018

Examples

			1.6487212707001281468486507878141635716537761007101480115750...
		

Crossrefs

Cf. A000354, A001113, A058281 for continued fraction for sqrt(e), A019775.

Programs

  • Maple
    evalf(sqrt(exp(1)), 120); # Muniru A Asiru, Aug 16 2018
  • Mathematica
    RealDigits[N[Sqrt[E],200]][[1]] (* Vladimir Joseph Stephan Orlovsky, Feb 21 2011 *)
  • PARI
    default(realprecision, 20080); x=sqrt(exp(1)); for (n=1, 20000, d=floor(x); x=(x-d)*10; write("b019774.txt", n, " ", d)); \\ Harry J. Smith, May 01 2009

Formula

sqrt(e) = Sum_{n>=0} 1/(2^n*n!) = Sum_{n>=0} 1/(2n)!!. - Daniel Forgues, Apr 17 2011
sqrt(e) = 1 + Sum_{n>0} Product_{i=1..n} 1/(2n). - Ralf Stephan, Sep 11 2013
Continued fraction representation: sqrt(e) = 1 + 1/(1 + 2/(3 + 4/(5 + ... ))). See A000354 for details. - Peter Bala, Jan 30 2015
sqrt(e) = (1/2)*( 1 + (3 + (5 + (7 + ...)/6)/4)/2 ) = 1 + (1 + (1 + (1 + ...)/6)/4)/2. - Rok Cestnik, Jan 19 2017
sqrt(e) = 2*Sum_{n >= 0} 1/((1 - 4*n^2)*(2^n)*n!). - Peter Bala, Jan 16 2022
sqrt(e) = (16/31)*(1 + Sum_{n>=1} (1/2)^n*((1/2)*n^3 + (1/2)*n + 1)/n!). - Alexander R. Povolotsky, Jul 01 2022
sqrt(e) = Sum_{n >= 0} (n + 1/2)/(2^n*n!). - Peter Bala, Jun 29 2024
Equals i^(-i/Pi), where i denotes the imaginary unit. - Stefano Spezia, Mar 01 2025

A007680 a(n) = (2n+1)*n!.

Original entry on oeis.org

1, 3, 10, 42, 216, 1320, 9360, 75600, 685440, 6894720, 76204800, 918086400, 11975040000, 168129561600, 2528170444800, 40537905408000, 690452066304000, 12449059983360000, 236887827111936000, 4744158915944448000, 99748982335242240000
Offset: 0

Views

Author

Keywords

Comments

Denominators in series for sqrt(Pi/4)*erf(x): sqrt(Pi/4)*erf(x)= x/1 - x^3/3 + x^5/10 - x^7/42 + x^9/216 -+ ...
Appears to be the BinomialMean transform of A000354 (after truncating the first term of A000354). (See A075271 for the definition of BinomialMean.) - John W. Layman, Apr 16 2003
Number of permutations p of {1,2,...,n+2} such that max|p(i)-i|=n+1. Example: a(1)=3 since only the permutations 312,231 and 321 of {1,2,3} satisfy the given condition. - Emeric Deutsch, Jun 04 2003
Stirling transform of A000670(n+1) = [3, 13, 75, 541, ...] is a(n) = [3, 10, 42, 216, ...]. - Michael Somos, Mar 04 2004
Stirling transform of a(n) = [2, 10, 42, 216, ...] is A052875(n+1) = [2, 12, 74, ...]. - Michael Somos, Mar 04 2004
A related sequence also arises in evaluating indefinite integrals of sec(x)^(2k+1), k=0, 1, 2, ... Letting u = sec(x) and d = sqrt(u^2-1), one obtains a(0) = log(u+d) 2*k*a(k) = (2*k-1)*u^(2*k-1)*d + a(k-1). Viewing these as polynomials in u gives 2^k*k!*a(k) = a(0) + d*Sum(i=0..k-1){ (2*i+1)*i!*2^i*u^(2*i+1) }, which is easily proved by induction. Apart from the power of 2, which could be incorporated into the definition of u (or by looking at erf(ix/2)/ i (i=sqrt(-1)), the sum's coefficients form our series and are the reciprocals of the power series terms for -sqrt(-Pi/4)*erf(ix/2)). This yields a direct but somewhat mysterious relationship between the power series of erf(x) and integrals involving sec(x). - William A. Huber (whuber(AT)quantdec.com), Mar 14 2002
When written in factoradic ("factorial base"), this sequence from a(1) onwards gives the smallest number containing two adjacent digits, increasing when read from left to right, whose difference is n-1. - Christian Perfect, May 03 2016
a(n-1)^2 is the number of permutations p of [1..2n] such that Sum_{i=1..2n} abs(p(i)-i) = 2n^2-2. - Fang Lixing, Dec 07 2018
A standard series for the calculation of coordinates on a clothoid (also called cornuspiral):
x = s*(a(0) - (tau^2/a(2)) + (tau^4/a(4)) - (tau^6/a(6)) + ...)
y = s*((tau/a(1)) + (tau^3/a(3)) - (tau^5/a(5)) + ...).
s is the arclength from the clothoids origin to the desired point p(x,y). The tangent at the clothoids origin intersects with the tangent at the point p(x,y) with an angle of tau. - Thomas Scheuerle, Oct 13 2021
a(n) = P_n(1) where P_n(x) is the Pidduck polynomials. - Michael Somos, May 27 2023

Examples

			G.f. = 1 + 3*x + 10*x^2 + 42*x^3 + 216*x^4 + 1320*x^5 + 9360*x^6 + ... - _Michael Somos_, Jan 01 2019
		

References

  • H. W. Gould, A class of binomial sums and a series transform, Utilitas Math., 45 (1994), 71-83.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • N. Wirth, Systematisches Programmieren, 1975, exercise 9.3

Crossrefs

From Johannes W. Meijer, Nov 12 2009: (Start)
Appears in A167546.
Equals the rows sums of A167556.
(End)

Programs

  • GAP
    a:=List([0..20],n->(2*n+1)*Factorial(n));; Print(a); # Muniru A Asiru, Jan 01 2019
  • Magma
    [(2*n+1)*Factorial(n): n in [0..20]]; // Vincenzo Librandi, Aug 20 2011
    
  • Maple
    [(2*n+1)*factorial(n)$n=0..20]; # Muniru A Asiru, Jan 01 2019
  • Mathematica
    Table[(2n + 1)*n!, {n, 0, 20}] (* Stefan Steinerberger, Apr 08 2006 *)
  • PARI
    {a(n) = if( n<0, 0, (2*n+1) * n!)}; /* Michael Somos, Mar 04 2004 */
    

Formula

E.g.f.: (1+x)/(1-x)^2.
This is the binomial mean transform of A000354 (after truncating the first term). See Spivey and Steil (2006). - Michael Z. Spivey (mspivey(AT)ups.edu), Feb 26 2006
E.g.f.: (of aerated sequence) 1+x^2/2+sqrt(pi)*(x+x^3/4)*exp(x^2/4)*ERF(x/2). - Paul Barry, Apr 11 2010
G.f.: 1 + x*G(0), where G(k)= 1 + x*(k+1)/(1 - (k+2)/(k+2 + (k+1)/G(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Jul 08 2013
a(n-2) = (A208528(n)+A208529(n))/2, for n>=2. - Luis Manuel Rivera Martínez, Mar 05 2014
D-finite with recurrence: (-2*n+1)*a(n) +n*(2*n+1)*a(n-1)=0. - R. J. Mathar, Jan 27 2020
Sum_{n>=0} 1/a(n) = sqrt(Pi)*erfi(1)/2 = A019704 * A099288 = A347910. - Amiram Eldar, Oct 07 2020
Sum_{n>=0} (-1)^n/a(n) = A347909 . - R. J. Mathar, Sep 30 2021

A010844 a(n) = 2*n*a(n-1) + 1 with a(0) = 1.

Original entry on oeis.org

1, 3, 13, 79, 633, 6331, 75973, 1063623, 17017969, 306323443, 6126468861, 134782314943, 3234775558633, 84104164524459, 2354916606684853, 70647498200545591, 2260719942417458913, 76864478042193603043, 2767121209518969709549, 105150605961720848962863
Offset: 0

Views

Author

Keywords

Comments

Related to Incomplete Gamma Function at 1/2. - Michael Somos, Mar 26 1999
For positive n, a(n) is equal to 2^n times the permanent of the n X n matrix with 3/2's along the main diagonal, and 1's everywhere else. - John M. Campbell, Jul 09 2011
Number of ways to sort a spreadsheet with n columns. (A subset of columns is chosen to sort on. These columns are ordered from major to minor, and each designated as to whether to sort by ascending or descending order. For example a spreadsheet with columns A,B,C,D could be sorted by column D ascending, then by column B descending, or any of 632 other ways.) - Marc LeBrun, Dec 07 2013
a(n) is a specific instance of sequences having the form b(0) = x, b(n) = a*n*b(n-1) + k for n >= 1. (Here x = 1, a = 2, and k = 1). Sequences of this form have a closed form of b(n) = n!*a^n*x + k*Sum_{j=1..n} n!*a^(n-j)/j!. - Gary Detlefs, Mar 26 2018

Examples

			a(3) = 2*3*a(2) + 1 = 6*13 + 1 = 79.
G.f. = 1 + 3*x + 13*x^2 + 79*x^3 + 633*x^4 + 6331*x^5 + 75973*x^6 + 1063623*x^7 + ...
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, Tenth Printing, 1972, p. 262.

Crossrefs

Programs

  • Maple
    G:=(x,a,k,n)-> n!*a^n*x + k*sum(n!*a^(n-j)/j!,j=1..n); seq(G(1,2,1,n), n = 0..20) # Gary Detlefs, Mar 26 2018
    a := n -> 2^n*add((n!/k!)*(1/2)^k, k=0..n):
    seq(a(n), n=0..19); # Peter Luschny, Jan 06 2020
    seq(simplify(2^n*KummerU(-n, -n, 1/2)), n = 0..19); # Peter Luschny, May 10 2022
  • Mathematica
    Table[ Gamma[ n, 1/2 ]*Exp[ 1/2 ]*2^(n-1), {n, 1, 24} ]
       and/or... s=1;lst={};Do[s+=s++n;AppendTo[lst, s], {n, 1, 5!, 2}];lst (* Vladimir Joseph Stephan Orlovsky, Oct 23 2008 *)
    a[ n_] := If[ n<0, 0, Floor[ n! E^(1/2) 2^n ]] (* Michael Somos, Sep 04 2013 *)
    nxt[{n_,a_}]:={n+1,2*a(n+1)+1}; NestList[nxt,{0,1},20][[All,2]] (* Harvey P. Dale, Jan 06 2022 *)
    a[n_] := n! 2^n Hypergeometric1F1[-n, -n, 1/2];
    Table[a[n], {n, 0, 19}] (* Peter Luschny, Jul 28 2024 *)
  • PARI
    {a(n) = if( n<0, 0, n! * sum(k=0, n, 2^(n-k) / k!))} /* Michael Somos, Sep 04 2013 */

Formula

a(n) = floor(n! * e^(1/2) * 2^n) = n! * Sum_{k=0..n} 2^(n-k) / k! (i.e. binomial transform of (2n)!! = n!*2^n) = n! * (e^(1/2) * 2^n - Sum_{k >= n+1} 2^(n-k) / k!). - Michael Somos, Mar 26 1999
a(n) = A056541(n) + A000165(n). - Henry Bottomley, Jun 20 2000
E.g.f.: exp(x)/(1 - 2*x). - Vladeta Jovovic, Aug 11 2002
Sum_{n >= 1} 1/a(n) = 0.4246665348160769533082551230... - Cino Hilliard, Aug 19 2003
a(n) = Sum_{k=0..n} P(n, k)*2^k, where P(n,k) = n!/(n-k)!. - Ross La Haye, Aug 29 2005
G.f.: 1/(1 - x - 2*x/(1 - 2*x/(1 - x - 4*x/(1 - 4*x/(1 - x - 6*x/(1 - 6*x/(1 - x - 8*x/(1 - 8*x/(1 - x - 10*x/(1 - ... (continued fraction).
G.f.: 1/Q(0), where Q(k) = 1 - x*(4*k+3) - 4*x^2*(k+1)^2/Q(k+1); (continued fraction). - Sergei N. Gladkovskii, Sep 30 2013
a(n) = Sum_{k=0..n} C(n,k)*k!*2^k. - Marc LeBrun, Dec 07 2013
0 = a(n)*(2*a(n+1) - 5*a(n+2) + a(n+3)) + a(n+1)*(a(n+1) + a(n+2) - a(n+3)) + a(n+2)*a(n+2) if n > -2. - Michael Somos, Jan 02 2014
a(n) + (-2*n-1)*a(n-1) + 2*(n-1)*a(n-2) = 0. - R. J. Mathar, Jan 31 2014
a(n) = hypergeometric_U(1, n+2, 1/2)/2. - Peter Luschny, Nov 26 2014
From Peter Bala, Jan 30 2015: (Start)
a(n) = Integral_{x >= 0} (2*x + 1)^n*exp(-x) dx. (Cf. A000354.)
The e.g.f. y = exp(x)/(1 - 2*x) satisfies the differential equation (1 - 2*x)*y' = (3 - 2*x)*y. R. J. Mathar's recurrence above follows easily from this.
The sequence b(n) := 2^n*n! also satisfies R. J. Mathar's recurrence with b(0) = 1 and b(1) = 2. This leads to the continued fraction representation a(n) = 2^n*n!*( 1 + 1/(2 - 2/(5 - 4/(7 - ... - (2*n - 2)/(2*n + 1) )))) for n >= 2. Taking the limit gives the continued fraction representation exp(1/2) = 1 + 1/(2 - 2/(5 - 4/(7 - ... - (2*n - 2)/((2*n + 1) - ... )))). (End)
a(n) = 2^n*KummerU(-n, -n, 1/2). - Peter Luschny, May 10 2022
a(n) = n!*2^n*hypergeom([-n], [-n], 1/2). - Peter Luschny, Jul 28 2024

Extensions

Better description and formulas from Michael Somos

A132382 Lower triangular array T(n,k) generator for group of arrays related to A001147 and A102625.

Original entry on oeis.org

1, -1, 1, -1, -2, 1, -3, -3, -3, 1, -15, -12, -6, -4, 1, -105, -75, -30, -10, -5, 1, -945, -630, -225, -60, -15, -6, 1, -10395, -6615, -2205, -525, -105, -21, -7, 1, -135135, -83160, -26460, -5880, -1050, -168, -28, -8, 1, -2027025, -1216215, -374220, -79380, -13230, -1890, -252, -36, -9, 1
Offset: 0

Views

Author

Tom Copeland, Nov 11 2007, Nov 12 2007, Nov 19 2007, Dec 04 2007, Dec 06 2007

Keywords

Comments

Let b(n) = LPT[ A001147 ] = -A001147(n-1) for n > 0 and 1 for n=0, where LPT represents the action of the list partition transform described in A133314.
Then T(n,k) = binomial(n,k) * b(n-k) .
Form the matrix of polynomials TB(n,k,t) = T(n,k) * t^(n-k) = binomial(n,k) * b(n-k) * t^(n-k) = binomial(n,k) * Pb(n-k,t),
beginning as
1;
-1, 1;
-1*t, -2, 1;
-3*t^2, -3*t, -3, 1;
-15*t^3, -12*t^2, -6*t, -4, 1;
-105*t^4, -75*t^3, -30*t^2, -10*t, -5, 1;
Let Pc(n,t) = LPT(Pb(.,t)).
Then [TB(t)]^(-1) = TC(t) = [ binomial(n,k) * Pc(n-k,t) ] = LPT(TB),
whose first column is
Pc(0,t) = 1
Pc(1,t) = 1
Pc(2,t) = 2 + t
Pc(3,t) = 6 + 6*t + 3*t^2
Pc(4,t) = 24 + 36*t + 30*t^2 + 15*t^3
Pc(5,t) = 120 + 240*t + 270*t^2 + 210*t^3 + 105*t^4.
The coefficients of these polynomials are given by the reverse of A102625 with the highest order coefficients given by A001147 with an additional leading 1.
Note this is not the complete matrix TC. The complete matrix is formed by multiplying along the diagonal of the lower triangular Pascal matrix by these polynomials, embedding trees of coefficients in the matrix.
exp[Pb(.,t)*x] = 1 + [(1-2t*x)^(1/2) - 1] / (t-0) = [1 + a finite diff. of [(1-2t*x)^(1/2)] with step t] = e.g.f. of the first column of TB.
exp[Pc(.,t)*x] = 1 / { 1 + [(1-2t*x)^(1/2) - 1] / t } = 1 / exp[Pb(.,t)*x) = e.g.f. of the first column of TC.
TB(t) and TC(t), being inverse to each other, are the generators of an Abelian group.
TB(0) and TC(0) are generators for a subgroup representing the iterated Laguerre operator described in A132013 and A132014.
Let sb(t,m) and sc(t,m) be the associated sequences under the LPT to TB(t)^m = B(t,m) and TC(t)^m = C(t,m).
Let Esb(t,m) and Esc(t,m) be e.g.f.'s for sb(t,m) and sc(t,m), rB(t,m) and rC(t,m) be the row sums of B(t,m) and C(t,m) and aB(t,m) and aC(t,m) be the alternating row sums.
Then B(t,m) is the inverse of C(t,m), Esb(t,m) is the reciprocal of Esc(t,m) and sb(t,m) and sc(t,m) form a reciprocal pair under the LPT. Similar relations hold among the row sums and the alternating sign row sums and associated quantities.
All the group members have the form B(t,m) * C(u,p) = TB(t)^m * TC(u)^p = [ binomial(n,k) * s(n-k) ]
with associated e.g.f. Es(x) = exp[m * Pb(.,t) * x] * exp[p * Pc(.,u) * x] for the first column of the matrix, with terms s(n), so group multiplication is isomorphic to matrix multiplication and to multiplication of the e.g.f.'s for the associated sequences (see examples).
These results can be extended to other groups of integer-valued arrays by replacing the 2 by any natural number in the expression for exp[Pb(.,t)*x].
More generally,
[ G.f. for M = Product_{i=0..j} B[s(i),m(i)] * C[t(i),n(i)] ]
= exp(u*x) * Product_{i=0..j} { exp[m(i) * Pb(.,s(i)) * x] * exp[n(i) * Pc(.,t(i)) * x] }
= exp(u*x) * Product_{i=0..j} { 1 + [ (1 - 2*s(i)*x)^(1/2) - 1 ] / s(i) }^m(i) / { 1 + [ (1 - 2*t(i)*x)^(1/2) - 1 ] / t(i) }^n(i)
= exp(u*x) * H(x)
[ E.g.f. for M ] = I_o[2*(u*x)^(1/2)] * H(x).
M is an integer-valued matrix for m(i) and n(i) positive integers and s(i) and t(i) integers. To invert M, change B to C in Product for M.
H(x) is the e.g.f. for the first column of M and diagonally multiplying the Pascal matrix by the terms of this column generates M. See examples.
The G.f. for M, i.e., the e.g.f. for the row polynomials of M, implies that the row polynomials form an Appell sequence (see Wikipedia and Mathworld). - Tom Copeland, Dec 03 2013

Examples

			Some group members and associated arrays are
(t,m) :: Array :: Asc. Matrix :: Asc. Sequence :: E.g.f. for sequence
..............................................................................
(0,1).::.B..::..A132013.::.(1,-1,0,0,0,0,...).....::.s(x).=.1-x
(0,1).::.C..::..A094587.::.(0!,1!,2!,3!,...)......::.1./.s(x)
(0,1).::.rB.::.~A055137.::.(1,0,-1,-2,-3,-4,...)..::.exp(x).*.s(x)
(0,1).::.rC.::....-.....::..A000522...............::.exp(x)./.s(x)
(0,1).::.aB.::....-.....::.(1,-2,3,-4,5,-6,...)...::.exp(-x).*.s(x)
(0,1).::.aC.::..A008290.::..A000166...............::.exp(-x)./.s(x)
..............................................................................
(0,2).::.B..::..A132014.::.(1,-2,2,0,0,0,0...)....::.s(x).=.(1-x)^2
(0,2).::.C..::..A132159.::.(1!,2!,3!,4!,...)......::..1./.s(x).
(0,2).::.rB.::...-......::.(1,-1,-1,1,5,11,19,29,)::.exp(x).*.s(x).
(0,2).::.rC.::...-......::..A001339...............::.exp(x)./.s(x).
(0,2).::.aB.::...-......::.(-1)^n.A002061(n+1)....::.exp(-x).*.s(x).
(0,2).::.aC.::...-......::..A000255...............::.exp(-x)./.s(x).
..............................................................................
(1,1).::.B..::..T.......::.(1,-A001147(n-1))......::.s(x).=.(1-2x)^(1/2)
(1,1).::.C..::.~A113278.::..A001147...............::.1./.s(x)...
(1,1).::.rB.::...-......::..A055142...............::.exp(x).*.s(x).
(1,1).::.rC.::...-......::..A084262...............::.exp(x)./.s(x).
(1,1).::.aB.::...-......::.(1,-2,2,-4,-4,-56,...).::.exp(-x).*.s(x).
(1,1).::.aC.::...-......::..A053871...............::.exp(-x)./.s(x).
..............................................................................
(2,1).::.B..::...-......::.(1,-A001813)...........::.s=[1+(1-4x)^(1/2)]/2....
(2,1).::.C..::...-......::..A001761...............::.1./.s(x)..
(2,1).::.rB.::...-......::.(1,0,-3,-20,-183,...)..::.exp(x).*.s(x)..
(2,1).::.rC.::...-......::.(1,2,7,46,485,...).....::.exp(x)./.s(x).
(2,1).::.aB.::...-......::.(1,-2,1,-10,-79,...)...::.exp(-x).*.s(x).
(2,1).::.aC.::...-......::.(1,0,3,20,237,...).....::.exp(-x)./.s(x)
..............................................................................
(1,2).::.B..::.~A134082.::.(1,-2,0,0,0,0,...).....::.s(x).=.1.-.2x
(1,2).::.C..::....-.....::..A000165...............::.1./.s(x)..
(1,2).::.rB.::....-.....::.(1,-1,-3,-5,-7,-9,...).::.exp(x).*.s(x).
(1,2).::.rC.::....-.....::..A010844...............::.exp(x)./.s(x)..
(1,2).::.aB.::....-.....::.(1,-3,5,-7,9,-11,...)..::.exp(-x).*.s(x).
(1,2).::.aC.::....-.....::..A000354...............::.exp(-x)./.s(x).
..............................................................................
(The tilde indicates the match is not exact--specifically, there are differences in signs from the true matrices.)
Note the row sums correspond to binomial transforms of s(x) and the alternating row sums, to inverse binomial transforms, or, finite differences.
Some additional examples:
C(1,2)*B(0,1) = B(1,-2)*C(0,-1) = [ binomial(n,k)*A002866(n-k) ] with asc. e.g.f. (1-x) / (1-2x).
B(1,2)*C(0,1) = C(1,-2)*B(0,-1) = 2I - A094587 with asc. e.g.f. (1-2x) / (1-x).
		

Formula

[G.f. for TB(n,k,t)] = GTB(u,x,t) = exp(u*x) * { 1 + [ (1 - 2t*x)^(1/2) - 1 ] / t } = exp[(u+Pb(.,t))*x] where TB(n,k,t) = (D_x)^n (D_u)^k /k! GTB(u,x,t) eval. at u=x=0.
[G.f. for TC(n,k,t)] = GTC(u,x,t) = exp(u*x) / { 1 + [ (1 - 2t*x)^(1/2) - 1 ] / t } = exp[(u+Pc(.,t))*x] where TC(n,k,t) = (D_x)^n (D_u)^k /k! GTC(u,x,t) eval. at u=x=0.
[E.g.f. for TB(n,k,t)] = I_o[2*(u*x)^(1/2)] * { 1 + [ (1 - 2t*x)^(1/2) - 1 ] / t } and
[E.g.f. for TC(n,k,t)] = I_o[2*(u*x)^(1/2)] / { 1 + [ (1 - 2t*x)^(1/2) - 1 ] / t }
where I_o is the zeroth modified Bessel function of the first kind, i.e.,
I_o[2*(u*x)^(1/2)] = Sum_{j>=0} (u^j/j!) * (x^j/j!).
So [e.g.f. for TB(n,k)] = I_o[2*(u*x)^(1/2)] * (1 - 2x)^(1/2).

Extensions

More terms from Tom Copeland, Dec 05 2007

A157142 Signed denominators of Leibniz series for Pi/4.

Original entry on oeis.org

1, -3, 5, -7, 9, -11, 13, -15, 17, -19, 21, -23, 25, -27, 29, -31, 33, -35, 37, -39, 41, -43, 45, -47, 49, -51, 53, -55, 57, -59, 61, -63, 65, -67, 69, -71, 73, -75, 77, -79, 81, -83, 85, -87, 89, -91, 93, -95, 97, -99, 101, -103, 105, -107, 109, -111, 113, -115
Offset: 0

Views

Author

Jaume Oliver Lafont, Feb 24 2009

Keywords

Comments

Numerators are all 1.
a(n) is also the determinant of the n X n matrix with 1's on the diagonal and 2's elsewhere (cf. A000354). - Jody Nagel (SejeongY(AT)aol.com), May 01 2010

Examples

			G.f.  = 1 - 3*x + 5*x^2 - 7*x^3 + 9*x^4 - 11*x^5 + 13*x^6 - 15*x^7 + 17*x^8 + ...
		

Crossrefs

Programs

  • Magma
    [(2*n + 1) * (-1)^n: n in [0..70]]; // Vincenzo Librandi, Dec 23 2018
  • Mathematica
    a[ n_] := (2*n + 1) * (-1)^n; (* Michael Somos, Nov 21 2022 *)
  • PARI
    {a(n) = (2*n + 1) * (-1)^n};
    

Formula

Euler transform of length 2 sequence [-3, 2]. - Michael Somos, Mar 26 2011
a(n) = b(2*n + 1) where b(n) is completely multiplicative with b(2) = 0, b(p) = p if p == 1 (mod 4), b(p) = -p if p == 3 (mod 4). - Michael Somos, Mar 26 2011
With offset 1 this sequence is the exponential reversion of A005264. - Michael Somos, Mar 26 2011
a(-1 - n) = a(n), a(n + 1) + a(n - 1) = -2*a(n) for all n in Z. - Michael Somos, Mar 26 2011
E.g.f.: (1 - 2*x)*exp(-x). - Michael Somos, Mar 26 2011
a(n) = A005408(n)*A033999(n).
G.f.: (1 - x)/(1 + x)^2 = (1 - x)^3 / (1 - x^2)^2.
a(0) = 1, a(1) = -3, a(n) = -2*a(n-1) - a(n-2) for n >= 2.
Sum_{n=0..inf} 1/a(n) = Pi/4.

A001907 Expansion of e.g.f. exp(-x)/(1-4*x).

Original entry on oeis.org

1, 3, 25, 299, 4785, 95699, 2296777, 64309755, 2057912161, 74084837795, 2963393511801, 130389314519243, 6258687096923665, 325451729040030579, 18225296826241712425, 1093517809574502745499, 69985139812768175711937, 4758989507268235948411715
Offset: 0

Views

Author

Keywords

References

  • J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 83.
  • 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 k=4 of A320032.

Programs

  • Magma
    I:=[3,25]; [1] cat [n le 2 select I[n]  else (4*n-1)*Self(n-1)+4*(n-1)*Self(n-2): n in [1..40]]; // Vincenzo Librandi, Aug 08 2015
  • Maple
    f:= gfun:-rectoproc({a(n) = (4*n-1)*a(n-1) + 4*(n-1)*a(n-2), a(0)=1, a(1)=3},a(n), remember):
    map(f, [$0..30]); # Robert Israel, Aug 07 2015
  • Mathematica
    With[{nn=20},CoefficientList[Series[Exp[-x]/(1-4x),{x,0,nn}], x] Range[0,nn]!] (* or *) Table[Sum[(-1)^(n+k) Binomial[n,k]k! 4^k, {k,0,n}], {n,0,20}](* Harvey P. Dale, Oct 25 2011 *)
    Join[{1}, RecurrenceTable[{a[1] == 3, a[2] == 25, a[n] == (4 n - 1) a[n-1] + 4(n - 1) a[n-2]}, a, {n, 20}]] (* Vincenzo Librandi, Aug 08 2015 *)
  • PARI
    a(n)=sum(k=0,n,(-1)^(n+k)*binomial(n,k)*k!*4^k)
    
  • PARI
    x = 'x+O('x^33); Vec(serlaplace(exp(-x)/(1-4*x))) \\ Gheorghe Coserea, Aug 06 2015
    

Formula

a(n) = Sum_{k=0..n} (-1)^(n+k)*C(n,k)*k!*4^k. - Ralf Stephan, May 22 2004
Recurrence: a(n) = (4*n-1)*a(n-1) + 4*(n-1)*a(n-2). - Vaclav Kotesovec, Aug 16 2013
a(n) ~ n! * exp(-1/4)*4^n. - Vaclav Kotesovec, Aug 16 2013
E.g.f. A(x) = exp(-x)/(1-4x) satisfies (1-4x)A' - (3+4x)A = 0. - Gheorghe Coserea, Aug 06 2015
a(n) = exp(-1/4)*4^n*Gamma(n+1,-1/4), where Gamma is the incomplete Gamma function. - Robert Israel, Aug 07 2015
a(0) = 1; a(n) = Sum_{k=1..n} binomial(n,k) * (4*k - 1) * a(n-k). - Ilya Gutkovskiy, Jan 17 2020

Extensions

More terms from Ralf Stephan, May 22 2004
Typo fixed by Charles R Greathouse IV, Oct 28 2009
Name clarified by Ilya Gutkovskiy, Jan 17 2020

A320032 Square array A(n,k), n >= 0, k >= 0, read by antidiagonals, where column k is the expansion of the e.g.f. exp(-x)/(1 - k*x).

Original entry on oeis.org

1, 1, -1, 1, 0, 1, 1, 1, 1, -1, 1, 2, 5, 2, 1, 1, 3, 13, 29, 9, -1, 1, 4, 25, 116, 233, 44, 1, 1, 5, 41, 299, 1393, 2329, 265, -1, 1, 6, 61, 614, 4785, 20894, 27949, 1854, 1, 1, 7, 85, 1097, 12281, 95699, 376093, 391285, 14833, -1, 1, 8, 113, 1784, 26329, 307024, 2296777, 7897952, 6260561, 133496, 1
Offset: 0

Views

Author

Ilya Gutkovskiy, Oct 03 2018

Keywords

Comments

For n > 0 and k > 0, A(n,k) gives the number of derangements of the generalized symmetric group S(k,n), which is the wreath product of Z_k by S_n. - Peter Kagey, Apr 07 2020

Examples

			E.g.f. of column k: A_k(x) = 1 + (k - 1)*x/1! + (2*k^2 - 2*k + 1)*x^2/2! + (6*k^3 - 6*k^2 + 3*k - 1)*x^3/3! + (24*k^4 - 24*k^3 + 12*k^2 - 4*k + 1)*x^4/4! + ...
Square array begins:
   1,   1,     1,      1,      1,       1,  ...
  -1,   0,     1,      2,      3,       4,  ...
   1,   1,     5,     13,     25,      41,  ...
  -1,   2,    29,    116,    299,     614,  ...
   1,   9,   233,   1393,   4785,   12281,  ...
  -1,  44,  2329,  20894,  95699,  307024,  ...
		

Crossrefs

Columns k=0..5 give A033999, A000166, A000354, A000180, A001907, A001908.
Main diagonal gives A319392.
Cf. A320031.

Programs

  • Maple
    A:= proc(n, k) option remember;
         `if`(n=0, 1, k*n*A(n-1, k)+(-1)^n)
        end:
    seq(seq(A(n, d-n), n=0..d), d=0..12);  # Alois P. Heinz, May 07 2020
  • Mathematica
    Table[Function[k, n! SeriesCoefficient[Exp[-x]/(1 - k x), {x, 0, n}]][j - n], {j, 0, 10}, {n, 0, j}] // Flatten
    Table[Function[k, (-1)^n HypergeometricPFQ[{1, -n}, {}, k]][j - n], {j, 0, 10}, {n, 0, j}] // Flatten

Formula

E.g.f. of column k: exp(-x)/(1 - k*x).
A(n,k) = Sum_{j=0..n} (-1)^(n-j)*binomial(n,j)*j!*k^j.
A(n,k) = (-1)^n*2F0(1,-n; ; k).

A374427 Triangle read by rows: T(n, k) = n! * 2^k * hypergeom([-k], [-n], -1/2).

Original entry on oeis.org

1, 1, 1, 2, 3, 5, 6, 10, 17, 29, 24, 42, 74, 131, 233, 120, 216, 390, 706, 1281, 2329, 720, 1320, 2424, 4458, 8210, 15139, 27949, 5040, 9360, 17400, 32376, 60294, 112378, 209617, 391285, 40320, 75600, 141840, 266280, 500184, 940074, 1767770, 3325923, 6260561
Offset: 0

Views

Author

Peter Luschny, Jul 28 2024

Keywords

Examples

			     1
     1      1
     2      3      5
     6     10     17     29
    24     42     74    131    233
   120    216    390    706   1281   2329
   720   1320   2424   4458   8210  15139  27949
  5040   9360  17400  32376  60294 112378 209617 391285
 40320  75600 141840 266280 500184 940074 1767770 3325923 6260561
362880 685440 1295280 2448720 4631160 8762136 16584198 31400626 59475329
		

Crossrefs

Cf. A000354 (main diagonal), A374428, A007680 (col k=0).

Programs

  • Maple
    A374427 := proc(n,k)
        (-1)^k*add((-2)^(k-j)*binomial(k,k-j)*(n-j)!,j=0..k) ;
    end proc:
    seq(seq(A374427(n,k),k=0..n),n=0..12) ; # R. J. Mathar, Aug 30 2024
  • Mathematica
    T[n_, k_] := n! 2^k Hypergeometric1F1[-k, -n, -1/2];
    (* Alternative: )
    T[n_, k_] := (-1)^k*Sum[(-2)^(k - j)*Binomial[k, k - j]*((n - j)!), {j, 0, k}];
    Table[T[n, k], {n, 0, 8}, {k, 0, n}] // Flatten (* Detlef Meya, Aug 12 2024 *)

Formula

T(n, k) = (-1)^k*Sum_{j=0..k} (-2)^(k - j)*binomial(k, k - j)*(n - j)!. - Detlef Meya, Aug 12 2024
Showing 1-10 of 31 results. Next