HelixDelaunay

org.appliedtopology.tda4j.HelixDelaunay
See theHelixDelaunay companion object
open class HelixDelaunay(pts: Array[Array[Double]], seed: Long = ..., requireValidTriangulation: Boolean = ...)(using factor: EpsilonFactor) extends DelaunayAlphaShapes

The Delaunay triangulation of a point cloud, built by an incremental frontier walk (https://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=10917453), filtered as an alpha complex.

The walk starts from a hull facet found by gift wrapping and, across each frontier facet, takes the point whose sphere through the facet is met first: one pass over the points per facet. Points that are exactly cospherical (grids) are tiled as a cluster. Every result is checked cheaply (each point a vertex, no facet in three top simplices, every boundary facet on the convex hull); a result that fails is re-triangulated from slightly perturbed points, with every radius recomputed from the original coordinates. The perturbation (1e-4 of the point spacing) decides how exact ties are broken, and can also flip a near-tie closer than that. The same pts and seed always give the same triangulation.

Limitation: a very small Epsilon (far below the default 1e-5) can leave an exactly degenerate input (a 3-D grid) with an invalid triangulation when the perturbed retriangulation does not converge.

Value parameters

pts

the points to triangulate

requireValidTriangulation

off by default. When on, the triangulation is also checked for cavities (a homology computation), and a result that cannot be repaired raises an exception instead of being returned as it is.

seed

seeds the perturbation used when a triangulation has to be repaired; general-position input does not depend on it.

Attributes

Companion
object
Experimental
true
Source
AlphaShapes.scala
Graph
Supertypes
class AlphaShapes
trait LevelwiseSimplexStream[Int, Double]
trait StratifiedCellStream[Simplex[Int], Double]
trait CellStream[Simplex[Int], Double]
trait IterableOnce[Simplex[Int]]
trait Filtration[Simplex[Int], Double]
trait Filterable[Double]
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

Frontier facets where the walk fell back to its slow candidate search (diagnostics and tests).

Frontier facets where the walk fell back to its slow candidate search (diagnostics and tests).

Attributes

Source
AlphaShapes.scala

Inherited methods

override def filtrationOrdering: Ordering[Simplex[Int]]

Attributes

Definition Classes
Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
override def filtrationValue: PartialFunction[Simplex[Int], Double]

Attributes

Definition Classes
Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
override def flatLayers: Option[Iterator[Layer]]

The dimensions straight from the face tables, without a Simplex per cell: each in the order the cohomology engines take it in, ascending value and, among equal values, ascending lexicographic order (the reverse of the stream's own listing of them). None when points are repeated: their extra cells are not in the tables.

The dimensions straight from the face tables, without a Simplex per cell: each in the order the cohomology engines take it in, ascending value and, among equal values, ascending lexicographic order (the reverse of the stream's own listing of them). None when points are repeated: their extra cells are not in the tables.

Attributes

Definition Classes
Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
def homologyDegreeLimit: Option[Int]

Some(k) for a complex cut off to compute homology in degrees 0..k (what VietorisRips(points, maxDimension = k) returns, holding cells up to dimension k + 1): its higher degrees are not the homology of the full complex. None (the default) for a complete complex.

Some(k) for a complex cut off to compute homology in degrees 0..k (what VietorisRips(points, maxDimension = k) returns, holding cells up to dimension k + 1): its higher degrees are not the homology of the full complex. None (the default) for a complete complex.

Attributes

Inherited from:
StratifiedCellStream
Source
SimplexStream.scala
override def iterateDimension: PartialFunction[Int, Iterator[Simplex[Int]]]

The cells of dimension d, oldest first. The domain must be contiguous from 0 (0, 1, ..., k, or empty, or all of the naturals): iterator stops at the first dimension where this is undefined.

The cells of dimension d, oldest first. The domain must be contiguous from 0 (0, 1, ..., k, or empty, or all of the naturals): iterator stops at the first dimension where this is undefined.

Attributes

Definition Classes
Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
override def iterator: Iterator[Simplex[Int]]

All the cells, dimension by dimension. Stops at the first undefined dimension (takeWhile, never filter, which would search forever past the last one).

All the cells, dimension by dimension. Stops at the first undefined dimension (takeWhile, never filter, which would search forever past the last one).

Attributes

Definition Classes
StratifiedCellStream -> IterableOnce
Inherited from:
StratifiedCellStream
Source
SimplexStream.scala
def knownSize: Int

The number of elements in this collection, if it can be cheaply computed, -1 otherwise. Cheaply usually means: Not requiring a collection traversal.

The number of elements in this collection, if it can be cheaply computed, -1 otherwise. Cheaply usually means: Not requiring a collection traversal.

Attributes

Inherited from:
IterableOnce
Source
IterableOnce.scala
def simplices(): Iterator[Simplex[Int]]

Attributes

Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
def simplicesInDimension(d: Int): Iterator[Simplex[Int]]

Attributes

Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
def smallestCircumsphere(s: Simplex[Int]): (Point, Double)

The smallest sphere through every vertex of s: its centre lies in s's own affine hull (Hypersphere.apply is for full-dimensional simplices only).

The smallest sphere through every vertex of s: its centre lies in s's own affine hull (Hypersphere.apply is for full-dimensional simplices only).

Attributes

Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
def stepper[S <: Stepper[_]](implicit shape: StepperShape[Simplex[Int], S]): S

Returns a scala.collection.Stepper for the elements of this collection.

Returns a scala.collection.Stepper for the elements of this collection.

The Stepper enables creating a Java stream to operate on the collection, see scala.jdk.StreamConverters. For collections holding primitive values, the Stepper can be used as an iterator which doesn't box the elements.

The implicit scala.collection.StepperShape parameter defines the resulting Stepper type according to the element type of this collection.

  • For collections of Int, Short, Byte or Char, an scala.collection.IntStepper is returned
  • For collections of Double or Float, a scala.collection.DoubleStepper is returned
  • For collections of Long a scala.collection.LongStepper is returned
  • For any other element type, an scala.collection.AnyStepper is returned

Note that this method is overridden in subclasses and the return type is refined to S with EfficientSplit, for example scala.collection.IndexedSeqOps.stepper. For Steppers marked with scala.collection.Stepper.EfficientSplit, the converters in scala.jdk.StreamConverters allow creating parallel streams, whereas bare Steppers can be converted only to sequential streams.

Attributes

Inherited from:
IterableOnce
Source
IterableOnce.scala

Concrete fields

val ambientDimension: Int

The dimension of the triangulation (of the points' affine span).

The dimension of the triangulation (of the points' affine span).

Attributes

Source
AlphaShapes.scala

Attributes

Source
AlphaShapes.scala
val points: Seq[Point]

The points, in the coordinates the triangulation was built in.

The points, in the coordinates the triangulation was built in.

Attributes

Source
AlphaShapes.scala

Attributes

Source
AlphaShapes.scala

Inherited fields

val largest: Double

Attributes

Inherited from:
DoubleFiltration
Source
SimplexStream.scala
lazy val simplicesMap: Map[Int, Seq[Simplex[Int]]]

Attributes

Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
lazy val simplicesSortedMap: Map[Int, Seq[Simplex[Int]]]

Attributes

Inherited from:
DelaunayAlphaShapes
Source
AlphaShapes.scala
val smallest: Double

Attributes

Inherited from:
DoubleFiltration
Source
SimplexStream.scala