schechter_lf_redshift¶
-
skypy.galaxy.redshift.schechter_lf_redshift(redshift, M_star, phi_star, alpha, m_lim, fsky, cosmology, noise=True)[source] [edit on github]¶ Sample redshifts from Schechter luminosity function.
Sample the redshifts of galaxies following a Schechter luminosity function with potentially redshift-dependent parameters, limited by an apparent magnitude
m_lim, for a fractionfskyof the sky.- Parameters
- redshiftarray_like
Input redshift grid on which the Schechter function parameters are evaluated. Galaxies are sampled over this redshift range.
- M_stararray_like or function
Characteristic absolute magnitude of the Schechter function. Can be a single value, an array of values for each
redshift, or a function of redshift.- phi_stararray_like or function
Normalisation of the Schechter function. Can be a single value, an array of values for each
redshift, or a function of redshift.- alphaarray_like or function
Schechter function power law index. Can be a single value, an array of values for each
redshift, or a function of redshift.- m_limfloat
Limiting apparent magnitude.
- fskyarray_like
Sky fraction over which galaxies are sampled.
- cosmologyCosmology, optional
Cosmology object to convert apparent to absolute magnitudes. If not given, the default cosmology is used.
- noisebool, optional
Poisson-sample the number of galaxies. Default is
True.
- Returns
- redshiftsarray_like
Redshifts of the galaxy sample described by the Schechter luminosity function.
Examples
Compute the number density of galaxies with redshifts between 0 and 5 for typical values of the “blue” galaxy luminosity function above an apparent magnitude cut of 22 for a survey of 1 square degree = 1/41253 of the sky.
>>> from skypy.galaxy.redshift import schechter_lf_redshift >>> z = [0., 5.] >>> M_star = -20.5 >>> phi_star = 3.5e-3 >>> alpha = -1.3 >>> z_gal = schechter_lf_redshift(z, M_star, phi_star, alpha, 22, 1/41253)