Skip to content

Geometry (1D)¤

phydrax.domain.Interval1d ¤

A 1D closed interval geometry.

Represents the domain

\[ \Omega = [a,b]\subset\mathbb{R}, \]

with boundary \(\partial\Omega = \{a,b\}\) and outward normal \(n(a)=-1\), \(n(b)=+1\).

Sampling supports both: - sample_interior: draws points in \([a,b]\) (optionally filtered by a predicate); - sample_boundary: draws from the discrete boundary set \(\{a,b\}\).

length property ¤

Return the interval length \(b-a\).

bounds property ¤
__init__(start: ArrayLike, end: ArrayLike) ¤
sample_interior(num_points: int, *, where: collections.abc.Callable | None = None, sampler: str = 'latin_hypercube', key: Key[Array, ''] = jr.key(0)) -> Array ¤
sample_boundary(num_points: int, *, where: collections.abc.Callable | None = None, sampler: str = 'latin_hypercube', key: Key[Array, ''] = jr.key(0)) -> Array ¤