Abstract
We show that the maximum number of different square substrings in unrooted labelled trees behaves much differently than in words. A substring in a tree corresponds (as its value) to a simple path. Let \(\textsf{sq}(n)\) be the maximum number of different square substrings in a tree of size n. We show that asymptotically \(\textsf{sq}(n)\) is strictly between linear and quadratic orders, for some constants c 1,c 2 > 0 we obtain:
This is a preview of subscription content, log in via an institution.
Buying options
Tax calculation will be finalised at checkout
Purchases are for personal use only
Learn about institutional subscriptionsPreview
Unable to display preview. Download preview PDF.
References
Alon, N., Grytczuk, J.: Breaking the rhythm on graphs. Discrete Mathematics 308(8), 1375–1380 (2008)
Alon, N., Grytczuk, J., Haluszczak, M., Riordan, O.: Nonrepetitive colorings of graphs. Random Struct. Algorithms 21(3-4), 336–346 (2002)
Blanchet-Sadri, F., Mercas, R., Scott, G.: Counting distinct squares in partial words. Acta Cybern. 19(2), 465–477 (2009)
Bresar, B., Grytczuk, J., Klavzar, S., Niwczyk, S., Peterin, I.: Nonrepetitive colorings of trees. Discrete Mathematics 307(2), 163–172 (2007)
Crochemore, M., Hancart, C., Lecroq, T.: Algorithms on Strings. Cambridge University Press (2007)
Crochemore, M., Rytter, W.: Jewels of Stringology. World Scientific (2003)
Fraenkel, A.S., Simpson, J.: How many squares can a string contain? J. of Combinatorial Theory Series A 82, 112–120 (1998)
Grytczuk, J., Przybylo, J., Zhu, X.: Nonrepetitive list colourings of paths. Random Struct. Algorithms 38(1-2), 162–173 (2011)
Ilie, L.: A simple proof that a word of length n has at most 2n distinct squares. J. Comb. Theory, Ser. A 112(1), 163–164 (2005)
Ilie, L.: A note on the number of squares in a word. Theor. Comput. Sci. 380(3), 373–376 (2007)
Lothaire, M.: Combinatorics on Words. Addison-Wesley, Reading (1983)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2012 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Crochemore, M. et al. (2012). The Maximum Number of Squares in a Tree. In: Kärkkäinen, J., Stoye, J. (eds) Combinatorial Pattern Matching. CPM 2012. Lecture Notes in Computer Science, vol 7354. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-31265-6_3
Download citation
DOI: https://doi.org/10.1007/978-3-642-31265-6_3
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-31264-9
Online ISBN: 978-3-642-31265-6
eBook Packages: Computer ScienceComputer Science (R0)