diff options
author | dos-reis <gdr@axiomatics.org> | 2010-06-21 03:16:39 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2010-06-21 03:16:39 +0000 |
commit | afaaaac2b55741bfe43099f819fd4a9592b1c022 (patch) | |
tree | 7a5bbd28009759b1c787d3df4c4ba5960cd11280 /src/algebra/sgcf.spad.pamphlet | |
parent | 640d839b4de4d0daf0dde00ba08eab6d264160ad (diff) | |
download | open-axiom-afaaaac2b55741bfe43099f819fd4a9592b1c022.tar.gz |
Revert previous erroneous commit
Diffstat (limited to 'src/algebra/sgcf.spad.pamphlet')
-rw-r--r-- | src/algebra/sgcf.spad.pamphlet | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/src/algebra/sgcf.spad.pamphlet b/src/algebra/sgcf.spad.pamphlet index 20fdb544..72669658 100644 --- a/src/algebra/sgcf.spad.pamphlet +++ b/src/algebra/sgcf.spad.pamphlet @@ -212,12 +212,11 @@ SymmetricGroupCombinatoricFunctions(): public == private where for t in 0..(m-2) repeat s : I := 0 sOld: I - y : I := 0 - while y <= n repeat + y : I + for y in 0..n repeat sOld := s s := s + numberOfImproperPartitions(n-y,m-t-1) if s > k then leave - y := y + 1 l := append(l,list(y)$(L I))$(L I) k := k - sOld n := n - y @@ -242,13 +241,12 @@ SymmetricGroupCombinatoricFunctions(): public == private where s : I := 0 cm := cm - 1 sOld : I - y : I := n - while y >= 1 repeat --determination of the next son + y : I + for y in n..1 by -1 repeat --determination of the next son sOld := s -- remember old s -- this functions counts the number of elements in a subtree s := s + numberOfImproperPartitionsInternal(n-y,m,cm) if s > k then leave - y := y - 1 -- y is the next son, so put it into the pathlist "nonZero" nonZeros := append(nonZeros,list(y)$(L I))$(L I) k := k - sOld --updating @@ -272,10 +270,9 @@ SymmetricGroupCombinatoricFunctions(): public == private where mm : I := k s : I := m for t in 0..(m-1) repeat - y : Integer := s-1 - while y <= (n+1) repeat + y : Integer + for y in (s-1)..(n+1) repeat if binomial$ICF (y,s) > mm then leave - y := y + 1 l := append (l,list(y-1)$(L I)) mm := mm - binomial$ICF (y-1,s) s := s-1 |