# Virtual Sensor for Estimating the Strain-Hardening Rate of
## 2 Materials and Methods
### Methods
#### 2.2.2 Leave-One-Out Cross-Validation  
Due to the relatively small size of the MLR database used to establish correlations between the hardening rate and chemical composition across the entire ASS family, it is necessary to apply a method to validate the new parameter _HRHS_. For this purpose, the Leave-One-Out Cross-Validation (LOOCV) method has been identified as extensively used [37; 38; 39; 40; 41]. Building on the research by [42], which was validated by LOOCV, this study uses process parameter maps for AISI 316L-Cu parts produced by selective laser melting to predict suitable parameters for different compositions, revealing nonlinear dependencies and highlighting process-property relationships. In [43], a dataset of 116 data points was analysed using the RFECV-LOO method to identify key parameters for ML models. Various ML models were evaluated using metrics like root mean squared error (_RMSE_), mean squared error (_MSE_), and correlation coefficient (_R_). Support vector regression (SVR) showed the highest accuracy, while lasso regression was the least effective. The models' performance was validated through sensitivity and parametric analyses.  
Given the database \(\{(x_{i},y_{i})\}_{i=1}^{n}\), where \(x_{i}\) are the inputs features and \(y_{i}\) are the corresponding labels, from each \(i\) from \(1\) to \(n\). Remove the _i-th_ data point, resulting in the training set \(\big{\{}\big{(}x_{j},y_{j}\big{)}:j\
eq i\big{\}}\). Train the model on this reduced training set to obtain the model eliminating the _i-_th data point \(\hat{f}^{-i}\) and use this trained model to predict the value for the left-out observation \(x_{i}\), yielding the prediction \(\hat{y}_{i}=\hat{f}^{-i}(x_{i})\). Equations (4) and (5) provide the mathematical foundation of the process. Equation (4) calculates the prediction error for each left-out observation.  
\[e_{i}=y_{i}-\hat{y}_{i} \tag{4}\]  
Equation (5) shows the _MSE_:  
\[MSE_{\text{LOO}}=\frac{1}{n}{\sum_{i=1}^{n}}(y_{i}-\hat{y}_{i})^{2} \tag{5}\]  
LOOCV involves training and testing models in all the possible ways of dividing the original sample into training and validation sets. In this study, the validation set consists of one observation, and the training set comprises 18 out of the 19 cases from the MLR database. With each pass, the observation data are rotated, resulting in a total of 19 models trained and tested using the LOOCV method, as described in Table 3.  
\begin{table}
\begin{tabular}{c c c c} \hline \hline
**Model** & **Variables** & **Symbol** & **Description (Units)** \\ \hline \multirow{2}{*}{\(\bigtriangleup\)} & Input & red & Cold thickness reduction (\%) \\  & Output & Rm & Tensile Strength (MPa) \\ \hline \multirow{4}{*}{\(\bigtriangleup\)} & Input & Ni, Cr, Cu, Mn, Mo, Si, C, & Concentration of each alloying element (\%) \\  & & N, S, Ti, and Nb & Theoretical hardening rate of a hot rolled \\  & Output & HRHS & and annealed stainless steel sheet \\  & & & (dimensionless) \\ \hline \hline \end{tabular}
\end{table}
Table 2: Identification of variables used for both LR and MLR models.  
\begin{table}
\begin{tabular}{c c c c c c c c c c c c c c c c c c c} \hline \hline
**Steel Grade** & \multicolumn{3}{c}{**A1**} & \multicolumn{3}{c}{**A2**} & \multicolumn{3}{c}{**A3**} & \multicolumn{3}{c}{**A4**} & \multicolumn{3}{c}{**A5**} & \multicolumn{3}{c}{**A6**} & \multicolumn{1}{c}{**A7**} & \multicolumn{1}{c}{**A8**} \\ \hline
**\# Sample** & **1** & **2** & **3** & **1** & **2** & **3** & **4** & **5** & **1** & **2** & **3** & **1** & **2** & **1** & **2** & **1** & **2** & **1** & **1** \\ \hline \multirow{4}{*}{\(\bigtriangleup\)} & LOO-1 & & & & & & & & & & & & & & & & & & & & & & & & \\  & LOO-2 & & & & & & & & & & & & & & & & & & & & & & & \\  & LOO-3 & & & & & & & & & & & & & & & & & & & & & & \\  & & & & & & & & & & & & & & & & & & & & & & & & \\  &