Skip to content

Commit

Permalink
updated root_systems.jl and simple_lie_algebra-test.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
voggesbe committed Aug 1, 2023
1 parent 8b224c2 commit 4422d88
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions experimental/LieAlgebras/src/root_systems.jl
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,18 @@ function show(io::IO, R::RootSystem)
show(io, R.root_system_type[1] * string(R.root_system_type[2]))
end

###############################################################################
#
# Comparison
#
###############################################################################

function ==(R1::RootSystem, R2::RootSystem)
R1.root_system_type != R2.root_system_type &&
error("Incompatible Root systems")
return R1.roots == R2.roots
end

###############################################################################
#
# further functions
Expand Down
2 changes: 1 addition & 1 deletion experimental/LieAlgebras/test/simple_lie_algebra-test.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
@test base_ring(L) == QQ
@test base_ring(a) == QQ
@test root_system(L) == RootSystem("A2")
@test root_type(L) == Union{Int64, String}["A", 2]
@test root_type(L) == ("A", 2)
@test matrix(a) == zero_matrix(QQ, 1, 8)
@test characteristic(L) == 0
@test symbols(L) == [Symbol("e_$i") for i in 1:8]
Expand Down

0 comments on commit 4422d88

Please sign in to comment.