diff options
Diffstat (limited to 'src/algebra')
32 files changed, 318 insertions, 325 deletions
diff --git a/src/algebra/aggcat.spad.pamphlet b/src/algebra/aggcat.spad.pamphlet index 12fa9485..3ed7ceca 100644 --- a/src/algebra/aggcat.spad.pamphlet +++ b/src/algebra/aggcat.spad.pamphlet @@ -2684,9 +2684,6 @@ BitAggregate(): Category == "not": % -> % ++ not(b) returns the logical {\em not} of bit aggregate ++ \axiom{b}. - "^" : % -> % - ++ ^ b returns the logical {\em not} of bit aggregate - ++ \axiom{b}. nand : (%, %) -> % ++ nand(a,b) returns the logical {\em nand} of bit aggregates \axiom{a} ++ and \axiom{b}. @@ -2705,7 +2702,6 @@ BitAggregate(): Category == add not v == map(_not, v) - _^ v == map(_not, v) _~(v) == map(_~, v) _/_\(v, u) == map(_/_\, v, u) _\_/(v, u) == map(_\_/, v, u) diff --git a/src/algebra/boolean.spad.pamphlet b/src/algebra/boolean.spad.pamphlet index 11a8dd35..ab33ba62 100644 --- a/src/algebra/boolean.spad.pamphlet +++ b/src/algebra/boolean.spad.pamphlet @@ -356,7 +356,7 @@ Logic: Category == BasicType with ++ Author: Stephen M. Watt ++ Date Created: ++ Change History: -++ Basic Operations: true, false, not, and, or, xor, nand, nor, implies, ^ +++ Basic Operations: true, false, not, and, or, xor, nand, nor, implies ++ Related Constructors: ++ Keywords: boolean ++ Description: \spadtype{Boolean} is the elementary logic with 2 values: @@ -367,8 +367,6 @@ Boolean(): Join(OrderedSet, Finite, Logic, PropositionalLogic, ConvertibleTo Inp ++ true is a logical constant. false: % ++ false is a logical constant. - _^ : % -> % - ++ ^ n returns the negation of n. xor : (%, %) -> % ++ xor(a,b) returns the logical exclusive {\em or} ++ of Boolean \spad{a} and b. @@ -388,7 +386,6 @@ Boolean(): Join(OrderedSet, Finite, Logic, PropositionalLogic, ConvertibleTo Inp false == NIL$Lisp sample() == true not b == (b => false; true) - _^ b == (b => false; true) _~ b == (b => false; true) _and(a, b) == (a => b; false) _/_\(a, b) == (a => b; false) diff --git a/src/algebra/color.spad.pamphlet b/src/algebra/color.spad.pamphlet index 56801bff..4a6b7387 100644 --- a/src/algebra/color.spad.pamphlet +++ b/src/algebra/color.spad.pamphlet @@ -74,7 +74,9 @@ Color(): Exports == Implementation where if (xHueSmaller:= (diff < 0)) then diff := -diff if (moreThanHalf:=(diff > totalHues quo 2)) then diff := totalHues-diff offset : I := wholePart(round (diff::SF/(2::SF)**(x.weight/y.weight)) ) - if (xHueSmaller and ^moreThanHalf) or (^xHueSmaller and moreThanHalf) then + if (xHueSmaller and not moreThanHalf) + or (not xHueSmaller and moreThanHalf) + then ans := x.hue + offset else ans := x.hue - offset diff --git a/src/algebra/ddfact.spad.pamphlet b/src/algebra/ddfact.spad.pamphlet index 97b8f811..f160ec23 100644 --- a/src/algebra/ddfact.spad.pamphlet +++ b/src/algebra/ddfact.spad.pamphlet @@ -191,7 +191,7 @@ DistinctDegreeFactorize(F,FP): C == T degree fprod = d => ris := cons(fprod,ris) aux:=[fprod] setPoly fprod - while ^(empty? aux) repeat + while not (empty? aux) repeat t := ranpol(2*d) if charF then t:=trace2PowMod(t,(n1*d-1)::NNI,fprod) else t:=exptMod(tracePowMod(t,(d-1)::NNI,fprod), diff --git a/src/algebra/fortran.spad.pamphlet b/src/algebra/fortran.spad.pamphlet index 92b1f238..f0c2cc29 100644 --- a/src/algebra/fortran.spad.pamphlet +++ b/src/algebra/fortran.spad.pamphlet @@ -974,7 +974,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where -- the first argument must be a symbol, which is either i,j or k -- to specify the direction in which the concatenation is to take place matrixConcat3D(dir : Symbol,mat1 : $,mat2 : $) : $ == - ^((dir = (i::Symbol)) or (dir = (j::Symbol)) or (dir = (k::Symbol)))_ + not ((dir = (i::Symbol)) or (dir = (j::Symbol)) or (dir = (k::Symbol)))_ => error "the axis of concatenation must be i,j or k" mat1Dim := matrixDimensions(mat1) mat2Dim := matrixDimensions(mat2) @@ -990,7 +990,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where if (dir = (i::Symbol)) then -- j,k dimensions must agree - if (^((jDim1 = jDim2) and (kDim1=kDim2))) + if (not ((jDim1 = jDim2) and (kDim1=kDim2))) then error "jxk do not agree" else @@ -998,7 +998,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where if (dir = (j::Symbol)) then -- i,k dimensions must agree - if (^((iDim1 = iDim2) and (kDim1=kDim2))) + if (not ((iDim1 = iDim2) and (kDim1=kDim2))) then error "ixk do not agree" else @@ -1010,7 +1010,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where if (dir = (k::Symbol)) then temp : (PA PA R) -- i,j dimensions must agree - if (^((iDim1 = iDim2) and (jDim1=jDim2))) + if (not ((iDim1 = iDim2) and (jDim1=jDim2))) then error "ixj do not agree" else @@ -1101,7 +1101,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where kLength2 := mat2Dims.3 -- check that the dimensions are the same - (^(iLength1 = iLength2) or ^(jLength1 = jLength2) or ^(kLength1 = kLength2))_ + (not (iLength1 = iLength2) or not (jLength1 = jLength2) or not(kLength1 = kLength2))_ => error "error the matrices are different sizes" sum : R @@ -1133,10 +1133,10 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where --first check that the matrix is in the correct form for subList in listRep repeat - ^((#subList)$(L L R) = jLength) => error_ + not((#subList)$(L L R) = jLength) => error_ "can not have an irregular shaped matrix" for subSubList in subList repeat - ^((#(subSubList))$(L R) = kLength) => error_ + not((#(subSubList))$(L R) = kLength) => error_ "can not have an irregular shaped matrix" row1 : (PA R) := new(kLength,((listRep.1).1).1)$(PA R) diff --git a/src/algebra/gaussfac.spad.pamphlet b/src/algebra/gaussfac.spad.pamphlet index 660d9f4c..25c6a2ab 100644 --- a/src/algebra/gaussfac.spad.pamphlet +++ b/src/algebra/gaussfac.spad.pamphlet @@ -72,7 +72,7 @@ GaussianFactorizationPackage() : C == T q1:=q-1 r:=q1 r1:=r exquo 4 - while ^(r1 case "failed") repeat + while not (r1 case "failed") repeat r:=r1::Z r1:=r exquo 2 s : FMod := reduce(1,q) diff --git a/src/algebra/gbeuclid.spad.pamphlet b/src/algebra/gbeuclid.spad.pamphlet index 660e9230..47857e87 100644 --- a/src/algebra/gbeuclid.spad.pamphlet +++ b/src/algebra/gbeuclid.spad.pamphlet @@ -189,7 +189,7 @@ EuclideanGroebnerBasisPackage(Dom, Expon, VarSet, Dpol): T == C where H:= Pol Pol1:= rest(Pol1) D:= nil - while ^null Pol1 repeat + while not null Pol1 repeat h:= first(Pol1) Pol1:= rest(Pol1) en:= degree(h) @@ -214,7 +214,7 @@ EuclideanGroebnerBasisPackage(Dom, Expon, VarSet, Dpol): T == C where -------- loop - while ^null D repeat + while not null D repeat D0:= first D ep:=esPol(D0) D:= rest(D) @@ -235,7 +235,7 @@ EuclideanGroebnerBasisPackage(Dom, Expon, VarSet, Dpol): T == C where #2.lcmfij) or (( #1.lcmfij = #2.lcmfij ) and ( sizeLess?(#1.lcmcij,#2.lcmcij)) ), dd1)), ecritBonD(eh,D)) Pol:= cons(eh,eupdatF(eh,Pol)) - ^ecrithinH(eh,H) or + not ecrithinH(eh,H) or ((e = degree(first(H))) and (leadingCoefficient(eh) = leadingCoefficient(first(H)) ) ) => if xx2 = 1 then ala:= prindINFO(D0,ep,eh,#H, #D, xx) @@ -420,15 +420,15 @@ EuclideanGroebnerBasisPackage(Dom, Expon, VarSet, Dpol): T == C where true ---------------------------- - --- crit B - true, if eik is a multiple of eh and eik ^equal - --- lcm(eh,ei) and eik ^equal lcm(eh,ek) + --- crit B - true, if eik is a multiple of eh and eik not equal + --- lcm(eh,ei) and eik not equal lcm(eh,ek) ecritB(eh:Expon, ch: Dom, ei:Expon, ci: Dom, ek:Expon, ck: Dom) == eik:= sup(ei, ek) cik:= lcm(ci, ck) ecritM(eh, ch, eik, cik) and - ^ecritM(eik, cik, sup(ei, eh), lcm(ci, ch)) and - ^ecritM(eik, cik, sup(ek, eh), lcm(ck, ch)) + not ecritM(eik, cik, sup(ei, eh), lcm(ci, ch)) and + not ecritM(eik, cik, sup(ek, eh), lcm(ck, ch)) ------------------------------- diff --git a/src/algebra/gbintern.spad.pamphlet b/src/algebra/gbintern.spad.pamphlet index 2c3d430f..830c34ea 100644 --- a/src/algebra/gbintern.spad.pamphlet +++ b/src/algebra/gbintern.spad.pamphlet @@ -124,7 +124,7 @@ GroebnerInternalPackage(Dom, Expon, VarSet, Dpol): T == C where basPols:= updatF(hMonic(first Pol1),virtualDegree(first Pol1),[]) Pol1:= rest(Pol1) D:= nil - while _^ null Pol1 repeat + while not null Pol1 repeat h:= hMonic(first(Pol1)) Pol1:= rest(Pol1) toth := virtualDegree h @@ -137,7 +137,7 @@ GroebnerInternalPackage(Dom, Expon, VarSet, Dpol): T == C where -------- loop redPols := [x.pol for x in basPols] - while _^ null D repeat + while not null D repeat D0:= first D s:= hMonic(sPol(D0)) D:= rest(D) @@ -261,7 +261,7 @@ GroebnerInternalPackage(Dom, Expon, VarSet, Dpol): T == C where redPo(s: Dpol, F: List(Dpol)) == m:Dom := 1 Fh := F - while _^ ( s = 0 or null F ) repeat + while not ( s = 0 or null F ) repeat f1:= first(F) s1:= degree(s) e: Union(Expon, "failed") @@ -291,8 +291,8 @@ GroebnerInternalPackage(Dom, Expon, VarSet, Dpol): T == C where ---------------------------- - --- crit B - true, if eik is a multiple of eh and eik ^equal - --- lcm(eh,ei) and eik ^equal lcm(eh,ek) + --- crit B - true, if eik is a multiple of eh and eik not equal + --- lcm(eh,ei) and eik not equal lcm(eh,ek) critB(eh:Expon, eik:Expon, ei:Expon, ek:Expon) == critM(eh, eik) and (eik ~= sup(eh, ei)) and (eik ~= sup(eh, ek)) diff --git a/src/algebra/ghensel.spad.pamphlet b/src/algebra/ghensel.spad.pamphlet index 5643e7e2..cf8ddb42 100644 --- a/src/algebra/ghensel.spad.pamphlet +++ b/src/algebra/ghensel.spad.pamphlet @@ -79,7 +79,7 @@ GeneralHenselPackage(RP,TP):C == T where maxd := +/[degree f for f in fln] quo 2 auxfl:List List TP := [] for poly in fln while factlist~=[] repeat - factlist := [term for term in factlist | ^member?(poly,term)] + factlist := [term for term in factlist | not member?(poly,term)] dp := degree poly for term in factlist repeat (+/[degree f for f in term]) + dp > maxd => "next term" @@ -148,9 +148,9 @@ GeneralHenselPackage(RP,TP):C == T where dfn := degree m aux := [] for poly in fln repeat - ^member?(poly,auxl) => aux := cons(poly,aux) - auxfl := [term for term in auxfl | ^member?(poly,term)] - factlist := [term for term in factlist |^member?(poly,term)] + not member?(poly,auxl) => aux := cons(poly,aux) + auxfl := [term for term in auxfl | not member?(poly,term)] + factlist := [term for term in factlist | not member?(poly,term)] fln := aux factlist := auxfl if dfn > 0 then finallist := cons(m,finallist) diff --git a/src/algebra/groebsol.spad.pamphlet b/src/algebra/groebsol.spad.pamphlet index a25c60d5..b689d991 100644 --- a/src/algebra/groebsol.spad.pamphlet +++ b/src/algebra/groebsol.spad.pamphlet @@ -137,7 +137,7 @@ GroebnerSolve(lv,F,R) : C == T findCompon(leq:L HDPoly,lvar:L OV):L L DPoly == teq:=totolex(leq) #teq = #lvar => [teq] - -- ^((teq1:=testGenPos(teq,lvar)) case "failed") => [teq1::L DPoly] + -- not ((teq1:=testGenPos(teq,lvar)) case "failed") => [teq1::L DPoly] gp:=genPos(teq,lvar) lgp:= gp.polys g:HDPoly:=gp.univp @@ -175,7 +175,7 @@ GroebnerSolve(lv,F,R) : C == T lnp:=[dmpToHdmp(f) for f in leq] leq1:=groebner lnp #(leq1) = 1 and first(leq1) = 1 => list empty() - ^(zeroDim?(leq1,lvar)) => + not (zeroDim?(leq1,lvar)) => error "system does not have a finite number of solutions" -- add computation of dimension, for a more useful error basis:=computeBasis(leq1) @@ -200,7 +200,7 @@ GroebnerSolve(lv,F,R) : C == T testDim(leq : L HDPoly,lvar : L OV) : Union(L HDPoly,"failed") == leq1:=groebner leq #(leq1) = 1 and first(leq1) = 1 => empty() - ^(zeroDim?(leq1,lvar)) => "failed" + not (zeroDim?(leq1,lvar)) => "failed" leq1 @ diff --git a/src/algebra/ideal.spad.pamphlet b/src/algebra/ideal.spad.pamphlet index 980cba38..fe5fb90a 100644 --- a/src/algebra/ideal.spad.pamphlet +++ b/src/algebra/ideal.spad.pamphlet @@ -196,7 +196,7 @@ PolynomialIdeals(F,Expon,VarSet,DPoly) : C == T n:= # leastVars #fullVars < n => error "wrong vars" n=0 => fullVars - append([vv for vv in fullVars| ^member?(vv,leastVars)],leastVars) + append([vv for vv in fullVars| not member?(vv,leastVars)],leastVars) isMonic?(f:DPoly,x:VarSet) : Boolean == ground? leadingCoefficient univariate(f,x) @@ -220,7 +220,7 @@ PolynomialIdeals(F,Expon,VarSet,DPoly) : C == T ldif:List VarSet:= lv for mvset in monvar while ldif ~=[] repeat ldif:=setDifference(mvset,subs) - if ^(empty? ldif) then return #subs + if not (empty? ldif) then return #subs 0 -- Exported Functions ---- @@ -244,7 +244,7 @@ PolynomialIdeals(F,Expon,VarSet,DPoly) : C == T ---- groebner base for an Ideal ---- groebner(I:Ideal) : Ideal == I.isGr => - "or"/[^zero? f for f in I.idl] => I + "or"/[not zero? f for f in I.idl] => I [empty(),true] [groebner I.idl ,true] @@ -314,7 +314,7 @@ PolynomialIdeals(F,Expon,VarSet,DPoly) : C == T J = [1] => false n:NNI := # lvar #J < n => false - for f in J while ^empty?(lvar) repeat + for f in J while not empty?(lvar) repeat x:=(mainVariable f)::VarSet if isMonic?(f,x) then lvar:=delete(lvar,position(x,lvar)) empty?(lvar) @@ -336,7 +336,8 @@ PolynomialIdeals(F,Expon,VarSet,DPoly) : C == T empty?(I.idl) => # lvar element?(1,I) => -1 truelist:="setUnion"/[variables f for f in I.idl] - "or"/[^member?(vv,lvar) for vv in truelist] => error "wrong variables" + "or"/[not member?(vv,lvar) for vv in truelist] => + error "wrong variables" truelist:=setDifference(lvar,setDifference(lvar,truelist)) ed:Z:=#lvar - #truelist leadid:=leadingIdeal(I) diff --git a/src/algebra/idecomp.spad.pamphlet b/src/algebra/idecomp.spad.pamphlet index 740d60de..fe8b86f6 100644 --- a/src/algebra/idecomp.spad.pamphlet +++ b/src/algebra/idecomp.spad.pamphlet @@ -121,7 +121,7 @@ IdealDecompositionPackage(vl,nv) : C == T -- take away nv, now doesn't nvint1:=(#lvint-1)::NNI deleteunit(lI: List FIdeal) : List FIdeal == - [I for I in lI | _^ element?(1$DPoly,I)] + [I for I in lI | not element?(1$DPoly,I)] rearrange(vlist:List OV) :List OV == vlist=[] => vlist @@ -162,7 +162,7 @@ IdealDecompositionPackage(vl,nv) : C == T -- take away nv, now doesn't f:DPoly:=s I:=groebner I J:=generators(JJ:= (saturate(I,s))) - while _^ in?(ideal([f*g for g in J]),I) repeat f:=s*f + while not in?(ideal([f*g for g in J]),I) repeat f:=s*f [f,JJ] ---- is the ideal zerodimensional? ---- @@ -176,7 +176,7 @@ IdealDecompositionPackage(vl,nv) : C == T -- take away nv, now doesn't f := Jd.first Jd:=Jd.rest if ((y:=mainVariable f) case "failed") or (y::OV ~=x ) - or _^ (ismonic (f,x)) then return false + or not (ismonic (f,x)) then return false while Jd~=[] and (mainVariable Jd.first)::OV=x repeat Jd:=Jd.rest if Jd=[] and position(x,truelist)<n then return false true @@ -227,7 +227,7 @@ IdealDecompositionPackage(vl,nv) : C == T -- take away nv, now doesn't for ef in lfact repeat g:DPoly:=(ef.factor)**(ef.exponent::NNI) J1:= groebnerIdeal(groebner cons(g,Jd)) - if _^ (is0dimprimary (J1,truelist)) then + if not (is0dimprimary (J1,truelist)) then return zeroPrimDecomp(I,truelist) ris:=cons(groebner backGenPos(J1,lval,truelist),ris) ris @@ -301,13 +301,13 @@ IdealDecompositionPackage(vl,nv) : C == T -- take away nv, now doesn't (i case "failed") => return true JR:=(reverse Jd);JM:=groebnerIdeal([JR.first]);JP:List(DPoly):=[] for f in JR.rest repeat - if _^ ismonic(f,truelist.i) then - if _^ inRadical?(f,JM) then return false + if not ismonic(f,truelist.i) then + if not inRadical?(f,JM) then return false JP:=cons(f,JP) else x:=truelist.i i:=(i-1)::NNI - if _^ testPower(univariate(f,x),x,JM) then return false + if not testPower(univariate(f,x),x,JM) then return false JM :=groebnerIdeal(append(cons(f,JP),generators JM)) true @@ -355,7 +355,7 @@ IdealDecompositionPackage(vl,nv) : C == T -- take away nv, now doesn't Jd:=generators J #Jd~=n => false for f in Jd repeat - if _^ ismonic(f,lvint.i) then return false + if not ismonic(f,lvint.i) then return false if i<n and (degree univariate(f,lvint.i))~=1 then return false i:=i+1 g:=Jd.n @@ -384,7 +384,8 @@ IdealDecompositionPackage(vl,nv) : C == T -- take away nv, now doesn't n:= # lvar #fullVars < n => error "wrong vars" n=0 => I - newVars:= append([vv for vv in fullVars| ^member?(vv,lvar)]$List(OV),lvar) + newVars:= append([vv for vv in fullVars + | not member?(vv,lvar)]$List(OV),lvar) subsVars := [monomial(1,vv,1)$DPoly1 for vv in newVars] lJ:= [eval(g,fullVars,subsVars) for g in Id] J := groebner(lJ) diff --git a/src/algebra/indexedp.spad.pamphlet b/src/algebra/indexedp.spad.pamphlet index 34d62e96..eb949535 100644 --- a/src/algebra/indexedp.spad.pamphlet +++ b/src/algebra/indexedp.spad.pamphlet @@ -64,7 +64,7 @@ IndexedDirectProductObject(A:SetCategory,S:OrderedSet): IndexedDirectProductCate s: S --define x = y == - while not null x and _^ null y repeat + while not null x and not null y repeat x.first.k ~= y.first.k => return false x.first.c ~= y.first.c => return false x:=x.rest diff --git a/src/algebra/listgcd.spad.pamphlet b/src/algebra/listgcd.spad.pamphlet index 2f4ccde4..a654bf61 100644 --- a/src/algebra/listgcd.spad.pamphlet +++ b/src/algebra/listgcd.spad.pamphlet @@ -68,7 +68,7 @@ HeuGcd (BP):C == T myNextPrime(val:Z,bound:NNI) : Z == nextPrime(val)$IntegerPrimesPackage(Z) - constNotZero(f : BP ) : Boolean == (degree f = 0) and ^(zero? f) + constNotZero(f : BP ) : Boolean == (degree f = 0) and not (zero? f) negShiftz(n:Z,Modulus:PI):Z == n < 0 => n:= n+Modulus @@ -100,7 +100,7 @@ HeuGcd (BP):C == T member?(1,lval) => 1$Z lval:=sort(#1<#2,lval) val:=lval.first - for val1 in lval.rest while ^(val=1) repeat val:=gcd(val,val1) + for val1 in lval.rest while not (val=1) repeat val:=gcd(val,val1) val --content for a list of univariate polynomials @@ -149,9 +149,9 @@ HeuGcd (BP):C == T --local function for the gcd among n PRIMITIVE univariate polynomials localgcd(listf:List BP ):List BP == - hgt:="min"/[height(f) for f in listf|^zero? f] + hgt:="min"/[height(f) for f in listf| not zero? f] answr:=2+2*hgt - minf := "mindegpol"/[f for f in listf|^zero? f] + minf := "mindegpol"/[f for f in listf| not zero? f] (result := testDivide(listf, minf)) case List(BP) => cons(minf, result::List BP) if degree minf < 100 then for k in 1..10 repeat diff --git a/src/algebra/mfinfact.spad.pamphlet b/src/algebra/mfinfact.spad.pamphlet index 2e3a3183..5bf284ef 100644 --- a/src/algebra/mfinfact.spad.pamphlet +++ b/src/algebra/mfinfact.spad.pamphlet @@ -388,7 +388,7 @@ MultFiniteFactorize(OV,E,F,PG) : C == T degum ~= degree newm or minimumDegree newm ~=0 => range:=range+1 lffc1:=content newm newm:=(newm exquo lffc1)::SUP R - testp and leadtest and ^ polCase(lffc1*clc,#plist,leadcomp1) + testp and leadtest and not polCase(lffc1*clc,#plist,leadcomp1) => range:=range+1 Dnewm := differentiate newm D2newm := map(differentiate, newm) @@ -418,7 +418,7 @@ MultFiniteFactorize(OV,E,F,PG) : C == T -- polCase if leadtest or ((norm unifact > norm [ff.factor for ff in lunivf]) and - (^testp or polCase(lffc1*clc,#plist,leadcomp1))) then + (not testp or polCase(lffc1*clc,#plist,leadcomp1))) then unifact:=[uf.factor for uf in lunivf] int:=lval lffc:=lffc1 @@ -435,10 +435,10 @@ MultFiniteFactorize(OV,E,F,PG) : C == T nfatt := nf nfatt>nf => -- for the previous values there were more factors - if testp then leadtest:=^polCase(lffc*clc,#plist,leadcomp) + if testp then leadtest := not polCase(lffc*clc,#plist,leadcomp) else leadtest:= false -- if polCase=true we can consider the univariate decomposition - if ^leadtest then + if not leadtest then unifact:=[uf.factor for uf in lunivf] lffc:=lffc1 if testp then leadcomp:=leadcomp1 diff --git a/src/algebra/modgcd.spad.pamphlet b/src/algebra/modgcd.spad.pamphlet index f93e1898..4edd4475 100644 --- a/src/algebra/modgcd.spad.pamphlet +++ b/src/algebra/modgcd.spad.pamphlet @@ -77,7 +77,7 @@ InnerModularGcd(R,BP,pMod,nextMod):C == T modularGcdPrimitive(listf : List BP) :BP == empty? listf => 0$BP g := first listf - for f in rest listf | ^zero? f while degree g > 0 repeat + for f in rest listf | not zero? f while degree g > 0 repeat g:=modGcdPrimitive(g,f) g @@ -159,8 +159,8 @@ InnerModularGcd(R,BP,pMod,nextMod):C == T dp:=gcd(fp,gp) dgp :=euclideanSize dp if dgp =0 then return 1$BP - if dgp=dg and ^(f exquo g case "failed") then return g - if dgp=df and ^(g exquo f case "failed") then return f + if dgp=dg and not (f exquo g case "failed") then return g + if dgp=df and not (g exquo f case "failed") then return f dgp > testdeg => "next prime" ldp:FP:= ((lcdp:=leadingCoefficient(dp::BP)) = 1) => @@ -184,7 +184,7 @@ InnerModularGcd(R,BP,pMod,nextMod):C == T soFarModulus:=prime soFar:=dp::BP testdeg:=dgp - if ^zeroChar and euclideanSize(prime)>1 then + if not zeroChar and euclideanSize(prime)>1 then result:=dp::BP test(f,g,result) => return result -- this is based on the assumption that the caller of this package, diff --git a/src/algebra/multfact.spad.pamphlet b/src/algebra/multfact.spad.pamphlet index 0aa0bb59..8e5cf942 100644 --- a/src/algebra/multfact.spad.pamphlet +++ b/src/algebra/multfact.spad.pamphlet @@ -223,7 +223,7 @@ InnerMultFact(OV,E,R,P) : C == T degum ~= degree newm or minimumDegree newm ~=0 => range:=2*range lffc1:=content newm newm:=(newm exquo lffc1)::BP - testp and leadtest and ^ polCase(lffc1*clc,#plist,leadcomp1) + testp and leadtest and not polCase(lffc1*clc,#plist,leadcomp1) => range:=2*range degree(gcd [newm,differentiate(newm)])~=0 => range:=2*range luniv:=ufactor(newm) @@ -243,7 +243,7 @@ InnerMultFact(OV,E,R,P) : C == T -- polCase if leadtest or ((localNorm unifact > localNorm [ff.factor for ff in lunivf]) - and (^testp or polCase(lffc1*clc,#plist,leadcomp1))) then + and (not testp or polCase(lffc1*clc,#plist,leadcomp1))) then unifact:=[uf.factor for uf in lunivf] int:=lval lffc:=lffc1 @@ -260,10 +260,10 @@ InnerMultFact(OV,E,R,P) : C == T nfatt := nf nfatt>nf => -- for the previous values there were more factors - if testp then leadtest:=^polCase(lffc*clc,#plist,leadcomp) + if testp then leadtest:= not polCase(lffc*clc,#plist,leadcomp) else leadtest:= false -- if polCase=true we can consider the univariate decomposition - if ^leadtest then + if not leadtest then unifact:=[uf.factor for uf in lunivf] lffc:=lffc1 if testp then leadcomp:=leadcomp1 diff --git a/src/algebra/multsqfr.spad.pamphlet b/src/algebra/multsqfr.spad.pamphlet index 4d71bd73..292b6735 100644 --- a/src/algebra/multsqfr.spad.pamphlet +++ b/src/algebra/multsqfr.spad.pamphlet @@ -292,7 +292,7 @@ MultivariateSquareFree (E,OV,R,P) : C == T where lcd:P:=leadingCoefficient ud leadlist:List(P):=empty() - if ^ground?(leadingCoefficient ud) then + if not ground?(leadingCoefficient ud) then leadpol:=true ud:=lcoef*ud lcg0:R:=leadingCoefficient g0 diff --git a/src/algebra/newpoint.spad.pamphlet b/src/algebra/newpoint.spad.pamphlet index 27301539..9842394b 100644 --- a/src/algebra/newpoint.spad.pamphlet +++ b/src/algebra/newpoint.spad.pamphlet @@ -326,7 +326,7 @@ SubSpace(n:PI,R:Ring) : Exports == Implementation where leaf? space == empty? children space root? space == (space.levelField = 0$NNI) - internal? space == ^(root? space and leaf? space) + internal? space == not (root? space and leaf? space) new() == [point(empty())$POINT,0,new()$PROP,empty(),empty(),0,_ @@ -551,7 +551,7 @@ SubSpace(n:PI,R:Ring) : Exports == Implementation where extractPoint space == node := space - while ^root? node repeat node := parent node + while not root? node repeat node := parent node (node.pointDataField).(space.index) extractIndex space == space.index extractClosed space == closed? space.property diff --git a/src/algebra/npcoef.spad.pamphlet b/src/algebra/npcoef.spad.pamphlet index c89d9382..6607905c 100644 --- a/src/algebra/npcoef.spad.pamphlet +++ b/src/algebra/npcoef.spad.pamphlet @@ -66,7 +66,7 @@ NPCoef(BP,E,OV,R,P) : C == T where while changed and ndet~=1 repeat changed :=false dt:=#tablecoef - for i in 1..dt while ^changed repeat + for i in 1..dt while not changed repeat (cf:=check(tablecoef.i,ulist)) case "failed" => "next i" ltochange:=cons(i,ltochange) celtf:Detc:=cf::Detc @@ -143,7 +143,7 @@ NPCoef(BP,E,OV,R,P) : C == T where modify(tablecoef:TCoef,cfter:Detc) : TCoef == cfexp:=cfter.valexp;cfcoef:=cfter.valcoef;cfpos:=cfter.posit lterase:List(NNI):=empty() - for cterm in tablecoef | ^empty?(ctdet:=cterm.detfacts) repeat + for cterm in tablecoef | not empty?(ctdet:=cterm.detfacts) repeat (+/[term.expt for term in ctdet.first])<cfexp => "next term" for celt in ctdet repeat if celt.cfpos.expt=cfexp then diff --git a/src/algebra/permgrps.spad.pamphlet b/src/algebra/permgrps.spad.pamphlet index c4060112..69c4be03 100644 --- a/src/algebra/permgrps.spad.pamphlet +++ b/src/algebra/permgrps.spad.pamphlet @@ -244,10 +244,10 @@ PermutationGroup(S:SetCategory): public == private where point := orbit.orb.1 outlist := nil()$(L NNI) entryLessZero : B := false - while ^entryLessZero repeat + while not entryLessZero repeat entry := schreierVector.(actelt.point) entryLessZero := (entry < 0) - if ^entryLessZero then + if not entryLessZero then actelt := times(group.entry, actelt) if wordProblem then outlist := append ( words.(entry::NNI) , outlist ) [ actelt , reverse outlist ] @@ -262,7 +262,7 @@ PermutationGroup(S:SetCategory): public == private where workList := orbitList.pos for j in #workList..1 by -1 repeat newList := cons ( eval ( gen , workList.j ) , newList ) - if ^member?( newList , orbitList ) then + if not member?( newList , orbitList ) then orbitList := cons ( newList , orbitList ) pos := pos + 1 pos := pos - 1 @@ -318,7 +318,7 @@ PermutationGroup(S:SetCategory): public == private where for i in 1..#newGroup repeat newPoint := orbit.position newPoint := newGroup.i.newPoint - if ^ member? ( newPoint , orbit ) then + if not member? ( newPoint , orbit ) then orbit := cons ( newPoint , orbit ) position := position + 1 schreierVector.newPoint := i @@ -372,8 +372,8 @@ PermutationGroup(S:SetCategory): public == private where ran := ranelt ( group , words , maxLoops ) str := strip ( ran.elt , ort , group , words ) el2 := str.elt - if ^ testIdentity el2 then - if ^ member?(el2,group2) then + if not testIdentity el2 then + if not member?(el2,group2) then group2 := cons ( el2 , group2 ) if wordProblem then help : L NNI := append ( reverse str.lst , ran.lst ) diff --git a/src/algebra/pgcd.spad.pamphlet b/src/algebra/pgcd.spad.pamphlet index c371c1b6..365b0232 100644 --- a/src/algebra/pgcd.spad.pamphlet +++ b/src/algebra/pgcd.spad.pamphlet @@ -139,12 +139,12 @@ PolynomialGcdPackage(E,OV,R,P):C == T where --test if one of the polynomials is the gcd dd=d1 => - if ^((f:=p2 exquo p1) case "failed") then + if not ((f:=p2 exquo p1) case "failed") then return [[u],ltry,p1]$UTerm if dd~=d2 then dd:=(dd-1)::NNI dd=d2 => - if ^((f:=p1 exquo p2) case "failed") then + if not ((f:=p1 exquo p2) case "failed") then return [[u],ltry,p2]$UTerm dd:=(dd-1)::NNI return uterm @@ -338,7 +338,7 @@ PolynomialGcdPackage(E,OV,R,P):C == T where (p0:SUPP,p1:SUPP):=(plist.first,plist.2) if completeEval(p0,lvar,lval) ~= lg.first then (p0,p1):=(p1,p0) - ^leadpol => p0 + not leadpol => p0 p0 exquo content(p0) -- Gcd for two multivariate polynomials diff --git a/src/algebra/pleqn.spad.pamphlet b/src/algebra/pleqn.spad.pamphlet index f5653815..fa296d65 100644 --- a/src/algebra/pleqn.spad.pamphlet +++ b/src/algebra/pleqn.spad.pamphlet @@ -449,7 +449,7 @@ ParametricLinearEquations(R,Var,Expon,GR): test:=hasoln(zro, [rc.det]) -- zroideal:=ideal(zro) -- inRadical? (p, zroideal) => "incompatible or covered" - ^test.sysok => "incompatible or covered" + not test.sysok => "incompatible or covered" -- The next line is WRONG! cannot replace zro by test.z0 -- zro:=groebner$gb (cons(*/test.n0, test.z0)) zro:=groebner$gb (cons(p,zro)) @@ -549,7 +549,7 @@ ParametricLinearEquations(R,Var,Expon,GR): zro:=groebner$gb [*/x for x in psbf] inconsistent? zro => [false, zro, nzro] nzro:=[redPol$rp (p,zro) for p in nzro] - nzro:=[p for p in nzro | ^(ground? p)] + nzro:=[p for p in nzro | not (ground? p)] [true, zro, nzro] @@ -596,7 +596,7 @@ ParametricLinearEquations(R,Var,Expon,GR): minset lset == empty? lset => lset - [x for x in lset | ^(overset?(x,lset))] + [x for x in lset | not (overset?(x,lset))] sqfree p == */[j.factor for j in factors(squareFree p)] diff --git a/src/algebra/qalgset.spad.pamphlet b/src/algebra/qalgset.spad.pamphlet index 400aba47..30e121fe 100644 --- a/src/algebra/qalgset.spad.pamphlet +++ b/src/algebra/qalgset.spad.pamphlet @@ -189,7 +189,7 @@ QuasiAlgebraicSet(R, Var,Expon,Dpoly) : C == T minset lset == empty? lset => lset - [s for s in lset | ^(overset?(s,lset))] + [s for s in lset | not (overset?(s,lset))] overset?(p,qlist) == empty? qlist => false diff --git a/src/algebra/radeigen.spad.pamphlet b/src/algebra/radeigen.spad.pamphlet index 04e006fb..e4d24320 100644 --- a/src/algebra/radeigen.spad.pamphlet +++ b/src/algebra/radeigen.spad.pamphlet @@ -176,7 +176,7 @@ RadicalEigenPackage() : C == T ---- orthogonal basis for a symmetric matrix ---- orthonormalBasis(A:M):List(MRE) == - ^symmetric?(A) => error "the matrix is not symmetric" + not symmetric?(A) => error "the matrix is not symmetric" basis:List(MRE):=[] lvec:List(MRE) := [] alglist:List(RadicalForm):=radicalEigenvectors(A) diff --git a/src/algebra/rep2.spad.pamphlet b/src/algebra/rep2.spad.pamphlet index 01c39568..45fddeb4 100644 --- a/src/algebra/rep2.spad.pamphlet +++ b/src/algebra/rep2.spad.pamphlet @@ -320,7 +320,7 @@ RepresentationPackage2(R): public == private where --will be checked whether they are in the span of the vectors --computed so far. Of course we stop if we have got the whole --space. - while (^null furtherElts) and (nrows basis < #v) repeat + while (not null furtherElts) and (nrows basis < #v) repeat w : V R := first furtherElts nextVector : M R := matrix list entries w -- normalizing the vector -- will the rank change if we add this nextVector @@ -349,7 +349,7 @@ RepresentationPackage2(R): public == private where --will be checked whether they are in the span of the vectors --computed so far. Of course we stop if we have got the whole --space. - while (^null furtherElts) and (nrows basis < #v) repeat + while (not null furtherElts) and (nrows basis < #v) repeat w : V R := first furtherElts nextVector : M R := matrix list entries w -- normalizing the vector -- will the rank change if we add this nextVector diff --git a/src/algebra/solverad.spad.pamphlet b/src/algebra/solverad.spad.pamphlet index ee9e0b68..95b9375d 100644 --- a/src/algebra/solverad.spad.pamphlet +++ b/src/algebra/solverad.spad.pamphlet @@ -261,7 +261,7 @@ RadicalSolvePackage(R): Cat == Capsule where for f in factors repeat ff:=f.factor - ^ member?(v, variables (ff)) => + not member?(v, variables (ff)) => constants := cons(ff, constants) u := univariate(ff, v) t := reduce u diff --git a/src/algebra/space.spad.pamphlet b/src/algebra/space.spad.pamphlet index 3d269880..52c9de91 100644 --- a/src/algebra/space.spad.pamphlet +++ b/src/algebra/space.spad.pamphlet @@ -587,25 +587,25 @@ ThreeSpace(R:Ring):Exports == Implementation where space lp space == - if ^space.converted then space := convertSpace space + if not space.converted then space := convertSpace space space.rep3DField.lp lllip space == - if ^space.converted then space := convertSpace space + if not space.converted then space := convertSpace space space.rep3DField.llliPt -- lllp space == --- if ^space.converted then space := convertSpace space +-- if not space.converted then space := convertSpace space -- space.rep3DField.lllPt llprop space == - if ^space.converted then space := convertSpace space + if not space.converted then space := convertSpace space space.rep3DField.llProp lprop space == - if ^space.converted then space := convertSpace space + if not space.converted then space := convertSpace space space.rep3DField.lProp -- this function is just to see how this representation really -- does work objects space == - if ^space.converted then space := convertSpace space + if not space.converted then space := convertSpace space numPts := 0$NNI numCurves := 0$NNI numPolys := 0$NNI @@ -628,13 +628,13 @@ ThreeSpace(R:Ring):Exports == Implementation where [numPts,numCurves,numPolys,numConstructs] check(s) == - ^s.converted => convertSpace s + not s.converted => convertSpace s s subspace(s) == s.subspaceField coerce(s) == - if ^s.converted then s := convertSpace s + if not s.converted then s := convertSpace s hconcat(["3-Space with "::O, _ (sizo:=#(s.rep3DField.llliPt))::O, _ (sizo=1=>" component"::O;" components"::O)]) diff --git a/src/algebra/strap/BOOLEAN.lsp b/src/algebra/strap/BOOLEAN.lsp index 7a141b8b..f275dcd5 100644 --- a/src/algebra/strap/BOOLEAN.lsp +++ b/src/algebra/strap/BOOLEAN.lsp @@ -17,69 +17,67 @@ (DEFUN |BOOLEAN;not;2$;5| (|b| $) (COND (|b| 'NIL) ('T 'T))) -(DEFUN |BOOLEAN;^;2$;6| (|b| $) (COND (|b| 'NIL) ('T 'T))) +(DEFUN |BOOLEAN;~;2$;6| (|b| $) (COND (|b| 'NIL) ('T 'T))) -(DEFUN |BOOLEAN;~;2$;7| (|b| $) (COND (|b| 'NIL) ('T 'T))) +(DEFUN |BOOLEAN;and;3$;7| (|a| |b| $) (COND (|a| |b|) ('T 'NIL))) -(DEFUN |BOOLEAN;and;3$;8| (|a| |b| $) (COND (|a| |b|) ('T 'NIL))) +(DEFUN |BOOLEAN;/\\;3$;8| (|a| |b| $) (COND (|a| |b|) ('T 'NIL))) -(DEFUN |BOOLEAN;/\\;3$;9| (|a| |b| $) (COND (|a| |b|) ('T 'NIL))) +(DEFUN |BOOLEAN;or;3$;9| (|a| |b| $) (COND (|a| 'T) ('T |b|))) -(DEFUN |BOOLEAN;or;3$;10| (|a| |b| $) (COND (|a| 'T) ('T |b|))) +(DEFUN |BOOLEAN;\\/;3$;10| (|a| |b| $) (COND (|a| 'T) ('T |b|))) -(DEFUN |BOOLEAN;\\/;3$;11| (|a| |b| $) (COND (|a| 'T) ('T |b|))) - -(DEFUN |BOOLEAN;xor;3$;12| (|a| |b| $) +(DEFUN |BOOLEAN;xor;3$;11| (|a| |b| $) (COND (|a| (|BOOLEAN;nt| |b| $)) ('T |b|))) -(DEFUN |BOOLEAN;nor;3$;13| (|a| |b| $) +(DEFUN |BOOLEAN;nor;3$;12| (|a| |b| $) (COND (|a| 'NIL) ('T (|BOOLEAN;nt| |b| $)))) -(DEFUN |BOOLEAN;nand;3$;14| (|a| |b| $) +(DEFUN |BOOLEAN;nand;3$;13| (|a| |b| $) (COND (|a| (|BOOLEAN;nt| |b| $)) ('T 'T))) -(PUT '|BOOLEAN;=;3$;15| '|SPADreplace| 'EQ) +(PUT '|BOOLEAN;=;3$;14| '|SPADreplace| 'EQ) -(DEFUN |BOOLEAN;=;3$;15| (|a| |b| $) (EQ |a| |b|)) +(DEFUN |BOOLEAN;=;3$;14| (|a| |b| $) (EQ |a| |b|)) -(DEFUN |BOOLEAN;implies;3$;16| (|a| |b| $) (COND (|a| |b|) ('T 'T))) +(DEFUN |BOOLEAN;implies;3$;15| (|a| |b| $) (COND (|a| |b|) ('T 'T))) -(PUT '|BOOLEAN;equiv;3$;17| '|SPADreplace| 'EQ) +(PUT '|BOOLEAN;equiv;3$;16| '|SPADreplace| 'EQ) -(DEFUN |BOOLEAN;equiv;3$;17| (|a| |b| $) (EQ |a| |b|)) +(DEFUN |BOOLEAN;equiv;3$;16| (|a| |b| $) (EQ |a| |b|)) -(DEFUN |BOOLEAN;<;3$;18| (|a| |b| $) +(DEFUN |BOOLEAN;<;3$;17| (|a| |b| $) (COND (|b| (|BOOLEAN;nt| |a| $)) ('T 'NIL))) -(PUT '|BOOLEAN;size;Nni;19| '|SPADreplace| '(XLAM NIL 2)) +(PUT '|BOOLEAN;size;Nni;18| '|SPADreplace| '(XLAM NIL 2)) -(DEFUN |BOOLEAN;size;Nni;19| ($) 2) +(DEFUN |BOOLEAN;size;Nni;18| ($) 2) -(DEFUN |BOOLEAN;index;Pi$;20| (|i| $) - (COND ((SPADCALL |i| (|getShellEntry| $ 27)) 'NIL) ('T 'T))) +(DEFUN |BOOLEAN;index;Pi$;19| (|i| $) + (COND ((SPADCALL |i| (|getShellEntry| $ 26)) 'NIL) ('T 'T))) -(DEFUN |BOOLEAN;lookup;$Pi;21| (|a| $) (COND (|a| 1) ('T 2))) +(DEFUN |BOOLEAN;lookup;$Pi;20| (|a| $) (COND (|a| 1) ('T 2))) -(DEFUN |BOOLEAN;random;$;22| ($) - (COND ((SPADCALL (|random|) (|getShellEntry| $ 27)) 'NIL) ('T 'T))) +(DEFUN |BOOLEAN;random;$;21| ($) + (COND ((SPADCALL (|random|) (|getShellEntry| $ 26)) 'NIL) ('T 'T))) -(DEFUN |BOOLEAN;convert;$If;23| (|x| $) +(DEFUN |BOOLEAN;convert;$If;22| (|x| $) (COND - (|x| (SPADCALL (SPADCALL "true" (|getShellEntry| $ 34)) - (|getShellEntry| $ 36))) + (|x| (SPADCALL (SPADCALL "true" (|getShellEntry| $ 33)) + (|getShellEntry| $ 35))) ('T - (SPADCALL (SPADCALL "false" (|getShellEntry| $ 34)) - (|getShellEntry| $ 36))))) + (SPADCALL (SPADCALL "false" (|getShellEntry| $ 33)) + (|getShellEntry| $ 35))))) -(DEFUN |BOOLEAN;coerce;$Of;24| (|x| $) +(DEFUN |BOOLEAN;coerce;$Of;23| (|x| $) (COND - (|x| (SPADCALL "true" (|getShellEntry| $ 39))) - ('T (SPADCALL "false" (|getShellEntry| $ 39))))) + (|x| (SPADCALL "true" (|getShellEntry| $ 38))) + ('T (SPADCALL "false" (|getShellEntry| $ 38))))) (DEFUN |Boolean| () (PROG () (RETURN - (PROG (#0=#:G1423) + (PROG (#0=#:G1422) (RETURN (COND ((LETT #0# (HGET |$ConstructorCache| '|Boolean|) |Boolean|) @@ -98,7 +96,7 @@ (RETURN (PROGN (LETT |dv$| '(|Boolean|) . #0=(|Boolean|)) - (LETT $ (|newShell| 42) . #0#) + (LETT $ (|newShell| 41) . #0#) (|setShellEntry| $ 0 |dv$|) (|setShellEntry| $ 3 (LETT |pv$| (|buildPredVector| 0 0 NIL) . #0#)) @@ -112,77 +110,75 @@ (FUNCALL (|dispatchFunction| |BOOLEAN;true;$;3|) $)) (CONS IDENTITY (FUNCALL (|dispatchFunction| |BOOLEAN;false;$;4|) $)) - |BOOLEAN;not;2$;5| |BOOLEAN;^;2$;6| |BOOLEAN;~;2$;7| - |BOOLEAN;and;3$;8| |BOOLEAN;/\\;3$;9| |BOOLEAN;or;3$;10| - |BOOLEAN;\\/;3$;11| |BOOLEAN;xor;3$;12| - |BOOLEAN;nor;3$;13| |BOOLEAN;nand;3$;14| (|Boolean|) - |BOOLEAN;=;3$;15| |BOOLEAN;implies;3$;16| - |BOOLEAN;equiv;3$;17| |BOOLEAN;<;3$;18| - (|NonNegativeInteger|) |BOOLEAN;size;Nni;19| (|Integer|) - (0 . |even?|) (|PositiveInteger|) |BOOLEAN;index;Pi$;20| - |BOOLEAN;lookup;$Pi;21| |BOOLEAN;random;$;22| (|String|) + |BOOLEAN;not;2$;5| |BOOLEAN;~;2$;6| |BOOLEAN;and;3$;7| + |BOOLEAN;/\\;3$;8| |BOOLEAN;or;3$;9| |BOOLEAN;\\/;3$;10| + |BOOLEAN;xor;3$;11| |BOOLEAN;nor;3$;12| + |BOOLEAN;nand;3$;13| (|Boolean|) |BOOLEAN;=;3$;14| + |BOOLEAN;implies;3$;15| |BOOLEAN;equiv;3$;16| + |BOOLEAN;<;3$;17| (|NonNegativeInteger|) + |BOOLEAN;size;Nni;18| (|Integer|) (0 . |even?|) + (|PositiveInteger|) |BOOLEAN;index;Pi$;19| + |BOOLEAN;lookup;$Pi;20| |BOOLEAN;random;$;21| (|String|) (|Symbol|) (5 . |coerce|) (|InputForm|) (10 . |convert|) - |BOOLEAN;convert;$If;23| (|OutputForm|) (15 . |message|) - |BOOLEAN;coerce;$Of;24| (|SingleInteger|)) + |BOOLEAN;convert;$If;22| (|OutputForm|) (15 . |message|) + |BOOLEAN;coerce;$Of;23| (|SingleInteger|)) '#(~= 20 ~ 26 |xor| 31 |true| 37 |test| 41 |size| 46 |random| 50 |or| 54 |not| 60 |nor| 65 |nand| 71 |min| 77 |max| 83 |lookup| 89 |latex| 94 |index| 99 |implies| 104 |hash| 110 |false| 115 |equiv| 119 |convert| 125 |coerce| 130 |and| - 135 ^ 141 |\\/| 146 >= 152 > 158 = 164 <= 170 < 176 |/\\| - 182) + 135 |\\/| 141 >= 147 > 153 = 159 <= 165 < 171 |/\\| 177) 'NIL (CONS (|makeByteWordVec2| 1 '(0 0 0 0 0 0 0 0)) (CONS '#(|OrderedSet&| NIL |Logic&| |SetCategory&| NIL NIL |BasicType&| NIL) (CONS '#((|OrderedSet|) (|Finite|) (|Logic|) - (|SetCategory|) (|ConvertibleTo| 35) + (|SetCategory|) (|ConvertibleTo| 34) (|PropositionalLogic|) (|BasicType|) - (|CoercibleTo| 38)) - (|makeByteWordVec2| 41 - '(1 26 19 0 27 1 33 0 32 34 1 35 0 33 - 36 1 38 0 32 39 2 0 19 0 0 1 1 0 0 0 - 11 2 0 0 0 0 16 0 0 0 7 1 0 0 0 6 0 0 - 24 25 0 0 0 31 2 0 0 0 0 14 1 0 0 0 9 - 2 0 0 0 0 17 2 0 0 0 0 18 2 0 0 0 0 1 - 2 0 0 0 0 1 1 0 28 0 30 1 0 32 0 1 1 - 0 0 28 29 2 0 0 0 0 21 1 0 41 0 1 0 0 - 0 8 2 0 0 0 0 22 1 0 35 0 37 1 0 38 0 - 40 2 0 0 0 0 12 1 0 0 0 10 2 0 0 0 0 - 15 2 0 19 0 0 1 2 0 19 0 0 1 2 0 19 0 - 0 20 2 0 19 0 0 1 2 0 19 0 0 23 2 0 0 - 0 0 13))))) + (|CoercibleTo| 37)) + (|makeByteWordVec2| 40 + '(1 25 18 0 26 1 32 0 31 33 1 34 0 32 + 35 1 37 0 31 38 2 0 18 0 0 1 1 0 0 0 + 10 2 0 0 0 0 15 0 0 0 7 1 0 0 0 6 0 0 + 23 24 0 0 0 30 2 0 0 0 0 13 1 0 0 0 9 + 2 0 0 0 0 16 2 0 0 0 0 17 2 0 0 0 0 1 + 2 0 0 0 0 1 1 0 27 0 29 1 0 31 0 1 1 + 0 0 27 28 2 0 0 0 0 20 1 0 40 0 1 0 0 + 0 8 2 0 0 0 0 21 1 0 34 0 36 1 0 37 0 + 39 2 0 0 0 0 11 2 0 0 0 0 14 2 0 18 0 + 0 1 2 0 18 0 0 1 2 0 18 0 0 19 2 0 18 + 0 0 1 2 0 18 0 0 22 2 0 0 0 0 12))))) '|lookupComplete|)) (SETQ |$CategoryFrame| (|put| '|Boolean| '|isFunctor| '(((|test| ($ $)) T (ELT $ 6)) - ((|nor| ($ $ $)) T (ELT $ 17)) - ((|nand| ($ $ $)) T (ELT $ 18)) - ((|xor| ($ $ $)) T (ELT $ 16)) ((^ ($ $)) T (ELT $ 10)) + ((|nor| ($ $ $)) T (ELT $ 16)) + ((|nand| ($ $ $)) T (ELT $ 17)) + ((|xor| ($ $ $)) T (ELT $ 15)) ((|false| ($)) T (CONST $ 8)) ((|true| ($)) T (CONST $ 7)) - ((|convert| ((|InputForm|) $)) T (ELT $ 37)) - ((|equiv| ($ $ $)) T (ELT $ 22)) - ((|implies| ($ $ $)) T (ELT $ 21)) - ((|or| ($ $ $)) T (ELT $ 14)) - ((|and| ($ $ $)) T (ELT $ 12)) - ((|not| ($ $)) T (ELT $ 9)) ((~ ($ $)) T (ELT $ 11)) - ((|/\\| ($ $ $)) T (ELT $ 13)) - ((|\\/| ($ $ $)) T (ELT $ 15)) - ((|size| ((|NonNegativeInteger|))) T (ELT $ 25)) - ((|index| ($ (|PositiveInteger|))) T (ELT $ 29)) - ((|lookup| ((|PositiveInteger|) $)) T (ELT $ 30)) - ((|random| ($)) T (ELT $ 31)) + ((|convert| ((|InputForm|) $)) T (ELT $ 36)) + ((|equiv| ($ $ $)) T (ELT $ 21)) + ((|implies| ($ $ $)) T (ELT $ 20)) + ((|or| ($ $ $)) T (ELT $ 13)) + ((|and| ($ $ $)) T (ELT $ 11)) + ((|not| ($ $)) T (ELT $ 9)) ((~ ($ $)) T (ELT $ 10)) + ((|/\\| ($ $ $)) T (ELT $ 12)) + ((|\\/| ($ $ $)) T (ELT $ 14)) + ((|size| ((|NonNegativeInteger|))) T (ELT $ 24)) + ((|index| ($ (|PositiveInteger|))) T (ELT $ 28)) + ((|lookup| ((|PositiveInteger|) $)) T (ELT $ 29)) + ((|random| ($)) T (ELT $ 30)) ((|min| ($ $ $)) T (ELT $ NIL)) ((|max| ($ $ $)) T (ELT $ NIL)) ((<= ((|Boolean|) $ $)) T (ELT $ NIL)) ((>= ((|Boolean|) $ $)) T (ELT $ NIL)) ((> ((|Boolean|) $ $)) T (ELT $ NIL)) - ((< ((|Boolean|) $ $)) T (ELT $ 23)) + ((< ((|Boolean|) $ $)) T (ELT $ 22)) ((|latex| ((|String|) $)) T (ELT $ NIL)) ((|hash| ((|SingleInteger|) $)) T (ELT $ NIL)) - ((|coerce| ((|OutputForm|) $)) T (ELT $ 40)) - ((= ((|Boolean|) $ $)) T (ELT $ 20)) + ((|coerce| ((|OutputForm|) $)) T (ELT $ 39)) + ((= ((|Boolean|) $ $)) T (ELT $ 19)) ((~= ((|Boolean|) $ $)) T (ELT $ NIL))) (|addModemap| '|Boolean| '(|Boolean|) '((|Join| (|OrderedSet|) (|Finite|) (|Logic|) @@ -191,7 +187,6 @@ (CATEGORY |domain| (SIGNATURE |true| ($) |constant|) (SIGNATURE |false| ($) |constant|) - (SIGNATURE ^ ($ $)) (SIGNATURE |xor| ($ $ $)) (SIGNATURE |nand| ($ $ $)) (SIGNATURE |nor| ($ $ $)) @@ -206,7 +201,6 @@ (SIGNATURE |true| ($) |constant|) (SIGNATURE |false| ($) |constant|) - (SIGNATURE ^ ($ $)) (SIGNATURE |xor| ($ $ $)) (SIGNATURE |nand| ($ $ $)) (SIGNATURE |nor| ($ $ $)) diff --git a/src/algebra/strap/DFLOAT.lsp b/src/algebra/strap/DFLOAT.lsp index f7fd7c17..878da4c3 100644 --- a/src/algebra/strap/DFLOAT.lsp +++ b/src/algebra/strap/DFLOAT.lsp @@ -420,8 +420,9 @@ (GO #0#)))) (LETT |me| (MANEXP |x|) |DFLOAT;manexp|) (LETT |two53| - (EXPT (FLOAT-RADIX 0.0) - (FLOAT-DIGITS 0.0)) + (SPADCALL (FLOAT-RADIX 0.0) + (FLOAT-DIGITS 0.0) + (|getShellEntry| $ 118)) |DFLOAT;manexp|) (EXIT (CONS (* |s| (FIX (* |two53| (QCAR |me|)))) @@ -429,9 +430,9 @@ #0# (EXIT #0#))))) (DEFUN |DFLOAT;rationalApproximation;$2NniF;84| (|f| |d| |b| $) - (PROG (|#G103| |nu| |ex| BASE #0=#:G1525 |de| |tol| |#G104| |q| |r| - |p2| |q2| #1=#:G1543 |#G105| |#G106| |p0| |p1| |#G107| - |#G108| |q0| |q1| |#G109| |#G110| |s| |t| #2=#:G1541) + (PROG (|#G103| |nu| |ex| BASE #0=#:G1524 |de| |tol| |#G104| |q| |r| + |p2| |q2| #1=#:G1540 |#G105| |#G106| |p0| |p1| |#G107| + |#G108| |q0| |q1| |#G109| |#G110| |s| |t| #2=#:G1538) (RETURN (SEQ (EXIT (SEQ (PROGN (LETT |#G103| (|DFLOAT;manexp| |f| $) @@ -499,14 +500,14 @@ (- (* |nu| |q2|) (* |de| |p2|))) (|getShellEntry| $ - 120)) + 121)) (* |de| (ABS |p2|)))) (EXIT (PROGN (LETT #1# (SPADCALL |p2| |q2| (|getShellEntry| $ - 119)) + 120)) |DFLOAT;rationalApproximation;$2NniF;84|) (GO #1#))))) (PROGN @@ -548,36 +549,36 @@ |DFLOAT;rationalApproximation;$2NniF;84|) (|check-subtype| (>= #2# 0) '(|NonNegativeInteger|) #2#)))) - (|getShellEntry| $ 121))))))) + (|getShellEntry| $ 122))))))) #1# (EXIT #1#))))) (DEFUN |DFLOAT;**;$F$;85| (|x| |r| $) - (PROG (|n| |d| #0=#:G1552) + (PROG (|n| |d| #0=#:G1549) (RETURN (SEQ (EXIT (COND ((ZEROP |x|) (COND - ((SPADCALL |r| (|getShellEntry| $ 122)) - (|error| "0**0 is undefined")) ((SPADCALL |r| (|getShellEntry| $ 123)) + (|error| "0**0 is undefined")) + ((SPADCALL |r| (|getShellEntry| $ 124)) (|error| "division by 0")) ('T 0.0))) - ((OR (SPADCALL |r| (|getShellEntry| $ 122)) + ((OR (SPADCALL |r| (|getShellEntry| $ 123)) (= |x| 1.0)) 1.0) ('T (COND - ((SPADCALL |r| (|spadConstant| $ 124) - (|getShellEntry| $ 125)) + ((SPADCALL |r| (|spadConstant| $ 125) + (|getShellEntry| $ 126)) |x|) ('T (SEQ (LETT |n| (SPADCALL |r| - (|getShellEntry| $ 126)) + (|getShellEntry| $ 127)) |DFLOAT;**;$F$;85|) (LETT |d| (SPADCALL |r| - (|getShellEntry| $ 127)) + (|getShellEntry| $ 128)) |DFLOAT;**;$F$;85|) (EXIT (COND ((MINUSP |x|) @@ -589,14 +590,14 @@ (LETT #0# (- (SPADCALL (- |x|) |r| - (|getShellEntry| $ 128))) + (|getShellEntry| $ 129))) |DFLOAT;**;$F$;85|) (GO #0#))) ('T (PROGN (LETT #0# (SPADCALL (- |x|) |r| - (|getShellEntry| $ 128)) + (|getShellEntry| $ 129)) |DFLOAT;**;$F$;85|) (GO #0#))))) ('T (|error| "negative root")))) @@ -618,7 +619,7 @@ (DEFUN |DoubleFloat| () (PROG () (RETURN - (PROG (#0=#:G1565) + (PROG (#0=#:G1562) (RETURN (COND ((LETT #0# (HGET |$ConstructorCache| '|DoubleFloat|) @@ -639,7 +640,7 @@ (RETURN (PROGN (LETT |dv$| '(|DoubleFloat|) . #0=(|DoubleFloat|)) - (LETT $ (|newShell| 142) . #0#) + (LETT $ (|newShell| 143) . #0#) (|setShellEntry| $ 0 |dv$|) (|setShellEntry| $ 3 (LETT |pv$| (|buildPredVector| 0 0 NIL) . #0#)) @@ -701,48 +702,48 @@ (|Union| 105 '"failed") |DFLOAT;retractIfCan;$U;78| |DFLOAT;retract;$I;79| (|Union| 26 '"failed") |DFLOAT;retractIfCan;$U;80| |DFLOAT;sign;$I;81| - |DFLOAT;abs;2$;82| (63 . |Zero|) (67 . /) (73 . *) - (79 . |coerce|) (84 . |zero?|) (89 . |negative?|) - (94 . |One|) (98 . =) (104 . |numer|) (109 . |denom|) + |DFLOAT;abs;2$;82| (63 . **) (69 . |Zero|) (73 . /) + (79 . *) (85 . |coerce|) (90 . |zero?|) (95 . |negative?|) + (100 . |One|) (104 . =) (110 . |numer|) (115 . |denom|) |DFLOAT;**;$F$;85| (|PatternMatchResult| 102 $) (|Pattern| 102) (|Factored| $) (|List| $) - (|Union| 132 '"failed") + (|Union| 133 '"failed") (|Record| (|:| |coef1| $) (|:| |coef2| $) (|:| |generator| $)) (|Record| (|:| |coef1| $) (|:| |coef2| $)) - (|Union| 135 '"failed") + (|Union| 136 '"failed") (|Record| (|:| |quotient| $) (|:| |remainder| $)) - (|Record| (|:| |coef| 132) (|:| |generator| $)) + (|Record| (|:| |coef| 133) (|:| |generator| $)) (|SparseUnivariatePolynomial| $) (|Record| (|:| |unit| $) (|:| |canonical| $) (|:| |associate| $)) (|SingleInteger|)) - '#(~= 114 |zero?| 120 |wholePart| 125 |unitNormal| 130 - |unitCanonical| 135 |unit?| 140 |truncate| 145 |tanh| 150 - |tan| 155 |subtractIfCan| 160 |squareFreePart| 166 - |squareFree| 171 |sqrt| 176 |sizeLess?| 181 |sinh| 187 - |sin| 192 |sign| 197 |sech| 202 |sec| 207 |sample| 212 - |round| 216 |retractIfCan| 221 |retract| 231 |rem| 241 - |recip| 247 |rationalApproximation| 252 |quo| 265 - |principalIdeal| 271 |prime?| 276 |precision| 281 - |positive?| 285 |pi| 290 |patternMatch| 294 |order| 301 - |one?| 306 |nthRoot| 311 |norm| 317 |negative?| 322 - |multiEuclidean| 327 |min| 333 |max| 343 |mantissa| 353 - |log2| 358 |log10| 363 |log| 368 |lcm| 373 |latex| 384 - |inv| 389 |hash| 394 |gcdPolynomial| 404 |gcd| 410 - |fractionPart| 421 |floor| 426 |float| 431 |factor| 444 - |extendedEuclidean| 449 |exquo| 462 |expressIdealMember| - 468 |exponent| 474 |exp1| 479 |exp| 483 |euclideanSize| - 488 |doubleFloatFormat| 493 |divide| 498 |digits| 504 - |differentiate| 508 |csch| 519 |csc| 524 |coth| 529 |cot| - 534 |cosh| 539 |cos| 544 |convert| 549 |coerce| 569 - |characteristic| 599 |ceiling| 603 |bits| 608 |base| 612 - |atanh| 616 |atan| 621 |associates?| 632 |asinh| 638 - |asin| 643 |asech| 648 |asec| 653 |acsch| 658 |acsc| 663 - |acoth| 668 |acot| 673 |acosh| 678 |acos| 683 |abs| 688 ^ - 693 |Zero| 711 |One| 715 |OMwrite| 719 |Gamma| 743 D 748 - |Beta| 759 >= 765 > 771 = 777 <= 783 < 789 / 795 - 807 + - 818 ** 824 * 854) + '#(~= 120 |zero?| 126 |wholePart| 131 |unitNormal| 136 + |unitCanonical| 141 |unit?| 146 |truncate| 151 |tanh| 156 + |tan| 161 |subtractIfCan| 166 |squareFreePart| 172 + |squareFree| 177 |sqrt| 182 |sizeLess?| 187 |sinh| 193 + |sin| 198 |sign| 203 |sech| 208 |sec| 213 |sample| 218 + |round| 222 |retractIfCan| 227 |retract| 237 |rem| 247 + |recip| 253 |rationalApproximation| 258 |quo| 271 + |principalIdeal| 277 |prime?| 282 |precision| 287 + |positive?| 291 |pi| 296 |patternMatch| 300 |order| 307 + |one?| 312 |nthRoot| 317 |norm| 323 |negative?| 328 + |multiEuclidean| 333 |min| 339 |max| 349 |mantissa| 359 + |log2| 364 |log10| 369 |log| 374 |lcm| 379 |latex| 390 + |inv| 395 |hash| 400 |gcdPolynomial| 410 |gcd| 416 + |fractionPart| 427 |floor| 432 |float| 437 |factor| 450 + |extendedEuclidean| 455 |exquo| 468 |expressIdealMember| + 474 |exponent| 480 |exp1| 485 |exp| 489 |euclideanSize| + 494 |doubleFloatFormat| 499 |divide| 504 |digits| 510 + |differentiate| 514 |csch| 525 |csc| 530 |coth| 535 |cot| + 540 |cosh| 545 |cos| 550 |convert| 555 |coerce| 575 + |characteristic| 605 |ceiling| 609 |bits| 614 |base| 618 + |atanh| 622 |atan| 627 |associates?| 638 |asinh| 644 + |asin| 649 |asech| 654 |asec| 659 |acsch| 664 |acsc| 669 + |acoth| 674 |acot| 679 |acosh| 684 |acos| 689 |abs| 694 ^ + 699 |Zero| 717 |One| 721 |OMwrite| 725 |Gamma| 749 D 754 + |Beta| 765 >= 771 > 777 = 783 <= 789 < 795 / 801 - 813 + + 824 ** 830 * 860) '((|approximate| . 0) (|canonicalsClosed| . 0) (|canonicalUnitNormal| . 0) (|noZeroDivisors| . 0) ((|commutative| "*") . 0) (|rightUnitary| . 0) @@ -801,68 +802,68 @@ (|HyperbolicFunctionCategory|) (|ArcTrigonometricFunctionCategory|) (|TrigonometricFunctionCategory|) - (|OpenMath|) (|ConvertibleTo| 130) + (|OpenMath|) (|ConvertibleTo| 131) (|RadicalCategory|) (|RetractableTo| 105) (|RetractableTo| 26) (|ConvertibleTo| 102) (|ConvertibleTo| 15) (|BasicType|) (|CoercibleTo| 40)) - (|makeByteWordVec2| 141 + (|makeByteWordVec2| 142 '(0 9 0 10 2 11 0 7 9 12 1 11 13 0 14 2 11 13 0 15 16 1 11 13 0 17 1 11 13 0 18 2 0 0 24 0 31 1 40 0 15 41 1 43 0 15 44 1 94 15 15 95 2 94 15 15 15 97 - 1 102 0 15 103 0 105 0 118 2 105 0 26 - 26 119 2 26 0 106 0 120 1 105 0 26 - 121 1 105 20 0 122 1 105 20 0 123 0 - 105 0 124 2 105 20 0 0 125 1 105 26 0 - 126 1 105 26 0 127 2 0 20 0 0 1 1 0 - 20 0 89 1 0 26 0 99 1 0 140 0 1 1 0 0 - 0 1 1 0 20 0 1 1 0 0 0 1 1 0 0 0 77 1 - 0 0 0 65 2 0 91 0 0 1 1 0 0 0 1 1 0 - 131 0 1 1 0 0 0 56 2 0 20 0 0 1 1 0 0 - 0 75 1 0 0 0 63 1 0 26 0 116 1 0 0 0 - 80 1 0 0 0 67 0 0 0 1 1 0 0 0 1 1 0 - 111 0 112 1 0 114 0 115 1 0 105 0 110 - 1 0 26 0 113 2 0 0 0 0 1 1 0 91 0 92 - 2 0 105 0 106 108 3 0 105 0 106 106 - 107 2 0 0 0 0 1 1 0 138 132 1 1 0 20 - 0 1 0 0 24 29 1 0 20 0 1 0 0 0 39 3 0 - 129 0 130 129 1 1 0 26 0 35 1 0 20 0 - 1 2 0 0 0 26 1 1 0 0 0 1 1 0 20 0 88 - 2 0 133 132 0 1 0 0 0 34 2 0 0 0 0 53 - 0 0 0 33 2 0 0 0 0 52 1 0 26 0 27 1 0 - 0 0 30 1 0 0 0 57 1 0 0 0 62 1 0 0 - 132 1 2 0 0 0 0 1 1 0 7 0 1 1 0 0 0 1 - 1 0 26 0 90 1 0 141 0 1 2 0 139 139 - 139 1 1 0 0 132 1 2 0 0 0 0 1 1 0 0 0 - 1 1 0 0 0 1 3 0 0 26 26 24 100 2 0 0 - 26 26 1 1 0 131 0 1 2 0 134 0 0 1 3 0 - 136 0 0 0 1 2 0 91 0 0 1 2 0 133 132 - 0 1 1 0 26 0 28 0 0 0 38 1 0 0 0 61 1 - 0 106 0 1 1 0 7 7 8 2 0 137 0 0 1 0 0 - 24 1 1 0 0 0 93 2 0 0 0 106 1 1 0 0 0 - 78 1 0 0 0 68 1 0 0 0 79 1 0 0 0 66 1 - 0 0 0 76 1 0 0 0 64 1 0 43 0 45 1 0 - 130 0 1 1 0 102 0 104 1 0 15 0 101 1 - 0 0 105 1 1 0 0 26 60 1 0 0 105 1 1 0 - 0 26 60 1 0 0 0 1 1 0 40 0 42 0 0 106 - 1 1 0 0 0 1 0 0 24 32 0 0 24 25 1 0 0 - 0 83 2 0 0 0 0 109 1 0 0 0 71 2 0 20 - 0 0 1 1 0 0 0 81 1 0 0 0 69 1 0 0 0 - 86 1 0 0 0 74 1 0 0 0 84 1 0 0 0 72 1 - 0 0 0 85 1 0 0 0 73 1 0 0 0 82 1 0 0 - 0 70 1 0 0 0 117 2 0 0 0 26 1 2 0 0 0 - 106 1 2 0 0 0 24 1 0 0 0 36 0 0 0 37 - 3 0 13 11 0 20 23 2 0 7 0 20 21 2 0 - 13 11 0 22 1 0 7 0 19 1 0 0 0 96 1 0 - 0 0 1 2 0 0 0 106 1 2 0 0 0 0 98 2 0 - 20 0 0 1 2 0 20 0 0 1 2 0 20 0 0 54 2 - 0 20 0 0 1 2 0 20 0 0 46 2 0 0 0 26 + 1 102 0 15 103 2 26 0 0 24 118 0 105 + 0 119 2 105 0 26 26 120 2 26 0 106 0 + 121 1 105 0 26 122 1 105 20 0 123 1 + 105 20 0 124 0 105 0 125 2 105 20 0 0 + 126 1 105 26 0 127 1 105 26 0 128 2 0 + 20 0 0 1 1 0 20 0 89 1 0 26 0 99 1 0 + 141 0 1 1 0 0 0 1 1 0 20 0 1 1 0 0 0 + 1 1 0 0 0 77 1 0 0 0 65 2 0 91 0 0 1 + 1 0 0 0 1 1 0 132 0 1 1 0 0 0 56 2 0 + 20 0 0 1 1 0 0 0 75 1 0 0 0 63 1 0 26 + 0 116 1 0 0 0 80 1 0 0 0 67 0 0 0 1 1 + 0 0 0 1 1 0 111 0 112 1 0 114 0 115 1 + 0 105 0 110 1 0 26 0 113 2 0 0 0 0 1 + 1 0 91 0 92 2 0 105 0 106 108 3 0 105 + 0 106 106 107 2 0 0 0 0 1 1 0 139 133 + 1 1 0 20 0 1 0 0 24 29 1 0 20 0 1 0 0 + 0 39 3 0 130 0 131 130 1 1 0 26 0 35 + 1 0 20 0 1 2 0 0 0 26 1 1 0 0 0 1 1 0 + 20 0 88 2 0 134 133 0 1 0 0 0 34 2 0 + 0 0 0 53 0 0 0 33 2 0 0 0 0 52 1 0 26 + 0 27 1 0 0 0 30 1 0 0 0 57 1 0 0 0 62 + 1 0 0 133 1 2 0 0 0 0 1 1 0 7 0 1 1 0 + 0 0 1 1 0 26 0 90 1 0 142 0 1 2 0 140 + 140 140 1 1 0 0 133 1 2 0 0 0 0 1 1 0 + 0 0 1 1 0 0 0 1 3 0 0 26 26 24 100 2 + 0 0 26 26 1 1 0 132 0 1 2 0 135 0 0 1 + 3 0 137 0 0 0 1 2 0 91 0 0 1 2 0 134 + 133 0 1 1 0 26 0 28 0 0 0 38 1 0 0 0 + 61 1 0 106 0 1 1 0 7 7 8 2 0 138 0 0 + 1 0 0 24 1 1 0 0 0 93 2 0 0 0 106 1 1 + 0 0 0 78 1 0 0 0 68 1 0 0 0 79 1 0 0 + 0 66 1 0 0 0 76 1 0 0 0 64 1 0 43 0 + 45 1 0 131 0 1 1 0 102 0 104 1 0 15 0 + 101 1 0 0 105 1 1 0 0 26 60 1 0 0 105 + 1 1 0 0 26 60 1 0 0 0 1 1 0 40 0 42 0 + 0 106 1 1 0 0 0 1 0 0 24 32 0 0 24 25 + 1 0 0 0 83 2 0 0 0 0 109 1 0 0 0 71 2 + 0 20 0 0 1 1 0 0 0 81 1 0 0 0 69 1 0 + 0 0 86 1 0 0 0 74 1 0 0 0 84 1 0 0 0 + 72 1 0 0 0 85 1 0 0 0 73 1 0 0 0 82 1 + 0 0 0 70 1 0 0 0 117 2 0 0 0 26 1 2 0 + 0 0 106 1 2 0 0 0 24 1 0 0 0 36 0 0 0 + 37 3 0 13 11 0 20 23 2 0 7 0 20 21 2 + 0 13 11 0 22 1 0 7 0 19 1 0 0 0 96 1 + 0 0 0 1 2 0 0 0 106 1 2 0 0 0 0 98 2 + 0 20 0 0 1 2 0 20 0 0 1 2 0 20 0 0 54 + 2 0 20 0 0 1 2 0 20 0 0 46 2 0 0 0 26 55 2 0 0 0 0 87 2 0 0 0 0 49 1 0 0 0 47 2 0 0 0 0 48 2 0 0 0 0 59 2 0 0 0 - 105 128 2 0 0 0 26 58 2 0 0 0 106 1 2 + 105 129 2 0 0 0 26 58 2 0 0 0 106 1 2 0 0 0 24 1 2 0 0 0 105 1 2 0 0 105 0 1 2 0 0 0 0 50 2 0 0 26 0 51 2 0 0 106 0 1 2 0 0 24 0 31))))) @@ -968,7 +969,7 @@ (|PatternMatchResult| (|Float|) $))) T (ELT $ NIL)) ((|convert| ((|Pattern| (|Float|)) $)) T (ELT $ NIL)) - ((** ($ $ (|Fraction| (|Integer|)))) T (ELT $ 128)) + ((** ($ $ (|Fraction| (|Integer|)))) T (ELT $ 129)) ((|nthRoot| ($ $ (|Integer|))) T (ELT $ NIL)) ((|sqrt| ($ $)) T (ELT $ 56)) ((|retract| ((|Fraction| (|Integer|)) $)) T (ELT $ 110)) diff --git a/src/algebra/strap/FFIELDC-.lsp b/src/algebra/strap/FFIELDC-.lsp index 56e49451..0e6a1eae 100644 --- a/src/algebra/strap/FFIELDC-.lsp +++ b/src/algebra/strap/FFIELDC-.lsp @@ -436,8 +436,9 @@ ('T (SEQ (LETT |rho| - (* (QCDR |rhoHelp|) - |mult|) + (SPADCALL + (QCDR |rhoHelp|) |mult| + (|getShellEntry| $ 72)) |FFIELDC-;discreteLog;2SU;12|) (LETT |disclog| (+ |disclog| |rho|) @@ -464,25 +465,25 @@ #2# (EXIT #2#))))) (DEFUN |FFIELDC-;squareFreePolynomial| (|f| $) - (SPADCALL |f| (|getShellEntry| $ 76))) + (SPADCALL |f| (|getShellEntry| $ 77))) (DEFUN |FFIELDC-;factorPolynomial| (|f| $) - (SPADCALL |f| (|getShellEntry| $ 78))) + (SPADCALL |f| (|getShellEntry| $ 79))) (DEFUN |FFIELDC-;factorSquareFreePolynomial| (|f| $) (PROG (|flist| |u| #0=#:G1517 #1=#:G1514 #2=#:G1512 #3=#:G1513) (RETURN (SEQ (COND - ((SPADCALL |f| (|spadConstant| $ 79) - (|getShellEntry| $ 80)) - (|spadConstant| $ 81)) + ((SPADCALL |f| (|spadConstant| $ 80) + (|getShellEntry| $ 81)) + (|spadConstant| $ 82)) ('T (SEQ (LETT |flist| - (SPADCALL |f| 'T (|getShellEntry| $ 85)) + (SPADCALL |f| 'T (|getShellEntry| $ 86)) |FFIELDC-;factorSquareFreePolynomial|) (EXIT (SPADCALL (SPADCALL (QCAR |flist|) - (|getShellEntry| $ 86)) + (|getShellEntry| $ 87)) (PROGN (LETT #3# NIL |FFIELDC-;factorSquareFreePolynomial|) @@ -504,13 +505,13 @@ (LETT #1# (SPADCALL (QCAR |u|) (QCDR |u|) - (|getShellEntry| $ 87)) + (|getShellEntry| $ 88)) |FFIELDC-;factorSquareFreePolynomial|) (COND (#3# (LETT #2# (SPADCALL #2# #1# - (|getShellEntry| $ 88)) + (|getShellEntry| $ 89)) |FFIELDC-;factorSquareFreePolynomial|)) ('T (PROGN @@ -523,11 +524,11 @@ (GO G190) G191 (EXIT NIL)) (COND (#3# #2#) - ('T (|spadConstant| $ 89)))) - (|getShellEntry| $ 90)))))))))) + ('T (|spadConstant| $ 90)))) + (|getShellEntry| $ 91)))))))))) (DEFUN |FFIELDC-;gcdPolynomial;3Sup;16| (|f| |g| $) - (SPADCALL |f| |g| (|getShellEntry| $ 92))) + (SPADCALL |f| |g| (|getShellEntry| $ 93))) (DEFUN |FiniteFieldCategory&| (|#1|) (PROG (|dv$1| |dv$| $ |pv$|) @@ -535,7 +536,7 @@ (PROGN (LETT |dv$1| (|devaluate| |#1|) . #0=(|FiniteFieldCategory&|)) (LETT |dv$| (LIST '|FiniteFieldCategory&| |dv$1|) . #0#) - (LETT $ (|newShell| 95) . #0#) + (LETT $ (|newShell| 96) . #0#) (|setShellEntry| $ 0 |dv$|) (|setShellEntry| $ 3 (LETT |pv$| (|buildPredVector| 0 0 NIL) . #0#)) @@ -572,27 +573,27 @@ (|String|) (|OutputForm|) (126 . |messagePrint|) (|Factored| $) (131 . |factor|) (|Factored| 18) (136 . |factors|) (|DiscreteLogarithmPackage| 6) - (141 . |shanksDiscLogAlgorithm|) + (141 . |shanksDiscLogAlgorithm|) (148 . *) |FFIELDC-;discreteLog;2SU;12| - (|SparseUnivariatePolynomial| 6) (|Factored| 73) - (|UnivariatePolynomialSquareFree| 6 73) - (148 . |squareFree|) (|DistinctDegreeFactorize| 6 73) - (153 . |factor|) (158 . |Zero|) (162 . =) (168 . |Zero|) - (|Record| (|:| |irr| 73) (|:| |pow| 18)) (|List| 82) - (|Record| (|:| |cont| 6) (|:| |factors| 83)) - (172 . |distdfact|) (178 . |coerce|) (183 . |primeFactor|) - (189 . *) (195 . |One|) (199 . *) (|EuclideanDomain&| 73) - (205 . |gcd|) (|SparseUnivariatePolynomial| $) + (|SparseUnivariatePolynomial| 6) (|Factored| 74) + (|UnivariatePolynomialSquareFree| 6 74) + (154 . |squareFree|) (|DistinctDegreeFactorize| 6 74) + (159 . |factor|) (164 . |Zero|) (168 . =) (174 . |Zero|) + (|Record| (|:| |irr| 74) (|:| |pow| 18)) (|List| 83) + (|Record| (|:| |cont| 6) (|:| |factors| 84)) + (178 . |distdfact|) (184 . |coerce|) (189 . |primeFactor|) + (195 . *) (201 . |One|) (205 . *) (|EuclideanDomain&| 74) + (211 . |gcd|) (|SparseUnivariatePolynomial| $) |FFIELDC-;gcdPolynomial;3Sup;16|) - '#(|primitive?| 211 |order| 216 |nextItem| 226 |init| 231 - |gcdPolynomial| 235 |discreteLog| 241 |differentiate| 252 - |createPrimitiveElement| 257 |conditionP| 261 |charthRoot| - 266) + '#(|primitive?| 217 |order| 222 |nextItem| 232 |init| 237 + |gcdPolynomial| 241 |discreteLog| 247 |differentiate| 258 + |createPrimitiveElement| 263 |conditionP| 267 |charthRoot| + 272) 'NIL (CONS (|makeByteWordVec2| 1 'NIL) (CONS '#() (CONS '#() - (|makeByteWordVec2| 94 + (|makeByteWordVec2| 95 '(0 6 0 7 1 6 10 0 11 1 6 0 10 12 1 6 13 0 14 1 6 10 0 17 1 19 0 18 20 1 24 23 0 25 2 22 13 26 0 27 1 6 0 0 28 2 @@ -602,16 +603,16 @@ 18 50 2 6 13 0 0 51 0 6 0 54 1 6 55 18 56 1 55 35 0 57 2 55 58 10 0 59 2 6 0 0 0 60 1 64 62 63 65 1 18 66 0 67 - 1 68 48 0 69 3 70 58 6 6 35 71 1 75 - 74 73 76 1 77 74 73 78 0 73 0 79 2 73 - 13 0 0 80 0 74 0 81 2 77 84 73 13 85 - 1 73 0 6 86 2 74 0 73 18 87 2 74 0 0 - 0 88 0 74 0 89 2 74 0 73 0 90 2 91 0 - 0 0 92 1 0 13 0 52 1 0 10 0 53 1 0 19 - 0 21 1 0 15 0 16 0 0 0 9 2 0 93 93 93 - 94 1 0 35 0 61 2 0 58 0 0 72 1 0 0 0 - 8 0 0 0 46 1 0 32 33 34 1 0 0 0 39 1 - 0 15 0 40))))) + 1 68 48 0 69 3 70 58 6 6 35 71 2 18 0 + 35 0 72 1 76 75 74 77 1 78 75 74 79 0 + 74 0 80 2 74 13 0 0 81 0 75 0 82 2 78 + 85 74 13 86 1 74 0 6 87 2 75 0 74 18 + 88 2 75 0 0 0 89 0 75 0 90 2 75 0 74 + 0 91 2 92 0 0 0 93 1 0 13 0 52 1 0 10 + 0 53 1 0 19 0 21 1 0 15 0 16 0 0 0 9 + 2 0 94 94 94 95 1 0 35 0 61 2 0 58 0 + 0 73 1 0 0 0 8 0 0 0 46 1 0 32 33 34 + 1 0 0 0 39 1 0 15 0 40))))) '|lookupComplete|)) (SETQ |$CategoryFrame| @@ -632,7 +633,7 @@ ((|nextItem| ((|Union| $ "failed") $)) T (ELT $ 16)) ((|discreteLog| ((|Union| (|NonNegativeInteger|) "failed") $ $)) - T (ELT $ 72)) + T (ELT $ 73)) ((|order| ((|OnePointCompletion| (|PositiveInteger|)) $)) T (ELT $ 21)) ((|charthRoot| ((|Union| $ "failed") $)) T (ELT $ 40)) @@ -640,7 +641,7 @@ ((|SparseUnivariatePolynomial| $) (|SparseUnivariatePolynomial| $) (|SparseUnivariatePolynomial| $))) - T (ELT $ 94))) + T (ELT $ 95))) (|addModemap| '|FiniteFieldCategory&| '(|FiniteFieldCategory&| |#1|) '((CATEGORY |domain| diff --git a/src/algebra/view2D.spad.pamphlet b/src/algebra/view2D.spad.pamphlet index dfab772f..8d2b67e4 100644 --- a/src/algebra/view2D.spad.pamphlet +++ b/src/algebra/view2D.spad.pamphlet @@ -280,7 +280,7 @@ GraphImage (): Exports == Implementation where plotLists(graf:Rep,listOfListsOfPoints:L L P,listOfPointColors:L PAL,listOfLineColors:L PAL,listOfPointSizes:L PI):$ == givenLen := #listOfListsOfPoints -- take out point lists that are actually empty - listOfListsOfPoints := [ l for l in listOfListsOfPoints | ^null l ] + listOfListsOfPoints := [ l for l in listOfListsOfPoints | not null l ] if (null listOfListsOfPoints) then error "GraphImage was given a list that contained no valid point lists" if ((len := #listOfListsOfPoints) ~= givenLen) then |