tjpcov.covariance_fourier_ssc
=============================

.. py:module:: tjpcov.covariance_fourier_ssc


Classes
-------

.. autoapisummary::

   tjpcov.covariance_fourier_ssc.FourierSSCHaloModel


Module Contents
---------------

.. py:class:: FourierSSCHaloModel(config)

   Bases: :py:obj:`tjpcov.covariance_builder.CovarianceFourier`


   Class to compute the CellxCell Halo Model Super Sample Covariance.

   The SSC is computed in CCL with the "linear bias" approximation using
   :func:`pyccl.halos.halo_model.halomod_Tk3D_SSC_linear_bias`.

   Initialize the class with a config file or dictionary.

   :param config: If dict, it returns the configuration
                  dictionary directly. If string, it asumes a YAML file and
                  parses it.
   :type config: dict or str


   .. py:attribute:: cov_type
      :value: 'SSC'



   .. py:attribute:: ssc_conf


   .. py:method:: _get_sigma2_B(cosmo, a_arr, tr=None)

      Returns the variance of the projected linear density field,
          for the case when a survey mask is provided.

      :param cosmo: a Cosmology object.
      :type cosmo: :class:`~pyccl.cosmology.Cosmology`
      :param a_arr: an array of
                    scale factor values at which to evaluate
                    the projected variance.
      :type a_arr: :obj:`float`, `array` or :obj:`None`
      :param tr: dictionary containing the
                 tracer name combinations.
      :type tr: :obj:`dict`

      :returns: projected variance.
      :rtype: - (:obj:`float` or `array`)



   .. py:method:: get_covariance_block(tracer_comb1, tracer_comb2, integration_method=None, include_b_modes=True)

      Compute a single SSC covariance matrix for a given pair of C_ell.

      If outdir is set, it will save the covariance to a file called
      ssc_tr1_tr2_tr3_tr4.npz. This file will be read and its output returned
      if found.

      Blocks of the B-modes are assumed 0 so far.

      :param tracer_comb1: List of the pair of tracer names of C_ell^1
      :type tracer_comb1: list
      :param tracer_comb2: List of the pair of tracer names of C_ell^2
      :type tracer_comb2: list
      :param integration_method: integration method to be
                                 used for the Limber integrals. Possibilities: 'qag_quad' (GSL's
                                 qag method backed up by quad when it fails) and 'spline'
                                 (the integrand is splined and then integrated analytically). If
                                 given, it will take priority over the specified in the
                                 configuration file through config['SSC']['integration_method'].
                                 Elsewise, it will use 'qag_quad'.
      :type integration_method: str, optional
      :param include_b_modes: If True, return the full SSC with
                              zeros in for B-modes (if any). If False, return the non-zero
                              block. This option cannot be modified through the configuration
                              file to avoid breaking the compatibility with the NaMaster
                              covariance. Defaults to True.
      :type include_b_modes: bool, optional

      :returns: Super sample covariance matrix for a pair of C_ell.
      :rtype: array



