OFFSET
1,3
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
László Tóth, Alternating Sums Concerning Multiplicative Arithmetic Functions, Journal of Integer Sequences, Vol. 20 (2017), Article 17.2.1.
FORMULA
MATHEMATICA
uphi[n_] := Times @@ (-1 + Power @@@ FactorInteger[n]); uphi[1] = 1; Accumulate[Array[(-1)^(# + 1) * uphi[#] &, 100]]
PROG
(PARI) uphi(n) = {my(f = factor(n)); prod(i = 1, #f~, f[i, 1]^f[i, 2] - 1); }
lista(kmax) = {my(s = 0); for(k = 1, kmax, s += (-1)^(k+1) * uphi(k); print1(s, ", "))};
CROSSREFS
KEYWORD
sign,easy
AUTHOR
Amiram Eldar, Mar 05 2024
STATUS
approved