Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

enter image description here

My goal is to get an analytical solution of x ( $\lambda$ in the problem), when $\epsilon$ (f[x] in the problem) is maximum (use inverse form).

I found that if I can use trigonometric identity to change Sin[x] and Cos[x] to Sin[2x] or Cos[2x], then I can achieve my goal. Here is the code that I wrote, but I found it is not very good, because for the third line I copy and paste from the evaluation cell.

So, can anyone think of an easier way to change $\epsilon$ in terms of 2$\lambda$, or can provide another way to achieve the goal?

f[x_] = (R ω^2 Sin[x] Cos[x])/(g - ω^2 (Cos[x])^2 R);

f'[x] // FullSimplify;

Solve[2 R ω^2 (R ω^2 + (-2 g + R ω^2) Cos[2 x]) == 0, Cos[2 x]][[1]] // FullSimplify;
share|improve this question
3  
You don't have to copy anything, try der = f'[x] // FullSimplify Solve[der == 0, Cos[2 x]][[1]] // FullSimplify –  Kuba Apr 16 at 6:31
add comment

1 Answer 1

up vote 5 down vote accepted

Another way is to use Maximize rather than solving for the zero of the derivative.

f[x_] = (r ω^2 Sin[x] Cos[x])/(g - ω^2 (Cos[x])^2 r);

as = {r > 0, ω > 0, g > 0, r ω^2 < g};

You can see that

f[x] // TrigReduce
(* -((r ω^2 Sin[2 x])/(-2 g + r ω^2 + r ω^2 Cos[2 x])) *)    

therefore you can make a simple substitution and, assuming the angle is very small,

sol = Simplify[Maximize[(f[x] // TrigReduce) /. {Cos[2 x] -> y, Sin[2 x] -> Sqrt[1 - y^2]}, 
                        y], 
        Assumptions -> as]
(* {(r ω^2)/(2 Sqrt[g (g - r ω^2)]), {y -> (r ω^2)/(2 g - r ω^2)}} *)
share|improve this answer
    
Thanks a lot. Your way is exactly what I want to get. –  Lawerance Apr 16 at 7:13
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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