login
A129826
Transformed Bernoulli twin numbers.
10
1, -1, -2, -4, -4, 24, 120, -960, -12096, 120960, 3024000, -36288000, -1576143360, 22066007040, 1525620096000, -24409921536000, -2522591034163200, 45406638614937600, 6686974460694528000, -133739489213890560000, -27033456071346536448000, 594736033569623801856000
OFFSET
0,3
LINKS
FORMULA
We define Bernoulli twin numbers C(n) via Bernoulli numbers B(n) = A027641(n)/A027642(n) as C(0)=1, 2C(1)=-1, 3C(2)=-1, C(2n-1)= -B(2n-2) and C(2n)=B(2n), n>1. The sequence is defined as a(n)=(n+1)!*C(n).
a(n) = (n+1)!*C(n), where C(n) = A051718(n)/A051717(n).
E.g.f.: Sum(n>=0) C(n) x^n/n! = 1 + x - x^2/2 + Sum_{n>=1} (B(n) - B(n-1))*x^n/n! = x - x^2/2 + x/(e^x-1) - Integral_{y=0..x} ((y dy)/(e^y-1)).
MATHEMATICA
c[n_?EvenQ] := BernoulliB[n]; c[n_?OddQ] := -BernoulliB[n-1]; c[1]=-1/2; c[2]=-1/3; a[n_] := (n+1)!*c[n]; Table[a[n], {n, 0, 21}] (* Jean-François Alcover, Aug 08 2012 *)
PROG
(Magma)
f:= func< n | n le 2 select (-1)^Floor((n+1)/2)/(n+1) else (-1)^n*BernoulliNumber(Floor(n - (1-(-1)^n)/2)) >;
A129826:= func< n | Factorial(n+1)*f(n) >;
[A129826(n): n in [0..30]]; // G. C. Greubel, Feb 01 2024
(SageMath)
def f(n): return (-1)^((n+1)//2)/(n+1) if n<3 else (-1)^n*bernoulli(n-(n%2))
def A129826(n): return factorial(n+1)*f(n)
[A129826(n) for n in range(31)] # G. C. Greubel, Feb 01 2024
CROSSREFS
KEYWORD
sign
AUTHOR
Paul Curtz, May 20 2007
EXTENSIONS
Edited and extended by R. J. Mathar, Aug 06 2008
STATUS
approved