Blogs I Follow
Hi all, here’s a brief summary of my 13th (and last) week of GSoC.
_sizeattribute to the Permutation class, and then, when faced with something like
Permutation([[2, 3], [4, 5, 6], ]), find the maximum index appearing in the permutation (here it’s 8) and assign the size of the permutation to that + 1. Then it remains to adjust some of the other methods in the class (after I adjusted mul so that it treats permutations of different sizes as if they leave all points outside their domain fixed, all the tests passed) so that they make sense with that new approach to cyclic forms.
ExtendedArrayFormor something, with a field
_array_formthat holds the usual array form of a permutation. Then we overload the
__getitem__method so that if the index is outside the bounds of
self._array_formwe return the index unchanged. Of course, we’ll have to overload other things, like the
__str__to make it behave like a list. Then instead of using a list to initialize the array form of a permutation, we use the corresponding
ExtendedArrayForm. This will make all permutations behave as if they are acting on a practically infinite domain, and if we do it that way, we won’t have to make any changes to the methods in
Permutation– everything is going to work as expected, no casework like
if len(a) > len(b),...will be needed. So this sounds like a rather elegant approach. On the other hand, I’m not entirely sure if it is possible to make it completely like a list, and also it doesn’t seem like a very performance-efficient decision since
ExtendedArrayForminstances will be created all the time. (see the discussion here).
That’s it for now, and that’s the end of my series of blog posts for the GSoC, but I don’t really feel that something has ended since it seems that my contributions to the combinatorics module will continue (albeit not that regularly : ) ). After all, it’s a lot of fun, and there are a lot more things to be implemented/fixed there! So, a big “Thank you” to everyone who helped me get through (and to) GSoC, it’s been a pleasure and I learned a lot. Goodbye!
Exploring and venting about quantitative issues
Adventures of a would-be do-gooder.
Mathematics related discussions
Updates on my research and expository papers, discussion of open problems, and other maths-related topics. By Terence Tao
Most of the blog moved to blog.krastanov.org