uvex_transients.models.supernovae.IIp.TypeIIPExcessSED.simulate#
- TypeIIPExcessSED.simulate(nu: Quantity, t: Quantity, size: int = 1, *, rng: RNGInput = None) Quantity#
Draw random parameter realizations and evaluate the model at the given frequency and time.
Equivalent to
self.eval(nu, t, **self.sample_parameters(size=size, rng=rng)).- Parameters:
nu (
Quantity) – Frequency at which to evaluate the model. Seeeval().size (
int) – Number of realizations to draw.rng (
numpy.random.Generator,int, orNone) – Random-number source, forwarded tosample_parameters().
- Returns:
\(L_\nu(\nu, t)\), in erg/s/Hz.
sample_parameters()always returns array-valued parameters, even forsize=1, so the batch axis is never squeezed away here.- Return type:
See also
evalThe underlying evaluation.
sample_parametersThe underlying sampling.