Nothing Special   »   [go: up one dir, main page]

Skip to main content

An Indexing Method for Two-D Pattern Matching with Applications to Digital Image Searches

  • Conference paper
Web Technologies Research and Development - APWeb 2005 (APWeb 2005)

Part of the book series: Lecture Notes in Computer Science ((LNISA,volume 3399))

Included in the following conference series:

Abstract

The two-dimensional pattern matching problem is to find all occurrences of a two-dimensional m × m matrix P (called the pattern) in another (larger) two-dimensional n × n matrix T (called the text). Most known algorithms for the problem first pre-process the pattern or patterns to make subsequent searches fast. Since each search still takes time proportional to the size of the text, such algorithms are inappropriate in applications in which the text is large and fixed and one will search for many different patterns in the text. We propose an algorithm that first processes the text into an index structure in such a way that subsequent searches with different patterns can be performed very quickly. The construction of the index takes O(n 2log n) time and O(n 2) space. The algorithm may produce false matches, in which the algorithm claims a “match” between P and some submatrix of T while they are actually not equal. However, as will be seen, the probability that a false match can occur is negligible. All occurrences of P in T, probably with a few false matches, can be found in O(m 2) time in the worst case, regardless of the distribution of the elements in T and P. Under the assumption that both T and P are random matrices, the algorithm can find all (correct) occurrences of P in T in O(m + log n) expected time. We applied our algorithm to a digital image search problem and we will present experimental results.

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

Access this chapter

Subscribe and save

Springer+ Basic
$34.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or eBook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 129.00
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 169.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.

Similar content being viewed by others

References

  1. Amir, A., Benson, G., Farach, M.: Alphabet Independent Twodimensional Matching. In: Proc. the 24th annual ACM Symposium on Theory of Computing, pp. 59–68 (1992)

    Google Scholar 

  2. Aho, A.V., Corasick, M.: Efficient string matching: an aid to bibliographic search. Communications of the ACM 18(6), 333–340 (1975)

    Article  MATH  MathSciNet  Google Scholar 

  3. Amir, A., Landau, G.: Fast parallel and serial multidimensional approximate array matching. Theoretical Computer Science 81, 97–115 (1991)

    Article  MATH  MathSciNet  Google Scholar 

  4. Baker, T.J.: A Technique for Extending Rapid Exact-Match String Matching to Arrays of More Than One Dimension. SIAM J. on Computing 7, 533–541 (1978)

    Article  MATH  Google Scholar 

  5. Bird, R.S.: Two Dimensional Pattern Matching. Information Processing Letters 6(5), 168–170 (1977)

    Article  Google Scholar 

  6. Boyer, R.S., Moore, J.S.: A fast matching algorithm. Commun. ACM 20, 762–772 (1977)

    Article  Google Scholar 

  7. Giancarlo, R.: The Suffix of a Square Matrix, with Applications. In: Proc. Fourth Symposium on Discrete Algorithms. ACM-SIAM, pp. 402–411 (1993)

    Google Scholar 

  8. Giancarlo, R., Grossi, R.: Suffix Tree Data Structures for Matrices. In: Apostolico, A., Galil, Z. (eds.) Pattern Matching Algorithms, pp. 293–340. Oxford University Press, Oxford (1997)

    Google Scholar 

  9. Galil, Z., Park, K.: Truly Alphabet-Independent Two-dimensional Pattern Matching. In: Proc. 33th Symposium on Foundations of Computer Science, IEEE, pp. 247–256 (1992)

    Google Scholar 

  10. Knuth, D.E., Morries, J.H., Pratt, V.B.: Fast pattern matching in strings. SIAM J. on Computing 6, 189–195 (1977)

    Article  Google Scholar 

  11. Karp, R., Rabin, M.: Efficient Randomized Pattern Matching Algorithms. IBM J. Res. Develop. 31(2), 249–260 (1987)

    Article  MATH  MathSciNet  Google Scholar 

  12. Manber, U., Myers, G.: Suffix Arrays: A New Method for On-Line String Searches. SIAM Journal on Computing 22, 935–948 (1993)

    Article  MATH  MathSciNet  Google Scholar 

  13. Rosser, J.B., Schoenfeld, L.: Approximate Formulas for Some Functions of Prime Numbers. Illinois J. Math 6, 64–94 (1962)

    MATH  MathSciNet  Google Scholar 

  14. Shi, F.: Suffix arrays for multiple strings: a method for on-line multiple string searches. In: Jaffar, J., Yap, R.H.C. (eds.) ASIAN 1996. LNCS, vol. 1179. Springer, Heidelberg (1996)

    Chapter  Google Scholar 

  15. Zhu, R.F., Takaoka, T.: A Technique for Two-Dimensional Pattern Matching. Communications of the ACM 32(9), 1110–1120 (1989)

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2005 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Shi, F., AlShibli, A. (2005). An Indexing Method for Two-D Pattern Matching with Applications to Digital Image Searches. In: Zhang, Y., Tanaka, K., Yu, J.X., Wang, S., Li, M. (eds) Web Technologies Research and Development - APWeb 2005. APWeb 2005. Lecture Notes in Computer Science, vol 3399. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-31849-1_84

Download citation

  • DOI: https://doi.org/10.1007/978-3-540-31849-1_84

  • Publisher Name: Springer, Berlin, Heidelberg

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

  • Online ISBN: 978-3-540-31849-1

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics