automaton.lift(identities = "default")

$\newcommand{\eword}{\varepsilon} \newcommand{\lmul}[2]{\bra{#1}{#2}} \newcommand{\rmul}[2]{#1\bra{#2}} \newcommand{\lmulq}[2]{\bra{#1}^?{#2}} \newcommand{\rmulq}[2]{#1\bra{#2}^?} \newcommand{\bra}[1]{\langle#1\rangle} \newcommand{\K}{\mathbb{K}} \newcommand{\zed}{\mathsf{0}} \newcommand{\und}{\mathsf{1}} \newcommand{\zeK}{0_{\K}} \newcommand{\unK}{1_{\K}} \newcommand{\Ed}{\mathsf{E}} \newcommand{\Fd}{\mathsf{F}} \newcommand{\Gd}{\mathsf{G}}$ Turn an automaton into a spontaneous automaton by mapping each transition $\lmul{w}{\ell}$ into $\lmul{\lmul{w}{\ell}}{\varepsilon}$.

Preconditions:

  • None

See also:

Examples


In [1]:
import vcsn
a = vcsn.Q.expression('(<1>a+<2>b+<3>c){2}').automaton()
a


:0: FutureWarning: IPython widgets are experimental and may change in the future.
Out[1]:
%3 I0 0 0 I0->0 F2 1 1 0->1 a, ⟨2⟩b, ⟨3⟩c 2 2 1->2 a, ⟨2⟩b, ⟨3⟩c 2->F2

In [2]:
b = a.lift()
b


Out[2]:
%3 I0 0 0 I0->0 F2 1 1 0->1 ⟨a+⟨2⟩b+⟨3⟩c⟩ 2 2 1->2 ⟨a+⟨2⟩b+⟨3⟩c⟩ 2->F2

In [3]:
from IPython.display import display
display(a.context(), b.context())


$\{a, b, c\}\rightarrow\mathbb{Q}$
$1\rightarrow\mathsf{}[\{a, b, c\}\rightarrow\mathbb{Q}]$

A different set of identities can be chosen.


In [4]:
a.lift().type()


Out[4]:
'mutable_automaton<lao, expressionset<letterset<char_letters(abc)>, q>>'

In [5]:
a.lift(identities = 'trivial').type()


Out[5]:
'mutable_automaton<lao, expressionset<letterset<char_letters(abc)>, q>(trivial)>'