%I #10 Jan 02 2023 16:49:00
%S 1,-1,-1,-2,-1,-1,-1,-4,0,-1,-1,-4,-1,-1,1,-8,-1,-2,-1,-4,1,-1,-1,-12,
%T 0,-1,0,-4,-1,-3,-1,-16,1,-1,1,-10,-1,-1,1,-12,-1,-3,-1,-4,0,-1,-1,
%U -32,0,-2,1,-4,-1,-4,1,-12,1,-1,-1,-16,-1,-1,0,-32,1,-3,-1,-4,1,-3,-1,-36,-1,-1,0,-4,1,-3,-1,-32,0
%N a(1) = 1; a(n) = Sum_{d|n, d < n} (-1)^d * a(d).
%H Antti Karttunen, <a href="/A343370/b343370.txt">Table of n, a(n) for n = 1..16384</a>
%H Antti Karttunen, <a href="/A343370/a343370.txt">Data supplement: n, a(n) computed for n = 1..100000</a>
%F G.f.: x + Sum_{n>=1} (-1)^n * a(n) * x^(2*n) / (1 - x^n).
%p a:= proc(n) option remember; `if`(n<2, 1,
%p add((-1)^d*a(d), d=numtheory[divisors](n) minus {n}))
%p end:
%p seq(a(n), n=1..70); # _Alois P. Heinz_, Apr 12 2021
%t a[1] = 1; a[n_] := a[n] = Sum[If[d < n, (-1)^d a[d], 0], {d, Divisors[n]}]; Table[a[n], {n, 70}]
%o (PARI)
%o memoA343370 = Map();
%o A343370(n) = if(1==n,1,my(v); if(mapisdefined(memoA343370,n,&v), v, v = sumdiv(n,d,if(d<n,((-1)^d)*A343370(d),0)); mapput(memoA343370,n,v); (v))); \\ _Antti Karttunen_, Jan 02 2023
%Y Cf. A008683, A053850 (positions of 0's), A056913 (positions of 1's), A067856, A074206, A307778, A308077, A325144.
%K sign
%O 1,4
%A _Ilya Gutkovskiy_, Apr 12 2021
%E Data section extended up to a(81) by _Antti Karttunen_, Jan 02 2023