15#ifndef MCRL2_DATA_BAG64_H
16#define MCRL2_DATA_BAG64_H
44 container_sort
bag(
const sort_expression& s)
46 container_sort
bag(bag_container(), s);
55 bool is_bag(
const sort_expression& e)
59 return container_sort(e).container_name() == bag_container();
103 application
constructor(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
114 void make_constructor(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
159 static_cast< void >(s);
190 return atermpp::down_cast<function_symbol>(e).name() ==
bag_fbag_name();
200 application
bag_fbag(
const sort_expression& s,
const data_expression& arg0)
210 void make_bag_fbag(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
262 application
bag_comprehension(
const sort_expression& s,
const data_expression& arg0)
272 void make_bag_comprehension(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
298 function_symbol count(
const sort_expression& ,
const sort_expression& s0,
const sort_expression& s1)
314 return f.name() ==
count_name() && atermpp::down_cast<function_sort>(f.sort()).domain().
size() == 2;
325 application
count(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
336 void make_count(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
362 function_symbol in(
const sort_expression& ,
const sort_expression& s0,
const sort_expression& s1)
378 return f.name() ==
in_name() && atermpp::down_cast<function_sort>(f.sort()).domain().
size() == 2;
389 application
in(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
400 void make_in(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
426 function_symbol union_(
const sort_expression& s,
const sort_expression& s0,
const sort_expression& s1)
429 if (s0 ==
bag(s) && s1 ==
bag(s))
447 throw mcrl2::runtime_error(
"Cannot compute target sort for union_ with domain sorts " +
pp(s0) +
", " +
pp(s1) +
". ");
463 return f.name() ==
union_name() && atermpp::down_cast<function_sort>(f.sort()).domain().
size() == 2;
474 application
union_(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
485 void make_union_(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
514 if (s0 ==
bag(s) && s1 ==
bag(s))
548 throw mcrl2::runtime_error(
"Cannot compute target sort for intersection with domain sorts " +
pp(s0) +
", " +
pp(s1) +
". ");
564 return f.name() ==
intersection_name() && atermpp::down_cast<function_sort>(f.sort()).domain().
size() == 2;
575 application
intersection(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
586 void make_intersection(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
615 if (s0 ==
bag(s) && s1 ==
bag(s))
641 throw mcrl2::runtime_error(
"Cannot compute target sort for difference with domain sorts " +
pp(s0) +
", " +
pp(s1) +
". ");
657 return f.name() ==
difference_name() && atermpp::down_cast<function_sort>(f.sort()).domain().
size() == 2;
668 application
difference(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
679 void make_difference(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
721 return atermpp::down_cast<function_symbol>(e).name() ==
bag2set_name();
731 application
bag2set(
const sort_expression& s,
const data_expression& arg0)
741 void make_bag2set(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
783 return atermpp::down_cast<function_symbol>(e).name() ==
set2bag_name();
793 application
set2bag(
const sort_expression& s,
const data_expression& arg0)
803 void make_set2bag(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
855 application
zero_function(
const sort_expression& s,
const data_expression& arg0)
865 void make_zero_function(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
917 application
one_function(
const sort_expression& s,
const data_expression& arg0)
927 void make_one_function(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
980 application
add_function(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
991 void make_add_function(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
1044 application
min_function(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
1055 void make_min_function(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
1108 application
monus_function(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
1119 void make_monus_function(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
1171 application
nat2bool_function(
const sort_expression& s,
const data_expression& arg0)
1181 void make_nat2bool_function(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
1233 application
bool2nat_function(
const sort_expression& s,
const data_expression& arg0)
1243 void make_bool2nat_function(data_expression& result,
const sort_expression& s,
const data_expression& arg0)
1285 return atermpp::down_cast<function_symbol>(e).name() ==
join_name();
1366 application
fbag_intersect(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1,
const data_expression&
arg2,
const data_expression&
arg3)
1379 void make_fbag_intersect(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1,
const data_expression&
arg2,
const data_expression&
arg3)
1434 application
fbag_difference(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1,
const data_expression&
arg2,
const data_expression&
arg3)
1447 void make_fbag_difference(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1,
const data_expression&
arg2,
const data_expression&
arg3)
1489 return atermpp::down_cast<function_symbol>(e).name() ==
fbag2fset_name();
1500 application
fbag2fset(
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
1511 void make_fbag2fset(data_expression& result,
const sort_expression& s,
const data_expression& arg0,
const data_expression&
arg1)
1553 return atermpp::down_cast<function_symbol>(e).name() ==
fset2fbag_name();
1630 result.push_back(f);
1679 static_cast< void >(s);
1688 const data_expression&
left(
const data_expression& e)
1691 return atermpp::down_cast<application>(e)[0];
1700 const data_expression&
right(
const data_expression& e)
1703 return atermpp::down_cast<application>(e)[1];
1712 const data_expression&
arg(
const data_expression& e)
1715 return atermpp::down_cast<application>(e)[0];
1724 const data_expression&
arg1(
const data_expression& e)
1727 return atermpp::down_cast<application>(e)[0];
1736 const data_expression&
arg2(
const data_expression& e)
1739 return atermpp::down_cast<application>(e)[1];
1748 const data_expression&
arg3(
const data_expression& e)
1751 return atermpp::down_cast<application>(e)[2];
1760 const data_expression&
arg4(
const data_expression& e)
1763 return atermpp::down_cast<application>(e)[3];
1782 variable vx(
"x",
bag(s));
1783 variable vy(
"y",
bag(s));
1788 result.push_back(data_equation(
variable_list({vb, ve, vf}),
count(s, ve,
constructor(s, vf, vb)),
sort_nat::swap_zero(vf(ve),
count(s, ve, vb))));
1790 result.push_back(data_equation(
variable_list({vb, vc, vf, vg}),
equal_to(
constructor(s, vf, vb),
constructor(s, vg, vc)),
if_(
equal_to(vf, vg),
equal_to(vb, vc), forall(
variable_list({vd}),
equal_to(
count(s, vd,
constructor(s, vf, vb)),
count(s, vd,
constructor(s, vg, vc)))))));
1793 result.push_back(data_equation(
variable_list({vb, vc, vf, vg}),
union_(s,
constructor(s, vf, vb),
constructor(s, vg, vc)),
constructor(s,
add_function(s, vf, vg),
join(s, vf, vg, vb, vc))));
1799 result.push_back(data_equation(
variable_list({vb, vc, vf, vg}),
intersection(s,
constructor(s, vf, vb),
constructor(s, vg, vc)),
constructor(s,
min_function(s, vf, vg),
fbag_intersect(s, vf, vg, vb, vc))));
1801 result.push_back(data_equation(
variable_list({vb, vd, vp, vx}),
intersection(s,
sort_fbag::cons_(s, vd, vp, vb), vx),
if_(
in(s, vd, vx),
sort_fbag::cons_(s, vd,
sort_nat::minimum(vp,
sort_nat::nat2pos(
count(s, vd, vx))),
intersection(s, vb, vx)),
intersection(s, vb, vx))));
1803 result.push_back(data_equation(
variable_list({vb, vc, vf, vg}),
difference(s,
constructor(s, vf, vb),
constructor(s, vg, vc)),
constructor(s,
monus_function(s, vf, vg),
fbag_difference(s, vf, vg, vb, vc))));
1805 result.push_back(data_equation(
variable_list({vb, vd, vp, vx}),
difference(s,
sort_fbag::cons_(s, vd, vp, vb), vx),
if_(
greater(
sort_nat::pos2nat(vp),
count(s, vd, vx)),
sort_fbag::cons_(s, vd,
sort_nat::nat2pos(
sort_nat::monus(
sort_nat::pos2nat(vp),
count(s, vd, vx))),
difference(s, vb, vx)),
difference(s, vb, vx))));
1806 result.push_back(data_equation(
variable_list({vb, vf}),
bag2set(s,
constructor(s, vf, vb)),
sort_set::constructor(s,
nat2bool_function(s, vf),
fbag2fset(s, vf, vb))));
1807 result.push_back(data_equation(
variable_list({vh, vs}),
set2bag(s,
sort_set::constructor(s, vh, vs)),
constructor(s,
bool2nat_function(s, vh),
fset2fbag(s, vs))));
1830 result.push_back(data_equation(
variable_list({vb, vd, vf, vg, vp}),
join(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::empty(s)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_add(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::c0()),
join(s, vf, vg, vb,
sort_fbag::empty(s)))));
1831 result.push_back(data_equation(
variable_list({vc, ve, vf, vg, vq}),
join(s, vf, vg,
sort_fbag::empty(s),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, ve,
sort_nat::swap_zero_add(vf(ve), vg(ve),
sort_nat::c0(),
sort_nat::pos2nat(vq)),
join(s, vf, vg,
sort_fbag::empty(s), vc))));
1832 result.push_back(data_equation(
variable_list({vb, vc, vd, vf, vg, vp, vq}),
join(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, vd, vq, vc)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_add(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::pos2nat(vq)),
join(s, vf, vg, vb, vc))));
1833 result.push_back(data_equation(
variable_list({vb, vc, vd, ve, vf, vg, vp, vq}),
less(vd, ve),
join(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_add(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::c0()),
join(s, vf, vg, vb,
sort_fbag::cons_(s, ve, vq, vc)))));
1834 result.push_back(data_equation(
variable_list({vb, vc, vd, ve, vf, vg, vp, vq}),
less(ve, vd),
join(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, ve,
sort_nat::swap_zero_add(vf(ve), vg(ve),
sort_nat::c0(),
sort_nat::pos2nat(vq)),
join(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb), vc))));
1836 result.push_back(data_equation(
variable_list({vb, vd, vf, vg, vp}),
fbag_intersect(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::empty(s)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_min(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::c0()),
fbag_intersect(s, vf, vg, vb,
sort_fbag::empty(s)))));
1837 result.push_back(data_equation(
variable_list({vc, ve, vf, vg, vq}),
fbag_intersect(s, vf, vg,
sort_fbag::empty(s),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, ve,
sort_nat::swap_zero_min(vf(ve), vg(ve),
sort_nat::c0(),
sort_nat::pos2nat(vq)),
fbag_intersect(s, vf, vg,
sort_fbag::empty(s), vc))));
1838 result.push_back(data_equation(
variable_list({vb, vc, vd, vf, vg, vp, vq}),
fbag_intersect(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, vd, vq, vc)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_min(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::pos2nat(vq)),
fbag_intersect(s, vf, vg, vb, vc))));
1839 result.push_back(data_equation(
variable_list({vb, vc, vd, ve, vf, vg, vp, vq}),
less(vd, ve),
fbag_intersect(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_min(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::c0()),
fbag_intersect(s, vf, vg, vb,
sort_fbag::cons_(s, ve, vq, vc)))));
1840 result.push_back(data_equation(
variable_list({vb, vc, vd, ve, vf, vg, vp, vq}),
less(ve, vd),
fbag_intersect(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, ve,
sort_nat::swap_zero_min(vf(ve), vg(ve),
sort_nat::c0(),
sort_nat::pos2nat(vq)),
fbag_intersect(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb), vc))));
1842 result.push_back(data_equation(
variable_list({vb, vd, vf, vg, vp}),
fbag_difference(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::empty(s)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_monus(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::c0()),
fbag_difference(s, vf, vg, vb,
sort_fbag::empty(s)))));
1843 result.push_back(data_equation(
variable_list({vc, ve, vf, vg, vq}),
fbag_difference(s, vf, vg,
sort_fbag::empty(s),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, ve,
sort_nat::swap_zero_monus(vf(ve), vg(ve),
sort_nat::c0(),
sort_nat::pos2nat(vq)),
fbag_difference(s, vf, vg,
sort_fbag::empty(s), vc))));
1844 result.push_back(data_equation(
variable_list({vb, vc, vd, vf, vg, vp, vq}),
fbag_difference(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, vd, vq, vc)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_monus(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::pos2nat(vq)),
fbag_difference(s, vf, vg, vb, vc))));
1845 result.push_back(data_equation(
variable_list({vb, vc, vd, ve, vf, vg, vp, vq}),
less(vd, ve),
fbag_difference(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, vd,
sort_nat::swap_zero_monus(vf(vd), vg(vd),
sort_nat::pos2nat(vp),
sort_nat::c0()),
fbag_difference(s, vf, vg, vb,
sort_fbag::cons_(s, ve, vq, vc)))));
1846 result.push_back(data_equation(
variable_list({vb, vc, vd, ve, vf, vg, vp, vq}),
less(ve, vd),
fbag_difference(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb),
sort_fbag::cons_(s, ve, vq, vc)),
sort_fbag::cinsert(s, ve,
sort_nat::swap_zero_monus(vf(ve), vg(ve),
sort_nat::c0(),
sort_nat::pos2nat(vq)),
fbag_difference(s, vf, vg,
sort_fbag::cons_(s, vd, vp, vb), vc))));
1848 result.push_back(data_equation(
variable_list({vb, vd, vf, vp}),
fbag2fset(s, vf,
sort_fbag::cons_(s, vd, vp, vb)),
sort_fset::cinsert(s, vd,
equal_to(
equal_to(vf(vd),
sort_nat::pos2nat(vp)),
greater(vf(vd),
sort_nat::c0())),
fbag2fset(s, vf, vb))));
1850 result.push_back(data_equation(
variable_list({vd, vs}),
fset2fbag(s,
sort_fset::cons_(s, vd, vs)),
sort_fbag::cinsert(s, vd,
sort_nat::pos2nat(
sort_pos::c1()),
fset2fbag(s, vs))));
Term containing a string.
size_type size() const
Returns the number of arguments of this term.
An application of a data expression to a number of arguments.
sort_expression sort() const
Returns the sort of the data expression.
Standard exception class for reporting runtime errors.
The class container_sort.
The class function symbol.
Exception classes for use in libraries and tools.
atermpp::aterm_string identifier_string
String type of the LPS library. Identifier strings are represented internally as ATerms.
function_symbol fbag2fset(const sort_expression &s)
Constructor for function symbol @fbag2fset.
bool is_bag2set_application(const atermpp::aterm &e)
Recogniser for application of Bag2Set.
bool is_intersection_function_symbol(const atermpp::aterm &e)
Recogniser for function *.
void make_bool2nat_function(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol @Bool2Nat_.
const core::identifier_string & fbag2fset_name()
Generate identifier @fbag2fset.
const data_expression & right(const data_expression &e)
Function for projecting out argument. right from an application.
bool is_min_function_function_symbol(const atermpp::aterm &e)
Recogniser for function @min_.
function_symbol bag_fbag(const sort_expression &s)
Constructor for function symbol @bagfbag.
bool is_min_function_application(const atermpp::aterm &e)
Recogniser for application of @min_.
function_symbol monus_function(const sort_expression &s)
Constructor for function symbol @monus_.
const core::identifier_string & fbag_intersect_name()
Generate identifier @fbag_inter.
void make_bag2set(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol Bag2Set.
bool is_fbag_difference_function_symbol(const atermpp::aterm &e)
Recogniser for function @fbag_diff.
void make_count(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol count.
const core::identifier_string & join_name()
Generate identifier @fbag_join.
function_symbol_vector bag_generate_functions_code(const sort_expression &s)
Give all system defined mappings for bag.
function_symbol fset2fbag(const sort_expression &s)
Constructor for function symbol @fset2fbag.
const core::identifier_string & bool2nat_function_name()
Generate identifier @Bool2Nat_.
void make_one_function(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol @one_.
const data_expression & arg3(const data_expression &e)
Function for projecting out argument. arg3 from an application.
bool is_difference_application(const atermpp::aterm &e)
Recogniser for application of -.
function_symbol difference(const sort_expression &s, const sort_expression &s0, const sort_expression &s1)
const core::identifier_string & set2bag_name()
Generate identifier Set2Bag.
bool is_bag_fbag_application(const atermpp::aterm &e)
Recogniser for application of @bagfbag.
function_symbol_vector bag_generate_constructors_and_functions_code(const sort_expression &s)
Give all system defined mappings and constructors for bag.
void make_add_function(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol @add_.
data_equation_vector bag_generate_equations_code(const sort_expression &s)
Give all system defined equations for bag.
const core::identifier_string & fset2fbag_name()
Generate identifier @fset2fbag.
bool is_fbag_difference_application(const atermpp::aterm &e)
Recogniser for application of @fbag_diff.
bool is_bag_fbag_function_symbol(const atermpp::aterm &e)
Recogniser for function @bagfbag.
const core::identifier_string & zero_function_name()
Generate identifier @zero_.
const core::identifier_string & add_function_name()
Generate identifier @add_.
function_symbol_vector bag_mCRL2_usable_constructors(const sort_expression &s)
Give all defined constructors which can be used in mCRL2 specs for bag.
bool is_fbag2fset_function_symbol(const atermpp::aterm &e)
Recogniser for function @fbag2fset.
bool is_union_application(const atermpp::aterm &e)
Recogniser for application of +.
function_symbol bag2set(const sort_expression &s)
Constructor for function symbol Bag2Set.
bool is_monus_function_application(const atermpp::aterm &e)
Recogniser for application of @monus_.
const core::identifier_string & nat2bool_function_name()
Generate identifier @Nat2Bool_.
function_symbol intersection(const sort_expression &s, const sort_expression &s0, const sort_expression &s1)
bool is_zero_function_application(const atermpp::aterm &e)
Recogniser for application of @zero_.
const core::identifier_string & fbag_difference_name()
Generate identifier @fbag_diff.
void make_monus_function(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol @monus_.
implementation_map bag_cpp_implementable_mappings(const sort_expression &s)
Give all system defined mappings that are to be implemented in C++ code for bag.
bool is_count_function_symbol(const atermpp::aterm &e)
Recogniser for function count.
function_symbol count(const sort_expression &, const sort_expression &s0, const sort_expression &s1)
implementation_map bag_cpp_implementable_constructors(const sort_expression &s)
Give all system defined constructors which have an implementation in C++ and not in rewrite rules for...
function_symbol add_function(const sort_expression &s)
Constructor for function symbol @add_.
bool is_nat2bool_function_application(const atermpp::aterm &e)
Recogniser for application of @Nat2Bool_.
function_symbol fbag_intersect(const sort_expression &s)
Constructor for function symbol @fbag_inter.
void make_fbag_intersect(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1, const data_expression &arg2, const data_expression &arg3)
Make an application of function symbol @fbag_inter.
bool is_union_function_symbol(const atermpp::aterm &e)
Recogniser for function +.
void make_nat2bool_function(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol @Nat2Bool_.
bool is_fbag_intersect_application(const atermpp::aterm &e)
Recogniser for application of @fbag_inter.
bool is_in_application(const atermpp::aterm &e)
Recogniser for application of in.
function_symbol fbag_difference(const sort_expression &s)
Constructor for function symbol @fbag_diff.
bool is_in_function_symbol(const atermpp::aterm &e)
Recogniser for function in.
bool is_bag_comprehension_function_symbol(const atermpp::aterm &e)
Recogniser for function @bagcomp.
void make_min_function(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol @min_.
const core::identifier_string & min_function_name()
Generate identifier @min_.
bool is_set2bag_function_symbol(const atermpp::aterm &e)
Recogniser for function Set2Bag.
const data_expression & left(const data_expression &e)
Function for projecting out argument. left from an application.
function_symbol_vector bag_mCRL2_usable_mappings(const sort_expression &s)
Give all system defined mappings that can be used in mCRL2 specs for bag.
bool is_nat2bool_function_function_symbol(const atermpp::aterm &e)
Recogniser for function @Nat2Bool_.
const core::identifier_string & monus_function_name()
Generate identifier @monus_.
const data_expression & arg4(const data_expression &e)
Function for projecting out argument. arg4 from an application.
bool is_add_function_application(const atermpp::aterm &e)
Recogniser for application of @add_.
void make_fbag2fset(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol @fbag2fset.
function_symbol min_function(const sort_expression &s)
Constructor for function symbol @min_.
function_symbol set2bag(const sort_expression &s)
Constructor for function symbol Set2Bag.
const core::identifier_string & bag_fbag_name()
Generate identifier @bagfbag.
const core::identifier_string & bag2set_name()
Generate identifier Bag2Set.
const core::identifier_string & intersection_name()
Generate identifier *.
void make_in(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol in.
bool is_fset2fbag_function_symbol(const atermpp::aterm &e)
Recogniser for function @fset2fbag.
function_symbol bag_comprehension(const sort_expression &s)
Constructor for function symbol @bagcomp.
bool is_bag2set_function_symbol(const atermpp::aterm &e)
Recogniser for function Bag2Set.
bool is_bool2nat_function_application(const atermpp::aterm &e)
Recogniser for application of @Bool2Nat_.
bool is_join_function_symbol(const atermpp::aterm &e)
Recogniser for function @fbag_join.
void make_intersection(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol *.
bool is_fset2fbag_application(const atermpp::aterm &e)
Recogniser for application of @fset2fbag.
function_symbol join(const sort_expression &s)
Constructor for function symbol @fbag_join.
bool is_constructor_application(const atermpp::aterm &e)
Recogniser for application of @bag.
bool is_zero_function_function_symbol(const atermpp::aterm &e)
Recogniser for function @zero_.
function_symbol constructor(const sort_expression &s)
Constructor for function symbol @bag.
const data_expression & arg2(const data_expression &e)
Function for projecting out argument. arg2 from an application.
const core::identifier_string & constructor_name()
Generate identifier @bag.
bool is_bag_comprehension_application(const atermpp::aterm &e)
Recogniser for application of @bagcomp.
bool is_set2bag_application(const atermpp::aterm &e)
Recogniser for application of Set2Bag.
function_symbol in(const sort_expression &, const sort_expression &s0, const sort_expression &s1)
void make_zero_function(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol @zero_.
const data_expression & arg1(const data_expression &e)
Function for projecting out argument. arg1 from an application.
void make_bag_fbag(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol @bagfbag.
function_symbol bool2nat_function(const sort_expression &s)
Constructor for function symbol @Bool2Nat_.
void make_set2bag(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol Set2Bag.
const core::identifier_string & union_name()
Generate identifier +.
bool is_fbag_intersect_function_symbol(const atermpp::aterm &e)
Recogniser for function @fbag_inter.
function_symbol union_(const sort_expression &s, const sort_expression &s0, const sort_expression &s1)
bool is_intersection_application(const atermpp::aterm &e)
Recogniser for application of *.
void make_bag_comprehension(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol @bagcomp.
const data_expression & arg(const data_expression &e)
Function for projecting out argument. arg from an application.
void make_join(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1, const data_expression &arg2, const data_expression &arg3)
Make an application of function symbol @fbag_join.
void make_fbag_difference(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1, const data_expression &arg2, const data_expression &arg3)
Make an application of function symbol @fbag_diff.
const core::identifier_string & count_name()
Generate identifier count.
void make_union_(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol +.
function_symbol nat2bool_function(const sort_expression &s)
Constructor for function symbol @Nat2Bool_.
bool is_one_function_application(const atermpp::aterm &e)
Recogniser for application of @one_.
const core::identifier_string & difference_name()
Generate identifier -.
bool is_bool2nat_function_function_symbol(const atermpp::aterm &e)
Recogniser for function @Bool2Nat_.
bool is_bag(const sort_expression &e)
Recogniser for sort expression Bag(s)
container_sort bag(const sort_expression &s)
Constructor for sort expression Bag(S)
bool is_difference_function_symbol(const atermpp::aterm &e)
Recogniser for function -.
bool is_fbag2fset_application(const atermpp::aterm &e)
Recogniser for application of @fbag2fset.
bool is_join_application(const atermpp::aterm &e)
Recogniser for application of @fbag_join.
std::map< function_symbol, std::pair< std::function< void(data_expression &, const data_expression &)>, std::string > > implementation_map
const core::identifier_string & in_name()
Generate identifier in.
bool is_constructor_function_symbol(const atermpp::aterm &e)
Recogniser for function @bag.
const core::identifier_string & bag_comprehension_name()
Generate identifier @bagcomp.
bool is_count_application(const atermpp::aterm &e)
Recogniser for application of count.
void make_difference(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol -.
const core::identifier_string & one_function_name()
Generate identifier @one_.
bool is_add_function_function_symbol(const atermpp::aterm &e)
Recogniser for function @add_.
void make_constructor(data_expression &result, const sort_expression &s, const data_expression &arg0, const data_expression &arg1)
Make an application of function symbol @bag.
function_symbol zero_function(const sort_expression &s)
Constructor for function symbol @zero_.
bool is_one_function_function_symbol(const atermpp::aterm &e)
Recogniser for function @one_.
function_symbol one_function(const sort_expression &s)
Constructor for function symbol @one_.
void make_fset2fbag(data_expression &result, const sort_expression &s, const data_expression &arg0)
Make an application of function symbol @fset2fbag.
function_symbol_vector bag_generate_constructors_code(const sort_expression &s)
Give all system defined constructors for bag.
bool is_monus_function_function_symbol(const atermpp::aterm &e)
Recogniser for function @monus_.
const basic_sort & bool_()
Constructor for sort expression Bool.
const function_symbol & and_()
Constructor for function symbol &&.
const function_symbol & false_()
Constructor for function symbol false.
container_sort fbag(const sort_expression &s)
Constructor for sort expression FBag(S)
function_symbol cons_(const sort_expression &s)
Constructor for function symbol @fbag_cons.
function_symbol empty(const sort_expression &s)
Constructor for function symbol {:}.
function_symbol cinsert(const sort_expression &s)
Constructor for function symbol @fbag_cinsert.
function_symbol cinsert(const sort_expression &s)
Constructor for function symbol @fset_cinsert.
function_symbol cons_(const sort_expression &s)
Constructor for function symbol @fset_cons.
function_symbol empty(const sort_expression &s)
Constructor for function symbol {}.
container_sort fset(const sort_expression &s)
Constructor for sort expression FSet(S)
function_symbol head(const sort_expression &s)
Constructor for function symbol head.
const function_symbol & one_word()
Constructor for function symbol @one_word.
const function_symbol & monus()
Constructor for function symbol @monus.
const function_symbol & c0()
Constructor for function symbol @c0.
const function_symbol & swap_zero_add()
Constructor for function symbol @swap_zero_add.
const basic_sort & nat()
Constructor for sort expression Nat.
const function_symbol & swap_zero()
Constructor for function symbol @swap_zero.
const function_symbol & swap_zero_min()
Constructor for function symbol @swap_zero_min.
function_symbol minimum(const sort_expression &s0, const sort_expression &s1)
const function_symbol & swap_zero_monus()
Constructor for function symbol @swap_zero_monus.
const function_symbol & nat2pos()
Constructor for function symbol Nat2Pos.
const function_symbol & most_significant_digit_nat()
Constructor for function symbol @most_significant_digitNat.
const function_symbol & auxiliary_plus_nat()
Constructor for function symbol @plus_nat.
const function_symbol & pos2nat()
Constructor for function symbol Pos2Nat.
const function_symbol & c1()
Constructor for function symbol @c1.
const basic_sort & pos()
Constructor for sort expression Pos.
function_symbol true_function(const sort_expression &s)
Constructor for function symbol @true_.
container_sort set_(const sort_expression &s)
Constructor for sort expression Set(S)
function_symbol constructor(const sort_expression &s)
Constructor for function symbol @set.
function_symbol false_function(const sort_expression &s)
Constructor for function symbol @false_.
function_symbol less_equal(const sort_expression &s)
Constructor for function symbol <=.
function_symbol not_equal_to(const sort_expression &s)
Constructor for function symbol !=.
function_symbol less(const sort_expression &s)
Constructor for function symbol <.
std::vector< data_equation > data_equation_vector
\brief vector of data_equations
function_sort make_function_sort_(const sort_expression &dom1, const sort_expression &codomain)
Convenience constructor for function sort with domain size 1.
std::string pp(const abstraction &x)
bool is_container_sort(const atermpp::aterm &x)
Returns true if the term t is a container sort.
bool is_function_symbol(const atermpp::aterm &x)
Returns true if the term t is a function symbol.
atermpp::term_list< variable > variable_list
\brief list of variables
function_symbol equal_to(const sort_expression &s)
Constructor for function symbol ==.
bool is_application(const atermpp::aterm &x)
Returns true if the term t is an application.
std::vector< function_symbol > function_symbol_vector
\brief vector of function_symbols
function_symbol if_(const sort_expression &s)
Constructor for function symbol if.
void make_application(atermpp::aterm &result)
Make function for an application.
function_symbol greater(const sort_expression &s)
Constructor for function symbol >
data::sort_expression target_sort(const data::sort_expression &s)
A class that takes a linear process specification and checks all tau-summands of that LPS for conflue...
Standard functions that are available for all sorts.