# A Review of Thermal Error Modeling Methods for Machine Tools
## 2 Thermal Error Modeling Method for Machine Tools
### Neural Network (NN)  
Neural network is a hot research spot that has emerged from the field of artificial intelligence since the 1980s. In the neural network model, multiple variables are used as input and output. There are three layers (input, output, and hidden) in classical NN model. The input layer accepts external signals and data. The output layer realizes the output of the system processing results, and the hidden layer is a unit that lies between the input and output layers and cannot be observed from the outside of the system. As shown in Figure 3, it is a kind of structure of thermal error compensation model based on a BP neural network with five inputs. Compared with the regression model, the artificial neural network model has good nonlinear fitting performance and better prediction accuracy. As early as the end of the last century, artificial neural networks have been used for the thermal error modeling of machine tools [42]. Usually, the temperature variables tested by multiple sensors are taken as the input and the thermal errors of machine tools are the output of NN model. After the network learning and training, the thermal errors of machine tools in multiple directions  
Figure 3: The structure of thermal error compensation based on BP neural network. can be accurately fitted and predicted [43; 44; 45]. Back propagation (BP) and radial basis function (RBF) are two kinds of the most common used neural network methods. By using a BP neural network, complex nonlinear relations can be fully approximated. BP neural networks have high robustness and fault tolerance ability, so it is widely used for thermal error modeling. However, the convergence speed of the BP neural network is slow and it is easy to fall into value-extremum [46]. In order to solve these problems, [PERSON] and [PERSON] [47] used a hybrid particle swarm algorithm to optimize the structure of the BP neural network and to avoid unstable prediction performance. Similarly, [PERSON] et al. [48], [PERSON] et al. [49], [PERSON] et al. [50], and [PERSON] et al. [51] used the variable inertia factor particle swarm algorithm to optimize the weights and thresholds of the BP neural network, and build the thermal error model of the machine tool. The improved BP neural network model could better overcome the limitations of the traditional BP algorithm, and the accuracy was relatively high. Among them, the prediction accuracy of [PERSON]'s model was 93.155%, and that of [PERSON]'s model reached to 96.5%. In order to solve the problem that the BP neural network cannot adjust independent parameters of new data in thermal error modeling, [PERSON] et al. [52] proposed an improved BP neural network model based on the overall adjustment strategy. By achieving the minimum value of the square error of the overall data, the prediction accuracy of this improved thermal error model was increased 50%. In the paper of [PERSON] et al. [53], multiple BP neural network models were integrated to enhance the predictive performance. With the improved model on a horizontal machining center THM6380, the root mean squared error (RMSE) of the integrated model was 5.6522 \(\mu\)m. To improve the robustness of the BP neural network, [PERSON] et al. [54] modified the BP network into a dynamic feedback network. With this method, the residual error after thermal error compensation was smaller. The ability dealing with dynamic information was also improved and the training time was greatly reduced. Furthermore, based on the research of the relationship between the thermal error and the actual motion error of machine tool parts, [PERSON] et al. [55] used the \"two-step method\" to establish the thermal error model of a ball screw. In this method, BP neural network was first used to model the thermal deformation of the screw. Then, the relationship between the axial thermal error of the table and the actual thermal deformation of the screw was obtained based on the polynomial fitting method. However, this method has not been applied for complex machine tools.