-
Notifications
You must be signed in to change notification settings - Fork 126
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
86ae0b9
commit c5615e9
Showing
7 changed files
with
160 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
@testset "LieAlgebras.LieAlgebraIdeal" begin | ||
@testset "Constructor and basic properties" begin | ||
let | ||
L = general_linear_lie_algebra(QQ, 3) | ||
b = lie_algebra( | ||
sub( | ||
L, [basis(L, 1), basis(L, 2), basis(L, 3), basis(L, 5), basis(L, 6), basis(L, 9)] | ||
), | ||
) | ||
n = ideal(b, [basis(b, 2), basis(b, 3), basis(b, 5)]) | ||
|
||
let L = b, I = n | ||
@test I == ideal(L, basis(I)) | ||
@test base_lie_algebra(I) == L | ||
@test length(gens(I)) == ngens(I) | ||
@test length(basis(I)) == dim(I) | ||
@test all(in(I), gens(I)) | ||
@test all(in(I), basis(I)) | ||
end | ||
|
||
@test dim(b) == 6 | ||
@test dim(n) == 3 | ||
end | ||
|
||
let # Example where ideal basis is only found after two steps | ||
sc = zeros(QQ, 4, 4, 4) | ||
sc[1, 2, 3] = 1 | ||
sc[2, 1, 3] = -1 | ||
sc[1, 3, 4] = 1 | ||
sc[3, 1, 4] = -1 | ||
L = lie_algebra(QQ, sc, ["a", "b", "c", "d"]) | ||
a, b, c, d = basis(L) | ||
|
||
let I = ideal(L, b) | ||
@test I == ideal(L, [b]) | ||
@test dim(I) == 3 | ||
@test ngens(I) == 1 | ||
|
||
@test I == ideal(L, basis(I)) | ||
@test base_lie_algebra(I) == L | ||
@test length(gens(I)) == ngens(I) | ||
@test length(basis(I)) == dim(I) | ||
@test all(in(I), gens(I)) | ||
@test all(in(I), basis(I)) | ||
end | ||
|
||
let I = ideal(L, [a + b + c + d]) | ||
@test dim(I) == 3 | ||
@test ngens(I) == 1 | ||
|
||
@test I == ideal(L, basis(I)) | ||
@test base_lie_algebra(I) == L | ||
@test length(gens(I)) == ngens(I) | ||
@test length(basis(I)) == dim(I) | ||
@test all(in(I), gens(I)) | ||
@test all(in(I), basis(I)) | ||
end | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
@testset "LieAlgebras.LieSubalgebra" begin | ||
@testset "Constructor and basic properties" begin | ||
let | ||
L = general_linear_lie_algebra(QQ, 3) | ||
b = sub( | ||
L, [basis(L, 1), basis(L, 2), basis(L, 3), basis(L, 5), basis(L, 6), basis(L, 9)] | ||
) | ||
|
||
n = sub(L, [basis(b, 2), basis(b, 3), basis(b, 5)]) | ||
|
||
for S in [b, n] | ||
@test L == base_lie_algebra(S) | ||
@test length(gens(S)) == ngens(S) | ||
@test length(basis(S)) == dim(S) | ||
@test all(in(S), gens(S)) | ||
@test all(in(S), basis(S)) | ||
end | ||
|
||
@test dim(b) == 6 | ||
@test dim(n) == 3 | ||
end | ||
end | ||
|
||
@testset "Hum72, Exercise 2.3" begin | ||
@testset for n in 2:4, F in [QQ, GF(2)] | ||
L = general_linear_lie_algebra(F, n) | ||
|
||
b = sub(L, [basis(L, (i - 1) * n + j) for i in 1:n, j in 1:n if i <= j]) | ||
d = sub(L, [basis(L, (i - 1) * n + j) for i in 1:n, j in 1:n if i == j]) | ||
n = sub(L, [basis(L, (i - 1) * n + j) for i in 1:n, j in 1:n if i < j]) | ||
|
||
@test is_self_normalizing(b) | ||
@test is_self_normalizing(d) | ||
@test !is_self_normalizing(n) | ||
@test normalizer(n) == b | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters