OFFSET
1,3
LINKS
FORMULA
a(1) = 1; for n > 1, a(n) = -Sum_{d|n, d<n} A002487(n/d)*a(d).
MATHEMATICA
s[0] = 0; s[1] = 1;
s[n_] := s[n] = If[EvenQ[n], s[n/2], s[(n-1)/2] + s[(n+1)/2]];
a[n_] := a[n] = If[n == 1, 1, -Sum[s[n/d] a[d], {d, Most@ Divisors[n]}]];
Array[a, 100] (* Jean-François Alcover, Feb 16 2020 *)
PROG
CROSSREFS
KEYWORD
sign
AUTHOR
Antti Karttunen, Aug 09 2018
STATUS
approved