Abstract
We evaluate the practical performance of labeling schemes for lowest common ancestors in trees. We develop different variants for encoding the labels. We then perform a thorough experimental evaluation of these schemes on a variety of tree shapes and sizes. We find that in general non-prefix-free codes lead to shorter labels than those that are prefix-free, while having roughly the same query time.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
Kannan, S., Naor, M., Rudich, S.: Implicit representation of graphs. SIAM J. Discrete Math. 5(4), 596–603 (1992)
Abiteboul, S., Alstrup, S., Kaplan, H., Milo, T., Rauhe, T.: Compact labeling scheme for ancestor queries. SIAM J. Comput. 35(6), 1295–1309 (2006)
Kaplan, H., Milo, T., Shabo, R.: Compact labeling scheme for xml ancestor queries. Theory Comput. Syst. 40(1), 55–99 (2007)
Alstrup, S., Bille, P., Rauhe, T.: Labeling schemes for small distances in trees. SIAM J. Discrete Math. 19(2), 448–462 (2005)
Gavoille, C., Peleg, D., Pérennes, S., Raz, R.: Distance labeling in graphs. J. Algorithms 53(1), 85–112 (2004)
Cohen, E., Halperin, E., Kaplan, H., Zwick, U.: Reachability and distance queries via 2-hop labels. SIAM J. Comput. 32(5), 1338–1355 (2003)
Harel, D., Tarjan, R.E.: Fast algorithms for finding nearest common ancestors. SIAM J. Comput. 13(2), 338–355 (1984)
Alstrup, S., Gavoille, C., Kaplan, H., Rauhe, T.: Nearest common ancestors: A survey and a new algorithm for a distributed environment. Theory Comput. Syst. 37, 441–456 (2004)
Peleg, D.: Informative labeling schemes for graphs. Theor. Comput. Sci. 340(3), 577–593 (2005)
Caminiti, S., Finocchi, I., Petreschi, R.: Engineering tree labeling schemes: A case study on least common ancestors. In: Halperin, D., Mehlhorn, K. (eds.) ESA 2008. LNCS, vol. 5193, pp. 234–245. Springer, Heidelberg (2008)
Ferragina, P., Venturini, R.: A simple storage scheme for strings achieving entropy bounds. Theor. Comput. Sci. 372(1), 115–121 (2007)
Gilbert, E.N., Moore, E.F.: Variable length binary encodings. Bell System Tech. J. 38, 933–968 (1959)
Hu, T.C., Tucker, A.C.: Optimum computer search trees. SIAM J. Appl. Math. 21, 514–532 (1971)
Hu, T.C., Larmore, L.L., Morgenthaler, J.D.: Optimal integer alphabetic trees in linear time. In: Brodal, G.S., Leonardi, S. (eds.) ESA 2005. LNCS, vol. 3669, pp. 226–237. Springer, Heidelberg (2005)
Mehlhorn, K.: The best possible bound for the weighted path length of binary search trees. SIAM J. Comput. 6(2), 235–239 (1977)
Knuth, D.E.: Optimum binary search trees. Act Informatica 1, 14–25 (1971)
Munro, J.I.: Tables. In: Chandru, V., Vinay, V. (eds.) FSTTCS 1996. LNCS, vol. 1180, pp. 37–42. Springer, Heidelberg (1996)
Gog, S.: Broadword computing and Fibonacci code speed up compressed suffix arrays. In: Gog, S., Vahrenhold, J. (eds.) SEA 2009. LNCS, vol. 5526, pp. 161–172. Springer, Heidelberg (2009)
Witten, I.H., Moffat, A., Bell, T.C.: Managing Gigabytes: Compressing and Indexing Documents and Images, 2nd edn. Morgan Kaufmann, San Francisco (1999)
Garsia, A.M., Wachs, M.L.: A new algorithm for minimum cost binary trees. SIAM J. Comput. 6(4), 622–642 (1977)
Rémy, J.L.: Un procédé itératif de dénombrement d’arbres binaires et son application a leur génération aléatoire. Informatique Théorique et Applications 19(2), 179–195 (1985)
Fischer, J., Heun, V.: Theoretical and practical improvements on the RMQ-problem, with applications to LCA and LCE. In: Lewenstein, M., Valiente, G. (eds.) CPM 2006. LNCS, vol. 4009, pp. 36–48. Springer, Heidelberg (2006)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2009 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Fischer, J. (2009). Short Labels for Lowest Common Ancestors in Trees. In: Fiat, A., Sanders, P. (eds) Algorithms - ESA 2009. ESA 2009. Lecture Notes in Computer Science, vol 5757. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-04128-0_67
Download citation
DOI: https://doi.org/10.1007/978-3-642-04128-0_67
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-04127-3
Online ISBN: 978-3-642-04128-0
eBook Packages: Computer ScienceComputer Science (R0)