I wanted to make a plot of x^3+y^3=1729 (the well-known taxicab problem).
I'm sure there are better ways of acieving this but I opted for a naive
approach:

{{{
def sng(x):
  if x < 0:
    return -1
  return 1

def f(x):
  y3 = 1729 - x^3
  return sgn(y3) * abs(y3)^(1/3)
}}}

{{{
c = parametric_plot((x,f(x)),-15,15)
c.show()
}}}

(I want to add other things to the plot).
However, when I run this in the notebook, the plot has a cusp at x=12+
and behaves as if the sgn(x) has been taken as +1. I tried evaluating
f(x) at 12 and 13 and the result changes sign as I'd expect.
Am I doing something totally stupid or is there a bug here?

Bill
(still running 2.10.1.rc3 on Linux, Ubuntu 7.10 on a Toshiba Equium laptop)
-- 
+---------------------------------------+
| Bill Purvis, Amateur Mathematician    |
|  email: [EMAIL PROTECTED]                  |
|  http://bil.members.beeb.net          |
+---------------------------------------+

--~--~---------~--~----~------------~-------~--~----~
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://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to