public static final class Matrices.Simplex extends Matrices.ConvexHyperpolyhedron
Simplex: the simplest n-dimensional hyperpolyhedron with
Simplex is a particular case of the
Simplex is specified by its vertices and can be created by the following methods:
Matrices.Region.getTriangle2D(double x1, double y1, double x2, double y2, double x3, double y3),
Matrices.Region.getTetrahedron3D(double x1, double y1, double z1, double x2, double y2, double z2, double x3, double y3, double z3, double x4, double y4, double z4).
Note: degenerated simplexes, when all vertices lie in the same (n−1)-dimensional hyperplane,
are not allowed. (In
DegeneratedSimplexException is thrown in these cases.
All calculations while building and processing simplex are performed in strictfp mode, so the results are absolutely identical on all platforms.
This class is immutable and thread-safe: there are no ways to modify settings of the created instance.
|Modifier and Type||Method and Description|
Returns true if and only if the specified vertices lies in the same (n−1)-dimensional hyperplane, as far as it can be detected by analysing the coordinates via calculations with standard Java double numbers.
Returns a brief string description of this object.
Returns the coordinates of all vertices of the simplex.
a, b, contains, sectionAtLastCoordinate
checkSectionAtLastCoordinate, coordRange, coordRanges, getConvexHyperpolyhedron, getHyperparallelepiped, getParallelepiped3D, getPolygon2D, getRectangle2D, getSegment, getSimplex, getTetrahedron3D, getTriangle2D, isContainsSupported, isRectangular, n
public static boolean isSimplexDegenerated(double vertices)
vertices- coordinates of all vertices.
java.lang.NullPointerException- if the vertices array or some of its elements is null.
java.lang.IllegalArgumentException- if the vertices array or some of its elements is empty (has zero length), or if the length of some vertices[k] array is not equal to vertices.length+1.
public double vertices()
The returned array is a deep clone of the internal data stored in this object: no references, maintained by this object, are returned.