14 template <Automaton Aut>
18 -> std::enable_if_t<!is_tropical<weightset_t_of<Aut>>::value,
25 template <Automaton Aut>
29 -> std::enable_if_t<is_tropical<weightset_t_of<Aut>>::value,
33 return res ? res->second : a->weightset()->zero();
41 template <Automaton Aut>
45 const auto& a = aut->as<Aut>();
47 const auto&
ctx = a->context();
weight weight_series(const automaton &aut)
Bridge.
std::shared_ptr< const detail::weight_base > weight
weight make_weight(const WeightSet &ws, const typename WeightSet::value_t &w)
auto path_monomial(const Aut &aut, const std::vector< transition_t_of< Aut >> &path, state_t_of< Aut > src=Aut::element_type::pre(), state_t_of< Aut > dst=Aut::element_type::post()) -> boost::optional< typename detail::word_polynomialset_t< context_t_of< Aut >>::monomial_t >
Given a path (typically computed by lightest_path), the corresponding monomial (label, weight).
typename detail::weight_t_of_impl< base_t< ValueSet >>::type weight_t_of
auto weight_series(const Aut &a) -> std::enable_if_t<!is_tropical< weightset_t_of< Aut >>::value, weight_t_of< Aut >>
auto eval(const Aut &a, const word_t_of< Aut > &w) -> std::enable_if_t<!context_t_of< Aut >::is_lao, weight_t_of< Aut >>
General case of evaluation.
std::shared_ptr< detail::automaton_base > automaton
auto to_spontaneous(const Aut &aut) -> std::enable_if_t<!context_t_of< Aut >::is_lao, decltype(make_mutable_automaton(make_context(oneset(), *aut->weightset())))>
to_spontaneous
static dyn::context ctx(const driver &d)
Get the context of the driver.
auto proper(const Aut &aut, direction dir=direction::backward, bool prune=true, const std::string &algo="auto") -> fresh_automaton_t_of< Aut, detail::proper_context< context_t_of< Aut >>>
Eliminate spontaneous transitions.
std::vector< transition_t_of< Aut > > lightest_path(const Aut &aut, state_t_of< Aut > source, state_t_of< Aut > dest, a_star_tag)