Skip to content

Commit

Permalink
Add some more functionality, docs and tests for root systems (oscar-s…
Browse files Browse the repository at this point in the history
  • Loading branch information
lgoettgens authored and ooinaruhugh committed Feb 15, 2024
1 parent b382893 commit 10feb3e
Show file tree
Hide file tree
Showing 5 changed files with 516 additions and 48 deletions.
6 changes: 2 additions & 4 deletions experimental/LieAlgebras/src/CartanMatrix.jl
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ end
@doc raw"""
cartan_bilinear_form(gcm::ZZMatrix; check::Bool=true) -> ZZMatrix
Returns the matrix of the symmetric bilinear form associated to the Cartan matrix from `cartan_matrix_symmetrizer`.
Returns the matrix of the symmetric bilinear form associated to the Cartan matrix from `cartan_symmetrizer`.
The keyword argument `check` can be set to `false` to skip verification whether `gcm` is indeed a generalized Cartan matrix.
# Example
Expand All @@ -233,10 +233,8 @@ julia> cartan_bilinear_form(cartan_matrix(:B, 2))
```
"""
function cartan_bilinear_form(gcm::ZZMatrix; check::Bool=true)
@req !check || is_cartan_matrix(gcm) "Requires a generalized Cartan matrix"

sym = cartan_symmetrizer(gcm; check)
bil = deepcopy(gcm)
sym = cartan_symmetrizer(gcm; check=false)
for i in 1:length(sym)
mul!(view(bil, i, :), sym[i])
end
Expand Down
30 changes: 30 additions & 0 deletions experimental/LieAlgebras/src/LieAlgebras.jl
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,14 @@ import ..Oscar:
derived_series,
dim,
direct_sum,
dot,
dual,
elem_type,
expressify,
exterior_power,
gen,
gens,
height,
hom,
hom_tensor,
ideal,
Expand Down Expand Up @@ -77,6 +79,7 @@ import ..Oscar:
import Base: getindex, deepcopy_internal, hash, issubset, iszero, parent, zero

export AbstractLieAlgebra, AbstractLieAlgebraElem
export DualRootSpaceElem
export LieAlgebra, LieAlgebraElem
export LieAlgebraHom
export LieAlgebraIdeal
Expand All @@ -92,6 +95,7 @@ export WeylGroup, WeylGroupElem
export abelian_lie_algebra
export abstract_module
export base_lie_algebra
export bilinear_form
export bracket
export cartan_bilinear_form
export cartan_matrix
Expand All @@ -103,6 +107,8 @@ export coefficient_vector
export coerce_to_lie_algebra_elem
export combinations
export conjugate_dominant_weight
export coroot
export coroots
export coxeter_matrix
export derived_algebra
export dim_of_simple_module
Expand All @@ -118,10 +124,14 @@ export is_cartan_matrix
export is_cartan_type
export is_direct_sum
export is_dual
export is_coroot_with_index
export is_negative_coroot_with_index
export is_negative_root_with_index
export is_positive_coroot_with_index
export is_positive_root_with_index
export is_root_with_index
export is_self_normalizing
export is_simple_coroot_with_index
export is_simple_root_with_index
export is_standard_module
export is_symmetric_power
Expand All @@ -132,13 +142,17 @@ export longest_element
export lower_central_series
export matrix_repr_basis
export multicombinations
export negative_coroot
export negative_coroots
export negative_root
export negative_roots
export num_positive_roots
export num_roots, nroots
export num_simple_roots
export permutations
export permutations_with_sign
export positive_coroot
export positive_coroots
export positive_root
export positive_roots
export reduced_expressions
Expand All @@ -147,6 +161,8 @@ export root_system_type, has_root_system_type
export root_system, has_root_system
export show_dynkin_diagram
export simple_module
export simple_coroot
export simple_coroots
export simple_root
export simple_roots
export special_linear_lie_algebra
Expand Down Expand Up @@ -185,6 +201,7 @@ end
using .LieAlgebras

export AbstractLieAlgebra, AbstractLieAlgebraElem
export DualRootSpaceElem
export LieAlgebra, LieAlgebraElem
export LieAlgebraHom
export LieAlgebraIdeal
Expand All @@ -200,6 +217,7 @@ export WeylGroup, WeylGroupElem
export abelian_lie_algebra
export abstract_module
export base_lie_algebra
export bilinear_form
export bracket
export cartan_bilinear_form
export cartan_matrix
Expand All @@ -209,6 +227,8 @@ export cartan_type_with_ordering
export chevalley_basis
export coerce_to_lie_algebra_elem
export conjugate_dominant_weight
export coroot
export coroots
export coxeter_matrix
export derived_algebra
export dim_of_simple_module
Expand All @@ -224,10 +244,14 @@ export is_cartan_matrix
export is_cartan_type
export is_direct_sum
export is_dual
export is_coroot_with_index
export is_negative_coroot_with_index
export is_negative_root_with_index
export is_positive_coroot_with_index
export is_positive_root_with_index
export is_root_with_index
export is_self_normalizing
export is_simple_coroot_with_index
export is_simple_root_with_index
export is_standard_module
export is_symmetric_power
Expand All @@ -239,11 +263,15 @@ export longest_element
export lower_central_series
export matrix_repr_basis
export matrix_repr_basis
export negative_coroot
export negative_coroots
export negative_root
export negative_roots
export num_positive_roots
export num_roots, nroots
export num_simple_roots
export positive_coroot
export positive_coroots
export positive_root
export positive_roots
export reduced_expressions
Expand All @@ -254,6 +282,8 @@ export root_system, has_root_system
export roots
export show_dynkin_diagram
export simple_module
export simple_coroot
export simple_coroots
export simple_root
export simple_roots
export special_linear_lie_algebra
Expand Down
Loading

0 comments on commit 10feb3e

Please sign in to comment.