A134599 Sum of digital sums (base 3) of the prime factors of n.
0, 2, 1, 4, 3, 3, 3, 6, 2, 5, 3, 5, 3, 5, 4, 8, 5, 4, 3, 7, 4, 5, 5, 7, 6, 5, 3, 7, 3, 6, 3, 10, 4, 7, 6, 6, 3, 5, 4, 9, 5, 6, 5, 7, 5, 7, 5, 9, 6, 8, 6, 7, 7, 5, 6, 9, 4, 5, 5, 8, 5, 5, 5, 12, 6, 6, 5, 9, 6, 8, 7, 8, 5, 5, 7, 7, 6, 6, 7, 11, 4, 7, 3, 8, 8, 7, 4, 9, 5, 7, 6, 9, 4, 7, 6, 11, 5, 8, 5, 10, 5, 8, 5, 9, 7
Offset: 1
Examples
a(6) = 3, since 6 = 2*3 and so a(6) = ds_3(2) + ds_3(3) = 2 + 1.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
f[p_, e_] := e * DigitSum[p, 3]; a[1] = 0; a[n_] := Plus @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Jul 30 2025 *)
-
PARI
a(n) = {my(f = factor(n)); sum(i = 1, #f~, f[i, 2] * sumdigits(f[i, 1], 3));} \\ Amiram Eldar, Jul 30 2025
Formula
If p_1*p_2*p_3* ... *p_m = n is the unique prime factorization of n, then a(n) = Sum_{k=1..m} ds_3(p_k), where ds_3 is the digital sum base 3.
Totally additive with a(p) = A053735(p). - Amiram Eldar, Jul 30 2025
Extensions
a(1) = 0 prepended by Amiram Eldar, Jul 30 2025