/* Firstly mark all definitions in the pc-presentation. */ for (j = Dimension[1] + 1; j <= NrPcGens; j++)
Conjugate[ Definition[j].h ][ Definition[j].g ] =
(word)((unsignedlong)
(Conjugate[Definition[j].h][Definition[j].g]) | 0x1);
/* Secondly new generators are defined. */ /* Powers */ for (j = 1; j <= NrPcGens; j++) if (Exponent[j] != (expo)0) {
G++;
l = 0; if (Power[j] != (word)0) l = WordLength(Power[ j ]);
w = (word)malloc((l + 2) * sizeof(gpower)); if (Power[j] != (word)0) WordCopy(Power[ j ], w);
w[l].g = G;
w[l].e = (expo)1;
w[l + 1].g = EOW;
w[l + 1].e = (expo)0; if (Power[ j ] != (word)0) free(Power[ j ]);
Power[ j ] = w;
Definition[ G ].h = j;
Definition[ G ].g = (gen)0; if (Verbose) {
printf("# generator %d = ", G);
printGen(j, 'A');
printf("^"EXP_FORMAT"\n", Exponent[j]);
}
}
/* Conjugates */ /* New/pseudo generators are only defined for commutators of the
** form [x,1], the rest is computed in Tails(). */ for (j = 1; j <= NrPcGens; j++) for (i = 1; i <= min(j - 1, Dimension[1]); i++) if (!((unsignedlong)(Conjugate[j][i]) & 0x1)) {
G++;
l = WordLength(Conjugate[ j ][ i ]);
w = (word)malloc((l + 2) * sizeof(gpower));
WordCopy(Conjugate[j][i], w);
w[l].g = G;
w[l].e = (expo)1;
w[l + 1].g = EOW;
w[l + 1].e = (expo)0; if (Conjugate[j][i] != Generators[j])
free(Conjugate[j][i]);
Conjugate[j][i] = w;
Definition[ G ].h = j;
Definition[ G ].g = i; if (Verbose) {
printf("# generator %d = [", G);
printGen(j, 'A');
printf(", ");
printGen(i, 'A');
printf("]\n");
}
}
if (G == NrPcGens) {
printf("## Warning : no new generators in addGenerators()\n"); return;
}
/* Thirdly remove the marks from the definitions.*/ for (j = Dimension[1] + 1; j <= NrPcGens; j++)
Conjugate[Definition[j].h][Definition[j].g] =
(word)((unsignedlong)
(Conjugate[Definition[j].h][Definition[j].g]) & ~0x1);
/* Fourthly enlarge the necessary arrays, so that the collector
works. */
/* Shrink Definition[] to the right size. */
Definition = (def*)realloc(Definition, (G + 1) * sizeof(def));
/* Enlarge Exponent[] ... */
Exponent = (expo *)realloc(Exponent, (G + 1) * sizeof(expo)); if (Exponent == (expo *)0) {
perror("addGenerators(), Exponent"); exit(2);
} for (i = NrPcGens + 1; i <= G; i++) Exponent[i] = (expo)0;
/* ... and Power[]. */
Power = (word *)realloc(Power, (G + 1) * sizeof(word)); if (Power == (word *)0) {
perror("addGenerators(), Power"); exit(2);
} for (i = NrPcGens + 1; i <= G; i++) Power[i] = (word)0;
Weight = (int *)realloc(Weight, (G + 1) * sizeof(long)); if (Weight == (int *)0) {
perror("addGenerators(), Weight"); exit(2);
} for (i = NrPcGens + 1; i <= G; i++) Weight[i] = Class + 1;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.