diff options
author | dos-reis <gdr@axiomatics.org> | 2008-05-11 19:14:29 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2008-05-11 19:14:29 +0000 |
commit | 20e1bed66399cce629d08a71ca0552ed24fef1d1 (patch) | |
tree | 000ab5b98e479d1c077fc4f6fd4a9f46c4a9451c /src/algebra/pfo.spad.pamphlet | |
parent | 51422a0c6bc0128cd5635a01c402ef56ad4ed770 (diff) | |
download | open-axiom-20e1bed66399cce629d08a71ca0552ed24fef1d1.tar.gz |
Restrict loop variable scopes, take 2.
* interp/iterator.boot (compReduce1): Maintain proper scope for
loop variables.
(compRepeatOrCollect): Really maintain proper scope for loop variables.
* interp/compiler.boot (eltModemapFilter): Highlight faulty selector.
(seteltModemapFilter): Likewise.
* interp/c-util.boot (stackMessage): Don't build message if there
is no argument for substitution.
* algebra/aggcat.spad.pamphlet (#$UnaryRecursiveAggregate):
Declare free loop variable.
(cycleEntry$UnaryRecursiveAggregate): Likewise.
(cycleLength): Likewise.
(merge$OneDimensionalArrayAggregate): Likewise.
(delete$OneDimensionalArrayAggregate): Likewise.
(position$ListAggregate): Likewise.
* algebra/array1.spad.pamphlet (merge!$IndexedFlexibleArray): Likewise.
* algebra/combfunc.spad.pamphlet (K2fact$CombinatorialFunction):
Likewise.
* algebra/curve.spad.pamphlet
(nonSingularModel$FunctionFieldCategory): Likewise.
* algebra/dpolcat.spad.pamphlet
(differentiate$DifferentialPolynomialCategory): Likewise.
* algebra/efstruc.spad.pamphlet
(validExponential$ElementaryFunctionStructurePackage): Likewise.
(ker2explogs$InnerTrigonometricManipulations): Likewise.
(complexNormalize$TrigonometricManipulations): Likewise.
Diffstat (limited to 'src/algebra/pfo.spad.pamphlet')
-rw-r--r-- | src/algebra/pfo.spad.pamphlet | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/src/algebra/pfo.spad.pamphlet b/src/algebra/pfo.spad.pamphlet index 1b310c40..493a68e4 100644 --- a/src/algebra/pfo.spad.pamphlet +++ b/src/algebra/pfo.spad.pamphlet @@ -499,15 +499,24 @@ PointsOfFiniteOrder(R0, F, UP, UPUP, R): Exports == Implementation where selIntegers():RC0 == f := definingPolynomial()$R - while zero?(d := doubleDisc(r := polyred pmod f)) repeat newReduc()$q - [r, d] + repeat + r := polyred pmod f + d := doubleDisc r + if zero? d then + newReduc()$q + else + return [r,d] selectIntegers(k:K):REC == g := polyred(f := definingPolynomial()$R) p := minPoly k - while zero?(d := doubleDisc(r := kpmod(g, k))) or (notIrr? fmod p) - repeat newReduc()$q - [r, d, splitDenominator(fmod p).num] + repeat + r := kpmod(g, k) + d := doubleDisc r + if zero? d or notIrr? fmod p then + newReduc()$q + else + return [r, d, splitDenominator(fmod p).num] toQ1(p, d) == map(Q2F(retract(#1 rem d)@Q), @@ -528,6 +537,7 @@ PointsOfFiniteOrder(R0, F, UP, UPUP, R): Exports == Implementation where kgetGoodPrime(rec, res, h, b, d) == p:PI := 3 + u : Union(UPQ, "failed") while (u := goodRed(rec, res, h, b, d, p)) case "failed" repeat p := nextPrime(p::Z)::PI [p, u::UPQ] |