expression.standard

Generate the standard automaton (aka, "position" or "Glushkov" automaton) from an expression.

Postcondition:

  • Result.is_standard()

Caveats:

  • it is not guaranteed that Result.is_valid()

Properties:

  • Result.is_isomorphic(r.thompson().proper())

See also:

Examples


In [1]:
import vcsn
q = vcsn.context('lal_char(abc), q')


:0: FutureWarning: IPython widgets are experimental and may change in the future.

In [2]:
q.expression('(<1/6>a*+<1/3>b*)*').standard()


Out[2]:
%3 I0 0 0 I0->0 F0 F1 F3 0->F0 ⟨2⟩ 1 1 0->1 ⟨1/3⟩a 3 3 0->3 ⟨2/3⟩b 1->F1 ⟨2⟩ 1->1 ⟨4/3⟩a 1->3 ⟨2/3⟩b 3->F3 ⟨2⟩ 3->1 ⟨1/3⟩a 3->3 ⟨5/3⟩b