milespy.sfh.SFH

class milespy.sfh.SFH(time=<Quantity [ 0.035, 0.74368421, 1.45236842, 2.16105263, 2.86973684, 3.57842105, 4.28710526, 4.99578947, 5.70447368, 6.41315789, 7.12184211, 7.83052632, 8.53921053, 9.24789474, 9.95657895, 10.66526316, 11.37394737, 12.08263158, 12.79131579, 13.5       ] Gyr>)

Bases: object

Class for manipulating star formation histories (SFH) and create derived spectra

time

Look-back time

Type:

Quantity

sfr

Values of the star formation rate (SFR) at each time

Type:

Quantity

met

Values of the metallicity at each time (dex)

Type:

Quantity

alpha

Values of [alpha/Fe] at each time (dex)

Type:

Quantity

imf

Values of the IMF slope

Type:

Quantity

Methods

alpha_linear([start, end, t_start, t_end])

Linear [alpha/Fe] evolution

alpha_sigmoid([start, end, tc, gamma])

Sigmoidal [alpha/Fe] evolution

imf_linear([start, end, t_start, t_end])

Linear IMF slope evolution

imf_sigmoid([start, end, tc, gamma])

Sigmoidal IMF slope evolution

met_linear([start, end, t_start, t_end])

Linear metallicity evolution

met_sigmoid([start, end, tc, gamma])

Sigmoidal metallicity evolution

sfr_custom(sfr[, mass])

User-defined SFR

sfr_delayed_tau([start, tau, mass])

Delayed exponentially declining SFR

sfr_double_power_law([a, b, tp, mass])

Double power law SFR evolution

sfr_lognormal([Tpeak, tau, mass])

Lognormal SFR

sfr_tau([start, tau, mass])

Exponentially declining SFR

__init__(time=<Quantity [ 0.035, 0.74368421, 1.45236842, 2.16105263, 2.86973684, 3.57842105, 4.28710526, 4.99578947, 5.70447368, 6.41315789, 7.12184211, 7.83052632, 8.53921053, 9.24789474, 9.95657895, 10.66526316, 11.37394737, 12.08263158, 12.79131579, 13.5       ] Gyr>)

Create a base SFH object

Parameters:

time (Quantity) – Look-back time array for the SFH samples

alpha_linear(start=-1.5, end=0.2, t_start=<Quantity 5. Gyr>, t_end=<Quantity 1. Gyr>)

Linear [alpha/Fe] evolution

The [alpha/Fe] evolves as a ReLU function, i.e., constant at the beginning and linearly varing afterwards.

Parameters:
  • start (Quantity (dex)) – [alpha/Fe] of the oldest stellar population (default=-1.5 dex)

  • end (Quantity (dex)) – [alpha/Fe] of the youngest stellar population (default=0.2 dex)

  • t_start (Quantity (Gyr)) – Start of the [alpha/Fe] variation (default=5 Gyr)

  • t_end (Quantity (Gyr)) – End of the [alpha/Fe] variation (default=1 Gyr)

alpha_sigmoid(start=0.4, end=0.0, tc=<Quantity 5. Gyr>, gamma=<Quantity 1. 1 / Gyr>)

Sigmoidal [alpha/Fe] evolution

The [alpha/Fe] evolves as a sigmoidal function. This is not meant to be physically meaningful but to reproduce the exponential character of the chemical evolution

Parameters:
  • start (Quantity (dex)) – [alpha/Fe] of the oldest stellar population (default=-1.5 dex)

  • end (Quantity (dex)) – [alpha/Fe] of the youngest stellar population (default=0.2 dex)

  • tc (Quantity (Gyr)) – Characteristic transition time (default=5 Gyr)

  • gamma (Quantity) – Transition slope (default=1/Gyr)

imf_linear(start=-1.5, end=0.2, t_start=<Quantity 5. Gyr>, t_end=<Quantity 1. Gyr>)

Linear IMF slope evolution

The IMF slope evolves as a ReLU function, i.e., constant at the beginning and linearly varing afterwards.

Parameters:
  • start (Quantity) – IMF of the oldest stellar population (default=-1.5)

  • end (Quantity) – IMF of the youngest stellar population (default=0.2)

  • t_start (Quantity (Gyr)) – Start of the IMF variation (default=5 Gyr)

  • t_end (Quantity (Gyr)) – End of the IMF variation (default=1 Gyr)

imf_sigmoid(start=0.5, end=3.0, tc=<Quantity 5. Gyr>, gamma=<Quantity 1. 1 / Gyr>)

Sigmoidal IMF slope evolution

The IMF slope evolves as a sigmoidal function. This is not meant to be physically meaningful but to track the chemical variations (see e.g. Martin-Navarro et al. 2015)

Parameters:
  • start (Quantity (dex)) – IMF slope of the oldest stellar population (default=0.5)

  • end (Quantity (dex)) – IMF slope of the youngest stellar population (default=3.0)

  • tc (Quantity (Gyr)) – Characteristic transition time (default=5 Gyr)

  • gamma (Quantity) – Transition slope (default=1 Gyr)

met_linear(start=-1.5, end=0.2, t_start=<Quantity 5. Gyr>, t_end=<Quantity 1. Gyr>)

Linear metallicity evolution

The metallicity evolves as a ReLU function, i.e., constant at the beginning and linearly varing afterwards.

Parameters:
  • start (Quantity (dex)) – Metallicity of the oldest stellar population (default=-1.5 dex)

  • end (Quantity (dex)) – Metallicity of the youngest stellar population (default=0.2 dex)

  • t_start (Quantity (Gyr)) – Start of the metallicity variation (default=5 Gyr)

  • t_end (Quantity (Gyr)) – End of the metallicity variation (default=5 Gyr)

met_sigmoid(start=-1.5, end=0.2, tc=<Quantity 5. Gyr>, gamma=<Quantity 1. 1 / Gyr>)

Sigmoidal metallicity evolution

The metallicity evolves as a sigmoidal function. This is not meant to be physically meaningful but to reproduce the exponential character of the chemical evolution

Parameters:
  • start (Quantity (dex)) – Metallicity of the oldest stellar population (default=-1.5 dex)

  • end (Quantity (dex)) – Metallicity of the youngest stellar population (default=0.2 dex)

  • tc (Quantity (Gyr)) – Characteristic transition time (default=5 Gyr)

  • gamma (Quantity) – Transition slope (default=1/Gyr)

sfr_custom(sfr, mass=None)

User-defined SFR

Parameters:
  • sfr (Quantity) – Star formation rate array, with the same shape as time.

  • mass (Quantity) – If given, normalize the input SFR such that it produces this mass.

sfr_delayed_tau(start=<Quantity 10. Gyr>, tau=<Quantity 1. Gyr>, mass=<Quantity 1. solMass>)

Delayed exponentially declining SFR

This is a standard tau model where the SFR is given by

\[\begin{split}\text{SFR}(t) = \begin{cases} 0 & \text{if}\; t < t_0 \\ (t_0-t)e^{- (t-t_0)/\tau } & \text{if}\; t >= t_0 \\ \end{cases}\end{split}\]
Parameters:
  • start (Quantity) – Start of the burst (default=10 Gyr)

  • tau (Quantity) – e-folding time (default=1 Gyr)

  • mass (Quantity) – Total formed mass (default=1 Msun)

sfr_double_power_law(a=5, b=5, tp=<Quantity 10. Gyr>, mass=<Quantity 1. solMass>)

Double power law SFR evolution

The SFR as a function of time is given by (Behroozi et al. 2013)

\[\text{SFR}(t_n) = ((t_n/t_p)^a + (t_n/t_p)^{-b})^{-1}\]

As for the lognormal SFR, \(t_n\) refers to time since the Big Bang

Parameters:
  • a (float) – falling slope (default=5)

  • b (float) – rising slope (default=5)

  • tp (Quantity) – similar to the SFR peak in look-back time (default=10 Gyr)

  • mass (Quantity) – Total formed mass (default=1 Msun)

sfr_lognormal(Tpeak=<Quantity 10. Gyr>, tau=<Quantity 1. Gyr>, mass=<Quantity 1. solMass>)

Lognormal SFR

The time evolution of the SFR is given by

\[\text{SFR}(t) = e^{ -(t_0- \log(t_n))^2 / 2\tau^2} / t_n\]

Note that \(t_n\) is in this case the time since the Big Bang and not lookback time as in the SSP. See details in Diemer et al. 2017, ApJ, 839, 26, Appendix A.1

Parameters:
  • Tpeak (Quantity) – Time of the SFR peak (default=10 Gyr)

  • tau (Quantity) – Characteristic time-scale (default=1 Gyr)

  • mass (Quantity) – Total formed mass (default=1 Msun)

sfr_tau(start=<Quantity 10. Gyr>, tau=<Quantity 1. Gyr>, mass=<Quantity 1. solMass>)

Exponentially declining SFR

This is a standard tau model where the SFR is given by

\[\begin{split}\text{SFR}(t) = \begin{cases} 0 & \text{if}\; t < t_0 \\ e^{- (t-t_0)/\tau } & \text{if}\; t >= t_0 \\ \end{cases}\end{split}\]
Parameters:
  • start (Quantity) – Start of the burst (default=10 Gyr)

  • tau (Quantity) – e-folding time (default=1 Gyr)

  • mass (Quantity) – Total formed mass (default=1 Msun)