# Prediction Research on Irregularly Cavited Components Volume Based on Gray Correlation and PSO-SVM
## 3 Gray Correlation Analysis  
A gray relationship refers to the uncertain relationships between things or the system factors or the factors and the main behavior. Gray-correlation analysis [18; 19] judges whether the relationship between data sequences is close by the similarity of the geometric shapes of the data curves; a modified algorithm finds out the main factors that affect the target value through correlation calculation, and evaluates the influence of various factors. There are some deficiencies in the samples of traditional mathematical-statistics methods, such as large demand and large computational-volume, and there may be inconsistencies between quantitative results and qualitative analysis. This analysis method overcomes these deficiencies and becomes a simple and unique system-analysis method [20]. When the micro-compression air method is used to detect the volume of irregularly cavited components, the volume-prediction model of irregularly cavitied components is affected by various factors such as atmospheric pressure, pressure before and after air micro-compression, temperature, and equilibrium time. In addition, the relationship between most of the influencing factors and the volume of the irregular-cavity parts is nonlinear, so the effect of these influencing factors on the volume of the irregular-cavity parts is not clear, which is gray. The gray-correlation analysis can quantitatively reflect the degree of correlation between the volume of irregular cavity parts and various influencing factors. Through comparative analysis, the main factors with higher correlation were selected from the factors that affect the volume of irregularly-cavitied components. As input variables for SVM modeling, SVM was then used for prediction. Here are the specific steps of gray relational analysis:  
Step 1. determine the referential data sequence as  
\[x^{\prime}_{0}(k)=\left\{x^{\prime}_{0}(1),x^{\prime}_{0}(2),\cdots,x^{\prime} _{0}(n)\right\} \tag{2}\]  
Step 2. determine the comparative data series as  
\[x^{\prime}_{i}(k)=\left\{x^{\prime}_{1}(1),x^{\prime}_{i}(2),\cdots,x^{\prime} _{i}(n)\right\} \tag{3}\]  
Figure 1: Schematic diagram of the volume-measurement method using micro-compressed air. Step 3. the data is processed in a dimensionless manner. Since the parameters of different properties (such as pressure, temperature, humidity, equilibration-time, etc.) are measured at each test point during the volume test, and these parameters have different orders of magnitude, to make sure the correlation analysis result between parameters of each detection point and the volume is reliable, the original sequence needs to be processed in a dimensionless manner. Therefore, \(x_{0}^{\prime}(k)\) and \(x_{i}^{\prime}(k)\) sequences are processed in a dimensionless manner, and the reference sequence \(x_{0}(k)\) and the comparative data \(x_{i}(k)\) are obtained, as in Equations (4) and (5). \[x_{0}(k)=\frac{x_{0}^{\prime}(k)}{x_{0}^{\prime}(1)}=\{x_{0}(1),x_{0}(2), \cdots,x_{0}(n)\} \tag{4}\]  
\[x_{i}(k)=\frac{x_{i}^{\prime}(k)}{x_{i}^{\prime}(1)}=\{x_{i}(1),x_{i}(2), \cdots,x_{i}(n)\} \tag{5}\]  
Step 4. find the absolute-difference sequence. The absolute value of the difference between the reference sequence \(x_{0}(k)\) and the comparative data \(x_{i}(k)\) constitutes an absolute-difference sequence, as in Equation (6). \[\Delta_{0i}(k) =|x_{0}(k)-x_{i}(k)|\] \[=\{\Delta_{i}(1),\Delta_{i}(2),\cdots\Delta_{i}(n)\} \tag{6}\]  
Step 5. find the maximum difference and the minimum difference in the absolute-difference sequence, as in Equations (7) and (8). \[\Delta_{\max}=\max\left| \begin{array}{c}\Delta_{oi}(k)\\ 1\leq i\leq m\\ 1\leq k\leq n\end{array} \right| \tag{7}\]  
\[\Delta_{\min}=\min\left| \begin{array}{c}\Delta_{oi}(k)\\ 1\leq i\leq m\\ 1\leq k\leq n\end{array}