Opened 5 years ago
Closed 5 years ago
#20480 closed defect (fixed)
cleanup of centralizer_size
Reported by:  chapoton  Owned by:  

Priority:  major  Milestone:  sage7.2 
Component:  combinatorics  Keywords:  partition 
Cc:  tscrim, darij  Merged in:  
Authors:  Frédéric Chapoton  Reviewers:  Travis Scrimshaw 
Report Upstream:  N/A  Work issues:  
Branch:  3bd7eb8 (Commits, GitHub, GitLab)  Commit:  3bd7eb83dd90434adb652ab4c87bd45e3e27a476 
Dependencies:  Stopgaps: 
Description (last modified by )
the method centralizer_size
(with its default options t=q=0)
is spending some time to take a product of several 1.
Let us spare us that.
This will also partially prevent some bad behaviour in py3, where the division of integers becomes a float.
Change History (9)
comment:1 Changed 5 years ago by
 Branch set to public/20480
 Cc tscrim darij added
 Commit set to d14f00e937fe78b6c72afb415ded2c4aeac52055
 Description modified (diff)
 Keywords partition added
 Status changed from new to needs_review
comment:2 Changed 5 years ago by
You can remove the list in the second prod
. Also, it will probably be cleaner (in terms of the coercions) and possibly faster to do ZZ.one()
instead of 1
.
comment:3 Changed 5 years ago by
hum. ok for the prod, but which 1 are you talking about ? i + 1 ?
comment:4 Changed 5 years ago by
The 1  q**j
and 1  t**j
.
comment:5 Changed 5 years ago by
 Commit changed from d14f00e937fe78b6c72afb415ded2c4aeac52055 to d3e0cda0a78af950ce1abb2cf477ab7c1f22726d
Branch pushed to git repo; I updated commit sha1. New commits:
d3e0cda  trac #20480 better code for centralizer_size

comment:6 Changed 5 years ago by
 Commit changed from d3e0cda0a78af950ce1abb2cf477ab7c1f22726d to 3bd7eb83dd90434adb652ab4c87bd45e3e27a476
Branch pushed to git repo; I updated commit sha1. New commits:
3bd7eb8  Some small reviewer tweaks.

comment:7 Changed 5 years ago by
If you agree with my changes, then positive review. Thanks.
comment:8 Changed 5 years ago by
 Reviewers set to Travis Scrimshaw
 Status changed from needs_review to positive_review
looks good
thanks Travis
comment:9 Changed 5 years ago by
 Branch changed from public/20480 to 3bd7eb83dd90434adb652ab4c87bd45e3e27a476
 Resolution set to fixed
 Status changed from positive_review to closed
New commits:
cleanup of centralizer_size in partition.py