1
0
mirror of https://github.com/kalmarek/PropertyT.jl.git synced 2024-11-23 08:15:29 +01:00

faster & simpler Cstar_repr

This commit is contained in:
kalmarek 2017-11-08 09:29:12 +01:00
parent e636c97738
commit 2d02c98947

View File

@ -187,15 +187,7 @@ function reconstruct_sol{T<:GroupElem, S<:Nemo.perm}(preps::Dict{T, S},
end
function Cstar_repr{T}(x::GroupRingElem{T}, mreps::Dict)
res = spzeros(size(mreps[first(keys(mreps))])...)
for g in parent(x).basis
if x[g] != zero(T)
res .+= Float64(x[g]).*mreps[g]
end
end
return res
return sum(x[g].*mreps[g] for g in parent(x).basis if x[g] != zero(T))
end
function orthSVD(M::AbstractMatrix)