Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
| Download
GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it
Project: cocalc-sagemath-dev-slelievre
Views: 4183461/**************************************************************************23enum02.c4Colin Ramsay ([email protected])525 Feb 0067ADVANCED COSET ENUMERATOR, Version 3.00189Copyright 200010Centre for Discrete Mathematics and Computing,11Department of Mathematics and12Department of Computer Science & Electrical Engineering,13The University of Queensland, QLD 4072.14(http://staff.itee.uq.edu.au/havas)1516To fully process all deductions properly we need to invoke the stack17clearing routine several times in _rpefn(). The following code allow us18to do this; it's equivalent to the `standard' code, but the loops have been19unrolled & jumps removed. This allows multiple copies to be included20without problems, although we still have to be careful about the variable21names used. The (local) variables used are: irow, icol, ires, rcol, first,22last, i, beg, end, ifront, iback, fwd, l, bwd, m, mi.2324**************************************************************************/2526while (topded >= 0)27{28INCR(cddproc);2930irow = dedrow[topded];31icol = dedcol[topded--];32if (COL1(irow) < 0)33{34INCR(cdddedn);35continue;36}37else38{39ires = CT(irow,icol);40rcol = invcol[icol];41}4243if ((first = edpbeg[icol]) >= 0)44{45last = edpend[icol];46for (i = first; i <= last; i += 2)47{48beg = &(relators[edp[i]]);49end = beg + edp[i+1]-1;5051ifront = l = ires;52iback = irow;5354for (fwd = beg+1; fwd <= end; fwd++)55{56if ((l = CT(ifront, *fwd)) > 0)57{ ifront = l; }58else59{ break; }60}6162if (l == 0)63{64for (bwd = end; bwd >= fwd; bwd--)65{66m = *bwd;67mi = invcol[m];6869if ((l = CT(iback, mi)) > 0)70{ iback = l; }71else if (bwd == fwd)72{73CT(iback, mi) = ifront;74CT(ifront, m) = iback;7576SAVED(iback, mi);77INCR(cddedn);78iback = ifront;79}80else81{82iback = ifront;83break;84}85}86}8788if (iback != ifront)89{90INCR(cdcoinc);9192if ((l = al0_coinc(ifront,iback,TRUE)) > 0)93{ return(l); }94if (COL1(irow) < 0 || COL1(ires) < 0)95{ break; }96}97}98}99100if (COL1(irow) >= 0 && COL1(ires) >= 0 && (irow != ires || icol != rcol))101{102if ((first = edpbeg[rcol]) >= 0)103{104last = edpend[rcol];105for (i = first; i <= last; i += 2)106{107beg = &(relators[edp[i]]);108end = beg + edp[i+1]-1;109110ifront = l = irow;111iback = ires;112113for (fwd = beg+1; fwd <= end; fwd++)114{115if ((l = CT(ifront, *fwd)) > 0)116{ ifront = l; }117else118{ break; }119}120121if (l == 0)122{123for (bwd = end; bwd >= fwd; bwd--)124{125m = *bwd;126mi = invcol[m];127128if ((l = CT(iback, mi)) > 0)129{ iback = l; }130else if (bwd == fwd)131{132CT(iback, mi) = ifront;133CT(ifront, m) = iback;134135SAVED(iback, mi);136INCR(cddedn);137iback = ifront;138}139else140{141iback = ifront;142break;143}144}145}146147if (iback != ifront)148{149INCR(cdcoinc);150151if ((l = al0_coinc(ifront,iback,TRUE)) > 0)152{ return(l); }153if (COL1(irow) < 0 || COL1(ires) < 0)154{ break; }155}156}157}158}159160#ifdef AL0_DD161if (msgctrl && --msgnext == 0)162{163msgnext = msgincr;164ETINT;165fprintf(fop, "DD: a=%d r=%d h=%d n=%d;", nalive, knr, knh, nextdf);166MSGMID;167fprintf(fop, " d=%d\n", topded+1);168BTINT;169}170#endif171}172173174175