# NewApproach to Predict the Motion Characteristics of Single Bubbles in Still Water
## 3 Results
### Prediction Model for the Shape of Single Bubbles  
The number of datasets for learning and testing purposes is 710 and 304, respectively. A platform was built under a Python environment to predict the shape of single bubbles. Three algorithms were applied to perform the task which are KNN, random forest, and logistic regression. The input variables are Re number, Eo number, and We number, while the bubble shapes are labelled with number 1, 2, and 3 to represent the bubbles with elliptical shape, spherical-cap shape, and irregular shape, respectively [37]. Table 2 shows the distribution of the confusion matrix corresponding to the KNN model. Most of the predicted outputs fall accurately and precisely into their own category. In terms of recall rate, the true positive rate (TPR) and true negative rate (TNR) are the two important indicators. TPR value is 76.92% for the elliptical-shaped bubbles, 76.16% for spherical-cap shaped bubbles, and 86.11% for irregular-shaped bubbles. Meanwhile, the TNR value for the bubbles with elliptical shape, spherical-cap shape, and irregular shape is 85%, 76.10%, and 99.25%, respectively. Both the TPR and TNR values for each category are above 75%, indicating that the classifiers of the model perform well. In addition, the Kappa coefficient of the model is 87.55%, showing that the model has a considerably high degree of consistency. On the other hand, the distribution of confusion matrix for the logistic regression algorithm prediction model is presented in Table 3. Similar to the KNN algorithm prediction model, most of the predicted label falls into its own category accurately. From the point of view of recall rate, the elliptical-shaped bubbles have a TPR of 84.62%, spherical-cap shaped bubbles have a TPR of 87.41%, while irregular-shaped bubbles have a TPR of 94.44%. Meanwhile, for TNR value, it is 90.90% for the bubbles with elliptical shape, 87.5% for the bubbles with spherical-cap shape, and 99.25% for \begin{table}
\begin{tabular}{c c c c c c} \hline \hline  & \multicolumn{4}{c}{**Predicted label**} \\ \hline \multirow{3}{*}{**Actual label**} & **Label** & **1** & 2 & 3 & Total sample \\ \cline{2-6}  & 1 & 90 & 27 & 0 & 117 \\ \cline{2-6}  & 2 & 36 & 115 & 2 & 151 \\ \cline{2-6}  & 3 & 0 & 5 & 31 & 36 \\ \hline \hline \end{tabular}
\begin{tabular}{c c c c c} \hline \hline  & Total & 126 & 147 & 33 & 304 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Confusion matrix of the K-nearest neighbours (KNN)algorithm prediction model. Figure 13: Comparison of the predicted values from the developed model and empirical formulas from previous researchers with the actual experimental C\({}_{\text{D}}\) values. the bubbles with an irregular shape. The TPR and TNR values for all the categories are higher than 80%, indicating that each classifier of the model exhibits good performance. Moreover, the Kappa coefficient of the model is calculated and recorded at 78.28%. As suggested by [PERSON] [38], such a Kappa coefficient show a substantial agreement between the predicted and actual condition as it falls within the range of 61% to 80%. The distribution of confusion matrix for the random forest algorithm prediction model is contained in Table 4. The classification through the random forest algorithm displays that most of the predicted data located correctly and accurately in its own category. From the perspective of TPR, it is 87.18%, 86.09%, 83.33%, corresponding to bubbles with elliptical shape, spherical-cap shape, and irregular shape, respectively. Meanwhile, for TNR value, it shows 88.77% for the elliptical-shaped bubbles, 86.27% for spherical-cap shaped bubbles, and 98.16% for the irregular-shaped bubbles. Such high values of TPR and TNR represent that each of the classifiers of the model performs well. For the Kappa coefficient, the calculated value is 76.41%, which indicates that the classification accuracy of the model is substantially high [38].