From ab0b6c871a1e4d6d7acc5e4fa3e6e789b211445a Mon Sep 17 00:00:00 2001 From: kalmar Date: Wed, 17 May 2017 11:34:03 +0200 Subject: [PATCH] use reverse_dict --- src/GroupRings.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GroupRings.jl b/src/GroupRings.jl index 7cf3a84..0db8715 100644 --- a/src/GroupRings.jl +++ b/src/GroupRings.jl @@ -73,7 +73,7 @@ function GroupRing(G::Group, pm::Array{Int,2}, basis::Vector) size(pm,1) == size(pm,2) || throw("pm must be of size (n,n), got $(size(pm))") eltype(basis) == elem_type(G) || throw("basis must consist of elements of $G") - basis_dict = Dict(g => i for (i,g) in enumerate(basis)) + basis_dict = reverse_dict(basis) return GroupRing(Group, pm, basis, basis_dict) end