LebesgueMeasure

class probnum.quad.LebesgueMeasure(domain, dim=None, normalized=False)

Bases: probnum.quad.IntegrationMeasure

Lebesgue measure on a hyper-rectangle.

Parameters
  • dim (Optional[Integral]) – Dimension of the integration domain

  • domain (Tuple[Union[ndarray, Real], Union[ndarray, Real]]) – Tuple which contains two arrays which define the start and end points, respectively, of the rectangular integration domain.

  • normalized (Optional[bool]) – Boolean which controls whether or not the measure is normalized (i.e., integral over the domain is one).

Methods Summary

__call__(points)

Evaluate the density function of the integration measure.

sample(rng, n_sample)

Sample n_sample points from the integration measure.

Methods Documentation

__call__(points)[source]

Evaluate the density function of the integration measure.

Parameters

points (Union[float, floating, ndarray]) – shape=(n_points,) or (n_points, dim) – Input locations.

Returns

shape=(n_points,) – Density evaluated at given locations.

Return type

density_evals

sample(rng, n_sample)[source]

Sample n_sample points from the integration measure.

Parameters
  • rng (Generator) – Random number generator

  • n_sample (Integral) – Number of points to be sampled

Returns

shape=(n_sample,) or (n_sample,dim) – Sampled points

Return type

points