12#ifndef MCRL2_PBES_SEARCH_STRATEGY_H
13#define MCRL2_PBES_SEARCH_STRATEGY_H
15#include "mcrl2/utilities/exception.h"
18namespace mcrl2::pbes_system
33 if (s ==
"breadth-first")
41 else if (s ==
"depth-first")
60 case breadth_first:
return "breadth-first";
61 case depth_first:
return "depth-first";
62 case breadth_first_short:
return "b";
63 case depth_first_short:
return "d";
65 throw mcrl2::runtime_error(
"unknown search strategy");
75 strategy = parse_search_strategy(s);
79 is.setstate(
std::ios_base::failbit);
87 os << print_search_strategy(s);
96 case breadth_first:
return "Compute the right hand side of the boolean variables"
97 " in a first come first served basis. This is comparable with a breadth-first search."
98 " This is good for generating counter examples. ";
99 case depth_first:
return "Compute the right hand side of a boolean variables where "
100 " the last generated variable is investigated first. This corresponds to a depth-first "
101 " search. This can substantially outperform breadth-first search when the validity of a"
102 " formula is determined at a larger depth. ";
103 case breadth_first_short:
return "Shorthand for breadth-first.";
104 case depth_first_short:
return "Shorthand for depth-first.";
106 throw mcrl2::runtime_error(
"unknown search strategy");
Standard exception class for reporting runtime errors.
search_strategy parse_search_strategy(const std::string &s)
std::string print_search_strategy(const search_strategy s)
std::istream & operator>>(std::istream &is, search_strategy &strategy)
search_strategy
Search strategy when generating a BES from a PBES.
std::string description(const search_strategy s)
std::size_t operator()(const std::vector< X > &v) const