Controller optimization for a solar tracking system using differential evolution

Optimización de un controlador para un sistema de seguimiento solar mediante la evolución diferencial

Helbert Eduardo Espitia Cuchango1, Fabio Emiro Sierra Vargas2*

1 Universidad Distrital Francisco José de Caldas, Bogotá, Colombia,
2 Universidad Nacional de Colombia, Bogotá, Colombia,

* Corresponding Author. Tel: +57 (1) 3165000 Ext. 11130 E-mail:

How to cite: Espitia, H.; Sierra, F., Controller optimization for a solar tracking system using differential evolution, TECCIENCIA, Vol. 7 No. 18., 7-13, 2015, DOI:

Received: 16 Jan. 2015 Accepted: 26 Feb 2015 Available Online: 20 April 2015


This paper details the design and implementation of two analog controllers for the solar tracker located in the thermal power plant laboratory at the Universidad Nacional de Colombia. In this study we used differential evolution for the optimization of the controllers. In addition to the design of the controllers, it is possible with this approach to observe the characteristics of this bio-inspired algorithm. As a result, we first present the optimization process and subsequently the dynamic response of the controllers implemented.

Keywords: differential evolution, control, optimization, solar power.


Este artículo detalla el diseno y la implementación de dos controladores análogos para un rastreador solar localizado en el laboratorio de plantas térmicas en la Universidad Nacional de Colombia. En este estudio se utilizó la evolución diferencial para la optimización de los controladores. Además del diseño de los controladores es posible con este enfoque observar las características de este algoritmo bioinspirado. Como resultado primero presentamos la optimización del proceso y posteriormente la respuesta dinámica del controlador implementado.

Palabras Clave: Evolución diferencial, Control, optimización, Energía Solar.

1. Introduction

Solar energy is one of the cleanest alternative sources of energy. Yet to extract this resource, a solar tracking system is needed due to its ability to capture as much solar energy as possible at any given moment [1]. It is important to note, however, that poor tracking of the sun performed by this device decreases the amount of energy that can be captured during the day [1] [2] [3] [4] [5]

In this paper, we seek to design and implement an analog controller for the solar tracking system at the thermal power plant laboratory of the Universidad Nacional de Colombia. In previous studies, design was based on genetic algorithms and particle swarm optimization [6], [7]. For this study, we employ a variation of genetic algorithm called "differential evolution." The aim is to observe the application of this bio-inspired optimization technique on a real design problem, and furthermore to provide other alternatives for the implementation of the solar tracking system controller.

1.1. Solar tracking system

The physical configuration of the solar tracking system is shown in Figure 1. The system essentially consists of a parabolic reflector fitted to an axis on which a motor exerts movement.

This tracking system belongs to the thermal power plant laboratory at the Universidad Nacional de Colombia and is part of a set of equipment for the exploitation of solar energy.

Other equipment that is being developed and which is expected to obtain better results includes an experimental modulus designed by the clean development mechanisms and energy management investigation group (spanish acronym: mdlyge) at the Universidad Nacional de Colombia. The experimental solar tracking system can be seen in Figure 2

Control of the prototype is performed digitally through the micro-controller pic16f877a, of the microchip family. This prototype contains limit sensors to prevent the reflector from deviating from its normal route. In addition to automatic mode, there is a manual operation mode which is controlled by two switches, allowing positive and negative rotation.

1.2. Bio-inspired optimization

Nowadays, different optimization algorithms are based on behavior observed in nature. These algorithms, referred to as bio-inspired, have been proposed as an alternative to traditional optimization methods. The process of foraging, as performed by living beings, is an example of the behaviors which can be used as references for the development of optimization algorithms [8]. Notably, good techniques for finding meals bestow the being with survival advantages, which is precisely what an optimization algorithm seeks [8].

In regard to algorithms based on individual congregations, one of the techniques of bio-inspired optimization is based on the behavior of ants [9] [10] [11]. Behaviors present in bee colonies are also taken into account to solve problems of research and exploration [12] Other optimization algorithms with this focus have been inspired by swarms of animals such as birds and fish, spawning optimization based on particle swarm. Meanwhile, genetic algorithms and differential evolution attempt to emulate nature's process in improving a species over time [13].

1.3. Optimization based on differential evolution

The algorithm of differential evolution (de) was originally proposed by storm and price [14] [15]. This is an evolutionary algorithm specializing in the mutation process through a differential operator. After performing the mutation, a cross or recombination process also takes place. Mutation, recombination and selection processes are performed to meet specific criteria of completion, such as the maximum number of generations or until a desired value for the objective function is reached. In order to apply the differential operator, this algorithm requires each individual to have a codification associated with real values related directly to the objective function.

Figure 3 shows the flowchart of the algorithm of differential evolution and the stages involved.

Population is initiated randomly (first generation), taking into account the minimum and maximum values of each variable. Through the operator of differential mutation, a proportional difference of two individuals(q1, q2) selected randomly from the population is added to a third individual q3. As a result of the previous process, there is now an individua pi, corresponding to a new mutated individual:

Through a mutation constant µ > 0 a differentiation rank between individuals is established in order to avoid stagnancy in the search process. After mutation occurs, a recombination operation is performed on each individual qi to generate an individual ui, which is constructed by mixing pi and qi components, using the following equation:

Where: Pε[0.1] is a predefined value of probability. In the final part of the algorithm, the selection operator is applied, considering the improvement obtained from of the objective function so that it can be established if the intermediate individual ui is accepted and replaces individual qi or if instead qi remains in the next generation.

Parameter µ is closely linked to the speed in which the algorithm converges. Small values of this parameter allow for local exploration, while big values stimulate a global search. As can be appreciated, by having a good µ selection it is possible to escape from local minima as well as achieve good precision of the objective function.

1.4. Dynamic model of the solar tracking system

A complete dynamic model of the solar tracking system can be impractical due to the identification of its own parameters. As an alternative, we propose a simplified model and perform the identification of the parameters taking into consideration the dynamic behavior of the solar tracking system. Equation 3 corresponds to the simplified transfer function of the plant, which consists of a first order system with an integrator. In this model, variable S is associated with the laplace transform, which allows for the representation of a dynamic system as a transfer function.

The identification of the parameters of the plant is performed considering the mean values of speed and settlement time, as presented in [6], [7].

For transfer function of equation 3, the parameter k corresponds to the relation of input and output at a steady state, which in this case is:

Where ω is angular speed. With a 12v voltage, the average time taken by the system to traverse an angle of π/2 is 0.06 rad/sec, so the value of the parameter k equals 0.005 rad/(vsec).

On the other hand, parameter τ can be determined as a quarter of the settling time of the system. Mean settling time of the system equals 1.53, so the parameter τ is 0.38 seconds. Considering this, the plant model is given by the following transfer function:

The mechanism for detecting the position of the sun consists of an arrangement of two connected photoresistors as shown in Figure 4. With this arrangement, a voltage proportional to the lighting difference present in the two photoresistors is obtained. To achieve the lightning difference, a separator is provided, as shown in Figure 4

Figure 4 shows the physical implementation of the sensor where it's positioning in the solar tracking system can be observed.

Figure 6 displays different versions of the sensor. The arrangement shown in the upper right-hand corner was selected for the implementation since it has a smaller dead zone and thus allows for the continuous monitoring of the sun.

1.6. Controllers

To achieve the physical implementation of the controller, there needs to be a circuit where the sensor can be connected to an amplifier in follower mode, which allows for the suitable coupling of impedance matching. There is also a circuit that provides reference voltage through a resistive divider and an operational amplifier in follower mode, for potential operation without dual power supply. Finally, there is a power stage with four transistors, making proportional action on the engine possible. The implemented circuit for this part is shown in Figure 6

With the circuit shown in Figure 7, different analog controllers can be connected using terminals a, b and c, where a is the input, b the output and c is the reference voltage.

1.7. Proportional controller

The controller is implemented via an operational amplifier with inverting configuration, as shown in Figure 8

The implementation of this controller involves the adjustment of amplification gain, which is given by the combination of a resistance and a potentiometer in series. The input-output relationship of this controller is:

1.8. Compensator

The compensator of zero-pole-gain is implemented through the circuit shown in Figure 9

The transfer function of the compensator is given by equation 7:

2. Methodology.

2.1. Optimization process

To perform the optimization process, the schematic diagram shown in fig. 10 needs to be followed. Under this orientation, we first carry out a function where the dynamic of the plant and the control system are described, taking as input the parameters of the controller and as output the control system response. The result of this function is used to calculate the respective performance index to be optimized. Finally, the function that implements the performance index is optimized with the respective algorithm.

In this case, the performance index, in addition to considering the output of the system, incorporates a factor associated with the energy supplied since there is a limitation in the power supply of the system. According to [16] and [17], a performance index incorporating the error and the energy supplied is:

Where are two constants respectively pondering error and control action. At a computational level, the above performance index can be calculated as:

X being the set of controller parameters, e(n,X) the error signal, u(n,X) the energy supplied, n the discrete-time index, and N corresponding to the total number of data taken.

3. Results

The two controllers are optimized performing 20 executions of the differential evolution algorithm. The parameters used for the algorithm were:

  • Generations: 100
  • Population: 20
  • Cross factor: 0.9
  • Mutation constant: 0.85

3.1. Results from the optimization of the proportional controller

The objective function results of the optimization of the proportional controller for each execution (n) can be observed in table 1.

3.2. Implemented controllers

Considering the results of the performed optimizations, we chose the parameters of the optimized controllers which demonstrated the best obtained performance. Figure 10 shows the physical implementation of the controllers.

For the proportional controller, the gain value corresponds to X=1L4 which is implemented by equation 6. Meanwhile, when considering the best case of the optimization process, the transference function of the compensator is:

3.3. Results of the compensator optimization

The objective function results for the compensator optimization can be observed in Table 1

The previous controller is physically implemented using equation 7.

3.4. Results of the controllers implemented

In this section, we present the results of the dynamic behavior of the solar tracking system using the two controllers designed, comparing their performance with simulations of the system. The schematic diagram of the simulation can be seen in Figure 12

Figure 13 shows measured and simulated results of the behavior of the solar tracking system using the two designed controllers. In this figure, (m) is employed to indicate a real measurement and (s) to indicate a simulation.

One will note that neither the proportional controller nor the lag compensator present steady-state errors. However, the lag compensator displays a settlement time smaller than that of the proportional controller.

4. Conclusions

In practice, the implemented controllers achieved the tracking desired, and therefore can be permanently utilized for the solar tracking system. Since there is saturation of the controllers, an additional battery can be included to assure dual power supply and thus increase the applied voltage. The proportional controller and the compensator display similar behaviors, although the compensator has a shorter response time than the proportional controller. The differential evolution optimization algorithm allowed for the design of two controllers adequate for the solar tracking system.

The performance obtained from the controllers designed using differential evolution was similar to the designs created in earlier versions with genetic algorithms and particles swarms [6] [7].


[1] F. Sierra, F. Mejia y E. Caro, Tecnologías para el aprovechamiento de la energía solar, Bogotá: Universidad Nacional de Colombia, 2008.

[2] S. Lakeou, E. Ososanya, O. Latigo, W. Mahmoud, G. Karanga y W. Oshumare, «Design of a low- cost digital controller for a solar tracking photo-voltaic (pv) module and wind turbine combination system,» de 21st European Photovoltaic solar energy conference, Dresden, 2006.

[3] D. Kang, A. Martinez y E. Chaparro, «Solar tracker system based on a digital heuristic controller,» de IEEE trondheim powertech, Trondheim, 2011.

[4] B. Plesz, P. Sági y T.-H. V., «Enhancement of solar panels power generation by the usage of solar tracking.,» Proceedings of Ecopole, vol. 3, n° 1, pp. 15-22, 2009.

[5] M. Khan, S. Tanzil, R. Rahman y S. Alam, «Design and construction of an automatic solar tracking system,» de Presented at the international conference on electrical and computer engineering (ICECE), Daca., 2010.

[6] H. E. Cuchango y F. Sierra, «Optimization of an analog controller for a solar tracker using genetic algorithms and particle swarm optimization,» de Presented at the ieee international symposium on alternative energies and energy quality (SIFAE), Barra, 2010.

[7] H. E. Espitia y F. Sierra, «Diseño e implementación de controladores análogos para un seguidor solar,» Visión electrónica., vol. 7, n° 1, pp. 118-132, 2013.

[8] K. Passino, «Biomimicry of bacterian foragin for distributed optimization and control,» IEEE control systems., vol. 22, n° 3, pp. 52-67, 2002.

[9] M. Birattari, P. Pellegrini y M. Dorigo, «On the invariance of ant colony optimization,» IEEE transactions on evolutionary computation, vol. 11, n° 6, pp. 732-342, 2007.

[10] M. Dorigo, M. Birattari y T. Stutzle, «Ant colony optimization. Artificial ants as a computational intelligence technique,» IEEE computational intelligence magazine, vol. 1, n° 4, pp. 28-39, 2006.

[11] Zecchin, A. C; Simpson, A.; Maier, H.; Nixon, J., «Parametric study for an ant algorithm applied to water distribution system optimization,» IEEE transactions on evolutionary computation, vol. 9, n° 2, pp. 175-191, 2005.

[12] S. Thakoor, J. Morookian, J. Chahl, B. Hine y S. Zornetzer, «Bees: exploring mars with bioinspired technologies,» IEEE computer, vol. 37, n° 9, pp. 38-47, 2004.

[13] T. S. P. Lim y H. Haron, «Performance comparison of genetic algorithm, differential evolution and particle swarm optimization towards benchmark fiinctions,» de IEEE conference on open systems (ICOS), Kunching, 2013.

[14] R. M. Storn y K. Price, «Differential evolution a simple and efficient heuristic for global optimization over continuous spaces,» Journal of global optimization., vol. 11, n° 4, pp. 341-359, 1997.

[15] K. V. Price, R. M. Storn y J. A. Lampinen, Differential evolution: a practical approach to global optimization, Germany: Springer-Verlag, 2005.

[16] K. Ogata, Ingeniería de control moderna, cuarta edición., Madrid: Pearson Prentice Hall, 2003.

[17] C. T. Chen, Analog and digital control system design, fort worth: Saunders College Publishing, 2003.


  • There are currently no refbacks.

Copyright (c) 2015 TECCIENCIA