Presentation is loading. Please wait.

Presentation is loading. Please wait.

Suffix Trees ALGGEN: Algorithmics and genetics group Dep. Llenguatges i Sistemes Informàtics Universitat Politècnica de Catalunya Dr. Xavier Messeguer.

Similar presentations


Presentation on theme: "Suffix Trees ALGGEN: Algorithmics and genetics group Dep. Llenguatges i Sistemes Informàtics Universitat Politècnica de Catalunya Dr. Xavier Messeguer."— Presentation transcript:

1

2 Suffix Trees ALGGEN: Algorithmics and genetics group Dep. Llenguatges i Sistemes Informàtics Universitat Politècnica de Catalunya Dr. Xavier Messeguer http://www.lsi.upc.es/~alggen

3 Suffix trees Given string ababaas: 1: ababaas 2: babaas 3: abaas 4: baas 5: aas 6: as 7: s as,3 s,6 as,5 s,7 as,4 ba baas,2 a ba baas,1 a ba baas,1 ba baas,2 as,3as,4 s,6 as,5 s,7 Suffixes: What kind of queries?

4 Queries on Suffix trees a ba baas,1 as,3 ba baas,2 as,4 s,6 as,5 s,7 Does the sequence ababaas contain any ocurrence of patterns abab, aab, and ab? Find repeats within the sequence ababaas. …………………………

5 Quadratic Insertion algorithm Given the string ababaabbs ababaabbs,1

6 Quadratic Insertion algorithm Given the string ababaabbs babaabbs,2 ababaabbs,1

7 Quadratic Insertion algorithm Given the string ababaabbs babaabbs,2 ababaabbs,1 aba baabbs,1

8 Quadratic Insertion algorithm Given the string ababaabbs babaabbs,2 aba baabbs,1 abbs,3

9 Quadratic Insertion algorithm Given the string ababaabbs babaabbs,2 aba baabbs,1 abbs,3 ba baabbs,2

10 Quadratic Insertion algorithm Given the string ababaabbs aba baabbs,1 abbs,3 ba baabbs,2 abbs,4

11 Quadratic Insertion algorithm Given the string ababaabbs aba baabbs,1 abbs,3 abbs,4 ba baabbs,2 abbs,4 abbs,3 ba a baabbs,1

12 Quadratic Insertion algorithm Given the string ababaabbs abbs,4 ba baabbs,2 abbs,4 abbs,3 ba a baabbs,1 abbs,5

13 Quadratic Insertion algorithm Given the string ababaabbs abbs,4 ba baabbs,2 abbs,4 abbs,3 ba a baabbs,1 abbs,5

14 Quadratic Insertion algorithm Given the string ababaabbs abbs,4 ba baabbs,2 abbs,4 a abbs,5 b a abbs,3 baabbs,1

15 Quadratic Insertion algorithm Given the string ababaabbs abbs,4 ba baabbs,2 abbs,4 a abbs,5 b a abbs,3 baabbs,1 bs,6

16 Quadratic Insertion algorithm Given the string ababaabbs abbs,4 ba baabbs,2 abbs,4 a abbs,5 b a abbs,3 baabbs,1 bs,6

17 Quadratic Insertion algorithm Given the string ababaabbs a abbs,5 b a abbs,3 baabbs,1 bs,6 a baabbs,2 b abbs,4 bs,7

18 Quadratic Insertion algorithm Given the string ababaabbs a abbs,5 b a abbs,3 baabbs,1 bs,6 a baabbs,2 b abbs,4 bs,7 s,7

19 Quadratic Insertion algorithm Given the string ababaabbs a abbs,5 b a abbs,3 baabbs,1 bs,6 a baabbs,2 b abbs,4 bs,7 s,7

20 Quadratic Insertion algorithm Given the string ababaabbs abbs,4 ba baabbs,2 abbs,4 a abbs,5 b a abbs,3 baabbs,1 bs,6 a baabbs,2 b abbs,4

21 Definition of MUM … a a t g….c t g... … c g t g….c c c... MatchingUniqueMaximal MUM

22 Search for MUMs Given strings ababaabs and aabaat: List of UM aab,abaa,baa. ba a s,8 s,6 s,7 baabs,2 b a baabs,1 a bs,3 a s,5 a bs,4 b a b t,2 t,5 t,6 t,4 aat,1 t,3 (through the list of UM) 1st: Bottom-up traversal 2nd: Search for maximals (Through the tree) MUMs: aab,abaa.


Download ppt "Suffix Trees ALGGEN: Algorithmics and genetics group Dep. Llenguatges i Sistemes Informàtics Universitat Politècnica de Catalunya Dr. Xavier Messeguer."

Similar presentations


Ads by Google