I tried to solve the following simple 3 equations with 3 variables:

sage: var ('P X Y')
(P, X, Y)

sage: eq
[(1/2) == -1/2*(2*P - 1)/Y + P/X, Y == 2*P*X/(2*P + 1), Y == P + 1/2]

sage: solve(eq,[P,X,Y])
[[P == (-1/2), X == 0, Y == 0]]

I know that there are 2 solutions, but solve returned a bad solution
(X==0??? it is in the denominator)

while playing with it a bit I discovered that the following (strange)
definition works:

sage: eq2
[Y == P + 1/2, [(1/2) == -1/2*(2*P - 1)/Y + P/X, Y == 2*P*X/(2*P +
1)]]

sage: solve(eq2,[P,X,Y])
[[P == -1/2*sqrt(2) - 1/2, X == -sqrt(2) + 1, Y == -1/2*sqrt(2)], [P
== 1/2*sqrt(2) - 1/2, X == sqrt(2) + 1, Y == 1/2*sqrt(2)]]

I am working with sage 4.5.2 on Ubuntu 10.04 64 bit

Thanks,
Maor

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

Reply via email to