0
$\begingroup$

The equation containing trigonometric function is:

R == Sqrt[(i1-Sin[t])^2 + j1^2 + (k1-Cos[t])^2]*Sqrt[(i2-Sin[t])^2 + j2^2 + (k2-Cos[t])^2]*c/Sqrt[(Sqrt[(i1-Sin[t])^2 + j1^2 + (k1-Cos[t])^2]+Sqrt[(i2-Sin[t])^2 + j2^2 + (k2-Cos[t])^2]+c)*(-Sqrt[(i1-Sin[t])^2 + j1^2 + (k1-Cos[t])^2]+Sqrt[(i2-Sin[t])^2 + j2^2 + (k2-Cos[t])^2]+c)*(Sqrt[(i1-Sin[t])^2 + j1^2 + (k1-Cos[t])^2]-Sqrt[(i2-Sin[t])^2 + j2^2 + (k2-Cos[t])^2]+c)*(Sqrt[(i1-Sin[t])^2 + j1^2 + (k1-Cos[t])^2]+Sqrt[(i2-Sin[t])^2 + j2^2 + (k2-Cos[t])^2]-c)]

The t falls in range of (0,Pi/2). I want to solve t. How to make it?

This equation is too complicated and my computer could solve it for a long time?

$\endgroup$
2
  • 1
    $\begingroup$ Use the Weierstrass substitution (with suitable parameter restrictions) to convert it to a purely algebraic problem. $\endgroup$ Aug 10, 2017 at 11:20
  • 1
    $\begingroup$ Maybe also square both sides, but then you'll have to check which solutions are spurious. One might quickly eliminate some by numerically substituting sample values for the parameters. Checking probably is what is taking so long, and that's where @J.M.'s suggestion about parameter restrictions would be helpful. $\endgroup$
    – Michael E2
    Aug 10, 2017 at 11:44

1 Answer 1

1
$\begingroup$

This is your equation:

eq1 = R == Sqrt[(i1 - Sin[t])^2 + j1^2 + (k1 - Cos[t])^2]*
    Sqrt[(i2 - Sin[t])^2 + j2^2 + (k2 - Cos[t])^2]*
    c/Sqrt[(Sqrt[(i1 - Sin[t])^2 + j1^2 + (k1 - Cos[t])^2] + 
         Sqrt[(i2 - Sin[t])^2 + j2^2 + (k2 - Cos[t])^2] + 
         c)*(-Sqrt[(i1 - Sin[t])^2 + j1^2 + (k1 - Cos[t])^2] + 
         Sqrt[(i2 - Sin[t])^2 + j2^2 + (k2 - Cos[t])^2] + 
         c)*(Sqrt[(i1 - Sin[t])^2 + j1^2 + (k1 - Cos[t])^2] - 
         Sqrt[(i2 - Sin[t])^2 + j2^2 + (k2 - Cos[t])^2] + 
         c)*(Sqrt[(i1 - Sin[t])^2 + j1^2 + (k1 - Cos[t])^2] + 
         Sqrt[(i2 - Sin[t])^2 + j2^2 + (k2 - Cos[t])^2] - c)];

Let us transform it as follows:

eq2 = eq1 /. Sin[t] -> Sqrt[1 - Cos[t]^2] /. Cos[t] -> x

That gives a rather long expression. For this reason I do not write it here. It is in terms of x=Cos[t]. If we get x, we can then calculate arccos(x), provided -1<x<1. OK, let us solve it:

Solve[eq2, x]

It is solved exactly in somewhat about 10 min, but the result is a huge analytic expression, such that one can hardly make use of it.

Depending on the nature of the problem in such a situation I would look for some sort of a simplification of this equation.

Have fun!

$\endgroup$
2
  • $\begingroup$ I tried you solution on my workstation. It do be a huge formulation. Thank you. I wonder if there is any way to accelerate Command Solve[]? (My workstation has a GPU Nvidia K80) $\endgroup$
    – PureLine
    Aug 11, 2017 at 5:13
  • $\begingroup$ I do not think that you can do it considerably. $\endgroup$ Aug 11, 2017 at 6:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.