2014-03-18 19:13 GMT+01:00, john_perry_usm <[email protected]>:
> It looks as if there are infinitely many solutions. If you clear the
> denominators, you get polynomials, with which you can compute a
> lexicographical Gröbner basis of 15 elements (given below). The dimension
> of the corresponding ideal is 4, which is admittedly the dimension of the
> set of complex solutions, but I can find quite a few real solutions, as
> well: for example, {r1=r2=s1=s2=1,t1=-4,t2=6,t3=-4,t4=1}. To obtain those,
> I first converted the result of the Gröbner basis back to SR. It's actually
>
> pretty quick once you get the hang of it. As long as you keep t4=/=0, this
> method should work.
>
> There's probably a better way, though.
>
> john perry
>
> Gröbner basis:
>
> {
> r1*r2*t1 + 2*r1*s2 + 2*r2*s1,
> r1*r2*t2 - r1 - r2 - 4*s1*s2,
> r1*s2*t2 + 1/2*r1*t1 - r2*s2^2*t3 - 8*s1*s2^3*t3 - 4*s1*s2^2*t2 + s1 +
> 8*s2^5*t4 + 4*s2^4*t3 - 2*s2^3*t2 - s2^2*t1 - s2,
> r1*t3 + r2*t3 + 4*s1*s2*t3 + 2*s1*t2 + 2*s2*t2,
> r1*t4 + r2*t4 - 4*s2^2*t4 - 2*s2*t3 - t2,
> r2^2*t3 + 2*r2*s2^2*t3 + 2*r2*s2*t2 - r2*t1 + 16*s2^5*t4 + 8*s2^4*t3 +
> 4*s2^3*t2 + 2*s2^2*t1 - 4*s2,
> r2^2*t4 - r2*s2*t3 - r2*t2 - 8*s2^4*t4 - 4*s2^3*t3 - 2*s2^2*t2 - s2*t1 +
> 1,
> r2*s1*t2 + r2*s2^2*t3 + 1/2*r2*t1 + 8*s1*s2^3*t3 + 4*s1*s2^2*t2 +
> 2*s1*s2*t1 - s1 - 8*s2^5*t4 - 4*s2^4*t3 + 2*s2^3*t2 + s2^2*t1 + s2,
> r2*s1*t3 - r2*s2*t3 - 4*s1*s2^2*t3 - 2*s1*s2*t2 - s1*t1 - 2*s2^2*t2 -
> s2*t1,
> r2*s2*t3^2 - 2*r2*t1*t4 + r2*t2*t3 + 32*s2^5*t4^2 + 40*s2^4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ing with the following system of nonlinear equations
>> [R_1*S_2+S_1*R_2==-(1/2)*(T_1/T_4),S_1+S_2==-(1/2)*(T_3/T_4),R_1+R_2+4*S_1*S_2==(T_2/T_4),R_1*R_2==1/T_4]
>>
>>
>> in the real variables R_1,R_2,S_1 and S_2. What is the best way to
>> solve this system using Sage, if there is any?
>> I tried to use solve, but we didn't receive any result within 26 hours.
>> Thanks a lot in advance!
>>
>> Best regards,
>>
>> Urs Hackstein
>>
>
Dear Prof. Perry,
thanks a lot for your interesting remark. T_1,T_2,T_3,T_4 aren't
variables of the system of equations, they are arbitrary, but fixed
real numbers. Does this change something?
However, if one tries to solve the system in a slightly rewritten form
with mathematica, one receives six set of roots satisfying the
equation in a fraction of a second. Why does Mathematica succeeds in
solving the system of equations and Sage not?
For the seek of completeness, I attach the attempt with Mathematica
(thanks to Ben Rodanski):
Solve[x1*x4 + x2*x3 == a*d && x1 + x3 == b*d && x1*x3 + x2 + x4 ==
c*d && x2*x4 == d, {x1, x2, x3, x4}]
Where: x1 =2*S_2; x2 = R_2; x3 =2S_1 ; x4 = R_1; a = -T_1; b = -T_3; c
= T_2; d = 1/T_4.
Below is just a first variable, calculated by Mathematica 9:
x1 -> -(-6 b d (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 - 9 a b c d^3 +
2 c^3 d^3 + \[Sqrt](4 (-12 d + 3 a b d^2 -
c^2 d^2)^3 + (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 -
9 a b c d^3 + 2 c^3 d^3)^2))^(
1/3) - \[Sqrt](36 b^2 d^2 (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 -
9 a b c d^3 +
2 c^3 d^3 + \[Sqrt](4 (-12 d + 3 a b d^2 -
c^2 d^2)^3 + (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 -
9 a b c d^3 + 2 c^3 d^3)^2))^(2/3) +
24 (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 - 9 a b c d^3 +
2 c^3 d^3 + \[Sqrt](4 (-12 d + 3 a b d^2 -
c^2 d^2)^3 + (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 -
9 a b c d^3 + 2 c^3 d^3)^2))^(
1/3) (24 2^(1/3) d - 6 2^(1/3) a b d^2 + 2 2^(1/3) c^2 d^2 -
4 c d (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 - 9 a b c d^3 +
2 c^3 d^3 + \[Sqrt](4 (-12 d + 3 a b d^2 -
c^2 d^2)^3 + (27 a^2 d^2 - 72 c d^2 +
27 b^2 d^3 - 9 a b c d^3 + 2 c^3 d^3)^2))^(1/3) +
2^(2/3) (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 -
9 a b c d^3 +
2 c^3 d^3 + \[Sqrt](4 (-12 d + 3 a b d^2 -
c^2 d^2)^3 + (27 a^2 d^2 - 72 c d^2 +
27 b^2 d^3 - 9 a b c d^3 + 2 c^3 d^3)^2))^(
2/3))))/(12 (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 -
9 a b c d^3 +
2 c^3 d^3 + \[Sqrt](4 (-12 d + 3 a b d^2 -
c^2 d^2)^3 + (27 a^2 d^2 - 72 c d^2 + 27 b^2 d^3 -
9 a b c d^3 + 2 c^3 d^3)^2))^(1/3))
Best regards,
Urs Hackstein
--
You received this message because you are subscribed to the Google Groups
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.