File:Qgamma,q=2plot.png
From specialfunctionswiki
Size of this preview: 591 × 600 pixels. Other resolutions: 236 × 240 pixels | 872 × 885 pixels.
Original file (872 × 885 pixels, file size: 38 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 x1=np.arange(0.0673,2,0.001); # right of y-axis x2=np.arange(-0.9294,-0.037666,0.0001); # first hump left of y-axis x3=np.arange(-3.1,2,0.001); # horizontal line y=0 x4=np.arange(-40,20,0.1); # vertical line x=0 x5=np.arange(-40,20,0.1); # vertical line x=-1 x6=np.arange(-1.80288,-1.165,0.0001); # second hump left of y-axis x7=np.arange(-40,20,0.1); # vertical line x=-2 x8=np.arange(-2.888,-2.0999,0.001); # third hump left of y-axis x9=np.arange(-40,20,0.1); # vertical line x=-3 def g(x): return qgamma(x,2) f=np.vectorize(g) y1=f(x1) y2=f(x2) def h(x): return 0 k=np.vectorize(h) y3=k(x3) y4=k(x4) def l(x): return -1 m=np.vectorize(l) y5=m(x5) y6=f(x6) def n(x): return -2 o=np.vectorize(n) y7=o(x7) y8=f(x8) def p(x): return -3 q=np.vectorize(p) y9=q(x9) fig, ax = plt.subplots() xlabels = [item.get_text() for item in ax.get_xticklabels()] xlabels=[r'$-2$',r'$-1$',r'$0$'] ax.set_xticks([-2,-1,0]) ax.set_xticklabels(xlabels,horizontalalignment='center') plt.xlabel('$x$') plt.ylabel('$\mathrm{\Gamma_2}(x)$') plt.plot(x1,y1,linewidth=2,color='Black') plt.plot(x2,y2,linewidth=2,color='Black') plt.plot(x3,y3,'--',linewidth=2,color='Black') plt.plot(y4,x4,'--',linewidth=2,color='Black') # plot vertical line x=0 plt.plot(y5,x5,'--',linewidth=2,color='Black') # plot vertical line x=-1 plt.plot(x6,y6,linewidth=2,color='Black') # second hump left of y-axis plt.plot(y7,x7,'--',linewidth=2,color='Black') # vertical line x=-2 plt.plot(x8,y8,linewidth=2,color='Black') # third hump left of y-axis plt.plot(y9,x9,'--',linewidth=2,color='Black') # vertical line x=-3 plt.savefig('qgamma,q=2plot.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/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 19:40, 16 May 2016 | 872 × 885 (38 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 x1=np.arange(0.0673,2,0.001); # right of y-axis x2=np.arange(-0.9294,-0.0... |
- You cannot overwrite this file.
File usage
The following page links to this file: