import mppnp as mp import utils import mesa as ms logdir='/rpod2/athira/mesa/case1/LOGS' p=ms.mesa_profile(logdir,100,num_type='model') cycles_1=p.log_ind.keys() cycles_1.sort() m=mp.se('/rpod2/athira/mppnp/case1/H5_out') #specs1a_l=['$^1H$','$^4He$','$^{12}C$','$^{13}C$','$^{14}N$','$^{15}N$','$^{16}O$','$^{18}O$','$^{19}F$','$^{22}Ne$'] specs1a_l=['$^1H$','$^4He$','$^{12}C$','$^{13}C$','$^{14}N$'] specs1b_l=['$^{15}N$','$^{16}O$','$^{18}O$','$^{19}F$','$^{22}Ne$'] lines=['b--','ro-','bs-','k-.','r+:','bd-','kx--','r>-','kp-','r.:','k^-'] matplotlib.rc('xtick',labelsize=13,color='k') matplotlib.rc('ytick',labelsize=10) matplotlib.rc('ytick.major',pad=6) matplotlib.rc('axes',labelsize=11,labelcolor='k') #par_l=['log T (K)','log D ($\mathrm{g^{s}/cc}$)'] par_l=['log $D_\mathrm{total}$','log $T$'] specs1a_l=['$^1H$','$^4He$','$^{12}C$','$^{13}C$','$^{14}N$'] specs1b_l=['$^{15}N$','$^{16}O$','$^{18}O$','$^{19}F$','$^{22}Ne$'] close(30) ifig=figure(30,figsize=(14,16)) subplot(3,2,1) ax1=ifig.add_subplot(3,2,1) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1 p=ms.mesa_profile(logdir,ind,num_type='model') i=0 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') log_D_mix=p.get('log_D_mix');logT=p.get('logT');mass_mesa=p.get('mass') par=[log_D_mix,logT] specs1a=[h1,he4,c12,c13,n14] specs1b=[n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[i], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 ax1.legend(loc='center', bbox_to_anchor=(-0.2, 0.5),prop={'size':8.6}) ax1.set_ylabel('Mass fraction') ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') #setp(ax1.get_xticklabels(), visible=False) ylim(1e-8,1.3) xlim(0.44,0.90) text(0.35, 1.0, '(i)a', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax2 = ax1.twinx() ax2.plot(mass_mesa,par[0],color='cyan',label=par_l[0],linewidth=2.5,alpha=0.7) ax2.set_ylabel(par_l[0]) ax2.set_xlabel('$Mr/M_\mathrm{\odot}$') xlim(0.44,0.90) ylim(0,16.0) ax2.yaxis.set_major_locator(MultipleLocator(4)) subplot(3,2,2) ax1=ifig.add_subplot(3,2,2) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1 ax1.plot(mass_mesa,par[1],color='orange',label=par_l[1],linewidth=2.5) ax1.set_ylabel(par_l[1]) xlim(0.44,0.90) ax1.yaxis.set_major_locator(MultipleLocator(0.5)) ax1.yaxis.set_minor_locator(MultipleLocator(0.1)) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(7.0,9.0) ax2 = ax1.twinx() for a in range (len(specs1b)): ax2.semilogy(mass,specs1b[a],lines[i], label=specs1b_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #setp(ax2.get_xticklabels(), visible=False) ax2.legend(loc='center', bbox_to_anchor=(1.2, 0.485),prop={'size':8.6}) ax2.set_xlabel('$Mr/M_\mathrm{\odot}$') ax2.set_ylabel('Mass fraction') ylim(1e-8,1.3) xlim(0.44,0.90) text(0.95, 1.0, '(i)b', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax1=ifig.add_subplot(3,2,3) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=650 p=ms.mesa_profile(logdir,ind,num_type='model') i=0 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') log_D_mix=p.get('log_D_mix');logT=p.get('logT');mass_mesa=p.get('mass') par=[log_D_mix,logT] specs1a=[h1,he4,c12,c13,n14] specs1b=[n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[i], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 ax1.set_ylabel('Mass fraction') ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) #ax1.legend(loc='center', bbox_to_anchor=(-0.25, 0.36),prop={'size':9.0}) #setp(ax1.get_xticklabels(), visible=False) text(0.35, 1.0, '(ii)a', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax2 = ax1.twinx() ax2.plot(mass_mesa,par[0],color='cyan',label=par_l[0],linewidth=2.5,alpha=0.7) ax2.set_ylabel(par_l[0]) xlim(0.44,0.90) ylim(0,16.0) ax2.yaxis.set_major_locator(MultipleLocator(4)) ax2.set_xlabel('$Mr/M_\mathrm{\odot}$') subplot(3,2,4) ax1=ifig.add_subplot(3,2,4) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=650 ax1.plot(mass_mesa,par[1],color='orange',label=par_l[1],linewidth=2.5) ax1.set_ylabel(par_l[1]) xlim(0.44,0.90) ax1.yaxis.set_major_locator(MultipleLocator(0.5)) ax1.yaxis.set_minor_locator(MultipleLocator(0.1)) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(7.0,9.0) ax2 = ax1.twinx() for a in range (len(specs1b)): ax2.semilogy(mass,specs1b[a],lines[i], label=specs1b_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #setp(ax2.get_xticklabels(), visible=False) #ax2.legend(loc='center', bbox_to_anchor=(1.17, 0.36),prop={'size':8.6}) ylim(1e-8,1.3) xlim(0.44,0.90) ax2.set_ylabel('Mass fraction') ax2.set_xlabel('$Mr/M_\mathrm{\odot}$') text(0.95, 1.0, '(ii)b', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax1=ifig.add_subplot(3,2,5) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1150 p=ms.mesa_profile(logdir,ind,num_type='model') i=0 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') log_D_mix=p.get('log_D_mix');logT=p.get('logT');mass_mesa=p.get('mass') par=[log_D_mix,logT] specs1a=[h1,he4,c12,c13,n14] specs1b=[n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[i], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #ax1.legend(loc='center', bbox_to_anchor=(-0.25, 0.36),prop={'size':9.0}) #setp(ax1.get_xticklabels(), visible=False) ax1.set_ylabel('Mass fraction') ylim(1e-8,1.3) xlim(0.44,0.90) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') text(0.35, 1.0, '(iii)a', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax2 = ax1.twinx() ax2.plot(mass_mesa,par[0],color='cyan',label=par_l[0],linewidth=2.5,alpha=0.7) ax2.set_ylabel(par_l[0]) xlim(0.44,0.90) ylim(0,16.0) ax2.yaxis.set_major_locator(MultipleLocator(4)) subplot(3,2,6) ax1=ifig.add_subplot(3,2,6) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1150 ax1.plot(mass_mesa,par[1],color='orange',label=par_l[1],linewidth=2.5) ax1.set_ylabel(par_l[1]) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') xlim(0.44,0.90) ax1.yaxis.set_major_locator(MultipleLocator(0.5)) ax1.yaxis.set_minor_locator(MultipleLocator(0.1)) ylim(7.0,9.0) ax2 = ax1.twinx() for a in range (len(specs1b)): ax2.semilogy(mass,specs1b[a],lines[i], label=specs1b_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #setp(ax2.get_xticklabels(), visible=False) #ax2.legend(loc='center', bbox_to_anchor=(1.17, 0.36),prop={'size':8.6}) ax2.set_ylabel('Mass fraction') ax2.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) text(0.95, 1.0, '(iii)b', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) savefig('nuc_profile1.eps');savefig('nuc_profile1.png');savefig('nuc_profile1.pdf') ########################## ######################## close(31) ifig=figure(31,figsize=(14,9)) ax1=ifig.add_subplot(2,2,1) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1750 log_D_mix=p.get('log_D_mix');logT=p.get('logT');mass_mesa=p.get('mass') i=0 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') p=ms.mesa_profile(logdir,ind,num_type='model') log_D_mix=p.get('log_D_mix');logT=p.get('logT');mass_mesa=p.get('mass') par=[log_D_mix,logT] specs1a=[h1,he4,c12,c13,n14] specs1b=[n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[i], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #ax1.legend(loc='center', bbox_to_anchor=(-0.25, 0.36),prop={'size':9.0}) #setp(ax1.get_xticklabels(), visible=False) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ax1.set_ylabel('Mass fraction') ylim(1e-8,1.3) xlim(0.44,0.90) text(0.35, 1.0, '(iv)a', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax2 = ax1.twinx() ax2.plot(mass_mesa,par[0],color='cyan',label=par_l[0],linewidth=2.5,alpha=0.7) ax2.set_ylabel(par_l[0]) xlim(0.44,0.90) ylim(0,16.0) ax2.yaxis.set_major_locator(MultipleLocator(4)) subplot(2,2,2) ax1=ifig.add_subplot(2,2,2) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1750 ax1.plot(mass_mesa,par[1],color='orange',label=par_l[1],linewidth=2.5) ax1.set_ylabel(par_l[1]) xlim(0.44,0.90) ax1.yaxis.set_major_locator(MultipleLocator(0.5)) ax1.yaxis.set_minor_locator(MultipleLocator(0.1)) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(7.0,9.0) ax2 = ax1.twinx() for a in range (len(specs1b)): ax2.semilogy(mass,specs1b[a],lines[i], label=specs1b_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #setp(ax2.get_xticklabels(), visible=False) #ax2.legend(loc='center', bbox_to_anchor=(1.17, 0.36),prop={'size':8.6}) ax2.set_ylabel('Mass fraction') ax2.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) text(0.95, 1.0, '(iv)b', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax1=ifig.add_subplot(2,2,3) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=2500 log_D_mix=p.get('log_D_mix');logT=p.get('logT');mass_mesa=p.get('mass') i=0 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') p=ms.mesa_profile(logdir,ind,num_type='model') log_D_mix=p.get('log_D_mix');logT=p.get('logT');mass_mesa=p.get('mass') par=[log_D_mix,logT] specs1a=[h1,he4,c12,c13,n14] specs1b=[n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[i], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #ax1.legend(loc='center', bbox_to_anchor=(-0.25, 0.36),prop={'size':9.0}) #setp(ax1.get_xticklabels(), visible=False) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ax1.set_ylabel('Mass fraction') ylim(1e-8,1.3) xlim(0.44,0.90) text(0.35, 1.0, '(v)a', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) ax2 = ax1.twinx() ax2.plot(mass_mesa,par[0],color='cyan',label=par_l[0],linewidth=2.5,alpha=0.7) ax2.set_ylabel(par_l[0]) xlim(0.44,0.90) ylim(0,16.0) ax2.yaxis.set_major_locator(MultipleLocator(4)) subplot(2,2,4) ax1=ifig.add_subplot(2,2,4) box = ax1.get_position() #ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=2500 ax1.plot(mass_mesa,par[1],color='orange',label=par_l[1],linewidth=2.5) ax1.set_ylabel(par_l[1]) xlim(0.44,0.90) ax1.yaxis.set_major_locator(MultipleLocator(0.5)) ax1.yaxis.set_minor_locator(MultipleLocator(0.1)) ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(7.0,9.0) ax2 = ax1.twinx() for a in range (len(specs1b)): ax2.semilogy(mass,specs1b[a],lines[i], label=specs1b_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) i+=1 #setp(ax2.get_xticklabels(), visible=False) #ax2.legend(loc='center', bbox_to_anchor=(1.17, 0.36),prop={'size':8.6}) ax2.set_ylabel('Mass fraction') ax2.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) text(0.95, 1.0, '(v)b', ha='center', va='center', rotation='horizontal',color='k',fontsize=14) savefig('nuc_profile2.eps');savefig('nuc_profile2.png');savefig('nuc_profile2.pdf') ''' ifig=figure(20,figsize=(10,12)) ax1=ifig.add_subplot(4,1,3) box = ax1.get_position() ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1150 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') specs1a=[h1,he4,c12,c13,n14,n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[a], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) #ax1.legend(loc='center', bbox_to_anchor=(1.14, 0.42),prop={'size':9.0}) ax1.set_ylabel('Mass fraction') #ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) #text(1.0, 1.0, '1a', ha='center', va='center', rotation='horizontal',color='k',fontsize=12) title('c') subplot(4,1,4) ax1=ifig.add_subplot(4,1,4) box = ax1.get_position() ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=2000 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') specs1a=[h1,he4,c12,c13,n14,n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[a], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) #ax1.legend(loc='center', bbox_to_anchor=(1.14, 0.42),prop={'size':9.0}) ax1.set_ylabel('Mass fraction') #ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) #text(1.0, 1.0, '1a', ha='center', va='center', rotation='horizontal',color='k',fontsize=12) title('d') ''' ''' close(10) ifig=figure(10,figsize=(8.25,11.6)) subplot(3,1,1) ax1=ifig.add_subplot(3,1,1) box = ax1.get_position() ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') specs1a=[h1,he4,c12,c13,n14,n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[a], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) ax1.legend(loc='center', bbox_to_anchor=(1.14, 0.42),prop={'size':9.0}) ax1.set_ylabel('Mass fraction') #ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.0,0.90) text(0.25,4e-3,"Core (Hydro)",rotation=90,color='orange',fontsize=9) text(0.462,4e-3,"Buffer",rotation=90,color='orange',fontsize=9) text(0.535,1e-3,"SOF",rotation=90,color='orange',fontsize=9) text(0.75,9e-4,"Envelope",rotation=90,color='orange',fontsize=9) #text(1.0, 1.0, '1a', ha='center', va='center', rotation='horizontal',color='k',fontsize=12) title('a') ifig=figure(10,figsize=(8.25,11.6)) subplot(3,2,3) ax1=ifig.add_subplot(3,2,3) box = ax1.get_position() ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=700 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') specs1a=[h1,he4,c12,c13,n14,n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[a], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) #ax1.legend(loc='center', bbox_to_anchor=(1.14, 0.42),prop={'size':9.0}) ax1.set_ylabel('Mass fraction') #ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) #text(1.0, 1.0, '1a', ha='center', va='center', rotation='horizontal',color='k',fontsize=12) title('b') subplot(3,2,4) ax1=ifig.add_subplot(3,2,4) box = ax1.get_position() ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=1150 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') specs1a=[h1,he4,c12,c13,n14,n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[a], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) #ax1.legend(loc='center', bbox_to_anchor=(1.14, 0.42),prop={'size':9.0}) ax1.set_ylabel('Mass fraction') #ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) #text(1.0, 1.0, '1a', ha='center', va='center', rotation='horizontal',color='k',fontsize=12) title('c') subplot(3,2,5) ax1=ifig.add_subplot(3,2,5) box = ax1.get_position() ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=2000 h1=m.get(ind,'H-1');he4=m.get(ind,'He-4');c12=m.get(ind,'C-12');c13=m.get(ind,'C-13');n14=m.get(ind,'N-14');n15=m.get(ind,'N-15');o16=m.get(ind,'O-16');o18=m.get(ind,'O-18');f19=m.get(ind,'F-19');ne22=m.get(ind,'Ne-22') mass=m.get(ind,'mass') specs1a=[h1,he4,c12,c13,n14,n15,o16,o18,f19,ne22] for a in range (len(specs1a)): ax1.semilogy(mass,specs1a[a],lines[a], label=specs1a_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) #ax1.legend(loc='center', bbox_to_anchor=(1.14, 0.42),prop={'size':9.0}) ax1.set_ylabel('Mass fraction') #ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') ylim(1e-8,1.3) xlim(0.44,0.90) #text(1.0, 1.0, '1a', ha='center', va='center', rotation='horizontal',color='k',fontsize=12) title('d') subplot(3,2,6) ax1=ifig.add_subplot(3,2,6) box = ax1.get_position() ax1.set_position([box.x0, box.y0, box.width * 0.90, box.height]) ind=2000 specs3_l=['$Fe$','$Ni$','$Zn$','$Y$','$Zr$','$Ba$','$La$'] neut_den_1=[] neut=m.get(ind,'Neutron-1') rho= m.get(ind,'rho') mass=m.get(ind,'mass') for a in range(len(neut)): res=(neut[a]*6*10**23*rho[a]) neut_den_1.append(res) fe56=m.get(ind,'Fe-56');fe57=m.get(ind,'Fe-57');fe58=m.get(ind,'Fe-58') ni58=m.get(ind,'Ni-58');ni60=m.get(ind,'Ni-60');ni61=m.get(ind,'Ni-61');ni62=m.get(ind,'Ni-62');ni64=m.get(ind,'Ni-64') zn64=m.get(ind,'Zn-64');zn66=m.get(ind,'Zn-66');zn67=m.get(ind,'Zn-67');zn68=m.get(ind,'Zn-68');zn70=m.get(ind,'Zn-70') y89=m.get(ind,'Y-89') zr90=m.get(ind,'Zr-90');zr91=m.get(ind,'Zr-91');zr92=m.get(ind,'Zr-92');zr94=m.get(ind,'Zr-94');zr96=m.get(ind,'Zr-96') ba130=m.get(ind,'Ba-130');ba132=m.get(ind,'Ba-132');ba134=m.get(ind,'Ba-134');ba135=m.get(ind,'Ba-135');ba136=m.get(ind,'Ba-136');ba137=m.get(ind,'Ba-137');ba138=m.get(ind,'Ba-138') la138=m.get(ind,'La-138');la139=m.get(ind,'La-139') fe=fe56/56.0+fe57/57.0+fe58/58.0 ni=ni58/58.0+ni60/60.0+ni61/61.0+ni62/62.0+ni64/64.0 zn=zn64/64.0+zn66/66.0+zn67/67.0+zn68/68.0+zn70/70.0 y=y89/89.0 zr=zr90/90.0+zr91/91.0+zr92/92.0+zr94/94.0+zr96/96.0 ba=ba130/130.0+ba132/132.0+ba134/134.0+ba135/135.0+ba136/136.0+ba137/137.0+ba138/138.0 la=la138/138.0+la139/139.0 specs3=[fe,ni,zn,y,zr,ba,la] for a in range (len(specs3)): ax1.semilogy(mass,specs3[a],lines[a], label=specs3_l[a],linewidth=2,markersize=5,alpha=0.60,markevery=15) ax1.legend(loc='center', bbox_to_anchor=(1.14, 0.42),prop={'size':9.0}) ax1.set_ylabel('Number fraction') #ax1.set_xlabel('$Mr/M_\mathrm{\odot}$') #ylim(1e-6,1e-4) xlim(0.44,0.90) #text(1.0, 1.0, '1a', ha='center', va='center', rotation='horizontal',color='k',fontsize=12) title('e') '''