Skip to content

Fix cached orbits inside orbits #4753

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 31, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/Groups/gsets.jl
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ function _orbit_generic(Omega::GSetByElements{<:GAPGroup, S}, omega::S) where S

res = as_gset(acting_group(Omega), action_function(Omega), orb)
# We know that this G-set is transitive.
set_attribute!(res, :orbits => [orb])
set_attribute!(res, :orbits => [res])
return res
end
#T check whether omega lies in Omega?
Expand Down Expand Up @@ -409,7 +409,7 @@ function _orbit_special_GAP(Omega::GSetByElements{<:GAPGroup, S}, omega::S) wher

res = as_gset(acting_group(Omega), action_function(Omega), orb)
# We know that this G-set is transitive.
set_attribute!(res, :orbits => [orb])
set_attribute!(res, :orbits => [res])
return res
end

Expand All @@ -435,7 +435,7 @@ function orbit_via_Julia(Omega::GSet, omega)

res = as_gset(acting_group(Omega), action_function(Omega), orbarray)
# We know that this G-set is transitive.
set_attribute!(res, :orbits => [orbarray])
set_attribute!(res, :orbits => [res])
return res
end

Expand Down
4 changes: 3 additions & 1 deletion test/Groups/gsets.jl
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,9 @@
# orbit
G = symmetric_group(6)
Omega = gset(G, permuted, [[0,1,0,1,0,1], [1,2,3,4,5,6]])
@test length(orbit(Omega, [0,1,0,1,0,1])) == length(Oscar.orbit_via_Julia(Omega, [0,1,0,1,0,1]))
orb = orbit(Omega, [0,1,0,1,0,1])
@test length(orb) == length(Oscar.orbit_via_Julia(Omega, [0,1,0,1,0,1]))
@test orbits(orb) == [orb]

# permutation
G = symmetric_group(6)
Expand Down
Loading