label.rdivide(l)

The right-quotient of label by l, i.e., the removal of a suffix. Written label / l, or sometimes $(\mathit{label})\ell^{-1}$.

See also:

Examples

In [1]:
import sys
import vcsn
label = vcsn.context('law_char, q').label
label('abcd').rdivide(label(''))
Out[1]:
$\mathit{abcd}$
In [2]:
label('abcd').rdivide(label('d'))
Out[2]:
$\mathit{abc}$
In [3]:
label('abcd').ldivide(label('abcd'))
Out[3]:
$\varepsilon$
In [4]:
try:
    label('d').rdivide(label('abcd'))
except Exception as e:
    print(e, file=sys.stderr)
{abcd}*: rdivide: invalid arguments: d, abcd
In [5]:
label('abcd') / label('')
Out[5]:
$\mathit{abcd}$