import numpy
from enthought.mayavi import mlab
#def test_mesh():
#"""A very pretty picture of spherical harmonics translated from
#the octaviz example."""
for r in range (1,5):
print r
pi = numpy.pi
cos = numpy.cos
sin = numpy.sin
dphi, dtheta, dz = pi/250.0, pi/250.0, 0.01
import numpy as np
import matplotlib.pyplot as plt
E=[81.97400737666324, 322.0939978589591, 694.5766491226185]
V0=1000
a=0.1
def V(x):
if x > -a and x < a:
return 0
return V0
V=np.vectorize(V)
#psi=np.vectorize(psi)
x= np.linspace(-1.5*a,1.5*a,100)
plt.plot(x,V(x))
plt.xlim(-5*a,5*a)
what is the basic difference between the commands
import pylab as *
import matplotlib.pyplot as plt
--
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers