OFFSET
0,3
COMMENTS
This ranking scheme condenses the structures of the same size (cf. A072789) somewhat better than scheme presented in A072656 (which uses the N X N -> N bijection A072793). Compare the sequences A072790 and A072640 giving the max positions where the last structure with size n will occur in these orderings and the respective binary widths A072791 & A072642. However, by using the second or third power of the bijection A072734 one gets even better results in a certain range.
LINKS
PROG
(Scheme functions below show the essential idea. For a complete source, follow the "Gatomorphisms" link.)
(define A072787 (lexrank->arithrank-bijection packA072734))
(define (lexrank->arithrank-bijection packfun) (lambda (n) (rank-bintree (binexp->parenthesization (A014486 n)) packfun)))
(define (rank-bintree bt packfun) (cond ((not (pair? bt)) 0) (else (1+ (packfun (rank-bintree (car bt) packfun) (rank-bintree (cdr bt) packfun))))))
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jun 12 2002
STATUS
approved