login
Irregular triangle read by rows: row n lists the divisors of n, ordered lexicographically in decimal representation.
2

%I #11 Jan 23 2022 15:33:39

%S 1,1,2,1,3,1,2,4,1,5,1,2,3,6,1,7,1,2,4,8,1,3,9,1,10,2,5,1,11,1,12,2,3,

%T 4,6,1,13,1,14,2,7,1,15,3,5,1,16,2,4,8,1,17,1,18,2,3,6,9,1,19,1,10,2,

%U 20,4,5,1,21,3,7,1,11,2,22,1,23,1,12,2,24

%N Irregular triangle read by rows: row n lists the divisors of n, ordered lexicographically in decimal representation.

%H Reinhard Zumkeller, <a href="/A254679/b254679.txt">Rows n = 1..1000 of triangle, flattened</a>

%e . n | T(n,1..A000005(n)) n | T(n,1..A000005(n))

%e . ----+------------------- ----+-------------------

%e . 1 | 1 21 | 1 21 3 7

%e . 2 | 1 2 22 | 1 11 2 22

%e . 3 | 1 3 23 | 1 23

%e . 4 | 1 2 4 24 | 1 12 2 24 3 4 6 8

%e . 5 | 1 5 25 | 1 25 5

%e . 6 | 1 2 3 6 26 | 1 13 2 26

%e . 7 | 1 7 27 | 1 27 3 9

%e . 8 | 1 2 4 8 28 | 1 14 2 28 4 7

%e . 9 | 1 3 9 29 | 1 29

%e . 10 | 1 10 2 5 30 | 1 10 15 2 3 30 5 6

%e . 11 | 1 11 31 | 1 31

%e . 12 | 1 12 2 3 4 6 32 | 1 16 2 32 4 8

%e . 13 | 1 13 33 | 1 11 3 33

%e . 14 | 1 14 2 7 34 | 1 17 2 34

%e . 15 | 1 15 3 5 35 | 1 35 5 7

%e . 16 | 1 16 2 4 8 36 | 1 12 18 2 3 36 4 6 9

%e . 17 | 1 17 37 | 1 37

%e . 18 | 1 18 2 3 6 9 38 | 1 19 2 38

%e . 19 | 1 19 39 | 1 13 3 39

%e . 20 | 1 10 2 20 4 5 40 | 1 10 2 20 4 40 5 8 .

%o (Haskell)

%o import Data.List (sortBy); import Data.Ord (comparing)

%o a254679 n k = a254679_tabf !! (n-1) !! (k-1)

%o a254679_row n = a254679_tabf !! (n-1)

%o a254679_tabf = map (sortBy (comparing show)) a027750_tabf

%o (PARI) cmps(x,y) = cmp(Str(x), Str(y));

%o row(n) = vecsort(divisors(n), cmps); \\ _Michel Marcus_, Jan 23 2022

%Y Cf. A027750, A000005 (row lengths), A000203 (row sums), A122425 (right edge).

%K nonn,base,tabf

%O 1,3

%A _Reinhard Zumkeller_, Feb 05 2015