Go to the source code of this file.
◆ fractalWalkConsistency()
WalkState fractalWalkConsistency |
( |
ring |
sring, |
|
|
ring |
dring, |
|
|
int * |
vperm |
|
) |
| |
Definition at line 221 of file walkProc.cc.
228 WerrorS(
"rings must have same characteristic" );
235 WerrorS(
"only works for global orderings" );
241 WerrorS(
"rings must have same number of variables" );
247 WerrorS(
"rings must have same number of parameters" );
251 if ( state !=
WalkOk )
return state;
256 int npar =
rPar(sring);
263 snames=sring->cf->extRing->names;
264 dnames=dring->cf->extRing->names;
265 pperm= (
int *)
omAlloc0( (npar+1)*
sizeof( int ) );
275 dring->names, nvar, dnames, npar, vperm, pperm,
278 for (
k= nvar; (
k > 0) && (state ==
WalkOk);
k-- )
281 WerrorS(
"variable names do not agree" );
285 for (
k= npar; (
k > 0) && (state ==
WalkOk);
k-- )
286 if ( pperm[
k-1] >= 0 )
288 WerrorS(
"parameter names do not agree" );
294 for (
k= nvar; (
k > 0) && (state ==
WalkOk);
k-- )
295 if ( vperm[
k] != (
k) )
297 WerrorS(
"orders of variables do not agree" );
302 for (
k= npar; (
k > 0) && (state ==
WalkOk);
k-- )
303 if ( pperm[
k-1] != (-
k) )
305 WerrorS(
"orders of parameters do not agree" );
312 if ( state !=
WalkOk )
return state;
315 if ( (sring->qideal !=
NULL) || (dring->qideal !=
NULL) )
317 WerrorS(
"rings are not allowed to be qrings");
322 while(dring->order[
i]!=0){
338 while(sring->order[
i]!=0)
void WerrorS(const char *s)
void maFindPerm(char const *const *const preim_names, int preim_n, char const *const *const preim_par, int preim_p, char const *const *const names, int n, char const *const *const par, int nop, int *perm, int *par_perm, n_coeffType ch)
#define omFreeSize(addr, size)
static int rPar(const ring r)
(r->cf->P)
static short rVar(const ring r)
#define rVar(r) (r->N)
BOOLEAN rHasLocalOrMixedOrdering(const ring r)
@ WalkIncompatibleDestRing
@ WalkIncompatibleSourceRing
◆ walkConsistency()
WalkState walkConsistency |
( |
ring |
sring, |
|
|
ring |
dring, |
|
|
int * |
vperm |
|
) |
| |
Definition at line 54 of file walkProc.cc.
61 WerrorS(
"rings must have same characteristic" );
67 WerrorS(
"only works for global orderings" );
70 else if ( sring->N != dring->N )
72 WerrorS(
"rings must have same number of variables" );
75 else if (
rPar(sring) !=
rPar(dring) )
77 WerrorS(
"rings must have same number of parameters" );
81 if ( state !=
WalkOk )
return state;
85 int nvar =
rVar(sring);
86 int npar =
rPar(sring);
92 snames=sring->cf->extRing->names;
93 dnames=dring->cf->extRing->names;
94 pperm= (
int *)
omAlloc0( (npar+1)*
sizeof( int ) );
104 dring->names, nvar, dnames, npar, vperm, pperm,
107 for (
k= nvar; (
k > 0) && (state ==
WalkOk);
k-- )
110 WerrorS(
"variable names do not agree" );
114 for (
k= npar-1; (
k >= 0) && (state ==
WalkOk);
k-- )
117 WerrorS(
"parameter names do not agree" );
122 for (
k= nvar; (
k > 0) && (state ==
WalkOk);
k-- )
123 if ( vperm[
k] != (
k) )
125 WerrorS(
"orders of variables do not agree" );
130 for (
k= npar; (
k > 0) && (state ==
WalkOk);
k-- )
132 if ( pperm[
k-1] != (-
k) )
134 WerrorS(
"orders of parameters do not agree" );
141 if ( state !=
WalkOk )
return state;
144 if ( (sring->qideal !=
NULL) || (dring->qideal !=
NULL) )
146 WerrorS(
"rings are not allowed to be qrings");
151 while(dring->order[
i]!=0)
171 while(sring->order[
i]!=0)
@ ringorder_a64
for int64 weights