update to AA-0.9

This commit is contained in:
kalmarek 2020-04-06 16:39:26 +02:00
parent 9225d2153f
commit ef616f11bd
No known key found for this signature in database
GPG Key ID: 8BF1A3855328FC15
3 changed files with 14 additions and 13 deletions

View File

@ -6,9 +6,11 @@ version = "0.3.0"
[deps]
AbstractAlgebra = "c3fe647b-3220-5bb0-a1ea-a7954cac585d"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Markdown = "d6f4376e-aef5-505a-96c1-9c027394607a"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
[compat]
AbstractAlgebra = "^0.9.0"
[extras]
Groups = "5d8bd718-bd84-11e8-3b40-ad14f4a32557"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

View File

@ -4,8 +4,7 @@ using AbstractAlgebra
import AbstractAlgebra: Group, NCRing, NCRingElem, parent, elem_type, parent_type, addeq!, mul!
using SparseArrays
using LinearAlgebra
using Markdown
import LinearAlgebra
import Base: convert, show, hash, ==, +, -, *, ^, //, /, length, getindex, setindex!, eltype, one, zero
@ -72,7 +71,7 @@ function GroupRingElem(c::AbstractVector, RG::GroupRing)
return GroupRingElem{eltype(c), typeof(c), typeof(RG)}(c, RG)
end
function GroupRing(G::Generic.PermGroup; cachedmul::Bool=false)
function GroupRing(G::Generic.SymmetricGroup; cachedmul::Bool=false)
return GroupRing(G, vec(collect(G)), cachedmul=cachedmul)
end
@ -342,7 +341,7 @@ function -(X::GroupRingElem{S}, Y::GroupRingElem{T}) where {S, T}
addeq!((-Y), X)
end
@doc doc"""
"""
fmac!(result::AbstractVector{T},
X::AbstractVector,
Y::AbstractVector,
@ -377,7 +376,7 @@ function fmac!(result::AbstractVector{T},
return result
end
@doc doc"""
"""
GRmul!(result::AbstractVector{T}, X::AbstractVector, Y::AbstractVector,
pm::Matrix{<:Integer}) where T
> The most specialised multiplication for `X` and `Y` (intended for `coeffs` of
@ -399,7 +398,7 @@ function GRmul!(result::AbstractVector{T},
return fmac!(result, X, Y, pm)
end
@doc doc"""
"""
mul!(result::GroupRingElem, X::GroupRingElem, Y::GroupRingElem)
> In-place multiplication for `GroupRingElem`s `X` and `Y`.
> `mul!` will make use the initialised entries of `pm` attribute of

View File

@ -6,8 +6,8 @@ using SparseArrays
@testset "GroupRings" begin
@testset "Constructors: PermutationGroup" begin
G = PermutationGroup(3)
@testset "Constructors: SymmetricGroup" begin
G = SymmetricGroup(3)
@test isa(GroupRing(G), AbstractAlgebra.NCRing)
@test isa(GroupRing(G), GroupRing)
@ -18,7 +18,7 @@ using SparseArrays
@test isdefined(RG, :basis_dict) == true
@test isdefined(RG, :pm) == false
@test isa(GroupRing(PermutationGroup(6), rand(1:6, 6,6)), GroupRing)
@test isa(GroupRing(SymmetricGroup(6), rand(1:6, 6,6)), GroupRing)
RG = GroupRing(G, cachedmul=true)
@test isdefined(RG, :pm) == true
@ -76,7 +76,7 @@ using SparseArrays
end
@testset "GroupRingElems constructors/basic manipulation" begin
G = PermutationGroup(3)
G = SymmetricGroup(3)
RG = GroupRing(G, cachedmul=true)
a = rand(6)
@test isa(GroupRingElem(a, RG), GroupRingElem)
@ -129,7 +129,7 @@ using SparseArrays
end
@testset "Arithmetic" begin
G = PermutationGroup(3)
G = SymmetricGroup(3)
RG = GroupRing(G, cachedmul=true)
a = RG(ones(Int, order(G)))
@ -224,7 +224,7 @@ using SparseArrays
@testset "HPC multiplicative operations" begin
G = PermutationGroup(5)
G = SymmetricGroup(5)
RG = GroupRing(G, cachedmul=true)
RG2 = GroupRing(G, cachedmul=false)