%I #35 Sep 27 2023 16:46:50
%S 2,9,35,135,527,2079,8255,32895,131327,524799,2098175,8390655,
%T 33558527,134225919,536887295,2147516415,8590000127,34359869439,
%U 137439215615,549756338175,2199024304127,8796095119359,35184376283135,140737496743935,562949970198527
%N Numbers having in binary representation a leading 1 followed by n zeros and n-1 ones.
%C Smallest numbers having in binary representation n 0's and n 1's: a(n) = Min{m: A023416(m)=A000120(m)=n}.
%H Vincenzo Librandi, <a href="/A092431/b092431.txt">Table of n, a(n) for n = 1..500</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/Binary.html">Binary</a>
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (7,-14,8).
%F a(n+1) = 2*a(n) + 4^n + 1.
%F a(n) = 2^(2*n-1) + 2^(n-1) - 1.
%F a(n) = A007582(n)-1 = A056326(2n+1) = A005367(n-1)/2 = A063376(n)/2-1 = A032125(n+1)/3-1 = A056309(2n+1)/2 = A028403(n+1)/4-1 = (A001576(n)-3)/2 = (A028400(n+1)-9)/8 = Sum_{k=2..n+1} A049775(k). - _Ralf Stephan_, Mar 24 2004
%F G.f.: x*(-2+5*x) / ( (x-1)*(2*x-1)*(4*x-1) ). - _R. J. Mathar_, Jun 01 2011
%F E.g.f.: exp(x)*(exp(3*x) + exp(x) - 2)/2. - _Stefano Spezia_, Sep 27 2023
%t LinearRecurrence[{7, -14, 8}, {2, 9, 35}, 40] (* _Vladimir Joseph Stephan Orlovsky_, Feb 20 2012 *)
%t Table[FromDigits[Join[PadRight[{1},n,0],PadRight[{},n-2,1]],2],{n,2,30}]//Sort (* or *) Rest[CoefficientList[Series[x (-2+5x)/((x-1)(2x-1)(4x-1)),{x,0,30}],x]] (* _Harvey P. Dale_, Jul 30 2021 *)
%Y Cf. A007088, A001700.
%Y Subsequence of A031443.
%Y Cf. A000120, A023416.
%Y Cf. A007582, A056326, A005367, A063376, A032125, A056309, A028403, A001576, A028400, A049775.
%K nonn,easy
%O 1,1
%A _Reinhard Zumkeller_, Mar 23 2004