[sage-support] Re: is_RealNumber does not work

2007-05-10 Thread Timothy Clemans

I was just trying to make something that would spot issues before an
object is created. You know be robust.

On 5/9/07, Justin C. Walker [EMAIL PROTECTED] wrote:


 On May 9, 2007, at 23:32 , Timothy Clemans wrote:

 
  Well I would like to make a Point class for a 2D coordinate system. So
  what is the best way to prevent most numbers with non-zero imaginary
  parts from becoming x and/or y in the definition of a given point?
  Like I would like to at least prevent 3 + i from being x and/or y.

 Why are you worried about this?  Would it be a problem if someone
 tried to do this with an integer mod 37, or a Plymouth?

 Justin

 --
 Justin C. Walker, Curmudgeon at Large
 Institute for the Absorption of Federal Funds
 ---
 If it weren't for carbon-14, I wouldn't date at all.
 ---



 


--~--~-~--~~~---~--~~
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/
-~--~~~~--~~--~--~---



[sage-support] Re: is_RealNumber does not work

2007-05-10 Thread Justin C. Walker


On May 9, 2007, at 23:44 , Timothy Clemans wrote:

 I was just trying to make something that would spot issues before an
 object is created. You know be robust.

I know what you are after, but I am not sure this is the way to do  
it.  You can spend a long time writing code that tries to predict all  
the ways a user can screw things up, and you will always end up with  
code that is full of those kind of holes, and which rapidly becomes  
unmaintainable.  Maybe better to approach robustness a different way  
(e.g., by catching errors when they happen, with 'try' clauses).

I think this thread is way OT now...

Justin

--
Justin C. Walker, Curmudgeon-At-Large
Institute for the Enhancement of the Director's Income

When LuteFisk is outlawed,
Only outlaws will have LuteFisk





--~--~-~--~~~---~--~~
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://sage.math.washington.edu/sage/ and http://sage.scipy.org/sage/
-~--~~~~--~~--~--~---