12#ifndef MCRL2_PBES_ABSTRACT_H
13#define MCRL2_PBES_ABSTRACT_H
15#include "mcrl2/data/consistency.h"
16#include "mcrl2/pbes/builder.h"
17#include "mcrl2/pbes/detail/pbes_parameter_map.h"
45 for (
const data::variable_list& variables: m_quantifier_stack)
47 for (
const data::variable& w: variables)
61 m_quantifier_stack.push_back(variables);
67 m_quantifier_stack.pop_back();
74 std::set<data::variable> FV = data::find_free_variables(d);
75 for (
const data::variable& v: FV)
77 if (std::find(m_selected_variables.begin(), m_selected_variables.end(), v) == m_selected_variables.end())
83 result = atermpp::down_cast<pbes_expression>(m_value);
87 result = atermpp::down_cast<pbes_expression>(d);
96 apply(new_expression, x
.body());
107 apply(new_expression, x
.body());
125 const detail::pbes_parameter_map& parameter_map,
129 for (pbes_equation& eqn: p.equations())
131 auto j = parameter_map.find(eqn.variable().name());
132 if (j != parameter_map.end())
134 detail::pbes_abstract_builder builder(j->second, value_true);
135 pbes_expression result;
136 builder.apply(result, eqn.formula());
137 eqn.formula() = result;
data_expression(const data_expression &) noexcept=default
Move semantics.
\brief The existential quantification operator for pbes expressions
const data::variable_list & variables() const
const pbes_expression & body() const
\brief The universal quantification operator for pbes expressions
const pbes_expression & body() const
const data::variable_list & variables() const
Algorithm class for the abstract algorithm.
void run(pbes &p, const detail::pbes_parameter_map ¶meter_map, bool value_true)
Runs the algorithm.
parameterized boolean equation system
const data_expression & false_()
const data_expression & true_()
pbes_expression make_exists_(const data::variable_list &l, const pbes_expression &p)
Make an existential quantification. It checks for an empty variable list, which is not allowed.
pbes_expression make_forall_(const data::variable_list &l, const pbes_expression &p)
Make a universal quantification. It checks for an empty variable list, which is not allowed.
Visitor that implements the pbes-abstract algorithm.
bool is_bound(const data::variable &v) const
Returns true if the m_quantifier_stack contains a given data variable.
const data::data_expression m_value
pbes_abstract_builder(const std::vector< data::variable > &selected_variables, bool value_true)
void apply(T &result, const data::data_expression &d)
Visit data_expression node.
void apply(T &result, const exists &x)
Visit exists node.
void apply(T &result, const forall &x)
Visit forall node.
std::vector< data::variable_list > m_quantifier_stack
const std::vector< data::variable > m_selected_variables
void pop_variables()
Removes the last added sequence of variables from the quantifier stack.
void push_variables(const data::variable_list &variables)
Adds a sequence of variables to the quantifier stack.