mirror of
https://github.com/kalmarek/Groups.jl.git
synced 2024-12-24 01:55:29 +01:00
move deletion of identities into free_reduce
This commit is contained in:
parent
12cf72b476
commit
6ae234cabb
@ -52,6 +52,7 @@ function free_reduce!(W::GWord)
|
||||
W.symbols[i] = one(W.symbols[i])
|
||||
end
|
||||
end
|
||||
deleteat!(W.symbols, find(x -> x.pow == 0, W.symbols))
|
||||
return reduced
|
||||
end
|
||||
|
||||
@ -62,7 +63,6 @@ function reduce!{T}(W::GWord{T})
|
||||
reduced = false
|
||||
while !reduced
|
||||
reduced = free_reduce!(W)
|
||||
deleteat!(W.symbols, find(x -> x.pow == 0, W.symbols))
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user