Design optimization of a solenoid actuator using particle swarm optimization algorithm with multiple objectives

Solenoid actuators are well-known components that convert electromagnetic energy into mechanical energy. For control purposes, it is requested to have a high magnetic force that stays almost constant in the working region of the actuator. To meet these requirements, it is necessary to have an optimal geometrical design of the actuator. In this study, the following steps are performed to optimize the geometry of the solenoid actuator. The Finite Element Analysis (FEA) is performed, and the results of the simulation is verified with the experimental data. The effect of all geometrical parameters on the characteristics of the magnetic force is investigated. The parameters that highly affect the magnetic force are chosen as design optimization parameters. Then, the Particle Swarm Optimization (PSO) algorithm is realized to find optimal parameters. The algorithm consists of two objective functions being combined into a single objective function. It includes a higher and more consistent magnetic force in the effective working region of the solenoid. Finally, the solenoid actuator with optimized parameters is manufactured, and the results are compared. They show that the optimized solenoid actuator satisfies one of the objective functions, and magnetic force stays almost constant in the working region of the solenoid actuator.


Introduction
Solenoid actuators are electromagnetic components that have been extensively used in various industrial applications, including fuel injection systems, automatic transmissions, mobile robots, engine valve trains, refrigerators, washing machines, hydraulic valve mechanisms, autonomous underwater vehicles, etc. [1][2][3][4][5][6][7][8][9] They are low-cost, rugged, and have a simple construction. Because of their fast response time and controllability, solenoid actuators have been one of the most popular actuating components in the research community. [10][11][12][13][14][15][16] However, there are some important challenges in the solenoid actuators, including a non-consistent magnetic force in the operation region and the need for a higher magnetic force at constant operating current. A high magnetic force that stays almost constant in the effective working region can be achieved through the current control of the coil of the solenoid actuator or by improving the generated magnetic field inside the actuator. Since the current control of the coil needs more complex and expensive control models, it is not preferable in industrial applications. Therefore, the generated magnetic field inside the actuator could be investigated to improve the performance of the actuator. The magnetic field inside the actuator depends on the geometry and dimensions of the different parts of the solenoid actuator. Consequently, higher values of magnetic force that stay constant in the working region can be achieved by the geometrical optimization of the solenoid actuator.
In recent years, the design and geometrical optimization of solenoid actuators have been considered in some research studies. Mach et al. 17 proposed a genetic algorithm optimization approach for obtaining the optimal shape of the plunger of the electromagnetic actuator. In Wang et al., 18,19 the GA algorithm is performed to optimize a typical solenoid actuator. Hey et al. 20 developed an optimization approach based on a genetic algorithm for the design analysis of an electromagnetic actuator. The problem is considered as a maximization problem that is looking for the highest magnetic force per unit of heat generated in the actuator. Lalitha and Gupta 21 developed a design optimization algorithm for a high-temperature superconductor solenoid actuator. The performance analysis of the actuator and optimization of the parameters of the magnet were performed through a coupled field parametric analysis. Plavec and Vidovic´2 2 proposed a genetic algorithm optimization approach along with Finite Element Analysis (FEA) for shape optimization of a solenoid actuator. Maximization of the generated magnetic force was the main objective function of the proposed algorithm. Ebrahimi et al. 23 investigated the design optimization of the coil's parameters of a cylindrical electromagnetic actuator, including two solenoids. The objective function of the suggested approach was to obtain the maximum magnetic field inside the actuator. Beckers et al. 24 proposed a FEA along with an analytical model for design optimization and performance analysis of a solenoid actuator. The objective functions of the developed optimization algorithm were to minimize the operating peak power and the copper volume used in the actuator. Some of these research papers propose some optimization techniques to investigate the impact of some design parameters on the magnetic flux inside the solenoid actuators. However, the impact of all the geometrical design parameters of these components on the magnetic force should be investigated completely. Furthermore, some optimization algorithms that were used in previous studies have more tuning parameters, and the algorithms are also not easily programmable. Some other studies in the literature only theoretically investigate the magnetic force characteristics of the solenoid actuators. [25][26][27] However, manufacturing the optimized design of these components is necessary to evaluate the effectiveness of the optimization algorithms.
The main contributions of this research are as follows: First, the FEA of the solenoid actuator was performed, and the results were verified with the experimental data before the optimization process. Second, the effects of all geometrical parameters, including height, length, width, and radius of different parts of the actuator, on the magnetic force were thoroughly investigated. Then, the most important parameters affecting magnetic force were chosen as design parameters. Using these parameters, geometrical optimization of the solenoid actuator through FEA is time-consuming since too many combinations of the parameters have to be investigated. Therefore, the multi-objective Particle Swarm Optimization (PSO) algorithm is implemented to optimize the geometry of the solenoid actuator to reduce the time of finding optimal solutions. Although the PSO algorithm is a wellknown optimization method that has been widely used in various engineering optimization problems, it has not been previously used for solenoid design optimization purposes. The purpose of this work is not to compare different optimization methods but to make use of the PSO algorithm so that a real design problem can be solved by formulating the problem correctly. For this purpose, the PSO algorithm consists of two contradictory objective functions being combined into a single objective function. The objective functions are to maximize the magnetic force in the working region of the solenoid and to keep it almost constant in that region. Finally, the solenoid actuator design with optimized parameters is manufactured, and the results of the experiments are compared.
The rest of the paper is organized as follows. First, the working principles and the mathematical model of the solenoid actuators are described. In the next step, simulation and its results are considered to find the most important design parameters. Then, the PSO algorithm is applied to find the optimal geometrical design parameters of the solenoid actuator. The results of the optimization procedure are discussed. Finally, the concluding remarks of this research paper are provided in conclusion.
A typical solenoid actuator has three main models, including electrical, magnetic, and mechanical circuits. 28 The coil of the actuator is energized by an external current or voltage source. Then, the electrical current flows in the winding of the coil and generates an intense magnetic field around the coil of the actuator. The generated magnetic field passes through the different parts of the actuator. The anti-magnetic part in the guider of the solenoid actuator changes the path of the magnetic field lines on the plunger part. The magnetic lines flow across the plunger's cross-section surface and generate the magnetic force. The resultant magnetic force pulls the moving plunger toward the ferromagnetic pole piece through the working gap. When the current is applied to the coil, the pole piece acts as a magnet that attracts the plunger to itself. Finally, the push-pin transmits the mechanical force of the plunger to the hydraulic valve to perform opening and closing actions. When the coil is de-energized, the plunger moves to its initial position through a returning spring.
The electrical model of the solenoid actuator consists of a series connection of a resistor (R) and an induction element (L). 29 The input of the model is voltage (V (t)), which comes from an external power supply and the current flows in the coil winding. The voltage (V (t)) in the electrical circuit is calculated using equation (1) from the Kirchhoff voltage law. 30 where V R (t), V L (t), and i(t) represent the voltage of the resistance element, the voltage of the inductance element, and the current flowing through the circuit, respectively. The magnetic model represents the magnetic flux and magnetic field strength inside the guider of the solenoid actuator. 30 The magnetic flux density (B) is produced by the magnetic field strength (H) as equation (2): where m r and m 0 are material's relative permeability and the permeability constant, respectively. The dependency of the relative permeability to the field strength (H) is usually analyzed using the B-H curves of the materials. If there is no saturation, the product of the permeability constant and the relative permeability will be constant regardless of the magnetic field strength (H).
For higher values of the magnetic field strength (H), saturation effects become more important and it cannot be considered as a constant value. The B-H curve of the ferromagnetic parts of a typical solenoid actuator, which is 11SMN30, is shown in Figure 2. 31 It shows that there is a nonlinear relationship between the magnetic field strength (H) and the magnetic flux density (B).
The well-known Maxwell equation, which represents the distribution of the electromagnetic field of the solenoid actuator, can be expressed as equation (3). 32 where s, A, and j ext are the electrical conductivity, the magnetic vector potential, and the current density due to the external source, respectively. r is Nabla or Del operator for vector calculations which is used as a vector differential operator. The basic mechanical model of the solenoid actuator uses the second law of Newton to formulate the displacement of the plunger as equation (4). 22 where m, c, and k are mechanical parameters which represent the mass of the moving part, the friction coefficient, and the stiffness of the spring, respectively. F m (t) and F r (t) represent the magnetic force and the friction force, respectively. In the solenoid actuators, there is a linear relationship between the magnetic force and the current of the coil. However, this linear relationship is valid only for a portion of the full displacement of the plunger. 33 For the other portion of the plunger's displacement, there is a nonlinear relationship between the magnetic force F m (t), the current of the coil i(t), and the displacement of the plunger x(t).

Simulations and experimental test results
In this research, the magnetic field analysis is performed through electromagnetic modeling and FEA of the 2D axis-symmetric model of the solenoid actuator. The material used for the simulation of the different parts of the solenoid actuator is as follows: The material of the coil is assigned as copper. Stainless steel is used for the anti-magnetic parts of the actuator. Since the electromagnetic characteristics of the material (B-H curve, electrical conductivity, relative permeability, and relative permittivity) of the existing solenoid actuator are similar to those of 11SMN30, it has been assigned to the ferromagnetic parts of the solenoid actuator.
The nonlinear B-H curve of the ferromagnetic material 11SMN30 is used for magnetic field calculations. The input current to the coil is 2.7 A and it consists of 430 turns of winding. The electrical conductivity of the coil windings and the coil windings' diameter are chosen as 6 3 10 7 S/m and 0.7 mm, respectively. The magnetic force is calculated for the full displacement of the plunger in the working gap. For each position of the plunger, different parts of the solenoid actuator are analyzed with triangular mesh. The numerical simulation result of the solenoid actuator is validated with experimental data for magnetic force versus displacement of the plunger and is represented in Figure 3. The maximum error between the model and the experimental data within the working region range of 2.7-5 mm is as low as 1.82%.
The force increases up to a maximum value where the plunger reaches its effective working region. In this position, the plunger reaches the edge of the antimagnetic part. This portion of displacement is used for fluid flow control in hydraulic valves. In solenoid actuators, having a high magnetic force that stays almost constant in the effective working region of a solenoid actuator is a desirable goal that should be achieved.  In the simulation of the solenoid actuator, the material of different parts of the solenoid, the coil characteristics, including current, the diameter of the windings, and the number of windings are kept constant and are not considered as optimization parameters. The effect of all the geometrical parameters of the solenoid actuator on the magnetic field is investigated when it operates at 2.7 A. For this aim, Finite Element Analysis (FEA) is performed for different geometrical parameters of all parts of the solenoid actuator to investigate their effects on the magnetic force. Moreover, some geometrical variations were made to simplify the manufacturing of the solenoid actuator. The conical angles on both sides of the anti-magnetic part were eliminated and fixed to zero degrees. Since the tubular shape of the plunger gives the flexibility to control the magnetic force, the flat tubular shape of the plunger is changed to a conical tubular shape. For simplicity, some parts of the actuator that are not affecting the magnetic field were eliminated in the simulation process. The push-pin is made of stainless steel and can be ignored in the model as it does not affect the magnetic field. The re-designed model of the solenoid actuator and the most important parameters, including R, W, L1, L2, and u that highly affect the magnetic field are represented in Figure 4.
The five most important parameters (R, W, L1, L2, and u) that affect the magnetic force values in the plunger's working region are chosen as optimization parameters. Five different values of these parameters, including their lower and upper bounds, are selected as optimization constraints. Since the solenoid actuator will be attached to the hydraulic valve mechanism, the geometry of the solenoid actuator has to fit within the mechanism's bounds. Therefore, the lower and upper bounds of the solenoid actuator are determined by the dimensions of the hydraulic valve mechanism. The effect of each of these parameters on the magnetic force is shown in Figures 5 to 9. Figure 5 shows that the magnetic force values increase by increasing the value of R. It shows that the magnetic force reaches its maximum and minimum values in the plunger's effective working region (2.7-5 mm) when R is 11.35 and 8.35 mm, respectively. It could be concluded that this parameter affects the magnitude of the magnetic force and it has to be considered as an optimization parameter. Figure 6 shows that the magnetic force values increase by increasing the value of W. It demonstrates that the magnetic force reaches its maximum and minimum values in the effective working region of the plunger (2.7-5 mm) when W is 3.5 and 1.5 mm, respectively. Consequently, it could be concluded that W has a significant effect on the magnitude of the magnetic force. Figure 7 shows that the magnetic force values increase by increasing the value of L1 in some working  regions of the plunger. It demonstrates that the magnetic force reaches its maximum and minimum value in some portions of the effective working region of the plunger (3.7-5 mm) when L1 is 2.5 and 5.7 mm, respectively. However, a slight change in the magnetic force values is observed in the other portion of the effective working region (2.7-3.7 mm). Moreover, L1 values affect the slope of the magnetic force versus plunger displacement. Consequently, it could be concluded that L1 has a significant effect on the magnitude and consistency (the slope of the magnetic force vs plunger displacement curve) of the magnetic force. Figure 8 shows that the magnetic force values increase by decreasing the value of L2 in some working regions of the plunger. It shows that the magnetic force reaches its maximum and minimum value in different effective working regions of the plunger when L1 is 4 and 6 mm, respectively. Consequently, it could be concluded that L2 has a significant effect on the magnitude of the magnetic force. Figure 9 shows that the consistency of the magnetic force values varies by increasing the value of u in the plunger's effective working region (2.7-5 mm). It shows that the magnetic force is more consistent (the slope of the magnetic force vs plunger displacement curve is very small) when u values are chosen at about 88. However, increasing or decreasing the u value from this value inversely affects the consistency of the magnetic force, which is not desirable. It means that the positive or negative slope of the magnetic force versus plunger displacement curve, which is observed in 168 and 08, should be avoided. As a result, u has a significant effect on the consistency and magnitude of the magnetic force.
Consequently, these five parameters, which considerably affect the magnitude and consistency (the slope of the magnetic force versus plunger displacement curve)  of the magnetic force in the plunger's effective working region, are chosen as optimization parameters. For obtaining the generated magnetic force in the solenoid actuator, five different simulations were carried out for five different values of parameters within their lower and upper bound values. In total, 5 5 simulations (3125) were repeated for all combinations of these five parameters. To save time during the optimization process, data for the different combinations of these parameter values within simulated values was generated using the interpolation technique in MATLAB software.
Design optimization of the solenoid actuator with a particle swarm optimization (PSO) algorithm In recent years, evolutionary techniques for solving different optimization problems have become a very popular research topic in different engineering fields. There are many evolutionary algorithms, such as Genetic Algorithms (GA), Differential Evolution (DE), Particle Swarm Optimization (PSO), etc., that are commonly used to solve geometry optimization problems. In the literature, some comparative studies discuss the PSO algorithm's advantages over other evolutionary methods. Wihartiko et al. 34 state that the PSO algorithm is superior in terms of complexity, accuracy, iteration number, and program simplicity in finding the optimal solution when compared to the Genetic Algorithm (GA). 34 They show that the average accuracy of GA is 99% for obtaining an optimal solution, whereas the PSO always gives the solution with 100% accuracy for the proposed optimization problem. In other research, Kecskes et al. 35 state that the PSO algorithm is a simple and effective method for complex optimization problems. They showed that the PSO  algorithm gives better and faster results compared to the GA. Moreover, some studies have been performed to evaluate the performance of the PSO algorithm using statistical analysis. In Firouzi et al., 36 the performance of different optimization algorithms is compared using statistical post hoc analysis. The PSO algorithm shows relatively accurate performance in finding the optimal solutions. The performance of a typical multi-objective particle swarm optimization algorithm is investigated in Nebro et al. 37 They statistically demonstrated that the PSO algorithm with multiple objectives gives more accurate estimations and also converges to the Pareto front more swiftly. In other work, statistical analysis is performed to test the performance of the PSO algorithm. 38 They showed that the standard deviation of the estimation of the PSO algorithm is very low, which shows the robustness of the obtained optimal solutions. Although the PSO algorithm is a well-known optimization method, it has not been used for solenoid design optimization purposes. Hence, in this research, it is preferred to use the PSO algorithm for geometry optimization of the solenoid actuator due to its superiority over other methods. Furthermore, a multiple objectives are introduced as a novelty of this research to optimize the existing solenoid actuator.
The PSO is an optimization method that is inspired by animal swarming behavior and it iteratively searches for the optimal solution. 39 The three main steps that are used to find an optimal solution are particle initialization, particle velocity update, and particle position update. In the first step, the particle positions are initialized randomly within the acceptable lower and upper bounds of the data. Then, the velocity (V id ) of the particle uses equation (5) to direct the position of the particles (X id ) within the solution space of the problem.
where, x, C 1 , and C 2 are positive values corresponding to the inertia weight, the self-confidence, and the swarm confidence, respectively. 39 The values of global best and particle best are shown with gBest and pBest. The differences between the global best and particle best are multiplied by the random values between ranges [0 1] which are represented by r 1 and r 2 . The PSO algorithm parameters are set using a trial-and-error method, and the values of the corresponding parameters are as follows: The algorithm has five dimensions, and 10 particles are assigned to each of these dimensions. The maximum iteration is 1000 and the inertia weight (x) is chosen as 0.9. The values of the self-confidence (C 1 ) and the swarm confidence (C 2 ) are tuned to 2. After particle velocity calculation, the new positions of the particles (X id ) are updated as shown in equation (6). 39 These iterative steps are repeated until the optimal solution is found.
In this research, the optimization problem is considered a maximization problem that has two distinct objectives. One of the design objectives is to obtain the maximum value of the magnetic force and the other one is to minimize the DF=DX (the slope of the magnetic force vs plunger displacement curve) values to obtain an almost constant magnetic force throughout the effective working stroke. To combine these two design objectives into a single objective function, 1=(DF=DX ) is used in the objective function, reducing the problem to a maximization problem with a single objective function. The overall objective function (J) of the solenoid actuator design problem is obtained as shown in equation (7).
where k1 and k2 are the weights of each component of the objective function. According to the design goals, the weights could be tuned easily between 0 and 1 values to give weights to the objective functions. In this research, there is a trade-off between the two design goals. Hence, the value of both weights is set to 1. J 1 and J 2 are objective functions of the PSO algorithm, which are introduced as equations (8) and (9) so that they both have an equal effect on the optimization. The values of F m and 1=(DF=DX ) are normalized using equations (8) and (9) so that they both have an equal effect on the optimization.
The geometrical design parameters of the solenoid actuator are the dimensions of particles that should be optimized to satisfy both parts of the objective function. The dimensions of the particles and their bounds are given in Table 1.

Results and discussion
The optimized design parameters obtained through the PSO algorithm and their original values are given in Table 2.
The numerical simulations were repeated for optimized parameters to obtain the magnetic force. Finally, the solenoid actuator with optimized parameters is manufactured and attached to the industrial hydraulic valve. The manufactured solenoid along with the experimental setup is shown in Figure 10.
The comparison of the simulation and experimental magnetic force results of the manufactured solenoid actuator with optimal design parameters along with original design is shown in Figure 11. Figure 11 shows that the new design of the solenoid actuator with optimal geometrical design parameters satisfies the first part of the objective function. For evaluation of this part of the objective function, the slope of the magnetic force versus displacement of the plunger (DF=DX ) in the effective working region between x = 3 mm and x = 5 mm is calculated. The change of magnetic force in the effective working region (DF=DX ) for the original design is 23.85 N/mm and for the optimized design is 0.66 N/mm. It shows that there is an almost constant magnetic force in the working region of the optimized design of the solenoid actuator. The simulation results show that both parts of the objective function are satisfied. It means that the simulated model with optimal parameters gives a higher magnetic force that stays almost constant in the effective working region of the solenoid actuator. However, the experimental result shows that only the first part of the objective function of the optimization algorithm is satisfied. For some possible reasons, the second part of the objective function is not satisfied. The material of the ferromagnetic parts of the solenoid actuator has an important effect on the magnetic force. Since the B-H curve of the ferromagnetic material used in the manufacturing of the solenoid actuator was not available, the exact B-H curve values of the material were not used in the simulations. Another possible reason for lower magnetic force values is related to manufacturing process errors. Since the conic tubular plunger needs a sensitive machining process, the angle of the conic part may not be equal to the optimal angle value.

Conclusion
In this research, the PSO algorithm with multiple objectives was realized to optimize the geometry of a typical solenoid actuator. For this aim, numerical simulation of the existing solenoid actuator is performed and verified with experimental data before the optimization process. To improve the performance of the existing design of the solenoid actuator, the following variations were made: The flat tubular shape of the plunger is altered to a conic tubular shape to improve the generated magnetic field. For simplicity in manufacturing, the angles of the anti-magnetic part were eliminated and fixed to zero degrees. Then, the FEA is performed to investigate the effect of all design parameters on the magnetic field. To simplify the problem, the most important parameters were chosen as optimization parameters. For the design optimization of the solenoid actuator, a PSO algorithm is coded and implemented in the MATLAB software package. The optimization algorithm consists of two goals combined into a single objective function, including maximizing the magnetic force and keeping it almost constant (DF=DX should be minimized) in the working region of the solenoid actuator. The suggested objective function allows more flexibility in the design procedure, which helps to give a desired weight to each of the objective functions according to their priority. The simulation is repeated for the optimized parameters to obtain the magnetic force versus displacement of the plunger. Finally, the solenoid actuator with optimal parameters was manufactured, and the experimental setup was built to acquire the magnetic force values of the actuator for a given input current (2.7 A). The simulation and experimental results of the magnetic force values for the solenoid actuator with optimal design parameters were compared. It has been shown that the magnetic force values of the simulation result satisfy both parts of the objective function. However, the experimental result acquired from the manufactured solenoid actuator with optimal design parameters only satisfies the second part of the objective function. It means that the magnetic force values stay almost constant (DF=DX was minimized) in the effective working region of the actuator, which is a significant improvement compared to the original design. However, the second part of the objective function, which is to obtain higher magnetic values in the effective working region, is not satisfied. There are some possible reasons for the discrepancy between the simulation and experimental results. First, since measuring the exact B-H curve of the material used for the manufacturing of the solenoid actuator was not possible, the utilized approximated curves in the simulations may not represent the real electromagnetic characteristics of the material. Another possible reason for lower magnetic force values is related to manufacturing process errors. According to the existing machining errors, the tubular plunger with the conical edge has not been manufactured with high precision.
In future work, the reasons for the existing discrepancy between simulation and experimental results will be investigated. Moreover, the design parameters of the coil of the solenoid actuator will be further improved with the utilization of the optimization algorithm. The optimization algorithm can be used to improve the performance of the other electromagnetic components.

Author contributions
The authors contributed equally to the paper. There is mutual agreement about the order of the authors' names.

Declaration of conflicting interests
The author(s) declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.

Funding
The author(s) disclosed receipt of the following financial support for the research, authorship, and/or publication of this article: This research was supported by the Scientific and Technological Research Council of Turkey (TÜ B _ ITAK-TEYDEB) with grant number 1180155.