680 likes | 831 Views
Input-Driven Pushdown Automata for Edit Distance Neighborhood V . Geffert Z . Bedn á rov á A . Szabari Dept. Computer Science, P.J. Šafárik University Košice, Slovakia. Edit Distance Neighborhood: L -- the given language l -- the given constant
E N D
Input-Driven Pushdown Automata for Edit Distance Neighborhood V.Geffert Z.Bednárová A.Szabari Dept. Computer Science, P.J.Šafárik University Košice, Slovakia
Edit Distance Neighborhood: L -- the given language l -- the given constant ElL -- an edit distance l-neighborhood: L
Edit Distance Neighborhood: L -- the given language l -- the given constant ElL -- an edit distance l-neighborhood: all strings obtained by at most l edit changes from strings in L L ElL w w=w’ w’ w w’
Edit Distance Neighborhood: neeyet you balat vesnced an eel ond of your nose
Edit Distance Neighborhood: neeyet you balat vesnced an eel ond of your nose yet you balat vesnced an eel ontheend of your nose
Edit Distance Neighborhood: neeyet you balat vesnced an eel ond of your nose yet you balatvesnced an eel ontheend of your nose neeyet you balanced an eel on the end of your nose L
Edit Distance Neighborhood: nee yet you balat vesnced an eel ond of your nose yet you balatvesnced an eel ontheend of your nose neeyet you balanced an eel on the end of your nose |tvesnthee| l L
Edit Distance Neighborhood: nee yet you balat vesnced an eel ond of your nose yet you balatvesnced an eel ontheend of your nose neeyet you balanced an eel on the end of your nose |tvesnthee| l L E’l L
Edit Distance Neighborhood: Algorithm computing edit distance between two strings [Wagner&Fischer1974]
Edit Distance Neighborhood: Algorithm computing edit distance between two strings [Wagner&Fischer1974] Input-driven pushdown automata [Mehlhorn1980] … while … do … if … then … else … fi … od …
Edit Distance Neighborhood: Algorithm computing edit distance between two strings [Wagner&Fischer1974] Input-driven pushdown automata [Mehlhorn1980] … while … do … if … then … else … fi … od … push push pop pop
**** PDA Definition **** coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
Finite state control coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
Finite state control Pushdown store coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
Finite state control Pushdown store Input tape coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
Finite state control Pushdown store Input tape = oU+U- coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
o (neutral) Finite state control Pushdown store Input tape = oU+U- co q q’ coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
a+pushB o (neutral) q q’ Finite state control Pushdown store Input tape = oU+U- + (pushing) co q q’ coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
a+pushB o (neutral) q q’ Finite state control Pushdown store Input tape = oU+U- + (pushing) l-popB co q q’ q q’ - (popping) coa+l-m-e+s+t+ col-i+m-a+t+e+ q BRAIN
a+pushB o (neutral) q q’ + (pushing) m-pop l-popB co q q q’ q’ q q’ - (popping) coa+l-m-e+s+t+ col-i+m-a+t+e+ q
a+pushB o (neutral) q q’ + (pushing) m-pop l-popB co q q q’ q’ q q’ - (popping) q q’ -transitions coa+l-m-e+s+t+ col-i+m-a+t+e+ q RAIN
a+pushB o (neutral) q q’ + (pushing) m-pop l-popB co q q q’ q’ q q’ - (popping) q q’ -transitions coa+l-m-e+s+t+ col-i+m-a+t+e+ q’ RAIN
a+pushB … -transitions coa+l-m-e+s+t+ col-i+m-a+t+e+ q’ q1 qr q’ q3 q4 q2 RAIN
a+pushB … a+pushB -transitions coa+l-m-e+s+t+ col-i+m-a+t+e+ q’ q1 q1 qr q’ q’ q4 q3 q2 RAIN
**** PDA Motivation **** Input-Driven Pushdown Automata: Closed under Boolean operations, concatenation, Kleene star (not homomorphism)
Input-Driven Pushdown Automata: Closed under Boolean operations, concatenation, Kleene star (not homomorphism) Nondeterminism can be eliminated
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]:
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]: L || stack symbols |Q| states
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]: L || stack symbols |Q| states E1L |’| O(||2) |Q’| O(|Q|||)
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]: L || stack symbols |Q| states E1L |’| O(||2) |Q’| O(|Q|||) • ElL = E1El-1L
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]: L || stack symbols |Q| states E1L |’| O(||2) |Q’| O(|Q|||) ElL |’| ||2l|Q’| |Q|||2l-1 • ElL = E1El-1L
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]: L || stack symbols |Q| states E1L |’| O(||2) |Q’| O(|Q|||) ElL |’| ||2l|Q’| |Q|||2l-1 E1L |’| = ||+1 3 days before DLT’19 deadline • ElL = E1El-1L
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]: L || stack symbols |Q| states E1L |’| O(||2) |Q’| O(|Q|||) ElL |’| ||2l|Q’| |Q|||2l-1 E1L |’| = ||+1 ElL |’| = ||+l|Q’| |Q|2l(||+3/2)l 3 days before DLT’19 deadline
Input-Driven Pushdown Automata: Closed under edit distance neighborhood [Okhotin&Salomaa2017]: L || stack symbols |Q| states E1L |’| O(||2) |Q’| O(|Q|||) ElL |’| ||2l|Q’| |Q|||2l-1 E1L |’| = ||+1 ElL |’| = ||+l|Q’| |Q|2l(||+3/2)l ElL |’| = 2||+1 |Q’| O( |Q|l||l ) This Work
**** For Marked Corrections **** A Machine for Marked Corrections yetyoubalancedaneelontheendofyournose yetyoubalatvesncedaneelontheendofyournose L El L neeyet you balat vesnced an eel ond of your nose
yetyoubalancedaneelontheendofyournose • ’ yetyoubalatvesncedaneelontheendofyournose L
yetyoubalancedaneelontheendofyournose yetyoubalatvesncedaneelontheendofyournose • ’ yetyoubalatvesncedaneelontheendofyournose L
yetyoubalatvesncedaneelontheendofyournose • ’ yetyoubalatvesncedaneelontheendofyournose
• ’ • yetyoubalatvesncedaneelontheendofyournose • ’ yetyoubalatvesncedaneelontheendofyournose
• ’ • +g’ • ’
g’ 0…l • = (+g’)-’ 0…+l • +g’ • ’
F O R T H E N I G H T • g’ 0…l • = (+g’)-’ 0…+l • +g’ • ’
F O R T H E N I G H T • g’ 0…l • = (+g’)-’ 0…+l • g’ • +g’ • ’
F O R T H E N I G H T • +g’ • g’ 0…l • = (+g’)-’ 0…+l • g’ • +g’ • ’
F O R T H E N I G H T • +g’ • ’ • g’ 0…l • = (+g’)-’ 0…+l • g’ • +g’ • ’
F O R • T H E N I G H T • +g’ • ’ • g’ 0…l • = (+g’)-’ 0…+l • g’ • +g’ • ’
F O R • Buffer • New • pushdown • store T H E N I G H T • g’ 0…l • = (+g’)-’ 0…+l • +g’ • ’
**** For Neighborhood **** A Machine for Edit Distance Neighborhood L yetyoubalatvesncedaneelontheendofyournose yetyoubalatvesncedaneelontheendofyournose
L yetyoubalatvesncedaneelontheendofyournose yetyoubalatvesncedaneelontheendofyournose
qINI q’ L yetyoubalatvesncedaneelontheendofyournose yetyoubalatvesncedaneelontheendofyournose