Salut,
it will take a lot of place to give here all the procedures needed to
enable you to run this example. This is ok for me, but this is maybe
not the place for this ?
Here is a little more detail, a reduced example, coming from the
problem above.
sage: kiki
{B[[1, 0, 1, 1, 0, 1, 0, 1, 0, 0]] + B[[1, 0, 1, 1, 1, 0, 0, 1, 0, 0]]
+ B[[1, 0, 1, 1, 0, 1, 1, 0, 0, 0]] + B[[1, 0, 1, 1, 1, 0, 1, 0, 0,
0]] + B[[1, 0, 1, 1, 1, 1, 0, 0, 0, 0]], B[[1, 0, 1, 1, 0, 1, 0, 1, 0,
0]] + B[[1, 0, 1, 1, 0, 1, 1, 0, 0, 0]] + B[[1, 0, 1, 1, 1, 0, 0, 1,
0, 0]] + B[[1, 0, 1, 1, 1, 0, 1, 0, 0, 0]] + B[[1, 0, 1, 1, 1, 1, 0,
0, 0, 0]]}
sage: kiki.cardinality()
2
sage: kiki[0]==kiki[1]
True
sage: kiki[0]-kiki[1]
0
so these 2 linear combinations differ only by their order.
On 2 fév, 12:01, "Nicolas M. Thiery" <[email protected]> wrote:
> Salut Fr d ric,
>
>
>
> On Wed, Feb 02, 2011 at 02:51:51AM -0800, Fr d ric Chapoton wrote:
> > I have found the following problem.
>
> > sage: Set([len([v for v in mySet if v==u]) for u in mySet])
> > {1, 2}
> > sage: type(mySet)
> > <class 'sage.sets.set.Set_object_enumerated_with_category'>
>
> > So we have here a *set with repetitions*. This happens for a very
> > specific set mySet which contains linear combinations of elements of a
> > rather big poset.
>
> > sage: type(mySet[0])
> > <class
> > 'sage.combinat.free_module.modules_sur_P_with_category.element_class'>
>
> > Is there any known explanation for this bad behavior ?
>
> If at all possible, please include a complete example that we can run
> an analyze.
>
> Amiti s,
> Nicolas
> --
> Nicolas M. Thi ry "Isil" <[email protected]>http://Nicolas.Thiery.name/
--
You received this message because you are subscribed to the Google Groups
"sage-combinat-devel" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-combinat-devel?hl=en.