#14862: Compositions accept any input
-------------------------------------+-------------------------------------
       Reporter:  stumpc5            |        Owner:  sage-combinat
           Type:  defect             |       Status:  needs_review
       Priority:  major              |    Milestone:  sage-5.13
      Component:  combinatorics      |   Resolution:
       Keywords:  composition,       |    Merged in:
  FindStat                           |    Reviewers:
        Authors:                     |  Work issues:  provide a test in the
Report Upstream:  N/A                |  constructor
         Branch:                     |       Commit:
   Dependencies:                     |     Stopgaps:
-------------------------------------+-------------------------------------
Changes (by andrew.mathas):

 * cc: andrew.mathas (added)


Comment:

 Replying to [comment:9 stumpc5]:
 > We use {{{Partition}}} for {{{IntegerPartition}}}, though it could as
 well refer to {{{SetPartition}}} or whatever else. For me
 {{{IntegerPartition}}} is a partition of a positive integer. I would be
 totally fine with using {{{IntegerPartition}}} and
 {{{IntegerComposition}}}.

 I am against changing the name of the `Partition` class to
 `IntegerPartition`. This would create a major patch bomb as `Partition` is
 used in many places -- a quick and dirty count with grep gives me 114
 different python files.

 More importantly, even though the name `IntegerPartition` is not bad, I do
 not think it is what most people would guess when looking for partitions
 so this change would, in effect, make `sage ` harder to use. Of the files
 using `Partition`, 29 of them are outside of the `combinat` directory so
 presumably the usage of this class is wider than just algebraic
 combinatorics).

 As far as I am aware there is no name conflict with the name `Partition`
 (btw, there already is a separate `SetPartition` class). The only
 justification for changing this name given so far is in order to maintain
 name consistency with a potential name change for `Composition`. I do not
 think that this is a good argument.

 With regard to `Composition`, I do not have any strong feelings. I do not
 see anything wrong with having both `IntegerComposition` and `Partition`
 in the name-space. On the other hand, since no one has noticed a problem
 with `Composition` before I don't really understand why there is suddenly
 a problem now, especially as there already is a much superior notation
 already available for the composition of two maps:
 {{{
 sage: a=Hom(ZZ,ZZ)(1)
 sage: b=Hom(ZZ,ZZ)(1)
 sage: a*b
 Ring endomorphism of Integer Ring
   Defn: 1 |--> 1
 }}}
 As there already is a really good way to compose maps in sage I don't find
 the argument for changing the meaning of `Composition` very compelling.

--
Ticket URL: <http://trac.sagemath.org/ticket/14862#comment:10>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to