[go: up one dir, main page]

login
A372281
Numbers written in base of triangular numbers where the trailing digits are made as high as possible.
0
1, 2, 3, 4, 5, 6, 7, 8, 9, 17, 18, 19, 27, 28, 29, 37, 38, 39, 47, 48, 49, 57, 58, 59, 67, 68, 69, 77, 78, 79, 87, 88, 89, 97, 98, 99, 187, 188, 189, 197, 198, 199, 287, 288, 289, 297, 298, 299, 387, 388, 389, 397, 398, 399, 487, 488, 489, 497, 498, 499, 587
OFFSET
1,2
COMMENTS
This sequence differs from A000462 whose leading digits are made as high as possible.
EXAMPLE
The digits (from right to left) have values 1, 3, 6, 10, etc. (A000217), hence a(61) = 587 because 61 = 5*6 + 8*3 + 7*1.
MATHEMATICA
A000217[n_]:=n(n+1)/2; a[n_]:=Module[{s=0}, num=n; digits={}; s=Ceiling[Root[9(#1^3+3#1^2+2#1)-6num &, 1]]; While[s>0, AppendTo[digits, d=Ceiling[(num-9(s-1)^2)/A000217[s]]]; num-=d*A000217[s]; s--]; FromDigits[digits]]; Array[a, 61]
CROSSREFS
9*A000292(n) gives the number of terms with at most n digits.
Sequence in context: A108971 A179977 A326298 * A124359 A124366 A289868
KEYWORD
nonn,base,easy
AUTHOR
Stefano Spezia, Apr 25 2024
STATUS
approved