login
Numbers whose base-4 representation contains no 2's and exactly one 3.
1

%I #21 May 21 2023 12:23:28

%S 3,7,12,13,19,23,28,29,48,49,52,53,67,71,76,77,83,87,92,93,112,113,

%T 116,117,192,193,196,197,208,209,212,213,259,263,268,269,275,279,284,

%U 285,304,305,308,309,323,327,332,333,339,343,348

%N Numbers whose base-4 representation contains no 2's and exactly one 3.

%H Robert Israel, <a href="/A045134/b045134.txt">Table of n, a(n) for n = 1..10000</a>

%F From _Robert Israel_, Sep 20 2016: (Start)

%F a(m+(n+1)*2^n) = a(m) + 4^(n+1) for 1 <= m <= (n+1)*2^n.

%F a(m+(n+1)*2^n) = A000695(m-(n+1)*2^n-1) + 3*4^(n+1) for (n+1)*2^n < m <= (n+2)*2^n. (End)

%p N:= 5: # to get all terms < 4^(N+1)

%p B0:= {0,1}:

%p B1:= {3}:

%p for d from 1 to N do

%p B1:= B1 union map(`+`,B0, 3*4^d) union map(`+`,B1,4^d);

%p B0:= B0 union map(`+`, B0,4^d);

%p od:

%p sort(convert(B1,list)); # _Robert Israel_, Sep 20 2016

%t Select[Range[400],DigitCount[#,4,2]==0&&DigitCount[#,4,3]==1&] (* _Harvey P. Dale_, Dec 25 2012 *)

%Y Cf. A000695, A007090.

%K nonn,base

%O 1,1

%A _Clark Kimberling_