[plotter] removed unused overlay_kennicut

This commit is contained in:
Noe Brucy
2021-07-24 18:33:16 +02:00
parent a3318595ef
commit 35e5a767cb
-20
View File
@@ -1320,26 +1320,6 @@ class Plotter(Aggregator, BaseProcessor):
label = r"Power-law fit with index {:.1f}".format(a)
plt.plot(x, (10 ** b) * x ** a, label=label, **kwargs)
def overlay_kennicutt(self, n0, step):
"""
Add an overlay : Kennicutt mass accretion
"""
plt.grid(False)
ylim = plt.ylim()
(tmin, tmax) = plt.xlim()
tmax = tmax + 20
ymax = plt.ylim()[1]
ssfr_sun = 2.5e-9
ssfr_ken = ssfr_sun * n0 ** 1.4
coeff = ssfr_ken * 1e6 * (self.study.info["unit_length"].express(U.pc)) ** 2
for i in np.arange(tmin, max(tmax, tmin + ymax / coeff), step):
t = np.linspace(0, tmax, 1000)
plt.plot(t + i, t * coeff, ls="--", lw=0.9, color="grey")
plt.plot(t + tmin, (t + i - tmin) * coeff, ls="--", lw=0.9, color="grey")
plt.xlim(tmin, tmax)
plt.ylim(ylim)
def _gen_from_log(self, logrule, name_y, name_x="time", description="Generated"):
if name_x == "time":
name_rule = name_y