예제 #1
0
def halomodel_matter_power(cosmo, k, a):
    """Matter power spectrum from halo model assuming NFW density profiles
    Args:
        cosmo (:obj:`ccl.cosmology`): Cosmological parameters.
        a (float): scale factor.
        k (float or array_like): wavenumber

    Returns:
        halomodel_matter_power (float or array_like): matter power spectrum from halo model
    """
    return _vectorize_fn2(lib.halomodel_matter_power,
                          lib.halomodel_matter_power_vec, cosmo, k, a)
예제 #2
0
def twohalo_matter_power(cosmo, k, a):
    """Two-halo term for matter power spectrum assuming NFW density profiles
    Args:
        cosmo (:obj:`ccl.cosmology`): Cosmological parameters.
        a (float): scale factor.
        k (float or array_like): wavenumber

    Returns:
        two-halo matter power spectrum (float or array_Like): two-halo term for matter power spectrum
    """
    return _vectorize_fn2(lib.twohalo_matter_power,
                          lib.twohalo_matter_power_vec, cosmo, k, a)
예제 #3
0
def sigmaM(cosmo, halo_mass, a):
    """RMS variance for the given halo mass of the linear power spectrum; Msun.

    Args:
        cosmo (:obj:`ccl.cosmology`): Cosmological parameters.
        halo_mass (float or array_like): Halo masses; Msun.
        a (float): scale factor.

    Returns:
        sigmaM (float or array_like): RMS variance of halo mass.

    """
    return _vectorize_fn2(lib.sigmaM, lib.sigmaM_vec, cosmo, halo_mass, a)
예제 #4
0
파일: power.py 프로젝트: rainwoodman/CCL
def sigmaR(cosmo, R, a=1.):
    """RMS variance in a top-hat sphere of radius R in Mpc.

    Args:
        cosmo (:obj:`ccl.cosmology`): Cosmological parameters.
        R (float or array_like): Radius; Mpc.
        a (float): optional scale factor; defaults to a=1

    Returns:
        float or array_like: RMS variance in the density field in top-hat sphere; Mpc.

    """
    return _vectorize_fn2(lib.sigmaR, lib.sigmaR_vec, cosmo, R, a)
예제 #5
0
파일: power.py 프로젝트: zdu863/CCL
def linear_matter_power(cosmo, k, a):
    """The linear matter power spectrum; Mpc^3.

    Args:
        cosmo (:obj:`ccl.cosmology`): Cosmological parameters.
        k (float or array_like): Wavenumber; Mpc^-1.
        a (float): Scale factor.

    Returns:
        linear_matter_power (float or array_like): Linear matter power spectrum; Mpc^3.

    """
    return _vectorize_fn2(lib.linear_matter_power, lib.linear_matter_power_vec,
                          cosmo, k, a)
예제 #6
0
파일: power.py 프로젝트: rainwoodman/CCL
def sigmaV(cosmo, R, a=1.):
    """RMS variance in the displacement field in a top-hat sphere of radius R.
    The linear displacement field is the gradient of the linear density field.

    Args:
        cosmo (:obj:`ccl.cosmology`): Cosmological parameters.
        R (float or array_like): Radius; Mpc.
        a (float): optional scale factor; defaults to a=1

    Returns:
        sigmaV (float or array_like): RMS variance in the displacement field in top-hat sphere.

    """
    return _vectorize_fn2(lib.sigmaV, lib.sigmaV_vec, cosmo, R, a)