A023759 Nialpdromes: digits in base 3 are in nonincreasing order.
0, 1, 2, 3, 4, 6, 7, 8, 9, 12, 13, 18, 21, 22, 24, 25, 26, 27, 36, 39, 40, 54, 63, 66, 67, 72, 75, 76, 78, 79, 80, 81, 108, 117, 120, 121, 162, 189, 198, 201, 202, 216, 225, 228, 229, 234, 237, 238, 240, 241, 242, 243, 324, 351, 360, 363, 364, 486, 567, 594
Offset: 1
Links
- Vincenzo Librandi and Ray Chandler, Table of n, a(n) for n = 1..1000 (first 800 terms from Vincenzo Librandi)
Programs
-
Mathematica
Select[Range[0, 4000], Max[Differences[IntegerDigits[#, 3]]] <= 0 &] (* Vincenzo Librandi, Dec 26 2012 *) Select[Range[0,600],GreaterEqual@@IntegerDigits[#,3]&] (* Ray Chandler, Jan 06 2014 *)
-
PARI
is(n)=n=digits(n,3); n==vecsort(n,,4) \\ Charles R Greathouse IV, Mar 31 2014