I was looking at the digit sum definition, but I also saw a simpler version that can be used for binary numbers. I'm trying to figure out and understand how the generic formula for any base can be simplified into this version that works for base 2 (A000120). Why are they compatible?
Digit Sum Definition for base b:
$$F_b(n)=\sum_{i=0}^{\lfloor\log_b{n}\rfloor}\frac{n \bmod{b^{i+1}} - n \bmod b^i}{b^i}$$
Digit Sum Definition for base 2:
$$F_2(n)=n - \sum_{i=1}^{\lfloor\log_2{n}\rfloor}\bigg\lfloor\frac{n}{2^i}\bigg\rfloor$$