I created a ticket #13461 with a patch that is another large speedup in 
WeylCharacterRings.

The workhorse in WeylCharacterRings is (was) the Freudenthal multiplicity 
formula that
computes the character of an irreducible representation. It occurred to me 
that after
some one-time arithmetic (not in a loop) a Demazure character can be 
computed using
only integer addition and subtraction, and it might be fast, so I tried it. 
If you run
sage -t --long weyl_characters.py it is more that twice as fast: about 2.5 
times as fast.
If you omit the --long, it is slightly slower, so the speedup is mainly for 
big calculations.

As a biproduct, you get Demazure characters as a new method of the 
WeylCharacterRing.
self.demazure_character(weight, word) thus produces an element of the 
WeightRing.

This enhancement is only for WeylCharacterRings created using 
style="coroots". That means that
we can do Demazure characters for SL(n) but not GL(n). This could be fixed, 
but
generalizing the method to the reductive case would require carrying a bit 
more
data around, and we might lose the speedup. So if you omit style="coroots" 
when
you create the WeylCharacterRing, it reverts to the old method using the 
Freudenthal
multiplicity formula.

Dan

-- 
You received this message because you are subscribed to the Google Groups 
"sage-combinat-devel" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/sage-combinat-devel/-/Up4XVeo0XwUJ.
To post to this group, send email to sage-combinat-devel@googlegroups.com.
To unsubscribe from this group, send email to 
sage-combinat-devel+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sage-combinat-devel?hl=en.

Reply via email to