Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #8 Apr 07 2020 12:19:56
%S 0,1,2,3,4,6,5,7,8,12,10,13,9,14,11,15,16,24,20,25,18,26,21,27,17,28,
%T 22,30,19,29,23,31,32,48,40,49,36,50,41,51,34,52,42,54,37,53,43,55,33,
%U 56,44,60,38,58,46,61,35,57,45,62,39,59,47,63,64,96,80,97
%N Inverse permutation to A333776.
%H Rémy Sigrist, <a href="/A333777/b333777.txt">Table of n, a(n) for n = 0..8192</a>
%H <a href="/index/Bi#binary">Index entries for sequences related to binary expansion of n</a>
%H <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>
%e A333776(90) = 106, hence a(106) = 96.
%o (PARI) a(n, base=2) = { my (d=Vecrev(digits(n, base)), v=0); forstep (k=#d, 1, -1, v += d[k]*base^(k-1); if (d[k], d=Vecrev(d[1..k-1]))); v }
%Y Cf. A333776.
%K nonn,base
%O 0,3
%A _Rémy Sigrist_, Apr 05 2020