Algorithms Library Toolkit
A toolkit for algorithms, especially for algorithms on formal languages
Static Public Member Functions
automaton::convert::ToRegExpAlgebraic Class Reference

#include <ToRegExpAlgebraic.h>

Static Public Member Functions

template<class SymbolType , class StateType >
static regexp::UnboundedRegExp< SymbolType > convert (const automaton::EpsilonNFA< SymbolType, StateType > &automaton)
 
template<class SymbolType , class StateType >
static regexp::UnboundedRegExp< SymbolType > convert (const automaton::MultiInitialStateNFA< SymbolType, StateType > &automaton)
 
template<class T >
requires isDFA < T > || isNFA < T >
static regexp::UnboundedRegExp< typename T::SymbolType > convert (const T &automaton)
 

Detailed Description

Converts a finite automaton to a regular expression using using the Brzozowski's algebraic method (Melichar: Jazyky a překlady 2.122). The algorithm creates a system of right regular equations that is then solved. The regular expression is returned as regexp::UnboundedRegExp.

Member Function Documentation

◆ convert() [1/3]

template<class SymbolType , class StateType >
regexp::UnboundedRegExp< SymbolType > automaton::convert::ToRegExpAlgebraic::convert ( const automaton::EpsilonNFA< SymbolType, StateType > &  automaton)
static

Performs the actual conversion.

Parameters
automatonThe automaton that is to be converted to the regular expression.
Returns
regular expression equivalent to the input automaton.

◆ convert() [2/3]

template<class SymbolType , class StateType >
regexp::UnboundedRegExp< SymbolType > automaton::convert::ToRegExpAlgebraic::convert ( const automaton::MultiInitialStateNFA< SymbolType, StateType > &  automaton)
static

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ convert() [3/3]

template<class T >
requires isDFA < T > || isNFA < T >
static regexp::UnboundedRegExp< typename T::SymbolType > automaton::convert::ToRegExpAlgebraic::convert ( const T &  automaton)
static

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.


The documentation for this class was generated from the following file: