2
$\begingroup$

I want to solve the following function and get values for $\omega$.

$$\omega - \omega_{21} + i/\tau_{2} - s_{1}\alpha_{1}(\omega)[1+f(\omega)] = 0$$

The function $f(\omega)$ is the troublesome function here. It is the summation given below.

$$f(\omega) = \frac{1}{5M}\sum_{l>1} \frac{(11l+7)s_{(l,d)}\alpha_{l}(\omega)}{\omega - \omega_{21} + i/\tau_{2}-s_{(l,d)}\alpha_{l}(\omega)}$$

I want to plot $\omega$ for different $d$ values.

Since $\alpha$ depend on $\omega$ and l go from 2- 50 resulting expression is very complex. I tried solving it numerically using Mathematica NSolve but it can't solve it even after one day.

Can you please tell me an alternative way to solve this?

This is the code I'm using solve it. For now I'm trying to solve $f(\omega)$.

w=3.91;
a=1.337390547776*10^13;
b=2.014911487003*10^15;
function1=w-b^2/(frequency*(frequency+1I*a))
c=2.2;
R=5*10^(-9);

alpha=(R^(2*mode+1)*(function1-c)/(function1+(mode+mode^(-1))*c))

Simplify[alpha]
d=7.253971512072*10^14;
h=6.582119514*10^-16;
h2=1.054571800*10^-34;
mu=4*3.335640952*10^(-30);
t=h/0.05;
m=function1 /. frequency-> d

inversion=((h2*Im[m]*R^3)/(2*mu^2*t))*(1+shellThickness/R)^6

s=((mu^2)/h2)*((mode+1)*inversion)/(3*(R+shellThickness)^(2*mode+4))

dipoleNumber=5000;

innerFunction=((11*mode+7)*s*alpha)/(frequency-d+1I/t-s*alpha)

simplifiedInnerFunction= Simplify[innerFunction]
summedOut = Sum[simplifiedInnerFunction,{mode,2,50}];
equationToSOlve = summedOut /. shellThickness -> 0.5*R;
NSolve[equationToSOlve==0,frequency]
$\endgroup$
10
  • 1
    $\begingroup$ Can you post the numerical values of all the constants ? $\endgroup$
    – Lotus
    Jun 19, 2018 at 9:30
  • $\begingroup$ The only constant here is M and $s_{1}$ which is in the range 1000-2000. All the other variables will change for different d and omega values. $\endgroup$
    – Coderzz
    Jun 19, 2018 at 9:33
  • $\begingroup$ Could you post your equations as text-only code in Mathematica syntax? Post all code and the numerical values of all the constants? $\endgroup$ Jun 19, 2018 at 9:41
  • 2
    $\begingroup$ You have constants that differ by dozens of orders of magnitude; numerical results will be catastrophically bad. Please, work in natural units, where all parameters are of order one. $\endgroup$ Jun 19, 2018 at 14:41
  • 1
    $\begingroup$ NSolve is not the right tool here; it is mostly for linear and polynomial equations; yours are neither. Instead, you want FindRoot together with a good estimate for a starting point in your solution process. Since you are using numerical solutions, it would be really important for their stability that you take @AccidentalFourierTransform 's advice and use better parameter values, otherwise you will have to waste a lot of resources on arbitrary precision calculations. $\endgroup$
    – MarcoB
    Jun 19, 2018 at 22:47

0

Your Answer

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

Browse other questions tagged or ask your own question.