def plsvfig(LLS,NNS,X,projval,x_label,y_label,z_label,Title_fnc,save_fnc): fig = pl.figure() ax = fig.gca(projection = '3d') surf=ax.plot_surface(1e9*LS,NS,X,rstride=1,cstride=1,alpha=0.7,cmap=cm.winter,linewidth = 0.05, antialiased = True, shade = False) CS = contour(1e9*LLS,NNS,X, colors = 'k', linewidth = 0.5) cbar = pl.colorbar(surf) #cbar.ax.set_ylabel(r'$\mathcal{A}^{(0)}_{[9,3]}\,\,\,[zJ]$', size = 14) cbar.add_lines(CS) cset = ax.contour(1e9*LLS,NNS,X,zdir='z',offset = projval ,cmap = cm.Blues) ax.set_xlabel(x_label) ax.set_ylabel(y_label) ax.set_zlabel(z_label) pl.title(Title_fnc) #pl.title(r'$\rm{Gradient\, \mathcal{A}^{(0)}\, for \,[9,3]\, in\,water}$',size = 21) ax.view_init(elev = 17, azim = 150) savefig(save_fnc)#'plots/grad_A0_93_0.png')#, dpi = 300) #pl.show() return 0
surf=ax.plot_surface(1e9*LS,NS,X_93,rstride=1,cstride=1, alpha=0.5,cmap=cm.Reds,linewidth = 0.05, antialiased = True, shade = False) surf=ax.plot_surface(1e9*LS,NS,X_290,rstride=1,cstride=1,alpha=0.5,cmap=cm.hot,linewidth = 0.05, antialiased = True, shade = False) #cbar.ax.set_ylabel(r'$\mathcal{A}^{(0)}_{[9,3]}\,\,\,[zJ]$', size = 14) #pl.title(r'$\rm{Gradient\, \mathcal{A}^{(0)}\, for \,[9,3]\, in\,water}$',size = 21) ax.view_init(elev = 17, azim = 150) #fig = pl.figure() #ax = fig.gca(projection = '3d') #surf=ax.plot_surface(1e9*LS,NS,X,rstride=1,cstride=1,alpha=0.7,cmap=cm.winter,linewidth = 0.05, antialiased = True, shade = False) #CS = contour(1e9*LS,NS,X, colors = 'k', linewidth = 0.5) #cbar = pl.colorbar(surf) #cbar.ax.set_ylabel(r'$\mathcal{A}^{(0)}_{[9,3]}\,\,\,[zJ]$', size = 14) #cbar.add_lines(CS) #cset = ax.contour(1e9*LS,NS,X,zdir='z',offset = -0.25,cmap = cm.Blues) ax.set_xlabel(r'$\rm{separation}\,\,\,\ell\,\,[nm]$', size = 18) ax.set_ylabel(r'$\rm{n^{th}}\,Matsubra\,term$', size = 18) ax.set_zlabel(r'$\nabla \mathcal{A}^{(0)}\,\,[zJ]$',size = 18 ,rotation = 'horizontal' ) #pl.title(r'$\rm{Gradient\, \mathcal{A}^{(0)}\, for \,[9,3]\, in\,water}$',size = 21) #ax.view_init(elev = 17, azim = 10) savefig('plots/grad_A0_combo.png')#, dpi = 300) #show() # fig = pl.figure() ax = fig.gca(projection = '3d') contour(1e9*LS,NS,X_65, rstride=1,cstride=1,alpha=0.5,cmap=cm.Blues, linewidth = 0.05, antialiased = True, shade = False) contour(1e9*LS,NS,X_91, rstride=1,cstride=1,alpha=0.5,cmap=cm.Greens, linewidth = 0.05, antialiased = True, shade = False) contour(1e9*LS,NS,X_93, rstride=1,cstride=1,alpha=0.5,cmap=cm.Reds, linewidth = 0.05, antialiased = True, shade = False) contour(1e9*LS,NS,X_290,rstride=1,cstride=1,alpha=0.5,cmap=cm.Purples,linewidth = 0.05, antialiased = True, shade = False) #CS = contour(1e9*LS,NS,X, colors = 'k', linewidth = 0.5) #cbar = pl.colorbar(surf) #cbar.ax.set_ylabel(r'$\mathcal{A}^{(0)}_{[9,3]}\,\,\,[zJ]$', size = 14) #cbar.add_lines(CS)
cbar_290_0 = pl.colorbar(surf_290_0) cbar_290_0.ax.set_ylabel(r'$\mathcal{A}^{(0)}_{[29,0]}\,\,\,[zJ]$', size = 14) cbar_290_0.add_lines(CS_290_0) cset_065_0 = ax.contour(1e9*X,Y,1e21*A0_065_theta,zdir='y',offset = -0.3,cmap = cm.Blues) cset_091_0 = ax.contour(1e9*X,Y,1e21*A0_091_theta,zdir='y',offset = -0.3,cmap = cm.Greens) cset_290_0 = ax.contour(1e9*X,Y,1e21*A0_290_theta,zdir='y',offset = -0.3,cmap = cm.Reds) #man_loc = [(.1,.1),(.2,.2),(.3,.3),(.4,.4)] yticks([0, pi/8, pi/6, pi/4, pi/3, pi/2], ['$0$', r'$\frac{\pi}{8}$', r'$\frac{\pi}{6}$', r'$\frac{\pi}{4}$', r'$\frac{\pi}{3}$', r'$\frac{\pi}{2}$']) #clabel(CS, inline =1,fmt = '%1.1f', fontsize = 18,color = 'k', manual = man_loc) ax.grid(on = True) ax.set_xlabel(r'$\rm{separation}\,\,\,\ell\,\,[nm]$', size = 18) ax.set_ylabel(r'$\rm{angle}\,\,\,\theta\,\,[radians]$', size = 18) ax.set_zlabel(r'$\mathcal{A}^{(0)}\,\,[zJ]$',size = 18 ,rotation = 'horizontal' ) pl.title(r'$\rm{\mathcal{A}^{(0)}\, for \, [6,5],[9,1],\,and\,[29,0]\, in\,water}$', size = 21) ax.view_init(elev = 10, azim = 65) savefig('plots/A0_65_91_290.png')#, dpi = 300) show() ##### A_2 PLOTS ###### fig = figure() ax = fig.gca(projection = '3d') surf_065 = ax.plot_surface(1e9*X,Y,1e21*A2_065_theta, rstride = 5, cstride =5,alpha=0.7,cmap=cm.Blues, linewidth = 0.05, antialiased = True, shade = False)# True)#, cmap = hot() surf_091 = ax.plot_surface(1e9*X,Y,1e21*A2_091_theta, rstride = 5, cstride =5,alpha=0.7,cmap=cm.Greens, linewidth = 0.05, antialiased = True, shade = False)# True)#, cmap = hot() surf_290 = ax.plot_surface(1e9*X,Y,1e21*A2_290_theta, rstride = 5, cstride =5,alpha=0.7,cmap=cm.Reds, linewidth = 0.05, antialiased = True, shade = False)# True)#, cmap = hot()