OFFSET
1,2
COMMENTS
Glaisher calls this Delta'(n) or Delta'_1(n). - N. J. A. Sloane, Nov 24 2018
Equals row sums of triangle A143119. - Gary W. Adamson, Jul 26 2008
Cayley begins article 386 with "To find the value of A, = 8{q/(1-q)^2 + q^3/(1-q^3)^2 +&c.}," where A is 8 time the g.f. of this sequence. - Michael Somos, Aug 01 2011
a(n) = 2*(a(n-1) - a(n-4) + a(n-9) ... +- a(n-i^2) ...) up to the last positive number n - i^2, and if n is a square, then a(0) should be replaced by n/2 (cf. Halphen). - Michel Marcus, Oct 14 2012
From Omar E. Pol, Nov 26 2019: (Start)
a(n) is also the total number of odd parts in the partitions of n into equal parts.
a(n) = n iff n is a power of 2.
a(n) = n + 1 iff n is an odd prime. (End)
REFERENCES
A. Cayley, An Elementary Treatise on Elliptic Functions, G. Bell and Sons, London, 1895, p. 294, Art. 386.
G. Chrystal, Algebra: An elementary text-book for the higher classes of secondary schools and for colleges, 6th ed, Chelsea Publishing Co., New York 1959 Part II, p. 346 Exercise XXI(18). MR0121327 (22 #12066)
A. P. Prudnikov, Yu. A. Brychkov and O.I. Marichev, "Integrals and Series", Volume 1: "Elementary Functions", Chapter 4: "Finite Sums", New York, Gordon and Breach Science Publishers, 1986-1992, Eqs. (5.1.29.3), (5.1.29.9).
N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
T. D. Noe, Table of n, a(n) for n = 1..10000
H. H. Chan and C. Krattenthaler, Recent progress in the study of representations of integers as sums of squares, arXiv:math/0407061 [math.NT], 2004.
J. W. L. Glaisher, On the representations of a number as the sum of two, four, six, eight, ten, and twelve squares, Quart. J. Math. 38 (1907), 1-62 (see p. 4 and p. 8).
G.-H. Halphen, Sur les sommes des diviseurs des nombres entiers et les décompositions en deux carrés, Bull. math. Soc. France, 6 (1877-1878), 119-120.
P. A. MacMahon, Divisors of numbers and their continuations in the theory of partitions, Proc. London Math. Soc., 19 (1921), 75-113.
FORMULA
Expansion of K(k^2) * (K(k^2) - E(k^2)) / (2 * Pi^2) in powers of q where q is Jacobi's nome and K(), E() are complete elliptic integrals. - Michael Somos, Aug 01 2011
Multiplicative with a(p^e) = p^e if p = 2; (p^(e+1)-1)/(p-1) if p > 2. - David W. Wilson, Aug 01 2001
a(n) = sigma(n) - sigma(n/2) for even n and = sigma(n) otherwise where sigma(n) is the sum of divisors of n (A000203). - Valery A. Liskovets, Apr 07 2002
G.f.: A(x) satisfies 0 = f(A(x), A(x^2), A(x^3), A(x^6)) where f(u1, u2, u3, u6) = 2*u1*u6 - u1*u3 - 10*u2*u6 + u2^2 + 2*u2*u3 + 9*u6^2. - Michael Somos, Apr 10 2005
G.f.: A(x) satisfies 0 = f(A(x), A(x^2), A(x^3), A(x^6)) where f(u1, u2, u3, u6) = (u2 - 3*u6)^2 - (u1 - 2*u2) * (u3 - 2*u6). - Michael Somos, Sep 06 2005
G.f.: Sum_{n>=1} n*x^n/(1-x^(2*n)). - Vladeta Jovovic, Oct 16 2002
G.f.: Sum_{k>0} x^(2*k - 1) / (1 - x^(2*k - 1))^2. - Michael Somos, Aug 17 2005
G.f.: (1/8) * theta_4''(0) / theta_4(0) = (Sum_{k>0} -(-1)^k * k^2 q^(k^2)) / (Sum_{k in Z} (-1)^k * q^(k^2)) where theta_4(u) is one of Jacobi's theta functions.
G.f.: A(q) = Z'(0) * K^2 / (2 * Pi^2) = (K - E) * K /(2 * Pi^2) where Z(u) is the Jacobi Zeta function and K, E are complete elliptic integrals. - Michael Somos, Sep 06 2005
Dirichlet g.f.: zeta(s) * zeta(s-1) * (1 - 1/2^s). - Michael Somos, Apr 05 2003
Moebius transform is A026741.
a(n) = n * Sum_{c|n} 1/c, where c are odd numbers (A005408) dividing n. a(n) = A069359(n) + n. a(n) = A000035(n) (*) A000027(n), where operation (*) denotes Dirichlet convolution, that is, convolution of type: a(n) = Sum_{d|n} b(d) * c(n/d) = Sum_{d|n} A000035(d) * A000027(n/d). -Jaroslav Krizek, Nov 07 2013
L.g.f.: Sum_{ k>0 } atanh(x^k) = Sum_{ n>0 } (a(n)/n)*x^n. - Benedict W. J. Irwin, Jul 05 2016
Sum_{k=1..n} a(k) ~ Pi^2 * n^2 /16. - Vaclav Kotesovec, Feb 01 2019
From Peter Bala, Jan 06 2021: (Start)
G.f.: A(x) = (1/2)*Sum_{n = -oo..oo} x^(2*n+1)/(1 - x^(2*n+1))^2.
A(x) = Sum_{n = -oo..oo} x^(4*n+1)/(1 - x^(4*n+1))^2.
a(2*n) = 2*a(n); a(2*n+1) = A008438(n). (End)
EXAMPLE
G.f. = q + 2*q^2 + 4*q^3 + 4*q^4 + 6*q^5 + 8*q^6 + 8*q^7 + 8*q^8 + 13*q^9 + ...
The divisors of 6 are 1, 2, 3, and 6. Only 6/2 and 6/6 are odd. Hence, a(6) = 2 + 6 = 8.
As 120 = 15 * 2^3 where 15 is odd and 2^3 is the largest power of 2 dividing 120, a(120) = sigma(15) * 2^3 = 24 * 8 = 192. - David A. Corneth, Aug 12 2019
For n = 6 the partitions of 6 into equal parts are [6], [3,3], [2,2,2], [1,1,1,1,1,1]. There are 8 odd parts, so a(6) = 8. - Omar E. Pol, Nov 26 2019
MAPLE
a:= proc(n) local e;
e:= 2^padic:-ordp(n, 2);
e*numtheory:-sigma(n/e)
end proc:
map(a, [$1..100]); # Robert Israel, Jul 05 2016
MATHEMATICA
a[n_]:=Total[Cases[Divisors[n], d_ /; OddQ[n/d]]]; Table[a[n], {n, 1, 71}] (* Jean-François Alcover, Mar 18 2011 *)
a[ n_] := If[ n < 1, 0, DivisorSum[n, # / GCD[#, 2] &]] (* Michael Somos, Aug 01 2011 *)
a[ n_] := With[{m = InverseEllipticNomeQ @ q}, SeriesCoefficient[ (1/8) EllipticK[ m] ( EllipticK[ m] - EllipticE[ m] ) / (Pi/2 )^2, {q, 0, n}]] (* Michael Somos, Aug 01 2011 *)
Table[Total[Select[Divisors[n], OddQ[n/#]&]], {n, 80}] (* Harvey P. Dale, Jun 05 2015 *)
a[ n_] := SeriesCoefficient[ With[ {m = InverseEllipticNomeQ[q]}, (1/2) (EllipticK[ m] / Pi)^2 (D[ JacobiZeta[ JacobiAmplitude[x, m], m], x] /. x -> 0)], {q, 0, n}]; (* Michael Somos, Mar 17 2017 *)
f[2, e_] := 2^e; f[p_, e_] := (p^(e+1)-1)/(p-1); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Sep 21 2020 *)
PROG
(PARI) {a(n) = if( n<1, 0, direuler( p=2, n, (1 - (p<3) * X) / ((1 - X) * (1 - p*X))) [n])}; /* Michael Somos, Apr 05 2003 */
(PARI) {a(n) = if( n<1, 0, sumdiv( n, d, d / gcd(d, 2)))}; /* Michael Somos, Apr 05 2003 */
(PARI) a(n) = my(v = valuation(n, 2)); sigma(n>>v)<<v \\ David A. Corneth, Aug 12 2019
(Haskell)
a002131 n = sum [d | d <- [1..n], mod n d == 0, odd $ div n d]
-- Reinhard Zumkeller, Aug 14 2011
(MAGMA) [&+[d:d in Divisors(m)|IsOdd(Floor(m/d))] :m in [1..75]]; // Marius A. Burtea, Aug 12 2019
CROSSREFS
KEYWORD
nonn,nice,easy,mult
AUTHOR
STATUS
editing