12#include "mcrl2/pbes/detail/has_propositional_variables.h"
13#include "mcrl2/pbes/detail/instantiate_global_variables.h"
14#include "mcrl2/pbes/detail/is_well_typed.h"
15#include "mcrl2/pbes/detail/occurring_variable_visitor.h"
16#include "mcrl2/pbes/is_bes.h"
17#include "mcrl2/pbes/parse_impl.h"
18#include "mcrl2/pbes/print.h"
19#include "mcrl2/pbes/translate_user_notation.h"
66 pbes_system::detail::instantiate_global_variables(p);
82 const std::set<data::sort_expression>& declared_sorts,
83 const std::set<data::variable>& declared_global_variables,
87 return pbes_system::detail::is_well_typed_equation(eqn, declared_sorts, declared_global_variables, data_spec);
91 const std::set<data::variable>& declared_global_variables,
92 const std::set<data::variable>& occurring_global_variables,
93 const std::set<propositional_variable>& declared_variables,
94 const std::set<propositional_variable_instantiation>& occ,
99 return pbes_system::detail::is_well_typed_pbes(declared_sorts, declared_global_variables, occurring_global_variables, declared_variables, occ, init, data_spec);
109 std::set<propositional_variable_instantiation> result;
110 for (
const pbes_equation& eqn: equations())
112 detail::occurring_variable_visitor f;
113 f.apply(eqn.formula());
114 result.insert(f.variables.begin(), f.variables.end());
124 unsigned int start_symbol_index = p.start_symbol_index(
"PbesExpr");
125 bool partial_parses =
false;
126 core::parse_node node = p.parse(text, start_symbol_index, partial_parses);
135 unsigned int start_symbol_index = p.start_symbol_index(
"PbesSpec");
136 bool partial_parses =
false;
137 core::parse_node node = p.parse(text, start_symbol_index, partial_parses);
153 unsigned int start_symbol_index = p.start_symbol_index(
"PropVarDecl");
154 bool partial_parses =
false;
155 core::parse_node node = p.parse(text, start_symbol_index, partial_parses);
162 unsigned int start_symbol_index = p.start_symbol_index(
"PbesExpr");
163 bool partial_parses =
false;
164 core::parse_node node = p.parse(text, start_symbol_index, partial_parses);
const pbes_expression & formula() const
Returns the predicate formula on the right hand side of the equation.
bool is_solved() const
Returns true if the predicate formula on the right hand side contains no predicate variables.
parameterized boolean equation system
std::set< propositional_variable_instantiation > occurring_variable_instantiations() const
Returns the set of occurring propositional variable instantiations of the pbes. This is the set of va...
\brief A propositional variable instantiation
\brief A propositional variable declaration
D_ParserTables parser_tables_mcrl2
void warn_and_or(const parse_node &)
Prints a warning for each occurrence of 'x && y || z' in the parse tree.
void instantiate_global_variables(pbes &p)
Attempts to eliminate the free variables of a PBES, by substituting a constant value for them....
bool is_bes(const pbes &x)
Returns true if a PBES is in BES form.
untyped_pbes parse_pbes_new(const std::string &text)
void complete_pbes(pbes &x)
bool has_propositional_variables(const pbes_expression &x)
propositional_variable parse_propositional_variable(const std::string &text)
pbes_expression parse_pbes_expression(const std::string &text)
bool is_well_typed(const pbes_equation &eqn)
Checks if the equation is well typed.
pbes_expression parse_pbes_expression_new(const std::string &text)
The main namespace for the PBES library.
std::set< data::variable > find_free_variables(const pbes_system::pbes_equation &x)
std::string pp(const pbes_system::propositional_variable_list &x, bool arg0)
std::string pp(const pbes_system::or_ &x, bool arg0)
std::set< data::variable > find_free_variables(const pbes_system::pbes &x)
void normalize_sorts(pbes_system::pbes_equation_vector &x, const data::sort_specification &sortspec)
std::string pp(const pbes_system::imp &x, bool arg0)
std::string pp(const pbes_system::propositional_variable_instantiation_list &x, bool arg0)
pbes_system::pbes_expression normalize_sorts(const pbes_system::pbes_expression &x, const data::sort_specification &sortspec)
std::set< data::sort_expression > find_sort_expressions(const pbes_system::pbes &x)
std::string pp(const pbes_system::pbes_equation_vector &x, bool arg0)
std::string pp(const pbes_system::pbes_expression_list &x, bool arg0)
std::set< pbes_system::propositional_variable_instantiation > find_propositional_variable_instantiations(const pbes_system::pbes_expression &x)
void normalize_sorts(pbes_system::pbes &x, const data::sort_specification &)
bool is_well_typed_pbes(const std::set< data::sort_expression > &declared_sorts, const std::set< data::variable > &declared_global_variables, const std::set< data::variable > &occurring_global_variables, const std::set< propositional_variable > &declared_variables, const std::set< propositional_variable_instantiation > &occ, const propositional_variable_instantiation &init, const data::data_specification &data_spec)
std::set< data::function_symbol > find_function_symbols(const pbes_system::pbes &x)
void typecheck_pbes(pbes &pbesspec)
Type check a parsed mCRL2 pbes specification. Throws an exception if something went wrong.
std::string pp(const pbes_system::propositional_variable &x, bool arg0)
std::string pp(const pbes_system::exists &x, bool arg0)
std::string pp(const pbes_system::pbes_expression &x, bool arg0)
bool is_well_typed(const pbes_equation &eqn)
std::set< data::variable > find_free_variables(const pbes_system::pbes_expression &x)
pbes_system::pbes_expression translate_user_notation(const pbes_system::pbes_expression &x)
bool search_variable(const pbes_system::pbes_expression &x, const data::variable &v)
std::set< data::variable > find_all_variables(const pbes_system::pbes &x)
std::string pp(const pbes_system::not_ &x, bool arg0)
void complete_data_specification(pbes &)
Adds all sorts that appear in the PBES p to the data specification of p.
std::string pp(const pbes_system::pbes_equation &x, bool arg0)
std::set< core::identifier_string > find_identifiers(const pbes_system::pbes_expression &x)
bool is_well_typed_equation(const pbes_equation &eqn, const std::set< data::sort_expression > &declared_sorts, const std::set< data::variable > &declared_global_variables, const data::data_specification &data_spec)
std::string pp(const pbes_system::propositional_variable_instantiation &x, bool arg0)
void translate_user_notation(pbes_system::pbes &x)
std::string pp(const pbes_system::pbes &x, bool arg0)
std::string pp(const pbes_system::and_ &x, bool arg0)
std::string pp(const pbes_system::fixpoint_symbol &x, bool arg0)
std::string pp(const pbes_system::forall &x, bool arg0)
pbes_system::propositional_variable parse_PropVarDecl(const core::parse_node &node) const
pbes_actions(const core::parser &parser_)
untyped_pbes parse_PbesSpec(const core::parse_node &node) const
pbes_system::pbes_expression parse_PbesExpr(const core::parse_node &node) const