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 A365804 #8 Sep 19 2023 15:32:42 %S A365804 2,0,0,4,0,12,0,8,9,28,0,12,0,20,42,16,0,18,0,12,30,76,0,24,49,52,27, %T A365804 68,0,-24,0,32,114,100,70,36,0,44,78,40,0,72,0,-20,63,92,0,48,25,-86, %U A365804 150,52,0,54,266,24,66,220,0,84,0,148,45,192,182,-144,0,84,138,280,0,72,0,124,-45,188,190,0,0,80,81 %N A365804 Sum of bijective base-3 reverse of n (A263273) and its Dirichlet inverse. %H A365804 Antti Karttunen, <a href="/A365804/b365804.txt">Table of n, a(n) for n = 1..19683</a> %F A365804 a(n) = A263273(n) + A365803(n). %F A365804 a(1) = 2, and for n > 1, a(n) = -Sum_{d|n, 1<d<n} A263273(d) * A365803(n/d). %o A365804 (PARI) %o A365804 A030102(n) = { my(r=[n%3]); while(0<n\=3, r=concat(n%3, r)); subst(Polrev(r),x,3); }; %o A365804 A263273 = n -> if(!n,n,A030102(n/(3^valuation(n,3))) * (3^valuation(n, 3))); %o A365804 memoA365803 = Map(); %o A365804 A365803(n) = if(1==n,1,my(v); if(mapisdefined(memoA365803,n,&v), v, v = -sumdiv(n,d,if(d<n,A263273(n/d)*A365803(d),0)); mapput(memoA365803,n,v); (v))); %o A365804 A365804(n) = (A263273(n)+A365803(n)); %Y A365804 Cf. A263273, A323239, A365803. %Y A365804 Cf. also A365712. %K A365804 sign %O A365804 1,1 %A A365804 _Antti Karttunen_, Sep 19 2023