Awali
Another Weighted Automata library
|
Implementation details of static layer (not stable). More...
Typedefs | |
template<typename T > | |
using | base_t = typename std::remove_cv< typename std::remove_reference< T >::type >::type |
T without reference or const/volatile qualifiers. More... | |
template<typename ValueSet > | |
using | context_of_t = typename context_of< ValueSet >::type |
template<typename LabelSet > | |
using | law_t = typename labelset_trait< LabelSet >::wordset_t |
template<typename Aut > | |
using | lifted_automaton_t = mutable_automaton< lifted_context_t< context_t_of< Aut > >> |
template<typename Context > | |
using | lifted_context_t = context< oneset, ratexpset_of< Context > > |
template<typename Exp > | |
using | lifted_ratexp_t = typename lifted_context_t< context_t_of< Exp > >::ratexp_t |
template<typename RatExpSet > | |
using | lifted_ratexpset_t = ratexpset< lifted_context_t< context_t_of< RatExpSet > >> |
template<typename Ctx > | |
using | word_context_t = context< law_t< labelset_t_of< Ctx > >, weightset_t_of< Ctx > > |
template<typename Ctx > | |
using | word_polynomialset_t = polynomialset< word_context_t< Ctx > > |
Functions | |
template<typename Aut > | |
Aut::element_type::automaton_nocv_t | absval (const Aut &aut) |
Copy of aut, with absolute values. More... | |
void | append (std::string &s, char c) |
void | append (std::string &s, const std::string t) |
template<typename Aut1 , typename Aut2 , typename P > | |
auto | are_equivalent_ (const Aut1 &aut1, const Aut2 &aut2, priority::FIVE< P >) -> typename std::enable_if<(labelset_t_of< Aut1 >::is_free() &&std::is_same< weightset_t_of< Aut1 >, b >::value &&labelset_t_of< Aut2 >::is_free() &&std::is_same< weightset_t_of< Aut2 >, b >::value), bool >::type |
Check equivalence between Boolean automata on a free labelset. More... | |
template<typename Aut1 , typename Aut2 , typename T > | |
auto | are_equivalent_ (const Aut1 &aut1, const Aut2 &aut2, priority::FOUR< T >) -> decltype(aut2->weightset() ->sub, aut2->weightset() ->zero, aut2->weightset() ->one, bool()) |
Check equivalence between automata on fields, or Z. More... | |
template<typename Aut1 , typename Aut2 , typename P > | |
bool | are_equivalent_ (const Aut1 &aut1, const Aut2 &aut2, priority::ONE< P >) |
template<typename Key , typename T , typename Hash , typename KeyEqual , typename Alloc > | |
size_t | collision_count (const std::unordered_map< Key, T, Hash, KeyEqual, Alloc > &m) |
Sum of bucket sizes. More... | |
template<size_t I, size_t J, typename Tuple1 , typename Tuple2 > | |
auto | concat_and_remove (const Tuple1 &t1, const Tuple2 &t2) -> typename std::concat_tuple< typename rem_in_tuple< I >::template type< Tuple1 >, typename rem_in_tuple< J >::template type< Tuple2 >>::type |
template<typename A , typename B , typename P > | |
A & | concatenate_here (A &res, B b, priority::ONE< P >) |
template<typename A , typename B , typename P > | |
auto | concatenate_here (A &res, B b, priority::TWO< P >) -> typename std::enable_if< labelset_t_of< A >::has_one(), A & >::type |
template<typename Fun > | |
void | cross (Fun f) |
Variadic Cartesian product of vectors. More... | |
template<typename Fun , typename H , typename... Ts> | |
void | cross (Fun f, std::vector< H > const &h, std::vector< Ts > const &... ts) |
template<typename... Sequences> | |
cross_sequences< Sequences... > | cross (Sequences &&... seqs) |
template<typename... Sequences> | |
cross_sequences< Sequences... > | cross_tuple (const std::tuple< Sequences... > &seqs) |
template<typename Fun , typename... Ts> | |
void | cross_tuple (Fun f, const std::tuple< Ts... > &ts) |
template<typename Fun , typename... Ts, size_t... I> | |
void | cross_tuple_ (Fun f, const std::tuple< Ts... > &ts, awali::internal::index_sequence< I... >) |
static int | debug_level () |
Debug level set in the user's environment. More... | |
double | evalf (const q_fraction_t &x) |
template<typename T > | |
T | evalf (const T &x) |
template<typename T , typename Alloc > | |
ATTRIBUTE_PURE auto | find (const std::vector< T, Alloc > &s, const T &e) -> typename std::vector< T, Alloc >::const_iterator |
Convenience wrapper around std::find. More... | |
template<size_t N> | |
auto | get_iterator (const std::bitset< N > &bs) -> bitset_iterator< N > |
template<typename T > | |
std::set< T > | get_union (const std::set< T > &set1, const std::set< T > &set2) |
template<typename T , typename Compare , typename Alloc > | |
std::set< T, Compare, Alloc > | get_union (const std::set< T, Compare, Alloc > &set1, const std::set< T, Compare, Alloc > &set2) |
The union of two sets. More... | |
template<typename Key , typename Value , typename Compare , typename Alloc > | |
bool | has (const std::map< Key, Value, Compare, Alloc > &s, const Key &e) |
template<typename T > | |
bool | has (const std::set< T > &s, const T &e) |
template<typename T , typename Compare , typename Alloc > | |
bool | has (const std::set< T, Compare, Alloc > &s, const T &e) ATTRIBUTE_PURE |
Whether e is member of s. More... | |
template<typename Key , typename T , typename Hash , typename KeyEqual , typename Alloc > | |
bool | has (const std::unordered_map< Key, T, Hash, KeyEqual, Alloc > &m, const Key &k) |
Whether e is member of m. More... | |
template<typename Key , typename Hash , typename KeyEqual , typename Alloc > | |
bool | has (const std::unordered_set< Key, Hash, KeyEqual, Alloc > &s, const Key &k) |
Whether e is member of s. More... | |
template<typename T , typename Alloc > | |
ATTRIBUTE_PURE bool | has (const std::vector< T, Alloc > &s, const T &e) |
Whether e is member of s. More... | |
template<typename Key , typename Value , typename Comp , typename Alloc > | |
std::set< typename std::map< Key, Value, Comp, Alloc >::mapped_type > | image (const std::map< Key, Value, Comp, Alloc > &m) |
The set of values of a map. More... | |
template<typename Aut > | |
void | initialize_partition (const Aut &aut, std::vector< std::vector< state_t > > &states_in_part) |
template<typename T > | |
std::set< T > | intersection (const std::set< T > &set1, const std::set< T > &set2) |
template<typename T , typename Compare , typename Alloc > | |
std::set< T, Compare, Alloc > | intersection (const std::set< T, Compare, Alloc > &set1, const std::set< T, Compare, Alloc > &set2) |
The intersection of two sets. More... | |
template<typename T > | |
std::set< std::set< T > > | intersection_closure (std::set< std::set< T >> pset) |
template<typename T , typename Compare , typename Alloc > | |
std::set< std::set< T, Compare, Alloc > > | intersection_closure (std::set< std::set< T, Compare, Alloc >> pset) |
The set of all the intersections of the sets in pset. More... | |
template<typename Aut > | |
bool | is_deterministic (const Aut &aut, state_t s) |
Whether state s is deterministic in aut. More... | |
template<typename WS , typename P > | |
constexpr bool | is_finite (const WS &, priority::ONE< P >) |
template<typename WS , typename P > | |
constexpr auto | is_finite (const WS &, priority::TWO< P >) -> typename WS::finite_t |
template<typename WS , typename P > | |
constexpr auto | is_locally_finite (const WS &, priority::TWO< P >) -> typename WS::locally_finite_t |
template<typename WS , typename P > | |
constexpr bool | is_locally_finite (const WS &ws, priority::ONE< P >) |
template<typename Aut > | |
constexpr std::enable_if<!labelset_t_of< Aut >::has_one(), bool >::type | is_proper_ (const Aut &) |
template<typename Aut > | |
std::enable_if< labelset_t_of< Aut >::has_one(), bool >::type | is_proper_ (const Aut &aut) |
template<size_t I, typename Tdc > | |
std::enable_if<!labelset_t_of< Tdc >::template valueset_t< I >::has_one(), bool >::type | is_proper_tape_ (const Tdc &) |
template<typename Tdc > | |
constexpr std::enable_if<!labelset_t_of< Tdc >::has_one(), bool >::type | is_proper_tape_ (const Tdc &) |
template<size_t I, typename Tdc > | |
std::enable_if< labelset_t_of< Tdc >::template valueset_t< I >::has_one(), bool >::type | is_proper_tape_ (const Tdc &tdc) |
template<typename Aut > | |
bool | is_properable (Aut &&aut) |
Whether proper_here(aut) succeeds. More... | |
template<typename Aut > | |
bool | is_sequential (const Aut &aut, state_t s) |
Whether state s is sequential in aut. More... | |
template<typename LabelSet , typename WeightSet > | |
lifted_context_t< context< LabelSet, WeightSet > > | lift_context (const context< LabelSet, WeightSet > &ctx) |
template<typename Context > | |
lifted_ratexpset_t< ratexpset< Context > > | lift_ratexpset (const ratexpset< Context > &rs) |
std::complex< double > | lr_parse_complex (std::string const &s, size_t &p, bool allow_empty=false, std::complex< double > value_if_empty={0, 0}) |
Reads a complex number left of position p in string, by using as many characters as possible. More... | |
char | lr_parse_dot (std::string const &s, size_t &p, bool allow_empty=true, char value_if_empty='\0') |
double | lr_parse_double (std::string const &s, size_t &p, bool allow_empty=false, double value_if_empty=0) |
Reads a double left of position p in string, by using as many characters as possible. More... | |
char | lr_parse_e (std::string const &s, size_t &p, bool allow_empty=true, char value_if_empty='\0') |
Parses the radix point. More... | |
int | lr_parse_int (std::string const &s, size_t &p, bool allow_empty=false, int value_if_empty=0) |
Reads an int written in decimal left of position p in string s , by using as many characters as possible Parameter p is decreased by the number of characters thus consumed. More... | |
char | lr_parse_one (std::string const &s, size_t &p, char const *t, bool allow_empty=false, char value_if_empty='\0') |
Checks whether there is in t left of position p in s . More... | |
q_fraction_t | lr_parse_qfraction (std::string const &s, size_t &p, bool allow_empty=false, q_fraction_t value_if_empty={1, 1}) |
Reads a q_fraction_t left of position p in string, by using as many characters as possible. More... | |
char | lr_parse_sign (std::string const &s, size_t &p, bool allow_empty=true, char value_if_empty='\0') |
unsigned | lr_parse_uint (std::string const &s, size_t &p, bool allow_empty=false, unsigned value_if_empty=0) |
Reads an unsigned int written in decimal left of position p in string s , by using as many character as possible Parameter p is decreased by the number of characters thus consumed. More... | |
unsigned | lr_scan_complex (std::string const &s, size_t &pp) |
unsigned | lr_scan_digits (std::string const &s, size_t &p) |
Scans for as many [0-9] digits as possible, left of position p in string s . More... | |
unsigned | lr_scan_dot (std::string const &s, size_t &p) |
unsigned | lr_scan_double (std::string const &s, size_t &pp) |
unsigned | lr_scan_e (std::string const &s, size_t &p) |
unsigned | lr_scan_int (std::string const &s, size_t &p) |
unsigned | lr_scan_one (std::string const &s, size_t &p, char const *t) |
Scans for a character in t left of position p in s . More... | |
unsigned | lr_scan_sign (std::string const &s, size_t &p) |
template<typename RandomGenerator = std::default_random_engine> | |
struct random_selector< RandomGenerator > | make_random_selector (const RandomGenerator &g) ATTRIBUTE_PURE |
template<typename LabelSet , typename WeightSet > | |
word_context_t< context< LabelSet, WeightSet > > | make_word_context (const context< LabelSet, WeightSet > &ctx) |
The wordset context of a labelset. More... | |
template<typename Ctx > | |
auto | make_word_polynomialset (const Ctx &ctx) -> word_polynomialset_t< Ctx > |
The polynomialset of words of a labelset (not necessarily on words itself). More... | |
template<typename LabelSet > | |
law_t< LabelSet > | make_wordset (const LabelSet &ls) |
The wordset of a labelset. More... | |
template<class Aut > | |
size_t | num_deterministic_states (const Aut &aut) |
Number of non-deterministic states. More... | |
static unsigned | powten (unsigned i) |
template<typename T > | |
std::ostream & | print (const std::set< T > &set, std::ostream &o) |
template<typename T , typename Compare , typename Alloc > | |
std::ostream & | print (const std::set< T, Compare, Alloc > &set, std::ostream &o) |
Print with a separator. Meant to help debugging. More... | |
template<typename Ctx > | |
mutable_automaton< Ctx > | random (const Ctx &ctx, unsigned num_states, float density=0.1, unsigned num_initial=1, unsigned num_final=1) |
template<typename Ctx > | |
mutable_automaton< Ctx > | random_deterministic (const Ctx &ctx, unsigned num_states) |
template<typename LabelSet , typename RandomGenerator = std::default_random_engine> | |
LabelSet::value_t | random_label (const LabelSet &ls, RandomGenerator &gen=RandomGenerator()) |
template<typename LabelSet , typename RandomGenerator = std::default_random_engine> | |
nullableset< LabelSet >::value_t | random_label (const nullableset< LabelSet > &ls, RandomGenerator &gen=RandomGenerator()) |
template<typename RandomGenerator = std::default_random_engine> | |
oneset::value_t | random_label (const oneset &ls, RandomGenerator &=RandomGenerator()) |
template<typename Context , typename RandomGenerator = std::default_random_engine> | |
ratexpset< Context >::value_t | random_label (const ratexpset< Context > &rs, RandomGenerator &gen=RandomGenerator()) |
template<typename... LabelSet, size_t... I, typename RandomGenerator = std::default_random_engine> | |
tupleset< LabelSet... >::value_t | random_label (const tupleset< LabelSet... > &ls, RandomGenerator &gen, awali::internal::index_sequence< I... >) |
template<typename... LabelSet, typename RandomGenerator = std::default_random_engine> | |
tupleset< LabelSet... >::value_t | random_label (const tupleset< LabelSet... > &ls, RandomGenerator &gen=RandomGenerator()) |
template<typename Aut , typename P > | |
Aut & | star_here (Aut &res, priority::ONE< P >) |
In place star of an automaton. More... | |
template<typename Aut , typename P > | |
auto | star_here (Aut &res, priority::TWO< P >) -> typename std::enable_if< labelset_t_of< Aut >::has_one(), Aut & >::type |
template<typename Container1 , typename Container2 > | |
bool | subset (const Container1 &set1, const Container2 &set2) ATTRIBUTE_PURE |
Whether set1 ⊆ set2. More... | |
template<typename A , typename B > | |
A & | sum_of_standard_here (A &res, const B &b) |
Merge transitions of b into those of res. More... | |
template<typename Cont > | |
std::vector< typename Cont::value_type > | to_vector (const Cont &cont) |
Return the content of cont as a vector. More... | |
template<typename Tuple > | |
auto | tuple_tail (const Tuple &t) -> typename tail_tuple< Tuple >::type |
template<typename Aut > | |
internal::lifted_automaton_t< Aut > | unnormalized_lift (const Aut &a, bool keep_history=true) |
template<typename WS , typename W1 , typename... W> | |
auto | variadic_mul (const WS &weightset, const W1 &w1, const W &... w) -> typename WS::value_t |
template<typename WS , typename W1 , typename W2 > | |
auto | variadic_mul (const WS &weightset, const W1 &w1, const W2 &w2) -> typename WS::value_t |
template<typename... Sequences> | |
zip_sequences< Sequences... > | zip (Sequences &&... seqs) |
template<typename Dereference = as_pair, typename... Maps> | |
zipped_maps< Dereference, Maps... > | zip_map_tuple (const std::tuple< Maps... > &maps) |
template<typename Dereference = as_pair, typename... Maps> | |
zipped_maps< Dereference, Maps... > | zip_maps (Maps &&... maps) |
template<typename... Sequences> | |
zip_sequences< Sequences... > | zip_tuple (const std::tuple< Sequences... > &seqs) |
Implementation details of static layer (not stable).
Append automaton b to res.
struct awali::sttc::internal::aff |
struct awali::sttc::internal::as_pair |
struct awali::sttc::internal::as_tuple |
struct awali::sttc::internal::concat_tupleset |
struct awali::sttc::internal::concat_tupleset< tupleset< T1... >, tupleset< T2... > > |
struct awali::sttc::internal::context_of |
struct awali::sttc::internal::context_of< sttc::mutable_automaton< Context > > |
struct awali::sttc::internal::context_t_of_impl |
struct awali::sttc::internal::label_t_of_impl |
struct awali::sttc::internal::labelset_t_of_impl |
struct awali::sttc::internal::labelset_types |
A traits so that tupleset may define types that may exist.
The types genset_t, letter_t, and word_t, exists only for tuples of labelsets, characterized as featuring a word_t type.
Data Fields | ||
---|---|---|
typedef void | genset_t | |
typedef void | letter_t | |
typedef void | word_t |
struct awali::sttc::internal::labelset_types< decltype(pass{typename ValueSets::word_t()...}, void()), ValueSets... > |
struct awali::sttc::internal::map_nullable |
struct awali::sttc::internal::multitupleset |
Data Fields | ||
---|---|---|
typedef typename concat_tupleset< tupleset< Labelset >, typename multitupleset< N-1, Labelset >::type >::type | type |
struct awali::sttc::internal::multitupleset< 1u, Labelset > |
Data Fields | ||
---|---|---|
typedef tupleset< Labelset > | type |
struct awali::sttc::internal::rem_in_tupleset |
struct awali::sttc::internal::replace_in_tupleset |
struct awali::sttc::internal::select_one |
struct awali::sttc::internal::select_tail |
struct awali::sttc::internal::selects |
struct awali::sttc::internal::state_eliminator |
struct awali::sttc::internal::tail_tuple |
struct awali::sttc::internal::tail_tuple< std::tuple< Head, Tail... > > |
struct awali::sttc::internal::tuple_to_tupleset |
struct awali::sttc::internal::tuple_to_tupleset< std::tuple< T... > > |
struct awali::sttc::internal::weight_t_of_impl |
struct awali::sttc::internal::weightset_t_of_impl |
using awali::sttc::internal::base_t = typedef typename std::remove_cv<typename std::remove_reference<T>::type>::type |
T without reference or const/volatile qualifiers.
using awali::sttc::internal::context_of_t = typedef typename context_of<ValueSet>::type |
using awali::sttc::internal::law_t = typedef typename labelset_trait<LabelSet>::wordset_t |
using awali::sttc::internal::lifted_automaton_t = typedef mutable_automaton<lifted_context_t<context_t_of<Aut> >> |
using awali::sttc::internal::lifted_context_t = typedef context<oneset, ratexpset_of<Context> > |
using awali::sttc::internal::lifted_ratexp_t = typedef typename lifted_context_t<context_t_of<Exp> >::ratexp_t |
using awali::sttc::internal::lifted_ratexpset_t = typedef ratexpset<lifted_context_t<context_t_of<RatExpSet> >> |
using awali::sttc::internal::word_context_t = typedef context<law_t<labelset_t_of<Ctx> >, weightset_t_of<Ctx> > |
using awali::sttc::internal::word_polynomialset_t = typedef polynomialset<word_context_t<Ctx> > |
Aut::element_type::automaton_nocv_t awali::sttc::internal::absval | ( | const Aut & | aut | ) |
Copy of aut, with absolute values.
Templated to avoid useless instantiations.
void awali::sttc::internal::append | ( | std::string & | s, |
char | c | ||
) |
void awali::sttc::internal::append | ( | std::string & | s, |
const std::string | t | ||
) |
auto awali::sttc::internal::are_equivalent_ | ( | const Aut1 & | aut1, |
const Aut2 & | aut2, | ||
priority::FIVE< P > | |||
) | -> typename std::enable_if<(labelset_t_of<Aut1>::is_free() && std::is_same<weightset_t_of<Aut1>, b>::value && labelset_t_of<Aut2>::is_free() && std::is_same<weightset_t_of<Aut2>, b>::value), bool>::type |
Check equivalence between Boolean automata on a free labelset.
auto awali::sttc::internal::are_equivalent_ | ( | const Aut1 & | aut1, |
const Aut2 & | aut2, | ||
priority::FOUR< T > | |||
) | -> decltype(aut2->weightset()->sub, aut2->weightset()->zero, aut2->weightset()->one, bool()) |
Check equivalence between automata on fields, or Z.
bool awali::sttc::internal::are_equivalent_ | ( | const Aut1 & | aut1, |
const Aut2 & | aut2, | ||
priority::ONE< P > | |||
) |
size_t awali::sttc::internal::collision_count | ( | const std::unordered_map< Key, T, Hash, KeyEqual, Alloc > & | m | ) |
Sum of bucket sizes.
auto awali::sttc::internal::concat_and_remove | ( | const Tuple1 & | t1, |
const Tuple2 & | t2 | ||
) | -> typename std::concat_tuple< typename rem_in_tuple<I>::template type<Tuple1>, typename rem_in_tuple<J>::template type<Tuple2>>::type |
A& awali::sttc::internal::concatenate_here | ( | A & | res, |
B | b, | ||
priority::ONE< P > | |||
) |
auto awali::sttc::internal::concatenate_here | ( | A & | res, |
B | b, | ||
priority::TWO< P > | |||
) | -> typename std::enable_if<labelset_t_of<A>::has_one(),A&>::type |
void awali::sttc::internal::cross | ( | Fun | f | ) |
Variadic Cartesian product of vectors.
void awali::sttc::internal::cross | ( | Fun | f, |
std::vector< H > const & | h, | ||
std::vector< Ts > const &... | ts | ||
) |
cross_sequences<Sequences...> awali::sttc::internal::cross | ( | Sequences &&... | seqs | ) |
cross_sequences<Sequences...> awali::sttc::internal::cross_tuple | ( | const std::tuple< Sequences... > & | seqs | ) |
void awali::sttc::internal::cross_tuple | ( | Fun | f, |
const std::tuple< Ts... > & | ts | ||
) |
void awali::sttc::internal::cross_tuple_ | ( | Fun | f, |
const std::tuple< Ts... > & | ts, | ||
awali::internal::index_sequence< I... > | |||
) |
|
static |
Debug level set in the user's environment.
double awali::sttc::internal::evalf | ( | const q_fraction_t & | x | ) |
T awali::sttc::internal::evalf | ( | const T & | x | ) |
ATTRIBUTE_PURE auto awali::sttc::internal::find | ( | const std::vector< T, Alloc > & | s, |
const T & | e | ||
) | -> typename std::vector<T, Alloc>::const_iterator |
Convenience wrapper around std::find.
auto awali::sttc::internal::get_iterator | ( | const std::bitset< N > & | bs | ) | -> bitset_iterator<N> |
std::set<T> awali::sttc::internal::get_union | ( | const std::set< T > & | set1, |
const std::set< T > & | set2 | ||
) |
std::set<T, Compare, Alloc> awali::sttc::internal::get_union | ( | const std::set< T, Compare, Alloc > & | set1, |
const std::set< T, Compare, Alloc > & | set2 | ||
) |
The union of two sets.
bool awali::sttc::internal::has | ( | const std::map< Key, Value, Compare, Alloc > & | s, |
const Key & | e | ||
) |
bool awali::sttc::internal::has | ( | const std::set< T > & | s, |
const T & | e | ||
) |
bool awali::sttc::internal::has | ( | const std::set< T, Compare, Alloc > & | s, |
const T & | e | ||
) |
Whether e is member of s.
bool awali::sttc::internal::has | ( | const std::unordered_map< Key, T, Hash, KeyEqual, Alloc > & | m, |
const Key & | k | ||
) |
Whether e is member of m.
bool awali::sttc::internal::has | ( | const std::unordered_set< Key, Hash, KeyEqual, Alloc > & | s, |
const Key & | k | ||
) |
Whether e is member of s.
ATTRIBUTE_PURE bool awali::sttc::internal::has | ( | const std::vector< T, Alloc > & | s, |
const T & | e | ||
) |
Whether e is member of s.
std::set< typename std::map< Key, Value, Comp, Alloc >::mapped_type > awali::sttc::internal::image | ( | const std::map< Key, Value, Comp, Alloc > & | m | ) |
The set of values of a map.
void awali::sttc::internal::initialize_partition | ( | const Aut & | aut, |
std::vector< std::vector< state_t > > & | states_in_part | ||
) |
std::set<T> awali::sttc::internal::intersection | ( | const std::set< T > & | set1, |
const std::set< T > & | set2 | ||
) |
std::set<T, Compare, Alloc> awali::sttc::internal::intersection | ( | const std::set< T, Compare, Alloc > & | set1, |
const std::set< T, Compare, Alloc > & | set2 | ||
) |
The intersection of two sets.
std::set<std::set<T> > awali::sttc::internal::intersection_closure | ( | std::set< std::set< T >> | pset | ) |
std::set<std::set<T, Compare, Alloc> > awali::sttc::internal::intersection_closure | ( | std::set< std::set< T, Compare, Alloc >> | pset | ) |
The set of all the intersections of the sets in pset.
bool awali::sttc::internal::is_deterministic | ( | const Aut & | aut, |
state_t | s | ||
) |
Whether state s is deterministic in aut.
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
std::enable_if<labelset_t_of<Aut>::has_one(), bool>::type awali::sttc::internal::is_proper_ | ( | const Aut & | aut | ) |
std::enable_if<!labelset_t_of<Tdc>::template valueset_t<I>::has_one(), bool>::type awali::sttc::internal::is_proper_tape_ | ( | const Tdc & | ) |
|
constexpr |
std::enable_if<labelset_t_of<Tdc>::template valueset_t<I>::has_one(), bool>::type awali::sttc::internal::is_proper_tape_ | ( | const Tdc & | tdc | ) |
bool awali::sttc::internal::is_properable | ( | Aut && | aut | ) |
Whether proper_here(aut) succeeds.
Destroys aut.
bool awali::sttc::internal::is_sequential | ( | const Aut & | aut, |
state_t | s | ||
) |
Whether state s is sequential in aut.
lifted_context_t<context<LabelSet, WeightSet> > awali::sttc::internal::lift_context | ( | const context< LabelSet, WeightSet > & | ctx | ) |
lifted_ratexpset_t<ratexpset<Context> > awali::sttc::internal::lift_ratexpset | ( | const ratexpset< Context > & | rs | ) |
std::complex<double> awali::sttc::internal::lr_parse_complex | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = false , |
||
std::complex< double > | value_if_empty = {0,0} |
||
) |
Reads a complex number left of position p
in string, by using as many characters as possible.
Acceptable format:
<double>
<double> i
<double> [+|-] <double without sign or empty> i
<double or empty> i [+|-] <double without sign>
Parameter p
is decreased by the number of characters used.
s | String in which the complex number is read. |
p | Position left of which the complex number is read; it is decreased by the number of character effectively used. |
allow_empty | Whether this function is allowed to read 0 characters; if set to false this function raises a parse_exception if it cannot read at least one valid character. Default is false . |
value_if_empty | Value returned if no character was consumed and allow_empty is true . Default is 1.0. |
char awali::sttc::internal::lr_parse_dot | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = true , |
||
char | value_if_empty = '\0' |
||
) |
double awali::sttc::internal::lr_parse_double | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = false , |
||
double | value_if_empty = 0 |
||
) |
Reads a double left of position p
in string, by using as many characters as possible.
Parameter p
is decreased by the number of characters used.
s | String in which the double is read. |
p | Position left of which the double is read; it is decreased by the number of character effectively used. |
allow_empty | Whether this function is allowed to read 0 characters; if set to false this function raises a parse_exception if it cannot read at least one valid character. Default is false . |
value_if_empty | Value returned if no character was consumed and allow_empty is true . Default is 1.0. |
char awali::sttc::internal::lr_parse_e | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = true , |
||
char | value_if_empty = '\0' |
||
) |
Parses the radix point.
int awali::sttc::internal::lr_parse_int | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = false , |
||
int | value_if_empty = 0 |
||
) |
Reads an int written in decimal left of position p
in string s
, by using as many characters as possible Parameter p
is decreased by the number of characters thus consumed.
s | String in which the int is read |
p | Position left of which the int is read; decreased by the number of character effectively used. |
allow_empty | Whether this function is allowed to read 0 characters; if set to false this function raises a parse_exception if it cannot read at least one valid character. |
value_if_empty | Value returned if no character was consumes and allow_empty is true . |
char awali::sttc::internal::lr_parse_one | ( | std::string const & | s, |
size_t & | p, | ||
char const * | t, | ||
bool | allow_empty = false , |
||
char | value_if_empty = '\0' |
||
) |
Checks whether there is in t
left of position p
in s
.
If a character is found, p
is modified accordingly (i.e., decreased by 1) and the found character is returned. If no such character is found: if allow_empty
is true
then returns value_if_empty
and p
is not modified, otherwise, an exception is raised.
value_if_empty
if none was found and allow_empty
is true. q_fraction_t awali::sttc::internal::lr_parse_qfraction | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = false , |
||
q_fraction_t | value_if_empty = {1,1} |
||
) |
Reads a q_fraction_t left of position p
in string, by using as many characters as possible.
Acceptable format:
<int> / <uint>
<int> . <uint>
Parameter p
is decreased by the number of characters used.s | String in which the q_fraction_t is read. |
p | Position left of which the q_fraction_t is read; it is decreased by the number of character effectively used. |
allow_empty | Whether this function is allowed to read 0 characters; if set to false this function raises a parse_exception if it cannot read at least one valid character. Default is false |
value_if_empty | Value returned if no character was consumes and allow_empty is true . Default is 1. |
char awali::sttc::internal::lr_parse_sign | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = true , |
||
char | value_if_empty = '\0' |
||
) |
unsigned awali::sttc::internal::lr_parse_uint | ( | std::string const & | s, |
size_t & | p, | ||
bool | allow_empty = false , |
||
unsigned | value_if_empty = 0 |
||
) |
Reads an unsigned int written in decimal left of position p
in string s
, by using as many character as possible Parameter p
is decreased by the number of characters thus consumed.
s | String in which the uint is read |
p | Position left of which the uint is read ; decreased by the number of character effectively used. |
allow_empty | Whether this function is allowed to read 0 characters; if set to false this function raises a parse_exception if it cannot read at least one valid character. |
value_if_empty | value returned if no characters and allow_empty is true . |
unsigned awali::sttc::internal::lr_scan_complex | ( | std::string const & | s, |
size_t & | pp | ||
) |
unsigned awali::sttc::internal::lr_scan_digits | ( | std::string const & | s, |
size_t & | p | ||
) |
Scans for as many [0-9] digits as possible, left of position p
in string s
.
Parameter p
is decreased by the amount of character scanned.
s | String to scan |
p | Position left of which the scan starts. |
unsigned awali::sttc::internal::lr_scan_dot | ( | std::string const & | s, |
size_t & | p | ||
) |
unsigned awali::sttc::internal::lr_scan_double | ( | std::string const & | s, |
size_t & | pp | ||
) |
unsigned awali::sttc::internal::lr_scan_e | ( | std::string const & | s, |
size_t & | p | ||
) |
unsigned awali::sttc::internal::lr_scan_int | ( | std::string const & | s, |
size_t & | p | ||
) |
unsigned awali::sttc::internal::lr_scan_one | ( | std::string const & | s, |
size_t & | p, | ||
char const * | t | ||
) |
Scans for a character in t
left of position p
in s
.
Returns 1 if both (p-1) is nonnegative and s[p-1] is in c-string t
; or returns 0 otherwise. Parameter p
is modified accordingly.
unsigned awali::sttc::internal::lr_scan_sign | ( | std::string const & | s, |
size_t & | p | ||
) |
struct random_selector< RandomGenerator > awali::sttc::internal::make_random_selector | ( | const RandomGenerator & | g | ) |
word_context_t<context<LabelSet, WeightSet> > awali::sttc::internal::make_word_context | ( | const context< LabelSet, WeightSet > & | ctx | ) |
The wordset context of a labelset.
auto awali::sttc::internal::make_word_polynomialset | ( | const Ctx & | ctx | ) | -> word_polynomialset_t<Ctx> |
The polynomialset of words of a labelset (not necessarily on words itself).
law_t<LabelSet> awali::sttc::internal::make_wordset | ( | const LabelSet & | ls | ) |
The wordset of a labelset.
size_t awali::sttc::internal::num_deterministic_states | ( | const Aut & | aut | ) |
Number of non-deterministic states.
|
static |
std::ostream& awali::sttc::internal::print | ( | const std::set< T > & | set, |
std::ostream & | o | ||
) |
std::ostream& awali::sttc::internal::print | ( | const std::set< T, Compare, Alloc > & | set, |
std::ostream & | o | ||
) |
Print with a separator. Meant to help debugging.
mutable_automaton<Ctx> awali::sttc::internal::random | ( | const Ctx & | ctx, |
unsigned | num_states, | ||
float | density = 0.1 , |
||
unsigned | num_initial = 1 , |
||
unsigned | num_final = 1 |
||
) |
mutable_automaton<Ctx> awali::sttc::internal::random_deterministic | ( | const Ctx & | ctx, |
unsigned | num_states | ||
) |
LabelSet::value_t awali::sttc::internal::random_label | ( | const LabelSet & | ls, |
RandomGenerator & | gen = RandomGenerator() |
||
) |
nullableset<LabelSet>::value_t awali::sttc::internal::random_label | ( | const nullableset< LabelSet > & | ls, |
RandomGenerator & | gen = RandomGenerator() |
||
) |
oneset::value_t awali::sttc::internal::random_label | ( | const oneset & | ls, |
RandomGenerator & | = RandomGenerator() |
||
) |
ratexpset<Context>::value_t awali::sttc::internal::random_label | ( | const ratexpset< Context > & | rs, |
RandomGenerator & | gen = RandomGenerator() |
||
) |
tupleset<LabelSet...>::value_t awali::sttc::internal::random_label | ( | const tupleset< LabelSet... > & | ls, |
RandomGenerator & | gen, | ||
awali::internal::index_sequence< I... > | |||
) |
tupleset<LabelSet...>::value_t awali::sttc::internal::random_label | ( | const tupleset< LabelSet... > & | ls, |
RandomGenerator & | gen = RandomGenerator() |
||
) |
Aut& awali::sttc::internal::star_here | ( | Aut & | res, |
priority::ONE< P > | |||
) |
In place star of an automaton.
auto awali::sttc::internal::star_here | ( | Aut & | res, |
priority::TWO< P > | |||
) | -> typename std::enable_if<labelset_t_of<Aut>::has_one(),Aut&>::type |
bool awali::sttc::internal::subset | ( | const Container1 & | set1, |
const Container2 & | set2 | ||
) |
Whether set1 ⊆ set2.
A& awali::sttc::internal::sum_of_standard_here | ( | A & | res, |
const B & | b | ||
) |
Merge transitions of b into those of res.
std::vector<typename Cont::value_type> awali::sttc::internal::to_vector | ( | const Cont & | cont | ) |
Return the content of cont as a vector.
auto awali::sttc::internal::tuple_tail | ( | const Tuple & | t | ) | -> typename tail_tuple<Tuple>::type |
internal::lifted_automaton_t<Aut> awali::sttc::internal::unnormalized_lift | ( | const Aut & | a, |
bool | keep_history = true |
||
) |
auto awali::sttc::internal::variadic_mul | ( | const WS & | weightset, |
const W1 & | w1, | ||
const W &... | w | ||
) | -> typename WS::value_t |
auto awali::sttc::internal::variadic_mul | ( | const WS & | weightset, |
const W1 & | w1, | ||
const W2 & | w2 | ||
) | -> typename WS::value_t |
zip_sequences<Sequences...> awali::sttc::internal::zip | ( | Sequences &&... | seqs | ) |
zipped_maps<Dereference, Maps...> awali::sttc::internal::zip_map_tuple | ( | const std::tuple< Maps... > & | maps | ) |
zipped_maps<Dereference, Maps...> awali::sttc::internal::zip_maps | ( | Maps &&... | maps | ) |
zip_sequences<Sequences...> awali::sttc::internal::zip_tuple | ( | const std::tuple< Sequences... > & | seqs | ) |