Message Boards Message Boards

DSolve function provides unexpected solution?

GROUPS:

Hello,

I'm trying to solve symbolically the following second-order differential equation using the DSolve function.

My expression contains a number of variables, but it is of the form:

$f''(x) = a \exp{\frac{b-f(x)}{c}} + d $

Because $ f'' $ contains an exponential, I expect the solution $f(x)$ to also contain an exponential. However, the DSolve function provides me with a quadratic solution, which is not what I am looking for.

Am I misusing the DSolve function? Have I misunderstood the mathematics? Any help is appreciated.

In[13]:= q = 1.602 * 10 ^ -19 (* C *)
e0 = 8.854 * 10 ^ -14 (* F/cm *)
en = 13.9
Ncn = 2.1 * 10 ^ 17 (* cm^-3 *)
Fn = -0.079 (* eV, = -12.656 * 10 ^ -21 J*)
xN = 1 * 10 ^ -4 (* cm *)
Nd = 10 ^ 16 (* cm^-3 *)
ND = 2 * 10 ^ 18 (* cm^-3 *)
kT = 0.0259 (* eV *)
(*f[x] = Ec[x], conduction band energy*)
(* DSolve with no given boundary conditions *)
DSolve[f''[x]== (-q^2)/(e0*en) * (Ncn*Exp[(Fn-f[x])/kT] - Nd),f[x],x]
Out[13]= 1.602*10^-19
Out[14]= 8.854*10^-14
Out[15]= 13.9
Out[16]= 2.1*10^17
Out[17]= -0.079
Out[18]= 1/10000
Out[19]= 10000000000000000
Out[20]= 2000000000000000000
Out[21]= 0.0259
Out[22]= {{f[x]->1.04266*10^-10 (-2.29963*10^19 C[1]+1. (x+C[2])^2)}}
Attachments:
POSTED BY: Brian Appleton
Answer
2 months ago
q = 1.602 * 10 ^ -19 ;(* C *)
e0 = 8.854 * 10 ^ -14 ;(* F/cm *)
en = 13.9;
Ncn = 2.1 * 10 ^ 17 ;(* cm^-3 *)
Fn = -0.079; (* eV, = -12.656 * 10 ^ -21 J*)
xN = 1 * 10 ^ -4 ;(* cm *)
Nd = 10 ^ 16 ;(* cm^-3 *)
ND = 2 * 10 ^ 18 ;(* cm^-3 *)
kT = 0.0259 ;(* eV *)
(*f[x] = Ec[x], conduction band energy*)
(* DSolve with no given boundary conditions *)

enter image description here

POSTED BY: Frank Kampas
Answer
2 months ago

Note that it is only necessary to use semicolons to separate the statements if they are all in the same input cell. It's also not good practice to use capital letters when defining variables, since you may conflict with built-in constants and functions.

POSTED BY: Frank Kampas
Answer
2 months ago

The semicolons are not important here, they only suppress the display of the output. I think the problem is that you use floating-point numbers inside DSolve, which is designed for exact, symbolic calculations. My guess is that the internal algorithms convert the equation into some exact form, making approximations.

POSTED BY: Gianluca Gorni
Answer
2 months ago

If the semicolons aren't important, why did putting them in change the result?

It may be that NDSolve could handle this problem as a boundary value problem.

It's also possible to handle band bending calculations numerically using quasi-linearization

http://library.wolfram.com/infocenter/Conferences/368/

POSTED BY: Frank Kampas
Answer
2 months ago

What is the effective difference between my script and yours? It doesn't appear to me that you made anything other than stylistic changes.

Or is your point that, for the same input, you simply get a different answer from DSolve than I do?

POSTED BY: Brian Appleton
Answer
2 months ago

separating statements by semicolons is more than just a stylistic change. it is the standard for programming in Mathematica.

POSTED BY: Frank Kampas
Answer
2 months ago

Ah, I see. Nevertheless, adding semicolons to my variable definitions does not seem to fix the problem:

enter image description here

Interestingly, if I replace the variables with a simplified set of constants (while retaining the original form of the equation), I get:

enter image description here

which looks very similar to the result you obtained. I can work with this, but it still seems that there is something wrong with either my script or the application.

Thanks again... notebook is attached if anyone would like to test

Attachments:
POSTED BY: Brian Appleton
Answer
2 months ago

The two results with floating point variables look the same to me, with or without the semicolons.

POSTED BY: Gianluca Gorni
Answer
2 months ago

Group Abstract Group Abstract