Give a regular description for the image of the language
L={xay∈{a,b}∗∣∣y∣=1} through this transducer:
Such transducer can be alternatively formalized as
the following set of rewrite rules:
0a→aba00b→b11a→b01b→aa1
In this alternative setting, to rewrite a word
w∈L we would start
the execution with the word
0w and proceed until obtaining a word of the form
w′0 or
w′1 (i.e., a word that cannot be rewritten any further),
where
w′ would be the generated output.
In order to get more intuition on how this transducer works, consider the word
baa∈L and the following step-by-step execution:
- 0 baa
Initially, the transducer is at state 0 and it remains to read the
whole word baa. Moreover, no output has been produced yet.
- b 1 aa
By reading b at state 0, the transducer has moved to state 1
and outputted b.
(Equivalently, the 2nd rewrite rule has been applied.)
- b b 0 a
By reading a at state 1, the transducer has moved to state 0
and outputted b.
(Equivalently, the 3rd rewrite rule has been applied.)
- b b aba 0
By reading a at state 0, the transducer has moved to state 0
and outputted aba
(Equivalently, the 1st rewrite rule has been applied.)
Since there is no more input, the execution terminates.
Hence, the image of the word
baa∈L through the transducer is
bbaba.