OFFSET
0,3
COMMENTS
The Clausen numbers C(n) are T(n, 1) in A160014.
LINKS
Peter Luschny, Stirling-Frobenius numbers
Peter Luschny, Generalized Bernoulli numbers.
FORMULA
EXAMPLE
The numerators of 1/1, 0/2, -2/6, 0/2, 14/30, 0/2, -62/42, 0/2, 254/30, 0/2, -5110/66, 0/2, 2828954/2730, ... (the denominators are the Clausen numbers).
MAPLE
MATHEMATICA
B[n_, m_] := Sum[((-1)^(n - v)/(j + 1))*Binomial[n, k]*Binomial[j, v]*If[k == 0, 1, (m*v)^k], {k, 0, n}, {j, 0, k}, {v, 0, j}];
c[n_] := Denominator[Sum[Boole[PrimeQ[d + 1]]/(d + 1), {d, Divisors[n]}]];
a[n_] := B[n, 2]*c[n];
Table[a[n], {n, 0, 33}] (* Jean-François Alcover, Aug 02 2019, from Maple *)
PROG
@CachedFunction
def EulerianNumber(n, k, m) : # The Eulerian numbers
if n == 0: return 1 if k == 0 else 0
return (m*(n-k)+m-1)*EulerianNumber(n-1, k-1, m)+(m*k+1)*EulerianNumber(n-1, k, m)
@CachedFunction
def B(n, m): # The generalized Bernoulli numbers
return add(add(EulerianNumber(n, j, m)*binomial(j, n - k)
for j in (0..n))*(-1)^k/(k+1) for k in (0..n))
def A225480(n):
if n == 0: return 1
C = mul(filter(lambda s: is_prime(s) , map(lambda i: i+1, divisors(n))))
return C*B(n, 2)
[A225480(n) for n in (0..33)]
CROSSREFS
KEYWORD
sign,frac
AUTHOR
Peter Luschny, May 30 2013
STATUS
approved