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 A377369 #23 Jan 01 2025 18:13:33 %S A377369 0,2,2,4,3,4,3,4,4,5,4,6,4,5,5,5,5,6,5,7,5,6,5,6,5,6,4,7,5,7,5,5,6,7, %T A377369 6,8,6,7,6,7,6,7,6,8,7,7,6,7,5,7,7,8,6,6,7,7,7,7,6,9,6,7,7,5,7,8,7,9, %U A377369 7,8,7,8,7,8,7,9,7,8,7,8,5,8,7,9,8,8,7,8,7,9 %N A377369 a(n) = total number of bits in the binary representation of the prime factorization of n (including exponents > 1). %H A377369 Paolo Xausa, <a href="/A377369/b377369.txt">Table of n, a(n) for n = 1..10000</a> %e A377369 a(10) = 5 because 10 = 2*5 = 10_2*101_2 (5 total bits). %e A377369 a(18) = 6 because 18 = 2*3^2 = 10_2*11_2^10_2 (6 total bits). %t A377369 A377369[n_] := Total[BitLength[Select[Flatten[FactorInteger[n]], # > 1 &]]]; %t A377369 Array[A377369, 100] %o A377369 (Python) %o A377369 from sympy import factorint %o A377369 def a(n): return sum(len(bin(p)[2:])+(len(bin(e)[2:]) if e>1 else 0) for p, e in factorint(n).items()) %o A377369 print([a(n) for n in range(1, 91)]) # _Michael S. Branicky_, Dec 27 2024 %o A377369 (PARI) a(n)={my(f=factor(n)); sum(i=1, #f~, 1 + logint(f[i,1],2) + (f[i,2]>1) + logint(f[i,2],2))} \\ _Andrew Howroyd_, Dec 29 2024 %Y A377369 Cf. A050252 (analogous for base 10). %Y A377369 Cf. A070939. %K A377369 nonn,base %O A377369 1,2 %A A377369 _Paolo Xausa_, Dec 27 2024