Design Controller of Pendulum System using Imperialist Competitive Algorithm

Due to development of technology in recent years, complexity and nonlinearity of mechanical and electrical system are increasing significantly. Inverted pendulum is nonlinear system that has become popular in recent years. However, inverted pendulum is nonlinear and unstable system. Therefore appropriate design controller of inverted pendulum system is crucial. Hence, this paper proposed, design of inverted pendulum system based on imperialist competitive algorithm (ICA). In order to design the controller, dynamic model of inverted pendulum system is used. Time domain simulation is used to address the controller performance. From the simulation result, it is found that imperialist competitive algorithm can be used to design inverted pendulum system controller. Keywords— Inverted pendulum system, PID controller, ICA


I. Introduction
Inverted pendulum system (inverted pendulum) is a system that simulates a control mechanism to regulate the problem of stability.Inverted pendulum is one plant that is dynamic and nonlinear, so the arrangement becomes complicated when used conventional control system [1].
Several previous studies have discussed about pendulum control using methods.In the study [2,3,4], pendulum controls used the fuzzy logic method.
The application of intelligent methods based on Imperialist Competitive Algorithm (ICA) [5,7,8,9,10] and several other intelligent methods have been widely applied to power systems.[6] using the Particle Swarm Optimization (PSO) method.
In this study, inverted pendulum will be controlled until stable with artificial intelligent methods imperialist competitive algorithm.Nonlinear equations of mathematical models of inverted pendulum will be linearized so that it will be some linear equations.

II. Research Methodology
A. Inverted Pendulum System Inverted pendulum system comprises of a pair of rod pendulum swinging on the train.Pendulum can move on vertical sides, while the train moves on the horizontal side.Trains are driven using a DC motor [1][2][3].To move the pendulum rod, the train moves back and forth on the track limited.The vertical position of the pendulum rod (top and bottom) is the equilibrium state where no force is working.If the top vertical equilibrium state by forces acting.If the equilibrium state by forces acting.If the equilibrium state vertically above given little style then the pendulum will not return to the original equilibrium state.This proves that the pendulum rail system is one example of an unstable system [1][2][3].
Inverted pendulum system is one example of single system multi output (SIMO).Input system is corresponded to control signals u, given by the train that is parallel to the track.Output of the system are position of the train (x1), angle of pendulum in terms of the vertical position (x2), train speed (x3), and pendulum speed (x4).A mathematical model of the pendulum system derivate from the physical identification of the system.Physical model of the system is shown in Fig. 1, whereas the forces acting on the system shows in Fig. 2 The system state equation is expressed as in (1) and ( 2) [1].

Center of Mass X2
Center of Rail

X2
Figure 2. The force acting on the pendulum system [1].
Equations 1 and 2 is obtained from the overall equation of forces acting on a pendulum system in terms of the z-axis and y-axis according to the second law of Newton.Equation 3 is obtained from the overall style of the rotation around the point of the center of mass of the pendulum system.Train mass and the mass of the pendulum is denoted as and .I is the distance between the axis of rotation of the pendulum to the center of mass of the system.J is the moment inertia in terms of the point of the center of mass.and V respectively are friction and the normal force of the system, whereas is the moment of friction of the system and expressed as a = [1].State space representation of the system can be described in (4) [4].A system cannot be separated from their errors caused by interference.This error can cause changed behavior of the system.This changed can lead to unstable condition of the system.To maintain the stability of the system, utilizing controller devices in inevitable.The function of the controller is to reduce error signal.The smaller the error, the better the performance of the control system is applied.Proportional, integral and derivative is popular controller among industry practitioners due to fast response of the controller [5,6].
Proportional controller output is the product of the gain and input signal.Variation in the input signal directly cause the system to change the output of the constant multiplier.Fig. 3 shows a block diagram of the relationship between the magnitude of the setting and the magnitude of proportional controller output.The error signal represents the difference between the amounts of setting and the amounts of actual signal.This difference will affect the controller to issue a positive signal or negative signal [5].The function of integral controller is produce a system response that has zero steady state error.If a plant does not have an element integrator (1/s), a proportional controller will not be able to ensure that output solid-state system with zero error.With integral controller, the system response can be improved, which has solid-state error to zero.Integral controller has the characteristics as well as an integral.Controller output is affected by changes in proportion to the value of error signal.If the error signal does not change, output will maintain a state like before the input changes [5].
Integral controller output signal is a broad field that is formed by the error curve driving.The output signal will be worth the same as before when the error signal value of zero.Fig. 4 shows an example of an error signals is inputted into the integral controller and an integral controller output to changes in the error signal [5].Effect of constant change integral to the output shown in Fig. 5.When the error signal is multiplied, then the value of the output slew rate controller value integrator transformed into larger, restively small error signal could result in the rate of output to be great [5].Derivative controller output has properties such as derivatives operations.Sudden changes in the input controller, will result in a very big change, and fast.Fig. 6 shows a block diagram that illustrates the relationship between the error signals to the controller output [5].When the input is not changed, the controller output is also unchanged, whereas when the input signal changed suddenly and ascending (step function), the output generating impulse shaped signal.If the input signal changes slowly rise (ramp function), the output is precisely the great step function magnitude is greatly influenced by the speed of the rise ramp function and the differential constant factor [5].
Each of the advantages and disadvantages of each controller proportional, integral and derivative can cover each other by combining all three in parallel into controller proportional plus integral plus derivative.The aims of the PID controller is to accelerate the reaction system, eliminating offset and produce large initial changes.

C. Imperialist Competitive Algorithm
Imperialist competitive algorithm (ICA) is an evolutionary algorithm inspired by the competitive authority [8][9][10].This algorithm was introduce by Esmaeil and Atashpaz in 2007.ICA simulates sociopolitical processes of imperialism and competition for power.ICA begins with initial determine initial population, each individual of the population referred to the state (country).Some of the best country chosen as a colonial state and the remaining colonies used by the invaders.Imperialist countries together with its colonies formed several empire (kingdom).After forming the early empire, the empire of each colonies move towards relevant imperialist countries [8][9][10].This movement is a simple model of a policy of assimilation given by the imperialist countries [8][9][10].
The total strength of an empire depends in the strength of the imperialist countries and the strength of the colony.This fact is modeled by defining a total strength of an empire is the strength of the imperialist countries coupled with a percentage of the average strength of the colony [8].
The final goal of optimization is to get the optimal solution for a particular problem.ICA forming an array of variable values that will be optimized.In other algorithms, such as genetic algorithm, this array is called chromosome, in ICA this array is called country.This array is defined as (5) [8].
Where is the variable to be optimized.Every variable in a country can be interpreted as the characteristics of the socio-politics of a country.From this point of view, all the will search for the best state in which the country has a combination of political and social characteristics such as culture, language, policy and religion.In terms of optimization, this will lead to discover the optimal solution of the problem, Fig. 8 shows the depiction of the country by using some social and political characteristics [8].Cost of country obtained by evaluating the variable cost function ( , , , . . ).So the equation become To start the optimization, the initial country must be established first.Some of the best country to be selected as an imperialist to lead an empire.The rest of the population will form colonies owned by the empire.An empire comprises of one imperialist and several colonies.The division should be based colonies by the imperialist right, then cost imperialist must be normalized in advance with the following equation [8].
With is the cost of the imperialist, and is the cost that has ben normalized.After that, each imperialist power are define as (8) [8].
Then the amount of the early colonist for an empire is [8].
With . . is the initial number of colonies of the empire and represent the number of early colonists.To divide the colonies, . . of colonies were randomly selected and given to imperialist [8].Assimilation is the process by which as minority group to quickly adapt to become a group that has a strong culture.Assimilation policies make the imperialist country trying to bring the colony and made to be a part of the country.More precisely, the imperialist countries make the colony moves toward himself [8].
Assimilation colonies by the imperialist countries do not move directly toward imperialist.The direction of movement is not necessarily as vector of colonies to imperialist.To model this reality the number of random deviations is added to the direction of movement of the objective is to increase the ability of the search area around the imperialist countries [8].
Revolution is a basic change in the organizational structure which took place in relative time period.In the terminology of ICA, the revolution led to a country suddenly changed socio-political characteristics.This means that, despite being assimilated by the imperialists, the colonies were randomly change its position on the socio-political axis.Revolutionary increase exploration of the algorithm and prevent local convergence towards the minimum country.Revolution speed of the algorithm shows the percentage of colonies on each colony will change its position randomly [8].Value are very high revolutions reduce the strength of exploitation algorithm and can reduce the speed of convergence [8].
When moving towards an imperialist colony, a colony might have a better cost than those of its imperialist.When this happens the exchange of positions between imperial colonies will happen.Then the algorithm will continue with the new imperialist [8].
In the colonies and imperialist movement towards global minimum, some imperialists may be moving to the same position.If the distance between the two imperialist less than the distance threshold, then they will form a new empire and the new imperialist in a position where it meets the second imperialist [8].
Imperialist have a considerable influence on the strength of the empire, but the strength of the colony also influence though small.The total cost of an empire is defined as the sum of the cost imperialists with the average cost colonies possessed of an imperialist empire.Value ξ shows the influence of the contribution of the colony [8].
With . . is the total cost of the empire and ξ is a positive value less than one, resulting in a total power of more influenced by the imperialist empire rather than a colony.Rated 0.01 for ξ has shown great result for implementation [8].
All the empire try to have the other colonies of the empire and master them.Competition for power gradually decrease the strength of a powerful empire.
The competition is modeled by just taking some or the weakest colonies empire owned by the weakest among all the empire and create competition between all empires to have the colony [8].
Based on the total force, in this competition, every empire will have the possibility of taking the colony.In other words, the colony will not necessarily be owned by the most powerful empire, but the empire has a greater opportunity to have a colony.To start the competition, first is to look the opportunities to owner any empire based on total power of each empire.Normalization of the total cost of the empire is simply by using (11) [8].
Where . . . is the total cost that has normalized from empire respectively.Ownership opportunities of each empire is as (12) [8].
To divide the weakest colony to empires, vector P is formed as (13) [8].
Then created a vector R of the same size as P whose elements are uniformly distributed randomly as described in ( 14) and (15) [8].
Based on the vector D, mentioned colony controlled by the empire that had the greatest D. The process of selecting an empire similar to the process used on the genetic algorithm roulette wheel.However, in this method the selection is done faster than a conventional roulette wheel.Because ICA does not require the calculation of the cumulative distribution function and selection is based only on the value of the opportunity.
Therefore, the selection process can only replace roulette empire wheel; on genetic algorithm and increase execution speed [8].
The weakest empire will disappear in the competition for power and colonies of the empire will be distributed to the other empire.To model a removal mechanism, different criteria can be define for letting a weak empire.In this paper implementation, in an empire is assumed to be lost if the loss of all the colonies [8].
After all the empire collapsed except for one of the strongest then all the colonies would be controlled by the most powerful empire.In a new ideal world, all colonies will be well positioned and cost the same as imperialist.In this condition, the competition authority ends and the algorithm stops [8].

III. Results and Discussion
In this work, case study were carried on MATLAB/SIMULINK environment.The test system is pendulum system with PID controlled installed as pendulum system controller.Table 1 shows the initial parameter of pendulum system and PID controller [11].Fig. 9 shows the convergence curves of ICA.It was clearly shown that after 38 iteration, the ICA found the convergence point.Table 2 shows the optimized parameter of PID controller.This case study started by applying 10 N/m force to the pendulum chart.Then, the overshoot and time settling of the pendulum angle was analyzed.The overshoot must less than 0.5 degree.Fig. 10 illustrates the oscillatory condition of pendulum angle again 10 N/m force.In this study, we compare conventional PID, PID optimized by particle swarm optimization and PID tune by ICA.It was found that pendulum with PID controller tune by ICA has the best performance in term of smaller overshoot and fastest settling time.Table 3 shows the comparison of the PID conventional, PID PSO and PID ICA.

IV. Conclusion
This paper investigate the application of PID controller to stabilize the pendulum system.From the case study, it is found that PID might be used as controller to stabilize the pendulum system.It is also found that ICA might be used as optimization method to tune PID controller.Further research is required to used another metaheuristic algorithm such as firefly algorithm, bat algorithm or used controller based on fuzzy logic method.

Figure 4 .
Figure 4. Curves error signal e(t) versus t and the curve u(t) versus t on generating zero error [5].

Figure 5 .
Figure 5. Changes in output as a result of strengthening and error [5].