I have been discussing this out with my girlfriend. Appalled as I was at witnessing computer scientists debate whether "==" should (or not) be what everybody on earth expects from a "==" sgn (don't trust me? Poll it), I felt rather down. But then we discussed it.
And we thought that it would be a vibrant message of Love to the universe if we decided that everything (all of us, and numbers too) were equal. I propose to solve this problem by having the default __eq__ function return 'True', regardless of its arguments. It would not be any less stupid, but it would be optimistic. And that matters. Nathann On 12 August 2015 at 22:32, Nils Bruin <nbr...@sfu.ca> wrote: > On Wednesday, August 12, 2015 at 1:08:00 PM UTC-7, Jeroen Demeyer wrote: >> >> On 2015-08-12 19:14, Volker Braun wrote: >> > "==" isn't used in any group theory textbook to my knowledge... Of >> > course group-equality should be a method, all I'm saying is that naming >> > it __eq__() really badly interacts with associative containers. >> >> To be clear, this isn't about comparing groups, but about comparing >> elements of the same(?) group. Most certainly, textbooks use == (with >> this, I really mean $=$) to compare elements of a group. It's like >> comparing 6/3 with 4/2, you really want those to be equal. > > > Yes, and I agree that we'd be deviating very far from the mathematical norm > if we'd let `==` mean anything else for group elements. It also means, as > Volker points out, that in group presentations where we don't have a > solution to the word problem, we don't have equality testing (and hence, > certainly no hash either). There are groups, though, where we can solve the > word problem. There `==` works. As Nathann points out, > groups.presentation.Cyclic(4) is one. > > Reading the doc of the wrapped Gap class > http://www.gap-system.org/Manuals/doc/ref/chap47.html (section 47.3) we see > that > in many cases GAP internally does do the work to get a decent hash function > (an isomorphism to a permutation group or a normal form via Knuth-Bendix). > If GAP doesn't expose this stuff automatically and having decent hashes > (when possible) on FPgroups is valuable, we should reach into GAP to get the > data out. > > -- > You received this message because you are subscribed to a topic in the > Google Groups "sage-devel" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/sage-devel/6rXKkF87Gtc/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > sage-devel+unsubscr...@googlegroups.com. > To post to this group, send email to sage-devel@googlegroups.com. > Visit this group at http://groups.google.com/group/sage-devel. > For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.