login
Negate primes in factorizations of divisors of n, then sum.
16

%I #69 Sep 24 2023 05:44:46

%S 1,-1,-2,3,-4,2,-6,-5,7,4,-10,-6,-12,6,8,11,-16,-7,-18,-12,12,10,-22,

%T 10,21,12,-20,-18,-28,-8,-30,-21,20,16,24,21,-36,18,24,20,-40,-12,-42,

%U -30,-28,22,-46,-22,43,-21,32,-36,-52,20,40,30,36,28,-58,24,-60,30,-42,43,48,-20,-66,-48,44,-24,-70,-35

%N Negate primes in factorizations of divisors of n, then sum.

%C Analog of sigma function A000203(n) with primes negated.

%C Unsigned sequence |a(n)| (A206369) gives the number of numbers 1 <= k <= n for which GCD(k,n) is a square. |a(n)| = Sum_{d|n} d*(-1)^bigomega(n/d). - _Vladeta Jovovic_, Dec 29 2002

%H T. D. Noe, <a href="/A061020/b061020.txt">Table of n, a(n) for n = 1..10000</a>

%H Dana G. Korssjoen, Biyao Li, Stefan Steinerberger, Raghavendra Tripathi, and Ruimin Zhang, <a href="https://doi.org/10.2140/involve.2022.15.251">Finding structure in sequences of real numbers via graph theory: a problem list</a>, Involve, a Journal of Mathematics, Vol. 15, No. 2 (2022), pp. 251-270; <a href="https://arxiv.org/abs/2012.04625">arXiv preprint</a>, arXiv:2012.04625 [math.CO], 2020-2021.

%H László Tóth, <a href="http://arxiv.org/abs/1111.4842">A survey of the alternating sum-of-divisors function</a>, arXiv:1111.4842 [math.NT], 2011-2014.

%F Replace each divisor d of n by A061019[d] and sum. Replace p^q with (1-(-p)^(q+1))/(1+p) in prime factorization of n.

%F Inverse mobius transform of A061019. In other words a(n) = Sum_{d|n} d*(-1)^bigomega(d), where bigomega(n) = A001222(n).

%F a(n) = Sum_{d|n} d*mu(core(d)) where core(x) = A007913(x) is the smallest number such that x*core(x) is a square. - _Benoit Cloitre_, Apr 07 2002

%F G.f.: A(x) = Sum_{k>=1} lambda(k)*k*x^k/(1 - x^k) where lambda(k) is the Liouville function, A008836. - _Stuart Clary_, Apr 15 2006

%F G.f.: A(x) is x times the logarithmic derivative of A118206(x). - _Stuart Clary_, Apr 15 2006

%F Dirichlet g.f.: zeta(s)*zeta(2 s - 2)/zeta(s - 1). - _Stuart Clary_, Apr 15, 2006

%F a(n) = Sum_{d|n} d*lambda(d), where lambda(n) is A008836(n). - _Enrique Pérez Herrero_, Aug 29 2013

%e a(12) = 1-2-3+4+6-12 = (1-2+4)*(1-3) = -6.

%p with(numtheory):

%p A061020 := proc(n) local d; add(d*(-1)^bigomega(d), d=divisors(n)) end:

%p seq(A061020(n), n=1..72); # _Peter Luschny_, Aug 29 2013

%t nmax = 72; Drop[ CoefficientList[ Series[ Sum[ LiouvilleLambda[k] k x^k/(1 - x^k), {k, 1, nmax} ], {x, 0, nmax} ], x ], 1 ] (* _Stuart Clary_, Apr 15 2006, updated by _Jean-François Alcover_, Dec 04 2017 *)

%t f[p_, e_] := ((-p)^(e+1)-1)/(-p-1); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* _Amiram Eldar_, Sep 24 2023 *)

%o (PARI) for(n=1,100,print1(sumdiv(n,d,(d)*moebius(core(d))),","))

%o (PARI) a(n)=if(n<1,0,direuler(p=2,n,1/(1-X)/(1+p*X))[n]) \\ _Ralf Stephan_

%o (PARI) A061020(n) = {my(f=factorint(n)); prod(k=1, #f[,2], ((-f[k,1])^(f[k,2]+1)-1)/(-f[k,1]-1))} \\ _Andrew Lelechenko_, Apr 22 2014

%o (Haskell)

%o a061020 = sum . map a061019 . a027750_row

%o -- _Reinhard Zumkeller_, Feb 08 2012

%Y Cf. A000203, A061019, A076792, A206369.

%Y Cf. A027750, A007913.

%K easy,sign,mult

%O 1,3

%A _Marc LeBrun_, Apr 13 2001