Syntax
BUGREPORT_delaunayTriangulation
Copyright 2020-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth
Algorithm (Workflow)
This MATLAB function demonstrates a bug in the delaunayTriangulation
function from MATLAB 2019a. The function is designed to show how the triangulation process can reference a non-existent point.
Input Parameters
- PLO: A matrix representing a list of 2D points. Each row corresponds to a point with x and y coordinates.
- CL: A matrix representing a list of edge constraints. Each row defines a constraint between two points, specified by their indices in the PLO matrix.
Algorithm Steps
- Define a set of 2D points in the
PLO
matrix.
- Define edge constraints in the
CL
matrix.
- Call the
delaunayTriangulation
function with PLO
and CL
as inputs to create a triangulation object TR
.
- Display the points, constraints, and connectivity list of the triangulation object
TR
.
- Check for a bug where the connectivity list references a non-existent point (index 7) that is not in the points list.
- Use the
finduniqueVL
function to find unique points and map the connectivity list to these points.
- Plot the original points and constraints using
VLELplots
and VLFLplot
functions.
- Recreate the triangulation with the corrected connectivity list
FL
and plot it.
Functions Used
delaunayTriangulation
: Creates a Delaunay triangulation from a set of points and constraints.
finduniqueVL
: Finds unique points and maps the connectivity list to these points.
VLELplots
: Plots points and edge constraints.
VLFLplot
: Plots the connectivity list of a triangulation.
ELofFL
: Converts a face list to an edge list.
Output
The function outputs the triangulation object TR
and displays plots of the points, constraints, and triangulation. It also prints a message indicating the bug in the connectivity list.
Algorithm explaination created using ChatGPT on 2025-08-19 08:21. (Please note: No guarantee for the correctness of this explanation)
Last html export of this page out of FM database by TL: 2025-08-09