0
$\begingroup$

$K = sign(\gamma)\cdot \{ \frac{A\cdot B}{R}[5-\frac{\gamma}{\pi}+8\theta \sinh(\frac{\gamma}{4\pi \theta})]-\frac{12A\cdot B\cdot \theta}{R}[4\sinh (\frac{\gamma}{8\pi \theta})] +\frac{A^2}{R}[2\theta \tanh \frac{1}{2\theta}-3] \}$

I want to obtain $\gamma$ for a specific value of $K$ and I have to resort to a numerical solver. However, I have never used this type of equation with a numerical solver and thus I was hoping someone can explain me how to solve this.

Usually, when I use a numerical solver the equation has the form similar to $\frac{dy}{dt}=0.2xy$ with an initial condition $y(0)=1$ and I can solve it using for example the following code:

f = @(x,y) 0.2*x*y
y0 = 1;
t0 = 0;tfinal = 4;
[x y] = ode45(f,[t0 tfinal],y0)
plot(x,y)

One of you experts can help me out, please?

$\endgroup$
  • $\begingroup$ ... and for specific values of $A,B,R,\theta$ as well... You are accustomed to differential equation solver. You need either a plain equation solver, or write down a form of Newton's method (advise: suppress the frontal "$sign(\gamma)$") by separating your study into 2 cases, either + signe or - sign. $\endgroup$ – Jean Marie Dec 27 '16 at 12:19
  • $\begingroup$ thank you for your answer. $A,B,R$ and $\theta$ are constants that are given (should have put that in the text,sorry). I have been told that I have to use a numerical solver in order to solve that equation... so are you saying I should use another solver because numerical solver can't solve that equation? If yes, do you know which solver (in MATLAB syntax) I can use? $\endgroup$ – user203 Dec 27 '16 at 12:33
  • $\begingroup$ Use matlab's "fsolve". $\endgroup$ – Jean Marie Dec 27 '16 at 13:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.