From 4bb52bd34b114c8694793038da677879a79d9281 Mon Sep 17 00:00:00 2001 From: kalmar Date: Thu, 27 Jul 2017 22:06:32 +0200 Subject: [PATCH] my Characters return Julia's Ints --- src/Projections.jl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Projections.jl b/src/Projections.jl index ae47405..f25b3bd 100644 --- a/src/Projections.jl +++ b/src/Projections.jl @@ -47,14 +47,15 @@ end # ############################################################################### -function central_projection(RG::GroupRing, chi::Function, T::Type=Rational{Int}) +function central_projection(RG::GroupRing, chi::AbstractCharacter, + T::Type=Rational{Int}) result = RG(T) result.coeffs = full(result.coeffs) dim = chi(RG.group()) ord = Int(order(RG.group)) for g in RG.basis - result[g] = convert(T, (Int(dim)//ord)*Int(chi(g))) + result[g] = convert(T, (dim//ord)*chi(g)) end return result