mirror of
https://github.com/kalmarek/Groups.jl.git
synced 2024-08-25 20:10:53 +02:00
use KB.Settings to pass options to knuthbendix
This commit is contained in:
parent
1345516521
commit
c75ff00aa9
@ -74,7 +74,7 @@ relations(S::SurfaceGroup) = S.relations
|
||||
function symplectic_twists(π₁Σ::SurfaceGroup)
|
||||
g = genus(π₁Σ)
|
||||
|
||||
saut = SpecialAutomorphismGroup(FreeGroup(2g), maxrules=100)
|
||||
saut = SpecialAutomorphismGroup(FreeGroup(2g), max_rules=1000)
|
||||
|
||||
Aij = [SymplecticMappingClass(saut, :A, i, j) for i in 1:g for j in 1:g if i≠j]
|
||||
|
||||
|
@ -7,12 +7,12 @@ function SpecialAutomorphismGroup(F::FreeGroup; ordering = KnuthBendix.LenLex, k
|
||||
A, rels = gersten_relations(n, commutative=false)
|
||||
S = [A[i] for i in 1:2:length(A)]
|
||||
|
||||
maxrules = 1000*n
|
||||
max_rules = 1000 * n
|
||||
|
||||
rws = KnuthBendix.RewritingSystem(rels, ordering(A))
|
||||
Logging.with_logger(Logging.NullLogger()) do
|
||||
rws = Logging.with_logger(Logging.NullLogger()) do
|
||||
rws = KnuthBendix.RewritingSystem(rels, ordering(A))
|
||||
# the rws is not confluent, let's suppress warning about it
|
||||
KnuthBendix.knuthbendix!(rws; maxrules=maxrules, kwargs...)
|
||||
KnuthBendix.knuthbendix(rws, KnuthBendix.Settings(; max_rules=max_rules, kwargs...))
|
||||
end
|
||||
return AutomorphismGroup(F, S, rws, ntuple(i -> gens(F, i), n))
|
||||
end
|
||||
|
@ -229,7 +229,7 @@ function FPGroup(
|
||||
word_rels = [word(lhs) => word(rhs) for (lhs, rhs) in [relations(G); rels]]
|
||||
rws = KnuthBendix.RewritingSystem(word_rels, ordering)
|
||||
|
||||
KnuthBendix.knuthbendix!(rws; kwargs...)
|
||||
rws = KnuthBendix.knuthbendix(rws, KnuthBendix.Settings(; kwargs...))
|
||||
|
||||
return FPGroup(G.gens, rels, rws)
|
||||
end
|
||||
|
@ -79,7 +79,7 @@
|
||||
@test inv(l)(deepcopy(D)) == (a, d^-1*b,c, d)
|
||||
end
|
||||
|
||||
A = SpecialAutomorphismGroup(F4, maxrules=1000)
|
||||
A = SpecialAutomorphismGroup(F4, max_rules=1000)
|
||||
|
||||
@testset "AutomorphismGroup constructors" begin
|
||||
@test A isa Groups.AbstractFPGroup
|
||||
|
@ -40,7 +40,7 @@
|
||||
end
|
||||
|
||||
# quotient of G
|
||||
H = FPGroup(G, [aG^2=>cG, bG*cG=>aG], maxrules=200)
|
||||
H = FPGroup(G, [aG^2 => cG, bG * cG => aG], max_rules=200)
|
||||
|
||||
h = H(word(g))
|
||||
|
||||
@ -48,7 +48,7 @@
|
||||
@test_throws AssertionError h == g
|
||||
@test_throws MethodError h*g
|
||||
|
||||
H′ = FPGroup(G, [aG^2=>cG, bG*cG=>aG], maxrules=200)
|
||||
H′ = FPGroup(G, [aG^2 => cG, bG * cG => aG], max_rules=200)
|
||||
@test_throws AssertionError one(H) == one(H′)
|
||||
|
||||
Groups.normalform!(h)
|
||||
|
Loading…
Reference in New Issue
Block a user