OFFSET
0,4
COMMENTS
For n>0, a(n) is the denominator of Sum_{odd d|n} 1/d. See Sumit Kumar Jha link. - Michel Marcus, Jul 21 2020
LINKS
Sumit Kumar Jha, An identity for the sum of inverses of odd divisors of n in terms of the number of representations of n as a sum of r squares, arXiv:2007.04243 [math.GM], 2020.
EXAMPLE
2*q-2*q^2+8/3*q^3-2*q^4+12/5*q^5-8/3*q^6+16/7*q^7-2*q^8+26/9*q^9-...
MAPLE
A098985_list := proc(n::integer)
local q, m, nsq ;
nsq := floor(sqrt(n)) ;
add(q^(m^2), m=-nsq-1..nsq+1) ;
log(%) ;
taylor(%, q=0, n+1) ;
[seq( denom(coeftayl(%, q=0, i)) , i=1..n) ] ;
end proc:
A098985_list(200) ; # R. J. Mathar, Jul 16 2020
A336114 := proc(n::integer)
local a ;
for d in numtheory[divisors](n) do
if type(d, 'odd') then
a := a+1/d ;
end if;
end do;
denom(a) ;
end proc:
seq(A336114(n), n=1..70) ; # R. J. Mathar, Jul 16 2020
MATHEMATICA
Denominator[CoefficientList[Series[Log[Sum[q^m^2, {m, -Infinity, Infinity}]], {q, 0, 79}], q]] (* L. Edson Jeffery, Jul 14 2014 *)
a[n_] := Denominator @ DivisorSum[n, 1/# &, OddQ[#] &]; Array[a, 100] (* Amiram Eldar, Jul 09 2020 *)
PROG
(PARI) lista(nn) = {my(k = sqrtint(nn), s = sum(m=-k-1, k+1, x^(m^2)) + O(x^nn)); apply(x->denominator(x), Vec(log(s))); } \\ Michel Marcus, Jul 17 2020
(PARI) a(n) = if (n==0, 1, denominator(sumdiv(n, d, if (d%2, 1/d)))); \\ Michel Marcus, Jul 21 2020; corrected Jun 13 2022
CROSSREFS
KEYWORD
nonn,frac
AUTHOR
N. J. A. Sloane, Oct 24 2004
STATUS
approved