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 A344259 #15 May 15 2021 01:43:52 %S A344259 0,1,1,1,2,2,3,3,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,6,6,6,6,7,7,7,7,4,4, %T A344259 4,4,4,4,4,4,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,8,8,8,8, %U A344259 8,8,8,8,9,9,9,9,9,9,9,9,10,10,10,10,10 %N A344259 For any number n with binary expansion (b(1), ..., b(k)), the binary expansion of a(n) is (b(1), ..., b(ceiling(k/2))). %C A344259 Leading zeros are ignored. %H A344259 Rémy Sigrist, <a href="/A344259/b344259.txt">Table of n, a(n) for n = 0..8191</a> %H A344259 <a href="/index/Bi#binary">Index entries for sequences related to binary expansion of n</a> %F A344259 a(A020330(n)) = n. %F A344259 a(A006995(n+1)) = A162751(n). %F A344259 a(n XOR A344220(n)) = a(n) (where XOR denotes the bitwise XOR operator). %e A344259 The first terms, alongside their binary expansion, are: %e A344259 n a(n) bin(n) bin(a(n)) %e A344259 -- ---- ------ --------- %e A344259 0 0 0 0 %e A344259 1 1 1 1 %e A344259 2 1 10 1 %e A344259 3 1 11 1 %e A344259 4 2 100 10 %e A344259 5 2 101 10 %e A344259 6 3 110 11 %e A344259 7 3 111 11 %e A344259 8 2 1000 10 %e A344259 9 2 1001 10 %e A344259 10 2 1010 10 %e A344259 11 2 1011 10 %e A344259 12 3 1100 11 %e A344259 13 3 1101 11 %e A344259 14 3 1110 11 %e A344259 15 3 1111 11 %t A344259 Array[FromDigits[First@Partition[l=IntegerDigits[#,2],Ceiling[Length@l/2]],2]&,100,0] (* _Giorgos Kalogeropoulos_, May 14 2021 *) %o A344259 (PARI) a(n) = n\2^(#binary(n)\2) %o A344259 (Python) %o A344259 def a(n): b = bin(n)[2:]; return int(b[:(len(b)+1)//2], 2) %o A344259 print([a(n) for n in range(85)]) # _Michael S. Branicky_, May 14 2021 %Y A344259 Cf. A006995, A020330, A162751, A344220. %K A344259 nonn,base,easy %O A344259 0,5 %A A344259 _Rémy Sigrist_, May 13 2021