login
A296694
Numbers whose base-4 digits d(m), d(m-1), ... d(0) have #(rises) = #(falls); see Comments.
4
1, 2, 3, 5, 10, 15, 17, 18, 19, 21, 24, 25, 28, 29, 30, 33, 34, 35, 38, 39, 42, 44, 45, 46, 49, 50, 51, 54, 55, 59, 63, 65, 66, 67, 69, 74, 79, 81, 82, 83, 85, 88, 89, 92, 93, 94, 96, 101, 104, 105, 112, 117, 122, 124, 125, 126, 129, 130, 131, 133, 138, 143
OFFSET
1,2
COMMENTS
A rise is an index i such that d(i) < d(i+1); a fall is an index i such that d(i) > d(i+1). The sequences A296694-A296696 partition the natural numbers. See the guide at A296712.
LINKS
EXAMPLE
The base-4 digits of 143 are 2,0,3,3; here #(rises) = 1 and #(falls) = 1, so 143 is in the sequence.
MATHEMATICA
z = 200; b = 4; d[n_] := Sign[Differences[IntegerDigits[n, b]]];
Select[Range [z], Count[d[#], -1] == Count[d[#], 1] &] (* A296694 *)
Select[Range [z], Count[d[#], -1] < Count[d[#], 1] &] (* A296695 *)
Select[Range [z], Count[d[#], -1] > Count[d[#], 1] &] (* A296696 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Clark Kimberling, Dec 21 2017
STATUS
approved