On Wed, Jan 25, 2012 at 9:57 AM, Christopher Swenson <ch...@caswenson.com> wrote: > Fair enough. :)
It's just that often people freak all the time about Sage allowing "<" and complex numbers in the same room. Some people have proposed that it would be a good idea to have an architecture for comparisons that are useful for making output (e.g., a list of complex numbers) be returned in some well-defined order, but which wouldn't be __cmp__. Then one can order complex (number field, etc.) elements for all output, but still have < give an error when used directly. This is a good idea; it allows for the usefulness of ordering (e.g., making Sage more deterministic), without causing as much confusion regarding algebraic properties of comparison operators. -- william > > On Wed, Jan 25, 2012 at 12:46, William Stein <wst...@gmail.com> wrote: >> >> On Wed, Jan 25, 2012 at 9:30 AM, Christopher Swenson >> <ch...@caswenson.com> wrote: >> > Looking in rings/complex_number.pyx, it looks like it a simple lex >> > ordering. >> > I would bet that this is because people would be annoyed that you get >> > an >> > exception if you tried to sort a list of complex numbers, even though >> > you >> > can't. :) >> >> The set of complex numbers a+b*i can be endowed with an ordering, >> e.g,. by virtue of the isomorphism with R^2 got by fixing the basis >> 1,i. There is just no ordering that also preserves the algebraic >> structure. I don't see why this causes people to go so batshit >> insane. >> >> -- William >> >> > >> > --Christopher >> > >> > >> > On Wed, Jan 25, 2012 at 12:22, Volker Braun <vbraun.n...@gmail.com> >> > wrote: >> >> >> >> On Wednesday, January 25, 2012 8:58:15 AM UTC-8, Nils Bruin wrote: >> >>> >> >>> sage: bool(37 +i < 37 -i) >> >>> False >> >> >> >> >> >> False meaning that Sage cannot affirm that it is true; IMHO the correct >> >> answer. >> >> >> >>> >> >>> sage: bool(37 +i > 37 -i) >> >>> True >> >> >> >> >> >> BUG >> >> >> >> >> >> -- >> >> To post to this group, send an email to sage-devel@googlegroups.com >> >> To unsubscribe from this group, send an email to >> >> sage-devel+unsubscr...@googlegroups.com >> >> For more options, visit this group at >> >> http://groups.google.com/group/sage-devel >> >> URL: http://www.sagemath.org >> > >> > >> > -- >> > To post to this group, send an email to sage-devel@googlegroups.com >> > To unsubscribe from this group, send an email to >> > sage-devel+unsubscr...@googlegroups.com >> > For more options, visit this group at >> > http://groups.google.com/group/sage-devel >> > URL: http://www.sagemath.org >> >> >> >> -- >> William Stein >> Professor of Mathematics >> University of Washington >> http://wstein.org >> >> -- >> To post to this group, send an email to sage-devel@googlegroups.com >> To unsubscribe from this group, send an email to >> sage-devel+unsubscr...@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/sage-devel >> URL: http://www.sagemath.org > > > -- > To post to this group, send an email to sage-devel@googlegroups.com > To unsubscribe from this group, send an email to > sage-devel+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/sage-devel > URL: http://www.sagemath.org -- William Stein Professor of Mathematics University of Washington http://wstein.org -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org