|
|
A043605
|
|
Numbers whose base-5 representation has exactly 5 runs.
|
|
1
|
|
|
651, 652, 653, 654, 660, 661, 663, 664, 665, 666, 667, 669, 670, 671, 672, 673, 676, 677, 678, 679, 680, 682, 683, 684, 690, 691, 692, 694, 695, 696, 697, 698, 701, 702, 703, 704, 705, 707, 708, 709, 710, 711, 713, 714, 720
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
LINKS
|
|
|
MAPLE
|
fBC:= proc(b, c) local t, i, j, m;
m:= 1/5; t:= 0:
for i from 1 to 5 do
for j from 1 to c[i] do
m:= 5*m;
t:= t + b[i]*m;
od od;
t
end proc:
F:= proc(n) local Res, a, b, c, q, B, C;
Res:= NULL;
B:= [seq(seq(seq(seq(seq([a[1], a[2], a[3], a[4], a[5]], a[1]=subs(a[2]=NULL, [$0..4])), a[2]=subs(a[3]=NULL, [$0..4])), a[3]=subs(a[4]=NULL, [$0..4])), a[4]=subs(a[5]=NULL, [$0..4])), a[5]=1..4)];
sort([seq(seq(fBC(b, c), b=B), c=combinat:-composition(n, 5))])
end proc:
|
|
MATHEMATICA
|
Select[Range[1000], Length[Split[IntegerDigits[#, 5]]]==5&] (* Harvey P. Dale, Jan 02 2014 *)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|