Advertisement

AC-Automaton Update Algorithm for Semi-dynamic Dictionary Matching

  • DiptaramaEmail author
  • Ryo Yoshinaka
  • Ayumi Shinohara
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 9954)

Abstract

Given a set of pattern strings called a dictionary and a text string, dictionary matching is the problem to find the occurrences of the patterns on the text. Dynamic dictionary matching is dictionary matching where patterns may dynamically be inserted into and deleted from the dictionary. The problem is called semi-dynamic dictionary matching when we only consider the insertion. An AC-automaton is a data structure which enables us to solve dictionary matching in \(O(d\log \sigma )\) preprocessing time and \(O(n\log \sigma )\) matching time, where d denotes the total length of the patterns in the dictionary, n denotes the length of the text, and \(\sigma \) denotes the alphabet size. In this paper we propose an efficient algorithm that dynamically updates an AC automaton for insertion of a new pattern by using a directed acyclic word graph.

Keywords

Semi-dynamic dictionary matching AC-automaton DAWG 

Notes

Acknowledgments

This work is supported by Tohoku University Division for Interdisciplinary Advance Research and Education, JSPS KAKENHI Grant Numbers JP15H05706, JP24106010, and ImPACT Program of Council for Science, Technology and Innovation (Cabinet Office, Government of Japan).

References

  1. 1.
    Aho, A.V., Corasick, M.J.: Efficient string matching: an aid to bibliographic search. Commun. ACM 18(6), 333–340 (1975)MathSciNetCrossRefzbMATHGoogle Scholar
  2. 2.
    Amir, A., Farach, M., Galil, Z., Giancarlo, R., Park, K.: Dynamic dictionary matching. J. Comput. Syst. Sci. 49(2), 208–222 (1994)MathSciNetCrossRefzbMATHGoogle Scholar
  3. 3.
    Amir, A., Farach, M., Idury, R.M., Lapoutre, J.A., Schaffer, A.A.: Improved dynamic dictionary matching. Inf. Comput. 119(2), 258–282 (1995)MathSciNetCrossRefzbMATHGoogle Scholar
  4. 4.
    Blumer, A., Blumer, J., Haussler, D., McConnell, R., Ehrenfeucht, A.: Complete inverted files for efficient text retrieval and analysis. J. ACM 34(3), 578–595 (1987)MathSciNetCrossRefzbMATHGoogle Scholar
  5. 5.
    Blumer, A., Blumer, J., Haussler, D., Ehrenfeucht, A., Chen, M.T., Seiferas, J.: The smallest automation recognizing the subwords of a text. Theor. Comput. Sci. 40, 31–55 (1985)MathSciNetCrossRefzbMATHGoogle Scholar
  6. 6.
    Chan, H.L., Hon, W.K., Lam, T.W., Sadakane, K.: Dynamic dictionary matching and compressed suffix trees. In: Proceedings of the Sixteenth Annual ACM-SIAM Symposium on Discrete Algorithms. Society for Industrial and Applied Mathematics, pp. 13–22 (2005)Google Scholar
  7. 7.
    Commentz-Walter, B.: A string matching algorithm fast on the average. In: Maurer, H.A. (ed.) Automata, Languages and Programming. LNCS, vol. 71, pp. 118–132. Springer, Heidelberg (1979)CrossRefGoogle Scholar
  8. 8.
    Crochemore, M.: String matching with constraints. In: Chytil, M.P., Koubek, V., Janiga, L. (eds.) Mathematical Foundations of Computer Science 1988. LNCS, vol. 324, pp. 44–58. Springer, Heidelberg (1988)CrossRefGoogle Scholar
  9. 9.
    Crochemore, M., Rytter, W.: Jewels of Stringology. World Scientific Publishing Co. Pte. Ltd., Singapore (2002)CrossRefzbMATHGoogle Scholar
  10. 10.
    Feigenblat, G., Porat, E., Shiftan, A.: An improved query time for succinct dynamic dictionary matching. In: Kulikov, A.S., Kuznetsov, S.O., Pevzner, P. (eds.) CPM 2014. LNCS, vol. 8486, pp. 120–129. Springer, Heidelberg (2014)Google Scholar
  11. 11.
    Hon, W.-K., Lam, T.-W., Shah, R., Tam, S.-L., Vitter, J.S.: Succinct index for dynamic dictionary matching. In: Dong, Y., Du, D.-Z., Ibarra, O. (eds.) ISAAC 2009. LNCS, vol. 5878, pp. 1034–1043. Springer, Heidelberg (2009)CrossRefGoogle Scholar
  12. 12.
    Idury, R.M., Schäffer, A.A.: Dynamic dictionary matching with failure functions. Theor. Comput. Sci. 131(2), 295–310 (1994)MathSciNetCrossRefzbMATHGoogle Scholar
  13. 13.
    Ishizaki, F., Toyama, M.: An incremental update algorithm for large Aho-Corasick automaton. In: Proceedings of the 4th Forum on Data Engineering and Information Management, F11–5, pp. 1–6 (2012). (In Japanese)Google Scholar
  14. 14.
    Kucherov, G., Rusinowitch, M.: Matching a set of strings with variable length don’t cares. Theor. Comput. Sci. 178(12), 129–154 (1997)MathSciNetCrossRefzbMATHGoogle Scholar
  15. 15.
    Meyer, B.: Incremental string matching. Inf. Process. Lett. 21(5), 219–227 (1985)CrossRefGoogle Scholar
  16. 16.
    Tsuda, K., Fuketa, M., Aoe, J.I.: An incremental algorithm for string pattern matching machines. Int. J. Comput. Math. 58, 33–42 (1995)CrossRefGoogle Scholar
  17. 17.
    Wikipedia: Dynamic array – Wikipedia, the free encyclopedia (2016). Accessed 15 May 2016Google Scholar

Copyright information

© Springer International Publishing AG 2016

Authors and Affiliations

  1. 1.Graduate School of Information SciencesTohoku UniversityAoba-ku, SendaiJapan

Personalised recommendations