Upload
sen
View
213
Download
1
Embed Size (px)
Citation preview
An Efficient Algorithm For The Inverse ST Problem
Ge Nong Sen ZhangComputer Sci. Dept. Dept. of Math., Computer Sci. and Stat.
Sun Yat-Sen University, PRC SUNY College at Oneonta, USAEmail: [email protected] Email: [email protected]
The Schindler Transform (ST) [1] can speed up the block sorting phase of the Burrows-Wheeler Transform (BWT) by limiting the context sorting to the first k (k ∈ [0, N ],where N is the length of the text) positions only. Under the ST’s partial sorting scheme,if two rows share the exactly same k-order context, they may not be ordered alpha-betically; instead, the relative order between them in the original matrix is preservedin the transformed matrix. A major tradeoff for the ST to achieve the speedup gainover the BWT is that the inverse ST appears to be more complicated than the inverseBWT. To deal with the existence of identical k-order contexts, Schindler suggested ahash based approach in which the text retrieval has to rely on the hash table basedcontext lookup, which in turn has to rely on the complete retrieval of all the k-ordercontexts. An improved solution proposed by Yokoo [2] uses no hash table; however, itstill needs to restore all the k-order contexts, which clearly requires O(kN) for both thetime and the space complexities. Recently, Nong and Zhang [3] had proposed an auxiliaryvector based framework, which is different from any possible k-order context retrievalbased approaches formerly suggested by others, but similar to that used for the inverseBWT. This framework relies on two size-N vectors Tk and Ck (details are omitted dueto space limit) to correctly retrieve the true immediate preceding character for a givencharacter, which allows the original text to be recovered directly from the transformedtext without statically restoring the complete k-order contexts. As a consequence, thisframework requires only O(N) space. However, its running time remains to be O(kN),for it has to visit each column of the k-order context matrix to obtain Tk and Ck. SinceTk and Ck can be deduced from the context switch vector D (the data structure indicatingwhether each pair of two neighbor rows in the context matrix are the same or not) inlinear time, the more efficient the D can be calculated, the faster the ST can be inverted.If two k-order contexts are different, either their first halves are different already, ortheir second halves are different; furthermore, the second half of the k-order contextmatrix can be deduced from its first half due to the rotating scheme in ST. Based onthis observation, we proposed a dynamic programming approach to quickly calculate Dby doubling the steps to reach the kth column in comparing the k-order contexts. This“doubling technique” based algorithm requires only O(N log k) time to calculate D, thusresulting in an O(N log k) time complexity algorithm to invert ST. The space complexityof the algorithm remains to be O(N). This new algorithm can be used to build efficientcompression solutions based on the ST.
REFERENCES
[1] M. Schindler, “A fast block-sorting algorithm for lossless data compression,” in Proceedings DCC ’97 DataCompression Conference, Snowbird, UT, USA, Mar. 1997, p. 469.
[2] H. Yokoo, “Notes on block-sorting data compression,” Electronics and Communications in Japan (Part III:Fundamental Electronic Science), vol. 82, no. 6, pp. 18–25, 1999.
[3] G. Nong and S. Zhang, “Unifying the Burrows-Wheeler and the Schindler transforms,” in Proceedings DCC ’06Data Compression Conference, Snowbird, UT, USA, Mar. 2006, p. 464.
2007 Data Compression Conference (DCC'07)0-7695-2791-4/07 $20.00 © 2007