u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Faculty of Science Programming Macro Tree Transducers Patrick Bahr 1 Laurence E. Day 2 1 University of Copenhagen, Department of Computer Science paba@diku.dk 2 University of Nottingham, Functional Programming Laboratory led@cs.nott.ac.uk FP Lab Away Day, 13th June, 2013 Slide 1
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Agenda 1 String Acceptors & String Transducers Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 2
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Agenda 1 String Acceptors & String Transducers 2 Tree Acceptors & Tree Transducers Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 2
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Agenda 1 String Acceptors & String Transducers 2 Tree Acceptors & Tree Transducers 3 Programming with Tree Transducers in Haskell Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 2
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Agenda 1 String Acceptors & String Transducers 2 Tree Acceptors & Tree Transducers 3 Programming with Tree Transducers in Haskell 4 Tree Transducers with Polymorphic State Space Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 2
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Agenda 1 String Acceptors & String Transducers 2 Tree Acceptors & Tree Transducers 3 Programming with Tree Transducers in Haskell 4 Tree Transducers with Polymorphic State Space 5 Macro Tree Transducers (= Tree Transducers with Accumulation Parameters) Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 2
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Agenda 1 String Acceptors & String Transducers 2 Tree Acceptors & Tree Transducers 3 Programming with Tree Transducers in Haskell 4 Tree Transducers with Polymorphic State Space 5 Macro Tree Transducers (= Tree Transducers with Accumulation Parameters) Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 2
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Agenda 1 String Acceptors & String Transducers 2 Tree Acceptors & Tree Transducers 3 Programming with Tree Transducers in Haskell 4 Tree Transducers with Polymorphic State Space 5 Macro Tree Transducers (= Tree Transducers with Accumulation Parameters) Why Tree Transducers? • Compositionality � deforestation • Manipulation of transducers • Composition with state transition functions Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 2
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q 3 q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q 3 q 4 q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q 3 q 4 ∈ Q F ? q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q 3 q 4 ∈ Q F ? Acceptor q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q 3 q 4 ∈ Q F ? Transducer? q , s → q ′ Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q 3 q 4 Transducer q , s → q ′ , w Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings w o r d q 0 q 1 q 2 q 3 q 4 Transducer q , s → q ′ , w Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings ne w w ord ε w o r d q 0 q 1 q 2 q 3 q 4 Transducer q , s → q ′ , w Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Finite State Automata – On Strings new word ne w w ord ε w o r d q 0 q 1 q 2 q 3 q 4 Transducer q , s → q ′ , w Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 3
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Now on Trees! not and or not tt b b Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 4
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Now on Trees! q 0 not and or not tt b b Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 4
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Now on Trees! q 0 not q 1 and or not tt b b Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 4
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Now on Trees! q 0 not q 1 and q 2 q 3 or not tt b b Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 4
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Now on Trees! q 0 not q 1 and q 2 q 3 or not q 4 q 5 q 6 tt b b Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 4
u n i v e r s i t y o f c o p e n h a g e n d e p a r t m e n t o f c o m p u t e r s c i e n c e Now on Trees! q 0 not q , f → q 1 , . . . , q n q 1 and q 2 q 3 or not q 4 q 5 q 6 tt b b Patrick Bahr, Laurence E. Day — Programming Macro Tree Transducers — FP Lab Away Day, 13th June, 2013 Slide 4
Recommend
More recommend