1 Introduction

Due to their excellent speed control characteristics with simplicity and advantage of producing solutions in a cost-friendly manner, direct current (DC) motors have been in service for more than a century in a vast number of areas including house appliances, automotive, aeronautics, hoists and elevators, cranes [1,2,3]. As permanent magnet brushless motors give similar performance closer to DC motor while eliminating the requirement of commutator and brushes and provide fast dynamic response, high torque/volume ratio, and high efficiency, they have got involved broadly in high-performance applications [4]. Although motors of such kind decrease the fortune of brushed motors in industry, it is not possible to think that they will completely replace brushed motors specifically because of their increased manufacturing and installation costs. That’s why brushed DC motors keep their position strongly competitive in the market, and the need for them would continue undiminished in the future [5].

Many techniques can be applied to the control of electrical drive system with different degree of success, some of which are based on sliding mode, predictive control, traditional proportional integral (PI) control, robust control, neural networks, fuzzy logic, and neuro-fuzzy systems [6]. Each has its own advantages and disadvantages. Among them, the PI controller is doubtlessly the one that is the most popular and yet the simplest control algorithm to implement in the process control industry, i.e., it is a known fact that the majority of industrial control loops are of PI/PID type [7, 8]. The performance of PI controller depends greatly on how well its parameters K p and K i are tuned. In order to obtain the best performance, controller parameters must be tuned according to the nature of the system being controlled, and this has been quite difficult because many industrial plants are often burdened with problems such as high order, time delays, and nonlinearities. In addition, despite its extensive use in practice, there is no any specific methodology that helps the operator to design this controller. For long years, Ziegler–Nichols (Z–N) frequency response method has been applied to tune the parameters empirically by taking advantage of requiring very little information about the process, but it is regarded as a time-consuming and tedious work. There is also a significant disadvantage because the method inherently gives very poor damping [9]. Particularly since 2000, a large number of optimization algorithms have been reported in literature to provide automatic tuning of PI/PID controllers [7, 10,11,12,13,14,15,16,17,18,19,20], where the concerned problem is formulated as an optimization problem and controller gains are optimized through an objective function with an aim to obtain better output response profile for the controlled system. As it is possible to find better controller gains depending upon the adopted algorithm’s search capability which leads to an incremental improvement in system control performance, the desire of bringing this performance to the optimal one as closely as possible has been always found attractive by the researchers. Apart from these artificial intelligence-based self-tuning control strategies, in [21], an approach based on convex combination approach is presented to calculate the control gains that satisfy the required design specifications where the PID controller has degree of freedom and complex control laws. In [22], a new technique for calculating PID gains is given using model-based compact form (MBCF) formulation for design in discrete time, where calculation of controller gains depends on mathematical equations sensitive to system parameters and it is not guaranteed that obtained gains are optimal. An application note for implementation of PID regulator is reported in [23] to control an electric kart DC motor using MSP430 series microcontroller. At first, the regulator gains values are classically determined by Z–N method, and then they are adjusted roughly by trial. A simulation study to compare fuzzy-based self-tuning PID controller and model reference adaptive control (MRAC) with PID compensator is conducted in [24] for brushless DC motor tracking control. These are well-known techniques and they both involve larger computational burden and time than PI controller. In [25], a fuzzy-neural network (FNN) PI/PD controller, which is trained online using Extended Kalman Filter (EKF), is developed and implemented for speed control of a brushless drive system. The FNN PI/PD controller combines two independent controllers of fuzzy-neural PD controller and fuzzy-neural PI controller to simulate a PID control law in the event. With an aim to get a better transient response than a classical PI and IP speed control, an adaptive self-tuning IP controller with recursive extended least squares estimation algorithm and load torque feedforward compensation is presented in [26] for rolling mill DC drive system. Design of these controllers in [25, 26] suffers from heavy computational burden and is much more complex than a simple PI controller handled in the present paper, and their implementation in real time is difficult and limited.

Symbiotic organisms search (SOS) algorithm is a new simple and powerful metaheuristic optimization technique introduced in 2014. It simulates the symbiotic interaction strategies adopted by organisms to survive and propagate in the ecosystem [27]. The SOS works on a population of candidate solutions distributed in the search space at the beginning of the algorithm, then guided iteratively to the optimal global solution by its own algorithmic steps. Unlike other optimization techniques, SOS is free from any tuning parameters; it requires only common controlling parameters like population size (number of organisms) and maximum number of iterations [28]. According to the conducted tests and comparisons with other well-known optimization methods, the SOS method, while robust and easy to implement, has proved to be effective in solving various complex numerical problems despite using fewer control parameters than competing algorithms [27]. Particle swarm optimization (PSO) was originally proposed by Kennedy and Eberhart as a simulation of social behavior of bird flock in 1995 [29]. It belongs to the group of population-based evolutionary algorithms with a difference that PSO mimics the social behavior instead of survival of the fittest. Each candidate solution or particle updates its velocity and position based on its own experience and others’ experiences in the population. The goal of PSO algorithm is to guide each particle toward better solution areas by the swarming process. Genetic algorithm (GA) is a stochastic global adaptive search optimization technique based on the mechanisms of natural selection and survival of the fittest. It performs a parallel search of a parameter space by using genetic operators to manipulate a set of encoded chromosome that represents system parameters. In other words, rather than a single path in the single search, genetic search comes with multiple paths in every iteration [30]. Specifically, the GA has been theoretically and empirically shown to provide a reliable and effective search procedure in complex search spaces [31].

As it is understood from the previous paragraphs that PI controllers are the focus of great interest in practice, this study is devoted to enhance the performance of such controllers installed in DC motor drives. For this, an attempt has been made to benefit from a recently introduced, robust, and powerful optimization technique named symbiotic organisms search algorithm for the first time. In this regard, by introducing the SOS algorithm, to obtain better controller parameters that yield increased performance constitutes our main contribution. After the PI parameters are optimized by an off-line approach in accurately prepared simulation software under various motor operating conditions subjected to variable step speed references and load torque disturbances, then they are used in real-time application. For the controller robustness and sensitivity properties, we take into account the nonlinear motor electric dynamics such that the change of armature resistance and inductance in the range of ± 20% is included during the optimization. Note that there is not a systematic way for selecting that rate of change. It is somewhat up to the operator choice. If the resulting controller performance seems to be unsatisfactory under parameter change in simulation or experiment, the operator may decide to extend the range which means that controller parameters will be optimized for the case the associated motor parameters change more. For the concerned test system, an industrial-type permanent magnet DC motor equipped with a tacho-generator and an incremental encoder and TMS320F28335 DSP controller from Texas Instruments are used. The presented extensive simulation and laboratory experimental tests fully prove the superiority and contribution of the SOS algorithm to the improvement of controller performance by gaining a better tuning capability than all other methods such as PSO, GA, and Z–N.

The remainder of the paper is constructed as follows. A brief review of the SOS algorithm is initially given in Sect. 2. Our proposal of off-line optimization process of PI coefficients by using the SOS is illustrated in Sect. 3, which is followed by implementation of DC motor drive system in Sect. 4. In this section, a comparative study based on simulation and experimental results obtained by the application of four methods is also presented. Finally, conclusions are drawn in the final section.

2 The symbiotic organisms search algorithm

Nowadays, the developed stochastic algorithms are simulation of the natural phenomena [32]. Among those, SOS algorithm is a new simple, robust, and powerful metaheuristic optimization technique recently developed for solving numerical optimization problems over a continuous search space. It imitates the natural phenomena of symbiotic interactions within symbiotic organisms living together in an ecosystem. As mentioned earlier, since the SOS algorithm requires no specific tuning parameters, robustness of the algorithm is improved with respect to different problems, and this helps decrease to great extent the risk of deteriorated performance due to inappropriate parameter settings unlike most other competing algorithms.

Being a population-based algorithm, SOS begins its search with an initial population called the ecosystem, which is usually generated at random. Each organism represents one candidate solution to the corresponding problem and it is associated with a certain fitness value in the ecosystem, which reflects degree of adaptation to the desired objective [27]. The SOS algorithm has been developed using three most common symbiotic connections found in natures such as mutualism phase, commensalism phase, and parasitism phase [33]. The characteristic of each phase determines the movement of the organism and the decision to replace an organism. Mutualism represents a symbiotic interaction between two organisms in which both benefit. Commensalism is a symbiotic interaction between two organisms in which one benefits and the other is unaffected. Parasitism is a symbiotic interaction between two organisms in which one benefits and the other is harmed [34]. Apart from these original three phases, two new interaction strategies, named as competition and amensalism, are proposed in [35] to improve the solution quality of SOS. Results show that SOS can perform better in terms of computational efficiency and quality of solutions when combined with some other algorithms, such as solution representation and local search methods.

After all the phases are completed, SOS algorithm tries another iteration, and the whole process is repeated likewise until pre-defined stopping criteria are met. The above explanation is summarized in the following pseudocode in Fig. 1, where the variable eco_size stands for the number of organisms in ecosystem and f is the objective function to be minimized.

Fig. 1
figure 1

Pseudocode of SOS algorithm

3 Proposed method to design the SOS-based PI controller

This study presents off-line optimization of PI parameters using the SOS algorithm as the robust and powerful optimizer tool. In such an approach, as a suitable simulation model is required to perform optimization, we firstly begin with the preparation of the simulation software in C language that accurately simulates the ingredients of concerned closed-loop control system consisting of power converter, PI controller, and DC motor. In the beginning of the SOS algorithm, a number of organisms that contain real-coded PI controller coefficients are generated at random over the continuous interval of 0 ≤ K p , K i  ≤ 20, with each organism having a K p and K i parameter. Therefore, it is aimed to obtain optimal organism in the search space bounded by 0 and 20 for both proportional and integral parameters. In the study, controller parameters are not optimized by considering only one motor operating condition, since the operating point of the closed-loop system may be changed continuously, such that it may be subjected to step changes in reference speed, endogenous and exogenous disturbances due to load torque and system parameters, possibly resulting in non-optimal performance for PI controller. For this reason, a wide range of conditions including variable step speed commands and mechanical load torque from zero to full value is considered during optimization, in addition to change of armature resistance and inductance in the range of ± 20% for parametric robustness and sensitivity.

By feeding each organism or candidate controller into the closed-loop system module, the system is simulated for a while under varying conditions to obtain the speed response. Each organism gives rise to a different speed curve with its own rise time, overshoot rate, settling time, and steady-state performance. To measure off-line performance of each organism, integral squared error (ISE) combined with integral absolute error (IAE) is chosen as the objective function in Eq. 1

$$P_{k} = \alpha \int {e_{k}^{2} {\text{d}}t} + \beta \int {\left| {e_{k} } \right|} {\text{d}}t$$
(1)

where \(e_{k}\) is the error between the reference speed and the actual speed of the k-th organism. \(\alpha\) and \(\beta\) are the gains used to weight sub-objectives in Eq. 1, which are determined via trial by considering which sub-objective is more important for the system response. It is known that ISE avoids large errors more than smaller ones, which in turn leads to a fast response, but with remarkable overshoot. As for IAE, it integrates the absolute error with time and has a tendency of slowing down response. This usually comes with a less overshoot level. As our aim is to ensure a fast response with a small overshoot, those gains are set to 0.65 and 0.35, respectively.

After the overall performance of each organism is calculated using Eq. 1, then the organisms are fed back into the optimization module in order to update them through the typical SOS phases in a manner to minimize the value of Eq. 1. This process of moving up and down between the closed-loop system module and the optimization module repeats in next iterations until the maximum number of iteration is achieved. Figure 2 illustrates the comprehensive flowchart of the SOS implementation.

Fig. 2
figure 2

Comprehensive flowchart of the SOS implementation

After the optimization process terminates, the obtained set of controller parameters, which are expected to be optimal or have the least error compared with the globally optimum solution, is inserted into the DSP for practical implementation. Then, system is run by using this set.

4 Implementation of DC motor drive system

In this section, feasibility and validity of proposed SOS optimized PI controller are evaluated through several laboratory tests. A comparison study is also conducted when PSO, GA, and Z–N methods replace the SOS. The block diagram of the control system is shown in Fig. 3, where digital signals are isolated to prevent electric noise and shock. A reference current signal i * a is produced by the PI speed controller according to speed error between the reference speed and the actual speed. By comparing the reference current signal with the actual one, i a , obtained through 12-bit A/D converter, PWM signals are generated for the H-bridge converter to drive the motor, which works like a four-quadrant chopper. In order to apply external torque disturbances at the DC motor shaft, a rheostat is connected to terminals of a suitable DC generator that is coupled to DC motor shaft as a dynamic load. In such a system, the produced torque by the generator depends on the motor speed and the resistance value of rheostat.

Fig. 3
figure 3

Block diagram of the control system

For the concerned test system whose experimental platform is shown in Fig. 4, an industrial permanent magnet DC motor of type R730T-042EL7 from Sanyo Denki is used, which has a rated power of 300 W at 2500 rpm, armature resistance of 1.75 Ω, armature inductance of 1.65 mH, and voltage constant of 28.6 V/krpm. The generator model Sanyo Denki T730B-569EL8 N is the generator to apply external torque disturbances. IGBT of IXGH48N60C3D1 is adopted as the power switches, and controllers to be tested are implemented using DSP of TMS320F28335. To trace the speed response, the built-in tacho-generator with a voltage constant of 7.4 V/krpm is used. A Yokogawa DLM4038 oscilloscope views the measured speed and motor current. To keep the generator operation safe, a wattmeter is placed between the generator and the rheostat to observe the load power and set the rheostat resistance value such a way that the generator rated power is not exceeded. Moreover, a circuit breaker is used to connect and disconnect the rheostat with the generator terminals safely.

Fig. 4
figure 4

Experimental platform

As stated before, the success of SOS is just sensitive to two parameters, namely ecosystem size and maximum iteration number. It is known that there is not a definite way that tells us the optimal values of these parameters across all problems, and tuning of these parameters based on the problem at hand is definitely important not only for solution quality, but also for time consumption. By considering this, the population size was set to 30 for SOS, PSO, and GA algorithms. The maximum iteration number was tuned to 100 for SOS. As each iteration in SOS method is repeated for the number of organisms in ecosystem, the maximum iteration number used for GA and PSO was set to 30 × 100 = 3000 in order to have a fair comparison. Other parameters of GA such as discarding rate and mutation rate were considered to be 0.42 and 0.31, respectively. Natural selection mechanism is based on the rank-order roulette wheel, and uniform crossover technique was adopted. Beside, elitism was also used in GA, which means that the fittest individual of the population is transferred to the next generation without any change [36]. Learning factors c 1 and c 2 in PSO are considered to be 2, and the inertia weight factor ω which weights the current velocity of an individual is gradually decreased from 1.0 to 0.15 as the number of iteration increases. Eventually, setting the algorithm parameters as above via trial by considering the algorithm success appears to produce the best solution among all possible solutions that we could achieve. The obtained PI parameters by applying SOS, PSO, GA, and Z–N are reported in Table 1. As seen, different values of K p and K i gains are attained with the methods. The difference obtained by the SOS leads to better control performance for considered system, as will be discussed later.

Table 1 Obtained PI parameters

Off-line optimization studies are performed on a computer which has an Intel® Core™ i5-4590 3.30 GHz processor and 8 GB memory. The execution time taken for GA and PSO is found to be more or less the same which is 163.9 min for GA and 158.1 min for PSO while it is 39.8 min in the case of SOS. From this, it is manifest that SOS is able to operate much faster than GA and PSO due to its simple three phases based on simple mathematical operations to code. As for the Z–N method, we spent 10–15 min to bring the controlled system to the operating point required by the Z–N method and to design PI controller. In the experimental study, the DC motor is subjected to run under three scenarios given below.

  • Case a: 1500 rpm speed reference under no-load condition.

  • Case b: 2000 rpm speed reference under varying load condition.

  • Case c: Varying step speed reference under varying load condition.

Figure 5 presents the simulation and experimental results under case a while the motor is operating by the PI parameters tuned by Z–N, GA, PSO, and SOS algorithm. In this test, the generator terminals are kept opened. The desired speed and measured speed, ω *, ω, are indicated by the superimposed black and purple traces, with a scaling factor of 270.27 rpm/div. The red trace indicates the measured motor current, with a scaling factor of 5A/div. The speed and current scaling factors are adopted the same in all the reported experiments. The current waveform is provided for approximating the power or torque produced by the motor. According to the resulting responses, no steady-state error is seen in all four cases. The controller tuned by Z–N generates no overshoot but causes high current ripple and sluggish speed response with a slow settling time of 0.3 s, while the one based on GA improves the settling time considerably at the expense of some speed overshoot. Notice that the settling time is further improved and speed overshoot is reduced in the case of PSO-PI controller. When comparing these results to that of SOS optimized PI controller, we see that it accomplishes the best transient response with the least settling time and minimal speed overshoot. According to the simulation results in Fig. 5e that are comparable with the experimental ones, response with the presented controller settles to 1500 rpm more quickly after a mild overshoot.

Fig. 5
figure 5

Simulation and experimental results of speed/current responses under case a a Z–N, b GA, c PSO, d SOS, e comparative simulation responses

In order to evaluate load disturbance rejection capability and robustness of the presented drive system, a load disturbance is applied to the motor shaft at t = 0.46 s, while the rotational speed is 2000 rpm. After the motor is subject to run under such condition for 1.04 s, the load is removed at t = 1.5 s. Notice that the motor current increases up to 4A in the presence of external disturbance and the motor previously rotating at 2000 rpm starts decelerating and accelerating, respectively, and settles to 2000 rpm after a while. In this test, load change has been made by switching on and off the load resistance of the DC generator via the circuit breaker. It is clear from Fig. 6 that the proposed method is able to recover the speed in a very short period of time less than the others, while keeping the speed dip and spike not greater than those in Figs. 6a–c. As a result, we conclude that disturbance rejection performance of the presented controller is considerably better than those of the Z–N and GA-based controllers and slightly better than that of the PSO-PI controller.

Fig. 6
figure 6

Simulation and experimental results of speed/current responses under case b a Z–N, b GA, c PSO, d SOS, e comparative simulation responses

In Fig. 7, tracking performance of varying step speed references under varying load condition is presented. For this test, variable speed reference configuration is organized as follows: during the first 0.2 s, the speed reference is zero, and it is increased to 1000 rpm at t = 0.2 s. This is followed by one more increase in speed reference to 2000 rpm at t = 0.6 s. After that, the speed reference is given as zero at t = 1 s, and finally an increase to 500 rpm at t = 1.4 s. As for the load torque, it changes proportionally to the motor speed as stated previously, i.e., the larger speed, the greater load torque applied to the motor shaft. Notice that, at each working speed, the motor current is different at steady state. This is attributed mainly due to the varying load torque and marginally due to the friction of the whole system. With this test, we realize that the proposed approach fully confirms its effectiveness and applicability in achieving a better closed-loop response for tracking the sudden change in speed reference from one arbitrary level to another under variable load condition.

Fig. 7
figure 7

Simulation and experimental results of speed/current responses under case c a Z–N, b GA, c PSO, d SOS, e comparative simulation responses

5 Conclusions

An application of SOS algorithm as the new alternative artificial intelligence-based optimization technique intended to find better values of PI parameters in an off-line sense is introduced in this article for the first time. The main reason behind why we employ SOS is owing to the desire to acquire optimal (or very close to the globally optimum solution) PI coefficients within the defined search space, which in turn yields to achieve higher performance for DC motor drives. The ability of SOS in generating solutions at a better quality than other metaheuristic algorithms has been already demonstrated in literature for some kind of engineering problems. We investigate its performance for the concerned engineering problem by simulation and experiment in comparison with those of PSO, GA, and classical Z–N method through several tests. Results obtained by the SOS optimized PI controller show that SOS is a significant optimization tool for efficient design of PI controllers, since the dynamic response of the system to step speed references and external torque disturbances is improved. It is found that the nearest competitor to SOS is PSO and the worst performance belongs to Z–N method for this control application. Moreover, SOS, PSO, and GA-based optimized values of the controller gains with our off-line tuning approach need not be reset for a wide change of operating conditions.