1
0
mirror of https://github.com/kalmarek/PropertyT.jl.git synced 2024-11-26 17:05:27 +01:00

fix rankOne_projections for the new type of GroupRingElem

This commit is contained in:
kalmarek 2017-11-17 15:29:09 +01:00
parent bdadac33f4
commit 7ee7a30829

View File

@ -91,19 +91,22 @@ function idempotents(RG::GroupRing{Generic.PermGroup}, T::Type=Rational{Int})
return unique(idems)
end
function rankOne_projection(chi::PropertyT.PermCharacter, idems::Vector{T}) where {T<:GroupRingElem}
function rankOne_projection(chi::PropertyT.PermCharacter,
idems::Vector{T}) where {T<:GroupRingElem}
RG = parent(first(idems))
S = eltype(first(idems))
ids = [[one(RG, T)]; idems]
ids = [one(RG, S); idems]
zzz = zero(S)
for (i,j,k) in Base.product(ids, ids, ids)
if chi(i) == zero(T) || chi(j) == zero(T) || chi(k) == zero(T)
if chi(i) == zzz || chi(j) == zzz || chi(k) == zzz
continue
end
elt = i*j*k
elt^2 == elt || continue
if chi(elt) == one(T)
if chi(elt) == one(S)
return elt
# return (i,j,k)
end