OFFSET
1,2
COMMENTS
abs(a(n)) is also the number of distinct routes starting from a point A and ending at a point B, without traversing any edge more than once, when there are n bi-directional edges connecting A and B. E.g., if there are 3 edges p, q and r from A to B, then the 9 routes starting from A and ending at B are p, q, r, pqr, prq, rpq, rqp, qpr and qrp. - Nikita Kiran, Sep 02 2022
Reducing the sequence modulo the odd integer 2*k + 1 results in a purely periodic sequence with period dividing 4*k + 2, For example, reduced modulo 5 the sequence becomes the purely periodic sequence [1, 3, 4, 2, 0, 4, 2, 1, 3, 0, 1, 3, 4, 2, 0, 4, 2, 1, 3, 0, ...] with period 10. - Peter Bala, Sep 12 2022
REFERENCES
J. M. Gandhi, On logarithmic numbers, Math. Student, 31 (1963), 73-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).
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..200
J. M. Gandhi, On logarithmic numbers, Math. Student, 31 (1963), 73-83. [Annotated scanned copy]
Simon Plouffe, Simple inverter lookup on 1.8134302039235
Simon Plouffe, Smart inverter lookup on 1.8134302039235
FORMULA
E.g.f.: x/exp(x)/(1-x^2). - Vladeta Jovovic, Feb 09 2003
a(n) = n*((n-1)*a(n-2)-(-1)^n). - Matthew Vandermast, Jun 30 2003
From Gerald McGarvey, Jun 06 2004: (Start)
For n odd, a(n) = n! * Sum_{i=0..n-1, i even} 1/i!.
For n even, a(n) = n! * Sum_{i=1..n-1, i odd} 1/i!.
For n odd, lim_{n->infinity} a(n)/n! = cosh(1).
For n even, lim_{n->infinity} a(n)/n! = sinh(1).
For n even, lim_{n->infinity} n*a(n)*a(n-1)/n!^2 = cosh(1)*sinh(1).
For signed values, Sum_{n>=1} a(n)/n!^2 = 0.
For unsigned values, Sum_{n>=1} a(n)/n!^2 = cosh(1)*sinh(1). (End)
a(n) = (-1)^(n-1)*Sum_{k=0..n} C(n, k)*k!*(1-(-1)^k)/2. - Paul Barry, Sep 14 2004
a(n) = (-1)^(n+1)*n*A087208(n-1). - R. J. Mathar, Jul 24 2015
a(n) = (exp(-1)*Gamma(1+n,-1) - (-1)^n*exp(1)*Gamma(1+n,1))/2 = (A000166(n) - (-1)^n*A000522(n))/2. - Peter Luschny, Dec 18 2017
MAPLE
a:= proc(n) a(n):= n*`if`(n<2, n, (n-1)*a(n-2)-(-1)^n) end:
seq(a(n), n=1..25); # Alois P. Heinz, Jul 10 2013
MATHEMATICA
egf = x/Exp[x]/(1-x^2); a[n_] := SeriesCoefficient[egf, {x, 0, n}]*n!; Table[a[n], {n, 1, 22}] (* Jean-François Alcover, Jan 17 2014, after Vladeta Jovovic *)
a[n_] := (Exp[-1] Gamma[1 + n, -1] - (-1)^n Exp[1] Gamma[1 + n, 1])/2;
Table[a[n], {n, 1, 22}] (* Peter Luschny, Dec 18 2017 *)
PROG
(PARI) a(n) = (-1)^(n+1)*sum(k=0, n, binomial(n, k)*k!*(1-(-1)^k)/2); \\ Michel Marcus, Jan 13 2022
CROSSREFS
KEYWORD
sign
AUTHOR
EXTENSIONS
More terms from Jeffrey Shallit
More terms from Vladeta Jovovic, Feb 09 2003
STATUS
approved