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.

A009123 Expansion of e.g.f.: cosh(log(1+sin(x))).

Original entry on oeis.org

1, 0, 1, -3, 8, -30, 136, -693, 3968, -25260, 176896, -1351383, 11184128, -99680490, 951878656, -9695756073, 104932671488, -1202439837720, 14544442556416, -185185594118763, 2475749026562048, -34674437196568950
Offset: 0

Views

Author

Keywords

Comments

|a(n)| = number of even alternating permutations on n letters (offset 1). - Vladeta Jovovic, May 20 2007

Crossrefs

Cf. A000111.

Programs

  • Magma
    m:=30; R:=PowerSeriesRing(Rationals(), m); b:=Coefficients(R!(Cosh(Log(1+Sin(x))))); [Factorial(n-1)*b[n]: n in [1..m]]; // G. C. Greubel, Jul 26 2018
  • Mathematica
    CoefficientList[Series[(1 + (1 + Sin[x])^2)/(2*(1 + Sin[x])), {x, 0, 20}], x] * Range[0, 20]! (* Vaclav Kotesovec, Jan 22 2015 *)
  • PARI
    x='x+O('x^30); Vec(serlaplace(cosh(log(1+sin(x))))) \\ G. C. Greubel, Jul 26 2018
    

Formula

a(2*n) = (1/2)*A000182(n+1); a(2*n+1) = A012007(n+1) = A009567(2*n+1) + 1.
G.f.: (1+x/(1+x^2))/2 + 1/2/Q(0) where Q(k) = 1 + (k+1)*x - x^2*(k+1)*(k+2)/2 /Q(k+1) ; (continued fraction). - Sergei N. Gladkovskii, Mar 12 2013
a(n) ~ n! * n * (-1)^n * (2/Pi)^(n+2). - Vaclav Kotesovec, Jan 22 2015

Extensions

Extended with signs by Olivier Gérard, Mar 15 1997