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.
%I A325940 #22 Jun 22 2024 14:12:34 %S A325940 0,1,-2,4,-4,4,-6,11,-10,6,-10,18,-12,8,-20,26,-16,13,-18,28,-28,12, %T A325940 -22,48,-28,14,-36,38,-28,24,-30,57,-44,18,-44,62,-36,20,-52,74,-40, %U A325940 32,-42,58,-72,24,-46,110,-54,31,-68,68,-52,40,-68,100,-76,30,-58,116 %N A325940 Expansion of Sum_{k>=1} x^(2*k) / (1 + x^k)^2. %H A325940 Seiichi Manyama, <a href="/A325940/b325940.txt">Table of n, a(n) for n = 1..10000</a> %H A325940 Joerg Arndt, <a href="http://arxiv.org/abs/1202.6525">On computing the generalized Lambert series</a>, arXiv:1202.6525v3 [math.CA], (2012). %F A325940 G.f.: Sum_{k>=2} (-1)^k * (k - 1) * x^k / (1 - x^k). %F A325940 a(n) = Sum_{d|n} (-1)^d * (d - 1). %F A325940 a(n) = A048272(n) - A002129(n). %F A325940 Faster converging series: A(q) = Sum_{n >= 1} (-1)^n*q^(n^2)*((n-1)*q^(3*n) + n*q^(2*n) + (n-2)*q^n + n-1)/((1 + q^n)*(1 - q^(2*n))) - apply the operator t*d/dt to equation 1 in Arndt, then set t = -q and x = q. - _Peter Bala_, Jan 22 2021 %F A325940 a(n) = A128315(n, 2). - _G. C. Greubel_, Jun 22 2024 %t A325940 nmax = 60; CoefficientList[Series[Sum[x^(2 k)/(1 + x^k)^2, {k, 1, nmax}], {x, 0, nmax}], x] // Rest %t A325940 Table[Sum[(-1)^d (d - 1), {d, Divisors[n]}], {n, 1, 60}] %o A325940 (PARI) {a(n) = sumdiv(n, d, (-1)^d*(d-1))} \\ _Seiichi Manyama_, Sep 14 2019 %o A325940 (Magma) %o A325940 A325940:= func< n | (&+[0^(n mod j)*(-1)^j*(j-1): j in [1..n]]) >; %o A325940 [A325940(n): n in [1..70]]; // _G. C. Greubel_, Jun 22 2024 %o A325940 (SageMath) %o A325940 def A325940(n): return sum(0^(n%j)*(-1)^j*(j-1) for j in range(1, n+1)) %o A325940 [A325940(n) for n in range(1,71)] # _G. C. Greubel_, Jun 22 2024 %Y A325940 Cf. A002129, A048272, A065608, A128315, A363615, A363616. %K A325940 sign,look %O A325940 1,3 %A A325940 _Ilya Gutkovskiy_, Sep 09 2019