ranking and unranking of words;
fast enumeration and denumeration of words;
enumerative encoding;
Dyck language;
D O I:
10.1134/S0001434614070062
中图分类号:
O1 [数学];
学科分类号:
0701 ;
070101 ;
摘要:
The problem of enumerating and denumerating words generated by Dyck grammars arises in the work of compilers for high-level programming languages and a number of other applications. The present paper proposes an algorithm for the fast enumeration and denumeration of words of Dyck languages; the complexity of this algorithm per one symbol of enumerated words is O(log(3) n log log n) bit operations, provided that the Schonhage-Strassen multiplication and division algorithmis used. The well-knownmethods applied earlier possess complexityO(n) per one symbol of enumerated words. The construction of the proposed algorithm is based on the Ryabko method.
机构:
Univ Banja Luka, Dept Math & Informat, Banja Luka 78000, Republic Of Srp, Bosnia & HercegUniv Banja Luka, Dept Math & Informat, Banja Luka 78000, Republic Of Srp, Bosnia & Herceg