Implementation of Delaunary triangulation network by point-by-point insertion method (with C++ code)

The point-by-point insertion method is a classic convex closure shrinkage algorithm. Its idea is to first find the smallest convex hull polygon containing the data area, and form a Delaunary triangle network from the outside to the inside starting from this polygon. Therefore, every time it inserts a new point, it will delete the corresponding triangle to construct a triangular network. This process is often accompanied by a large number of query calculation processes, which also leads to its inability to deal with large amounts of data. But its idea is very simple and ingenious, and it is more suitable to be implemented through programs.

#ifndef POINT2
#define POINT2

#include <math.h>

namespace DT {
   
    
    

  //因为并没有用的指针动态分配内存,所以这里使用class与struct没有什么区别
  template<typename T>
  class Point2
  {
   
    
    
  public:
  	T x;
  	T y;
  	Poin

Guess you like

Origin blog.csdn.net/a394467238/article/details/132586851