Re: [sage-devel] A issue with the Set function in sage

2020-06-25 Thread Nils Bruin
On Thursday, June 25, 2020 at 5:00:23 AM UTC-7, Dima Pasechnik wrote: > > > - the problem is that lists are not hashable, and considered unequal. > The problem is that in general testing objects for equality is far > from obvious, might be algorithmically unsolvable, etc. > > Why is Set

Re: [sage-devel] A issue with the Set function in sage

2020-06-25 Thread 'Travis Scrimshaw' via sage-devel
> >> - the problem is that lists are not hashable, and considered unequal. >> The problem is that in general testing objects for equality is far >> from obvious, might be algorithmically unsolvable, etc. >> >> Why is Set trying then? I can see in the documentation that "Sets with >

Re: [sage-devel] A issue with the Set function in sage

2020-06-25 Thread 'Martin R' via sage-devel
See https://trac.sagemath.org/ticket/23324 for some discussion. Am Donnerstag, 25. Juni 2020 19:19:26 UTC+2 schrieb Nils Bruin: > > > > On Thursday, June 25, 2020 at 5:00:23 AM UTC-7, Dima Pasechnik wrote: >> >> >> - the problem is that lists are not hashable, and considered unequal. >> The

Re: [sage-devel] A issue with the Set function in sage

2020-06-25 Thread Dima Pasechnik
On Thu, Jun 25, 2020 at 12:49 PM Ars-Magna wrote: > > Is the following a bug ? > > sage: Set([[(Integer(0), Integer(0)), (Integer(1), Integer(1))],[(Integer(0), > Integer(0)), (Integer(1), Integer(1))]]).cardinality() > > 2 hard to say. Note that sage: Set([[(0,0), (1,1)],[(0,0),

[sage-devel] A issue with the Set function in sage

2020-06-25 Thread Ars-Magna
Is the following a bug ? sage: Set([[(Integer(*0*), Integer(*0*)), (Integer(*1*), Integer(*1* ))],[(Integer(*0*), Integer(*0*)), (Integer(*1*), Integer(*1* ))]]).cardinality() 2 -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe

[sage-devel] Re: A issue with the Set function in sage

2020-06-25 Thread Frédéric Chapoton
Try with "set" and you will see an informative error : lists are not hashable Le jeudi 25 juin 2020 13:49:00 UTC+2, Ars-Magna a écrit : > > Is the following a bug ? > > sage: Set([[(Integer(*0*), Integer(*0*)), (Integer(*1*), Integer(*1* > ))],[(Integer(*0*), Integer(*0*)), (Integer(*1*),