## 2 Materials and Methods  
### The Principle of the Method  
The principle of the proposed method is quite simple. The point cloud representing the object's surface contains a finite number of discrete points. The surface of flatter parts can be captured using much fewer points than curved or rugged surfaces. If we can, therefore, determine the \"flatness\" of the surroundings of the point, we can determine how much we can dilute the cloud in its vicinity without compromising the quality of the object description. The proposed method performs this in the unordered original point cloud using already known simple manipulations. Unlike the commonly used uniform dilution using only one parameter determining the distance between individual points in the diluted cloud (a), the proposed method adds an additional parameter (b), which defines the maximum distance between points, i.e., the distance that shall be used on the flattest surfaces. The method sequence is as follows (also shown on Figure 1):  
1. Calculation of an evaluation variable \(E_{3}\). 2. Transformation of the \(E_{3}\) variable into the \(T\) variable. 3. Correction of the range of the \(T\) variable by winsdorizing. 4. Dilution of the cloud based on a linearly changing distance between individual points based on the relative value of \(T\). The \(E_{3}\) variable is calculated separately for each point within the cloud. \(E_{3}\) calculated for a point is defined as the variance of the distances of surrounding points (within a sphere with radius \(R\)) from the plane interspersed through them; it can be acquired, for example, as the third eigenvalue of the matrix according to Equation (1). \[ \begin{array}{c}A=\begin{pmatrix}x_{1R}&y_{1R}&z_{1R}\\ \vdots&\vdots&\vdots\\ x_{nR}&y_{nR}&z_{nR}\end{pmatrix},\ U\Sigma V=svd\left(\frac{A^{T}A}{n} \right),\ diag(\Sigma)=\begin{pmatrix}E_{1}^{2}\\ E_{3}^{2}\end{pmatrix},\\ x_{iR}=x_{i}-x_{m},\ y_{iR}=y_{i}-y_{m},\ z_{iR}=z_{i}-z_{m},\\ x_{m}=\frac{\sum_{i}^{m}x_{i}}{n}\,\ y_{m}=\frac{\sum_{i}^{m}y_{i}}{n}\,\ z_{m}= \frac{\sum_{i}^{m}z_{i}}{n}.\end{array}  \tag{1}\]  
The calculation of the eigenvalues of vectors/matrices is generally well-known; here, we present a procedure using a singular decomposition (function _svd ()_) used in Equation (1). In that equation, \(A\) is a matrix of coordinates of points \(x_{iR}\), \(y_{iR}\), \(z_{iR}\) (i.e., the coordinates of each point within the spherical surroundings of the evaluated point with radius R, relative to the mean coordinates of all points within the sphere \(x_{m}\), \(y_{m}\), \(z_{m}\)). Subsequently, the \(E_{3}\) variable is transformed into the \(T\) variable. \(E_{3}\), as a characteristic of variance, greatly changes with even small changes in flatness; for this reason, we have proposed a transformation into the \(T\) variable (Equation (2)), which allows more linear changes in dilution. \[T=\frac{1}{\sqrt{E_{3}}} \tag{2}\]  
Moreover, in every cloud, there are extreme points excessively broadening the range of the \(T\) variable. A typical histogram, then, looks like that shown in Figure 2a--a vast majority of points fall within a relatively small range and only a small minority is outside this range. Values of \(T\) for individual points can be as high as \(T\) = 35,000 but there are so few such points that they are even not visible on the histogram. For this reason, winsdorizing is performed--the 99.9 th percentile of data is arbitrarily found and this number is assigned to all points with \(T\) values above this percentile, see Figure 2b. This includes points on  
Figure 1: The flowchart of the proposed progressive dilution algorithm. extremely smooth and planar surfaces, for which \(T\) was undefined (\(E_{3}\) for these points is 0 and \(T\) would, therefore, be \(+\infty\); in CloudCompare, such points would be marked NaN). The same is done for the 0.1 th percentile and points lower than 0.1.