uvex_transients.phase_space.space.Space.sobol#

Space.sobol(n: int, seed: int | SeedSequence | None = None) → NDArray[float64][source]#

Draw a scrambled Sobol design over the unit cube.

A Sobol sequence is balanced in blocks of a power of two, so this draws the next power of two points and keeps the first n.

Parameters:
  • n (int) – The number of points, at least 1.

  • seed (int or numpy.random.SeedSequence, optional) – Seed of the scrambling. The same seed gives the same design, and a ~numpy.random.SeedSequence is not advanced by being used, so it can be passed again.

Returns:

Points in the unit cube, shape (n, ndim). Use from_unit() for points in the coordinates of the axes.

Return type:

numpy.ndarray

Raises:

ValueError – If n is not a positive integer.