Regular Languages in Sage?

asked 2021-06-04 20:08:54 +0100

dispo gravatar image

updated 2021-06-04 20:10:25 +0100

I see there's a package for automata, but is there a way to work directly with regular languages? For instance, is there an option for seeing which strings are carved out by (ac+b)*c? What about finding a machine associated to that regular expression? Is there a way to work with rational series? I would love to be able to expand out something like (ac+b)*c as a rational function (in noncommuting variables) (1 - (ac+b))^(-1)c, then take a series expansion, but I can't find any documentation on noncommuting power series (though I did find something on noncommuting polynomials, which I could probably leverage by expanding out kleene stars far enough by hand).

I feel like regular languages are such a fundamental topic in CS, and a lot of computational results are known, that some of it must be implemented already. Any advice would be fantastic!

Thanks in advance ^_^.

edit retag flag offensive close merge delete