If I want to plot the function
$\qquad \psi(\rho,\theta,\phi)=\frac{1}{8}\left(\frac{1}{\pi}\right)^{1/2}\rho e^{-\rho/2}sin(\theta)e^{-i\phi}$,
for which I wrote the code
ψ[ρ_, θ_, ϕ_] := (E^(-(ρ/2) - i ϕ) ρ Sin[θ])/(8 Sqrt[π])
How would I go about making a plot? I'm thinking that I could convert these spherical coordinates to cartesian coordinates using a built-in function, but I haven't been able to get that to work.
SphericalPlot3D
won't plot a field. (2) It's a complex field, and only real fields can be plotted, so you have to chooseRe
,Im
,Abs
, and/orArg
. (3)ContourPlot3D
is one way to plot scalar fields. See alsoTransformedField
for converting from spherical to cartesian forContourPlot3D
. $\endgroup$i
in your function definition should beI
. $\endgroup$