fix the action of WreathProdElem on MatElem

mul! is not correct for NmodRing??
This commit is contained in:
kalmarek 2018-08-18 23:23:52 +02:00
parent 42f915b91d
commit 95066b9c56

View File

@ -10,8 +10,8 @@ struct SpecialLinearGroup <: SymmetrizedGroup
if p == 0 if p == 0
G = MatrixSpace(Nemo.ZZ, n, n) G = MatrixSpace(Nemo.ZZ, n, n)
else else
F, a = FiniteField(p, 1, "a") R = Nemo.NmodRing(UInt(p))
G = MatrixSpace(F, n, n) G = MatrixSpace(R, n, n)
end end
return new(args, G) return new(args, G)
end end
@ -83,9 +83,7 @@ function (g::WreathProductElem)(A::MatElem)
G = matrix_emb(g.n, g_inv.p) G = matrix_emb(g.n, g_inv.p)
G_inv = matrix_emb(g_inv.n, g.p) G_inv = matrix_emb(g_inv.n, g.p)
M = parent(A) M = parent(A)
res = M(G_inv) return M(G)*A*M(G_inv)
Nemo.mul!(res, A, res)
return Nemo.mul!(res, M(G), res)
end end
import Base.* import Base.*
@ -100,7 +98,7 @@ function *(x::AbstractAlgebra.MatElem, P::Generic.perm)
n = cols(x) n = cols(x)
for i = 1:m for i = 1:m
for j = 1:n for j = 1:n
z[i, j] = x[i, P[j]] z[i, j] = x[i,P[j]]
end end
end end
return z return z