Definition at line 162 of file monomial-ordering.cpp.
164{
168 const int *wts;
169 bool all_one = true;
170 for (int i = 0; i < degs.size(); i++)
171 if (degs[i] <= 0)
172 {
173 ERROR(
"grevlex: expected all degrees to be positive");
174 return nullptr;
175 }
176 else if (degs[i] > 1)
177 all_one = false;
178
179 if (all_one)
180 {
181 if (packing == 2)
183 else if (packing == 4)
185 else
187 wts = nullptr;
188 }
189 else
190 {
191 if (packing == 2)
193 else if (packing == 4)
195 else
197 wts = degs.data();
198 }
199
204}
VALGRIND_MAKE_MEM_DEFINED & result(result)
static struct mon_part_rec_ * mo_make(enum MonomialOrdering_type type, int nvars, const int *wts)
static MonomialOrdering * make_mon_order(int n)
References ERROR, make_mon_order(), MO_GREVLEX, MO_GREVLEX2, MO_GREVLEX2_WTS, MO_GREVLEX4, MO_GREVLEX4_WTS, MO_GREVLEX_WTS, mo_make(), p, and result().