## 4 Adaptive Neuro-Fuzzy System  
The MATLAB 16 (MathWorks, US) software was used to identify the adaptive neuro-fuzzy inference \"system-ANFIS\" model. This is one of the most commonly used programs for creating intelligent models [18]. To train and create an ANFIS, the fuzzy logic toolbox in the program MATLAB was used. The ANFIS architecture is based on the Sugeno type of fuzzy inference system [19]. This method represents an effective system for undertaking complex tasks where knowledge is expressed through the if-then rules. With the help of the neural network and fuzzy logic, ANFIS suggests a relationship of mapping between input and output data. For the optimal adjustment of membership functions, the most useful hybrid learning method is used [20]. The ANFIS model structure is based on fuzzy logic, while the neural network is only used in model training [21]. Figure 2 shows the basic architecture of the ANFIS model. In this case, a five-layer neural network was used that simulated the operation of a fuzzy inference system (Figure 2). Every layer of the network has its role here. Figure 3 shows a five-layer neural network through which the ANFIS model training was performed. Input values (crisp signal), such as cutting speed, feed, depth of cut, and tool material, were converted to fuzzy values through the membership functions. The key roles when creating the ANFIS model are the membership function and the rule base. Based on experimental data, a set of rules was generated by defining the number and type of membership functions. Figure 2: Four inputs and one output fuzzy inference system for cutting temperature. The structure of the neuro-fuzzy model consisted of five different adaptive layers. Below is a brief description of the Sugeno first-order model with two input variable variables. Layer 1: The fuzzification layer, where the names of the fuzzy sets or language variables are defined. \[ \begin{array}{l}O_{i}^{1}=\mu_{Ai}(x_{2}),\ i=1,2\\ O_{j}^{1}=\mu_{Bi}(x_{2}),\ i=1,2\end{array}  \tag{3}\]  
where \(O_{i\;or\;j}^{1}\) are output functions and \(\mu_{Ai\;or\;Bi}\) are membership functions. Layer 2: Represents the result of layer 1. Here the weight functions \(w_{i}\) for the next layer is defined. \[ \begin{array}{l}O_{i}^{2}=w_{i}=\mu_{Ai}(x_{1})\mu_{Bi}(x_{2}),\ \ \ i=1,\ 2\end{array}  \tag{4}\]  
Layer 3: In this layer, the normalization of the value from layer 2 is carried out and is transferred to layer 4. \[ \begin{array}{l}O_{i}^{3}=\overline{w}_{i}=\frac{w_{i}}{\Sigma_{i}w_{i}}\ \ \ i=1,\ 2\end{array}  \tag{5}\]  
Layer 4: The de-fuzzification layer. In this layer, the linear parameters \(p_{i}\), \(q_{i}\), and \(r_{i}\) that result from the function are defined. \[ \begin{array}{l}O_{i}^{4}=\overline{w}_{i}\cdot f_{i}=\overline{w}_{i}(p_{i }\cdot x_{1}+q_{i}\cdot x_{2}+r_{i})\ \ \ i=1,\ 2\end{array}  \tag{6}\]  
Layer 5: The total output layer. The total number of output signals is the output from this layer. \[ \begin{array}{l}Q_{i}^{5}=f(x_{1},x_{2})=\frac{\Sigma}{i}\overline{w}_{i} \cdot f_{i}=\overline{w}_{i}\cdot f_{1}+\overline{w}_{i}\cdot f_{2}=\frac{ \Sigma_{i}w_{i}\cdot f_{i}}{\Sigma_{i}w_{i}}.\end{array}  \tag{7}\]  
The most significant steps in identifying the ANFIS model are the training and testing steps that defined the model's characteristics. The total number of experimental data used to generate the ANFIS model was 48. Approximately 70% of the data was used to successfully train the model, while the remaining 30% is used for testing. Therefore, for this study, 36 training data points and 12 test data points were used. There are more possible membership functions, but for this research, the Gaussian function was chosen. From the crisp input, the neural network passes data using the membership functions. Neural  
Figure 3: Adaptive fuzzy inference system. networks define the basic rules that are associated with system locking. The hybrid learning method was used to train the adaptive network and the proper form of the membership function.