login
This site is supported by donations to The OEIS Foundation.

 

Logo

The OEIS is looking to hire part-time people to help edit core sequences, upload scanned documents, process citations, fix broken links, etc. - Neil Sloane, njasloane@gmail.com

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A000023 Expansion of e.g.f. exp(-2*x)/(1-x).
(Formerly M0373 N0140)
15
1, -1, 2, -2, 8, 8, 112, 656, 5504, 49024, 491264, 5401856, 64826368, 842734592, 11798300672, 176974477312, 2831591702528, 48137058811904, 866467058876416, 16462874118127616, 329257482363600896, 6914407129633521664, 152116956851941670912 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,3

COMMENTS

A010843, A000023, A000166, A000142, A000522, A010842, A053486, A053487 are successive binomial transforms with the e.g.f. exp(k*x)/(1-x) and recurrence b(n) = n*b(n-1)+k^n and are related to incomplete gamma functions at k. In this case k=-2, a(n) = n*a(n-1)+(-2)^n = Gamma(n+1,k)*exp(k) = Sum_{i=0..n} (-1)^(n-i)*binomial(n,i)*i^(n-i)*(i+k)^i. - Vladeta Jovovic, Aug 19 2002

a(n) is the permanent of the n X n matrix with -1's on the diagonal and 1's elsewhere. - Philippe Deléham, Dec 15 2003

REFERENCES

J. Riordan, An Introduction to Combinatorial Analysis, Wiley, 1958, p. 210.

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).

LINKS

Simon Plouffe, Table of n, a(n) for n = 0..250

A. R. Kräuter, Permanenten - Ein kurzer Überblick, Séminaire Lotharingien de Combinatoire, B09b (1983), 34 pp.

A. R. Kräuter, Über die Permanente gewisser zirkulärer Matrizen..., Séminaire Lotharingien de Combinatoire, B11b (1984), 11 pp.

FORMULA

a(n) = Sum_{k=0..n} A008290(n, k)*(-1)^k. - Philippe Deléham, Dec 15 2003

a(n) = Sum_{k=0..n} (-2)^(n-k)*n!/(n-k)! = Sum_{k=0..n} binomial(n, k)*k!*(-2)^(n-k). - Paul Barry, Aug 26 2004

a(n) = exp(-2)*Gamma(n+1,-2)  (incomplete Gamma function). - Mark van Hoeij, Nov 11 2009

a(n) = b such that (-1)^n*Integral_{x=0..2} x^n*exp(x) dx = c + b*exp(2). - Francesco Daddi, Aug 01 2011

G.f.: hypergeom([1,k],[],x/(1+2*x))/(1+2*x) with k=1,2,3 is the generating function for A000023, A087981, and A052124. - Mark van Hoeij, Nov 08 2011

Conjecture: -a(n) +(n-2)*a(n-1) +2*(n-1)*a(n-2) =0. - R. J. Mathar, Nov 14 2011

E.g.f.: 1/E(0) where E(k)=1-x/(1-2/(2-(k+1)/E(k+1))); (continued fraction). - Sergei N. Gladkovskii, Nov 21 2011

G.f.: 1/Q(0), where Q(k)= 1 + 2*x - x*(k+1)/(1 - x*(k+1)/Q(k+1)); (continued fraction). - Sergei N. Gladkovskii, Apr 19 2013

G.f.: 1/Q(0), where Q(k) = 1 - x*(2*k-1) - x^2*(k+1)^2/Q(k+1); (continued fraction). - Sergei N. Gladkovskii, Sep 30 2013

a(n) = Sum_{k=0..n} (-1)^(n+k)*binomial(n, k)*!k, where !k is the subfactorial A000166. a(n) = (-2)^n*hypergeom([1, -n], [], 1/2). - Vladimir Reshetnikov, Oct 18 2015

For n>=3, a(n) = r - (-1)^n mod((-1)^n r, 2^(n - floor((2/n) + log2(n)))) where r = {n! * e^(-2) - (-2)^(n+1)/(n+1)}. - Stan Wagon, May 02 2016

MAPLE

a:=n->n!*sum(((-2)^k/k!), k=0..n): seq(a(n), n=0..27); # Zerinvary Lajos, Jun 22 2007

MATHEMATICA

FoldList[#1*#2 + (-2)^#2 &, 1, Range[22]] (* Robert G. Wilson v, Jul 07 2012 *)

With[{r = Round[n!/E^2 - (-2)^(n + 1)/(n + 1)]}, r - (-1)^n Mod[(-1)^n r, 2^(n + Ceiling[-(2/n) - Log[2, n]])]] (* Stan Wagon May 02 2016 *)

a[n_] := (-1)^n x D[1/x Exp[x], {x, n}] x^n Exp[-x]

Table[a[n] /. x -> 2, {n, 0, 22}](* Gerry Martens , May 05 2016 *)

PROG

(PARI) a(n)=if(n<0, 0, n!*polcoeff(exp(-2*x+x*O(x^n))/(1-x), n))

(Haskell)

a000023 n = foldl g 1 [1..n]

  where g n m = n*m + (-2)^m

-- James Spahlinger, Oct 08 2012

(Sage)

@CachedFunction

def A000023(n):

    if n == 0 : return 1

    return n*A000023(n-1)+(-2)^n

[A000023(i) for i in (0..22)]   # Peter Luschny, Oct 17 2012

(PARI) x='x+O('x^66); Vec( serlaplace( exp(-2*x)/(1-x)) ) \\ Joerg Arndt, Oct 06 2013

CROSSREFS

Cf. A087891, A008290 A089258.

Cf. also A010843, A000166, A000142, A000522, A010842, A053486, A053487.

Sequence in context: A037223 A066988 A100384 * A244676 A010584 A131659

Adjacent sequences:  A000020 A000021 A000022 * A000024 A000025 A000026

KEYWORD

sign,easy

AUTHOR

N. J. A. Sloane

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified May 29 03:40 EDT 2017. Contains 287242 sequences.