# Aircraft Structural Stress Prediction Based on Multilayer Perceptron Neural Network
## 4 Model Construction and Result Analysis
### Prediction Results and Analysis  
Figure 5 illustrates the decline in loss values for both the training and validation sets. Initially, the loss values decrease rapidly, followed by a gradual reduction as the number of iterations reaches 25 steps. After approximately 90 steps, the loss values stabilize. Following this stabilization, both the training and validation set losses fluctuate within a narrow range without changing by an order of magnitude, indicating that the model has converged. The model updates the network weights using the training data, resulting in significantly lower initial loss for the validation set compared to the training set. To enhance model performance, multiple early stopping criteria are employed to monitor the training process, ensuring that the best model for stress prediction is preserved. The scores of the MLP model and the RF model on the validation set and test set for each evaluation metric are presented in Table 7. Both models demonstrate a strong fitting performance on the validation set, with MSE metrics below 0.26 MPa, MAE within  
Figure 5: Training and Validation Loss Curves for MLP Model. 0.5 MPa, and MAPE below 5%. In contrast, on the test set, the performance metrics for the MLP model significantly outperform those of the RF model. These results indicate that the MLP model exhibits superior generalization capabilities and a greater ability to capture nonlinear relationships compared to the RF model. Figure 6 illustrates the stress prediction cloud and relative error cloud for both models under typical working conditions. A comparison of Figure 6a,b reveals that the equivalent stress distribution predictions on the airfoil ribs generated by the MLP model and the RF model align closely with the results obtained from FEM calculations, indicating that both models effectively capture the overall trend. However, Figure 6c,d demonstrate that while the MLP model exhibits lower relative errors compared to the RF model across most regions, some localized areas show relatively large discrepancies when compared to the FEM results. This observation can be attributed to the use of MSE as the loss function during the training of the MLP model. This choice tends to produce a more uniform distribution of errors across the overall region, resulting in smaller errors in higher stress areas  
Figure 7 presents scatter plots illustrating the prediction results of the MLP model and the RF model on the training and validation sets. Both models demonstrate strong prediction performance on the validation set; however, the MLP model significantly outperforms the RF model on the test set that includes limit case data. Notably, the prediction error of the RF model on the test set increases as the load rises, particularly after the stress value exceeds 20 MPa. In contrast, the prediction error of the MLP model begins to increase significantly only after the stress value surpasses 100 MPa. This discrepancy can be attributed to the nonlinear characteristics exhibited by the variation of loads on the wing ribs as they approach the ultimate operating condition. The MLP model is better equipped to capture these nonlinear dynamics compared to the RF model, which results in a higher threshold for the significant increase in prediction error for the MLP model relative to the RF model. Figure 6: Stress Prediction Results for Typical Operating Conditions. (**a**) Angle of Attack: \(5^{\circ}\); inflow Velocity: 165 km/h, (**b**) Angle of Attack: \(10^{\circ}\); inflow Velocity: 240 km/h, (**c**) Angle of Attack: \(5^{\circ}\); inflow Velocity: 165 km/h, (**d**) Angle of Attack: \(10^{\circ}\); inflow Velocity: 240 km/h. Figure 8 illustrates the distribution of absolute errors for the MLP model and the RF model across the validation and test sets. The MLP model demonstrates strong prediction accuracy on the validation set, with 95% of the regions exhibiting absolute errors of less than 0.6 MPa.