OFFSET
1,3
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
Mihai Caragiu and Kaleb Swieringa, On the alternating sum-of-divisors, JP Journal of Algebra, Number Theory and Applications, 63(2) (2024), 97-110 (page 3, expression 4).
FORMULA
EXAMPLE
Divisors of 20 are {1,2,4,5,10,20}, therefore a(20) = 1 - 2 + 4 - 5 + 10 - 20 = -12.
MATHEMATICA
Table[Total[Times@@@Partition[Riffle[Divisors[n], {1, -1}, {2, -1, 2}], 2]], {n, 50}] (* Harvey P. Dale, Nov 05 2014 *)
CROSSREFS
KEYWORD
sign
AUTHOR
Reinhard Zumkeller, May 18 2002
STATUS
approved
