OFFSET
0,8
COMMENTS
Row 0 consists of all 1's (corresponding to lcm(1,1,...,1) computed from the {1+1+...+1} partition), after which, on each succeeding row, the entry A(row,n) is computed by finding such a partition {p1+p2+...+pk} of n that value of lcm(A(row-1,n),p1,p2,...,pk) is maximized.
EXAMPLE
Table begins:
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ...
1, 1, 2, 3, 4, 6, 6, 12, 15, 20, ...
1, 1, 2, 6, 12, 30, 30, 84, 120, ...
1, 1, 2, 6, 12, 60, 60, 420, 840, ...
...
PROG
(Scheme):
(define (A225630bi col row) (let ((maxlcm (list 0))) (let loop ((prevmaxlcm 1) (stepsleft row)) (if (zero? stepsleft) prevmaxlcm (begin (gen_partitions col (lambda (p) (set-car! maxlcm (max (car maxlcm) (apply lcm (cons prevmaxlcm p)))))) (loop (car maxlcm) (- stepsleft 1)))))))
(define (gen_partitions m colfun) (let recurse ((m m) (b m) (n 0) (partition (list))) (cond ((zero? m) (colfun partition)) (else (let loop ((i 1)) (recurse (- m i) i (+ 1 n) (cons i partition)) (if (< i (min b m)) (loop (+ 1 i))))))))
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Antti Karttunen, May 13 2013
STATUS
approved