Skip to content

Commit

Permalink
minor improvements in invariant vecs BySignedPermutations
Browse files Browse the repository at this point in the history
  • Loading branch information
kalmarek committed Jul 26, 2023
1 parent 9cab871 commit 0521358
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/wedderburn_decomposition.jl
Original file line number Diff line number Diff line change
Expand Up @@ -245,11 +245,12 @@ function invariant_vectors(
coeffs[j] = c
end
@view(tovisit[orbit]) .= false
v = sparsevec(orbit, 1 // ordG .* coeffs, length(basis))
if (VT = eltype(v)) <: Union{AbstractFloat,Complex}
droptol!(v, eps(real(VT)) * length(v))
vals = sparsevec(orbit, coeffs, length(basis))
if CT <: Union{AbstractFloat,Complex}
droptol!(v, eps(real(CT)) * length(vals))
end
if !iszero(v)
v .*= 1 // ordG
push!(invariant_vs, v)
end
end
Expand Down

0 comments on commit 0521358

Please sign in to comment.