Regular Article
Pattern Matching in Hypertext

https://doi.org/10.1006/jagm.1999.1063Get rights and content

Abstract

The importance of hypertext has been steadily growing over the past decade. The Internet and other information systems use hypertext format, with data organized associatively rather than sequentially or relationally. A myriad of textual problems have been considered in the pattern matching field with many nontrivial results. Nevertheless, surprisingly little work has been done on the natural combination of pattern matching and hypertext. In contrast to regular text, hypertext has a nonlinear structure and the techniques of pattern matching for text cannot be directly applied to hypertext. Manber and Wu (1992, “IAPR Workshop on Structural and Syntactic Pattern Recognition, Bern, Switzerland”) pioneered the study of pattern matching in hypertext and defined a hypertext model for pattern matching. Akutsu (1993, “Procedures of the 4th Symposium on Combinatorial Pattern Matching, Podova, Italy,” pp. 1–10) developed an algorithm that can be used for exact pattern matching in a tree-structured hypertext. Park and Kim (1995, “6th Symposium on Combinatorial Pattern Matching, Helsinki, Finland”) considered regular pattern matching in hypertext. They developed a complex algorithm that works for hypertext with an underlying structure of a DAG. In this paper we present a much simpler algorithm achieving the same complexity which runs on any hypertext graph. We then extend the problem to approximate pattern matching in hypertext, first considering hamming distance and then edit distance. We show that in contrast to regular text, it does make a difference whether the errors occur in the hypertext or the pattern. The approximate pattern matching problem in hypertext with errors in the hypertext turns out to be NP-complete and the approximate pattern matching problem in hypertext with errors in the pattern has a polynomial time solution.

References (18)

  • K. Abrahamson

    Generalized string matching

    SIAM J. Comput.

    (1987)
  • T. Akutsu, A linear time pattern matching algorithm between a string and a tree, inProceedings of the 4th Symposium on...
  • A. Amir et al.

    Dynamic dictionary matching

    J. Comput. System Sci.

    (1994)
  • A. Amir et al.

    Improved dynamic dictionary matching

    Inform. and Comput.

    (1995)
  • A. Aviad

    HyperTalmud: A Hypertext System for the Babylonian Talmud and Its Commentaries

    (1993)
  • R.S. Boyer et al.

    A fast string searching algorithm

    Comm. Assoc. Comput. Mach.

    (1977)
  • T.H. Cormen et al.

    Introduction to Algorithms

    (1990)
  • M.J. Fischer et al.

    String matching and other products

There are more references available in the full text version of this article.

Cited by (0)

A preliminary version of this paper appeared in WADS 97.

2

Partially supported by NSF Grant CCR-96-101709, BSF Grant 96-00509, and a Bar-Ilan University Internal Research Grant.

3

Partially supported by the Israel Ministry of Science and the Arts Grant 8560. This work is part of this author's Ph.D. dissertation.

View full text