diff options
author | dos-reis <gdr@axiomatics.org> | 2010-04-22 01:40:53 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2010-04-22 01:40:53 +0000 |
commit | 9fac9abefef7f727a59b7861317d148352a43d88 (patch) | |
tree | 6cf281301d4609d71aae0540b6cd098abd41de2b /src/algebra/cycles.spad.pamphlet | |
parent | dca6da4bba9a14e544345d4b54f623450d47f283 (diff) | |
download | open-axiom-9fac9abefef7f727a59b7861317d148352a43d88.tar.gz |
* algebra/irsn.spad.pamphlet (IrrRepSymNatPackage): Tidy.
* algebra/partperm.spad.pamphlet (PartitionsAndPermutations): Likewise.
* algebra/cycles.spad.pamphlet (complete$CycleIndicators): Now
take only positive integers.
(powerSum$CycleIndicators): Likewise.
(elementary$CycleIndicators): Likewise.
(alternating$CycleIndicators): Likewise.
(cyclic$CycleIndicators): Likewise.
(dihedral$CycleIndicators): Likewise.
(graphs$CycleIndicators): Likewise.
Diffstat (limited to 'src/algebra/cycles.spad.pamphlet')
-rw-r--r-- | src/algebra/cycles.spad.pamphlet | 55 |
1 files changed, 28 insertions, 27 deletions
diff --git a/src/algebra/cycles.spad.pamphlet b/src/algebra/cycles.spad.pamphlet index b8bf2e16..c2941dd3 100644 --- a/src/algebra/cycles.spad.pamphlet +++ b/src/algebra/cycles.spad.pamphlet @@ -33,35 +33,36 @@ CycleIndicators: Exports == Implementation where RN ==> Fraction Integer FR ==> Factored Integer macro NNI == NonNegativeInteger + macro PI == PositiveInteger Exports ==> with - complete: NNI -> SPOL RN + complete: PI -> SPOL RN ++\spad{complete n} is the \spad{n} th complete homogeneous ++ symmetric function expressed in terms of power sums. ++ Alternatively it is the cycle index of the symmetric ++ group of degree n. - powerSum: NNI -> SPOL RN + powerSum: PI -> SPOL RN ++\spad{powerSum n} is the \spad{n} th power sum symmetric ++ function. - elementary: NNI -> SPOL RN + elementary: PI -> SPOL RN ++\spad{elementary n} is the \spad{n} th elementary symmetric ++ function expressed in terms of power sums. - alternating: NNI -> SPOL RN + alternating: PI -> SPOL RN ++\spad{alternating n} is the cycle index of the ++ alternating group of degree n. - cyclic: NNI -> SPOL RN --cyclic group + cyclic: PI -> SPOL RN --cyclic group ++\spad{cyclic n} is the cycle index of the ++ cyclic group of degree n. - dihedral: NNI -> SPOL RN --dihedral group + dihedral: PI -> SPOL RN --dihedral group ++\spad{dihedral n} is the cycle index of the ++ dihedral group of degree n. - graphs: NNI -> SPOL RN + graphs: PI -> SPOL RN ++\spad{graphs n} is the cycle index of the group induced on ++ the edges of a graph by applying the symmetric function to the ++ n nodes. @@ -83,7 +84,7 @@ CycleIndicators: Exports == Implementation where ++ of the two groups whose cycle indices are \spad{s1} and ++ \spad{s2}. - SFunction:L I -> SPOL RN + SFunction:L PI -> SPOL RN ++\spad{SFunction(li)} is the S-function of the partition \spad{li} ++ expressed in terms of power sum symmetric functions. @@ -99,24 +100,24 @@ CycleIndicators: Exports == Implementation where trm: PTN -> SPOL RN trm pt == monomial(inv(pdct(pt) :: RN),pt) - list: Stream L I -> L L I + list: Stream L PI -> L L PI list st == entries complete st complete i == i=0 => 1 - +/[trm(partition pt) for pt in list(partitions i)] + +/[trm partition pt for pt in list partitions i] - even?: L I -> B + even?: L PI -> B even? li == even?( #([i for i in li | even? i])) alternating i == - 2 * _+/[trm(partition li) for li in list(partitions i) | even? li] + 2 * _+/[trm partition li for li in list partitions i | even? li] elementary i == i=0 => 1 - +/[(spol := trm(partition pt); even? pt => spol; -spol) - for pt in list(partitions i)] + +/[(spol := trm partition pt; even? pt => spol; -spol) + for pt in list partitions i] divisors: I -> L I divisors n == @@ -125,23 +126,23 @@ CycleIndicators: Exports == Implementation where [[a.factor**j for j in 1..a.exponent] for a in b]); if #(b) = 1 then c else concat(n,c) - ss: (I,I) -> SPOL RN + ss: (PI,I) -> SPOL RN ss(n,m) == - li : L I := [n for j in 1..m] + li : L PI := [n for j in 1..m] monomial(1,partition li) powerSum n == ss(n,1) cyclic n == n = 1 => powerSum 1 - +/[(eulerPhi(i) / n) * ss(i,numer(n/i)) for i in divisors n] + +/[(eulerPhi(i) / n) * ss(i::PI,numer(n/i)) for i in divisors n] dihedral n == k := n quo 2 odd? n => (1/2) * cyclic n + (1/2) * ss(2,k) * powerSum 1 (1/2) * cyclic n + (1/4) * ss(2,k) + (1/4) * ss(2,k-1) * ss(1,2) - trm2: L I -> SPOL RN + trm2: L PI -> SPOL RN trm2 li == lli := powers(partition li)$PTN xx := 1/(pdct partition li) @@ -151,12 +152,12 @@ CycleIndicators: Exports == Implementation where k := ll0 quo 2 c := odd? ll0 => ss(ll0,ll1 * k) - ss(k,ll1) * ss(ll0,ll1 * (k - 1)) + ss(k::PI,ll1) * ss(ll0,ll1 * (k - 1)) c := c * ss(ll0,ll0 * ((ll1*(ll1 - 1)) quo 2)) prod2 : SPOL RN := 1 for r in lli | first(r) < ll0 repeat r0 := first r; r1 := second r - prod2 := ss(lcm(r0,ll0),gcd(r0,ll0) * r1 * ll1) * prod2 + prod2 := ss(lcm(r0,ll0)::PI,gcd(r0,ll0) * r1 * ll1) * prod2 prod := c * prod2 * prod xx * prod @@ -180,24 +181,24 @@ CycleIndicators: Exports == Implementation where cap(spol1,spol2) == eval cup(spol1,spol2) - mtpol: (I,SPOL RN) -> SPOL RN + mtpol: (PI,SPOL RN) -> SPOL RN mtpol(n,spol)== zero? spol => 0 - deg := partition [n*k for k in (degree spol)::L(I)] + deg := partition [n*k for k in (degree spol)::L(PI)] monomial(leadingCoefficient spol,deg) + mtpol(n,reductum spol) - evspol: ((I -> SPOL RN),SPOL RN) -> SPOL RN + evspol: ((PI -> SPOL RN),SPOL RN) -> SPOL RN evspol(fn2,spol) == zero? spol => 0 lc := leadingCoefficient spol - prod := */[fn2 i for i in (degree spol)::L(I)] + prod := */[fn2 i for i in (degree spol)::L(PI)] lc * prod + evspol(fn2,reductum spol) wreath(spol1,spol2) == evspol(mtpol(#1,spol2),spol1) SFunction li== a:Matrix SPOL RN := - matrix [[complete((k -j+i)::NNI) for k in li for j in 1..#li] + matrix [[complete((k -j+i)::PI) for k in li for j in 1..#li] for i in 1..#li] determinant a @@ -210,7 +211,7 @@ CycleIndicators: Exports == Implementation where #li1 < #li2 => error "skewSFunction: partition1 does not include partition2" li2:=roundup (li1,li2) - a:Matrix SPOL RN:=matrix [[complete((k-li2.i-j+i)::NNI) + a:Matrix SPOL RN:=matrix [[complete((k-li2.i-j+i)::PI) for k in li1 for j in 1..#li1] for i in 1..#li1] determinant a @@ -252,7 +253,7 @@ EvaluateCycleIndicators(F):T==C where pt:PTN spol:SPOL RN i:I - evp(fn, pt)== */[fn i for i in pt::(L I)] + evp(fn, pt)== */[fn i for i in pt::L(PositiveInteger)] eval(fn,spol)== if spol=0 |