Keywords

1 Introduction

The energy of Sun is the most abundant energy source on planet earth, it is renewable and available for direct or indirect use, i.e. solar radiation, wind, biomass, thermal, etc. If only 0.1 % of the solar energy that reaches the earth could be turned into electrical energy at an efficiency of 10 %, there would be 4 times more energy available than the world production capacity (5000 GW) [1]. One way to harvest this energy source is through the use of photovoltaic (PV) technology. Over the last decade, PV technology has had a rapid increase in usage compared to other types of renewable energy sources [2]. A Photovoltaic module (PVM) converts solar radiation into Direct Current (DC) which is transferred to a power condition unit [2], this means that high levels of radiation improve the overall output of the PVM, but this has a side effect. Higher levels of radiation mean that the flux of photons moving within a PV cell is also higher, which results in an increase in temperature of the PVM [3]. However, the rise in temperature within the module reduces its efficiency, thus producing low levels of voltage and current [4], this causes a problem since it is necessary to extract as much energy as possible from the system in order to make it effective. The implementation of cooling systems offers a solution to this problem, but these systems require exact measurements of T\(_{mod}\) for their optimal operation [5]. However, temperature sensors are usually imprecise, require maintenance and are sensible to climate conditions such as ambient temperature, wind speed, radiation flux and thermal properties of the materials of the PVM, making them unreliable when used on these systems [6]. Estimation methods offer an alternative to temperature sensors, although, the unpredictability and the non-linear behavior of the temperature tends to be a problem when trying to estimate it. Artificial Intelligence (AI) techniques have recently had multiple applications on engineering in general and this is due to the fact that they provide a better solution as these often do not need statistic data and solve problems more complex than their own programming at higher speeds  [7]. AI covers multiple techniques such as Artificial Neural Networks (ANN), Adaptive Neuro Fuzzy Inference Systems (ANFIS), amongs others.

Different publications related to application of ANN and ANFIS on PV technology can be found elsewhere. García-Domingo et al. [8] proposed an electric characterization of a concentrating PV using ANN. Paul et al. [9] presented an ANN model to identify and optimize statistics representing insulation availability by a solar PV system. Mellit et al. [10] estimated the power produced of a photovoltaic module with an ANN estimation model. Salah and Ouali [11] proposed two methods of maximum power point tracking using ANN and ANFIS controllers for PV systems. Salaiman [2] presented the modeling of operating PV module temperature using ANN with solar irradiance and ambient temperature as inputs for the ANN architecture.

The aim of this investigation is to design ANN and ANFIS models to estimate the T\(_{mod}\) of a PV system and compare these two models to determinate which is the best for estimation of this variable. This paper is organized as follows: an overview on PV experimental systems is proposed in the second section, artificial neural networks and adaptive neuro fuzzy inference system models are described in the third section, the fourth section is devoted to the training, results and comparison process. Finally, conclusions are presented.

2 Material and Method

2.1 Photovoltaic Experimental System

A photovoltaic setup was developed and installed in order to acquire experimental data and evaluate its performance, the PV system was installed in Mérida, Yucatán, México (20\(^{\circ }\)56’18.2”N 89\(^{\circ }\)36’55.8” W), a schematic diagram of this setup is illustrated in Fig. 1. The system consists of a solar PVM, a current sensor with a 0 to 20/40/80 ADC selector and 0–5 VDC output, a voltage sensor, a miniature infrared temperature sensor, a data acquisition (DAQ) USB Device, and finally, a laptop with NI LabView TM software, see Table 1 for component models.

Fig. 1.
figure 1

Schematic diagram for experimental system setup.

The measured T\(_{mod}\) was taken by the infrared temperature sensor, the voltage and current of the PVM were measured with the voltage and current sensors, respectively with a duty cycle d set by the DC/DC converter. Finally, this data is collected in a synchronized pattern using the DAQ USB Device and then dispatched to the computer where it is analyzed via LabView TM, this software provides a user-friendly interface and allows the setting of sampling time intervals.

Table 1. Photovoltaic experimental systems characteristics.

The database consists of registers taken every 10 s, at 20 min an average value of the registers is calculated in order to obtain a representative sample and the result is moved into the database. Sample consisting of a total of 1045 data pairs with significant temperature variations (see Fig. 5) was selected for training and validation purposes of the AI models, this sample presents PVM parameters under different climate conditions. Table 2 illustrates a list of input and output variables used for the ANN and ANFIS models; Figs. 2, 3 and 4 represent graphical behavior of Current (I), Voltage (V) and Duty Cycle (d) respectively as input variables, and Fig. 5 represent the behavior of module temperature as output variable.

Table 2. Characteristics of input and output variables about ANN and ANFIS models.
Fig. 2.
figure 2

Graphical representation of the current.

Fig. 3.
figure 3

Graphical representation of the voltage.

Fig. 4.
figure 4

Graphical representation of the duty cycle.

Fig. 5.
figure 5

Graphical representation of the module temperature.

2.2 Artificial Neural Network

ANN is an interconnected set of processing units that uses mathematical and computational techniques to solve problems from complicated, imprecise or missing data [12]. Each of these units is called a perceptron or neuron and has an incoming weight, bias and an output given by the transfer function of the sum of the inputs, see Fig. 6. The function of the output neuron can be mathematically expressed as:

$$\begin{aligned} u(x,w) = \sum _{i=1}^{n} f(w_ix_i + b), \end{aligned}$$
(1)

where u(xw) is the output of the neuron, \(w_i\) is the synaptic weights, \(x_i\) is the input data and b is the bias value.

Fig. 6.
figure 6

A typical elementary network with 3 inputs.

An ANN is generally organized on three layers: Input, hidden and output layer [13]. The ANN training can be divided in two phases: The first phase consists of updating the neuron activation values with a chosen learning algorithm, the second phase updates weights to minimize the function error measuring the difference between the desired and actual output [14].

Developing an ANN requires selection of the optimal training architecture, often set using information given by the experience and knowledge of the user [2].

2.3 Adaptive Neuro Fuzzy Inference System

ANFIS is a multilayer network that uses neural network learning algorithms and fuzzy logic to map an input space to an output space. There are two types of fuzzy inference systems (FIS): Mamdani [15] and Sugeno [16]; Mamdani being more intuitive and suited to human input, whereas Sugeno is more computationally efficient and works well with optimization and adaptive techniques. The consequence parameter in Sugeno FIS can be either a linear equation or a constant coefficient. The linear equation called “first-order Sugeno FIS” and the constant coefficient called “zero-order Sugeno FIS” are proposed by Jang [18]. Given the advantages of the Sugeno FIS, this model is used in this study, see Fig. 7.

Five layers are used to construct this system. Each layer consists of n number of nodes described by their function. Nodes denoted by squares are called “adaptive nodes”, these represent parameter sets that are modifiable; nodes denoted by circles are called “fixed nodes”, these fixed parameters set in the system. The output data from the nodes in a layer will be the input data of the next layer.

Fig. 7.
figure 7

Simplified ANFIS architecture.

To demonstrate the procedure of the ANFIS, a simple architecture is proposed. The system in Fig. 7 consists of two inputs, \(x_1\) and \(x_2\), and one output, y. Suppose the system is a first-order Sugeno FIS with a rule base contaning two fuzzy if-then rules expressed as:

Rule 1:

If \(x_1\) is \(A_1\) and \(x_2\) is \(B_1\),

then \(f_1 = p_1x_1 + q_1x_2 + r_1\).

Rule 2:

If \(x_1\) is \(A_2\) and \(x_2\) is \(B_2\),

then \(f_2 = p_2x_1 + q_2x_2 + r_2\).

where \(p_i\), \(q_i\) and \(r_i\) (i = 1, 2) are the linear parameters of the consequent part of the Sugeno FIS. Each layer of the model is as follows (note that O\(_i^j\) denotes the output of the i-th node and the j-th layer):

Layer 1: Input nodes. Each node in this layer generates membership grades for each input. For instance, the function of the i-th may be a Gaussian MF:

$$\begin{aligned} O_i^1= \mu A_i(x) = \ e^\frac{-(x_i-b_i)^2}{2a_i^2}, i = 1, 2. \ \end{aligned}$$
(2)

where x is the input to node i, \(A_i\) is the MF associated with this node and \(a_i\), \(b_i\) are the parameters set that change the shape of the MF. Parameters in this layer are called premise parameters.

Layer 2: Rule nodes. Each node in this layer calculates the firing strength (output) of a rule via multiplication.

$$\begin{aligned} O_i^2 = w_i = \mu A_i(x_1)\mu B_i(x_2), i = 1, 2. \end{aligned}$$
(3)

In ANFIS the total number of rules is given by Eq. (4)

$$\begin{aligned} R_n = j^i, \end{aligned}$$
(4)

where i is the number of inputs, and j is the number of MFs per input.

Layer 3: Average nodes. Each node in this layer calculates the ratio of the i-th rule’s firing strength to the total of all firing strengths:

$$\begin{aligned} O_i^3 = \overline{w}_i = \frac{w_i}{\sum _iw_i}, i = 1, 2. \end{aligned}$$
(5)

Layer 4: Consequent nodes. Each node in this layer computes the contribution the i-th rule towards the overall output with the function:

$$\begin{aligned} O_i^4 = \overline{w}_if_i = \overline{w}_i(p_ix_1 + q_ix_2 + r_i), i = 1, 2. \end{aligned}$$
(6)

where \(\overline{w}_i\) is the output of the layer 3, and \(p_i\), \(q_i\), \(r_i\) are the parameter sets. Parameters in this layer are called consequent parameters.

Layer 5: Output node. The single node in this layer computes the overall output as the sum of all contribution from each rule:

$$\begin{aligned} O_i^5 = y_1 = \sum _i\overline{w}_if_i = \frac{\sum _iw_if_i}{\sum _iw_i} \end{aligned}$$
(7)

2.4 Statistical Criteria

For training, validation and comparison processes for ANN and ANFIS models, a statistical analysis is performed and applied using the following statistical test parameters: Correlation Coefficient (R), Root Mean Square Error (RMSE) and Mean Absolute Percentage Error (MAPE), see Table 3. R provides information on the linear relationship between the measured and estimated values. RMSE parameter is a frequently-used measure of the differences between values predicted by a model and the actual values observed. MAPE parameter is the absolute computed average of errors (%) by which estimated predictions of a variable differ from their actual values. The knowledge of this statistical parameter aids to evaluate whether the estimated predictions are underestimated or overestimated with respect to actual or expected data [19].

Table 3. Statistical criteria used for evaluation.

Where T\(_{mod}\) is the measured temperature and T\(_{sim}\) is the simulated temperature.

3 Results and Discussion

3.1 Artificial Neural Network

Measurements of voltage and current from the PVM and the d factor from the DC/DC converter were selected as input variables for the ANN architecture, and \(T_{mod}\) of the PVM as the desired output. The number of neurons and transfer functions in the hidden layer must be adjusted to minimize the differences between the target and simulated output. MatLab TM’s neural network tool was used to train and estimate the measured data, with a total of 1045 data pairs used in this model, \(80\,\%\) for training and \(20\,\%\) for testing and validation. All results reached for the ANN architecture were trained with 1000 iterations of 1000 epochs.

Fig. 8.
figure 8

Optimal ANN architecture reached.

The process to determine the learning algorithm, number of neurons in the hidden layer, and activation functions is frequently set using heuristic method. In this work, eight back-propagation algorithms were studied to determine the best T\(_{mod}\) estimation. Table 4 shows different back-propagation algorithms trained with 25 neurons in the hidden layer. Results show that the performance between Levenberg-Marquardt (RMSE = 2.4368) and Bayesian regularization (RMSE = 2.4471) algorithms are similar but differ in the mean time of convergence (2.21 and 19.12 s respectively), Levenberg-Marquardt was over eleven times faster than the Bayesian regularization. The best prediction was found with the Levenberg-Marquardt algorithm, this algorithm performs at RMSE=2.4368 with better linear fitting (\(y = 0.67x + 99\)) and an execution time of 2.21 s, this is due to the LM algorithm being designed to approach second order training speed without having to compute the Hessian matrix [20].

Table 4. Comparison of back-propagation algorithms.

In order to find the most efficient transfer function, two different pairs of the transfer functions (Tansig-Purelin and Logsig-Purelin) were tested for the hidden and output layer respectively, varying the number of neurons in the hidden layer and training with LM algorithm. Logsig-Purelin were the functions with the best performance. A structure 3–25-1 presents a smaller RMSE (2.4368) and greater R (0.8167) than the values trained with a combination of Tansig-Purelin transfer function.

The optimum ANN architecture was found using an evaluation with different combinations of neurons. Table 5 illustrates the statistical comparison for different ANN architectures, the finest calculation is achieved by the ANN model with 25 neurons in the hidden layer, see Fig. 8. According to the results obtained about the RMSE, MAPE and R; values for training and testing are 2.4368, 0.6413 and 0.8167, respectively.

Table 5. Tests with different ANN architectures.
Fig. 9.
figure 9

ANFIS architecture used in this study. Input to Layer 3 connections are not shown.

3.2 Adaptive Neuro Fuzzy Inference System

The ANFIS model (see Fig. 9) used in this study has three inputs (V, I, d), with five membership functions assigned to each input variable, which results in having 125 total rules according to Eq. (4). The input database (containing 1045 data pairs) was randomly divided into learning and testing (80 % and 20 % respectively), obtaining good representation of the data distribution and to improve the overall training process. Several MF types were tested, including triangular, trapezoidal, generalized bell, Gaussian, sigmoidal and Pi; with 100 epoch in each training session using a hybrid learning algorithm, which uses a combination of the least-squares and back-propagation gradient descent methods to model a training data set [17]. Optimum parameters were found when checking data reached minimum RMSE.

Table 6. ANFIS performance with different types of membership functions.
Fig. 10.
figure 10

Comparison between error of the T\(_{mod}\), ANN and ANFIS outputs respectively.

Table 6 illustrates the ANFIS performance with different types of MF, it can be observed that the best architecture was obtained with the FIS composed by Gaussian membership function with smaller RMSE = 2.5235, MAPE = 0.6566 and higher R = 0.7996.

3.3 Comparison of ANN and ANFIS Models

The estimation capability of the ANN and ANFIS models were individually evaluated by a linear regression analysis (\(y = a + bx\)) between the estimated (T\(_{ANN}\) and T\(_{ANFIS}\) for ANN and ANFIS respectively) and measured (T\(_{mod}\)) data (using the correlation coefficient: R; the intercept: a; and the slope: b) under the same conditions [21]. Results obtained for ANN and ANFIS models are graphically shown in Fig. 10 (a, b).

The best linear regression equation for the ANN model was given by statistical parameters: a = 0.67 and b = 99 with R = 0.8120; whereas for ANFIS: a = 0.64 and b = 108 with R = 0.7996. According to these statistical analysis the ANN model estimation proved to be better than ANFIS for the T\(_{mod}\) approximation, although, the difference between ANN and ANFIS models is not outstanding.

Fig. 11.
figure 11

Comparison between measured temperatures, ANN and ANFIS outputs.

With the purpose to illustrate the behavior of the estimated T\(_{mod}\) of the ANN and ANFIS in comparison with the measured data, Fig. 11 presents samples of ANN and ANFIS models estimations of this variable. It can be observed that ANN and ANFIS following the periodic behavior of the T\(_{mod}\) with ANN having better precision than ANFIS.

4 Conclusion

Application and comparison of ANN and ANFIS models for estimation of photovoltaic module temperature were investigated. Models with different functions were designed and trained by ANN and ANFIS methods. Values R, RMSE and MAPE were obtained for the ANN and ANFIS models. Comparing the performance of both models, the ANN model with Levenberg-Marquardt function had better performance in photovoltaic module temperature estimation and was selected as the best fitting model. It is also important to recognize that the prediction capability of the ANN and ANFIS could be significantly improved by an appropriate training with a larger number of field measurements under such conditions and the complex behavior of the module temperature. ANN and ANFIS could constitute useful and practical tools for the implementation of smart sensors that estimate the module temperature on a photovoltaic system. One of the applications of these smart sensors focuses in the employment of cooling systems to improve the operation performance of photovoltaic modules and increase their efficiency.