[sage-devel] Re: Sage Tutorial: Section 2.3: Suggested addition

2009-03-11 Thread William Stein
On Wed, Mar 11, 2009 at 10:55 PM, R (Chandra) Chandrasekhar wrote: > > Folks, > > I have one suggestion for the Sage Tutorial. > > In Section 2.3, after the text > > == > > sage: def is_even(n): > ...       return n%2 == 0 > == > > I suggest that you add an instruction to press [Enter/Return/Newl

[sage-devel] Sage Tutorial: Section 2.3: Suggested addition

2009-03-11 Thread R (Chandra) Chandrasekhar
Folks, I have one suggestion for the Sage Tutorial. In Section 2.3, after the text == sage: def is_even(n): ... return n%2 == 0 == I suggest that you add an instruction to press [Enter/Return/Newline] after the ... return n%2 == 0 to conclude the definition. When I followed th

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jason Grout
Jaap Spies wrote: > Jason Grout wrote: >> Robert Bradshaw wrote: > >>> Internal consistency is good, but consistency with the vast body of >>> mathematical literature out there is pretty valuable as well. >> Yes, that is one reason why I am for having all multiplications denoted >> by "*". Mo

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 9:35 PM, Robert Bradshaw wrote: >> Here's some examples to hopefully clarify: > > >> RealField(20) -> RealField(50) >> RealField(20) -> RealIntervalField(20) > > I would call these dangerous, as the latter implicitly has more > "information" than the former. No they don't

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Robert Bradshaw
OK, my last post on this tread for a while, I promise :). On Mar 11, 2009, at 7:19 PM, Bill Page wrote: > On Wed, Mar 11, 2009 at 10:13 PM, David Roe wrote: >> On Wed, Mar 11, 2009 at 9:53 PM, Bill Page wrote: >>> >>> On Wed, Mar 11, 2009 at 9:08 PM, Carl Witty wrote: ... Does this mea

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jaap Spies
Jason Grout wrote: > Robert Bradshaw wrote: >> Internal consistency is good, but consistency with the vast body of >> mathematical literature out there is pretty valuable as well. > > Yes, that is one reason why I am for having all multiplications denoted > by "*". Most students are familiar

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jason Grout
William Stein wrote: > On Wed, Mar 11, 2009 at 8:14 PM, Alex Ghitza wrote: >> On Thu, Mar 12, 2009 at 2:03 PM, Jason Grout >> wrote: >>> seber...@spawar.navy.mil wrote: Carl Mathematica seems to have been successful with this approach. I'm curious what were the reasons for i

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Dan Drake
On Wed, 11 Mar 2009 at 08:50PM -0700, William Stein wrote: > sage: !math > Mathematica 6.0 for Linux x86 (64-bit) > Copyright 1988-2007 Wolfram Research, Inc. > > In[1]:= sin(x) > > Out[1]= sin x On a similar note, we have this: > sage: !math > Mathematica 6.0 for Linux x86 (64-bit) > Copyright

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Robert Bradshaw
On Mar 11, 2009, at 5:47 PM, Nicolas M. Thiery wrote: > On Wed, Mar 11, 2009 at 10:07:35AM -0800, Carl Witty wrote: >> >> On Tue, Mar 10, 2009 at 11:05 PM, Nicolas M. Thiery >> wrote: >>> I guess it all boils down to what are the convention for membership >>> testing, and how much freedom one ha

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jason Grout
Robert Bradshaw wrote: >>> Along with the other reasons people are giving, it may be >>> helpful to >>> remember that it is may be less error-prone in MMA. For example, >>> parentheses in Sage can denote function calling as well as >>> grouping, >>> while they only denote grou

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jason Grout
Jaap Spies wrote: > Jason Grout wrote: >> Alex Ghitza wrote: >>> On Thu, Mar 12, 2009 at 2:03 PM, Jason Grout >>> mailto:jason-s...@creativetrax.com>> wrote: >>> >>> >>> seber...@spawar.navy.mil wrote: >>> > Carl >>> > >>> > Mathematica seems t

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Robert Bradshaw
On Mar 11, 2009, at 9:38 AM, Bill Page wrote: > > On Wed, Mar 11, 2009 at 12:15 PM, Georg S. Weber wrote: >> On 11 Mrz., 14:06, Bill Page wrote: >> >>> I think the new coercion model in Sage is much too aggressive - >>> especially as applied when coding. As Ralf said: perhaps it makes >>> sense

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Robert Bradshaw
On Mar 11, 2009, at 8:17 PM, Jason Grout wrote: > > Alex Ghitza wrote: >> On Thu, Mar 12, 2009 at 2:03 PM, Jason Grout >> mailto:jason-s...@creativetrax.com>> >> wrote: >> >> >> seber...@spawar.navy.mil wrote: >>> Carl >>> >>> Mathematica seems to have been

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread William Stein
On Wed, Mar 11, 2009 at 8:14 PM, Alex Ghitza wrote: > On Thu, Mar 12, 2009 at 2:03 PM, Jason Grout > wrote: >> >> seber...@spawar.navy.mil wrote: >> > Carl >> > >> > Mathematica seems to have been successful with this approach.  I'm >> > curious what were the reasons for its disapproval.  Perhap

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Robert Bradshaw
On Mar 11, 2009, at 3:07 PM, Florent Hivert wrote: > Dear Carl, > >> The paragraph you quoted was part of a very rough proposal for a way >> that Sage's coercion might be changed in the future; it's definitely >> not how it works now. > > My apologies for missing this. > >> Also, the way co

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Robert Bradshaw
Wow, this thread has generated a lot of discussion! :) On Mar 11, 2009, at 12:29 PM, Ralf Hemmecke wrote: > Some more oil for the fire... > > sage: K=NumberField(x^2+1, 'a'); K > Number Field in a with defining polynomial x^2 + 1 > sage: a = K.0 > sage: a > a > sage: a*a > -1 > sage: a<1 > False

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jaap Spies
Jason Grout wrote: > Alex Ghitza wrote: >> On Thu, Mar 12, 2009 at 2:03 PM, Jason Grout >> mailto:jason-s...@creativetrax.com>> wrote: >> >> >> seber...@spawar.navy.mil wrote: >> > Carl >> > >> > Mathematica seems to have been successful with t

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jason Grout
Alex Ghitza wrote: > On Thu, Mar 12, 2009 at 2:03 PM, Jason Grout > mailto:jason-s...@creativetrax.com>> wrote: > > > seber...@spawar.navy.mil wrote: > > Carl > > > > Mathematica seems to have been successful with this approach. I'm > >

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Alex Ghitza
On Thu, Mar 12, 2009 at 2:03 PM, Jason Grout wrote: > > seber...@spawar.navy.mil wrote: > > Carl > > > > Mathematica seems to have been successful with this approach. I'm > > curious what were the reasons for its disapproval. Perhaps it was > > feared it was error prone? > > > Along with the oth

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jason Grout
seber...@spawar.navy.mil wrote: > Carl > > Mathematica seems to have been successful with this approach. I'm > curious what were the reasons for its disapproval. Perhaps it was > feared it was error prone? Along with the other reasons people are giving, it may be helpful to remember that it

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Dan Drake
On Wed, 11 Mar 2009 at 04:52PM -0700, seber...@spawar.navy.mil wrote: > Mathematica seems to have been successful with this approach. I'm > curious what were the reasons for its disapproval. Perhaps it was > feared it was error prone? I've written Mathematica notebooks for multivariable calculus

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Bill Page
On Wed, Mar 11, 2009 at 10:13 PM, David Roe wrote: > On Wed, Mar 11, 2009 at 9:53 PM, Bill Page wrote: >> >> On Wed, Mar 11, 2009 at 9:08 PM, Carl Witty wrote: >> > ... >> > Does this mean you want GF(5)(3)*2 and RR(pi)*2 to fail?  These >> > currently work due to coercions that would be unsafe ac

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread David Roe
On Wed, Mar 11, 2009 at 9:53 PM, Bill Page wrote: > > On Wed, Mar 11, 2009 at 9:08 PM, Carl Witty wrote: > > ... > > Does this mean you want GF(5)(3)*2 and RR(pi)*2 to fail? These > > currently work due to coercions that would be unsafe according to my > > definition. > > > > The __mul__ method e

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Bill Page
On Wed, Mar 11, 2009 at 9:08 PM, Carl Witty wrote: > ... > Does this mean you want GF(5)(3)*2 and RR(pi)*2 to fail?  These > currently work due to coercions that would be unsafe according to my > definition. > The __mul__ method exported by GF(5) could accept integers as well as elements of GF(5)

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 5:47 PM, Nicolas M. Thiery wrote: > > On Wed, Mar 11, 2009 at 10:07:35AM -0800, Carl Witty wrote: >> If you want (4), I think you should just write x.parent() == P (or if >> you know that P is unique, x.parent() is P). > > Yup. The question is: am I allowed to do it? I'm

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Nicolas M. Thiery
On Wed, Mar 11, 2009 at 10:07:35AM -0800, Carl Witty wrote: > > On Tue, Mar 10, 2009 at 11:05 PM, Nicolas M. Thiery > wrote: > > I guess it all boils down to what are the convention for membership > > testing, and how much freedom one has in implementing it. > > > > Here are some typical options

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Nicolas M. Thiery
On Wed, Mar 11, 2009 at 01:52:31PM -0800, Carl Witty wrote: > > On Wed, Mar 11, 2009 at 1:42 PM, Georg S. Weber > wrote: > > But would you find it helpful to have the possibility to let it act > > either "as gracefully as possible", or to "print out verbose > > warnings" (coercions have costs, s

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Jaap Spies
Mike Hansen wrote: > On Wed, Mar 11, 2009 at 4:52 PM, seber...@spawar.navy.mil > wrote: >> Mathematica seems to have been successful with this approach. I'm >> curious what were the reasons for its disapproval. Perhaps it was >> feared it was error prone? > > It's also not valid Python syntax,

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Mike Hansen
On Wed, Mar 11, 2009 at 4:52 PM, seber...@spawar.navy.mil wrote: > Mathematica seems to have been successful with this approach.  I'm > curious what were the reasons for its disapproval.  Perhaps it was > feared it was error prone? It's also not valid Python syntax, and many people are generally

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread seber...@spawar.navy.mil
Carl Mathematica seems to have been successful with this approach. I'm curious what were the reasons for its disapproval. Perhaps it was feared it was error prone? Chris On Mar 11, 11:36 am, Carl Witty wrote: > On Wed, Mar 11, 2009 at 10:21 AM, seber...@spawar.navy.mil > > wrote: > > > It w

[sage-devel] Re: script to profile import time

2009-03-11 Thread Ondrej Certik
>> >> and neither he could find the Sage script for it. Can someone please >> point us in the right direction? :) > > sage -startuptime > > (implemented in $SAGE_ROOT/local/bin/sage-startuptime.py) That's it, thanks a lot! I was blind. Ondrej --~--~-~--~~~---~--~

[sage-devel] Re: script to profile import time

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 3:43 PM, Ondrej Certik wrote: > > Hi, > > I know there was some script to debug import times, but I just cannot > find it anymore. Robert Kern wrote something similar recently: > > http://thread.gmane.org/gmane.comp.python.enthought.devel/20077 > > and neither he could fin

[sage-devel] script to profile import time

2009-03-11 Thread Ondrej Certik
Hi, I know there was some script to debug import times, but I just cannot find it anymore. Robert Kern wrote something similar recently: http://thread.gmane.org/gmane.comp.python.enthought.devel/20077 and neither he could find the Sage script for it. Can someone please point us in the right dir

[sage-devel] Re: Test failing on "ImportError: cannot import name Set"...

2009-03-11 Thread Robert Bradshaw
On Mar 11, 2009, at 11:45 AM, Nicolas M. Thiery wrote: > On Wed, Mar 11, 2009 at 03:20:18AM -0500, Jason Grout wrote: >> Wow, if the price tag on this feature is bumped up to that >> >> So, is this what is being asked for: >> >> * Whenever you build, compare the list of .pyc files and .so fil

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 2:08 PM, Bill Page wrote: > > On Wed, Mar 11, 2009 at 5:52 PM, Carl Witty wrote: >> This sounds potentially very useful; but option 3 ("do a strict subset >> of coercions/conversions, and stop otherwise") is also tricky to >> implement.  For instance, if you had a mode whe

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Bill Page
On Wed, Mar 11, 2009 at 5:52 PM, Carl Witty wrote: > > On Wed, Mar 11, 2009 at 1:42 PM, Georg S. Weber > wrote: >> But would you find it helpful to have the possibility to let it act >> either "as gracefully as possible", or to "print out verbose >> warnings" (coercions have costs, so if the cost

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Florent Hivert
Dear Carl, > The paragraph you quoted was part of a very rough proposal for a way > that Sage's coercion might be changed in the future; it's definitely > not how it works now. My apologies for missing this. > Also, the way coercion is implemented now, int(2) does have a parent; > it's

[sage-devel] Re: Enumerative structures in Sage

2009-03-11 Thread Georg S. Weber
Hi Nicolas, On 4 Mrz., 23:16, "Nicolas M. Thiery" wrote: > On Wed, Mar 04, 2009 at 01:59:59PM -0800, Georg S. Weber wrote: > > do I understand you correctly that something like ZZ[G] is already in > > Sage today? For an infinite group G, say PSL_2(Z), or some congruence > > subgroup? > > GroupAl

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 1:42 PM, Georg S. Weber wrote: > But would you find it helpful to have the possibility to let it act > either "as gracefully as possible", or to "print out verbose > warnings" (coercions have costs, so if the costs are higher than a > specific amount, this could trigger an

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Georg S. Weber
Hi all, we do not seem to understand each other well enough (especially Bill and me). Yet. :-) Let's try an analogy. When compiling C code, you can tell the compiler to "silently skip over warnings"; or to "print out verbose warnings, but to continue"; or to "treat all warnings like errors and st

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 12:11 PM, Florent Hivert wrote: >> Then "x in P" means that there is a safe conversion from the parent of >> x to P.  If this is actually a coercion, then you don't even have to >> run it; if it's a conversion, then you do have to run it, to test that >> the conversion is

[sage-devel] Re: Coercion and exception handling

2009-03-11 Thread Florent Hivert
> How many places is this used? In my (fairly fresh) Sage session, > there are only 9 actions in the action cache (on matrices, number > fields, and polynomials). I'd be willing to write the _get_action_ > methods for these cases, if it would help kill off some of the excess > error catching in

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Florent Hivert
Dear Carl. > > I definitely see your point. Well, without introducing a hierarchy, > > there is this natural notion of invertible coercions (strongly > > connected components in the conversion graph). But that would not have > > helped anyway for 4/2 in ZZ. Here it's more about a notion of

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 11:29 AM, Ralf Hemmecke wrote: > > Some more oil for the fire... > > sage: K=NumberField(x^2+1, 'a'); K > Number Field in a with defining polynomial x^2 + 1 > sage: a = K.0 > sage: a > a > sage: a*a > -1 > sage: a<1 > False > sage: a>1 > True > sage: 1 False > sage: 1>a >

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Ralf Hemmecke
Some more oil for the fire... sage: K=NumberField(x^2+1, 'a'); K Number Field in a with defining polynomial x^2 + 1 sage: a = K.0 sage: a a sage: a*a -1 sage: a<1 False sage: a>1 True sage: 1a True sage: version() 'Sage Version 3.3, Release Date: 2009-02-21' Do I do something wrong or is autocoe

[sage-devel] Re: Test failing on "ImportError: cannot import name Set"...

2009-03-11 Thread Nicolas M. Thiery
On Wed, Mar 11, 2009 at 03:20:18AM -0500, Jason Grout wrote: > Wow, if the price tag on this feature is bumped up to that > > So, is this what is being asked for: > > * Whenever you build, compare the list of .pyc files and .so files in > the build directory with the list in the source dire

[sage-devel] Re: What was the controversy over "assumed multiplication" ?

2009-03-11 Thread Carl Witty
On Wed, Mar 11, 2009 at 10:21 AM, seber...@spawar.navy.mil wrote: > > It was great going to the Sage Days in San Diego and seeing the very > capable Sage crew including W.S. > > I was curious about something the team said about a controversy > regarding something that I believe was called assumed

[sage-devel] Re: sage 3.4 under 64-bit SuSE 11.1?

2009-03-11 Thread John Cremona
John, I think we should keep this discussion on-list so I am cc-ing sage-devel. In answer to your question, yes, I have been using Sage on that machine for ages and try to test builds on it whenever I can since it often shows up some strange things. With 3.4.rc1 it works fince apart from that o

[sage-devel] What was the controversy over "assumed multiplication" ?

2009-03-11 Thread seber...@spawar.navy.mil
It was great going to the Sage Days in San Diego and seeing the very capable Sage crew including W.S. I was curious about something the team said about a controversy regarding something that I believe was called assumed or implicit multiplication. I think the controversy was whether to allow thi

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Carl Witty
On Tue, Mar 10, 2009 at 11:05 PM, Nicolas M. Thiery wrote: > I guess it all boils down to what are the convention for membership > testing, and how much freedom one has in implementing it. > > Here are some typical options: > > (1) x is in P if there is an element of P that is equal to x under ==

[sage-devel] Re: Coercion and exception handling

2009-03-11 Thread Carl Witty
On Tue, Mar 10, 2009 at 6:01 PM, Robert Bradshaw wrote: > Most of the errors caught are because it's trying to detect an > action, i.e. given a*b, it tries out a._rmul_(b) and, if successful, > registers that as an action, but otherwise goes on to try the next > thing. The benefit of this is conv

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Bill Page
On Wed, Mar 11, 2009 at 12:15 PM, Georg S. Weber wrote: > On 11 Mrz., 14:06, Bill Page wrote: > >> I think the new coercion model in Sage is much too aggressive - >> especially as applied when coding. As Ralf said: perhaps it makes >> sense for interactive use. Would it be possible to enable/disa

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Georg S. Weber
On 11 Mrz., 14:06, Bill Page wrote: > Nicolas M. Thiéry wrote: > > In short: for < = in, if it was just me, I would only use the most > > absolutely trivial coercions. And in particular avoid there all the > > coercions that involve projections and not embedding (like Z -> Z/nZ) > > +1 > -1 >

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Bill Page
Nicolas M. Thiéry wrote: > In short: for < = in, if it was just me, I would only use the most > absolutely trivial coercions. And in particular avoid there all the > coercions that involve projections and not embedding (like Z -> Z/nZ) +1 I think the new coercion model in Sage is much too aggre

[sage-devel] Re: Build of sagemath_3.0.5dfsg-2ubuntu1 using prevu fails on Kubuntu Intrepid

2009-03-11 Thread Jaap Spies
R (Chandra) Chandrasekhar wrote: > Dear Folks, > > I am on an AMD64 PC running Kubuntu Intrepid 8.04 and KDE4.2. The Linux > kernel is 2.6.27-11-generic. > > I downloaded the source package sagemath_3.0.5dfsg-2ubuntu1 from the > jaunty archives and tried compiling it, after having installed ot

[sage-devel] Re: Build of sagemath_3.0.5dfsg-2ubuntu1 using prevu fails on Kubuntu Intrepid

2009-03-11 Thread R (Chandra) Chandrasekhar
Tim Abbott wrote: > I'm guessing your issue is too old m4ri. Try upgrading to libm4ri-dev > from jaunty. Thank you. Installing libm4ri-dev from jaunty allowed sagemath to be built. After that, I needed to I needed to compile from source the following packages: lcalc gfan gap-guava libcdd-tes

[sage-devel] Re: 3d display: x3d?

2009-03-11 Thread Prabhu Ramachandran
On 03/10/09 16:41, Jason Grout wrote: >> http://nb.hpfem.org/home/pub/16 > > I just installed FreeWRL and looked at this. Awesome! It looks like > this might be the best way to get good opengl graphics (and mayavi!) in > the sage notebook while we still wait on the possibility of an html >

[sage-devel] Re: Test failing on "ImportError: cannot import name Set"...

2009-03-11 Thread Jason Grout
Florent Hivert wrote: >Dar all, > I'd rather fix the infrastructure if at all possible ... >>> It should be fairly simple to add a wipe option that kills all left >>> over pyc and so build remnants, but I personally tend to wipe out >>> "build" and just rebuild the Sage library if I

[sage-devel] Re: Test failing on "ImportError: cannot import name Set"...

2009-03-11 Thread Florent Hivert
Dar all, > > > I'd rather fix the infrastructure if at all possible ... > > > > It should be fairly simple to add a wipe option that kills all left > > over pyc and so build remnants, but I personally tend to wipe out > > "build" and just rebuild the Sage library if I can't manually fix i

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Florent Hivert
On Wed, Mar 11, 2009 at 08:27:14AM +0100, Ralf Hemmecke wrote: > > > In short: for < = in, if it was just me, I would only use the most > > absolutely trivial coercions. And in particular avoid there all the > > coercions that involve projections and not embedding (like Z -> Z/nZ) > > > Just my

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Ralf Hemmecke
> In short: for < = in, if it was just me, I would only use the most > absolutely trivial coercions. And in particular avoid there all the > coercions that involve projections and not embedding (like Z -> Z/nZ) > Just my own feeling ... And mine. Ralf --~--~-~--~~~-

[sage-devel] Re: element of integermod is element of integer?

2009-03-11 Thread Nicolas M. Thiery
On Tue, Mar 10, 2009 at 06:27:41PM -0700, Robert Bradshaw wrote: > Currently the rule is that if you can do arithmetic between two > elements, you can compare them. Ok, I am not used to it, but this seems fair enough. > Membership code is something entirely different. > > > I typically write

[sage-devel] Re: Coercion and exception handling

2009-03-11 Thread Nicolas M. Thiery
> > Wish you had brought this up sooner. The other day I was looking at > > that code and thinking "oh, I could get rid of catching stuff there" > > but as it wasn't relevant to what I was doing at the time and I > > didn't see any urgency it went on my "todo later" list. I'll put up a > >