cp's OEIS Frontend

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.

A051147 Smallest m such that A051145(m) = 2^n.

This page as a plain text file.
%I A051147 #25 Aug 26 2021 05:54:56
%S A051147 1,2,3,5,9,12,17,29,45,81,105,177,245,323,569,893,1277,2121,3221,4853,
%T A051147 7697,11015,15333,25841,40157,59213,84239,135107,184679,265277,445029,
%U A051147 606509,830411,1394489,1973405,2683997,4176989,6710687,9906153,15114275,22269021
%N A051147 Smallest m such that A051145(m) = 2^n.
%F A051147 A051145(a(n)) = 2^n. - _Reinhard Zumkeller_, Jul 05 2014
%t A051147 Block[{a, b, s}, a[0] = 0; a[1] = 1; a[n_] := a[n] = (b = 0; While[b++; BitOr[b, a[n - 1]] <= BitOr[a[n - 2], a[n - 1]]]; b); s = Array[a, 2^10, 0]; Array[FirstPosition[s, 2^#][[1]] - 1 &, Floor@ Log2@ Max@ s + 1, 0]] (* _Michael De Vlieger_, Aug 25 2021, after _Jean-François Alcover_ at A051145 *)
%o A051147 (Haskell)
%o A051147 import Data.List (elemIndex); import Data.Maybe (fromJust)
%o A051147 a051147 = fromJust . (`elemIndex` a051145_list) . (2 ^)
%o A051147 -- _Reinhard Zumkeller_, Jul 05 2014
%Y A051147 Cf. A000079, A051145, subsequence of A244747.
%K A051147 nonn,easy,nice
%O A051147 0,2
%A A051147 _N. J. A. Sloane_, E. M. Rains
%E A051147 More terms from Larry Reeves (larryr(AT)acm.org), Oct 03 2000
%E A051147 a(21)-a(23) from _Reinhard Zumkeller_, Jul 05 2014
%E A051147 Definition corrected by _Reinhard Zumkeller_, Jul 05 2014
%E A051147 a(24)-a(30) from _Charlie Neder_, Oct 12 2018
%E A051147 More terms from _Sean A. Irvine_, Aug 25 2021