circumcenters

Legacy form of circumcenter for TriRep and DelaunayTri objects.

Category: Mathematics > Computational Geometry

Syntax

C = circumcenters(TR)

Circumcenters of all simplices.

C = circumcenters(TR, T)

Only for the simplices in T.

[C, r] = circumcenters(___)

Also returns the circumradii.

Description

circumcenters is the plural, older name of circumcenter used by the TriRep and DelaunayTri classes. It returns the point equidistant from the vertices of each triangle or tetrahedron, plus the radius of the circle or sphere through them.

New code should use delaunayTriangulation with circumcenter.

Input arguments

TR
A DelaunayTri or TriRep object.
T
Optional simplex indices.

Output arguments

C
Circumcenter coordinates, one row per simplex.
r
Circumradii.

Example

Circumcenters with DelaunayTri

x = [0 1 1 0 0.5]';
y = [0 0 1 1 0.5]';
DL = DelaunayTri(x, y);
C = circumcenters(DL)
Output
C = 4×2

    1.0000    0.5000
    0.5000         0
         0    0.5000
    0.5000    1.0000

See also

circumcenter incenters DelaunayTri