On Saturday, July 13, 2013 1:43:09 AM UTC+2, darijgrinberg wrote: > There is a further issue lurking in the background here. It *is* possible > to make Sage use the standard convention (first \psi, then \pi), namely by > setting a global variable (see > http://trac.sagemath.org/sage_trac/ticket/14885 for details). > Unfortunately, this requires knowing of the existence of this variable; > apparently, some of the coders did not, and so a method in dyck_word.py > seemingly completely unrelated to permutations (it only uses permutations > in its implementation) breaks when this global variable is set.
This sounds like the most serious issue to me. Having such a global variable will be an eternal pitfall . If you always have to check *at runtime* in which order a permutation composition has to be done, you're far worse off than testing it *at developing time* (since you'll have to check how to interpret the value of the global variable at runtime anyway). Never mind that a separate thread could change the value of the global variable half way through your computation! I don't particularly care which convention is followed, since half of the time, it will be the less convenient one anyway, but it should be consistent. Since a permutation group is an abstract group *given by its action*, the appropriate place to offer a choice would be at construction of the group, e.g. SymmetricGroup(<finite set>,action="left"/"right") but I'd prefer there's only one. Incidentally, note: sage: S3=SymmetricGroup(3) sage: s=S3((1,2,3)) sage: s.matrix() [0 1 0] [0 0 1] [1 0 0] which suggests to me that the natural action of s as permutation matrix is on row vectors, i.e., on the right. The global variable doesn't change that. -- 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.