mirror of
https://github.com/kalmarek/PropertyT.jl.git
synced 2024-11-19 07:20:28 +01:00
faster version of reconstruct_sol
This commit is contained in:
parent
fd32ddbe82
commit
ff4f9e7857
@ -114,17 +114,20 @@ function matrix_reps{T<:GroupElem}(G::Group, S::Vector{T}, AutS::Group, radius::
|
|||||||
return mreps
|
return mreps
|
||||||
end
|
end
|
||||||
|
|
||||||
function reconstruct_sol(mreps::Dict, Us::Vector, Ps::Vector, dims::Vector)
|
function reconstruct_sol{T<:GroupElem, S<:AbstractArray}(mreps::Dict{T, S},
|
||||||
recP = zeros(size(Us[1],1), size(Us[1],1))
|
Us::Vector, Ps::Vector, dims::Vector)
|
||||||
|
|
||||||
for g in keys(mreps)
|
n = size(Us[1],1)
|
||||||
for π in 1:endof(Us)
|
recP = zeros(Float64, (n,n))
|
||||||
recP .+= dims[π] .* mreps[g]*transform(Us[π]', Ps[π])*mreps[inv(g)]
|
Ust = transpose.(Us)
|
||||||
end
|
for g in keys(mreps)
|
||||||
end
|
A, B = mreps[g], mreps[inv(g)]
|
||||||
recP .*= 1/length(collect(keys(mreps)))
|
for π in 1:length(Us)
|
||||||
|
recP .+= dims[π].* (A * Us[π]*Ps[π]*Ust[π] * B)
|
||||||
return recP
|
end
|
||||||
|
end
|
||||||
|
recP .*= 1/length(keys(mreps))
|
||||||
|
return recP
|
||||||
end
|
end
|
||||||
|
|
||||||
function Cstar_repr(x::GroupRingElem, mreps)
|
function Cstar_repr(x::GroupRingElem, mreps)
|
||||||
|
Loading…
Reference in New Issue
Block a user