mirror of
https://github.com/kalmarek/Groups.jl.git
synced 2024-12-25 18:15:29 +01:00
DirectProductGroup overloads: with vector and GroupElem
This commit is contained in:
parent
ba4400efbb
commit
10022fd31c
@ -69,8 +69,6 @@ end
|
|||||||
#
|
#
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
(G::DirectProductGroup)(g::DirectProductGroupElem) = G(g.elts)
|
|
||||||
|
|
||||||
doc"""
|
doc"""
|
||||||
(G::DirectProductGroup)(a::Vector, check::Bool=true)
|
(G::DirectProductGroup)(a::Vector, check::Bool=true)
|
||||||
> Constructs element of the $n$-fold direct product group `G` by coercing each
|
> Constructs element of the $n$-fold direct product group `G` by coercing each
|
||||||
@ -85,6 +83,10 @@ function (G::DirectProductGroup)(a::Vector, check::Bool=true)
|
|||||||
return DirectProductGroupElem(a)
|
return DirectProductGroupElem(a)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
(G::DirectProductGroup)() = DirectProductGroupElem([G.group() for _ in 1:G.n])
|
||||||
|
|
||||||
|
(G::DirectProductGroup)(g::DirectProductGroupElem) = G(g.elts)
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
#
|
#
|
||||||
# Basic manipulation
|
# Basic manipulation
|
||||||
|
Loading…
Reference in New Issue
Block a user