mirror of
https://github.com/kalmarek/GroupRings.jl.git
synced 2024-12-29 11:00:28 +01:00
remove excess of constructors
This commit is contained in:
parent
bf97fc083b
commit
93f48af087
@ -24,33 +24,23 @@ mutable struct GroupRing{Gr<:Group, T<:GroupElem} <: Ring
|
|||||||
basis_dict::Dict{T, Int}
|
basis_dict::Dict{T, Int}
|
||||||
pm::Array{Int,2}
|
pm::Array{Int,2}
|
||||||
|
|
||||||
function GroupRing{Gr, T}(G::Gr, basis::Vector{T}; fastm::Bool=false) where {Gr, T}
|
function GroupRing(G::Gr, basis::Vector{T}; fastm::Bool=false) where {Gr, T}
|
||||||
RG = new(G, basis, reverse_dict(basis))
|
RG = new{Gr, T}(G, basis, reverse_dict(basis))
|
||||||
fastm && fastm!(RG)
|
fastm && fastm!(RG)
|
||||||
return RG
|
return RG
|
||||||
end
|
end
|
||||||
|
|
||||||
function GroupRing{Gr, T}(G::Gr, b::Vector{T}, b_d::Dict{T, Int}, pm::Array{Int,2}) where {Gr,T}
|
function GroupRing(G::Gr, b::Vector{T}, b_d::Dict{T, Int}, pm::Array{Int,2}) where {Gr,T}
|
||||||
return new(G, b, b_d, pm)
|
return new{Gr, T}(G, b, b_d, pm)
|
||||||
end
|
end
|
||||||
|
|
||||||
function GroupRing{Gr}(G::Gr, pm::Array{Int,2}) where {Gr}
|
function GroupRing(G::Gr, pm::Array{Int,2}) where {Gr}
|
||||||
RG = new{Gr, elem_type(G)}(G)
|
RG = new{Gr, elem_type(G)}(G)
|
||||||
RG.pm = pm
|
RG.pm = pm
|
||||||
return RG
|
return RG
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function GroupRing(G::Gr, basis::Vector{T}; fastm::Bool=true) where {Gr<:Group, T<:GroupElem}
|
|
||||||
return GroupRing{Gr, T}(G, basis, fastm=fastm)
|
|
||||||
end
|
|
||||||
|
|
||||||
function GroupRing(G::Gr, b::Vector{T}, b_d::Dict{T,Int}, pm::Array{Int,2}) where {Gr<:Group, T<:GroupElem}
|
|
||||||
return GroupRing{Gr, T}(G, b, b_d, pm)
|
|
||||||
end
|
|
||||||
|
|
||||||
GroupRing(G::Gr, pm::Array{Int,2}) where {Gr<:Group} = GroupRing{Gr}(G, pm)
|
|
||||||
|
|
||||||
mutable struct GroupRingElem{T, A<:AbstractVector, GR<:GroupRing} <: RingElem
|
mutable struct GroupRingElem{T, A<:AbstractVector, GR<:GroupRing} <: RingElem
|
||||||
coeffs::A
|
coeffs::A
|
||||||
parent::GR
|
parent::GR
|
||||||
|
Loading…
Reference in New Issue
Block a user