Ask Your Question
0

Group element multiplication in symmetric group

asked 2022-09-21 13:09:01 +0200

vidyarthi gravatar image

I think this is elementary, but how do we just multiply two elements in the symmetric group. For example, I have a list of elements as

G=SymmetricGroup(5)
A=[(1,2), (1,3,2), (1,4), (1,4)(2,3),(2,4),(2,4,3),(3,4),(2,3,4)]
b=[G(1,5)*G(a) for a in A]
b

When I implement in the above code on the compiler, I get the error 'tuple' object is not callable. Anyway to overcome this error and multiply two elements in the group, or, in any other group? Thanks beforehand.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
3

answered 2022-09-21 14:24:51 +0200

tmonteil gravatar image

When you define A, the (1,4)(2,3) looks using the tuple (1,4) as a function to be called at (2,3), which explains your error.

If you want A be a list of elements of G you must make it explicit:

sage: A=[G((1,2)), G((1,3,2)), G((1,4)), G([(1,4),(2,3)]),G((2,4)),G((2,4,3)),G((3,4)),G((2,3,4))]

sage: A
[(1,2), (1,3,2), (1,4), (1,4)(2,3), (2,4), (2,4,3), (3,4), (2,3,4)]

Then, you can do:

sage: b=[G((1,5))*a for a in A]
sage: b
[(1,5,2),
 (1,5,3,2),
 (1,5,4),
 (1,5,4)(2,3),
 (1,5)(2,4),
 (1,5)(2,4,3),
 (1,5)(3,4),
 (1,5)(2,3,4)]
edit flag offensive delete link more

Your Answer

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

Add Answer

Question Tools

1 follower

Stats

Asked: 2022-09-21 13:09:01 +0200

Seen: 29 times

Last updated: Sep 21