This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A284059 #19 Jan 27 2024 07:11:45 %S A284059 1,1,2,0,0,2,2,0,2,0,2,0,0,2,0,0,0,2,2,0,4,2,2,0,0,0,2,0,0,0,2,0,4,0, %T A284059 0,0,0,2,0,0,0,4,2,0,0,2,2,0,2,0,0,0,0,2,0,0,4,0,2,0,0,2,4,0,0,4,2,0, %U A284059 4,0,2,0,0,0,0,0,4,0,2,0,2,0,2,0,0,2,0 %N A284059 The absolute values of A275966. %C A284059 This is multiplicative function with a(p^n) = |Re(I^(p^n+1) - I^(p^(n-1)+1))|. %H A284059 Charles R Greathouse IV, <a href="/A284059/b284059.txt">Table of n, a(n) for n = 1..10000</a> %F A284059 a(n) = |Re(I*Sum_{d|n}(mobius(d)*I^(n/d)))|. %F A284059 Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = 3/Pi = 0.954929... (A089491). - _Amiram Eldar_, Jan 27 2024 %e A284059 a(9) = |Re(I*(mobius(1)*I^9 + mobius(3)*I^3 + mobius(9)*I))| = |Re((I^10 - I^4))| = |-2| = 2. %p A284059 a(n):=abs(Re(I*add(numtheory:-mobius(d)*I^(n/d), d = numtheory:-divisors(n)))). %t A284059 Table[Abs@ Re[I* Sum[MoebiusMu[d] * I^(n/d), {d, Divisors[n]}]], {n, 87}] (* _Indranil Ghosh_, Mar 19 2017 *) %t A284059 f[p_, e_] := If[Mod[p, 4] == 1, 0, 2]; f[2, e_] := If[e == 1, 1, 0]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* _Amiram Eldar_, Jan 27 2024 *) %o A284059 (PARI) a(n)=my(f=factor(n)); prod(i=1,#f~, if(f[i,1]==2, if(f[i,2]==1,1,0), if(f[i,1]%4==3, 2, 0))) \\ _Charles R Greathouse IV_, Mar 22 2017 %Y A284059 Cf. A089491, A275966. %K A284059 nonn,mult %O A284059 1,3 %A A284059 _Gevorg Hmayakyan_, Mar 19 2017