Skip to main content

Tree Pattern Matching for Linear Static Terms

  • Conference paper
  • First Online:
String Processing and Information Retrieval (SPIRE 2002)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 2476))

Included in the following conference series:

Abstract

In this paper, we present a simple algorithm for pattern matching within a family of trees called linear terms, that have many applications in the design of programming languages, theorem proving and symbolic computation for example. Our algorithm relies on the representation of a tree by words. It has a quadratic worst-case time complexity, which is worse than the best known algorithm, but experimental results on uniformly distributed random binary terms suggest a linear expected time and interesting practical behavior.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. A. V. Aho and M. Ganapathi. Efficient tree pattern matching: an aid to code generation. In ACM Symposium on Principles of Programming Languages, POPL’85, pages 334–340. Assoc. Comput. Mach. Press, 1985.

    Google Scholar 

  2. M.S. Boyer and J. S. Moore. A fast string-searching algorithm. Comm. ACM, 20:762–772, 1977.

    Article  Google Scholar 

  3. J. Cai, R. Paige, and R. E. Tarjan. More efficient bottom-up multi-pattern matching in trees. Theoret. Comput. Sci., 106(1):21–60, 1992.

    Article  MATH  MathSciNet  Google Scholar 

  4. C. Chauve. Tree pattern matching with a more general notion of occurrence of the pattern. Inform. Process. Letters, 82(4):197–201, 2002.

    Article  MATH  MathSciNet  Google Scholar 

  5. R. Cole and R. Hariharan. Tree pattern matching and subset matching in randomized O(n log3 m) time. In ACM Symposium on Theory of Computing, STOC’97, pages 66–75. Assoc. Comput. Mach. Press, 1997.

    Google Scholar 

  6. R. Cole, R. Hariharan, and P. Indyk. Tree pattern matching and subset matching in deterministic O(n log3 n)-time. In ACM-SIAM Symposium on Discrete Algorithms, SODA’99, pages 245–254. Assoc. Comput. Mach. Press, 1999.

    Google Scholar 

  7. M. Crochemore and W. Rytter. Text algorithms. Oxford University Press, New York, 1994.

    MATH  Google Scholar 

  8. M. Dubiner, Z. Galil, and E. Magen. Faster tree pattern matching. J. Assoc. Comput. Mach., 41(2):205–213, 1994.

    MATH  MathSciNet  Google Scholar 

  9. C. M. Hoffmann and M.J. O’Donnell. Pattern matching in trees. J. Assoc. Comput. Mach., 29(1):68–95, 1982.

    MATH  MathSciNet  Google Scholar 

  10. D. E. Knuth, J. H. Jr. Morris, and V. R. Pratt. Fast pattern matching in strings. SI AM J. Comput., 6(2):323–350, 1977.

    Article  MATH  MathSciNet  Google Scholar 

  11. S.R. Kosaraju. Efficient tree pattern matching. In IEEE Symposium on Foundations of Computer Science, FOCS’89, pages 178–183. IEEE Comput. Soc. Press, 1989.

    Google Scholar 

  12. F. Luccio and L. Pagli. An efficient algorithm for some tree matching problems. Inform. Process. Lett., 39(1):51–57, 1991.

    Article  MATH  MathSciNet  Google Scholar 

  13. F. Luccio and L. Pagli. Simple solutions for approximate tree matching problems. In Theory and Practice of Software, TAPSOFT’ 91, volume 493 of Lecture Notes in Comput. Sci., pages 193–201. Springer, 1991.

    Google Scholar 

  14. F. Luccio and L. Pagli. Approximate matching for two families of trees. Inform. and Comput., 123(1):111–120, 1995.

    Article  MATH  MathSciNet  Google Scholar 

  15. B. A. Shapiro and K. Zhang. Comparing multiple RNA secondary structures using tree comparisons. Comput. Appl. Biosci., 6:309–318, 1990.

    Google Scholar 

  16. T. Shibuya. Constructing the suffix tree of a tree with a large alphabet. In International Symposium on Algorithms and Computation, ISAAC’99, volume 1741 of Lecture Notes in Comput. Sci., pages 225–236. Springer, 1999.

    Google Scholar 

  17. J. M. Steyaert and P. Flajolet. Patterns and pattern-matching in trees: an analysis. Inform. and Control, 58(1-3): 19–58, 1983.

    Article  MATH  MathSciNet  Google Scholar 

  18. M. Thorup. Efficient preprocessing of simple binary pattern forests. J. Algorithms, 20(3):602–612, 1996.

    Article  MATH  MathSciNet  Google Scholar 

  19. K. Zhang and D. Shasha. Simple fast algorithms for the editing distance between trees and related problems. SIAM J. Comput., 18(6):1245–1262, 1989.

    Article  MATH  MathSciNet  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2002 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Chauve, C. (2002). Tree Pattern Matching for Linear Static Terms. In: Laender, A.H.F., Oliveira, A.L. (eds) String Processing and Information Retrieval. SPIRE 2002. Lecture Notes in Computer Science, vol 2476. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-45735-6_15

Download citation

  • DOI: https://doi.org/10.1007/3-540-45735-6_15

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-44158-8

  • Online ISBN: 978-3-540-45735-0

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics