Next Article in Journal
Water Quality Evaluation and Analysis by Integrating Statistical and Machine Learning Approaches
Previous Article in Journal
Epileptic Seizure Prediction Using a Combination of Deep Learning, Time–Frequency Fusion Methods, and Discrete Wavelet Analysis
Previous Article in Special Issue
PI-DÆ: An Adaptive PID Controller Utilizing a New Adaptive Exponent (Æ) Algorithm to Solve Derivative Term Issues
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Comparison of Classical and Artificial Intelligence Algorithms to the Optimization of Photovoltaic Panels Using MPPT

by
João T. Sousa
1 and
Ramiro S. Barbosa
1,2,*
1
Department of Electrical Engineering, Institute of Engineering—Polytechnic of Porto (ISEP/IPP), 4249-015 Porto, Portugal
2
GECAD—Research Group on Intelligent Engineering and Computing for Advanced Innovation and Development, ISEP/IPP, 4249-015 Porto, Portugal
*
Author to whom correspondence should be addressed.
Algorithms 2025, 18(8), 493; https://doi.org/10.3390/a18080493
Submission received: 14 July 2025 / Revised: 29 July 2025 / Accepted: 2 August 2025 / Published: 7 August 2025
(This article belongs to the Special Issue Algorithmic Approaches to Control Theory and System Modeling)

Abstract

This work investigates the application of artificial intelligence techniques for optimizing photovoltaic systems using maximum power point tracking (MPPT) algorithms. Simulation models were developed in MATLAB/Simulink (Version 2024), incorporating conventional and intelligent control strategies such as fuzzy logic, genetic algorithms, neural networks, and Deep Reinforcement Learning. A DC/DC buck converter was designed and tested under various irradiance and temperature profiles, including scenarios with partial shading conditions. The performance of the implemented MPPT algorithms was evaluated using such metrics as Mean Absolute Error (MAE), Integral Absolute Error (IAE), mean squared error (MSE), Integral Squared Error (ISE), efficiency, and convergence time. The results highlight that AI-based methods, particularly neural networks and Deep Q-Network agents, outperform traditional approaches, especially in non-uniform operating conditions. These findings demonstrate the potential of intelligent controllers to enhance the energy harvesting capability of photovoltaic systems.

1. Introduction

Given the increasing global emphasis on sustainable and renewable energy solutions, photovoltaic (PV) energy plays a central role in the transition towards a sustainable energy paradigm. The global climate crisis, combined with the reduced availability of fossil resources, has accelerated the adoption of renewable energy solutions, positioning solar technology as a key pillar in decarbonization strategies worldwide. In this context, PV systems have emerged as a viable and scalable alternative, not only for their ability to generate clean energy but also for their flexibility in applications ranging from small-scale residential installations to large utility-scale power plants [1].
The overall efficiency of PV systems is directly linked to their ability to continuously extract the maximum available power from the solar panels. However, this task is inherently complex due to the dynamic nature of environmental conditions such as irradiance, temperature, and especially the occurrence of partial shading. These non-linearities introduce multiple local maximum in the power–voltage (P–V) characteristics curve, making the tracking of the global maximum power point (GMPP) a significant challenge. As a result, MPPT algorithms have become an essential component in PV system design, aimed at dynamically adjusting the operating point to ensure optimal energy harvesting under all conditions [2].
Over the past decades, MPPT has been the subject of extensive research, with traditional methods such as Perturb and Observe (P&O) and Incremental Conductance (InC) being widely adopted due to their simplicity and low computational cost. Nevertheless, these algorithms are known to suffer from several limitations, particularly under rapidly changing irradiance or partial shading conditions, where they tend to converge to local maxima or induce persistent oscillations around the operating point [3,4].
To overcome these limitations, the integration of intelligent control techniques has gained significant attention. Among these, Artificial Neural Networks (ANNs) and Deep Q-Networks (DQNs), a type of Deep Reinforcement Learning (DRL), have shown remarkable performance in handling the complex, non-linear, and dynamic behavior of PV systems. These AI-based approaches offer faster convergence, improved tracking precision, and greater stability under challenging conditions such as partial shading. By learning from environmental variations and adapting their control strategies in real time, ANN and DQN algorithms significantly enhance the system’s ability to identify and follow the true GMPP, even in highly variable scenarios.
The work by J and SY [5] presents an MPPT strategy using Artificial Neural Networks (ANNs), comparing it against the conventional P&O method. The study revealed that the ANN-based approach provides more accurate tracking and faster response times under dynamic irradiance conditions, outperforming P&O in terms of efficiency and stability.
In a more recent study, Giraldo et al. [6] applied Deep Reinforcement Learning (DRL), specifically a Deep Q-Network (DQN), for MPPT in real PV systems. The work includes both simulation and experimental validation, showing that, while DQN outperformed P&O in simulations, especially under partial shading conditions (PSCs), the real-world results were mixed. Notably, in PSC scenarios, P&O often got stuck in a local MPP, whereas DQN was able to extract up to 63.5% more energy, demonstrating the advantages of autonomous learning strategies. An early contribution to the use of reinforcement learning in MPPT is presented in the study by Kofinas et al. [7]. In their work, a tabular Q-learning algorithm was developed to track the MPP, showing strong convergence stability and reduced computational effort when compared to traditional metaheuristic techniques. Their results demonstrated that the method consistently outperformed the conventional P&O algorithm across multiple scenarios involving variations in irradiance and temperature. This line of research has since been extended by authors such as CSE [8] and Bavarinos et al. [9], who investigated alternative tabular reinforcement learning strategies for MPPT. These studies introduced comparative analyses between Q-learning and SARSA agents, as well as hybrid schemes incorporating fuzzy logic and sliding mode control, further validating the effectiveness of RL-based methods under dynamic environmental conditions.
Similarly, Phan et al. [10] explored DRL methods, including DQN and Deep Deterministic Policy Gradient (DDPG), for MPPT in MATLAB/Simulink simulations. Their work focused on the challenges of partial shading and showed that DQN significantly improved tracking efficiency compared to P&O. Under uniform conditions, DQN achieved a 5.83% efficiency gain, while DDPG yielded a 3.21% improvement, supporting the applicability of DRL in optimizing PV performance.
Remoaldo and Jesus [11] presented a comparative analysis between traditional P&O and a fuzzy logic-enhanced version (FLP&O). Using a system with five series-connected PV panels and a boost converter, the study demonstrated that FLP&O offers quicker convergence to the MPP under rapid irradiance changes, confirming the benefits of fuzzy logic in improving MPPT response time and accuracy.
Furthermore, the comprehensive review by Katche et al. [12] highlighted the limitations of conventional MPPT algorithms like P&O under partial shading. The authors advocated for hybrid and intelligent optimization techniques, which offer improved performance at the expense of higher computational complexity and cost, suggesting that the trade-off is justified in dynamic environments.
In addition to conventional approaches, the scientific community has increasingly explored the application of soft computing and evolutionary algorithms for MPPT control in photovoltaic systems. As highlighted by Rezk et al. [13], advanced control techniques such as fuzzy logic control (FLC) [14] and adaptive neuro-fuzzy inference systems (ANFISs) [15,16] have shown strong capability in managing the non-linear and time-varying behavior of PV systems. In parallel, a wide range of bio-inspired optimization algorithms have emerged as promising alternatives for global optimization. Among these, techniques such as genetic algorithms (GAs) [17], cuckoo search (CS) [18], ant colony optimization (ACO) [19], bee colony algorithm (BCA) [20], bat-inspired optimization (BAT) [21], and the memetic salp swarm algorithm [22] have demonstrated considerable effectiveness. These methods are particularly well-suited to address the challenges posed by partial shading conditions as they enable good exploration of the search space and enhance the system’s ability to reliably detect the GMPP. According to Jiang Jiang et al. [23], both soft computing and evolutionary techniques exhibit enhanced adaptability and are capable of delivering efficient and reliable tracking performance even under highly dynamic and non-linear operating conditions.
Additionally, recent works have explored data-driven and neural network-based methods that, while applied in different domains, offer valuable insights for adaptive control strategies in PV systems. For example, Lu et al. [24] proposed a transfer learning framework to enhance adaptability in dynamic environments, while Aizenberg and Tovt [25] introduced a multilayer neural network approach for intelligent frequency domain filtering. These contributions reinforce the relevance of learning-based techniques in handling non-linear time-varying conditions.
Lastly, Sharma et al. [26] compared traditional and metaheuristic MPPT techniques. Their findings reinforce that, although conventional algorithms such as P&O are easier to implement, they struggle in PSC scenarios.
Although previous studies have provided valuable insights, the majority of works in the literature still present notable limitations that prevent a comprehensive evaluation of MPPT strategies. Many focus on comparing only two or three algorithms, often within limited and idealized scenarios. Furthermore, performance assessments are frequently restricted to a few basic metrics, such as efficiency or steady-state accuracy, overlooking crucial dynamic aspects like convergence time or tracking stability under complex PSC. In particular, convergence time is an essential indicator of system responsiveness that remains underexplored and rarely quantified rigorously. Additionally, detailed scenario characterization, especially for PSC cases, is often lacking or simplified.
To address these gaps, this work presents a comprehensive comparative analysis of MPPT algorithms, including conventional methods (P&O and InC), control logic (FLC), hybrid (GA-based), and intelligent approaches (ANNs and DQNs). All the methods are evaluated under both uniform and partial shading conditions using a modular MATLAB/Simulink framework. Multiple performance metrics—MAE, IAE, MSE, ISE, efficiency, and convergence time—are considered. Convergence time is calculated using formal signal analysis with graphical validation. Test cases are clearly defined with specific irradiance and temperature settings, ensuring transparency. This study offers deeper insight into the strengths and limitations of MPPT strategies, especially AI-based ones, to support their practical application in PV systems.
The article is organized as follows. Section 2 describes the photovoltaic system modeling and simulation setup. Section 3 outlines the buck converter design. Section 4 defines the test scenarios, including both uniform and partial shading conditions. Section 5 presents the implemented MPPT algorithms, covering conventional, hybrid, and AI-based methods. Section 6 introduces the evaluation metrics, followed by the results and comparative analysis in Section 7. Section 8 discusses the key findings, and Section 9 concludes the work with suggestions for future developments.

2. PV System Description

The implemented PV system models were developed in MATLAB/Simulink to analyze the performance of different MPPT control strategies under realistic conditions. Figure 1b presents the system’s block diagram and its component interactions. Two configurations were considered: (i) a photovoltaic model with a single bypass diode, representing the actual SOLARPOWER XUNZEL 30 W 24 V panel (Figure 1a), and (ii) an extended model with three series-connected cell groups, each equipped with an individual bypass diode to simulate PSC (Figure 2). This latter approach allowed independent adjustment of irradiance and temperature for each cell group, enabling a comprehensive evaluation of MPPT algorithms under non-uniform operating conditions.
Figure 1a shows the Simulink implementation, structured into colored blocks:
  • Blue (MPPT Controller): Computes PV voltage, current, and power, implementing the MPPT algorithm to generate the optimal duty cycle for the Pulse Width Modulation (PWM) generator.
  • Green (DC–DC Buck Converter): Models the buck converter circuit, which adjusts the output voltage and current to transfer power efficiently to the load based on the MPPT control.
  • Orange (Measurements): Monitors key variables such as voltages, currents, power, efficiency, temperature, and irradiance, displaying them for performance analysis.
  • Yellow (Performance Metrics): Calculates and exports input/output power, efficiency, and tracking error to the MATLAB workspace for further evaluation.
This modular structure enables a clear and organized simulation environment for testing and comparing MPPT algorithms under different operating conditions.
The photovoltaic panel operation was characterized through detailed electrical calculations based on the manufacturer’s specifications presented in Table 1.
As shown in Figure 3, the red curve on both I–V and P–V plots indicates the MPP of the panel.
The PV parameters, summarized in Table 2, were calculated using the following formulas:
P i n = V m p p × I m p p
P o u t = η × P i n
I o u t = P o u t V o u t
R o = V o u t 2 P o u t

3. DC/DC Buck Converter Design

The DC/DC buck converter was carefully designed to interface with the PV panel while maintaining maximum power point tracking. The complete design process is presented below, with the circuit topology shown in Figure 4 [29,30].
Figure 4 illustrates the buck converter configuration, which includes a control switch, a diode, an inductor, and an output capacitor. The converter steps down the PV array voltage to the desired load level (20 V) while maintaining operation at the MPP, as dictated by the MPPT algorithm.
The key parameters of the converter, such as duty cycle (D), inductance ( L o ), and capacitance ( C o ), were calculated using classical design equations to ensure continuous conduction mode (CCM) and minimize ripple in both current and voltage. These calculations are based on the following expressions, respectively:
D = V o u t V i n
L o ( V i n V o u t ) × D f s × Δ I
C o Δ I 8 × f s × Δ V
Table 3 summarizes the theoretical values obtained and used in the simulations.

4. Simulation Scenarios

To evaluate the performance of the implemented MPPT algorithms under realistic operating conditions, two sets of simulation scenarios were defined: one with a single bypass diode and another with three bypass diodes to simulate PSC.
Table 4 summarizes the four scenarios for the single bypass diode configuration. These include uniform irradiance, varying irradiance, varying temperature, and simultaneous variation of both parameters, enabling assessment under static and dynamic environmental conditions. The corresponding temperature and irradiance profiles for each scenario are illustrated in Figure 5, which shows the environmental input conditions applied to the PV model in these simulations.
Table 5 presents the PSC scenarios using three series-connected cell groups, each with its own bypass diode. These configurations simulate different shading patterns by assigning independent irradiance levels to each cell group while maintaining the ambient temperature at 25 °C.

Analysis of I–V and P–V Curves Under PSC Conditions

To understand the formation of multiple local maxima and the GMPP under partial shading, it is essential to analyze the I–V and P–V characteristic curves for each PSC scenario illustrated in Figure 6.
These characteristic curves validate the importance of testing algorithms under non-uniform conditions to assess their capability to detect the true GMPP efficiently.

5. MPPT Algorithms

Table 6 presents the classification of the MPPT algorithms implemented in this study. Conventional techniques such as Perturb and Observe (P&O) and Incremental Conductance (InC) were included as baseline methods due to their simplicity and widespread use in PV applications.
Additionally, a control logic-based approach using the fuzzy logic controller (FLC) was implemented for its ability to handle system non-linearities through rule-based decision-making. An optimization-based algorithm, the genetic algorithm (GA), was also tested for its global search capability in identifying the maximum power point, particularly under partial shading conditions.
Hybrid algorithms were explored to combine the advantages of different methods, including InC combined with P&O (InC+P&O), GA combined with InC (GA+InC), and GA combined with P&O (GA+P&O), aiming to enhance convergence speed and tracking accuracy in dynamic environments.
However, particular emphasis in this work was placed on artificial intelligence (AI)-based algorithms due to their superior adaptability and learning capabilities. Specifically, the Artificial Neural Network (ANN) was employed for its powerful pattern recognition and non-linear mapping ability, enabling accurate prediction of the optimal operating voltage under varying irradiance and temperature conditions. Furthermore, the Deep Q-Network (DQN) algorithm, which integrates reinforcement learning with deep neural networks, was implemented to achieve autonomous learning and optimal decision-making without requiring an explicit PV system model, demonstrating good performance even under complex partial shading scenarios.
Overall, the integration of AI-based algorithms, namely ANN and DQN, formed a key focus of this study, aiming to improve MPPT accuracy, adaptability, and robustness beyond traditional approaches.

5.1. Artificial Neural Network (ANN)

The Artificial Neural Network (ANN) approach leverages its ability to model non-linear systems and recognize patterns to predict the maximum power point (MPP) under varying environmental conditions. The ANN used in this study was trained with irradiance and temperature as input features, while the output was the predicted maximum power point voltage ( V m p ). This prediction served as the reference for a PI controller, which adjusted the duty cycle of the buck converter to drive the PV panel towards the MPP.
The main characteristics of the implemented ANN are summarized in Table 7.

5.1.1. Dataset

To train the Artificial Neural Network (ANN), a comprehensive dataset was generated under realistic photovoltaic (PV) operating conditions, including dynamic variations in irradiance and temperature over a period of 1000 s. The simulation was carried out using a discrete step size of T s = 0.001 s , resulting in a total of one million samples per variable:
N = t total T s = 1000 0.001 = 1,000,000
The time vector was defined as
t = ( 0 : N 1 ) · T s
To ensure representative behavior under Standard Test Conditions (STCs), three time windows (at 200 s, 600 s, and 850 s) were defined with fixed irradiance of 1000 W/m2 and temperature of 25 °C. Outside these intervals, both irradiance and temperature followed sinusoidal functions with added Gaussian noise to emulate natural environmental fluctuations:
G ( t ) = G mean + A G · sin 2 π t T G + N ( 0 , σ G 2 )
T ( t ) = T mean + A T · sin 2 π t T T + N ( 0 , σ T 2 )
where
  • G mean = 500 W / m 2 , A G = 350 W / m 2 , T G = 300 s , σ G = 50 W / m 2 ;
  • T mean = 30 ° C , A T = 15 ° C , T T = 600 s , σ T = 1.5 ° C .
These profiles simulate realistic irradiance oscillations every 5 min and slower temperature drifts every 10 min.
The PV system was simulated (Figure 7) using a resistive load calculated to match the maximum power point (MPP) at STC using the manufacturer specifications:
R = V m p I m p = 36 0.83 43.37 Ω
The temporal evolution of the temperature and irradiance profiles is illustrated in Figure 8.
Table 8 summarizes the main statistics of the temperature and irradiance profiles.
This large and diverse dataset enabled the ANN to learn the non-linear relationship between environmental inputs and the optimal MPP voltage, ensuring good generalization across varying PV conditions.

5.1.2. Training Results of ANN

Figure 9 shows the training results of the ANN. The performance plot (Figure 9a) highlights a best validation performance of 0.94349 at epoch 266, indicating effective convergence. The regression plot (Figure 9b) reveals a strong correlation between predicted and actual values, with a regression coefficient of R = 0.99575 for the test dataset, confirming the model’s ability to generalize. A dataset containing one million samples was used for each variable (irradiance, temperature, V m p , and P m p ), ensuring a broad representation of different operating conditions and enhancing the generalization capability of the ANN.
The trained network is subsequently integrated as a Simulink block within the MPPT control system, as illustrated in Figure 10.
To evaluate the generalization performance of the network, 10 random test samples (10% of the dataset) were selected from the testing dataset. Table 9 combines the real and predicted values for V m p and P m p , along with absolute and relative errors.
It is worth noting that the performance saturation can be primarily attributed to the size of the dataset used for training. With approximately one million samples covering variables such as irradiance, temperature, voltage, and power, the dataset is sufficiently large to ensure that the network effectively learns the mapping between input and output variables. As a result, increasing or decreasing the number of neurons in the hidden layers did not lead to significant improvements in prediction error since the network already achieves good generalization.

5.1.3. ANN Training Under PSC

To enhance the model’s performance and adaptability under PSC, the neural network was retrained using updated datasets that included PSC scenarios. The network architecture remained identical, with two hidden layers comprising 20 and 10 neurons, respectively, while the input layer was expanded to six neurons to accommodate additional input features. Notably, the training algorithm and hyperparameters were kept unchanged to ensure evaluation consistency with the baseline model.
The retrained network was integrated as a Simulink block within the MPPT control system, as illustrated in Figure 11.

5.2. Deep Q-Network (DQN)

Figure 12 presents a simplified block diagram of the Deep Q-Network (DQN) algorithm used for MPPT control in PV systems. It illustrates the key components involved in the agent–environment interaction, including state observation, action selection, Q-value estimation, and policy updating.
The agent receives the system state, comprising the PV voltage, current, duty cycle, and its variation, and evaluates possible actions using a Q-network (a deep neural network). The agent selects the next action using an ε -greedy policy, balancing exploration (random actions) and exploitation (choosing the action with the highest Q-value). This policy is formally defined as follows [10,31]:
a t = arg max a A Q ( s t , a | θ ) with probability 1 ε random ( a t A ) with probability ε
where
  • A is the set of all available actions;
  • ε [ 0 , 1 ] is the exploration rate.
This approach allows the agent to continuously explore new strategies while also exploiting the best-known actions, facilitating learning in complex and high-dimensional environments. The selected action is applied to the PV system by modifying the duty cycle of the buck converter, which changes the operating point of the panel. The environment then moves to a new state and returns a reward that reflects the change in power output resulting from the agent’s action.
In DQN, the traditional Q-table is replaced by a deep neural network (Q-network) to approximate the action-value function Q ( s , a | θ ) , where θ are the network weights. Two networks are used: the predict Q-network (with weights θ ) and the target Q-network (with weights θ ) [10]. The loss function minimized during training is the mean squared error (MSE) between the predicted and target Q-values described in Equation (13) [10,32,33]:
L ( θ ) = E s , a Q target Q predict 2
The target Q-value is computed as
Q target = r reward + γ discount factor max a Q ( s t + 1 , a t + 1 | θ )
And the predicted Q-value from the online network is
Q predict = Q ( s t , a t | θ )
The critic network evaluates the Q-values and calculates the loss, which is used to update the weights of the predict network through backpropagation. Over time, this allows the agent to improve its decision-making, leading to convergence to an optimal policy that maximizes long-term power extraction from the PV system.
Being a model-free method, the DQN agent adapts autonomously to varying conditions, including non-uniform irradiance and PSC, demonstrating strong performance in identifying the GMPP without requiring prior knowledge of the system dynamics.
Additionally, Figure 13 shows the detailed Simulink implementation of the DQN-based MPPT control strategy developed in this study. This model integrates the trained agent within the PV system environment to perform real-time duty cycle adjustments based on learned policies.

5.2.1. Agent Architecture and Reward Function

The Deep Q-Network (DQN) agent used in this work was designed to operate based on three core elements: the state space, the action space, and a multi-objective reward function. These are defined as follows:
  • State Space (S).
The agent observes the system state at each timestep through the following vector:
S = V p v , I p v , D , Δ D
where V p v and I p v are the PV panel voltage and current, D is the duty cycle of the DC/DC converter, and Δ D is the perturbation applied to D.
  • Action Space (A).
The agent can select from a discrete set of actions that modify the duty cycle:
A = { 0.03 , 0.01 , 0.005 , 0.001 , 0 , 0.001 , 0.005 , 0.01 , 0.03 }
These values allow the agent to fine-tune the converter operation in small or large steps, or maintain the current setting.
  • Reward Function (R).
The total reward at each timestep is composed of seven distinct components:
R = r 1 + r 2 + r 3 + r 4 + r 5 + r 6 + r 7
The components are:
  • r 1 : Relative Power (base reward)
    r 1 = P t + 1 P M P P , S T C
    This ensures higher rewards when operating near the GMPP.
  • r 2 : Reward/Penalty for Power Change
    r 2 = P t + 1 P M P P , S T C 2 , Δ P > δ 1 P t + 1 P M P P , S T C 2 , Δ P < δ 1 with δ 1 = 1
  • r 3 : Duty Cycle Limit Penalty
    r 3 = 0 , 0 D 1 1 , otherwise
  • r 4 : Proportional Penalty for Power Drop
    r 4 = Δ P · 5 P M P P , S T C , Δ P < 2 0 , otherwise
  • r 5 : Significant Power Gain Reward
    r 5 = P t + 1 P M P P , S T C , Δ P > 3 0 , otherwise
  • r 6 : Current Stability Reward
    r 6 = + 0.5 , | Δ I | < 0.001 1.5 · | Δ I | , otherwise
  • r 7 : Exponential Reward for Power Stability
    r 7 = α · exp | Δ P | β , | Δ P | < δ 2 0 , otherwise with α = 1.5 , β = 0.05 , δ 2 = 0.005
This multi-component reward function was carefully designed to guide the agent towards fast convergence, stable operation, and global maximum power tracking while penalizing unnecessary oscillations or control saturation.

5.2.2. Simulation Setup

The training of the Deep Q-Network (DQN) agent was conducted in the MATLAB/Simulink environment using the Reinforcement Learning Toolbox [34]. A stochastic training strategy was adopted, where the irradiance and temperature applied to each of the three PV panel segments were randomly varied at the beginning of each episode. This approach ensured generalization of the learned policy across a wide range of environmental conditions, including STC and PSC.
Table 10 summarizes the main parameters used to configure the agent and the training process.

5.2.3. Training Results of DQN

The training process of the DQN agent is depicted in Figure 14, where the light-blue curve represents the episode reward, the dark-blue line indicates the moving average of the reward, and the yellow curve corresponds to the Episode Q0 metric. The Episode Q0 provides an estimation of the expected future reward based on the current policy and is a useful indicator of learning progress.
It is evident that the training converged around episode 100 as the average reward stabilized and episode rewards consistently exceeded the defined performance threshold. The final episode reward and Q0 values confirmed the agent’s ability to maximize the power extracted from the PV system.
A summary of the training performance is presented in Table 11, with hardware specified in Table 12.

5.3. Benchmark Algorithms

To ensure a fair and consistent comparison across all MPPT algorithms evaluated in this study, a common benchmarking strategy was adopted. Table 13 summarizes the key implementation parameters defined for each method, including initial duty cycle, perturbation step size, input variables, and control structure. This standardized setup ensures that observed performance differences are driven by algorithmic behavior rather than configuration disparities.
Additionally, for the hybrid algorithms GA-P&O and GA-InC, a small exponential moving average (EMA) filter was applied to the input measurements of panel voltage and current ( V p v and I p v ) in order to mitigate the effect of high-frequency measurement noise. The filtered signal is computed using Equation (16) [35,36]:
x f ( k ) = α · x ( k ) + ( 1 α ) · x f ( k 1 ) ,
where x represents the measured signals V p v and I p v , and α = 0.01 is the smoothing coefficient. This filtering strategy enhances the stability of the GA-based controllers by providing cleaner input data during operation.

6. Evaluation Metrics

To quantitatively assess the performance of the implemented MPPT algorithms under various operating conditions, six key metrics were employed. These metrics evaluate accuracy, stability, and dynamic response characteristics, providing comprehensive insights into each algorithm’s capabilities.

6.1. Error Metrics

  • Mean Absolute Error (MAE): Measures the average absolute deviation between the PV panel’s input power ( P i n ) and converter output power ( P o u t ):
    MAE = 1 N t = 1 N | P i n ( t ) P o u t ( t ) |
    where N is the number of samples. Lower MAE values indicate better steady-state accuracy.
  • Integral Absolute Error (IAE): Evaluates the cumulative tracking error over time, penalizing persistent deviations:
    IAE = 0 T | P i n ( t ) P o u t ( t ) | d t
    This metric is particularly sensitive to prolonged errors during transient conditions.
  • Mean Squared Error (MSE): Emphasizes larger errors through quadratic penalization:
    MSE = 1 N t = 1 N [ P i n ( t ) P o u t ( t ) ] 2
  • Integral Squared Error (ISE): Combines temporal accumulation with quadratic error weighting:
    ISE = 0 T [ P i n ( t ) P o u t ( t ) ] 2 d t
    ISE is especially relevant for assessing performance under partial shading conditions where large power fluctuations occur.

6.2. Efficiency and Dynamic Response

  • Conversion Efficiency ( η ): Quantifies the energy harvesting capability:
    η = P o u t ¯ P i n ¯ × 100 %
    where P ¯ denotes average power over the simulation period.
  • Convergence Time ( t c o n v ): Determined when the system reaches and maintains steady-state operation, calculated using MATLAB’s lsiminfo function. The threshold (2%) was set to ensure stable power delivery, with validation through moving average analysis of the error signal.

7. Results

Before presenting the performance results of the implemented MPPT algorithms, it is important to outline the methodology used to evaluate their behavior under both uniform and non-uniform operating conditions. The simulation scenarios were carefully designed to replicate realistic environmental profiles, including variable irradiance and temperature, as well as complex PSC. Key performance indicators such as tracking efficiency, convergence time, output power stability, and dynamic adaptability were used as evaluation metrics. This section presents a detailed comparison of conventional methods (P&O and InC), control-logic strategies (FLC), metaheuristic approaches (GA), and artificial intelligence algorithms (ANN and DQN), highlighting their relative strengths and limitations across various operating scenarios.
All the simulations, as well as the training of the ANN and DQN agents, were executed using the hardware configuration detailed in Table 12.

7.1. Scenario 1: Constant Irradiance and Temperature

As shown in Table 14, the ANN achieved the best performance, presenting the lowest MAE and IAE values, combined with the shortest convergence time (0.1763 s). Although DQN recorded a slightly lower MSE, it required more time to converge. Conventional algorithms such as P&O and InC demonstrated higher error metrics and lower average efficiencies, confirming their limitations under stable conditions.
To better visualize the dynamic behavior of the AI-based algorithms, Figure 15 shows the convergence performance of the ANN and DQN during the first 0.5 s of operation. The ANN agent demonstrates faster stabilization and lower initial error compared to the DQN agent.
Additionally, Figure 16 presents the error evolution of all the tested MPPT algorithms up to 0.5 s. It is evident that conventional approaches such as P&O and InC exhibit larger and more persistent oscillations. In contrast, intelligent controllers, particularly ANN and DQN, provide smoother convergence with reduced transient errors.

7.2. Scenario 2: Variable Irradiance and Constant Temperature

According to Table 15, the ANN clearly outperformed the remaining methods, with the lowest absolute and integral errors, as well as the highest efficiency (95.20%). The DQN maintained solid performance but showed higher error variance. Hybrid methods like InC + GA and P&O + GA improved upon their base algorithms, although they still lagged behind the AI-based models in accuracy and responsiveness.

7.3. Scenario 3: Variable Temperature and Constant Irradiance

Table 16 indicates that the ANN and DQN remained among the top-performing algorithms, with efficiencies above 95%. The ANN showed better consistency and robustness to temperature variations, while the DQN delivered competitive results. The fuzzy and hybrid approaches also improved tracking performance, whereas the conventional algorithms exhibited greater instability and error accumulation.

7.4. Scenario 4: Variable Irradiance and Temperature

In Table 17, the ANN once again provided the highest efficiency (94.90%) and fastest convergence time, demonstrating excellent adaptability to combined environmental variations. The DQN also delivered a strong performance, although with slightly higher error metrics. The fuzzy and GA-based hybrids offered moderate improvements over the conventional methods, which struggled to maintain accuracy in dynamic conditions.

7.5. Scenario PSC 1

As presented in Table 18, fuzzy logic and hybrid methods like InC + GA and P&O + GA reached the highest efficiency values (above 96%), with significantly reduced MAE and MSE. The ANN performed well with the fastest convergence time (0.1582 s), while the DQN exhibited slightly higher error values under this moderate shading pattern. The traditional methods showed limited adaptability to PSC conditions.

7.6. Scenario PSC 2

Table 19 highlights the DQN as the most effective algorithm in this severe shading scenario. It recorded the lowest error metrics across all the categories and achieved the highest average efficiency (93.92%). The ANN followed closely, with strong results and fast convergence. The metaheuristic hybrids and fuzzy logic showed improvements but could not match the precision of the AI-based models.

7.7. Scenario PSC 3

As shown in Table 20, InC + GA achieved the best performance, with the lowest MAE (0.0738) and IAE (0.7924), confirming its high precision under dynamic shading. Fuzzy and InC + P&O also maintained excellent efficiency (above 98.5%) with minimal errors. In contrast, the ANN recorded the lowest efficiency (91.42%) and significantly higher error metrics. This lower performance is attributed to the neural network’s limited ability to generalize to the specific irradiance profile of PSC 3, which was underrepresented in the training dataset. Enhancing the ANN performance in this scenario would require expanding or adapting the dataset to better reflect such dynamic conditions. Meanwhile, the DQN demonstrated moderate accuracy (96.28%) but exhibited noticeable tracking fluctuations, indicating reduced control stability in this scenario.

7.8. Scenario PSC 4

Based on the results in Table 21, the ANN provided an excellent trade-off between accuracy and convergence time, achieving 91.75% efficiency with fast response (0.1938 s). The DQN achieved the lowest MSE but at the cost of higher convergence time. Hybrid GA-based methods also performed well, while traditional algorithms like P&O and InC lagged behind with reduced efficiency and greater tracking error.

8. Discussion

The comparative analysis of the MPPT algorithms, summarized in Table 22, highlights distinct strengths and limitations across the different approaches.
Conventional methods such as P&O, InC, and InC+P&O offer simplicity and fast convergence but consistently underperform in dynamic conditions, particularly under partial shading (PSC), where they tend to become trapped in local maxima. Their average efficiencies remained below 85% in PSC scenarios, confirming their limited adaptability.
Fuzzy logic control (FLC) improved upon the traditional methods by providing better stability and slightly higher accuracy. While it showed moderate resilience under variable conditions, its tracking capability in PSC scenarios was still outperformed by more advanced techniques.
AI-based methods, namely ANN and DQN, demonstrated superior overall performance across all the scenarios. These algorithms achieved high average efficiencies (above 91%), fast convergence, and excellent results, even under complex PSC conditions. Their ability to learn and generalize from environmental variations enabled them to reliably track the GMPP.
Hybrid methods combining traditional techniques with genetic algorithms, such as InC + GA and P&O + GA, also yielded notable improvements in accuracy and adaptability. However, these gains came at the cost of increased convergence time due to the computational overhead of evolutionary optimization.
Overall, the results reinforce the effectiveness of AI-based and hybrid strategies for MPPT, particularly in challenging and rapidly changing operating environments.

9. Conclusions

This work demonstrates the effectiveness of intelligent control strategies, particularly Artificial Neural Networks (ANNs) and Deep Q-Networks (DQNs), in enhancing the performance of photovoltaic systems through MPPT optimization. The implemented MATLAB/Simulink models, which simulated both uniform and partial shading scenarios, provide a robust framework for comparative analysis. The results show that AI-based methods not only achieved superior tracking efficiency and faster convergence times but also exhibited greater resilience to dynamic changes and adaptability to non-linear environmental conditions. Among all the tested algorithms, the DQN agent consistently outperformed the others in PSC scenarios, confirming its ability to identify the GMPP more effectively. These findings underscore the potential of integrating learning-based controllers into PV systems to improve energy harvesting in real-world applications.
A natural progression of this research involves the integration of a bidirectional DC/DC converter, specifically a buck–boost topology, which would enable both the charging and discharging of an energy storage system. This architecture would facilitate the transition from a passive PV system to a hybrid energy management solution capable of supplying loads autonomously during periods of low solar generation.
Additionally, future work could focus on the experimental validation of the proposed MPPT algorithms under real-world operating conditions. This would involve developing a physical prototype that integrates photovoltaic panels, bidirectional converters, embedded controllers (e.g., microcontrollers), and appropriate sensors for current, voltage, irradiance, and temperature measurement. Implementing the control logic directly in embedded hardware would allow for the assessment of real-time performance, computational constraints, and resilience to disturbances, such as measurement noise or sudden environmental changes.
Another promising research direction includes the development of hybrid renewable energy systems, combining solar and wind energy sources under a unified control framework. The MPPT algorithms could be extended or adapted to coordinate multiple energy sources with complementary profiles, enhancing system reliability and reducing energy intermittency.

Author Contributions

Conceptualization, J.T.S. and R.S.B.; methodology, J.T.S. and R.S.B.; software, J.T.S.; validation, J.T.S. and R.S.B.; formal analysis, J.T.S.; investigation, J.T.S.; writing—original draft preparation, J.T.S.; writing—review and editing, J.T.S. and R.S.B.; visualization, J.T.S.; supervision, R.S.B. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

The original contributions presented in this study are included in the article. Further inquiries can be directed to the corresponding author.

Conflicts of Interest

The authors declare no conflicts of interest.

Abbreviations

The following abbreviations are used in this manuscript:
PVPhotovoltaic
MPPMaximum Power Point
MPPTMaximum Power Point Tracking
CCMContinuous Conduction Mode
PSCPartial Shading Condition
PWMPulse Width Modulation
STCsStandard Test Conditions
DQNDeep Q-Network
ANNArtificial Neural Network
RLReinforcement Learning
DRLDeep Reinforcement Learning
GAGenetic Algorithm
FLCFuzzy Logic Controller
P&OPerturb and Observe
InCIncremental Conductance
GMPPGlobal Maximum Power Point
VpvPV Panel Voltage
IpvPV Panel Current
GIrradiance
TTemperature
LLoss Function
aAction Taken by the Agent
rImmediate Reward Received
sObserved State
θ Weight Matrix of the Q-Network
γ Discount Factor for Future Rewards
ε Exploration Rate in ε -Greedy Policy

References

  1. Joshi, P.; Rao, A.B.; Banerjee, R. Review of solar PV deployment trends, policy instruments, and growth projections in China, the United States, and India. Renew. Sustain. Energy Rev. 2025, 213, 115436. [Google Scholar] [CrossRef]
  2. Endiz, M.S.; Gökkuş, G.; Coşgun, A.E.; Demir, H. A Review of Traditional and Advanced MPPT Approaches for PV Systems Under Uniformly Insolation and Partially Shaded Conditions. Appl. Sci. 2025, 15, 1031. [Google Scholar] [CrossRef]
  3. Elbarbary, Z.M.S.; Alranini, M.A. Review of maximum power point tracking algorithms of PV system. Front. Eng. Built Environ. 2021, 1, 68–80. [Google Scholar] [CrossRef]
  4. Worku, M.Y.; Hassan, M.A.; Maraaba, L.S.; Shafiullah, M.; Elkadeem, M.R.; Hossain, M.I.; Abido, M.A. A Comprehensive Review of Recent Maximum Power Point Tracking Techniques for Photovoltaic Systems under Partial Shading. Sustainability 2023, 15, 11132. [Google Scholar] [CrossRef]
  5. J, K.; SY, F. Modeling of a Photovoltaic Array in MATLAB Simulink and Maximum Power Point Tracking Using Neural Network. J. Electr. Amp; Electron. Syst. 2018, 7, 263. [Google Scholar] [CrossRef]
  6. Giraldo, L.F.; Gaviria, J.F.; Torres, M.I.; Alonso, C.; Bressan, M. Deep reinforcement learning using deep-Q-network for Global Maximum Power Point tracking: Design and experiments in real photovoltaic systems. Heliyon 2024, 10, e37974. [Google Scholar] [CrossRef] [PubMed]
  7. Kofinas, P.; Doltsinis, S.; Dounis, A.; Vouros, G. A reinforcement learning approach for MPPT control method of photovoltaic sources. Renew. Energy 2017, 108, 461–473. [Google Scholar] [CrossRef]
  8. Bag, A.; Subudhi, B.; Ray, P.K. A Combined Reinforcement Learning and Sliding Mode Control Scheme for Grid Integration of a PV System. CSEE J. Power Energy Syst. 2019, 5, 498–506. [Google Scholar] [CrossRef]
  9. Bavarinos, K.; Dounis, A.; Kofinas, P. Maximum Power Point Tracking Based on Reinforcement Learning Using Evolutionary Optimization Algorithms. Energies 2021, 14, 335. [Google Scholar] [CrossRef]
  10. Phan, B.C.; Lai, Y.C.; Lin, C.E. A Deep Reinforcement Learning-Based MPPT Control for PV Systems under Partial Shading Condition. Sensors 2020, 20, 3039. [Google Scholar] [CrossRef]
  11. Remoaldo, D.; Jesus, I. Analysis of a Traditional and a Fuzzy Logic Enhanced Perturb and Observe Algorithm for the MPPT of a Photovoltaic System. Algorithms 2021, 14, 24. [Google Scholar] [CrossRef]
  12. Katche, M.L.; Makokha, A.B.; Zachary, S.O.; Adaramola, M.S. A Comprehensive Review of Maximum Power Point Tracking (MPPT) Techniques Used in Solar PV Systems. Energies 2023, 16, 2206. [Google Scholar] [CrossRef]
  13. Rezk, H.; Fathy, A.; Abdelaziz, A.Y. A comparison of different global MPPT techniques based on meta-heuristic algorithms for photovoltaic system subjected to partial shading conditions. Renew. Sustain. Energy Rev. 2017, 74, 377–386. [Google Scholar] [CrossRef]
  14. Al-Majidi, S.D.; Abbod, M.F.; Al-Raweshidy, H.S. A novel maximum power point tracking technique based on fuzzy logic for photovoltaic systems. Int. J. Hydrogen Energy 2018, 43, 14158–14171. [Google Scholar] [CrossRef]
  15. Belhachat, F.; Larbes, C. Global maximum power point tracking based on ANFIS approach for PV array configurations under partial shading conditions. Renew. Sustain. Energy Rev. 2017, 77, 875–889. [Google Scholar] [CrossRef]
  16. Mumtaz, S.; Ahmad, S.; Khan, L.; Ali, S.; Kamal, T.; Hassan, S. Adaptive Feedback Linearization Based NeuroFuzzy Maximum Power Point Tracking for a Photovoltaic System. Energies 2018, 11, 606. [Google Scholar] [CrossRef]
  17. Shaiek, Y.; Ben Smida, M.; Sakly, A.; Mimouni, M.F. Comparison between conventional methods and GA approach for maximum power point tracking of shaded solar PV generators. Sol. Energy 2013, 90, 107–122. [Google Scholar] [CrossRef]
  18. Ahmed, J.; Salam, Z. A Maximum Power Point Tracking (MPPT) for PV system using Cuckoo Search with partial shading capability. Appl. Energy 2014, 119, 118–130. [Google Scholar] [CrossRef]
  19. Titri, S.; Larbes, C.; Toumi, K.Y.; Benatchba, K. A new MPPT controller based on the Ant colony optimization algorithm for Photovoltaic systems under partial shading conditions. Appl. Soft Comput. 2017, 58, 465–479. [Google Scholar] [CrossRef]
  20. Benyoucef, A.s.; Chouder, A.; Kara, K.; Silvestre, S.; sahed, O.A. Artificial bee colony based algorithm for maximum power point tracking (MPPT) for PV systems operating under partial shaded conditions. Appl. Soft Comput. 2015, 32, 38–48. [Google Scholar] [CrossRef]
  21. Kaced, K.; Larbes, C.; Ramzan, N.; Bounabi, M.; Dahmane, Z.e. Bat algorithm based maximum power point tracking for photovoltaic system under partial shading conditions. Sol. Energy 2017, 158, 490–503. [Google Scholar] [CrossRef]
  22. Yang, B.; Zhong, L.; Zhang, X.; Shu, H.; Yu, T.; Li, H.; Jiang, L.; Sun, L. Novel bio-inspired memetic salp swarm algorithm and application to MPPT for PV systems considering partial shading condition. J. Clean. Prod. 2019, 215, 1203–1222. [Google Scholar] [CrossRef]
  23. Jiang, L.L.; Srivatsan, R.; Maskell, D.L. Computational intelligence techniques for maximum power point tracking in PV systems: A review. Renew. Sustain. Energy Rev. 2018, 85, 14–45. [Google Scholar] [CrossRef]
  24. Lu, D.; Hu, D.; Wang, J.; Wei, W.; Zhang, X. A Data-Driven Vehicle Speed Prediction Transfer Learning Method With Improved Adaptability Across Working Conditions for Intelligent Fuel Cell Vehicle. IEEE Trans. Intell. Transp. Syst. 2025, 26, 10881–10891. [Google Scholar] [CrossRef]
  25. Aizenberg, I.; Tovt, Y. Intelligent Frequency Domain Image Filtering Based on a Multilayer Neural Network with Multi-Valued Neurons. Algorithms 2025, 18, 461. [Google Scholar] [CrossRef]
  26. Sharma, A.K.; Pachauri, R.K.; Choudhury, S.; Minai, A.F.; Alotaibi, M.A.; Malik, H.; Márquez, F.P.G. Role of Metaheuristic Approaches for Implementation of Integrated MPPT-PV Systems: A Comprehensive Study. Mathematics 2023, 11, 269. [Google Scholar] [CrossRef]
  27. Nunes, H.G.G.; Morais, F.A.L.; Pombo, J.A.N.; Mariano, S.J.P.S.; Calado, M.R.A. Bypass diode effect and photovoltaic parameter estimation under partial shading using a hill climbing neural network algorithm. Front. Energy Res. 2022, 10, 837540. [Google Scholar] [CrossRef]
  28. SOLARPOWER 30W 24V. Available online: https://www.xunzel.com/store/en/producto/solarpower-30w-24v/ (accessed on 25 March 2025).
  29. Laboratory Manual for Pulse-Width Modulated DC-DC Power Converters [Second Edition] 9781119009597, 1119009596, 9781119052753, 1119052750, 9781119009542. Available online: https://dokumen.pub/laboratory-manual-for-pulse-width-modulated-dc-dc-power-converters-second-edition-9781119009597-1119009596-9781119052753-1119052750-9781119009542.html (accessed on 29 March 2025).
  30. Basic Calculation of a Buck Converter’s Power Stage (Rev. B)-slva477b. Available online: https://www.ti.com/lit/an/slva477b/slva477b.pdf?ts=1740369413739&ref_url=https%253A%252F%252Fwww.google.com%252F (accessed on 3 April 2025).
  31. Dirani, M.; Altman, Z.; Salaun, M. Chapter 7—Autonomics in Radio Access Networks. Auton. Radio Access Netw. 2011, 141–166. [Google Scholar] [CrossRef]
  32. Lillicrap, T.P.; Hunt, J.J.; Pritzel, A.; Heess, N.; Erez, T.; Tassa, Y.; Silver, D.; Wierstra, D. Continuous control with deep reinforcement learning. arXiv 2015. [Google Scholar] [CrossRef]
  33. Wu, J.; He, H.; Peng, J.; Li, Y.; Li, Z. Continuous reinforcement learning of energy management with deep Q network for a power split hybrid electric bus. Appl. Energy 2018, 222, 799–811. [Google Scholar] [CrossRef]
  34. MathWorks. Deep Q-Network (DQN) Agent - MATLAB & Simulink. 2023. Available online: https://www.mathworks.com/help/reinforcement-learning/ug/dqn-agents.html (accessed on 4 May 2025).
  35. Martins, J.; Spataru, S.; Sera, D.; Stroe, D.I.; Lashab, A. Comparative Study of Ramp-Rate Control Algorithms for PV with Energy Storage Systems. Energies 2019, 12, 1342. [Google Scholar] [CrossRef]
  36. Tajiri, H.; Kumano, T. Input filtering of MPPT control by exponential moving average in photovoltaic system. In Proceedings of the 2012 IEEE International Conference on Power and Energy (PECon), Kota Kinabalu, Malaysia, 2–5 December 2012; pp. 372–377. [Google Scholar] [CrossRef]
Figure 1. PV MPPT control architecture: (a) Simulink model of the PV system; (b) block diagram of the MPPT control structure.
Figure 1. PV MPPT control architecture: (a) Simulink model of the PV system; (b) block diagram of the MPPT control structure.
Algorithms 18 00493 g001
Figure 2. Simulink models: (a) PV system with three groups of series-connected photovoltaic cells; (b) demonstration of bypass diode operation during PSC [27].
Figure 2. Simulink models: (a) PV system with three groups of series-connected photovoltaic cells; (b) demonstration of bypass diode operation during PSC [27].
Algorithms 18 00493 g002
Figure 3. I–V and P–V curves of the SOLARPOWER 30W 24V module.
Figure 3. I–V and P–V curves of the SOLARPOWER 30W 24V module.
Algorithms 18 00493 g003
Figure 4. DC/DC buck converter.
Figure 4. DC/DC buck converter.
Algorithms 18 00493 g004
Figure 5. Non-PSC operating conditions: (a) Case 1, (b) Case 2, (c) Case 3, and (d) Case 4 from Table 4.
Figure 5. Non-PSC operating conditions: (a) Case 1, (b) Case 2, (c) Case 3, and (d) Case 4 from Table 4.
Algorithms 18 00493 g005
Figure 6. Partial shading conditions: (ad) corresponding to Cases 1–4 in Table 5.
Figure 6. Partial shading conditions: (ad) corresponding to Cases 1–4 in Table 5.
Algorithms 18 00493 g006
Figure 7. Simulink model for dataset generation under dynamic environmental conditions.
Figure 7. Simulink model for dataset generation under dynamic environmental conditions.
Algorithms 18 00493 g007
Figure 8. Temporal evolution of environmental variables used in the dataset generation: (a) temperature profile and (b) irradiance profile.
Figure 8. Temporal evolution of environmental variables used in the dataset generation: (a) temperature profile and (b) irradiance profile.
Algorithms 18 00493 g008
Figure 9. Performance of the ANN during training: (a) training performance (best validation = 0.94349 at epoch 266) and (b) training regression ( R = 0.99575 for test data).
Figure 9. Performance of the ANN during training: (a) training performance (best validation = 0.94349 at epoch 266) and (b) training regression ( R = 0.99575 for test data).
Algorithms 18 00493 g009
Figure 10. Simulink model of the implemented ANN for MPPT control.
Figure 10. Simulink model of the implemented ANN for MPPT control.
Algorithms 18 00493 g010
Figure 11. Simulink model used under PSC conditions.
Figure 11. Simulink model used under PSC conditions.
Algorithms 18 00493 g011
Figure 12. Block diagram of the DQN algorithm, showing interaction between environment, critic network, and policy updating.
Figure 12. Block diagram of the DQN algorithm, showing interaction between environment, critic network, and policy updating.
Algorithms 18 00493 g012
Figure 13. Simulink implementation of the DQN-based MPPT control strategy.
Figure 13. Simulink implementation of the DQN-based MPPT control strategy.
Algorithms 18 00493 g013
Figure 14. Training process of the DQN method over 300 episodes.
Figure 14. Training process of the DQN method over 300 episodes.
Algorithms 18 00493 g014
Figure 15. Comparison of convergence behavior between ANN and DQN in Scenario 1.
Figure 15. Comparison of convergence behavior between ANN and DQN in Scenario 1.
Algorithms 18 00493 g015
Figure 16. Error evolution up to 0.5 s for all algorithms in Scenario 1.
Figure 16. Error evolution up to 0.5 s for all algorithms in Scenario 1.
Algorithms 18 00493 g016
Table 1. Specifications of the SOLARPOWER-XUNZEL-30W-24V photovoltaic panel [28].
Table 1. Specifications of the SOLARPOWER-XUNZEL-30W-24V photovoltaic panel [28].
ParameterValue
Maximum power ( P m a x )29.88 W
Number of cells per module ( N c e l l )72
Open-circuit voltage ( V o c )43.20 V
Short-circuit current ( I s c )0.92 A
Voltage at maximum power point ( V m p p )36.00 V
Current at maximum power point ( I m p p )0.83 A
Temperature coefficient of voltage ( β V o c )−0.27 %/°C
Temperature coefficient of current ( α I s c )+0.05 %/°C
Temperature coefficient of power ( α P s c )−0.35 %/°C
Table 2. Calculated PV system operating parameters.
Table 2. Calculated PV system operating parameters.
ParameterValue
Input voltage ( V i n )36 V
Output voltage ( V o u t )20 V
Input power ( P i n )29.88 W
Output power ( P o u t )26.89 W
Converter efficiency ( η )90%
MPP current ( I m p p )0.83 A
Output current ( I o u t )1.34 A
Load resistance ( R o )14.88  Ω
Table 3. Theoretical buck converter parameters used in simulations.
Table 3. Theoretical buck converter parameters used in simulations.
ComponentCalculated ValueSimulation Purpose
Duty cycle (D)0.555(5)Fundamental conversion ratio for ideal voltage step-down
Inductor ( L o )1658.71 µHMinimum value to maintain CCM at Δ I = 0.268 A
Capacitor ( C o )1675 µFExact value to achieve Δ V = 1 mV ripple
Switching freq. ( f s )20 kHzBalance between switching losses and dynamics
Current ripple ( Δ I )0.268 A20% of I o u t for stable MPPT operation
Voltage ripple ( Δ V )1 mV0.005% of V o u t for algorithm precision
Table 4. PV panel scenarios with single bypass diode.
Table 4. PV panel scenarios with single bypass diode.
CaseScenario DescriptionFixed Parameters
1Uniform irradiance (1000 W/m2)T = 25 °C
2Variable irradiance (G)T = 25 °C
3Variable temperature (T)G = 1000 W/m2
4Simultaneous G and T variation
Table 5. PSC with three bypass diodes.
Table 5. PSC with three bypass diodes.
CasePSC ConfigurationFixed Parameters
1G = [900, 1000, 200] W/m2T = 25 °C
2G = [200, 400, 300] W/m2T = 25 °C
3G = [900, 100, 150] W/m2T = 25 °C
4G = [300, 200, 100] W/m2T = 25 °C
Table 6. Classification of MPPT algorithms implemented in this study.
Table 6. Classification of MPPT algorithms implemented in this study.
ClassSubclassAcronym
Conventional AlgorithmsPerturb and ObserveP&O
Incremental ConductanceInC
Control Logic-Based AlgorithmFuzzy Logic ControllerFLC
Artificial Intelligence AlgorithmsArtificial Neural NetworkANN
Deep Reinforcement LearningDQN
Hybrid AlgorithmsInC combined with P&OInC + P&O
GA combined with InCGA + InC
GA combined with P&OGA + P&O
Table 7. Architecture and training parameters of the implemented ANN.
Table 7. Architecture and training parameters of the implemented ANN.
Component DetailsRemarks
Input Layer2 neuronsIrradiance and temperature
Hidden Layers1st: 20 neurons (tansig) 2nd: 10 neurons (tansig)Hyperbolic tangent sigmoid activation function
Output Layer2 neurons (purelin) V m p and P m p with linear activation
Training AlgorithmLevenberg-Marquardt (trainlm)Implemented using fitnet in MATLAB
Data Division75% training 15% validation 10% testingEnsures generalization and performance evaluation
Table 8. Statistical summary of environmental variables.
Table 8. Statistical summary of environmental variables.
ParameterTemperature (°C)Irradiance (W/m²)
Number of Samples1,000,0001,000,000
Mean31.09583.44
Standard Deviation10.11272.92
Minimum15.001.00
Maximum45.001000.00
Table 9. Real and predicted values of V m p and P m p , with respective absolute and relative errors.
Table 9. Real and predicted values of V m p and P m p , with respective absolute and relative errors.
Test Pt.Irrad.Temp. V mp Pred.Abs. Err.Rel. Err. P mp Pred.Abs. Err.Rel. Err.
(W/m2)(°C)(V)(V)(V)(%)(W)(W)(W)(%)
1477.2131.5818.2018.560.362.007.647.940.303.94
2163.7123.196.526.440.081.250.980.960.022.13
3597.2343.7322.7923.140.351.5411.9712.340.373.06
4433.1042.5616.7116.990.281.706.446.650.223.35
5868.9918.4532.6632.730.060.1924.6024.700.100.41
6531.0632.9520.6020.580.020.079.789.780.0010.01
7797.5117.3230.5230.010.501.6521.4720.760.713.29
8856.8523.4232.9432.470.471.4325.0124.320.702.78
9883.1043.1033.5833.150.431.2725.9925.420.582.22
10294.7744.7211.8011.660.131.133.213.140.072.22
Table 10. DQN agent configuration parameters.
Table 10. DQN agent configuration parameters.
ParameterValue
Simulation time per episode0.5 s
Agent sample time0.01 s
Maximum number of episodes300
Steps per episode50
Discount factor0.9
Mini-batch size64
Experience buffer length 1 × 10 6
Initial exploration rate ( ε )1.0
Minimum exploration rate0.001
Exploration decay rate0.0001
Double DQNEnabled
Critic optimizerAdam
Critic learning rate0.0001
Policy for saving agentEpisode reward ≥ 150
Stopping criterionAverage reward ≥ 10,000
Parallel trainingDisabled
Table 11. Summary of the training performance for the DQN agent.
Table 11. Summary of the training performance for the DQN agent.
MetricValue
Mean reward per episode28.73
Final episode reward11.74
Episode Q03.89
Average steps per episode50
Total agent steps15,000
Total training time2 h 3 min
Table 12. Specifications of the hardware used for simulations and training of ANN and DQN agents.
Table 12. Specifications of the hardware used for simulations and training of ANN and DQN agents.
ComponentSpecification
PC ModelHP ProDesk 600 G4 Mini PC
ProcessorIntel® CoreTM i7-7700T CPU @ 2.90 GHz
RAM16 GB DDR4 2400 MHz
Storage512 GB SSD
Operating SystemWindows 10 Pro 64-bit
Integrated GPUIntel® HD Graphics 630
Parallel computingDisabled
GPU accelerationDisabled
Table 13. Benchmarking configuration for MPPT algorithms.
Table 13. Benchmarking configuration for MPPT algorithms.
AlgorithmStep Size Δ Initial Duty ( D init ) Bounds D min / D max Training RequiredDynamic TuningMain Inputs
P&O0.0001250.55550 / 1NoFixed Δ V p v , I p v
InC0.0001250.55550 / 1NoFixed Δ V p v , I p v
FLCNot applicableNot defined0 / 1NoImplicit (fuzzy rules) V p v , I p v
InC + P&O0.0001250.55550 / 1NoThreshold switching ( | d V | > 5 × 10 4 V) V p v , I p v
InC + GA[0.00005, 0.0002]0.55550 / 1NoGA-optimized Δ V p v , I p v
P&O + GA[0.00005, 0.0002]0.55550 / 1NoGA-optimized Δ V p v , I p v
Table 14. Performance metrics for Scenario 1 (uniform irradiance at 1000 W/m²).
Table 14. Performance metrics for Scenario 1 (uniform irradiance at 1000 W/m²).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O2.274023.64698.445696.781593.60130.2029
InC2.268123.64538.422496.768793.62610.2029
Fuzzy1.302813.56643.485745.563095.37130.2385
InC + P&O2.275523.64868.451296.788993.59620.2030
InC + GA1.314413.63702.762933.881295.31020.3783
P&O + GA1.312413.64432.756133.860195.31650.3787
ANN1.293113.44243.386545.596595.49950.1763
DQN1.339614.24252.768143.011995.29810.2118
Table 15. Performance metrics for Scenario 2 (variable irradiance conditions).
Table 15. Performance metrics for Scenario 2 (variable irradiance conditions).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O2.013420.73507.160381.763792.49910.2008
InC2.033320.72827.232281.732792.37350.2008
Fuzzy1.282013.30913.524344.962094.21800.2370
InC + P&O1.995720.76197.085781.877092.68080.2010
InC + GA1.311313.57633.290938.660694.07370.3749
P&O + GA1.310013.55863.261738.342094.07720.3892
ANN0.94269.94332.706938.835195.20380.1837
DQN1.379614.18813.549542.886993.77600.2316
Table 16. Performance metrics for Scenario 3 (variable temperature conditions).
Table 16. Performance metrics for Scenario 3 (variable temperature conditions).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O2.290123.50398.490395.916393.56440.2026
InC2.302023.49608.545295.873893.49190.2026
Fuzzy1.291413.43043.458845.261895.40240.2389
InC + P&O2.273723.52718.413496.035193.66650.2027
InC + GA1.303613.51252.906235.257595.33840.3754
P&O + GA1.304013.51212.949135.642395.33670.3759
ANN1.358614.10223.543047.381895.15030.1773
DQN1.349914.24182.961243.015695.18820.2017
Table 17. Performance metrics for Scenario 4 (combined variable irradiance and temperature conditions).
Table 17. Performance metrics for Scenario 4 (combined variable irradiance and temperature conditions).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O1.908019.51596.328771.383392.34180.1937
InC1.883219.54116.234871.487992.57290.1937
Fuzzy1.226412.69953.066938.768994.05410.2303
InC + P&O1.923219.51316.379471.369492.22900.1937
InC + GA1.261013.00402.842233.073893.86700.3717
P&O + GA1.256112.99482.841433.187493.88600.3747
ANN0.82278.82442.172934.334894.89670.1746
DQN1.335113.85482.898738.892093.20060.2272
Table 18. Performance metrics for Scenario PSC 1 (partial shading conditions).
Table 18. Performance metrics for Scenario PSC 1 (partial shading conditions).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O1.247012.79902.461627.070294.39090.2261
InC1.247412.80192.462527.076294.38900.2254
Fuzzy0.62446.46070.893711.105496.30350.1891
InC + P&O1.247312.80122.462327.075894.38970.2259
InC + GA0.63626.57980.76849.571396.21990.4076
P&O + GA0.63616.58060.76369.521896.22090.4116
ANN0.75407.82100.984013.858394.70470.1582
DQN0.91749.11211.514016.258093.01040.1973
Table 19. Performance metrics for Scenario PSC 2 (severe partial shading conditions).
Table 19. Performance metrics for Scenario PSC 2 (severe partial shading conditions).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O1.084311.52101.925322.445183.59140.4561
InC1.122011.51382.007122.428282.94410.4557
Fuzzy1.003610.45731.313615.513084.06600.9092
InC + P&O1.092911.52571.940522.459383.43410.4559
InC + GA0.61626.33350.42834.747489.32520.5825
P&O + GA0.61606.33090.43084.767689.32850.5809
ANN0.51155.29310.38104.991692.76580.1816
DQN0.20142.00170.06450.628193.91540.2866
Table 20. Performance metrics for Scenario PSC 3 (dynamic partial shading conditions).
Table 20. Performance metrics for Scenario PSC 3 (dynamic partial shading conditions).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O0.10141.07730.06270.899398.50420.1958
InC0.10171.07960.06280.899698.50040.1958
Fuzzy0.09771.03850.06330.902398.55540.1988
InC + P&O0.09831.03690.06230.893898.54810.1933
InC + GA0.07380.79240.05490.824598.82310.5854
P&O + GA0.10841.13560.05980.873398.33240.5760
ANN0.25252.58860.09831.370791.42060.4003
DQN0.25592.59000.13701.550196.28220.2341
Table 21. Performance metrics for Scenario PSC 4 (extreme partial shading conditions).
Table 21. Performance metrics for Scenario PSC 4 (extreme partial shading conditions).
AlgorithmMAEIAEMSEISEAvg. Eff. (%)Conv. Time (s)
P&O0.58296.17570.56576.403185.54960.3757
InC0.59596.17270.57906.399185.18470.3751
Fuzzy0.55325.64500.38084.132085.68710.5335
InC + P&O0.60646.17110.58996.396484.89870.3748
InC + GA0.19882.02260.04790.523991.95300.4035
P&O + GA0.19922.02770.05150.559991.93490.4025
ANN0.20532.09800.05380.634891.74990.1938
DQN0.20432.03520.05960.590991.62150.9375
Table 22. Comparison of MPPT algorithms.
Table 22. Comparison of MPPT algorithms.
AlgorithmEvaluation Criteria
Compl.CostParam. Ind.TrainingConv. SpeedSensorsTuningStabilityPSC
P&OLowMediumYesNoFastV,INoLowWeak
InCMediumMediumYesNoFastV,INoLowWeak
FLCHighMediumYesNoFastV,INoHighGood
InC + P&OMediumMediumYesNoFastV,INoLowWeak
InC + GAHighHighYesNoSlowV,INoMediumV.Good
P&O + GAHighHighYesNoSlowV,INoMediumV.Good
ANNHighHighNoYesV.FastV,I,G,TYesHighExc.
DQN (RL)HighHighNoYesFastV,I,G,TYesHighExc.
Notes: Abbrev.: Compl. = Complexity, Param. Ind. = Parameter Independence, Conv. Speed = Convergence Speed, Sensors; Stability: Low (oscillations), Medium (small variations), High (stable); PSC: Weak (oscillations), Mod. (moderate), Good, V.Good, Exc. (Excellent); Sensors: V = Voltage, I = Current, G = Irradiance, T = Temperature.
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Sousa, J.T.; Barbosa, R.S. Comparison of Classical and Artificial Intelligence Algorithms to the Optimization of Photovoltaic Panels Using MPPT. Algorithms 2025, 18, 493. https://doi.org/10.3390/a18080493

AMA Style

Sousa JT, Barbosa RS. Comparison of Classical and Artificial Intelligence Algorithms to the Optimization of Photovoltaic Panels Using MPPT. Algorithms. 2025; 18(8):493. https://doi.org/10.3390/a18080493

Chicago/Turabian Style

Sousa, João T., and Ramiro S. Barbosa. 2025. "Comparison of Classical and Artificial Intelligence Algorithms to the Optimization of Photovoltaic Panels Using MPPT" Algorithms 18, no. 8: 493. https://doi.org/10.3390/a18080493

APA Style

Sousa, J. T., & Barbosa, R. S. (2025). Comparison of Classical and Artificial Intelligence Algorithms to the Optimization of Photovoltaic Panels Using MPPT. Algorithms, 18(8), 493. https://doi.org/10.3390/a18080493

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop