How to plot a function with several constants using Wolfram Mathematica

Click For Summary

Homework Help Overview

The discussion revolves around plotting a probability density function in Wolfram Mathematica, specifically the function ψ*ψ = A^2 (x^2)exp(-2a(mx^2/h)), where m, a, A, and h are constants. Participants are exploring how to represent this function graphically while keeping the constants unchanged.

Discussion Character

  • Exploratory, Conceptual clarification, Mathematical reasoning

Approaches and Questions Raised

  • Participants discuss the feasibility of plotting the function with constants intact, with some suggesting that Wolfram Alpha treats constants as variables, complicating the plotting process. Others propose substituting constants with specific values to generate a graph.

Discussion Status

Some participants have offered guidance on normalizing the wave function to eliminate one constant, suggesting that this could simplify the plotting process. There are also suggestions to use variable manipulation techniques to explore the effects of constants on the graph.

Contextual Notes

There is an emphasis on the need for a unitless argument in the exponential function and the exploration of characteristic lengths in the problem. The discussion reflects uncertainty regarding the best approach to visualize the function while adhering to the constraints of Mathematica.

Hany_Draidi
Messages
1
Reaction score
0
How can I plot this probability density function using Wolfram Mathematica Keeping the constants the same.
ψ*ψ= A^2 (x^2)exp(-2a(mx^2/h)) ; where m,a,A,and h are constants and I want the graph in terms of them.
I tried: Plot[A^2 *(x^2)*exp(-2a(mx^2/h)),{x,-1000,1000}]
 
Physics news on Phys.org
You can't.
 
Hany_Draidi said:
How can I plot this probability density function using Wolfram Mathematica Keeping the constants the same.



ψ*ψ= A^2 (x^2)exp(-2a(mx^2/h)) ; where m,a,A,and h are constants and I want the graph in terms of them.



I tried: Plot[A^2 *(x^2)*exp(-2a(mx^2/h)),{x,-1000,1000}]

I would say you can't do that since Wolfram Alpha assumes that these terms are variables. Hence, there is no approach for this. You could just substitute the constants with any values and then, check the graph. You just have a graph; that doesn't guaranteed the exact graph you should expect. You will need to substitute random values!

I may be wrong. I am just assuming that is true.
 
You should be able to solve for A in terms of a, m, and h by requiring the wave function be normalized. That'll get rid of one constant.

What you want to do is come up with some combination of the constants that is a characteristic length in the problem. In this case, your wave function is
$$\psi(x) = A x e^{-\frac{ma}{\hbar}x^2}.$$ The argument of the exponential has to be unitless, and if you check the units, you'll indeed find that the combination ##ma/\hbar## has units of 1/length2. A natural choice for your length scale would therefore be ##\alpha=\sqrt{\hbar/ma}##. Now if you change variables from ##x## to ##x/\alpha##, you'll find that all of the constants will be gone. Once you have the density in that form, you can plot it using Mathematica.
 
Try using Manipulate. You can set the constants to starting values and then vary them with the sliders to see what effect they have. A notebook is attached
 

Attachments

Similar threads

  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 14 ·
Replies
14
Views
2K
  • · Replies 2 ·
Replies
2
Views
3K
Replies
4
Views
3K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K