crow.cluster_modules.shear_profile module
Module to compute the cluster excess surface mass density (delta sigma).
The galaxy cluster delta sigma integral is a combination of both theoretical and phenomenological predictions. This module contains the classes and functions that produce those predictions.
- class crow.cluster_modules.shear_profile.ClusterShearProfile(cosmo: <MagicMock id = '123141829960640'>, halo_mass_function: <MagicMock name = 'mock.MassFunc' id='123141780377280'>, cluster_concentration: float | None = None, is_delta_sigma: bool = False, use_beta_s_interp: bool = False, two_halo_term: bool = False, boost_factor: bool = False)[source]
Bases:
ClusterAbundanceThe class that calculates the predicted delta sigma of galaxy clusters.
The excess density surface mass density is a function of a specific cosmology, a mass and redshift range, an area on the sky, as well as multiple kernels, where each kernel represents a different distribution involved in the final cluster shear integrand.
- property cluster_concentration
The cluster concentration parameter.
- compute_miscentering(clmm_model, radius_center, redshift, beta_s_mean, beta_s_square_mean)[source]
Compute the miscentered profile integral and return fraction.
- Parameters:
clmm_model (clmm.Modeling) -- CLMM model used to evaluate (reduced) shear or DeltaSigma.
radius_center (float) -- Radius where the profile is evaluated.
redshift (float) -- Cluster redshift.
beta_s_mean (float or None) -- Mean beta_s if using reduced shear; None if computing DeltaSigma.
beta_s_square_mean (float or None) -- Mean beta_s^2 for order2 approx; None if not used.
- Returns:
(miscentering_integral, miscentering_fraction)
- Return type:
tuple
Notes
- miscentering_integralnumpy.ndarray or float
Integral value of the miscentered profile at radius_center.
- miscentering_fractionfloat
Fraction of clusters that are miscentered (from parameters).
- compute_shear_profile(log_mass: ndarray[tuple[Any, ...], dtype[float64]], z: ndarray[tuple[Any, ...], dtype[float64]], radius_center: float64) ndarray[tuple[Any, ...], dtype[float64]][source]
Compute DeltaSigma (or reduced shear) for a list of cluster masses/redshifts.
- Parameters:
log_mass (numpy.ndarray) -- Array of log10(mass) values for clusters.
z (numpy.ndarray) -- Array of cluster redshifts (same length as log_mass).
radius_center (float) -- Radius (single value) at which the profile is evaluated [same units used by CLMM Modeling].
- Returns:
1D array of DeltaSigma (or reduced shear) values, one per input cluster.
- Return type:
numpy.ndarray
- compute_shear_profile_vectorized(log_mass: ndarray[tuple[Any, ...], dtype[float64]], z: ndarray[tuple[Any, ...], dtype[float64]], radius_center: ndarray[tuple[Any, ...], dtype[float64]]) ndarray[tuple[Any, ...], dtype[float64]][source]
Vectorized evaluation of the cluster profile when inputs are arrays.
- Parameters:
log_mass (numpy.ndarray) -- Array (or scalar) of log10(mass) values.
z (numpy.ndarray) -- Array (or scalar) of redshifts.
radius_center (numpy.ndarray) -- Radii at which to evaluate the profile (can be 1D array).
- Returns:
Array with profile values. Shape depends on input broadcasting (typically (n_clusters, n_radii) or (n_radii, n_clusters) depending on call).
- Return type:
numpy.ndarray
- set_beta_parameters(z_inf, zmax=10.0, delta_z_cut=0.1, zmin=None, z_distrib_func=None, approx='order1')[source]
Set parameters to comput mean value of the geometric lensing efficicency
\[\left<\beta_s\right> = \frac{\int_{z = z_{min}}^{z_{max}}\beta_s(z)N(z)} {\int_{z = z_{min}}^{z_{max}}N(z)}\]- Parameters:
z_inf (float) -- Redshift at infinity
zmax (float, optional) -- Maximum redshift to be set as the source of the galaxy when performing the sum. Default: 10
delta_z_cut (float, optional) -- Redshift interval to be summed with \(z_{cl}\) to return \(z_{min}\). This feature is not used if \(z_{min}\) is provided by the user. Default: 0.1
zmin (float, None, optional) -- Minimum redshift to be set as the source of the galaxy when performing the sum. Default: None
z_distrib_func (one-parameter function, optional) -- Redshift distribution function. Default is Chang et al (2013) distribution function.
approx (str, optional) --
Type of computation to be made for reduced tangential shears, options are:
'order1' : Same approach as in Weighing the Giants - III (equation 6 in Applegate et al. 2014; https://arxiv.org/abs/1208.0605). z_src_info must be 'beta':
\[g_t\approx\frac{\left<\beta_s\right>\gamma_{\infty}} {1-\left<\beta_s\right>\kappa_{\infty}}\]'order2' : Same approach as in Cluster Mass Calibration at High Redshift (equation 12 in Schrabback et al. 2017; https://arxiv.org/abs/1611.03866). z_src_info must be 'beta':
\[g_t\approx\frac{\left<\beta_s\right>\gamma_{\infty}} {1-\left<\beta_s\right>\kappa_{\infty}} \left(1+\left(\frac{\left<\beta_s^2\right>} {\left<\beta_s\right>^2}-1\right)\left<\beta_s\right>\kappa_{\infty}\right)\]
- Return type:
None
- set_beta_s_interp(z_min, z_max, n_intep=10)[source]
Build quadratic interpolators for <beta_s> and <beta_s^2> over a redshift grid.
- Parameters:
z_min (float) -- Redshift bounds for the interpolation grid.
z_max (float) -- Redshift bounds for the interpolation grid.
n_intep (int, optional) -- Number of interpolation nodes. Default 3.
- Return type:
None
- set_miscentering(miscentering_fraction: float, sigma: float = 0.12, miscentering_distribution_function: callable = None, integration_max: float = None) None[source]
Set the miscentering model parameters.
- Parameters:
miscentering_fraction (float) -- Fraction of miscentered clusters (required).
sigma (float, optional) -- Width of the miscentering distribution. Default is 0.12.
miscentering_distribution_function (callable, optional) -- Function describing the miscentering distribution (single-parameter). Default is None.
integration_max (float, optional) -- Maximum radius for integration in units of sigma. Default is 25 * sigma.
- property use_beta_s_interp
Flag to use beta_s interpolation (interpolate lens efficiency or not).