00001 // -*- c++ -*- 00002 //***************************************************************************** 00014 //***************************************************************************** 00015 00016 #ifndef polybori_groebner_MonomialPlusOneTerms_h_ 00017 #define polybori_groebner_MonomialPlusOneTerms_h_ 00018 00019 #include "TermsFacade.h" 00020 #include "PolyEntry.h" 00021 00022 // include basic definitions 00023 #include "groebner_defs.h" 00024 00025 BEGIN_NAMESPACE_PBORIGB 00026 00031 class MonomialPlusOneTerms: 00032 public TermsFacade<MonomialPlusOneTerms> { 00033 00034 public: 00035 template <class Type> 00036 MonomialPlusOneTerms(const Type& rhs): TermsFacade<MonomialPlusOneTerms>(rhs) {} 00037 00038 bool isCompatible(const PolyEntry& entry) const { 00039 PBORI_ASSERT( (entry.length != 2) || entry.p.isPair()); 00040 return (entry.length == 2) && (entry.p.hasConstantPart()); 00041 } 00042 }; 00043 00044 END_NAMESPACE_PBORIGB 00045 00046 #endif /* polybori_groebner_MonomialPlusOneTerms_h_ */