*4.2. Adaptive Neuro-Fuzzy Interface System Modelling (ANFIS)*

system for waste heat recovery.

*4.2. Adaptive Neuro-Fuzzy Interface System Modelling (ANFIS)*  The ANFIS is one of the artificial intelligence techniques which is the combination of ANN and fuzzy logic [30]. The nonlinear relationship between the input and output parameters with a larger number of data points could be established accurately using ANFIS [30]. Like ANN, the ANFIS is also used to predict and optimize the performances of the various physical systems [31]. The input and output parameters needed to be related are imported in the ANFIS model in the form of neurons. The data of each input and output parameter are shown in the form of various membership functions [31]. The type of membership function and number of membership functions are decided based on the variation trend of the input and output data. The types of membership functions in the ANFIS model are triangular, trapezoidal, gbell, gauss, gauss2, pi, dsig and psig [32]. In the ANFIS model, the input and output data are connected by rules with the statements by showing the relationship between the input and output data. The prediction of the output values for the various input conditions are decided based on the rules. The ANFIS structure is trained using two algorithms of the back-propagation and hybrid [33]. The maximum number of epochs and maximum error are set for the training of an ANFIS model. During the training of ANFIS, the rules get adjusted to predict the desired output of the various physical systems like solar systems. The training is continued until the desired accuracy is achieved. The ANFIS model with the prediction value closest to the actual output is selected as the optimum model [33]. The output variables are predicted from the optimum The ANFIS is one of the artificial intelligence techniques which is the combination of ANN and fuzzy logic [30]. The nonlinear relationship between the input and output parameters with a larger number of data points could be established accurately using ANFIS [30]. Like ANN, the ANFIS is also used to predict and optimize the performances of the various physical systems [31]. The input and output parameters needed to be related are imported in the ANFIS model in the form of neurons. The data of each input and output parameter are shown in the form of various membership functions [31]. The type of membership function and number of membership functions are decided based on the variation trend of the input and output data. The types of membership functions in the ANFIS model are triangular, trapezoidal, gbell, gauss, gauss2, pi, dsig and psig [32]. In the ANFIS model, the input and output data are connected by rules with the statements by showing the relationship between the input and output data. The prediction of the output values for the various input conditions are decided based on the rules. The ANFIS structure is trained using two algorithms of the back-propagation and hybrid [33]. The maximum number of epochs and maximum error are set for the training of an ANFIS model. During the training of ANFIS, the rules get adjusted to predict the desired output of the various physical systems like solar systems. The training is continued until the desired accuracy is achieved. The ANFIS model with the prediction value closest to the actual output is selected as the optimum model [33]. The output variables are predicted from the optimum ANFIS model by importing the input variables into the rule viewer [34].

ANFIS model by importing the input variables into the rule viewer [34]. Figure 4 shows the structure of formulated ANFIS model to predict the performance of the thermoelectric generator system for waste heat recovery. The selected ANFIS model type is a Takagi– Sugeno which has *n* number of inputs with only one output prediction [35]. Hence, in the present ANFIS model, two input parameters of voltage and temperature are connected to one output parameter of current, power and thermal efficiency. Seven ANFIS models are formulated to predict the performances of the thermoelectric generator system for waste heat recovery and predict the current, power and thermal efficiency of the thermoelectric generator system for waste heat recovery with the hot gas temperatures and high potential voltage conditions. Seven membership functions of the triangular, trapezoidal, gauss, gauss2, gbell, pi and dsig are used to formulate the ANFIS models, and each ANFIS model is formulated with one type of the membership function. In each ANFIS model, each type of membership function is used with the number of sets of 2, 3, 4 and 5. The ANFIS Figure 4 shows the structure of formulated ANFIS model to predict the performance of the thermoelectric generator system for waste heat recovery. The selected ANFIS model type is a Takagi–Sugeno which has *n* number of inputs with only one output prediction [35]. Hence, in the present ANFIS model, two input parameters of voltage and temperature are connected to one output parameter of current, power and thermal efficiency. Seven ANFIS models are formulated to predict the performances of the thermoelectric generator system for waste heat recovery and predict the current, power and thermal efficiency of the thermoelectric generator system for waste heat recovery with the hot gas temperatures and high potential voltage conditions. Seven membership functions of the triangular, trapezoidal, gauss, gauss2, gbell, pi and dsig are used to formulate the ANFIS models, and each ANFIS model is formulated with one type of the membership function. In each ANFIS model, each type of membership function is used with the number of sets of 2, 3, 4 and 5. The ANFIS models are trained for the same experimental data with sets of 931 data points used to train the ANN models.

All ANFIS models are trained using the back-propagation algorithm for the maximum epochs of 1000 and maximum error of 10−<sup>6</sup> . The ANFIS models are trained until the training error becomes steady. Once the training error converges, the output values are predicted in the rule viewer by importing the input conditions of hot gas temperature and voltage conditions. The predicted values of the current, power and thermal efficiency by each ANFIS model are compared with the corresponding experimental values using three statistical parameters of R<sup>2</sup> , RMSE and COV. The ANFIS model with the optimum values of three statistical parameters is considered as the best model to predict the current, power and thermal efficiency of the thermoelectric generator system for waste heat recovery under the influence of various hot gas inlet temperatures and voltage conditions. *Symmetry* **2020**, *12*, x FOR PEER REVIEW 8 of 30 epochs of 1000 and maximum error of 10−6. The ANFIS models are trained until the training error becomes steady. Once the training error converges, the output values are predicted in the rule viewer by importing the input conditions of hot gas temperature and voltage conditions. The predicted values of the current, power and thermal efficiency by each ANFIS model are compared with the corresponding experimental values using three statistical parameters of R2, RMSE and COV. The ANFIS model with the optimum values of three statistical parameters is considered as the best model to predict the current, power and thermal efficiency of the thermoelectric generator system for waste heat recovery under the influence of various hot gas inlet temperatures and voltage conditions.

**Figure 4.** Formulated ANFIS model to predict the performances of the thermoelectric generator system for waste heat recovery. **Figure 4.** Formulated ANFIS model to predict the performances of the thermoelectric generator system for waste heat recovery.

### **5. Data Reduction 5. Data Reduction**

The power generated by the thermoelectric modules [36] is expressed with Equation (10): The power generated by the thermoelectric modules [36] is expressed with Equation (10):

$$P = VI\tag{10}$$

where is the power (W) of the thermoelectric modules, is the voltage (V) and is the current where *P* is the power (W) of the thermoelectric modules, *V* is the voltage (V) and *I* is the current (A).

(A). The thermal efficiency of the thermoelectric generator system for waste heat recovery could be calculated with Equation (11) as the ratio of the power generated by the thermoelectric modules () to the heat transfer through the thermoelectric modules (ሶ ) [36]: The thermal efficiency of the thermoelectric generator system for waste heat recovery could be calculated with Equation (11) as the ratio of the power generated by the thermoelectric modules (*P*) to the heat transfer through the thermoelectric modules ( . *Q*) [36]:

$$
\eta\_{th} = \frac{P}{\dot{Q}} \times 100\% \tag{11}
$$

where ௧ is the thermal efficiency (%) of the thermoelectric generator system for waste heat recovery and ሶ is the heat transfer (W) through the thermoelectric modules. The heat transfer through the thermoelectric modules [37] is calculated using the Fourier's law of heat conduction as shown by Equation (12): where η*th* is the thermal efficiency (%) of the thermoelectric generator system for waste heat recovery and . *Q* is the heat transfer (W) through the thermoelectric modules. The heat transfer through the thermoelectric modules [37] is calculated using the Fourier's law of heat conduction as shown by Equation (12):

$$
\dot{Q} = \frac{KA}{t} \Delta T \tag{12}
$$

(13)

where is the thermal conductivity (W/m∙K), is the surface area (m2), is the module thickness (m) and ∆ is the temperature difference (°C) of the thermoelectric module. The coefficient of determination (R2), root mean square error (RMSE) and coefficient of variance where *K* is the thermal conductivity (W/m·K), *A* is the surface area (m<sup>2</sup> ), *t* is the module thickness (m) and ∆*T* is the temperature difference (◦C) of the thermoelectric module.

(COV) are calculated using Equations (13)–(15), respectively [38]:

The coefficient of determination (*R* 2 ), root mean square error (RMSE) and coefficient of variance (COV) are calculated using Equations (13)–(15), respectively [38]:

$$\mathcal{R}^2 = 1 - \frac{\sum\_{m=1}^n \left( \mathcal{X}\_{pre,m} - \mathcal{Y}\_{ma,m} \right)^2}{\sum\_{m=1}^n \left( \mathcal{Y}\_{ma,m} \right)^2} \tag{13}$$

$$RMSE = \sqrt{\frac{\sum\_{m=1}^{n} \left(X\_{pre,m} - Y\_{ma,m}\right)^2}{n}} \tag{14}$$

$$\text{ACC} = \frac{\text{RMSE}}{\left| \overline{\mathbf{Y}}\_{\text{ma}} \right|} \times 100 \tag{15}$$

where *R* 2 is the coefficient of determination, *RMSE* is the root mean square error, *COV* is the coefficient of variance, *n* is the number of data points, *Xpre*,*<sup>m</sup>* is predicted the value of the output parameter at data point *m*, *Ymea*,*<sup>m</sup>* is the experimental (actual) value of output parameter at data point m and *Ymea* is the average value at all experimental data points.
