Ukkonen's Algorithm Generalized Suffix Trees -
i understand ukkonen's algorithm. curious how extend have more 1 string in (ending special character "$").
i read somewhere given strings s1(say "abcddefx$") , s2(say "abddefgh$"), should insert s1 ukkonen's algo. traverse down tree s2. should search s2 in tree. once node search ends ("ab", after 'b') should resume ukkonen's algorithm there.
i understand basic logic behind this. curious is, happens old suffix links. still valid??? confused triple (active_node,active_length,remainder) should (node representing "ab",0,0) start new pass???
for dealing special characters can use unicode private use areas. these few special ranges of characters reserved own use, ranges around 4000 characters in size. depending on unicode support of language using can easy or difficult.
if not work, instead of inserting characters tree, wrap them in other sort of variable (struct, object, dictionary) 'extend' meaning. way can provide information needed (is end of string? string end of?). can provide custom operators equality on new wrapper instead of using characters directly.
Comments
Post a Comment