|
|
A009102
|
|
Expansion of e.g.f. cos(x)/(1+x).
|
|
8
|
|
|
1, -1, 1, -3, 13, -65, 389, -2723, 21785, -196065, 1960649, -21567139, 258805669, -3364473697, 47102631757, -706539476355, 11304631621681, -192178737568577, 3459217276234385, -65725128248453315, 1314502564969066301
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,4
|
|
COMMENTS
|
The absolute value of a(n) equals the real part of the permanent of the n X n matrix with (1+i)'s along the main diagonal, and 1's everywhere else. - John M. Campbell, Jul 10 2011
|
|
LINKS
|
|
|
FORMULA
|
a(n) = (-1)^n * n! * Sum_{k=0..floor(n/2)} (-1)^k/(2k)!. Unsigned sequence satisfies e.g.f. cos(x)/(1-x). - Ralf Stephan, Apr 16 2004
E.g.f.: cos(x)/(1+x) = U(0)/(1-x^2) where U(k)= 1 - x/(1 - x/(x + (2*k+1)*(2*k+2)/U(k+1)) ; (continued fraction, 3-step). - Sergei N. Gladkovskii, Oct 17 2012
a(n) = Re((-i)^n*hypergeom([1,-n], [], i)).
a(n) = (-1)^n*(cos(1)*(n+2)!+cos(Pi*n/2)*hypergeom([1], [n/2+2,(n+3)/2], -1/4)+sin(Pi*n/2)*(n+2)*hypergeom([1], [n/2+1,(n+3)/2], -1/4))/(n^2+3*n+2).
a(n) = (-1)^n*Re(Gamma(n+1, i)*exp(i)) = (-1)^n*(Gamma(n+1, i)*exp(i)+Gamma(n+1, -i)*exp(-i))/2, where Gamma(a, x) is the upper incomplete Gamma function, i=sqrt(-1).
Gamma(n+1, i) = exp(-i)*((-1)^n*a(n) + A009551(n)*i).
a(0) = 1, a(1) = -1, a(2) = 1, a(n+3) = -(n+3)*a(n+2)-a(n+1)-(n+1)*a(n). (End)
|
|
MAPLE
|
G(x):=cos(x)/(1+x): f[0]:=G(x): for n from 1 to 20 do f[n]:=diff(f[n-1], x) od: x:=0: seq(f[n], n=0..20); # Zerinvary Lajos, Apr 03 2009
g:= gfun:-rectoproc({a(0) = 1, a(1) = -1, a(2) = 1, a(n+3) = -(n+3)*a(n+2)-a(n+1)-(n+1)*a(n)}, a(n), remember):
|
|
MATHEMATICA
|
Table[SeriesCoefficient[Cos[x]/(1+x), {x, 0, n}] n!, {n, 0, 20}]
With[{nn=20}, CoefficientList[Series[Cos[x]/(1+x), {x, 0, nn}], x] Range[0, nn]!] (* Harvey P. Dale, Feb 18 2024 *)
|
|
PROG
|
(PARI) x='x+O('x^30); Vec(serlaplace(cos(x)/(1+x))) \\ G. C. Greubel, Jul 26 2018
(Magma) m:=30; R<x>:=PowerSeriesRing(Rationals(), m); b:=Coefficients(R!(Cos(x)/(1+x))); [Factorial(n-1)*b[n]: n in [1..m]]; // G. C. Greubel, Jul 26 2018
|
|
CROSSREFS
|
|
|
KEYWORD
|
sign,easy
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|