diff --git a/src/ComplexR.jl b/src/ComplexR.jl index 69aec7c4..c0ee081e 100644 --- a/src/ComplexR.jl +++ b/src/ComplexR.jl @@ -63,7 +63,7 @@ function complex_reflection_group(i::Integer) elseif i==35 coxgroup(:E,6) elseif i==36 coxgroup(:E,7) elseif i==37 coxgroup(:E,8) - else t=TypeIrred(Dict(:series=>:ST,:ST=>Int(i))) + else t=TypeIrred(series=:ST,ST=Int(i)) PRG(simpleroots(t),simplecoroots(t)) end end @@ -76,7 +76,7 @@ function complex_reflection_group(p,q,r) elseif p==2 return rootdatum(:so,q==2 ? 2r : 2r+1) elseif p==q && r==2 return coxgroup(:I,2,p) end - t=TypeIrred(Dict(:series=>:ST,:p=>p,:q=>q,:rank=>r)) + t=TypeIrred(;series=:ST,p,q,rank=r) PRG(simpleroots(t),simplecoroots(t)) end diff --git a/src/Cosets.jl b/src/Cosets.jl index 77669152..fe87799c 100644 --- a/src/Cosets.jl +++ b/src/Cosets.jl @@ -740,7 +740,7 @@ function PermRoot.refltype(WF::CoxeterCoset)::Vector{TypeIrred} end end for i in 2:length(c) o[i].indices=indices(o[i-1]).^phires end - TypeIrred(Dict(:orbit=>o,:twist=>twist)) + TypeIrred(;orbit=o,twist) end end end @@ -1071,7 +1071,7 @@ function PermRoot.refltype(WF::PRC) W=Group(WF) t=deepcopy(refltype(W)) if isone(WF.phi) - return map(x->TypeIrred(Dict(:orbit=>[x],:twist=>Perm())),t) + return map(x->TypeIrred(orbit=[x],twist=Perm()),t) end subgens=map(x->refls(W,x.indices),t) c=Perm(map(x->sort(x.^WF.phi),subgens),map(sort,subgens)) @@ -1105,7 +1105,7 @@ function PermRoot.refltype(WF::PRC) map(ratio,prr[inclusion(W,rr).^WF.phi],prr[inclusion(W,img)]) end typ=map(c) do orb - to=TypeIrred(Dict{Symbol,Any}(:orbit=>map(copy,t[orb]))) + to=TypeIrred(orbit=map(copy,t[orb])) scalar=Cyc{Rational{Int}}[] for i in eachindex(orb) next=i==length(orb) ? 1 : i+1 diff --git a/src/CoxGroups.jl b/src/CoxGroups.jl index 437d9a69..bcc3ecef 100644 --- a/src/CoxGroups.jl +++ b/src/CoxGroups.jl @@ -933,7 +933,7 @@ end PermRoot.action(W::CoxSym,i,p)=i^p PermRoot.refltype(W::CoxSym)=get!(W,:refltype)do - [TypeIrred(Dict(:series=>:A,:indices=>collect(1:length(W.d)-1)))] + [TypeIrred(series=:A,indices=collect(1:length(W.d)-1))] end PermRoot.inclusiongens(W::CoxSym)=W.d @@ -1052,8 +1052,7 @@ Base.show(io::IO, W::CoxHyp)=print(io,"coxhyp($(W.n))") PermRoot.action(W::CoxHyp,i,p)=abs(i^p) -PermRoot.refltype(W::CoxHyp)=[TypeIrred(Dict(:series=>:B, - :indices=>collect(1:W.n)))] +PermRoot.refltype(W::CoxHyp)=[TypeIrred(series=:B,indices=collect(1:W.n))] CoxGroups.nref(W::CoxHyp)=length(W.roots) diff --git a/src/PermRoot.jl b/src/PermRoot.jl index a875b774..78b3a24b 100644 --- a/src/PermRoot.jl +++ b/src/PermRoot.jl @@ -762,7 +762,7 @@ prim=[ de=filter(x->o==max(2,x.d),de) # here we have length(de)<=2 ST=filter(i->r==prim[i].r && s==prim[i].s && o==prim[i].o,eachindex(prim)) # if isempty(de) && length(ST)==1 # shortcut -# return Dict(:series=>:ST, :ST=>only(ST), :rank=> r) +# return TypeIrred(series=:ST, ST=only(ST), rank=r) # end h=div(sum(order,refls(W,unique_refls(W))),r) # Coxeter number if length(de)>1 @@ -787,8 +787,8 @@ prim=[ if d.d==2 && d.e==1 return TypeIrred(series=:B,rank=r) end if d.d==1 && d.e==2 return TypeIrred(series=:D,rank=r) end if d.d==1 && r==2 - if d.e==4 return TypeIrred(series=>:B, rank=2) - elseif d.e==6 return TypeIrred(series=>:G, rank=2) + if d.e==4 return TypeIrred(series=:B, rank=2) + elseif d.e==6 return TypeIrred(series=:G, rank=2) else return TypeIrred(series=:I, rank=2, bond=d.e) end end @@ -877,7 +877,7 @@ function findgoodcartan(H,g,C) return find(Int[],g) end -# try to make indecomposable cartan(H,p) like C by rotating roots +# try to make cartan(H,p) like C by rotating roots (both indecomposable) function fixCartan(H,C,p) CH=cartan(H,p) r=Weyl.type_fincox_cartan(CH) @@ -980,6 +980,7 @@ julia> t.indices ``` """ function refltype(W::PermRootGroup) + verbose=false get!(W,:refltype)do if isempty(gens(W)) return TypeIrred[] end map(diagblocks(cartan(W))) do I @@ -987,25 +988,30 @@ function refltype(W::PermRootGroup) CR=cartan(R) d=TypeIrred(R) C=cartan(d) - if C==CR indices=I + if C==CR if d.series!=:ST d=Weyl.type_fincox_cartan(CR) end - else - good=findgoodcartan(R,eachindex(gens(R)),C) - if isnothing(good) good=findgoodcartan(R,eachindex(roots(R)),C) end - if isnothing(good) good=findgoodgens(R,unique_refls(R),d) - better=fixCartan(R,C,good) - if !isnothing(better) good=better[2] - else better=findgensDiagCartan(R,C,good) - if !isnothing(better) good=better[1] - else better=findgensDiagCartan2(R,C) - if !isnothing(better) good=better[1] end - end - end - if d.series!=:ST d=Weyl.type_fincox_cartan(cartan(R,good)) end - end - indices=inclusion(R,W,good) + d.indices=I + return d + end + if verbose print("#1") end + good=findgoodcartan(R,eachindex(gens(R)),C) + if !isnothing(good) d.indices=inclusion(R,W,good); return d end + if verbose print("#2") end + good=findgoodcartan(R,eachindex(roots(R)),C) + if !isnothing(good) d.indices=inclusion(R,W,good); return d end + if verbose print("#3") end + good=findgoodgens(R,unique_refls(R),d) + better=fixCartan(R,C,good) + if !isnothing(better) d.indices=inclusion(R,W,better[2]); return d end + better=findgensDiagCartan(R,C,good) + if verbose print("#4") end + if !isnothing(better) good=better[1] + else better=findgensDiagCartan2(R,C) + if verbose print("#5") end + if !isnothing(better) good=better[1] end end - d.indices=indices + if d.series!=:ST d=Weyl.type_fincox_cartan(cartan(R,good)) end + d.indices=inclusion(R,W,good) d end end::Vector{TypeIrred} @@ -1729,7 +1735,7 @@ end PRG(a::Matrix,b::Matrix;k...)=PRG(toL(a),toL(b);k...) PRG(i::Integer;T1=Perms.Idef)=PRG(Perm{T1}[],Perm{T1}(),Matrix{Int}[], - Vector{Int}[],Vector{Int}[],Dict{Symbol,Any}(:rank=>i)) + Vector{Int}[],Vector{Int}[],Dict{Symbol,Any}(:rank=>i)) """ `radical(G::ComplexReflectionGroup)` diff --git a/src/Uch.jl b/src/Uch.jl index 98a26355..716d7693 100644 --- a/src/Uch.jl +++ b/src/Uch.jl @@ -343,12 +343,12 @@ function UnipotentCharacters(t::TypeIrred) uc[:almostHarishChandra]=map(uc[:harishChandra])do s res=Dict{Symbol,Any}() for f in [:levi, :cuspidalName, :eigenvalue, :charNumbers] res[f]=s[f] end - res[:relativeType]=TypeIrred(Dict(:orbit=> + res[:relativeType]=TypeIrred(orbit= map(eachindex(t.orbit))do i r=copy(s[:relativeType]) r.indices=r.indices.+(i-1)*rank(t.orbit[1]) r - end, :twist=>Perm())) + end, twist=Perm()) if haskey(s[:relativeType],:twist) && s[:relativeType][:twist]!=Perm() error() end diff --git a/src/Weyl.jl b/src/Weyl.jl index d6c17557..9b84b137 100644 --- a/src/Weyl.jl +++ b/src/Weyl.jl @@ -402,7 +402,7 @@ function type_fincox_cartan(m::AbstractMatrix) if !all(==(2),diag(m)) return nothing end s=two_tree(m) if isnothing(s) return nothing end - t=TypeIrred(Dict{Symbol,Any}(:rank=>rank)) + t=TypeIrred(;rank) if s isa Tuple # types D,E (vertex,b1,b2,b3)=s if length(b2)==1 t.series=:D diff --git a/test/Tests.jl b/test/Tests.jl index 6e304111..bd50d9d7 100644 --- a/test/Tests.jl +++ b/test/Tests.jl @@ -1540,7 +1540,7 @@ test[:eigen]=(applicable=isspetsial, function Tqeigen(W) uc=UnipotentCharacters(W) - e=Uch.qeigen(uc) + e=Families.qeigen(uc) for i in eachindex(uc.families) f=uc.families[i] q=Families.qeigen(f)