nucleardatapy 0.2.1__py3-none-any.whl → 1.0.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- nucleardatapy/__init__.py +3 -1
- nucleardatapy/astro/setup_gw.py +18 -18
- nucleardatapy/astro/setup_mr.py +123 -33
- nucleardatapy/astro/setup_mup.py +10 -10
- nucleardatapy/corr/setup_EsymDen.py +0 -5
- nucleardatapy/corr/setup_EsymLsym.py +50 -17
- nucleardatapy/corr/setup_KsatQsat.py +170 -69
- nucleardatapy/create_folder.py +2 -2
- nucleardatapy/crust/setup_crust.py +364 -126
- nucleardatapy/data/astro/HESS/J1731-347.dat +4 -0
- nucleardatapy/data/astro/NICER/J0030+0451.dat +6 -6
- nucleardatapy/data/astro/NICER/J0437-4715.dat +4 -3
- nucleardatapy/data/astro/NICER/J0614-3329.dat +4 -0
- nucleardatapy/data/astro/NICER/J0740+6620.dat +5 -4
- nucleardatapy/data/hnuclei/1991-2L-Yamamoto.csv +6 -0
- nucleardatapy/data/hnuclei/2013-2L-Ahn.csv +1 -1
- nucleardatapy/data/hnuclei/2019-2L-Ekawa.csv +7 -0
- nucleardatapy/data/matter/micro/2006-BHF/2006-BHF-Av18-E2A-NM.dat +8 -8
- nucleardatapy/data/matter/micro/2020-SCGF-NM-N3LO-414-E2A.dat +21 -0
- nucleardatapy/data/matter/micro/2020-SCGF-NM-N3LO-414-TD.dat +22 -0
- nucleardatapy/data/matter/micro/2020-SCGF-NM-N3LO-450-E2A.dat +20 -0
- nucleardatapy/data/matter/micro/2020-SCGF-NM-N3LO-450-TD.dat +22 -0
- nucleardatapy/data/matter/micro/2020-SCGF-NM-N3LO-500-E2A.dat +23 -0
- nucleardatapy/data/matter/micro/2020-SCGF-NM-N3LO-500-TD.dat +22 -0
- nucleardatapy/data/matter/micro/2020-SCGF-SM-N3LO-414-E2A.dat +15 -0
- nucleardatapy/data/matter/micro/2020-SCGF-SM-N3LO-414-TD.dat +21 -0
- nucleardatapy/data/matter/micro/2020-SCGF-SM-N3LO-450-E2A.dat +15 -0
- nucleardatapy/data/matter/micro/2020-SCGF-SM-N3LO-450-TD.dat +21 -0
- nucleardatapy/data/matter/micro/2020-SCGF-SM-N3LO-500-E2A.dat +20 -0
- nucleardatapy/data/matter/micro/2020-SCGF-SM-N3LO-500-TD.dat +20 -0
- nucleardatapy/data/matter/micro/2024-ABI-NM-DeltaNNLO450.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-NM-DeltaNNLO500.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-NM-DeltaNNLOgo394.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-NM-DeltaNNLOgo450.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-NM-NNLOsat.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-SM-DeltaNNLO450.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-SM-DeltaNNLO500.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-SM-DeltaNNLOgo394.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-SM-DeltaNNLOgo450.dat +28 -0
- nucleardatapy/data/matter/micro/2024-ABI-SM-NNLOsat.dat +28 -0
- nucleardatapy/data/matter/nep/NEPESkyrme.dat +2 -3
- nucleardatapy/data/matter/nep/NEPGSkyrme.dat +7 -0
- nucleardatapy/data/matter/nep/NEPSkyrme.dat +4 -2
- nucleardatapy/data/matter/nep/NEPxEFT.dat +8 -0
- nucleardatapy/data/matter/nep/best67DDSkyrme.dat +28 -0
- nucleardatapy/data/matter/nep/best90DDSkyrme.dat +46 -0
- nucleardatapy/data/matter/nep/best95DDSkyrme.dat +54 -0
- nucleardatapy/data/matter/pheno/ESkyrme/BSk31-NM.dat +996 -996
- nucleardatapy/data/matter/pheno/ESkyrme/BSk31-SM.dat +991 -991
- nucleardatapy/data/matter/pheno/ESkyrme/BSkG4-NM.dat +1002 -0
- nucleardatapy/data/matter/pheno/ESkyrme/BSkG4-SM.dat +1002 -0
- nucleardatapy/data/matter/pheno/Skyrme/BSkG1-NM.dat +102 -0
- nucleardatapy/data/matter/pheno/Skyrme/BSkG1-SM.dat +102 -0
- nucleardatapy/data/matter/pheno/Skyrme/BSkG2-NM.dat +102 -0
- nucleardatapy/data/matter/pheno/Skyrme/BSkG2-SM.dat +102 -0
- nucleardatapy/env.py +1 -1
- nucleardatapy/eos/__init__.py +4 -3
- nucleardatapy/eos/setupCC.py +429 -0
- nucleardatapy/eos/setup_am.py +39 -14
- nucleardatapy/eos/setup_am_Beq.py +40 -15
- nucleardatapy/eos/setup_am_Leq.py +40 -15
- nucleardatapy/fig/__init__.py +24 -15
- nucleardatapy/fig/astro_setupGW_fig.py +9 -7
- nucleardatapy/fig/astro_setupMR_fig.py +26 -18
- nucleardatapy/fig/astro_setupMasses_fig.py +8 -6
- nucleardatapy/fig/astro_setupMtov_fig.py +10 -6
- nucleardatapy/fig/astro_setupMup_fig.py +9 -7
- nucleardatapy/fig/corr_setupEsymDen_fig.py +22 -9
- nucleardatapy/fig/corr_setupEsymLsym_fig.py +25 -8
- nucleardatapy/fig/corr_setupKsatQsat_fig.py +23 -17
- nucleardatapy/fig/crust_setupCrust_fig.py +11 -9
- nucleardatapy/fig/eos_setupAMBeq_fig.py +641 -156
- nucleardatapy/fig/eos_setupAMLeq_fig.py +53 -50
- nucleardatapy/fig/eos_setupAM_asy_lep_fig.py +373 -0
- nucleardatapy/fig/eos_setupAM_asy_nuc_fig.py +346 -0
- nucleardatapy/fig/eos_setupAM_asy_tot_fig.py +352 -0
- nucleardatapy/fig/eos_setupAM_fig.py +519 -0
- nucleardatapy/fig/eos_setupCC_fig.py +270 -0
- nucleardatapy/fig/hnuc_setupChart_fig.py +19 -16
- nucleardatapy/fig/hnuc_setupRE1LExp_fig.py +15 -5
- nucleardatapy/fig/matter_all_fig.py +971 -0
- nucleardatapy/fig/matter_setupCheck_fig.py +106 -0
- nucleardatapy/fig/matter_setupFFGLep_fig.py +74 -0
- nucleardatapy/fig/matter_setupFFGNuc_fig.py +286 -115
- nucleardatapy/fig/matter_setupHIC_fig.py +107 -67
- nucleardatapy/fig/matter_setupMicroEsym_fig.py +259 -73
- nucleardatapy/fig/matter_setupMicro_LP_fig.py +185 -82
- nucleardatapy/fig/matter_setupMicro_band_fig.py +126 -53
- nucleardatapy/fig/matter_setupMicro_effmass_fig.py +253 -77
- nucleardatapy/fig/matter_setupMicro_err_NM_fig.py +45 -20
- nucleardatapy/fig/matter_setupMicro_fig.py +317 -77
- nucleardatapy/fig/matter_setupMicro_gap_fig.py +237 -100
- nucleardatapy/fig/matter_setupNEPStats_fig.py +106 -0
- nucleardatapy/fig/matter_setupPhenoEsym_fig.py +204 -65
- nucleardatapy/fig/matter_setupPheno_fig.py +395 -93
- nucleardatapy/fig/nuc_setupBEExp_chart_fig.py +93 -73
- nucleardatapy/fig/nuc_setupBEExp_fig.py +97 -87
- nucleardatapy/fig/nuc_setupBETheo_fig.py +114 -81
- nucleardatapy/fig/nuc_setupISGMRExp_fig.py +12 -15
- nucleardatapy/fig/nuc_setupRchExp_fig.py +14 -22
- nucleardatapy/fig/nuc_setupRchTheo_fig.py +37 -40
- nucleardatapy/fig/nuc_setupRnpExp_fig.py +86 -106
- nucleardatapy/fig/nuc_setupRnpTheo_fig.py +105 -94
- nucleardatapy/hello.py +6 -0
- nucleardatapy/hnuc/setup_re1L_exp.py +6 -6
- nucleardatapy/hnuc/setup_re1Xi_exp.py +5 -5
- nucleardatapy/hnuc/setup_re2L_exp.py +36 -13
- nucleardatapy/matter/__init__.py +14 -14
- nucleardatapy/matter/setup_check.py +6 -6
- nucleardatapy/matter/setup_ffg.py +66 -39
- nucleardatapy/matter/setup_hic.py +91 -74
- nucleardatapy/matter/setup_micro.py +2033 -1007
- nucleardatapy/matter/setup_micro_band.py +6 -6
- nucleardatapy/matter/setup_micro_esym.py +56 -54
- nucleardatapy/matter/setup_micro_gap.py +24 -17
- nucleardatapy/matter/setup_micro_lp.py +2 -2
- nucleardatapy/matter/setup_nep.py +175 -92
- nucleardatapy/matter/{setup_nep_model_dist.py → setup_nep_stat_model.py} +13 -8
- nucleardatapy/matter/{setup_nep_dist.py → setup_nep_stat_models.py} +12 -8
- nucleardatapy/matter/setup_pheno.py +129 -49
- nucleardatapy/matter/setup_pheno_esym.py +22 -19
- nucleardatapy/nuc/setup_be_exp.py +306 -292
- nucleardatapy/nuc/setup_be_theo.py +288 -105
- nucleardatapy/nuc/setup_isgmr_exp.py +4 -4
- nucleardatapy/nuc/setup_rnp_exp.py +1 -0
- nucleardatapy/nuc/setup_rnp_theo.py +2 -1
- {nucleardatapy-0.2.1.dist-info → nucleardatapy-1.0.1.dist-info}/METADATA +48 -16
- {nucleardatapy-0.2.1.dist-info → nucleardatapy-1.0.1.dist-info}/RECORD +157 -124
- {nucleardatapy-0.2.1.dist-info → nucleardatapy-1.0.1.dist-info}/WHEEL +1 -1
- tests/test_corr_setupKsatQsat.py +3 -1
- tests/test_matter_setupMicro.py +37 -10
- nucleardatapy/data/matter/pheno/ESkyrme/BSkG1-NM.dat +0 -1002
- nucleardatapy/data/matter/pheno/ESkyrme/BSkG1-SM.dat +0 -1002
- nucleardatapy/data/matter/pheno/ESkyrme/BSkG2-NM.dat +0 -1002
- nucleardatapy/data/matter/pheno/ESkyrme/BSkG2-SM.dat +0 -1002
- nucleardatapy/fig/eos_setupAM_e_asy_lep_fig.py +0 -125
- nucleardatapy/fig/eos_setupAM_e_asy_nuc_fig.py +0 -115
- nucleardatapy/fig/eos_setupAM_e_asy_tot_fig.py +0 -117
- nucleardatapy/fig/eos_setupAM_e_fig.py +0 -173
- nucleardatapy/fig/matter_ENM_fig.py +0 -128
- nucleardatapy/fig/matter_ESM_fig.py +0 -140
- nucleardatapy/fig/matter_Esym_fig.py +0 -134
- nucleardatapy/fig/matter_cs2_fig.py +0 -83
- nucleardatapy/fig/matter_preNM_fig.py +0 -146
- nucleardatapy/fig/matter_preSM_fig.py +0 -144
- nucleardatapy/fig/matter_setupNEPModelDist_fig.py +0 -68
- /nucleardatapy/data/LandauParameters/micro/{2006-IBHF-NM-AV18.dat → 2006-EBHF-NM-AV18.dat} +0 -0
- /nucleardatapy/data/LandauParameters/micro/{2006-IBHF-SM-AV18.dat → 2006-EBHF-SM-AV18.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-BSK14.dat → 2022-GMRS-BSK14.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-BSK16.dat → 2022-GMRS-BSK16.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-DHSL59.dat → 2022-GMRS-DHSL59.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-DHSL69.dat → 2022-GMRS-DHSL69.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-F0.dat → 2022-GMRS-F0.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-H1.dat → 2022-GMRS-H1.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-H2.dat → 2022-GMRS-H2.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-H3.dat → 2022-GMRS-H3.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-H4.dat → 2022-GMRS-H4.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-H5.dat → 2022-GMRS-H5.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-H7.dat → 2022-GMRS-H7.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-LNS5.dat → 2022-GMRS-LNS5.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-RATP.dat → 2022-GMRS-RATP.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-SGII.dat → 2022-GMRS-SGII.dat} +0 -0
- /nucleardatapy/data/crust/{2022-crustGMRS-SLY5.dat → 2022-GMRS-SLY5.dat} +0 -0
- /nucleardatapy/data/matter/micro/{2013-QMC-NM.dat → 2013-MBPT-NM.dat} +0 -0
- /nucleardatapy/data/{NeutronSkin/ddrhNskin-208Pb.dat → rnp/ddrhrnp-208Pb.dat} +0 -0
- /nucleardatapy/data/{NeutronSkin/ddrhNskin-48Ca.dat → rnp/ddrhrnp-48Ca.dat} +0 -0
- /nucleardatapy/data/{NeutronSkin/nlrhNskin-208Pb.dat → rnp/nlrhrnp-208Pb.dat} +0 -0
- /nucleardatapy/data/{NeutronSkin/nlrhNskin-48Ca.dat → rnp/nlrhrnp-48Ca.dat} +0 -0
- /nucleardatapy/data/{NeutronSkin/skyrmeNskin-208Pb.dat → rnp/skyrmernp-208Pb.dat} +0 -0
- /nucleardatapy/data/{NeutronSkin/skyrmeNskin-48Ca.dat → rnp/skyrmernp-48Ca.dat} +0 -0
- {nucleardatapy-0.2.1.dist-info → nucleardatapy-1.0.1.dist-info}/licenses/LICENSE +0 -0
- {nucleardatapy-0.2.1.dist-info → nucleardatapy-1.0.1.dist-info}/top_level.txt +0 -0
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
import numpy as np
|
|
2
|
-
import matplotlib.pyplot as plt
|
|
3
|
-
|
|
4
|
-
import nucleardatapy as nuda
|
|
5
|
-
|
|
6
|
-
def eos_setupAM_e_asy_lep_fig( pname, micro_mbs, pheno_models, asy, band ):
|
|
7
|
-
"""
|
|
8
|
-
Plot nuclear chart (N versus Z).\
|
|
9
|
-
The plot is 1x2 with:\
|
|
10
|
-
[0]: nuclear chart.
|
|
11
|
-
|
|
12
|
-
:param pname: name of the figure (*.png)
|
|
13
|
-
:type pname: str.
|
|
14
|
-
:param table: table.
|
|
15
|
-
:type table: str.
|
|
16
|
-
:param version: version of table to run on.
|
|
17
|
-
:type version: str.
|
|
18
|
-
:param theo_tables: object instantiated on the reference band.
|
|
19
|
-
:type theo_tables: object.
|
|
20
|
-
|
|
21
|
-
"""
|
|
22
|
-
#
|
|
23
|
-
print(f'Plot name: {pname}')
|
|
24
|
-
#
|
|
25
|
-
fig, axs = plt.subplots(1,2)
|
|
26
|
-
#fig.tight_layout() # Or equivalently, "plt.tight_layout()"
|
|
27
|
-
fig.subplots_adjust(left=0.10, bottom=0.12, right=None, top=0.90, wspace=0.05, hspace=0.3 )
|
|
28
|
-
#
|
|
29
|
-
axs[0].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
30
|
-
axs[0].set_ylabel(r'$E_\text{lep}/A$')
|
|
31
|
-
axs[0].set_xlim([0, 0.28])
|
|
32
|
-
axs[0].set_ylim([-10, 35])
|
|
33
|
-
#
|
|
34
|
-
axs[1].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
35
|
-
#axs[1].set_ylabel(r'$E/A$')
|
|
36
|
-
axs[1].set_xlim([0, 0.28])
|
|
37
|
-
axs[1].set_ylim([-10, 35])
|
|
38
|
-
axs[1].tick_params('y', labelleft=False)
|
|
39
|
-
#
|
|
40
|
-
mb_check = []
|
|
41
|
-
#
|
|
42
|
-
for kmb,mb in enumerate(micro_mbs):
|
|
43
|
-
#
|
|
44
|
-
print('mb:',mb,kmb)
|
|
45
|
-
#
|
|
46
|
-
models, models_lower = nuda.matter.micro_esym_models_mb( mb )
|
|
47
|
-
#
|
|
48
|
-
print('models:',models)
|
|
49
|
-
#
|
|
50
|
-
if mb == 'VAR':
|
|
51
|
-
models.remove('1998-VAR-AM-APR-fit')
|
|
52
|
-
models_lower.remove('1998-var-am-apr-fit')
|
|
53
|
-
#
|
|
54
|
-
for model in models:
|
|
55
|
-
#
|
|
56
|
-
micro = nuda.eos.setupAM( model = model, kind = 'micro', asy = asy )
|
|
57
|
-
if nuda.env.verb_output: micro.print_outputs( )
|
|
58
|
-
#
|
|
59
|
-
check = nuda.matter.setupCheck( eos = micro, band = band )
|
|
60
|
-
#
|
|
61
|
-
if check.isInside:
|
|
62
|
-
lstyle = 'solid'
|
|
63
|
-
else:
|
|
64
|
-
lstyle = 'dashed'
|
|
65
|
-
#continue
|
|
66
|
-
#
|
|
67
|
-
if micro.esym is not None:
|
|
68
|
-
print('model:',model)
|
|
69
|
-
print('den:',micro.den)
|
|
70
|
-
print('e2a_lep:',micro.e2a_lep)
|
|
71
|
-
if mb in mb_check:
|
|
72
|
-
axs[0].plot( micro.den, micro.e2a_lep, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
73
|
-
else:
|
|
74
|
-
mb_check.append(mb)
|
|
75
|
-
axs[0].plot( micro.den, micro.e2a_lep, marker='o', linestyle=lstyle, label=mb, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
76
|
-
# end of model
|
|
77
|
-
# end of mb
|
|
78
|
-
axs[0].text(0.02,-8,'microscopic models',fontsize='10')
|
|
79
|
-
axs[0].text(0.02,-9.5,r'for $\delta=$'+str(asy),fontsize='10')
|
|
80
|
-
#
|
|
81
|
-
model_check = []
|
|
82
|
-
#
|
|
83
|
-
for kmodel,model in enumerate(pheno_models):
|
|
84
|
-
#
|
|
85
|
-
params, params_lower = nuda.matter.pheno_esym_params( model = model )
|
|
86
|
-
#
|
|
87
|
-
for param in params:
|
|
88
|
-
#
|
|
89
|
-
pheno = nuda.eos.setupAM( model = model, param = param, kind = 'pheno', asy = asy )
|
|
90
|
-
if nuda.env.verb_output: pheno.print_outputs( )
|
|
91
|
-
#
|
|
92
|
-
check = nuda.matter.setupCheck( eos = pheno, band = band )
|
|
93
|
-
#
|
|
94
|
-
if check.isInside:
|
|
95
|
-
lstyle = 'solid'
|
|
96
|
-
else:
|
|
97
|
-
lstyle = 'dashed'
|
|
98
|
-
#continue
|
|
99
|
-
#
|
|
100
|
-
if pheno.e2a_lep is not None:
|
|
101
|
-
print('model:',model,' param:',param)
|
|
102
|
-
if model in model_check:
|
|
103
|
-
axs[1].plot( pheno.den, pheno.e2a_lep, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
104
|
-
else:
|
|
105
|
-
model_check.append(model)
|
|
106
|
-
axs[1].plot( pheno.den, pheno.e2a_lep, linestyle=lstyle, label=model, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
107
|
-
# end of param
|
|
108
|
-
# end of model
|
|
109
|
-
#
|
|
110
|
-
#axs[1].fill_between( band.den, y1=(band.e2a-band.e2a_std), y2=(band.e2a+band.e2a_std), color=band.color, alpha=band.alpha, visible=True )
|
|
111
|
-
#axs[1].plot( band.den, (band.e2a-band.e2a_std), color='k', linestyle='dashed' )
|
|
112
|
-
#axs[1].plot( band.den, (band.e2a+band.e2a_std), color='k', linestyle='dashed' )
|
|
113
|
-
axs[1].text(0.02,-8,'phenomenological models',fontsize='10')
|
|
114
|
-
axs[1].text(0.02,-9.5,r'for $\delta=$'+str(asy),fontsize='10')
|
|
115
|
-
#
|
|
116
|
-
#axs[1].legend(loc='upper left',fontsize='8', ncol=2)
|
|
117
|
-
#axs[0,1].legend(loc='upper left',fontsize='xx-small', ncol=2)
|
|
118
|
-
#axs[1].legend(loc='lower center',bbox_to_anchor=(0.5,1.02),mode='expand',columnspacing=0,fontsize='8', ncol=2,frameon=False)
|
|
119
|
-
#fig.legend(loc='lower center',bbox_to_anchor=(0.5,1.02),mode='expand',columnspacing=0,fontsize='8', ncol=2,frameon=False)
|
|
120
|
-
fig.legend(loc='upper left',bbox_to_anchor=(0.15,1.0),columnspacing=2,fontsize='8',ncol=5,frameon=False)
|
|
121
|
-
#
|
|
122
|
-
if pname is not None:
|
|
123
|
-
plt.savefig(pname, dpi=200)
|
|
124
|
-
plt.close()
|
|
125
|
-
#
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
import numpy as np
|
|
2
|
-
import matplotlib.pyplot as plt
|
|
3
|
-
|
|
4
|
-
import nucleardatapy as nuda
|
|
5
|
-
|
|
6
|
-
def eos_setupAM_e_asy_nuc_fig( pname, micro_mbs, pheno_models, asy, band ):
|
|
7
|
-
"""
|
|
8
|
-
Plot nuclear chart (N versus Z).\
|
|
9
|
-
The plot is 1x2 with:\
|
|
10
|
-
[0]: nuclear chart.
|
|
11
|
-
|
|
12
|
-
:param pname: name of the figure (*.png)
|
|
13
|
-
:type pname: str.
|
|
14
|
-
:param table: table.
|
|
15
|
-
:type table: str.
|
|
16
|
-
:param version: version of table to run on.
|
|
17
|
-
:type version: str.
|
|
18
|
-
:param theo_tables: object instantiated on the reference band.
|
|
19
|
-
:type theo_tables: object.
|
|
20
|
-
|
|
21
|
-
"""
|
|
22
|
-
#
|
|
23
|
-
print(f'Plot name: {pname}')
|
|
24
|
-
#
|
|
25
|
-
fig, axs = plt.subplots(1,2)
|
|
26
|
-
#fig.tight_layout() # Or equivalently, "plt.tight_layout()"
|
|
27
|
-
fig.subplots_adjust(left=0.10, bottom=0.12, right=None, top=0.90, wspace=0.05, hspace=0.3 )
|
|
28
|
-
#
|
|
29
|
-
axs[0].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
30
|
-
axs[0].set_ylabel(r'$E_\text{nuc}/A$')
|
|
31
|
-
axs[0].set_xlim([0, 0.28])
|
|
32
|
-
axs[0].set_ylim([-10, 35])
|
|
33
|
-
#
|
|
34
|
-
axs[1].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
35
|
-
#axs[1].set_ylabel(r'$E/A$')
|
|
36
|
-
axs[1].set_xlim([0, 0.28])
|
|
37
|
-
axs[1].set_ylim([-10, 35])
|
|
38
|
-
axs[1].tick_params('y', labelleft=False)
|
|
39
|
-
#
|
|
40
|
-
mb_check = []
|
|
41
|
-
#
|
|
42
|
-
for kmb,mb in enumerate(micro_mbs):
|
|
43
|
-
#
|
|
44
|
-
print('mb:',mb,kmb)
|
|
45
|
-
#
|
|
46
|
-
models, models_lower = nuda.matter.micro_esym_models_mb( mb )
|
|
47
|
-
#
|
|
48
|
-
print('models:',models)
|
|
49
|
-
#
|
|
50
|
-
if mb == 'VAR':
|
|
51
|
-
models.remove('1998-VAR-AM-APR-fit')
|
|
52
|
-
models_lower.remove('1998-var-am-apr-fit')
|
|
53
|
-
#
|
|
54
|
-
for model in models:
|
|
55
|
-
#
|
|
56
|
-
micro = nuda.eos.setupAM( model = model, kind = 'micro', asy = asy )
|
|
57
|
-
if nuda.env.verb_output: micro.print_outputs( )
|
|
58
|
-
#
|
|
59
|
-
check = nuda.matter.setupCheck( eos = micro, band = band )
|
|
60
|
-
#
|
|
61
|
-
if check.isInside:
|
|
62
|
-
lstyle = 'solid'
|
|
63
|
-
else:
|
|
64
|
-
lstyle = 'dashed'
|
|
65
|
-
#continue
|
|
66
|
-
#
|
|
67
|
-
if micro.e2a_nuc is not None:
|
|
68
|
-
if mb in mb_check:
|
|
69
|
-
axs[0].plot( micro.den, micro.e2a_nuc, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
70
|
-
else:
|
|
71
|
-
mb_check.append(mb)
|
|
72
|
-
axs[0].plot( micro.den, micro.e2a_nuc, marker='o', linestyle=lstyle, label=mb, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
73
|
-
# end of model
|
|
74
|
-
# end of mb
|
|
75
|
-
axs[0].text(0.02,-8,'microscopic models',fontsize='10')
|
|
76
|
-
axs[0].text(0.02,-9.5,r'for $\delta=$'+str(asy),fontsize='10')
|
|
77
|
-
#
|
|
78
|
-
model_check = []
|
|
79
|
-
#
|
|
80
|
-
for kmodel,model in enumerate(pheno_models):
|
|
81
|
-
#
|
|
82
|
-
params, params_lower = nuda.matter.pheno_esym_params( model = model )
|
|
83
|
-
#
|
|
84
|
-
for param in params:
|
|
85
|
-
#
|
|
86
|
-
pheno = nuda.eos.setupAM( model = model, param = param, kind = 'pheno', asy = asy )
|
|
87
|
-
if nuda.env.verb_output: pheno.print_outputs( )
|
|
88
|
-
#
|
|
89
|
-
check = nuda.matter.setupCheck( eos = pheno, band = band )
|
|
90
|
-
#
|
|
91
|
-
if check.isInside:
|
|
92
|
-
lstyle = 'solid'
|
|
93
|
-
else:
|
|
94
|
-
lstyle = 'dashed'
|
|
95
|
-
#continue
|
|
96
|
-
#
|
|
97
|
-
if pheno.e2a_nuc is not None:
|
|
98
|
-
print('model:',model,' param:',param)
|
|
99
|
-
if model in model_check:
|
|
100
|
-
axs[1].plot( pheno.den, pheno.e2a_nuc, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
101
|
-
else:
|
|
102
|
-
model_check.append(model)
|
|
103
|
-
axs[1].plot( pheno.den, pheno.e2a_nuc, linestyle=lstyle, label=model, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
104
|
-
# end of param
|
|
105
|
-
# end of model
|
|
106
|
-
#
|
|
107
|
-
axs[1].text(0.02,-8,'phenomenological models',fontsize='10')
|
|
108
|
-
axs[1].text(0.02,-9.5,r'for $\delta=$'+str(asy),fontsize='10')
|
|
109
|
-
#
|
|
110
|
-
fig.legend(loc='upper left',bbox_to_anchor=(0.15,1.0),columnspacing=2,fontsize='8',ncol=5,frameon=False)
|
|
111
|
-
#
|
|
112
|
-
if pname is not None:
|
|
113
|
-
plt.savefig(pname, dpi=200)
|
|
114
|
-
plt.close()
|
|
115
|
-
#
|
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
import numpy as np
|
|
2
|
-
import matplotlib.pyplot as plt
|
|
3
|
-
|
|
4
|
-
import nucleardatapy as nuda
|
|
5
|
-
|
|
6
|
-
def eos_setupAM_e_asy_tot_fig( pname, micro_mbs, pheno_models, asy, band ):
|
|
7
|
-
"""
|
|
8
|
-
Plot nuclear chart (N versus Z).\
|
|
9
|
-
The plot is 1x2 with:\
|
|
10
|
-
[0]: nuclear chart.
|
|
11
|
-
|
|
12
|
-
:param pname: name of the figure (*.png)
|
|
13
|
-
:type pname: str.
|
|
14
|
-
:param table: table.
|
|
15
|
-
:type table: str.
|
|
16
|
-
:param version: version of table to run on.
|
|
17
|
-
:type version: str.
|
|
18
|
-
:param theo_tables: object instantiated on the reference band.
|
|
19
|
-
:type theo_tables: object.
|
|
20
|
-
|
|
21
|
-
"""
|
|
22
|
-
#
|
|
23
|
-
print(f'Plot name: {pname}')
|
|
24
|
-
#
|
|
25
|
-
fig, axs = plt.subplots(1,2)
|
|
26
|
-
fig.subplots_adjust(left=0.10, bottom=0.12, right=None, top=0.90, wspace=0.05, hspace=0.3 )
|
|
27
|
-
#
|
|
28
|
-
axs[0].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
29
|
-
axs[0].set_ylabel(r'$E_\text{tot}/A$')
|
|
30
|
-
axs[0].set_xlim([0, 0.28])
|
|
31
|
-
axs[0].set_ylim([-10, 35])
|
|
32
|
-
#
|
|
33
|
-
axs[1].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
34
|
-
#axs[1].set_ylabel(r'$E/A$')
|
|
35
|
-
axs[1].set_xlim([0, 0.28])
|
|
36
|
-
axs[1].set_ylim([-10, 35])
|
|
37
|
-
axs[1].tick_params('y', labelleft=False)
|
|
38
|
-
#
|
|
39
|
-
mb_check = []
|
|
40
|
-
#
|
|
41
|
-
for kmb,mb in enumerate(micro_mbs):
|
|
42
|
-
#
|
|
43
|
-
print('mb:',mb,kmb)
|
|
44
|
-
#
|
|
45
|
-
models, models_lower = nuda.matter.micro_esym_models_mb( mb )
|
|
46
|
-
#
|
|
47
|
-
print('models:',models)
|
|
48
|
-
#
|
|
49
|
-
if mb == 'VAR':
|
|
50
|
-
models.remove('1998-VAR-AM-APR-fit')
|
|
51
|
-
models_lower.remove('1998-var-am-apr-fit')
|
|
52
|
-
#
|
|
53
|
-
for model in models:
|
|
54
|
-
#
|
|
55
|
-
micro = nuda.eos.setupAM( model = model, kind = 'micro', asy = asy )
|
|
56
|
-
if nuda.env.verb_output: micro.print_outputs( )
|
|
57
|
-
#
|
|
58
|
-
check = nuda.matter.setupCheck( eos = micro, band = band )
|
|
59
|
-
#
|
|
60
|
-
if check.isInside:
|
|
61
|
-
lstyle = 'solid'
|
|
62
|
-
else:
|
|
63
|
-
lstyle = 'dashed'
|
|
64
|
-
#continue
|
|
65
|
-
#
|
|
66
|
-
if micro.esym is not None:
|
|
67
|
-
print('model:',model)
|
|
68
|
-
if mb in mb_check:
|
|
69
|
-
axs[0].plot( micro.den, micro.e2a_tot, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
70
|
-
else:
|
|
71
|
-
mb_check.append(mb)
|
|
72
|
-
axs[0].plot( micro.den, micro.e2a_tot, marker='o', linestyle=lstyle, label=mb, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
73
|
-
# end of model
|
|
74
|
-
# end of mb
|
|
75
|
-
#
|
|
76
|
-
axs[0].text(0.02,-8,'microscopic models',fontsize='10')
|
|
77
|
-
axs[0].text(0.02,-9.5,r'for $\delta=$'+str(asy),fontsize='10')
|
|
78
|
-
#
|
|
79
|
-
model_check = []
|
|
80
|
-
#
|
|
81
|
-
for kmodel,model in enumerate(pheno_models):
|
|
82
|
-
#
|
|
83
|
-
params, params_lower = nuda.matter.pheno_esym_params( model = model )
|
|
84
|
-
#
|
|
85
|
-
for param in params:
|
|
86
|
-
#
|
|
87
|
-
pheno = nuda.eos.setupAM( model = model, param = param, kind = 'pheno', asy = asy )
|
|
88
|
-
if nuda.env.verb_output: pheno.print_outputs( )
|
|
89
|
-
#
|
|
90
|
-
check = nuda.matter.setupCheck( eos = pheno, band = band )
|
|
91
|
-
#
|
|
92
|
-
if check.isInside:
|
|
93
|
-
lstyle = 'solid'
|
|
94
|
-
else:
|
|
95
|
-
lstyle = 'dashed'
|
|
96
|
-
#continue
|
|
97
|
-
#
|
|
98
|
-
if pheno.e2a_tot is not None:
|
|
99
|
-
print('model:',model,' param:',param)
|
|
100
|
-
#beta.label=None
|
|
101
|
-
if model in model_check:
|
|
102
|
-
axs[1].plot( pheno.den, pheno.e2a_tot, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
103
|
-
else:
|
|
104
|
-
model_check.append(model)
|
|
105
|
-
axs[1].plot( pheno.den, pheno.e2a_tot, linestyle=lstyle, label=model, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
106
|
-
# end of param
|
|
107
|
-
# end of model
|
|
108
|
-
#
|
|
109
|
-
axs[1].text(0.02,-8,'phenomenological models',fontsize='10')
|
|
110
|
-
axs[1].text(0.02,-9.5,r'for $\delta=$'+str(asy),fontsize='10')
|
|
111
|
-
#
|
|
112
|
-
fig.legend(loc='upper left',bbox_to_anchor=(0.15,1.0),columnspacing=2,fontsize='8',ncol=5,frameon=False)
|
|
113
|
-
#
|
|
114
|
-
if pname is not None:
|
|
115
|
-
plt.savefig(pname, dpi=200)
|
|
116
|
-
plt.close()
|
|
117
|
-
#
|
|
@@ -1,173 +0,0 @@
|
|
|
1
|
-
import numpy as np
|
|
2
|
-
import matplotlib.pyplot as plt
|
|
3
|
-
|
|
4
|
-
import nucleardatapy as nuda
|
|
5
|
-
|
|
6
|
-
def eos_setupAM_e_fig( pname, micro_mbs, pheno_models, band ):
|
|
7
|
-
"""
|
|
8
|
-
Plot nuclear chart (N versus Z).\
|
|
9
|
-
The plot is 1x2 with:\
|
|
10
|
-
[0]: nuclear chart.
|
|
11
|
-
|
|
12
|
-
:param pname: name of the figure (*.png)
|
|
13
|
-
:type pname: str.
|
|
14
|
-
:param table: table.
|
|
15
|
-
:type table: str.
|
|
16
|
-
:param version: version of table to run on.
|
|
17
|
-
:type version: str.
|
|
18
|
-
:param theo_tables: object instantiated on the reference band.
|
|
19
|
-
:type theo_tables: object.
|
|
20
|
-
|
|
21
|
-
"""
|
|
22
|
-
#
|
|
23
|
-
print(f'Plot name: {pname}')
|
|
24
|
-
#
|
|
25
|
-
fig, axs = plt.subplots(3,2)
|
|
26
|
-
fig.subplots_adjust(left=0.10, bottom=0.12, right=None, top=0.9, wspace=0.05, hspace=0.05 )
|
|
27
|
-
#
|
|
28
|
-
#axs[0,0].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
29
|
-
axs[0,0].set_ylabel(r'$E_\text{lep}/A$')
|
|
30
|
-
axs[0,0].set_xlim([0, 0.28])
|
|
31
|
-
axs[0,0].set_ylim([-2, 38])
|
|
32
|
-
axs[0,0].tick_params('x', labelbottom=False)
|
|
33
|
-
#
|
|
34
|
-
#axs[0,1].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
35
|
-
axs[0,1].set_xlim([0, 0.28])
|
|
36
|
-
axs[0,1].set_ylim([-2, 38])
|
|
37
|
-
axs[0,1].tick_params('y', labelleft=False)
|
|
38
|
-
axs[0,1].tick_params('x', labelbottom=False)
|
|
39
|
-
#
|
|
40
|
-
#axs[1,0].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
41
|
-
axs[1,0].set_ylabel(r'$E_\text{nuc}/A$')
|
|
42
|
-
axs[1,0].set_xlim([0, 0.28])
|
|
43
|
-
axs[1,0].set_ylim([-10, 30])
|
|
44
|
-
axs[1,0].tick_params('x', labelbottom=False)
|
|
45
|
-
#
|
|
46
|
-
#axs[1,1].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
47
|
-
axs[1,1].set_xlim([0, 0.28])
|
|
48
|
-
axs[1,1].set_ylim([-10, 30])
|
|
49
|
-
axs[1,1].tick_params('y', labelleft=False)
|
|
50
|
-
axs[1,1].tick_params('x', labelbottom=False)
|
|
51
|
-
#
|
|
52
|
-
axs[2,0].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
53
|
-
axs[2,0].set_ylabel(r'$E_\text{tot}/A$')
|
|
54
|
-
axs[2,0].set_xlim([0, 0.28])
|
|
55
|
-
axs[2,0].set_ylim([-2, 38])
|
|
56
|
-
#
|
|
57
|
-
axs[2,1].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
58
|
-
axs[2,1].set_xlim([0, 0.28])
|
|
59
|
-
axs[2,1].set_ylim([-2, 38])
|
|
60
|
-
axs[2,1].tick_params('y', labelleft=False)
|
|
61
|
-
#
|
|
62
|
-
# fix the asymmetry parameters
|
|
63
|
-
#
|
|
64
|
-
asys = [ 0.6, 0.8 ]
|
|
65
|
-
#
|
|
66
|
-
mb_check = []
|
|
67
|
-
model_check = []
|
|
68
|
-
#
|
|
69
|
-
for asy in asys:
|
|
70
|
-
#
|
|
71
|
-
print('asy:',asy)
|
|
72
|
-
#
|
|
73
|
-
for kmb,mb in enumerate(micro_mbs):
|
|
74
|
-
#
|
|
75
|
-
print('mb:',mb,kmb)
|
|
76
|
-
#
|
|
77
|
-
models, models_lower = nuda.matter.micro_esym_models_mb( mb )
|
|
78
|
-
#models, models_lower = nuda.matter.micro_models_mb( mb )
|
|
79
|
-
#
|
|
80
|
-
print('models:',models)
|
|
81
|
-
#
|
|
82
|
-
if mb == 'VAR':
|
|
83
|
-
models.remove('1998-VAR-AM-APR-fit')
|
|
84
|
-
models_lower.remove('1998-var-am-apr-fit')
|
|
85
|
-
#
|
|
86
|
-
for model in models:
|
|
87
|
-
#
|
|
88
|
-
micro = nuda.eos.setupAM( model = model, kind = 'micro', asy = asy )
|
|
89
|
-
if nuda.env.verb_output: micro.print_outputs( )
|
|
90
|
-
#
|
|
91
|
-
check = nuda.matter.setupCheck( eos = micro, band = band )
|
|
92
|
-
#
|
|
93
|
-
if check.isInside:
|
|
94
|
-
lstyle = 'solid'
|
|
95
|
-
else:
|
|
96
|
-
lstyle = 'dashed'
|
|
97
|
-
continue
|
|
98
|
-
#
|
|
99
|
-
if micro.e2a_lep is not None:
|
|
100
|
-
if mb in mb_check:
|
|
101
|
-
print('model:',model)
|
|
102
|
-
print('den:',micro.den)
|
|
103
|
-
print('e2a_lep:',micro.e2a_lep)
|
|
104
|
-
axs[0,0].plot( micro.den, micro.e2a_lep, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
105
|
-
axs[1,0].plot( micro.den, micro.e2a_nuc, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
106
|
-
axs[2,0].plot( micro.den, micro.e2a_tot, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
107
|
-
else:
|
|
108
|
-
mb_check.append(mb)
|
|
109
|
-
print('mb:',mb)
|
|
110
|
-
print('model:',model)
|
|
111
|
-
print('den:',micro.den)
|
|
112
|
-
print('e2a_lep:',micro.e2a_lep)
|
|
113
|
-
axs[0,0].plot( micro.den, micro.e2a_lep, marker='o', linestyle=lstyle, label=mb, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
114
|
-
axs[1,0].plot( micro.den, micro.e2a_nuc, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
115
|
-
axs[2,0].plot( micro.den, micro.e2a_tot, marker='o', linestyle=lstyle, markevery=micro.every, color=nuda.param.col[kmb] )
|
|
116
|
-
# end of model
|
|
117
|
-
# end of mb
|
|
118
|
-
#
|
|
119
|
-
for kmodel,model in enumerate(pheno_models):
|
|
120
|
-
#
|
|
121
|
-
params, params_lower = nuda.matter.pheno_esym_params( model = model )
|
|
122
|
-
#
|
|
123
|
-
for param in params:
|
|
124
|
-
#
|
|
125
|
-
pheno = nuda.eos.setupAM( model = model, param = param, kind = 'pheno', asy = asy )
|
|
126
|
-
if nuda.env.verb_output: pheno.print_outputs( )
|
|
127
|
-
#
|
|
128
|
-
check = nuda.matter.setupCheck( eos = pheno, band = band )
|
|
129
|
-
#
|
|
130
|
-
if check.isInside:
|
|
131
|
-
lstyle = 'solid'
|
|
132
|
-
else:
|
|
133
|
-
lstyle = 'dashed'
|
|
134
|
-
continue
|
|
135
|
-
#
|
|
136
|
-
if pheno.e2a_lep is not None:
|
|
137
|
-
print('model:',model,' param:',param)
|
|
138
|
-
if model in model_check:
|
|
139
|
-
axs[0,1].plot( pheno.den, pheno.e2a_lep, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
140
|
-
axs[1,1].plot( pheno.den, pheno.e2a_nuc, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
141
|
-
axs[2,1].plot( pheno.den, pheno.e2a_tot, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
142
|
-
else:
|
|
143
|
-
model_check.append(model)
|
|
144
|
-
axs[0,1].plot( pheno.den, pheno.e2a_lep, linestyle=lstyle, label=model, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
145
|
-
axs[1,1].plot( pheno.den, pheno.e2a_nuc, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
146
|
-
axs[2,1].plot( pheno.den, pheno.e2a_tot, linestyle=lstyle, markevery=pheno.every, color=nuda.param.col[kmodel] )
|
|
147
|
-
# end of param
|
|
148
|
-
# end of model
|
|
149
|
-
#
|
|
150
|
-
axs[0,0].text(0.02,0,'microscopic models',fontsize='10')
|
|
151
|
-
axs[0,1].text(0.02,0,'phenomenological models',fontsize='10')
|
|
152
|
-
#
|
|
153
|
-
axs[0,0].text(0.1,30,r'$\delta=0.6$',fontsize='10')
|
|
154
|
-
axs[0,1].text(0.1,30,r'$\delta=0.6$',fontsize='10')
|
|
155
|
-
axs[0,0].text(0.1,13,r'$\delta=0.8$',fontsize='10')
|
|
156
|
-
axs[0,1].text(0.1,13,r'$\delta=0.8$',fontsize='10')
|
|
157
|
-
#
|
|
158
|
-
axs[1,0].text(0.1,-2,r'$\delta=0.6$',fontsize='10')
|
|
159
|
-
axs[1,1].text(0.1,-2,r'$\delta=0.6$',fontsize='10')
|
|
160
|
-
axs[1,0].text(0.1,7,r'$\delta=0.8$',fontsize='10')
|
|
161
|
-
axs[1,1].text(0.1,7,r'$\delta=0.8$',fontsize='10')
|
|
162
|
-
#
|
|
163
|
-
axs[2,0].text(0.1,27,r'$\delta=0.6$',fontsize='10')
|
|
164
|
-
axs[2,1].text(0.1,27,r'$\delta=0.6$',fontsize='10')
|
|
165
|
-
axs[2,0].text(0.1,15,r'$\delta=0.8$',fontsize='10')
|
|
166
|
-
axs[2,1].text(0.1,15,r'$\delta=0.8$',fontsize='10')
|
|
167
|
-
#
|
|
168
|
-
fig.legend(loc='upper left',bbox_to_anchor=(0.15,1.0),columnspacing=2,fontsize='8',ncol=5,frameon=False)
|
|
169
|
-
#
|
|
170
|
-
if pname is not None:
|
|
171
|
-
plt.savefig(pname, dpi=200)
|
|
172
|
-
plt.close()
|
|
173
|
-
#
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
import numpy as np
|
|
2
|
-
import matplotlib.pyplot as plt
|
|
3
|
-
|
|
4
|
-
import nucleardatapy as nuda
|
|
5
|
-
|
|
6
|
-
def matter_ENM_fig( pname, micro_mbs, pheno_models, band ):
|
|
7
|
-
"""
|
|
8
|
-
Plot nucleonic energy per particle E/A in NM.\
|
|
9
|
-
The plot is 1x2 with:\
|
|
10
|
-
[0,0]: E/A versus den (micro). [0,1]: E/A versus den (pheno).\
|
|
11
|
-
|
|
12
|
-
:param pname: name of the figure (*.png)
|
|
13
|
-
:type pname: str.
|
|
14
|
-
:param micro_mbs: many-body (mb) approach considered.
|
|
15
|
-
:type micro_mbs: str.
|
|
16
|
-
:param pheno_models: models to run on.
|
|
17
|
-
:type pheno_models: array of str.
|
|
18
|
-
:param band: object instantiated on the reference band.
|
|
19
|
-
:type band: object.
|
|
20
|
-
|
|
21
|
-
"""
|
|
22
|
-
#
|
|
23
|
-
print(f'Plot name: {pname}')
|
|
24
|
-
#
|
|
25
|
-
fig, axs = plt.subplots(1,2)
|
|
26
|
-
fig.subplots_adjust(left=0.10, bottom=0.12, right=None, top=0.9, wspace=0.05, hspace=0.3 )
|
|
27
|
-
#
|
|
28
|
-
axs[0].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
29
|
-
axs[0].set_ylabel(r'$e_\text{NM}(n_\text{nuc})$')
|
|
30
|
-
axs[0].set_xlim([0, 0.34])
|
|
31
|
-
axs[0].set_ylim([0, 35])
|
|
32
|
-
#
|
|
33
|
-
axs[1].set_xlabel(r'$n_\text{nuc}$ (fm$^{-3}$)')
|
|
34
|
-
#axs[1].set_ylabel(r'$e_{sym}(n)$')
|
|
35
|
-
axs[1].set_xlim([0, 0.34])
|
|
36
|
-
axs[1].set_ylim([0, 35])
|
|
37
|
-
axs[1].tick_params('y', labelleft=False)
|
|
38
|
-
#
|
|
39
|
-
mb_check = []
|
|
40
|
-
#
|
|
41
|
-
for kmb,mb in enumerate(micro_mbs):
|
|
42
|
-
#
|
|
43
|
-
models, models_lower = nuda.matter.micro_models_mb( mb )
|
|
44
|
-
#
|
|
45
|
-
for model in models:
|
|
46
|
-
#
|
|
47
|
-
micro = nuda.matter.setupMicro( model = model )
|
|
48
|
-
if nuda.env.verb: micro.print_outputs( )
|
|
49
|
-
#
|
|
50
|
-
check = nuda.matter.setupCheck( eos = micro, band = band )
|
|
51
|
-
#
|
|
52
|
-
if check.isInside:
|
|
53
|
-
lstyle = 'solid'
|
|
54
|
-
else:
|
|
55
|
-
lstyle = 'dashed'
|
|
56
|
-
#
|
|
57
|
-
if micro.nm_e2a is not None:
|
|
58
|
-
print('mb:',mb,'model:',model)
|
|
59
|
-
if mb in mb_check:
|
|
60
|
-
if micro.marker:
|
|
61
|
-
if micro.e_err:
|
|
62
|
-
axs[0].errorbar( micro.nm_den, micro.nm_e2a, yerr=micro.nm_e2a_err, marker=micro.marker, markevery=micro.every, linestyle=lstyle, errorevery=micro.every, color=nuda.param.col[kmb] )
|
|
63
|
-
else:
|
|
64
|
-
axs[0].plot( micro.nm_den, micro.nm_e2a, marker=micro.marker, markevery=micro.every, linestyle=lstyle, color=nuda.param.col[kmb] )
|
|
65
|
-
else:
|
|
66
|
-
if micro.e_err:
|
|
67
|
-
axs[0].errorbar( micro.nm_den, micro.nm_e2a, yerr=micro.nm_e2a_err, marker=micro.marker, markevery=micro.every, linestyle=lstyle, errorevery=micro.every, color=nuda.param.col[kmb] )
|
|
68
|
-
else:
|
|
69
|
-
axs[0].plot( micro.nm_den, micro.nm_e2a, marker=micro.marker, markevery=micro.every, linestyle=lstyle, color=nuda.param.col[kmb] )
|
|
70
|
-
else:
|
|
71
|
-
mb_check.append(mb)
|
|
72
|
-
if micro.marker:
|
|
73
|
-
if micro.e_err:
|
|
74
|
-
axs[0].errorbar( micro.nm_den, micro.nm_e2a, yerr=micro.nm_e2a_err, marker=micro.marker, markevery=micro.every, linestyle=lstyle, label=mb, errorevery=micro.every, color=nuda.param.col[kmb] )
|
|
75
|
-
else:
|
|
76
|
-
axs[0].plot( micro.nm_den, micro.nm_e2a, marker=micro.marker, markevery=micro.every, linestyle=lstyle, label=mb, color=nuda.param.col[kmb] )
|
|
77
|
-
else:
|
|
78
|
-
if micro.e_err:
|
|
79
|
-
axs[0].errorbar( micro.nm_den, micro.nm_e2a, yerr=micro.nm_e2a_err, marker=micro.marker, markevery=micro.every, linestyle=lstyle, label=mb, errorevery=micro.every, color=nuda.param.col[kmb] )
|
|
80
|
-
else:
|
|
81
|
-
axs[0].plot( micro.nm_den, micro.nm_e2a, marker=micro.marker, markevery=micro.every, linestyle=lstyle, label=mb, color=nuda.param.col[kmb] )
|
|
82
|
-
# end model
|
|
83
|
-
# end mb
|
|
84
|
-
axs[0].fill_between( band.den, y1=(band.e2a-band.e2a_std), y2=(band.e2a+band.e2a_std), color=band.color, alpha=band.alpha, visible=True )
|
|
85
|
-
axs[0].plot( band.den, (band.e2a-band.e2a_std), color='k', linestyle='dashed' )
|
|
86
|
-
axs[0].plot( band.den, (band.e2a+band.e2a_std), color='k', linestyle='dashed' )
|
|
87
|
-
axs[0].text(0.06,2,'microscopic models',fontsize='10')
|
|
88
|
-
#
|
|
89
|
-
model_check = []
|
|
90
|
-
#
|
|
91
|
-
for kmodel,model in enumerate(pheno_models):
|
|
92
|
-
#
|
|
93
|
-
params, params_lower = nuda.matter.pheno_params( model = model )
|
|
94
|
-
#
|
|
95
|
-
for param in params:
|
|
96
|
-
#
|
|
97
|
-
pheno = nuda.matter.setupPheno( model = model, param = param )
|
|
98
|
-
if nuda.env.verb: pheno.print_outputs( )
|
|
99
|
-
#
|
|
100
|
-
check = nuda.matter.setupCheck( eos = pheno, band = band )
|
|
101
|
-
#
|
|
102
|
-
if check.isInside:
|
|
103
|
-
lstyle = 'solid'
|
|
104
|
-
else:
|
|
105
|
-
lstyle = 'dashed'
|
|
106
|
-
#
|
|
107
|
-
if pheno.nm_e2a is not None:
|
|
108
|
-
print('model:',model,' param:',param)
|
|
109
|
-
if model in model_check:
|
|
110
|
-
axs[1].plot( pheno.nm_den, pheno.nm_e2a, linestyle=lstyle, color=nuda.param.col[kmodel] )
|
|
111
|
-
else:
|
|
112
|
-
model_check.append(model)
|
|
113
|
-
axs[1].plot( pheno.nm_den, pheno.nm_e2a, linestyle=lstyle, color=nuda.param.col[kmodel], label=model )
|
|
114
|
-
# end param
|
|
115
|
-
# end model
|
|
116
|
-
axs[1].fill_between( band.den, y1=(band.e2a-band.e2a_std), y2=(band.e2a+band.e2a_std), color=band.color, alpha=band.alpha, visible=True )
|
|
117
|
-
axs[1].plot( band.den, (band.e2a-band.e2a_std), color='k', linestyle='dashed' )
|
|
118
|
-
axs[1].plot( band.den, (band.e2a+band.e2a_std), color='k', linestyle='dashed' )
|
|
119
|
-
axs[1].text(0.06,2,'phenomenological models',fontsize='10')
|
|
120
|
-
#
|
|
121
|
-
#axs[1].legend(loc='upper left',fontsize='8', ncol=2)
|
|
122
|
-
#axs[0,1].legend(loc='upper left',fontsize='xx-small', ncol=2)
|
|
123
|
-
fig.legend(loc='upper left',bbox_to_anchor=(0.15,1.0),columnspacing=2,fontsize='8',ncol=5,frameon=False)
|
|
124
|
-
#
|
|
125
|
-
if pname is not None:
|
|
126
|
-
plt.savefig(pname, dpi=200)
|
|
127
|
-
plt.close()
|
|
128
|
-
#
|