Suffix Tree and Suffix Array.ppt

  1. 1、本文档共94页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
Suffix Tree and Suffix Array.ppt

Suffix Tree and Suffix Array Outline Motivation Exact Matching Problem Suffix Tree Building issues Suffix Array Build Search Longest common prefixes Extra topics discussion Suffix Tree VS. Suffix Array Exact Matching Problem Find ‘ssi’ in ‘mississippi’ Exact Matching Problem Find ‘ssi’ in ‘mississippi’ Exact Matching Problem Find ‘ssi’ in ‘mississippi’ Exact Matching Problem Find ‘ssi’ in ‘mississippi’ Exact Matching Problem Find ‘sissy’ in ‘mississippi’ Exact Matching Problem Find ‘sissy’ in ‘mississippi’ Exact Matching Problem Find ‘sissy’ in ‘mississippi’ Exact Matching Problem Find ‘sissy’ in ‘mississippi’ Exact Matching Problem So what? Knuth-Morris-Pratt and Boyer-Moore both achieve this worst case bound. O(m+n) when the text and pattern are presented together. Suffix trees are much faster when the text is fixed and known first while the patterns vary. O(m) for single time processing the text, then only O(n) for each new pattern. Aho-Corasick is faster for searching a number of patterns at one time against a single text. Boyer-Moore Algorithm For string matching(exact matching problem) Time complexity O(m+n) for worst case and O(n/m) for absense Method: backward matching with 2 jumping arrays(bad character table and good suffix table) Suffix Tree Properties of a Suffix Tree Each tree edge is labeled by a substring of S. Each internal node has at least 2 children. Each S(i) has its corresponding labeled path from root to a leaf, for 1? i ? n . There are n leaves. No edges branching out from the same internal node can start with the same character. Building the Suffix Tree How do we build a suffix tree? while suffixes remain: add next shortest suffix to the tree Building the Suffix Tree papua Building the Suffix Tree papua Building the Suffix Tree papua Building the Suffix Tree papua Building the Suffix Tree papua Building the Suffix Tree papua Building the Suffix Tree papua Building the Suffix Tree How do we build a suffix tree? while suffixes remain: ad

文档评论(0)

gshbzl + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档