Create a new automaton from the coaccessible part of the input, i.e., the subautomaton whose states can be reach a final state.
Preconditions:
Postconditions:
See also:
import vcsn
The following automaton has states that cannot be reach any final(s) states:
a = vcsn.automaton('''
digraph
{
vcsn_context = "lal_char(abc), b"
I -> 0
0 -> 1 [label = "a"]
1 -> F
i -> 0 [label = "a"]
1 -> f [label = "a"]
}
''')
a
a.is_coaccessible()
Calling coaccessible
returns the same automaton, but without its non-coaccessible states:
a.coaccessible()
a.coaccessible().is_coaccessible()