Multiple calls of irreducible_character() have incompatible output

37 views
Skip to first unread message

Ronno Das

unread,
Jun 23, 2021, 10:30:20 AM6/23/21
to sage-support
The following code throws the error "GAPError: Error, no method found! Error, no 1st choice method found for `=' on 2 arguments":

G = SymmetricGroup(3)
char_1 = G.irreducible_character()[0]
char_2 = G.irreducible_character()[0]
char_1.scalar_product(char_2)  # should be 1(or maybe 0 if the order is not consistent)

The same issue appears if G is a PermutationGroup. I'm running sage 9.3, compiled from source.

Trevor Karn

unread,
Jun 23, 2021, 1:42:16 PM6/23/21
to sage-support
I see the same issue on 9.4.beta1. It looks like maybe there is a unique representation issue happening? That is, on your second call if irreducible characters, it creates a new instance of the irreducible and so it doesn't recognize them as the same. If you only compute the G.irreducible_characters() once, it seems to work:

sage: G = SymmetricGroup(3)                                                                                                  sage: irr = G.irreducible_characters()                                                                                     sage: char_1 = irr[0]                                                                                                        sage: char_2 = irr[0]                                                                                                        sage: char_1.scalar_product(char_2)                                                                                          

1

Does this approach work for your use-case?

Ronno Das

unread,
Jun 23, 2021, 3:43:12 PM6/23/21
to sage-support
Yes, I wrote a wrapper that calls irreducible_characters() once and caches the results. There seems to be more issues about the output though, for example char_1.symmetric_power(2) throws an error. I think ClassFunction(G, char_1.values()) works as expected, but that's again a workaround and might have other issues.

Dima Pasechnik

unread,
Jun 23, 2021, 3:55:27 PM6/23/21
to sage-support
On Wed, Jun 23, 2021 at 8:43 PM Ronno Das <ronn...@gmail.com> wrote:
>
> Yes, I wrote a wrapper that calls irreducible_characters() once and caches the results. There seems to be more issues about the output though, for example char_1.symmetric_power(2) throws an error. I think ClassFunction(G, char_1.values()) works as expected, but that's again a workaround and might have other issues.


You might prefer to work directly with GAP via libgap.
It just works.

sage: G = libgap.SymmetricGroup(3)



sage: G.CharacterTable().Irr()[2]
Character( CharacterTable( Sym( [ 1 .. 3 ] ) ), [ 1, 1, 1 ] )
sage: G.CharacterTable().Irr()[2]
Character( CharacterTable( Sym( [ 1 .. 3 ] ) ), [ 1, 1, 1 ] )
sage: G.CharacterTable().Irr()[1]
Character( CharacterTable( Sym( [ 1 .. 3 ] ) ), [ 2, 0, -1 ] )
sage: a=G.CharacterTable().Irr()[1]
sage: b=G.CharacterTable().Irr()[2]
sage: b.ScalarProduct(b)
1
sage: b.ScalarProduct(a)
0





> On Wednesday, June 23, 2021 at 12:42:16 PM UTC-5 trevor...@gmail.com wrote:
>>
>> I see the same issue on 9.4.beta1. It looks like maybe there is a unique representation issue happening? That is, on your second call if irreducible characters, it creates a new instance of the irreducible and so it doesn't recognize them as the same. If you only compute the G.irreducible_characters() once, it seems to work:
>>
>> sage: G = SymmetricGroup(3) sage: irr = G.irreducible_characters() sage: char_1 = irr[0] sage: char_2 = irr[0] sage: char_1.scalar_product(char_2)
>>
>> 1
>>
>> Does this approach work for your use-case?
>>
>> On Wednesday, June 23, 2021 at 9:30:20 AM UTC-5 ronn...@gmail.com wrote:
>>>
>>> The following code throws the error "GAPError: Error, no method found! Error, no 1st choice method found for `=' on 2 arguments":
>>>
>>> G = SymmetricGroup(3)
>>> char_1 = G.irreducible_character()[0]
>>> char_2 = G.irreducible_character()[0]
>>> char_1.scalar_product(char_2) # should be 1(or maybe 0 if the order is not consistent)
>>>
>>> The same issue appears if G is a PermutationGroup. I'm running sage 9.3, compiled from source.
>
> --
> You received this message because you are subscribed to the Google Groups "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sage-support...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/6fb2fafe-caff-450a-af34-44e82b961eadn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages