Kernel: Python 3
automaton.is_partial_identity
Whether the automaton is a partial identity, i.e. each (accepted) input is transduced to itself.
Precondition:
The automaton is transducer.
The two tapes have the same labelset.
See also:
Examples
In [1]:
In [2]:
This transducer is a partial identity.
In [3]:
True
However, the following transducer is not a partial identity, as it maps aaa
to aaaa
.
In [4]:
In [5]:
False