Dear Folks,

Pardon for the double-posting since I am unsure which list is more 
appropriate.

In section 2.4.1 of the Sage Tutorial, there is a non-linear equation 
example from Jason Grout that I tried out, but it failed. Details follow.

My version is built from the Ubuntu jaunty package source and runs on a 
Kubuntu Intrepid AMD 64 PC. The startup banner is

---------------------------------------------------------------------- 

| SAGE Version 3.0.5, Release Date: 2008-07-11                       | 

| Type notebook() for the GUI, and license() for information.        | 

----------------------------------------------------------------------

When I load the file with these contents for the example:
===
var('x y p q')
(x, y, p, q)
eq1 = p+q==9
eq2 = q*y+p*x==-6
eq3 = q*y^2+p*x^2==24
solve([eq1,eq2,eq3,p==1],p,q,x,y)
===

I get this error (with directory paths anonymized):
--------------------------------------------------------------------------- 

ValueError                                Traceback (most recent call 
last)

/Path-To-File_non_linear_eq_sage_0.py in <module>() 

       8 eq2 = q*y+p*x==-Integer(6) 

       9 eq3 = q*y**Integer(2)+p*x**Integer(2)==Integer(24) 

---> 10 solve([eq1,eq2,eq3,p==Integer(1)],p,q,x,y)     11
      12

/usr/lib/python2.5/site-packages/sage/calculus/equations.pyc in solve(f, 
*args, **kwds)
    1386                 s = m.solve(args)
    1387         except:
-> 1388             raise ValueError, "Unable to solve %s for %s"%(f, args)
    1389         a = repr(s)
    1390         sol_list = string_to_list_of_solutions(a)

ValueError: Unable to solve [q + p == 9, q*y + p*x == -6, q*y^2 + p*x^2 
== 24, p == 1] for (p, q, x, y)
WARNING: Failure executing file: <Path-To-File_non_linear_eq_sage_0.py>
---------------------------------------------------------------------------

The version of the tutorial that I am using came with the version of 
Sage installed. So, I do not think it is a version incmpatibility problem.

Can someone tell me what the workaround is, or whether I need to file a 
bug report.

Thank you.

Chandra

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to