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 A366388 #21 Oct 23 2023 15:07:39 %S A366388 0,0,1,0,2,1,1,0,2,2,3,1,2,1,3,0,2,2,1,2,2,3,3,1,4,2,3,1,3,3,4,0,4,2, %T A366388 3,2,2,1,3,2,3,2,2,3,4,3,4,1,2,4,3,2,1,3,5,1,2,3,3,3,3,4,3,0,4,4,2,2, %U A366388 4,3,3,2,3,2,5,1,4,3,4,2,4,3,4,2,4,2,4,3,2,4,3,3,5,4,3,1,5,2,5,4,3,3,4,2,4 %N A366388 The number of edges minus the number of leafs in the rooted tree with Matula-Goebel number n. %C A366388 Number of iterations of A366385 needed to reach the nearest power of 2. %H A366388 Antti Karttunen, <a href="/A366388/b366388.txt">Table of n, a(n) for n = 1..65537</a> %H A366388 <a href="/index/Mat#matula">Index entries for sequences related to Matula-Goebel numbers</a> %H A366388 <a href="/index/Pri#prime_indices">Index entries for sequences related to prime indices in the factorization of n</a> %F A366388 Totally additive with a(2) = 0, and for n > 1, a(prime(n)) = 1 + a(n). %F A366388 a(n) = A196050(n) - A109129(n). %F A366388 a(2n) = a(A000265(n)) = a(n). %e A366388 See illustrations in A061773. %t A366388 Array[-1 + Length@ NestWhileList[PrimePi[#2]*#1/#2 & @@ {#, FactorInteger[#][[-1, 1]]} &, #, ! IntegerQ@ Log2[#] &] &, 105] (* _Michael De Vlieger_, Oct 23 2023 *) %o A366388 (PARI) A366388(n) = if(n<=2, 0, if(isprime(n), 1+A366388(primepi(n)), my(f=factor(n)); (apply(A366388, f[, 1])~ * f[, 2]))); %o A366388 (PARI) %o A366388 A006530(n) = if(1==n, n, my(f=factor(n)); f[#f~, 1]); %o A366388 A366385(n) = { my(gpf=A006530(n)); primepi(gpf)*(n/gpf); }; %o A366388 A366388(n) = if(n && !bitand(n,n-1),0,1+A366388(A366385(n))); %Y A366388 Cf. A000720, A006530, A052126, A061395, A061773, A366385. %Y A366388 Cf. A109129 (gives the exponent of the nearest power of 2 reached), A196050 (distance to the farthest power of 2, which is 1). %Y A366388 Cf. also A329697, A331410. %K A366388 nonn %O A366388 1,5 %A A366388 _Antti Karttunen_, Oct 23 2023