firecrown.models.cluster.integrator.numcosmo_integrator

The NumCosmo integrator module.

This module holds the NumCosmo implementation of the integrator classes

Classes

NumCosmoIntegralMethod

The available NumCosmo integration methods.

NumCosmoIntegrator

The NumCosmo implementation of the Integrator base class.

CountsIntegralND

Integral subclass used to compute the integrals using NumCosmo.

Module Contents

class firecrown.models.cluster.integrator.numcosmo_integrator.NumCosmoIntegralMethod(*args, **kwds)[source]

Bases: enum.Enum

Inheritance diagram of firecrown.models.cluster.integrator.numcosmo_integrator.NumCosmoIntegralMethod

The available NumCosmo integration methods.

P = 0
P_V = 0
H = 0
H_V = 0
class firecrown.models.cluster.integrator.numcosmo_integrator.NumCosmoIntegrator(method=None, relative_tolerance=0.0001, absolute_tolerance=1e-12)[source]

Bases: firecrown.models.cluster.integrator.integrator.Integrator

Inheritance diagram of firecrown.models.cluster.integrator.numcosmo_integrator.NumCosmoIntegrator

The NumCosmo implementation of the Integrator base class.

Parameters:
method
integrate(func_to_integrate)[source]

Integrate the provided integrand argument with NumCosmo.

Parameters:

func_to_integrate (Callable[[numpy.typing.NDArray[numpy.float64], numpy.typing.NDArray[numpy.float64]], numpy.typing.NDArray[numpy.float64]])

Return type:

float

class firecrown.models.cluster.integrator.numcosmo_integrator.CountsIntegralND(dim, fun, args)[source]

Bases: numcosmo_py.Ncm.IntegralND

Inheritance diagram of firecrown.models.cluster.integrator.numcosmo_integrator.CountsIntegralND

Integral subclass used to compute the integrals using NumCosmo.

Parameters:
  • dim (int)

  • fun (Callable[[numpy.typing.NDArray[numpy.float64], numpy.typing.NDArray[numpy.float64]], numpy.typing.NDArray[numpy.float64]])

  • args (numpy.typing.NDArray[numpy.float64])

dim
fun
extra_args
do_get_dimensions()[source]

Returns the dimensionality of the integral.

Return type:

tuple[int, int]

do_integrand(x, dim, npoints, _fdim, fval)[source]

Called by NumCosmo to evaluate the integrand.

Parameters:
  • x (numcosmo_py.Ncm.Vector)

  • dim (int)

  • npoints (int)

  • _fdim (int)

  • fval (numcosmo_py.Ncm.Vector)

Return type:

None