File:Multiplebesseliplot.png

From specialfunctionswiki
Revision as of 23:33, 10 June 2016 by Tom (talk | contribs) (Category:Plot <pre>#!/usr/bin/python import numpy as np import matplotlib.pyplot as plt from mpmath import * from pylab import rcParams rcParams['figure.figsize'] = 10, 10 x=np.arange(-5,5,0.01); j0=np.vectorize(lambda x: besseli(0,x)) j1=np.vecto...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Original file(866 × 885 pixels, file size: 61 KB, MIME type: image/png)
#!/usr/bin/python
import numpy as np
import matplotlib.pyplot as plt
from mpmath import *
from pylab import rcParams
rcParams['figure.figsize'] = 10, 10

x=np.arange(-5,5,0.01);
j0=np.vectorize(lambda x: besseli(0,x))
j1=np.vectorize(lambda x: besseli(1,x))
j2=np.vectorize(lambda x: besseli(2,x))
j3=np.vectorize(lambda x: besseli(3,x))

y0=j0(x)
y1=j1(x)
y2=j2(x)
y3=j3(x)

def h(x):
        return 0
k=np.vectorize(h)
yatzero=k(x)

fig, ax = plt.subplots()

plt.xlabel(r'$x$')
plt.ylabel('Various Bessel functions')

plt.plot(x,y0,linewidth=2,color='Red',label=r'$I_0(x)$')
plt.plot(x,y1,linewidth=2,color='Blue',label=r'$I_1(x)$')
plt.plot(x,y2,linewidth=2,color='Green',label=r'$I_2(x)$')
plt.plot(x,y3,linewidth=2,color='Orange',label=r'$I_3(x)$')
#plt.plot(x,yatzero,'--',linewidth=2,color='Black')

plt.xlim(-5,5)
plt.legend(loc='best')

plt.savefig('multiplebesseliplot.png',bbox_inches='tight',pad_inches=0.15)

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current23:33, 10 June 2016Thumbnail for version as of 23:33, 10 June 2016866 × 885 (61 KB)Tom (talk | contribs)Category:Plot <pre>#!/usr/bin/python import numpy as np import matplotlib.pyplot as plt from mpmath import * from pylab import rcParams rcParams['figure.figsize'] = 10, 10 x=np.arange(-5,5,0.01); j0=np.vectorize(lambda x: besseli(0,x)) j1=np.vecto...
  • You cannot overwrite this file.

The following page links to this file:

Metadata