A033014 Every run of digits of n in base 16 has length 2.
17, 34, 51, 68, 85, 102, 119, 136, 153, 170, 187, 204, 221, 238, 255, 4352, 4386, 4403, 4420, 4437, 4454, 4471, 4488, 4505, 4522, 4539, 4556, 4573, 4590, 4607, 8704, 8721, 8755, 8772, 8789, 8806, 8823, 8840, 8857, 8874
Offset: 1
Examples
In base 16, a(1)=17 is written 11; the subsequent 14 values are the multiples of 17, corresponding to 22, 33, 44, ..., FF. This is followed by a(16) = 4352 = 1100[16], then (still in base 16): 1122, 1133,..., 11FF, 2200, 2211, 2233, etc...
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..2000
Crossrefs
See A033001 for further cross-references.
Programs
-
Mathematica
Select[Range[9000],Union[Length/@Split[IntegerDigits[#,16]]]=={2}&] (* Harvey P. Dale, Jan 19 2013 *)
-
Python
from itertools import count, islice, groupby def A033014_gen(startvalue=1): # generator of terms >= startvalue return filter(lambda n:set(len(list(g)) for k, g in groupby(hex(n)[2:]))=={2},count(max(startvalue,1))) A033014_list = list(islice(A033014_gen(),20)) # Chai Wah Wu, Mar 10 2023
Formula
a(n) = 17*A043320(n) (= 17n for n<16, cf Example). - M. F. Hasler, Feb 02 2014