NcmPowspecFilter

NcmPowspecFilter — Class to compute filtered power spectrum

Properties

gdouble lnr0 Read / Write / Construct
NcmPowspec * powerspectrum Read / Write / Construct Only
gdouble reltol Read / Write / Construct
NcmPowspecFilterType type Read / Write
gdouble zf Read / Write
gdouble zi Read / Write

Object Hierarchy

    GEnum
    ╰── NcmPowspecFilterType
    GObject
    ╰── NcmPowspecFilter

Description

This class computes the filtered power spectrum, $\sigma^2(k, r)$, and its derivatives with respect to $\ln r$ (ncm_powspec_filter_eval_dnvar_dlnrn()) using the FFTLog approach (see NcmFftlog), \begin{equation}\lable{eq:variance} \sigma^2(r, z) = \frac{1}{2\pi^2} \int_0^\infty k^2 \ P(k, z) \vert W(k,r) \vert^2 \ \mathrm{d}k, \end{equation} where $P(k, z)$ is the power spectrum at mode $k$ and redshift $z$ and $W(k, r)$ is the filter (or window function).

Functions

ncm_powspec_filter_new ()

NcmPowspecFilter *
ncm_powspec_filter_new (NcmPowspec *ps,
                        NcmPowspecFilterType type);

Creates a new NcmPowspecFilter from the power spectrum ps .

Parameters

ps

a NcmPowspec

 

type

a type from NcmPowspecFilterType

 

Returns

the newly created NcmPowspecFilter.

[transfer full]


ncm_powspec_filter_ref ()

NcmPowspecFilter *
ncm_powspec_filter_ref (NcmPowspecFilter *psf);

Increases the reference count of psf by one.

Parameters

psf

a NcmPowspecFilter

 

Returns

psf .

[transfer full]


ncm_powspec_filter_free ()

void
ncm_powspec_filter_free (NcmPowspecFilter *psf);

Decreases the reference count of psf by one.

Parameters

psf

a NcmPowspecFilter

 

ncm_powspec_filter_clear ()

void
ncm_powspec_filter_clear (NcmPowspecFilter **psf);

If psf is different from NULL, decreases the reference count of psf by one and sets fftlog to NULL.

Parameters

psf

a NcmPowspecFilter

 

ncm_powspec_filter_prepare ()

void
ncm_powspec_filter_prepare (NcmPowspecFilter *psf,
                            NcmModel *model);

Prepares the object applying the filter to the power spectrum.

Parameters

psf

a NcmPowspecFilter

 

model

a NcmModel

 

ncm_powspec_filter_prepare_if_needed ()

void
ncm_powspec_filter_prepare_if_needed (NcmPowspecFilter *psf,
                                      NcmModel *model);

Prepares (if necessary) the object applying the filter to the power spectrum.

Parameters

psf

a NcmPowspecFilter

 

model

a NcmModel

 

ncm_powspec_filter_set_type ()

void
ncm_powspec_filter_set_type (NcmPowspecFilter *psf,
                             NcmPowspecFilterType type);

Sets the type of the NcmPowspecFilter to be used.

Parameters

psf

a NcmPowspecFilter

 

type

a type from NcmPowspecFilterType

 

ncm_powspec_filter_set_lnr0 ()

void
ncm_powspec_filter_set_lnr0 (NcmPowspecFilter *psf,
                             gdouble lnr0);

FIXME

Parameters

psf

a NcmPowspecFilter

 

lnr0

the output center value $\ln(r_0)$

 

ncm_powspec_filter_set_best_lnr0 ()

void
ncm_powspec_filter_set_best_lnr0 (NcmPowspecFilter *psf);

FIXME

Parameters

psf

a NcmPowspecFilter

 

ncm_powspec_filter_set_zi ()

void
ncm_powspec_filter_set_zi (NcmPowspecFilter *psf,
                           gdouble zi);

FIXME

Parameters

psf

a NcmPowspecFilter

 

zi

the output initial time $z_i$

 

ncm_powspec_filter_set_zf ()

void
ncm_powspec_filter_set_zf (NcmPowspecFilter *psf,
                           gdouble zf);

FIXME

Parameters

psf

a NcmPowspecFilter

 

zf

the output final time $z_f$

 

ncm_powspec_filter_get_r_min ()

gdouble
ncm_powspec_filter_get_r_min (NcmPowspecFilter *psf);

FIXME

Parameters

psf

a NcmPowspecFilter

 

Returns

FIXME


ncm_powspec_filter_get_r_max ()

gdouble
ncm_powspec_filter_get_r_max (NcmPowspecFilter *psf);

FIXME

Parameters

psf

a NcmPowspecFilter

 

Returns

FIXME


ncm_powspec_filter_eval_lnvar_lnr ()

gdouble
ncm_powspec_filter_eval_lnvar_lnr (NcmPowspecFilter *psf,
                                   const gdouble z,
                                   const gdouble lnr);

Evaluates the logarithm base e of the filtered power spectrum at lnr and z .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

Returns

FIXME


ncm_powspec_filter_eval_var ()

gdouble
ncm_powspec_filter_eval_var (NcmPowspecFilter *psf,
                             const gdouble z,
                             const gdouble r);

Evaluate the filtered variance at r .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

r

FIXME

 

Returns

FIXME


ncm_powspec_filter_eval_var_lnr ()

gdouble
ncm_powspec_filter_eval_var_lnr (NcmPowspecFilter *psf,
                                 const gdouble z,
                                 const gdouble lnr);

Evaluates the filtered power spectrum at lnr and z .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

Returns

FIXME


ncm_powspec_filter_eval_sigma_lnr ()

gdouble
ncm_powspec_filter_eval_sigma_lnr (NcmPowspecFilter *psf,
                                   const gdouble z,
                                   const gdouble lnr);

Evaluate the suare root of the filtered power spectrum at lnr and z .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

Returns

FIXME


ncm_powspec_filter_eval_sigma ()

gdouble
ncm_powspec_filter_eval_sigma (NcmPowspecFilter *psf,
                               const gdouble z,
                               const gdouble r);

Evaluates the filtered variance at r .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

r

FIXME

 

Returns

FIXME


ncm_powspec_filter_eval_dvar_dlnr ()

gdouble
ncm_powspec_filter_eval_dvar_dlnr (NcmPowspecFilter *psf,
                                   const gdouble z,
                                   const gdouble lnr);

Evaluates the filtered variance at lnr .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

Returns

FIXME


ncm_powspec_filter_eval_dlnvar_dlnr ()

gdouble
ncm_powspec_filter_eval_dlnvar_dlnr (NcmPowspecFilter *psf,
                                     const gdouble z,
                                     const gdouble lnr);

Evaluate the filtered variance at lnr .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

Returns

FIXME


ncm_powspec_filter_eval_dlnvar_dr ()

gdouble
ncm_powspec_filter_eval_dlnvar_dr (NcmPowspecFilter *psf,
                                   const gdouble z,
                                   const gdouble lnr);

Evaluates the filtered variance at lnr .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

Returns

FIXME


ncm_powspec_filter_eval_dnvar_dlnrn ()

gdouble
ncm_powspec_filter_eval_dnvar_dlnrn (NcmPowspecFilter *psf,
                                     const gdouble z,
                                     const gdouble lnr,
                                     guint n);

Evaluates the derivative of the filtered variance at lnr and z , namely:

  • n = 0: $\sigma(r, z)^2$,

  • n = 1: $\frac{d\sigma^2}{d\ln r}$,

  • n = 2: $\frac{d^2\sigma^2}{d(\ln r)^2}$,

  • n = 3: $\frac{d^3\sigma^2}{d(\ln r)^3}$.

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

n

number of derivatives

 

Returns

FIXME


ncm_powspec_filter_eval_dnlnvar_dlnrn ()

gdouble
ncm_powspec_filter_eval_dnlnvar_dlnrn (NcmPowspecFilter *psf,
                                       const gdouble z,
                                       const gdouble lnr,
                                       guint n);

Evaluates the filtered variance at lnr .

Parameters

psf

a NcmPowspecFilter

 

z

redshift

 

lnr

logarithm base e of $r$

 

n

number of derivatives

 

Returns

FIXME


ncm_powspec_filter_volume_rm3 ()

gdouble
ncm_powspec_filter_volume_rm3 (NcmPowspecFilter *psf);

Calculates the volume of the filter over $r^3$.

Parameters

psf

a NcmPowspecFilter

 

Returns

Filter's volume over the radius squared $V r^{-3}$.

Types and Values

enum NcmPowspecFilterType

Filter type to apply to the power spectrum. See also NcmFftlogTophatwin2 and NcmFftlogGausswin2, for the top-hat and Gaussian filters, respectively.

Members

NCM_POWSPEC_FILTER_TYPE_TOPHAT

Apply the top-hat filter

 

NCM_POWSPEC_FILTER_TYPE_GAUSS

Apply the Gaussian filter

 

NCM_POWSPEC_FILTER_DEFAULT_SIZE

#define NCM_POWSPEC_FILTER_DEFAULT_SIZE (200)

Property Details

The “lnr0” property

  “lnr0”                     gdouble

Output center value.

Flags: Read / Write / Construct

Default value: 0


The “powerspectrum” property

  “powerspectrum”            NcmPowspec *

NcmPowspec object.

Flags: Read / Write / Construct Only


The “reltol” property

  “reltol”                   gdouble

Relative tolerance for calibration.

Flags: Read / Write / Construct

Allowed values: [2.22045e-16,1]

Default value: 0.001


The “type” property

  “type”                     NcmPowspecFilterType

Filter type.

Flags: Read / Write

Default value: NCM_POWSPEC_FILTER_TYPE_TOPHAT


The “zf” property

  “zf”                       gdouble

Output final time.

Flags: Read / Write

Default value: 1


The “zi” property

  “zi”                       gdouble

Output initial time.

Flags: Read / Write

Default value: 0