Solving a transcendental equation

6 views (last 30 days)
Irene Bujalance
Irene Bujalance on 10 Jul 2017
Commented: Walter Roberson on 11 Jul 2017
I have a question about a transcendental equation. I have to graph the following equation, but I'm not sure how to do it.
s='x == 5.6250e+18 + 1.6144e+17 * log(exp(y / (0.0197 * 8.61e-5 * 300)) -1) + (1.6e-19 * y / 1.1500e-04)'
I have tried to do
[Vgs, n] = solve (s, 'x, y')
But I get
Vgs =
 
0.0000000000000013913043478260869565217391304348 * z + 161440000000000000.0 * log (exp (1965.2118203560570776121104213218 * z) - 1.0) + 5625000000000000000.0
 
 
N =
 
Z
And I do not know how to plot that.
Thanks for all the help.

Answers (3)

Walter Roberson
Walter Roberson on 10 Jul 2017
You are trying to solve one equation for two variables.
It would make more sense to solve for y only.
Doing that would not produce any solution, because there is no closed form solution. So what you need to do is loop doing numeric solutions.
However... the slope is so steep on that equation that any numeric solutions you find will likely be numeric nonsense that do not hold true if you do simple algebraic rearrangement of the terms and re-evaluate.

Irene Bujalance
Irene Bujalance on 11 Jul 2017
The graph should have the following form (black lines):
I do not know how to solve the equation to be able to graph it, but the result that I must obtain is that. I would greatly appreciate your help.
I remind you of the equation:
V_gs=V_0+V_T*log(exp(n_ch / g*k_B*T)-1)+V_ox
where V_0, V_T, g, k_B, T y V_ox are constants.
  1 Comment
Walter Roberson
Walter Roberson on 11 Jul 2017
We do not know which of those variables corresponds to x and y in your equation.
If we guess that Vgs corresponds to y, then we can take your earlier equation,
F = @(y) 5.6250e+18+1.6144e+17*log(exp(y/(0.0197*8.61e-5*300))-1)+(1.6e-19*y/1.1500e-04)
>> F(1)
ans =
Inf
We can try again at higher precision:
>> vpa(F(sym(1)))
ans =
322888796278281890077.30381831847
>> log10(ans)
ans =
20.509052975958833328319403410146
10^20 is off your graph.
If we look at Vgs = 1 on your graph, you are expecting values between 10^9 and 10^13
>> vpasolve(1*sym(10^9) == 5.6250e+18 + 1.6144e+17 * log(exp(y / (0.0197 * 8.61e-5 * 300)) -1) + (1.6e-19 * y / 1.1500e-04),y,[sym(1e-20) 1])
ans =
0.0000000000000000003755026911452804353750597949076
>> vpasolve(1*sym(10^13) == 5.6250e+18 + 1.6144e+17 * log(exp(y / (0.0197 * 8.61e-5 * 300)) -1) + (1.6e-19 * y / 1.1500e-04),y,[sym(1e-20) 1])
ans =
0.00000000000000000037552594912153051969173701783793
These are values on the order of y ~= 3E-19 . They are also nearly the same, so a change on the order of 3E-23 is responsible for a result difference of 4 orders of magnitude (10^9 to 10^13).
We have to conclude that your original equation was wrong for your purposes.
We would need to know the constants involved in order to be able to speak about V_gs=V_0+V_T*log(exp(n_ch / g*k_B*T)-1)+V_ox -- and in particular you need to re-check the units involved. For example perhaps 300 nm needs to enter the equation in the form of 300 * 10^(-9) m .

Sign in to comment.


Torsten
Torsten on 11 Jul 2017
n = logspace(6,13,20);
V_gs = V_0+V_T*log(exp(n/g*k_B*T)-1)+V_ox;
semilogy(V_gs,n)
Best wishes
Torsten.
  2 Comments
Irene Bujalance
Irene Bujalance on 11 Jul 2017
I've tried doing that by changing the values of n to:
n = [1000000: 100000000: 100000000000000];
And the graph that gives me fits well on the y-axis but not on the x-axis, as I show in the image.
What can I do to get the graph I sent in the previous message? Thank you very much in advance.
Torsten
Torsten on 11 Jul 2017
If the values on the x-axis do not fit, then either your equation is wrong or the values on the x-axis in the image you included are scaled (e.g. by a factor of 1e-18).
Best wishes
Torsten.

Sign in to comment.

Categories

Find more on Mathematics in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!