
#1
Jul710, 09:26 AM

P: 3

Hi everyone,
I am trying to solve this complicated two simultaneous equations, and it has been taking more than 2 hours to solve .. and it is still running... can anyone tell me what is wrong .. thanks Solve[{((((1  xr)/xr)^(1/2) (M2^2 xr  1)/( 1 + (gam + 1)/2 M2^2  M2^2 xr))  (((1  xm)/xm)^(1/2) ( M1^2 xm  1)/(1 + (gam + 1)/2 M1^2  M1^2 xm)))/( 1 + (((1  xr)/xr)^(1/2) (M2^2 xr  1)/( 1 + (gam + 1)/2 M2^2  M2^2 xr)) (((1  xm)/xm)^(1/2) ( M1^2 xm  1)/(1 + (gam + 1)/2 M1^2  M1^2 xm))) == tanthi, xm  a xr == b}, {xm, xr}] 



#2
Jul710, 10:37 AM

P: 19

Try to solve xm in terms of xr from
xm  a xr == b then place it in the other equation, then solve just for xm. It may do the job. 



#3
Jul710, 01:03 PM

P: 3





#4
Jul810, 12:42 PM

P: 972

Mathematica taking a long time to solve
Disclaimer: This is somewhat user superstition.
It seems that when Solve is given "complicated equations" that the size of the expression has a serious effect on the run time. Doing what is possible to reduce the size of the expressions seems to help. Notice that gam always appears as (gam + 1)/2 in your expression. Substituting using expression/.(gam + 1)/2>g will reduce the size and not change the results. If I have not made any mistake then the smallest I have been able to make your expression is ((Sqrt[1 + 1/xm]*(1 + M1^2*xm)*(1 + M2^2*(g  xr))) + (1 + M1^2*(g  xm))*Sqrt[1 + 1/xr]*(1 + M2^2*xr))/((1 + M1^2*(g  xm))*(1 + M2^2*(g  xr))  Sqrt[1 + 1/xm]*(1 + M1^2*xm)*Sqrt[1 + 1/xr]*(1 + M2^2*xr)) That is about 2/3 the size of your original and does not incorporate the other suggestion of substituting for one of the xm or xr. 



#5
Jul810, 02:54 PM

PF Gold
P: 444

Its a sign of the solution probably having no analytic form, or at least a really crazy one.
It helps to assign some assumptions sometimes, especially when sqrts are involved. Are the M's or xm's or a/b positive? real? less than/gt one? These things can help speed things up: $Assumptions = b>0&&a>0&&0<=xm<=1 etc. 



#6
Jul1310, 01:20 AM

P: 3

thank you guys for your replies



Register to reply 
Related Discussions  
How Long Should This Be Taking?  Academic Guidance  8  
Taking only the positive sqrt in Mathematica  Math & Science Software  1  
Solve a PDE of 4order in space and 2nd order in time using Mathematica or Matlab  Differential Equations  0  
My first sports session in a long long time (groan)  General Discussion  14 