PolyBoRi
MonomialFactory.h
Go to the documentation of this file.
1 // -*- c++ -*-
2 //*****************************************************************************
15 //*****************************************************************************
16 
17 #ifndef polybori_factories_MonomialFactory_h_
18 #define polybori_factories_MonomialFactory_h_
19 
20 // include basic definitions
21 #include <polybori/pbori_defs.h>
23 #include <polybori/BooleMonomial.h>
24 
26 
34  public CFactoryBase {
36  typedef MonomialFactory self;
37 
39  typedef CFactoryBase base;
40 
41 public:
44 
47 
49  MonomialFactory(const parent_type& ring): base(ring) {}
50 
52  MonomialFactory(const self& rhs): base(rhs) {}
53 
56 
58  value_type operator()() const {
59  return value_type(parent());
60  }
61 
63  value_type operator()(const value_type::ring_type& ring) const {
64  return value_type(ring);
65  }
66 
68  value_type operator()(const value_type& rhs) const {
69  return rhs;
70  }
71 
73  value_type operator()(value_type::var_type var) const {
74  return value_type(var);
75  }
76 
78  value_type operator()(const value_type::exp_type& rhs) const {
79  return value_type(rhs, parent());
80  }
81 
83  value_type operator()(const value_type::exp_type& rhs,
84  const value_type::ring_type& ring) const {
85  return value_type(rhs, ring);
86  }
87 
88 };
89 
91 
92 #endif /* polybori_factories_MonomialFactory_h_ */
MonomialFactory(const parent_type &ring)
Construct from given ring.
Definition: MonomialFactory.h:49
This class is just a wrapper for using variables for storing indices as interim data structure for Bo...
Definition: BooleExponent.h:34
#define END_NAMESPACE_PBORI
Finish project's namespace.
Definition: pbori_defs.h:77
base::parent_type parent_type
Type of parent.
Definition: MonomialFactory.h:43
#define BEGIN_NAMESPACE_PBORI
Start project's namespace.
Definition: pbori_defs.h:74
This class reinterprets decicion diagram managers as Boolean polynomial rings, adds an ordering and v...
Definition: BoolePolyRing.h:40
value_type operator()(const value_type::ring_type &ring) const
Get first variable of explicit ring.
Definition: MonomialFactory.h:63
This base class CFactoryBase is used for currying other constructors with a BoolePolyRing.
Definition: CFactoryBase.h:35
BooleMonomial value_type
We construct element of this type.
Definition: MonomialFactory.h:46
value_type operator()(const value_type::exp_type &rhs, const value_type::ring_type &ring) const
Construct from exponent vector and explicit ring.
Definition: MonomialFactory.h:83
value_type operator()(const value_type &rhs) const
Indirect copy constructor.
Definition: MonomialFactory.h:68
value_type operator()(value_type::var_type var) const
Construct from Boolean variable (does not need ring)
Definition: MonomialFactory.h:73
value_type operator()(const value_type::exp_type &rhs) const
Construct from exponent vector.
Definition: MonomialFactory.h:78
This class is just a wrapper for using variables from cudd's decicion diagram.
Definition: BooleMonomial.h:50
value_type operator()() const
Get first variable of the ring.
Definition: MonomialFactory.h:58
This class is just a wrapper for using variables from cudd's decicion diagram.
Definition: BooleVariable.h:39
~MonomialFactory()
Destructor.
Definition: MonomialFactory.h:55
MonomialFactory(const self &rhs)
Copy constructor.
Definition: MonomialFactory.h:52
This base class MonomialFactory is used for currying monomial constructors with a BoolePolyRing...
Definition: MonomialFactory.h:33