2
$\begingroup$

How I can solve the equation :

$$R -\tan^{-1}[(m1/m3)*(k3/k1)] - \tan^{-1}[(m1/m2)*(k2/k1)]=0$$

I tried on it using findroot as following :

$$
F = 0.56; 
w0 = 4*10^9*3.14;
wp = 10*10^9*3.14;
gama = 0.03*wp;
T = 0.03*w0;
e1 = -3.7;
m1 = -1;
e2 = 1;
m2 = 1;
e3 = -9.5;
m3 = 1;
w = 4.6*10^9*3.14;
c = 3*10^8;
k0 = w/c;
k1 = Sqrt[(k0^2*e1*m1) - b^2];
k2 = Sqrt[b^2 - (k0^2*e2*m2)];
k3 = Sqrt[b^2 - (k0^2*e3*m3)];
R = 3.45;

bbValue = 
 FindRoot[R - ArcTan[(m1/m3)*(k3/k1)] - ArcTan[(m1/m2)*(k2/k1)] , {b,0.5}]$$

But it give me an error :

The line search decreased the step size to within tolerance specified by AccuracyGoal and PrecisionGoal but was unable to find a sufficient decrease in the merit function. You may need more than MachinePrecision digits of working precision to meet these tolerances.

Regards

$\endgroup$
8
  • $\begingroup$ How I can solve the equation Solve it for what? $\endgroup$
    – Ghoster
    Feb 2 at 8:06
  • $\begingroup$ @Ghoster i want to solve it for b $\endgroup$
    – A.J.H
    Feb 2 at 8:08
  • $\begingroup$ There’s no $b$ in your equation. What is the point of writing the equation you are solving but not giving all the necessary info to check whether your code is correct? $\endgroup$
    – Ghoster
    Feb 2 at 8:11
  • $\begingroup$ it is not an error, just a warning on accuracy of root found. b -> 2.34938*10^-13 - 3.75897 I} $\endgroup$
    – Nasser
    Feb 2 at 8:35
  • $\begingroup$ @Ghoster there are b in k1 , k2 and k3 ... $\endgroup$
    – A.J.H
    Feb 2 at 8:46

1 Answer 1

3
$\begingroup$

Have a look at this plot

Plot[{Re[R - ArcTan[(m1/m3)*(k3/k1)] - ArcTan[(m1/m2)*(k2/k1)]], 
  Im[R - ArcTan[(m1/m3)*(k3/k1)] - ArcTan[(m1/m2)*(k2/k1)]]}, {b, -120, 120}]

Which root do you want to find?

enter image description here

$\endgroup$

Your Answer

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

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