A064894 Binary dilution of n. GCD of exponents in binary expansion of n.
0, 0, 1, 1, 2, 2, 1, 1, 3, 3, 1, 1, 1, 1, 1, 1, 4, 4, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 5, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 6, 6, 1, 1, 2, 2, 1, 1, 3, 3, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 0
Examples
577 = 2^0 + 2^6 + 2^9, GCD(0,6,9) = 3 = a(577).
Links
- Peter Kagey, Table of n, a(n) for n = 0..10000
Programs
-
Mathematica
A064894[n_] := Apply[GCD, Flatten[Position[Reverse[IntegerDigits[n, 2]], 1]] - 1]; Array[A064894, 100, 0] (* Paolo Xausa, Feb 13 2024 *)
-
PARI
a(n) = if (n==0, 0, my(ve = select(x->x==1, Vecrev(binary(n)), 1)); gcd(vector(#ve, k, ve[k]-1))); \\ Michel Marcus, Apr 12 2016
Comments