Hi Darij, On Sat, Jul 13, 2013 at 08:39:02PM +0200, Darij Grinberg wrote: > One way to do it, of course, is by making the symmetric group algebra > an AlgebraWithRealizations (like most combinatorial Hopf algebras), > and implement the two different conventions as two different > realizations of it, with the antipode map (g |-> g^{-1} for g in the > group) serving as the coercion in both directions. This will lead to > things working exactly as they should, *but* the coercion map involves > inverting permutations and that might slow things down. Ideally, I'd > want two distinct PermutationGroup classes differing only in their > __mul__'s, without having the need to duplicate code or split into > cases depending on left/rightness. Something like: if I put a method > in the left version of the PermutationGroup class, then it > automatically also works for the right version, but if the method > internally depends on __mul__, I want it to be using the same __mul__ > in both classes, so when I call the method from the right class, it > first converts into the left version, then applies the method written > there, and then converts back into the right version. But, of course, > I only want this for methods which *internally* depend on > multiplication rather than for methods like "product" which *should* > work differently on both sides. Do we have the right framework to > formalize this and make this work? Or is what I'm describing misguided > or self-contradictory?
Unless you have a specific need for working simultaneously with the two group algebras of a group of permutation (one for it acting on the left, and one for it acting on the right), this feels like overkill at this point to have the symmetric group algebra as an algebra with several realizations just for this. Btw: don't worry too much about SymmetricGroupAlgebra. It needs to be rewritten anyway at some point to use the generic code about group algebras, and there will be very little specific code left -- if any a this point -- after this. Cheers, Nicolas -- Nicolas M. ThiƩry "Isil" <nthi...@users.sf.net> http://Nicolas.Thiery.name/ -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.