Message Boards Message Boards

Solve a quantum potential well equation?

Posted 4 years ago

Hi. The quantum potential well equation is y''=-k y where k is a constant. I know how to write it in Mathematica

DSolve[y''[x] == -k y[x], y[x], x]

but I don't know how to write it with the boundary conditions. The boundary conditions are 0<x<a and y(x)=0 and y(a)=0. Please help me.

POSTED BY: Reza Hamzeh
2 Replies

I am not sure if this works for you, but this is what I think you are looking for. The documentation suggests clearing your function if something does not work correctly, so I started with that.

In[5]:= Clear[y]

In[7]:= DSolve[{y''[x] + k y[x] == 0, y[0] == 0, y[a] == 0}, y, x]

I have no idea how to paste the output but it is a Sin function with functional limitations on the values of k.

POSTED BY: Nathan Shpritz
Posted 4 years ago

Thanks, it's better now. How can I write it with this condition? => for x>a and x<0 y[a]==0.

POSTED BY: Reza Hamzeh
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract