[Graphic algorithm] Dirichlet triangle partitioning algorithm

Source: Internet
Author: User

1. Definition of triangular segmentation and AdaBoost Segmentation
How to split a scatter set into an uneven triangle mesh is the problem of the triangle division of the scatter set. The triangle division of the scatter set is for Numerical Analysis and graphics, is an extremely important preprocessing technology. The problem is illustrated as follows:

 

1. 1. triangle partitioning definition
[Definition] triangle partitioning: Assume that V is a finite point set in a two-dimensional real number field, edge E is a closed line segment composed of points in the vertex set as the endpoint, and E is a set of E. In this case, a triangle partition t = (V, E) of V is a plan G, which meets the following conditions:
1. except the endpoint, the edges in the plan do not contain any vertices in the vertex set.
2. No intersection edge.
3. All faces in the plot are triangular surfaces, and the collection of all triangular surfaces is the convex hull of the scatter set v.
1.2.
in practice, the most commonly used triangle partitioning is a special type of triangle partitioning. Start with the Dirichlet edge:
[Definition] Dirichlet edge: assume that an edge e in E (two endpoints are a and B). If e meets the following conditions, it is called a Dirichlet edge: There is a circle passing through two points A and B, and the inside of the circle (note that it is inside the circle, the circle can be at most three points in total) does not contain any other point in the V of the point set, this feature is also called the null circle feature.
[Definition] segmentation: If a triangle T of the point set V contains only the Cartesian edge, the triangle is called a segmentation.
1.3.principle of AdaBoost triangle partitioning
to meet the definition of the Adaboost triangle, it must comply with two important principles:
1. Empty circle feature: the Cartesian network is unique (a circle is not allowed at any four points ), no point exists in the outer circle of any triangle in the gridded triangle. As shown in:

2. maximization of the smallest angle: in a triangle that may be formed by a scatter set, the smallest angle of a triangle formed by a AdaBoost triangle is the largest. In this sense, the gridded network is the "closest to the regular" network. Specifically, two adjacent triangles form the diagonal line of a convex quadrilateral. After interchange, the minimum angle of the six inner angles does not increase. As shown in:

1.4.unique features
The following table lists the outstanding features of node partitioning:
1. closest: a triangle is formed at the nearest three points, and each line segment (Triangle edge) does not intersection.
2. uniqueness: No matter where the building starts from the region, the results are consistent.
3. Optimum: If the diagonal lines of a convex quadrilateral formed by any two adjacent triangles can be exchanged, the minimum angle of the six inner angles of the two triangles will not increase.
4. Most rule: if the smallest angle of each triangle in the Triangle network is sorted in ascending order, the maximum value obtained by the arrangement of the Triangle network is obtained.
5. region: adding, deleting, and moving a vertex only affect the adjacent triangle.
6. Case with convex polygon: the outer boundary of the Triangle network forms a convex polygon shell.
1. 5. local optimization processing
theoretically, in order to construct a Cartesian network, the LOP (local optimization procedure) process proposed by Lawson is generally processed by LOP, you can make sure that the network is a result of the following:
1. combine Two triangles with common edges into a polygon.
2. Check whether the fourth vertex is within the outer circle of the triangle based on the maximum null circle criterion.
3. If the diagonal line is corrected, the diagonal line is called to be reversed, that is, the local optimization process is completed.
shows the Lop processing process.

2.Algorithm
It is a standard for triangle partitioning. There are multiple algorithms to implement it.
2.1.lawson Algorithm
The point-by-point Lawson algorithm was proposed by Lawson in 1977. It has a simple idea and is easy to program. The basic principle is: first create a large triangle or polygon, enclose all data points and insert a point into it. The point is connected to three vertices of the triangle that contains it, create three new triangles, and then perform the null Outer Circle Detection on them one by one. At the same time, optimize the Lop with the local optimization process designed by lawson, that is to say, by exchanging the diagonal lines, we can ensure that the formed Triangle network is a Cartesian network.
The above scatter-Based Network Construction Algorithm is rigorous in theory and has good uniqueness. The grid satisfies the characteristics of an empty circle and is ideal. It can be seen from its point-by-point insertion of the network construction process that, in the case of non-Dirichlet edge, the deletion adjustment can be used to construct a new Dirichlet edge. After creating a network, you do not need to reconstruct the network of all points when adding new points. Instead, you only need to connect the affected triangle ranges of the new points to the local network, and the local network method is simple and easy. Similarly, you can quickly and dynamically delete or move a vertex. However, in practical applications, this network construction algorithm is slow when the point set is large. If the Point Set range is not convex or there is an inner ring, an invalid triangle is generated.
2.2.bowyer-Watson Algorithm 
The basic steps of the Lawson algorithm are as follows:
1. Construct a super triangle that contains all the scattered points and put them into the triangle linked list.
2. Insert the scattered points in the vertex set in sequence, find the triangle with the inserted points in the outer circle of the triangle linked list (called the triangle affected by the point), and delete the public edge that affects the triangle, concatenates the insertion point with all vertices that affect the triangle to complete insertion of a vertex in the table of the triangle.
3. Optimize the newly formed triangle according to the optimization criterion. Place the formed triangle into the table list of the gridded triangle.
4. Execute the preceding steps cyclically until all scatter plots are inserted.
The following figure shows the key step 1 of this algorithm:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.