A329801 Expansion of Sum_{k>=1} x^(k*(k + 1)/2) / (1 + x^(k*(k + 1)/2)).
1, -1, 2, -1, 1, -1, 1, -1, 2, 0, 1, -3, 1, -1, 3, -1, 1, -1, 1, -2, 3, -1, 1, -3, 1, -1, 2, 0, 1, -1, 1, -1, 2, -1, 1, -2, 1, -1, 2, -2, 1, -2, 1, -1, 4, -1, 1, -3, 1, 0, 2, -1, 1, -1, 2, -2, 2, -1, 1, -5, 1, -1, 3, -1, 1, 0, 1, -1, 2, 0, 1, -4, 1, -1, 3, -1, 1, 0, 1, -2, 2, -1, 1, -3, 1
Offset: 1
Keywords
Links
- Antti Karttunen, Table of n, a(n) for n = 1..20000
Programs
-
Mathematica
nmax = 85; CoefficientList[Series[Sum[x^(k (k + 1)/2)/(1 + x^(k (k + 1)/2)), {k, 1, nmax}], {x, 0, nmax}], x] // Rest Table[Sum[(-1)^(n/d + 1) Boole[IntegerQ[Sqrt[8 d + 1]]], {d, Divisors[n]}], {n, 1, 85}]
-
PARI
A329801(n) = sumdiv(n,d,((-1)^(1+(n/d))) * ispolygonal(d,3)); \\ Antti Karttunen, Jan 15 2025
Formula
G.f.: Sum_{k>=1} (-1)^(k + 1) * theta_2(x^(k/2)) / (2 * x^(k/8)).
a(n) = Sum_{d|n} (-1)^(n/d + 1) * A010054(d).