pbori_func.h
Go to the documentation of this file.
// -*- c++ -*-
//*****************************************************************************
//*****************************************************************************
#ifndef polybori_routines_pbori_func_h_
#define polybori_routines_pbori_func_h_
// get polybori definitions
#include <polybori/pbori_defs.h>
// get polybori properties
#include <polybori/common/traits.h>
// get standard string and string stream functionality
#include <string>
#include <sstream>
#ifdef PBORI_HAVE_TR1_UNORDERED_MAP
# include <tr1/unordered_map>
#else
# ifdef PBORI_HAVE_UNORDERED_MAP
# include <unordered_map>
# else
# ifdef PBORI_HAVE_HASH_MAP
# include <ext/hash_map>
# else
# include <map>
# endif
# endif
#endif
BEGIN_NAMESPACE_PBORI
template <class ListType, class ValueType = typename ListType::value_type >
class push_back {
public:
ListType
operator()(ListType theList, const ValueType& elt) const {
theList.push_back(elt);
return theList;
}
};
template <class RhsType, class LhsType = typename RhsType::idx_type >
class change_idx {
public:
RhsType operator() (const RhsType& rhs, const LhsType& lhs) const {
return (rhs.change(lhs));
}
};
template <class RhsType = void,
class LhsType = typename pbori_traits<RhsType>::idx_type >
class change_assign;
// default variant
template <class RhsType, class LhsType>
class change_assign {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
return (rhs = rhs.change(lhs));
}
};
// template specialization
template<>
class change_assign<void, pbori_traits<void>::idx_type> {
public:
template <class RhsType, class LhsType>
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
return (rhs = rhs.change(lhs));
}
};
template <class RhsType, class LhsType = typename RhsType::idx_type>
class subset1_assign {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs = rhs.subset1(lhs);
return rhs;
}
};
template <class RhsType, class LhsType>
class subset0_assign {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
return (rhs = rhs.subset0(lhs));
}
};
template <class RhsType,
class LhsType = typename pbori_traits<RhsType>::idx_type >
class unite_assign:
public std::binary_function<RhsType&, const LhsType&, RhsType&> {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
return (rhs = rhs.unite(lhs));
}
};
// @class project_ith
template <unsigned int ITH, unsigned int NLEN = ITH>
class project_ith;
template <unsigned int NLEN>
class project_ith<0, NLEN> {
public:
template <class ValueType>
void operator() (const ValueType&, ...) const { }
};
template <unsigned int NLEN>
class project_ith<1, NLEN> {
public:
template <class ValueType>
const ValueType& operator() (const ValueType& value, ...) const {
return value;
}
template <class ValueType>
ValueType& operator() (ValueType& value, ...) const {
return value;
}
};
template <unsigned int NLEN>
class project_ith<2, NLEN> {
public:
template <class FirstType, class ValueType>
const ValueType&
operator() (const FirstType&, const ValueType& value, ...) const {
return value;
}
template <class FirstType, class ValueType>
ValueType& operator() (const FirstType&, ValueType& value, ...) const {
return value;
}
};
template <unsigned int NLEN>
class project_ith<3, NLEN> {
public:
template <class FirstType, class SecondType, class ValueType>
const ValueType&
operator() (const FirstType&, const SecondType&,
const ValueType& value, ...) const {
return value;
}
template <class FirstType, class SecondType, class ValueType>
ValueType& operator() (const FirstType&, const SecondType&,
ValueType& value, ...) const {
return value;
}
};
/*
class print_all {
public:
print_all(std::ostream& os_):os(os_){}
template<class Type>
Type& operator()(Type& val){
std::copy(val.begin(), val.end(),
std::ostream_iterator<typename Type::value_type>(os, ", "));
return val;
}
std::ostream& os;
};
*/
class dummy_iterator {
public:
typedef dummy_iterator self;
template <class Type>
const self& operator=(const Type&) const { return *this;}
const self& operator*() const { return *this;}
const self& operator++() const { return *this;}
const self& operator++(int) const { return *this;}
};
template <>
class pbori_traits<dummy_iterator>:
public CTypes {
};
template <class IntType, IntType INTCONST, class ResultType = IntType>
struct integral_constant {
typedef ResultType result_type;
enum { result = INTCONST };
result_type operator()(...) const { return result; }
};
template <class BinaryOp, class FirstOp, class SecondOp>
class binary_composition:
public BinaryOp {
public:
typedef BinaryOp base;
typedef FirstOp first_op_type;
typedef SecondOp second_op_type;
// Constructor
binary_composition(const base& binop = base(),
const first_op_type& unop1 = first_op_type(),
const second_op_type& unop2 = second_op_type() ):
base(binop), first_op(unop1), second_op(unop2) {}
typedef typename base::result_type result_type;
template <class FirstType, class SecondType>
result_type operator()(const FirstType& first,
const SecondType& second) const {
return base::operator()(first_op(first), second_op(second));
}
template <class FirstType, class SecondType>
result_type operator()(FirstType& first,
const SecondType& second) const {
return base::operator()(first_op(first), second_op(second));
}
template <class FirstType, class SecondType>
result_type operator()(const FirstType& first,
SecondType& second) const {
return base::operator()(first_op(first), second_op(second));
}
protected:
first_op_type first_op;
second_op_type second_op;
};
template <class BinaryOp, class UnaryOperation>
class symmetric_composition:
public binary_composition<BinaryOp, UnaryOperation, UnaryOperation> {
public:
typedef BinaryOp binary_op_type;
typedef UnaryOperation unary_op_type;
typedef binary_composition<binary_op_type, unary_op_type, unary_op_type>
base;
// Constructor
symmetric_composition(const binary_op_type& binop = binary_op_type(),
const unary_op_type& unop = unary_op_type() ):
base(binop, unop, unop) {}
};
template<class ValueType>
class maximum_iteration {
public:
maximum_iteration(ValueType & init) : max(init){}
ValueType& operator()(const ValueType& val) const {
return max = std::max(max, val);
}
private:
ValueType & max;
};
template <class DDType>
class dd_add_assign {
public:
DDType& operator()(DDType& lhs, const DDType& rhs) const {
// several possible implementations
return
#if defined(PBORI_ADD_BY_OR)
(lhs = (lhs.diff(rhs)).unite(rhs.diff(lhs)));
# elif defined(PBORI_ADD_BY_UNION)
(lhs = lhs.unite(rhs).diff( lhs.intersect(rhs) ) );
# elif defined(PBORI_ADD_BY_EXTRA_XOR) || defined(PBORI_ADD_BY_XOR)
(lhs = lhs.Xor(rhs));
#endif
}
};
template <class DDType, class IdxType = typename DDType::idx_type>
class times_indexed_var {
public:
DDType& operator()(DDType& lhs, IdxType idx) const {
// get all terms not containing the variable with index idx
DDType tmp( lhs.subset0(idx) );
// get the complementary terms
lhs = lhs.diff(tmp);
// construct polynomial terms
dd_add_assign<DDType>()(lhs, tmp.change(idx));
return lhs;
}
};
template <class DDType, class IdxType = typename DDType::idx_type>
class append_indexed_divisor {
public:
DDType& operator()(DDType& lhs, IdxType idx) const {
lhs = lhs.unite( lhs.change(idx) );
return lhs;
}
};
// template <class RhsType = void,
// class LhsType = typename RhsType::value_type >
// class inserts:
// public std::binary_function<RhsType&, const LhsType&, RhsType&> {
// public:
// RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
// rhs.insert(lhs);
// return rhs;
// }
// };
template <class RhsType = void,
class LhsType = typename pbori_traits<RhsType>::idx_type >
class inserts;
template <class RhsType, class LhsType>
class inserts:
public std::binary_function<RhsType&, const LhsType&, RhsType&> {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.insert(lhs);
return rhs;
}
};
template <>
class inserts<void, pbori_traits<void>::idx_type> {
public:
template <class RhsType, class LhsType>
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.insert(lhs);
return rhs;
}
};
template <class RhsType = void,
class LhsType = typename pbori_traits<RhsType>::idx_type >
class insert_assign;
template <class RhsType, class LhsType>
class insert_assign:
public std::binary_function<RhsType&, const LhsType&, RhsType&> {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.insertAssign(lhs);
return rhs;
}
};
template <>
class insert_assign<void, pbori_traits<void>::idx_type> {
public:
template <class RhsType, class LhsType>
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.insertAssign(lhs);
return rhs;
}
};
template <class RhsType = void,
class LhsType = typename pbori_traits<RhsType>::idx_type >
class removes;
template <class RhsType, class LhsType>
class removes:
public std::binary_function<RhsType&, const LhsType&, RhsType&> {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.remove(lhs);
return rhs;
}
};
template <>
class removes<void, pbori_traits<void>::idx_type> {
public:
template <class RhsType, class LhsType>
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.remove(lhs);
return rhs;
}
};
template <class RhsType = void,
class LhsType = typename pbori_traits<RhsType>::idx_type >
class remove_assign;
template <class RhsType, class LhsType>
class remove_assign:
public std::binary_function<RhsType&, const LhsType&, RhsType&> {
public:
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.removeAssign(lhs);
return rhs;
}
};
template <>
class remove_assign<void, pbori_traits<void>::idx_type> {
public:
template <class RhsType, class LhsType>
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
rhs.removeAssign(lhs);
return rhs;
}
};
template <class ListType, class RhsType, class LhsType>
class insert_second_to_list {
public:
insert_second_to_list(ListType& theList__):
theList(theList__) {};
RhsType& operator() (RhsType& rhs, const LhsType& lhs) const {
theList.insert(lhs);
return rhs;
}
private:
ListType& theList;
};
template <class Type1, class Type2>
class is_same_type;
template <class Type>
class is_same_type<Type, Type>:
public integral_constant<CTypes::bool_type, true> {};
template <class Type1, class Type2>
class is_same_type:
public integral_constant<CTypes::bool_type, false> {};
template <class Type>
class is_valid:
public is_same_type<Type, valid_tag> {};
template <class Type1, class Type2, class ThenType, class ElseType>
class on_same_type;
template <class Type, class ThenType, class ElseType>
class on_same_type<Type, Type, ThenType, ElseType> {
public:
typedef ThenType type;
};
template <class Type1, class Type2, class ThenType, class ElseType>
class on_same_type {
public:
typedef ElseType type;
};
struct internal_tag {};
template<class Type>
struct type_tag {};
template <class Type>
class hashes {
public:
typedef typename Type::hash_type hash_type;
hash_type operator() (const Type& rhs) const{
return rhs.hash();
}
};
template <class Type>
class generate_index_map {
typedef typename Type::idx_type idx_type;
public:
#ifdef PBORI_HAVE_TR1_UNORDERED_MAP
typedef std::tr1::unordered_map<Type, idx_type, hashes<Type> > type;
#else
# ifdef PBORI_HAVE_UNORDERED_MAP
typedef std::unordered_map<Type, idx_type, hashes<Type> > type;
# else
# ifdef PBORI_HAVE_HASH_MAP
typedef __gnu_cxx::hash_map<Type, idx_type, hashes<Type> > type;
# else
typedef std::map<Type, idx_type> type;
# endif
# endif
#endif
};
template <class ListType>
class sizes_less:
public std::binary_function<const ListType&, const ListType&, bool> {
public:
bool operator()(const ListType& lhs, const ListType& rhs) const {
return (lhs.size() < rhs.size());
}
};
template <class BiIterator>
class reversed_iteration_adaptor {
public:
typedef BiIterator iterator;
typedef reversed_iteration_adaptor<iterator> self;
typedef std::bidirectional_iterator_tag iterator_category;
typedef typename std::iterator_traits<iterator>::difference_type
difference_type;
typedef typename std::iterator_traits<iterator>::pointer pointer;
typedef typename std::iterator_traits<iterator>::reference reference;
typedef typename std::iterator_traits<iterator>::value_type value_type;
reversed_iteration_adaptor(const iterator& iter):
m_iter(iter) {}
reference operator*() const {
return *m_iter;
}
self& operator++() {
--m_iter;
return *this;
}
self& operator--() {
++m_iter;
return *this;
}
bool operator==(const self& rhs) const {
return m_iter == rhs.m_iter;
}
bool operator!=(const self& rhs) const {
return m_iter != rhs.m_iter;
}
iterator get() const {
return m_iter;
}
protected:
iterator m_iter;
};
template <class DDType>
class navigates:
public std::unary_function<DDType, typename DDType::navigator> {
public:
typedef DDType dd_type;
typedef typename DDType::navigator navigator;
typedef std::unary_function<dd_type, navigator> base;
typename base::result_type operator()(const dd_type& rhs) const{
return rhs.navigation();
}
};
template <class ValueType>
class default_value {
public:
typedef ValueType value_type;
value_type operator()(...) const{
return value_type();
}
};
template <template<class> class BindType, class BinaryFunction,
class ValueType, class ConstantOp>
class constant_binder_base :
public BindType<BinaryFunction>{
public:
typedef BinaryFunction bin_op;
typedef ConstantOp const_type;
typedef BindType<bin_op> base;
typedef ValueType value_type;
constant_binder_base(const bin_op& op = bin_op()): base(op, const_type()()) {}
};
template <class BinaryFunction, class ConstantOp>
class constant_binder2nd :
public constant_binder_base<std::binder2nd, BinaryFunction,
typename BinaryFunction::second_argument_type,
ConstantOp> {
};
template <class BinaryFunction, class ConstantOp>
class constant_binder1st :
public constant_binder_base<std::binder1st, BinaryFunction,
typename BinaryFunction::first_argument_type,
ConstantOp> {
};
template <template<class> class BindType,
class BinaryFunction, class ValueType>
class default_binder_base :
public BindType<BinaryFunction>{
public:
typedef BinaryFunction bin_op;
typedef BindType<bin_op> base;
typedef ValueType value_type;
default_binder_base(const value_type& val): base(bin_op(), val) {}
};
template <class BinaryFunction>
class default_binder2nd :
public default_binder_base<std::binder2nd, BinaryFunction,
typename BinaryFunction::second_argument_type> {
public:
typedef default_binder_base<std::binder2nd, BinaryFunction,
typename BinaryFunction::second_argument_type>
base;
default_binder2nd(const typename base::value_type& val): base(val) {}
};
template <class BinaryFunction>
class default_binder1st :
public default_binder_base<std::binder1st, BinaryFunction,
typename BinaryFunction::first_argument_type> {
};
// /** @class property_owner
// * @brief defines generic base for properties
// **/
// template <class ValidityTag>
// class property_owner {
// public:
// /// Set marker for validity
// typedef typename
// on_same_type<ValidityTag, valid_tag, valid_tag, invalid_tag>::type property;
// /// Generate Boolean member function
// is_same_type<property, valid_tag> hasProperty;
// };
template <class ManagerType,
class IdxType = typename ManagerType::idx_type,
class VarNameType = typename ManagerType::const_varname_reference>
class variable_name {
public:
typedef ManagerType manager_type;
typedef IdxType idx_type;
typedef VarNameType varname_type;
variable_name(const manager_type& mgr): m_mgr(mgr) {}
varname_type operator()(idx_type idx) const{
return m_mgr.getVariableName(idx);
}
protected:
const manager_type& m_mgr;
};
template <class MapType, class VariableType, class TermType, class NodeType>
class mapped_new_node {
public:
typedef MapType map_type;
typedef NodeType node_type;
typedef typename node_type::idx_type idx_type;
mapped_new_node(const map_type& the_map): m_map(the_map) {}
NodeType operator()(idx_type idx,
const node_type& first, const node_type& second) const{
return ((TermType)VariableType(m_map[idx]))*first + second;
}
private:
const map_type& m_map;
};
template <class NewType>
struct pbori_base;
template <class DDType>
class get_node {
public:
typename DDType::node_type operator()(const DDType& rhs) const {
return rhs.getNode();
}
};
// template<unsigned ErrorNumber = CUDD_INTERNAL_ERROR>
// struct handle_error {
// typedef mgrcore_traits<Cudd>::errorfunc_type errorfunc_type;
// handle_error(errorfunc_type errfunc): m_errfunc(errfunc) {}
// bool found(unsigned err) const {
// if PBORI_UNLIKELY(err == ErrorNumber) {
// m_errfunc(cudd_error_traits<ErrorNumber>()());
// return true;
// }
// return false;
// }
// void operator()(unsigned err) const {
// if PBORI_UNLIKELY(err == ErrorNumber)
// m_errfunc(cudd_error_traits<ErrorNumber>()());
// else
// reinterpret_cast<const handle_error<ErrorNumber - 1>&>(*this)(err);
// }
// protected:
// const errorfunc_type m_errfunc;
// };
// template<>
// struct handle_error<0> {
// typedef mgrcore_traits<Cudd>::errorfunc_type errorfunc_type;
// handle_error(errorfunc_type errfunc): m_errfunc(errfunc) {}
// void operator()(unsigned err) const {
// if PBORI_LIKELY(err == 0)
// m_errfunc(cudd_error_traits<0>()());
// }
// protected:
// errorfunc_type m_errfunc;
// };
END_NAMESPACE_PBORI
#endif
polybori::symmetric_composition::binary_op_type
BinaryOp binary_op_type
Define types corresponding to template arguments.
Definition: pbori_func.h:332
polybori::binary_composition::result_type
base::result_type result_type
Getting inherited types.
Definition: pbori_func.h:293
polybori::variable_name::m_mgr
const manager_type & m_mgr
Store reference to manager.
Definition: pbori_func.h:851
polybori::get_node::operator()
DDType::node_type operator()(const DDType &rhs) const
Definition: pbori_func.h:889
polybori::mapped_new_node::node_type
NodeType node_type
Definition: pbori_func.h:858
polybori::dummy_iterator::operator++
const self & operator++(int) const
Definition: pbori_func.h:249
polybori::dd_add_assign
Defines addition operation with assignment for decision diagrams.
Definition: pbori_func.h:362
polybori::default_binder2nd::base
default_binder_base< std::binder2nd, BinaryFunction, typename BinaryFunction::second_argument_type > base
Definition: pbori_func.h:802
END_NAMESPACE_PBORI
#define END_NAMESPACE_PBORI
Finish project's namespace.
Definition: pbori_defs.h:77
polybori::binary_composition::operator()
result_type operator()(FirstType &first, const SecondType &second) const
The composed operation for constant second argument.
Definition: pbori_func.h:304
polybori::variable_name::varname_type
VarNameType varname_type
Definition: pbori_func.h:839
polybori::symmetric_composition::base
binary_composition< binary_op_type, unary_op_type, unary_op_type > base
Definition: pbori_func.h:335
polybori::hashes::hash_type
Type::hash_type hash_type
Definition: pbori_func.h:619
polybori::reversed_iteration_adaptor
Definition: pbori_func.h:665
polybori::variable_name::idx_type
IdxType idx_type
Definition: pbori_func.h:838
polybori::dummy_iterator
An iterator which virtually does nothing.
Definition: pbori_func.h:238
polybori::insert_assign
Accessing .insertAssign()
Definition: pbori_func.h:463
BEGIN_NAMESPACE_PBORI
#define BEGIN_NAMESPACE_PBORI
Start project's namespace.
Definition: pbori_defs.h:74
polybori::hashes
Definition: pbori_func.h:616
polybori::insert_second_to_list::insert_second_to_list
insert_second_to_list(ListType &theList__)
Definition: pbori_func.h:554
polybori::removes
Accessing .remove()
Definition: pbori_func.h:492
polybori::binary_composition::base
BinaryOp base
Define types corresponding to template arguments.
Definition: pbori_func.h:281
polybori::pbori_traits
This class contains property definitions to be used in polybori classes.
Definition: traits.h:41
polybori::default_value::operator()
value_type operator()(...) const
Definition: pbori_func.h:747
polybori::is_same_type
This class tests whether two types equal.
Definition: pbori_func.h:571
polybori::binary_composition::binary_composition
binary_composition(const base &binop=base(), const first_op_type &unop1=first_op_type(), const second_op_type &unop2=second_op_type())
Definition: pbori_func.h:287
polybori::inserts
Accessing .insert()
Definition: pbori_func.h:435
polybori::on_same_type
This class switches betweem two types, depending on equality of types.
Definition: pbori_func.h:589
polybori::default_binder_base::base
BindType< bin_op > base
Definition: pbori_func.h:788
polybori::reversed_iteration_adaptor::reference
std::iterator_traits< iterator >::reference reference
Definition: pbori_func.h:679
polybori::project_ith
Accessing ith of n arguments (ITH = 0 returns default value of first type)
Definition: pbori_func.h:144
polybori::dummy_iterator::operator*
const self & operator*() const
Definition: pbori_func.h:247
polybori::default_binder_base::value_type
ValueType value_type
Definition: pbori_func.h:790
polybori::push_back
Accessing .push_back()
Definition: pbori_func.h:48
polybori::mapped_new_node::map_type
MapType map_type
Definition: pbori_func.h:857
polybori::mapped_new_node::idx_type
node_type::idx_type idx_type
Definition: pbori_func.h:860
traits.h
polybori::symmetric_composition::symmetric_composition
symmetric_composition(const binary_op_type &binop=binary_op_type(), const unary_op_type &unop=unary_op_type())
Definition: pbori_func.h:339
polybori::navigates
Definition: pbori_func.h:722
polybori::integral_constant
integral_constant<int_type, NUM>()() returns NUM of int_type, instead of possibly arguments...
Definition: pbori_func.h:263
polybori::maximum_iteration
Returns maximun of given argument and previous calls.
Definition: pbori_func.h:347
polybori::constant_binder_base::bin_op
BinaryFunction bin_op
Definition: pbori_func.h:758
polybori::integral_constant::result_type
ResultType result_type
Definition: pbori_func.h:265
polybori::unite_assign
Accessing .uniteAssign()
Definition: pbori_func.h:126
polybori::dummy_iterator::operator++
const self & operator++() const
Definition: pbori_func.h:248
polybori::reversed_iteration_adaptor::reversed_iteration_adaptor
reversed_iteration_adaptor(const iterator &iter)
Constructor.
Definition: pbori_func.h:684
polybori::binary_composition::second_op
second_op_type second_op
Definition: pbori_func.h:318
polybori::type_tag
This class marks a given type.
Definition: pbori_func.h:613
polybori::pbori_base
Definition: pbori_func.h:881
polybori::maximum_iteration::maximum_iteration
maximum_iteration(ValueType &init)
Definition: pbori_func.h:349
polybori::constant_binder_base::constant_binder_base
constant_binder_base(const bin_op &op=bin_op())
Definition: pbori_func.h:764
polybori::default_value
Definition: pbori_func.h:743
pbori_defs.h
polybori::binary_composition::first_op
first_op_type first_op
Definition: pbori_func.h:317
polybori::mapped_new_node::mapped_new_node
mapped_new_node(const map_type &the_map)
Definition: pbori_func.h:862
polybori::constant_binder_base::base
BindType< bin_op > base
Definition: pbori_func.h:760
polybori::reversed_iteration_adaptor::iterator_category
std::bidirectional_iterator_tag iterator_category
Definition: pbori_func.h:675
polybori::navigates::operator()
base::result_type operator()(const dd_type &rhs) const
The actual operation.
Definition: pbori_func.h:735
polybori::generate_index_map
Definition: pbori_func.h:627
polybori::reversed_iteration_adaptor::operator!=
bool operator!=(const self &rhs) const
Definition: pbori_func.h:709
polybori::reversed_iteration_adaptor::m_iter
iterator m_iter
Definition: pbori_func.h:717
polybori::navigates::base
std::unary_function< dd_type, navigator > base
Generic access to base type.
Definition: pbori_func.h:732
polybori::remove_assign
Accessing .removeAssign()
Definition: pbori_func.h:522
polybori::reversed_iteration_adaptor::pointer
std::iterator_traits< iterator >::pointer pointer
Definition: pbori_func.h:678
polybori::binary_composition::operator()
result_type operator()(const FirstType &first, const SecondType &second) const
The composed operation for constant arguments.
Definition: pbori_func.h:297
polybori::get_node
Definition: pbori_func.h:886
polybori::symmetric_composition
Compose a binary function with a default constructable unary function for both arguments.
Definition: pbori_func.h:325
polybori::variable_name::variable_name
variable_name(const manager_type &mgr)
Constructor.
Definition: pbori_func.h:842
polybori::dd_add_assign::operator()
DDType & operator()(DDType &lhs, const DDType &rhs) const
Definition: pbori_func.h:365
polybori::default_binder_base::bin_op
BinaryFunction bin_op
Definition: pbori_func.h:787
polybori::change_assign
Accessing .changeAssign()
Definition: pbori_func.h:74
polybori::on_same_type::type
ElseType type
Definition: pbori_func.h:600
polybori::dummy_iterator::operator=
const self & operator=(const Type &) const
Definition: pbori_func.h:245
polybori::append_indexed_divisor
Defines multiplication (with assignment) with the idx-th variable.
Definition: pbori_func.h:404
polybori::reversed_iteration_adaptor::value_type
std::iterator_traits< iterator >::value_type value_type
Definition: pbori_func.h:680
polybori::constant_binder_base::value_type
ValueType value_type
Definition: pbori_func.h:762
polybori::reversed_iteration_adaptor::operator*
reference operator*() const
Dereferecing operation.
Definition: pbori_func.h:689
polybori::default_binder1st
Definition: pbori_func.h:809
polybori::binary_composition
Compose a binary function with two default constructable unary functions.
Definition: pbori_func.h:274
polybori::generate_index_map::type
std::map< Type, idx_type > type
Type for index maps.
Definition: pbori_func.h:642
polybori::default_binder2nd::default_binder2nd
default_binder2nd(const typename base::value_type &val)
Definition: pbori_func.h:804
polybori::mapped_new_node
Definition: pbori_func.h:855
polybori::reversed_iteration_adaptor::operator++
self & operator++()
Prefix increment operator.
Definition: pbori_func.h:694
polybori::binary_composition::second_op_type
SecondOp second_op_type
Definition: pbori_func.h:283
polybori::navigates::navigator
DDType::navigator navigator
Type for navigation through diagram.
Definition: pbori_func.h:729
polybori::maximum_iteration::operator()
ValueType & operator()(const ValueType &val) const
Definition: pbori_func.h:351
polybori::constant_binder2nd
Definition: pbori_func.h:768
polybori::internal_tag
This class marks an internal part of a procedure.
Definition: pbori_func.h:607
polybori::sizes_less
A functional for size comparisons.
Definition: pbori_func.h:652
polybori::default_value::value_type
ValueType value_type
Definition: pbori_func.h:745
polybori::insert_second_to_list
Insert second argument to a given list.
Definition: pbori_func.h:551
polybori::append_indexed_divisor::operator()
DDType & operator()(DDType &lhs, IdxType idx) const
Definition: pbori_func.h:407
polybori::binary_composition::first_op_type
FirstOp first_op_type
Definition: pbori_func.h:282
polybori::times_indexed_var
Defines multiplication operation with the idx-th variable.
Definition: pbori_func.h:382
polybori::default_binder_base
Definition: pbori_func.h:784
polybori::sizes_less::operator()
bool operator()(const ListType &lhs, const ListType &rhs) const
Definition: pbori_func.h:656
polybori::reversed_iteration_adaptor::iterator
BiIterator iterator
The iterator type to be reversed.
Definition: pbori_func.h:669
polybori::change_idx
Definition: pbori_func.h:61
polybori::groebner::idx_type
polybori::CTypes::idx_type idx_type
Definition: groebner_defs.h:44
polybori::variable_name::manager_type
ManagerType manager_type
Definition: pbori_func.h:837
polybori::constant_binder1st
Definition: pbori_func.h:776
polybori::reversed_iteration_adaptor::difference_type
std::iterator_traits< iterator >::difference_type difference_type
Definition: pbori_func.h:677
polybori::reversed_iteration_adaptor::operator--
self & operator--()
Prefix decrement operator.
Definition: pbori_func.h:700
polybori::push_back::operator()
ListType operator()(ListType theList, const ValueType &elt) const
Definition: pbori_func.h:52
polybori::on_same_type< Type, Type, ThenType, ElseType >::type
ThenType type
Definition: pbori_func.h:594
polybori::integral_constant::operator()
result_type operator()(...) const
Definition: pbori_func.h:267
polybori::constant_binder_base
Definition: pbori_func.h:755
polybori::symmetric_composition::unary_op_type
UnaryOperation unary_op_type
Definition: pbori_func.h:333
polybori::variable_name::operator()
varname_type operator()(idx_type idx) const
Funtional operator.
Definition: pbori_func.h:845
polybori::CTypes
This struct contains type definitions to be used in library classes.
Definition: pbori_defs.h:269
polybori::subset0_assign
Accessing .subset1Assign()
Definition: pbori_func.h:115
polybori::subset1_assign
Accessing .subset1Assign()
Definition: pbori_func.h:102
polybori::reversed_iteration_adaptor::operator==
bool operator==(const self &rhs) const
Definition: pbori_func.h:705
polybori::navigates::dd_type
DDType dd_type
Type of decision diagram.
Definition: pbori_func.h:726
polybori::constant_binder_base::const_type
ConstantOp const_type
Definition: pbori_func.h:759
polybori::binary_composition::operator()
result_type operator()(const FirstType &first, SecondType &second) const
The composed operation for constant first argument.
Definition: pbori_func.h:311
polybori::is_valid
Definition: pbori_func.h:582
polybori::default_binder2nd
Definition: pbori_func.h:796
polybori::times_indexed_var::operator()
DDType & operator()(DDType &lhs, IdxType idx) const
Definition: pbori_func.h:385
polybori::variable_name
Defines generic access to variable names.
Definition: pbori_func.h:835
polybori::default_binder_base::default_binder_base
default_binder_base(const value_type &val)
Definition: pbori_func.h:792
polybori::mapped_new_node::operator()
NodeType operator()(idx_type idx, const node_type &first, const node_type &second) const
Definition: pbori_func.h:864