Ask Your Question
1

intersection of subgroups

asked 14 years ago

oren gravatar image

I have a group and I'd like to compute the intersection of 2 certain subgroups. How can I compute the intersection in Sage?

Preview: (hide)

2 Answers

Sort by » oldest newest most voted
1

answered 0 years ago

Leen gravatar image

You can just do "s.intersection(t)", where s and t are subgroups of a group g. (This may have been impossible at the time this question was asked and answered.)

Preview: (hide)
link
0

answered 14 years ago

niles gravatar image

I don't think there is an automatic way to do this. If your groups are finite, something like the following might be enough:

sage: G = SymmetricGroup(4)
sage: H = G.subgroup([G([(1,2),(3,4)]),G((1,2))])
sage: K = G.subgroup([G((1,3,2,4))])
sage: for k in K:
    if k in H:
        print k
()
(1,2)(3,4)

Using a list comprehension does the same thing as the for loop above; you can feed this directly to the subgroup function to get the corresponding subgroup:

sage: G.subgroup([k for k in K if k in H])
Subgroup of SymmetricGroup(4) generated by [(), (1,2)(3,4)]

If your subgroups are countably infinite and the intersection is finite, then maybe some modified version of this will work. Otherwise you may have to be more clever.

Preview: (hide)
link

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 14 years ago

Seen: 1,065 times

Last updated: Apr 14