Skip to content

Commit c675fec

Browse files
committed
update docs
1 parent 94a3400 commit c675fec

File tree

11 files changed

+216
-97
lines changed

11 files changed

+216
-97
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ SO3 = LieGroup("SO", 3)
2525
a = MatrixGroupAction(SO3, [vars])
2626
V = FixedDegreePolynomials(vars, 2)
2727
ρ = GroupRepresentation(a, V)
28+
2829
irrs = irreducibles(ρ)
2930
```
3031
```

docs/make.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,10 @@ makedocs(;
1717
pages=[
1818
"Introduction" => "index.md",
1919
"Reductive groups" => [
20-
"Group types" => "groups/types.md",
20+
"Types of groups" => "groups/types.md",
2121
"Finite groups" => "groups/finite.md",
2222
"Lie groups" => "groups/lie.md",
2323
"Direct products" => "groups/products.md",
24-
"Group Elements" => "groups/elements.md",
2524
],
2625
"Representations of reductive groups" => [
2726
"Vector spaces" => "representations/spaces.md",

docs/src/groups/elements.md

Lines changed: 0 additions & 18 deletions
This file was deleted.

docs/src/groups/finite.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Finite groups
2+
3+
TBW

docs/src/groups/lie.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,19 @@
11
# Lie groups
22

3+
The computations with Lie groups are done by passing to their associated Lie algebras. We distinguish between Lie groups that act by scalings (represented by [`ScalingLieGroup`](@ref)) and basic reductive matrix Lie groups, like ``\mathrm{SO}(n)`` (represented by [`LieGroup`](@ref)).
4+
5+
## Lie groups
6+
37
```@docs
4-
algebra(::AbstractGroup{Lie})
8+
ScalingLieGroup
9+
LieGroup
510
```
611

712
## Lie algebras
813

914
```@docs
1015
AbstractLieAlgebra
16+
algebra(::AbstractGroup{Lie})
1117
name(::AbstractLieAlgebra)
1218
basis(::AbstractLieAlgebra)
1319
chevalley_basis(::AbstractLieAlgebra)

docs/src/groups/products.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22

33
```@docs
44
AbstractDirectProductGroup
5+
DirectProductGroup
56
```

docs/src/groups/types.md

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,9 @@
1-
# Group types
2-
3-
```@docs
4-
AbstractGroup
5-
```
6-
7-
Each [`AbstractGroup`](@ref) has a [`GroupType`](@ref) that are described below.
1+
# Types of groups
82

93
```@docs
104
GroupType
115
Finite
126
Lie
137
Mixed
8+
AbstractGroup
149
```

src/decompositions/irred-decomp.jl

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,41 @@ function irreducibles(
5858
return [IrreducibleRepresentation(action(ρ), hwv) for hwv in hw_vectors]
5959
end
6060

61+
# function irreducibles_old(
62+
# ρ::GroupRepresentation{A, S}
63+
# ) where {T, F, A<:AbstractGroupAction{Lie}, S<:SymmetricPower{T, F, <:HighestWeightModule}}
64+
# V = space(ρ)
65+
# power(V) == 1 && return [IrreducibleRepresentation(action(ρ), base_space(V))]
66+
# ws = weight_structure(base_space(V))
67+
# sym_ws = sym(ws, power(V))
68+
# println("old nweights: ", nweights(sym_ws))
69+
# println("old sum of dims: ", sum([dim(space(sym_ws[w])) for w in weights(sym_ws)]))
70+
# Xs = positive_root_elements(algebra(action(ρ)))
71+
# hw_vectors = common_nullspace_as_weight_vectors(Xs, action(ρ), sym_ws)
72+
# return [IrreducibleRepresentation(action(ρ), hwv) for hwv in hw_vectors]
73+
# end
74+
75+
# function irreducibles_old(
76+
# ρ::GroupRepresentation{A, T}
77+
# ) where {A<:AbstractGroupAction{Lie}, T<:SymmetricPower}
78+
# V = space(ρ)
79+
# ρ_base = GroupRepresentation(action(ρ), base_space(V))
80+
# irreds_base = irreducibles(ρ_base)
81+
# if length(irreds_base) == 1
82+
# V = SymmetricPower(space(first(irreds_base)), power(V))
83+
# ρᵢ = GroupRepresentation(action(ρ), V)
84+
# return irreducibles_old(ρᵢ)
85+
# end
86+
# mexps = multiexponents(degree=power(V), nvars=length(irreds_base))
87+
# irreds = IrreducibleRepresentation{A}[]
88+
# for mexp in mexps
89+
# Vᵢ = TensorProduct([SymmetricPower(space(irreds_base[idx]), val) for (val, idx) in zip(mexp.nzval, mexp.nzind)])
90+
# ρᵢ = GroupRepresentation(action(ρ), Vᵢ)
91+
# append!(irreds, irreducibles(ρᵢ))
92+
# end
93+
# return irreds
94+
# end
95+
6196
function irreducibles(
6297
ρ::GroupRepresentation{A, S}
6398
) where {T, F, A<:AbstractGroupAction{Lie}, S<:SymmetricPower{T, F, <:HighestWeightModule}}
@@ -71,41 +106,6 @@ function irreducibles(
71106
return [IrreducibleRepresentation(action(ρ), hwv) for hwv in hw_vectors]
72107
end
73108

74-
function irreducibles_old(
75-
ρ::GroupRepresentation{A, S}
76-
) where {T, F, A<:AbstractGroupAction{Lie}, S<:SymmetricPower{T, F, <:HighestWeightModule}}
77-
V = space(ρ)
78-
power(V) == 1 && return [IrreducibleRepresentation(action(ρ), base_space(V))]
79-
ws = weight_structure(base_space(V))
80-
sym_ws = sym(ws, power(V))
81-
println("old nweights: ", nweights(sym_ws))
82-
println("old sum of dims: ", sum([dim(space(sym_ws[w])) for w in weights(sym_ws)]))
83-
Xs = positive_root_elements(algebra(action(ρ)))
84-
hw_vectors = common_nullspace_as_weight_vectors(Xs, action(ρ), sym_ws)
85-
return [IrreducibleRepresentation(action(ρ), hwv) for hwv in hw_vectors]
86-
end
87-
88-
function irreducibles_old(
89-
ρ::GroupRepresentation{A, T}
90-
) where {A<:AbstractGroupAction{Lie}, T<:SymmetricPower}
91-
V = space(ρ)
92-
ρ_base = GroupRepresentation(action(ρ), base_space(V))
93-
irreds_base = irreducibles(ρ_base)
94-
if length(irreds_base) == 1
95-
V = SymmetricPower(space(first(irreds_base)), power(V))
96-
ρᵢ = GroupRepresentation(action(ρ), V)
97-
return irreducibles_old(ρᵢ)
98-
end
99-
mexps = multiexponents(degree=power(V), nvars=length(irreds_base))
100-
irreds = IrreducibleRepresentation{A}[]
101-
for mexp in mexps
102-
Vᵢ = TensorProduct([SymmetricPower(space(irreds_base[idx]), val) for (val, idx) in zip(mexp.nzval, mexp.nzind)])
103-
ρᵢ = GroupRepresentation(action(ρ), Vᵢ)
104-
append!(irreds, irreducibles(ρᵢ))
105-
end
106-
return irreds
107-
end
108-
109109
function irreducibles(
110110
ρ::GroupRepresentation{A, T}
111111
) where {A<:AbstractGroupAction{Lie}, T<:SymmetricPower}

src/lie-groups/lie-algebras/algebras.jl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ struct ScalingLieAlgebra{F} <: AbstractLieAlgebra{F}
1414
end
1515

1616
ScalingLieAlgebra{F}(size::Int) where F = ScalingLieAlgebra{F}("", sparse(ones(Int, 1, size)))
17+
ScalingLieAlgebra{F}(exps::Matrix{Int}) where F = ScalingLieAlgebra{F}("$(superscript(size(exps, 1)))", sparse(exps))
1718

1819
name(alg::ScalingLieAlgebra) = alg.name
1920
dim(alg::ScalingLieAlgebra) = size(alg.exps, 1)
@@ -129,6 +130,7 @@ dim(alg::LieAlgebra) = length(alg.basis.std_basis)
129130
rank(alg::LieAlgebra) = length(alg.basis.cartan)
130131
Base.size(alg::LieAlgebra) = size(alg.basis.std_basis[1], 1)
131132
weight_type(::LieAlgebra{F, W}) where {F, W} = W
133+
weight_inner_type(::LieAlgebra{F, Weight{W}}) where {F, W} = W
132134

133135
function Base.show(io::IO, alg::LieAlgebra{F, Weight{W}}; offset::Int=0) where {F, W}
134136
println(io, " "^offset, "LieAlgebra $(name(alg))")

src/lie-groups/lie-groups/groups.jl

Lines changed: 102 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,89 @@ export LieGroup,
44
×
55

66

7+
"""
8+
ScalingLieGroup{F} <: AbstractGroup{Lie, F}
9+
10+
Represents a scaling Lie group. The group elements are diagonal matrices.
11+
12+
# Constructors
13+
```julia
14+
ScalingLieGroup{F}(size::Int) where F
15+
ScalingLieGroup{F}(exps::Matrix{Int}) where F
16+
```
17+
18+
# Examples
19+
```jldoctest
20+
julia> ScalingLieGroup{ComplexF64}(5)
21+
ScalingLieGroup ℂˣ
22+
number type (or field): ComplexF64
23+
Lie algebra properties:
24+
dimension: 1
25+
basis (diagonal matrices):
26+
[1, 1, 1, 1, 1]
27+
```
28+
```jldoctest
29+
julia> exps = [1 1 1 0 0 0; 0 0 0 1 -2 0];
30+
31+
julia> ScalingLieGroup{ComplexF64}(exps)
32+
ScalingLieGroup (ℂˣ)²
33+
number type (or field): ComplexF64
34+
Lie algebra properties:
35+
dimension: 2
36+
basis (diagonal matrices):
37+
[1, 1, 1, 0, 0, 0]
38+
[0, 0, 0, 1, -2, 0]
39+
```
40+
"""
741
struct ScalingLieGroup{F} <: AbstractGroup{Lie, F}
842
name::String
943
algebra::ScalingLieAlgebra{F}
1044
end
1145

1246
ScalingLieGroup{F}(size::Int) where F = ScalingLieGroup("ℂˣ", ScalingLieAlgebra{F}(size))
47+
function ScalingLieGroup{F}(exps::Matrix{Int}) where F
48+
name = size(exps, 1) == 1 ? "ℂˣ" : "(ℂˣ)$(superscript(size(exps, 1)))"
49+
ScalingLieGroup(name, ScalingLieAlgebra{F}(exps))
50+
end
1351

1452
name(G::ScalingLieGroup) = G.name
1553
algebra(G::ScalingLieGroup) = G.algebra
1654
exponents(G::ScalingLieGroup) = exponents(algebra(G))
1755
weight(G::ScalingLieGroup, i::Integer) = Weight(Vector(exponents(G)[:, i]))
1856

57+
function Base.show(io::IO, G::ScalingLieGroup{F}) where F
58+
println(io, "ScalingLieGroup $(name(G))")
59+
println(io, " number type (or field): $(F)")
60+
println(io, " Lie algebra properties:")
61+
println(io, " dimension: $(dim(algebra(G)))")
62+
println(io, " basis (diagonal matrices):")
63+
show_basis(io, algebra(G), offset=3)
64+
end
65+
66+
67+
"""
68+
LieGroup{F} <: AbstractGroup{Lie, F}
69+
70+
Describes a matrix Lie group.
1971
72+
# Constructors
73+
```julia
74+
LieGroup(type::String, size::Int)
75+
```
76+
77+
Supported Lie group types: SO (special orthogonal).
78+
79+
# Examples
80+
```jldoctest
81+
julia> SO3 = LieGroup("SO", 3)
82+
LieGroup SO(3)
83+
number type (or field): ComplexF64
84+
weight type: Int64
85+
Lie algebra properties:
86+
dimension: 3
87+
rank (dimension of Cartan subalgebra): 1
88+
```
89+
"""
2090
struct LieGroup{F, T <: LieAlgebra{F}} <: AbstractGroup{Lie, F}
2191
name::String
2292
algebra::T
@@ -39,11 +109,32 @@ end
39109
function Base.show(io::IO, G::LieGroup{F}) where F
40110
println(io, "LieGroup $(name(G))")
41111
println(io, " number type (or field): $(F)")
42-
println(io, " Lie algebra:")
43-
show(io, algebra(G); offset = 2)
112+
println(io, " weight type: $(weight_inner_type(algebra(G)))")
113+
println(io, " Lie algebra properties:")
114+
println(io, " dimension: $(dim(algebra(G)))")
115+
print(io, " rank (dimension of Cartan subalgebra): $(rank(algebra(G)))")
44116
end
45117

46-
118+
"""
119+
DirectProductGroup{T<:GroupType, F} <: AbstractDirectProductGroup{T, F}
120+
121+
Represents a direct product of groups.
122+
# Examples
123+
```jldoctest
124+
julia> SO3 = LieGroup("SO", 3);
125+
126+
julia> T = ScalingLieGroup{ComplexF64}([1 2 3 4; -1 -2 -3 -4]);
127+
128+
julia> SO3 × SO3 × T
129+
DirectProductLieGroup SO(3) × SO(3) × (ℂˣ)²
130+
number type (or field): ComplexF64
131+
3 factors: SO(3), SO(3), (ℂˣ)²
132+
Lie algebra:
133+
SumLieAlgebra 𝖘𝖔(3) ⊕ 𝖘𝖔(3) ⊕ ℂ²
134+
dimension: 8
135+
rank (dimension of Cartan subalgebra): 4
136+
```
137+
"""
47138
struct DirectProductGroup{T<:GroupType, F, S<:AbstractGroup{T, F}} <: AbstractDirectProductGroup{T, F}
48139
name::String
49140
groups::Vector{S}
@@ -55,6 +146,7 @@ DirectProductGroup(
55146

56147
name(G::DirectProductGroup) = G.name
57148
groups(G::DirectProductGroup) = G.groups
149+
ngroups(G::DirectProductGroup) = length(groups(G))
58150
algebra(G::DirectProductGroup) = SumLieAlgebra([algebra(Gᵢ) for Gᵢ in groups(G)])
59151
×(
60152
G₁::AbstractGroup{Lie, F},
@@ -65,13 +157,17 @@ algebra(G::DirectProductGroup) = SumLieAlgebra([algebra(Gᵢ) for Gᵢ in groups
65157
G₂::AbstractGroup{Lie, F}
66158
) where F = DirectProductGroup("$(name(G₁)) × $(name(G₂))", vcat(groups(G₁), [G₂]))
67159

68-
function Base.show(io::IO, G::DirectProductGroup{F}) where F
160+
function Base.show(io::IO, G::DirectProductGroup{T, F}) where {T, F}
69161
println(io, "DirectProductLieGroup $(name(G))")
70162
println(io, " number type (or field): $(F)")
71-
print(io, " Lie algebra:")
163+
println(io, " $(ngroups(G)) factors: ", join([name(Gᵢ) for Gᵢ in groups(G)], ", "))
164+
println(io, " Lie algebra:")
165+
println(io, " SumLieAlgebra $(name(algebra(G)))")
166+
println(io, " dimension: $(dim(algebra(G)))")
167+
print(io, " rank (dimension of Cartan subalgebra): $(rank(algebra(G)))")
72168
end
73169

74-
170+
# TODO: remove and use DirectProductGroup instead with a Mixed group type
75171
struct DirectProductMixedGroup{
76172
F, T <: AbstractGroup{Lie, F}, S <: AbstractGroup{Finite, F}
77173
} <: AbstractDirectProductGroup{Mixed, F}

0 commit comments

Comments
 (0)