Design of Adaptive-RST Controller for Nonlinear Magnetic Levitation System Using Multiple Zone-Model Approach in Real-Time Experimentation

: A system with multiple controllers and a multiple-model architecture is one of the most effective solutions for the real-time control of nonlinear systems. The employment of these structures necessitates the resolution of certain difﬁculties, such as selecting the optimal algorithm or switching control algorithms. Based on the concepts of auto-transfer, the paper provides a way for switching the numerous controller structures’ algorithms. This paper presents a real-time dynamic model and platform of a magnetic levitation system (Maglev). The method’s applicability was demonstrated by utilizing a real-time architecture with an RST controller mechanism and real. In conclusion, the software was implemented and demonstrated by using the LabVIEW platform in real-time, and the results reveal that this solution can stabilize the ball’s location and has strong disturbance rejection because of the multi-zone effect.


Introduction
In recent years, magnetic levitation technologies have been used in a wide range of applications. Its major performance has led to its deployment in a wide variety of uses, including wind turbines, high-speed rails, building management systems, personal rapid transit, nuclear reactors, food inspection systems, military weapons, household appliances, and biomedical devices [1][2][3][4].
The magnetic levitation technology with no physical friction with the railway has advantages such as low noise, frictionless motion, and high speed in the process. The system's stability, on the other hand, is a difficult problem to solve [5].
There are a variety of controllers that may be used to design feedback systems in linear systems [6][7][8][9][10], but the RST controller is one of the most common. This controller is intended to strike a balance between the amount of control effort required and the reaction time of the system.
In an ideal world, the magnetic force produced by an electromagnet powered by electricity would be greater than the weight of the steel ball. However, because the fixed electromagnetic force is very sensitive to noise, the noise creates acceleration pressures on the steel ball. This causes the Maglev system model to become unstable due to unstable (positive) poles, which makes the ball move into the unstable (unbalanced) zone.
By using multiple models and multiple controllers, a set-point supervisory control methodology for switching and tuning magnetic levitation systems is proposed in this research. A local platform simulation of a highly nonlinear continuous real-time (MAGLEV) process was used to test this control method. Each of these models' models and controllers was estimated using a closed-loop adaptive control algorithm, and each of these models was controllers was estimated using a closed-loop adaptive control algorithm, and each of these models was tuned to a specific operating point. Then, a smart supervisor was put in place to manage the switching between multiple models and select the most appropriate and effective controller for the plant at any given time. When compared to a closed loop controller, the simulation results for three different set-point scaling scenarios show that the suggested control strategy is more effective and resilient in terms of performance and robustness.

Magnetic Levitation System (Maglev)
This section is devoted to a thorough examination of the magnetic levitation system (Maglev) and nonlinear modeling. Maglev is demonstrated through analyses and modeling.

Magnetic Levitation System Overview
A ferromagnetic steel ball was suspended in a magnetic field (voltage-controlled) in the MAGLEV system considered. The block diagram of MAGLEV is shown in Figure 1. Electromagnetism is used to move a ferromagnetic (steel) ball, while an optoelectronic sensor measures its position. A steel ball floats in mid-air due to a controller's ability to manage the flow of electricity in a circuit so that the electromagnetic force is equal to the weight of the steel ball. A nonlinear controller is required to keep an open-loop system stable [11].

The (Maglev) System Dynamics
The magnetic levitation system's mathematical model can be found by constructing appropriate differential equations based on common electrical and mechanical principles. In the impending mode, the components' paths might be anticipated to be easier or more complex. Within the system, the energetic balance formula is [12]: Electromagnetism is used to move a ferromagnetic (steel) ball, while an optoelectronic sensor measures its position. A steel ball floats in mid-air due to a controller's ability to manage the flow of electricity in a circuit so that the electromagnetic force is equal to the weight of the steel ball. A nonlinear controller is required to keep an open-loop system stable [11].

The (Maglev) System Dynamics
The magnetic levitation system's mathematical model can be found by constructing appropriate differential equations based on common electrical and mechanical principles. In the impending mode, the components' paths might be anticipated to be easier or more complex. Within the system, the energetic balance formula is [12]: ∆Welec: is the fluctuation of the electrical energy; ∆Wther: is the fluctuation of the thermal energy; ∆Wmec: is the fluctuation of the mechanical energy; ∆Wmag: is the fluctuation of the magnetic energy.

Description of the Mechanical Model of the Maglev System
When levitated bodies move through a magnetic field and the magnetic fluxes change, the magnetic energy changes as shown in [13]: (2) where: i is the coil winding's DC current; ∆∅ represents the variation in magnetic flux through the magnetic field; ∆x is the variance of the levitated body's (steel ball) position with respect to the electromagnet coil; F em (x, i, t): represents the electromagnetic sustentation force. The electromagnetic levitation force F em (x, i, t) can be calculated using the generalized forces theorem as follows: A coil's specific magnetic energy is: The inductivity L(x) can be determined directly or by utilizing reluctance. According to this relationship, the coil inductivity L(x) is dependent on the ferromagnetic ball's position x: x o x (5) where: L o represents the coil inductivity when the ball is away; L 1 represents the coil inductivity when the ball is ready; x o represents the equilibrium position of the ball. Substituting Equations (4) and (5) into Equation (3) yields: where: c = L 1 .x o 2 is the magnetic force constant. Figure 2 depicts a ferromagnetic ball in equilibrium with its electromagnetic force F em (x, i, t) and gravitational force F g .
Newton's third law of motion determines the net force F net acting on the ball [14]: m is the mass of the ball; g is the gravitational acceleration constant.

The System Identification Modeling Using Multi Zone-Model Approach
The variation in magnetic energy when levitated bodies move within a magnetic field and the magnetic fluxes vary with the position of the ball. This paper suggests dividing the zone of the desired position into multiple zones, as shown in Figure 2. Moreover, x1, x2, and x3 are the three positions of the ball or three zones desired when = ( ) = ( ) .

System Identification Process
The three model zones were identified by using pseudo-random signals and pole placement methods to find the models, as shown in Figure 3 [15]: The process of creating pseudo-random signals (PRBS) is based on a series of random pulses that are sent out at regular intervals. The main algorithm is to make a pattern that

The System Identification Modeling Using Multi Zone-Model Approach
The variation in magnetic energy when levitated bodies move within a magnetic field and the magnetic fluxes vary with the position of the ball. This paper suggests dividing the zone of the desired position into multiple zones, as shown in Figure 2.
Moreover, x1, x2, and x3 are the three positions of the ball or three zones desired when

System Identification Process
The three model zones were identified by using pseudo-random signals and pole placement methods to find the models, as shown in Figure 3

The System Identification Modeling Using Multi Zone-Model Approach
The variation in magnetic energy when levitated bodies move within a magnetic field and the magnetic fluxes vary with the position of the ball. This paper suggests dividing the zone of the desired position into multiple zones, as shown in Figure 2. Moreover, x1, x2, and x3 are the three positions of the ball or three zones desired when = ( ) = ( ) .

System Identification Process
The three model zones were identified by using pseudo-random signals and pole placement methods to find the models, as shown in Figure 3 [15]: The process of creating pseudo-random signals (PRBS) is based on a series of random pulses that are sent out at regular intervals. The main algorithm is to make a pattern that The process of creating pseudo-random signals (PRBS) is based on a series of random pulses that are sent out at regular intervals. The main algorithm is to make a pattern that has a wide range of frequencies so that the system can be identified [16]. A virtual instrument from the LabVIEW VI platform (Figure 4) was used to identify the models: has a wide range of frequencies so that the system can be identified [16]. A virtual instrument from the LabVIEW VI platform ( Figure 4) was used to identify the models: The process simulator software application when one analyzes the three different operating zones, Z1, Z2, and Z3, on the plant's nonlinear diagram is shown in Figure 3. Three distinct models were recognized as follows: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%), if we consider the desired position between 0 and 100%. Appropriate algorithms were implemented in these zones [17,18]. The relationship diagram of the process between PRBS signal and output is based on how well the models and algorithms fit the zones ( Figures 5-7). The data in (Figures 5-7) present the input and output signals for three zones that were used to find the models.
The models M1, M2, and M3 were identified as being appropriate for the following intervals: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%), respectively. The following models were identified using the least-squares identification method available on the WinPIM platform software [15,19]. The sample period = 0.1 s was used. The amplitude in volts and time in ms were used.  The process simulator software application when one analyzes the three different operating zones, Z1, Z2, and Z3, on the plant's nonlinear diagram is shown in Figure 3. Three distinct models were recognized as follows: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%), if we consider the desired position between 0 and 100%. Appropriate algorithms were implemented in these zones [17,18]. The relationship diagram of the process between PRBS signal and output is based on how well the models and algorithms fit the zones ( Figures 5-7). The data in (Figures 5-7) present the input and output signals for three zones that were used to find the models. The process simulator software application when one analyzes the three different operating zones, Z1, Z2, and Z3, on the plant's nonlinear diagram is shown in Figure 3. Three distinct models were recognized as follows: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%), if we consider the desired position between 0 and 100%. Appropriate algorithms were implemented in these zones [17,18]. The relationship diagram of the process between PRBS signal and output is based on how well the models and algorithms fit the zones ( Figures 5-7). The data in (Figures 5-7) present the input and output signals for three zones that were used to find the models.
The models M1, M2, and M3 were identified as being appropriate for the following intervals: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%), respectively. The following models were identified using the least-squares identification method available on the WinPIM platform software [15,19]. The sample period = 0.1 s was used. The amplitude in volts and time in ms were used.     ( where ( ) ( ) polynomials are: The three models are obtained as shown below:

Control System Design
Different techniques, such as the RST controller, have been proposed in recent years. The acronym RST stands for Regulation (R), Sensitivity (S), and Tracking (T) control. It is also linked to the polynomials r(z), s(z), and t(z) that are used in the two-degree of freedom controller structure [15,19]. The design steps of an RST controller to stabilize the nonlinear model of a Maglev system are presented in this section [20,21]. The optimum RST controllers were determined by the parameters chosen based on the three models that are found in the previews section. The control strategy was used, as shown in Figure 8 [20], with the supervisor architecture. The models M1, M2, and M3 were identified as being appropriate for the following intervals: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%), respectively. The following models were identified using the least-squares identification method available on the WinPIM platform software [15,19]. The sample period T e = 0.1 s was used. The amplitude in volts and time in ms were used.
where A q −1 and B q −1 polynomials are: The three models are obtained as shown below:

Control System Design
Different techniques, such as the RST controller, have been proposed in recent years. The acronym RST stands for Regulation (R), Sensitivity (S), and Tracking (T) control. It is also linked to the polynomials r(z), s(z), and t(z) that are used in the two-degree of freedom controller structure [15,19]. The design steps of an RST controller to stabilize the nonlinear model of a Maglev system are presented in this section [20,21]. The optimum RST controllers were determined by the parameters chosen based on the three models that are found in the previews section. The control strategy was used, as shown in Figure 8 [20], with the supervisor architecture.

RST Controller Design
The RST control algorithm was used with the MAGLEV system ( Figure 9) [15,19]: where y(k) = process output, u(k) = algorithm output, and y*(k) = trajectory or filtered set point. The corresponding parameters are: The RST controller with a closed-loop system is shown in Figure 9. The control law in (12) can be redesigned as shown below:

RST Controller Design
The RST control algorithm was used with the MAGLEV system ( Figure 9) [15,19]: where y(k) = process output, u(k) = algorithm output, and y*(k) = trajectory or filtered set point. The corresponding parameters are: R q −1 = r 0 + r 1 q −1 + · · · + r nR q −nR (14) The RST controller with a closed-loop system is shown in Figure 9.
Appl. Syst. Innov. 2022, 5, x FOR PEER REVIEW 7 of 13 Figure 8. Structure of the system with supervisory control architecture.

RST Controller Design
The RST control algorithm was used with the MAGLEV system ( Figure 9) [15,19]: where y(k) = process output, u(k) = algorithm output, and y*(k) = trajectory or filtered set point. The corresponding parameters are: ( The RST controller with a closed-loop system is shown in Figure 9. The control law in (12) can be redesigned as shown below: The control law in (12) can be redesigned as shown below: n S , n R , and n T represent the respective polynomial degrees as well as the memory dimension for the algorithm's software implementation. For example, if n R = 2, three memory places should be saved for the process's output: y(k), y(k − 1), y(k − 2). The same method applies to y*(k) and u(k), respectively.
One must be interested in the control method and, finally, the trajectory model generator for practical implementation. One cycle of the continuous monitoring procedure includes the following steps: acquisition of the process's inputs; computation of the trajectory (if necessary); computation of the control law; transmission of the controls to the actuators; graphical representation of the process's evolution; and memory update of the algorithms for the next iteration.
For example, if we have n S = n R = n T = 2, and without trajectory generator (y*(k) = r(k)), the control law computation is as the following: and (11) gives the algorithm's memory actualization for the next iteration:

RST Controller Parameters Calculation
In this case, we used a pole placement procedure from the WinREG platform to figure out three RST algorithms. Through a second-order system, all systems were forced to have the same nominal performance, which is defined by the dynamics ω 0 = 7.5, ξ = 0.8 tracking performances, and disturbance rejection performances, respectively, while keeping the same sampling period as for the identification, T s = 0.1. All of these algorithms are only in charge of the process in their own zones.

Adaptive Supervisor and Switching
When the plant parameter vector switches rapidly (or discontinuously) between two values, p1 and p2, the adaptive method must be able to detect the change and switch to the appropriate controller to avoid catastrophic failure. The use of multiple (fixed) models permits the rapid selection of a fixed controller from a set of controllers, which can also be considered adaptive [22].
The following are some of the important questions that have to be addressed when multiple models are used for adaptive control: (1) When is it appropriate to make the transfer from one model to another? We need to decide which model to use; (2) When is a switching scheme stable? Will switching stop after a finite time? Will the switching scheme improve performance?
The switching criterion (or switching rule), which provides the answer to question (1), plays an important role in system design. Various performance indices can be chosen based on the estimation error to determine which of the models best fits the plant at any given time and should thus be used to regulate it. These may assume the following forms for continuous-time systems and their discrete-time counterparts.
The main method of switching depends on two main criteria, as shown in Figure 10. The first one is the set point because our multi-models depend on the level of the set point or zones, and the second one is the error, but this works just when the set point or model is in the common zones between two models, where the error identifies which controller is suitable. Three different zones are identified in the preview sections: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%). If we consider the desired position between 0 and 100 percent, the common zones are between Z1 and Z2 (30-40%) and between Z2 and Z3 (60-70%) [17].
Appl. Syst. Innov. 2022, 5, x FOR PEER REVIEW 9 of 13 based on the estimation error to determine which of the models best fits the plant at any given time and should thus be used to regulate it. These may assume the following forms for continuous-time systems and their discrete-time counterparts.
The main method of switching depends on two main criteria, as shown in Figure 10. The first one is the set point because our multi-models depend on the level of the set point or zones, and the second one is the error, but this works just when the set point or model is in the common zones between two models, where the error identifies which controller is suitable. Three different zones are identified in the preview sections: Z1 (0-40%), Z2 (30-70%), and Z3 (60-100%). If we consider the desired position between 0 and 100 percent, the common zones are between Z1 and Z2 (30-40%) and between Z2 and Z3 (60-70%) [17].

Real-Time Implementation and Results
In this section, the experimental results for the proposed multi-controller and multimodel approaches with the MAGLEV system are presented. The local-platform system is proposed, as shown in Figure 11. LabVIEW was used to implement the real-time part with NI USB-6008 12-bit as the data acquisition. The MAGLEV system hardware also contains a Hall effect 49E sensor, electromagnetic coils, filters (hardware), a Dc Driver, and a realtime operating environment.

Real-Time Implementation and Results
In this section, the experimental results for the proposed multi-controller and multimodel approaches with the MAGLEV system are presented. The local-platform system is proposed, as shown in Figure 11. LabVIEW was used to implement the real-time part with NI USB-6008 12-bit as the data acquisition. The MAGLEV system hardware also contains a Hall effect 49E sensor, electromagnetic coils, filters (hardware), a Dc Driver, and a real-time operating environment.
As an experiment, Case 1 was imposed, and the model M2 was the model of the system. Therefore, the controller of M2 in the multi-control approach was C2 (R 2 , S 2 , T 2 ) but the system was forced to choose controller C1 as a test to see the response and performance of the Maglev system. Figure 12 depicts the response and performance of Case 1; slow rise time, high overshoot, high settling time, and weak rejecting the disturbances.

Real-Time Implementation and Results
In this section, the experimental results for the proposed multi-controller and multimodel approaches with the MAGLEV system are presented. The local-platform system is proposed, as shown in Figure 11. LabVIEW was used to implement the real-time part with NI USB-6008 12-bit as the data acquisition. The MAGLEV system hardware also contains a Hall effect 49E sensor, electromagnetic coils, filters (hardware), a Dc Driver, and a realtime operating environment. Figure 11. The magnetic levitation system platform. Figure 11. The magnetic levitation system platform.
Appl. Syst. Innov. 2022, 5, x FOR PEER REVIEW 10 of 13 As an experiment, Case 1 was imposed, and the model M2 was the model of the system. Therefore, the controller of M2 in the multi-control approach was C2 ( , , ) but the system was forced to choose controller C1 as a test to see the response and performance of the Maglev system. Figure 12 depicts the response and performance of Case 1; slow rise time, high overshoot, high settling time, and weak rejecting the disturbances. In the same way, considering the M2 as the main model of the system (Case 2), the process was repeated, but this time with ( , , ) as the controller. The result was also not good, with slow rise time, higher overshoot, higher settling time, and weak ability to reject the disturbances, as shown in Figure 13.  Figure 14 depicts the effect of multi-model and multi-control on the MAGLEV response; the three zones show good and strong performances as overshoot, rise time, settling time, and rejection of the disturbances for all zones. Table 1 shows a comprehensive comparison using the basic criteria. In the same way, considering the M2 as the main model of the system (Case 2), the process was repeated, but this time with (R 3 , S 3 , T 3 ) as the controller. The result was also not good, with slow rise time, higher overshoot, higher settling time, and weak ability to reject the disturbances, as shown in Figure 13. As an experiment, Case 1 was imposed, and the model M2 was the model of the system. Therefore, the controller of M2 in the multi-control approach was C2 ( , , ) but the system was forced to choose controller C1 as a test to see the response and performance of the Maglev system. Figure 12 depicts the response and performance of Case 1; slow rise time, high overshoot, high settling time, and weak rejecting the disturbances. In the same way, considering the M2 as the main model of the system (Case 2), the process was repeated, but this time with ( , , ) as the controller. The result was also not good, with slow rise time, higher overshoot, higher settling time, and weak ability to reject the disturbances, as shown in Figure 13.  Figure 14 depicts the effect of multi-model and multi-control on the MAGLEV response; the three zones show good and strong performances as overshoot, rise time, settling time, and rejection of the disturbances for all zones. Table 1 shows a comprehensive comparison using the basic criteria.   Table 1 shows a comprehensive comparison using the basic criteria.  Figure 14 depicts the effect of multi-model and multi-control on the MAGLEV response; the three zones show good and strong performances as overshoot, rise time, settling time, and rejection of the disturbances for all zones. Table 1 shows a comprehensive comparison using the basic criteria.   The proposed real-time platform presents an economical solution that is not expensive (hardware and software) and more stable (hardware and software from National Instruments Company [23]) compared with our previous paper [13], which used elements from different companies. For example, the DC Driver and filters were created from cheap and basic components (resistors, capacitors, transistors, etc.).
The test of switching showed in Figure 15 that this method is stable. We can see that in both tests, there are either no shocks or low bumps in how the control evolves. As shown in Table 2, all of the parameters (overshoot, settling time, rise time, and shocks test) are excellent and proof that each model/identified process, in a closed loop, is stable. If there were more (4 or 5) models or algorithms, the little oscillations could be stopped.  The proposed real-time platform presents an economical solution that is not expensive (hardware and software) and more stable (hardware and software from National Instruments Company [23]) compared with our previous paper [13], which used elements from different companies. For example, the DC Driver and filters were created from cheap and basic components (resistors, capacitors, transistors, etc.).
The test of switching showed in Figure 15 that this method is stable. We can see that in both tests, there are either no shocks or low bumps in how the control evolves. As shown in Table 2, all of the parameters (overshoot, settling time, rise time, and shocks test) are excellent and proof that each model/identified process, in a closed loop, is stable. If there were more (4 or 5) models or algorithms, the little oscillations could be stopped.  The last comparison is between the results obtained in our previous paper [13] under the title (design of PID controller for nonlinear magnetic levitation system using fuzzytuning approach) ( Figure 16) and the method in this paper. The result, shown in Table 3, also shows that this method is better than (fuzzy-PID single controller) in overshoot, set-  The last comparison is between the results obtained in our previous paper [13] under the title (design of PID controller for nonlinear magnetic levitation system using fuzzytuning approach) ( Figure 16) and the method in this paper. The result, shown in Table 3, also shows that this method is better than (fuzzy-PID single controller) in overshoot, setting time rise time, and rejecting the disturbances.

Conclusions
The following findings can be drawn from the research: 1. This paper deals with a magnetic-levitation (maglev) system. Real-time experimentation and simulations both confirmed the effectiveness of the maglev transportation system's control strategy by using multi-model and multi-control approaches; 2. The maglev system is nonlinear and very sensitive to disturbances, which is why the set point is divided into three zones to obtain three models; 3. The three models were computed using the least-squares identification approach and the generation of pseudo-random signals (PRBS). LabVIEW and WinPIM were utilized in real-time to locate all models; 4. The method's applicability was demonstrated by utilizing a real-time structure with an RST control mechanism, and all parameters of the RST controller were computed by using the WinREG platform; 5. Supervisor switching was implemented with two main criteria. The first one is the set point, and the second one is the level of the error; 6. On the LabVIEW platform, experimental results are tested by conducting regulation and tracking experiments. The results of the experiments show that this method is very good, with strong response and stability. Smooth and exponential convergence of system variables to their desired levels with three zones; 7. The experimental results also showed that the multi-zone model with multi-controller approaches is better with rising time, overshoot, settling time, rejecting the disturbances, and total response; 8. The proposed real-time-platform presents an economical solution, not expensive (hardware and software), and more stable when compared with our previous paper [13]; 9. The obtained results sustain proposed solutions and suggest future steps, such as robustness conditions designed for bumpless switching in multiple model control Figure 16. The response of PID controller using fuzzy-tuning approach [13]. Table 3. Comparison between the proposed solution (multi-model and multi-controller) with the results obtained in our previous paper [13] under the title (design of PID controller for nonlinear magnetic levitation system using fuzzy-tuning approach).

Conclusions
The following findings can be drawn from the research: 1. This paper deals with a magnetic-levitation (maglev) system. Real-time experimentation and simulations both confirmed the effectiveness of the maglev transportation system's control strategy by using multi-model and multi-control approaches; 2.
The maglev system is nonlinear and very sensitive to disturbances, which is why the set point is divided into three zones to obtain three models; 3.
The three models were computed using the least-squares identification approach and the generation of pseudo-random signals (PRBS). LabVIEW and WinPIM were utilized in real-time to locate all models; 4.
The method's applicability was demonstrated by utilizing a real-time structure with an RST control mechanism, and all parameters of the RST controller were computed by using the WinREG platform;

5.
Supervisor switching was implemented with two main criteria. The first one is the set point, and the second one is the level of the error; 6.
On the LabVIEW platform, experimental results are tested by conducting regulation and tracking experiments. The results of the experiments show that this method is very good, with strong response and stability. Smooth and exponential convergence of system variables to their desired levels with three zones; 7.
The experimental results also showed that the multi-zone model with multi-controller approaches is better with rising time, overshoot, settling time, rejecting the disturbances, and total response; 8.
The proposed real-time-platform presents an economical solution, not expensive (hardware and software), and more stable when compared with our previous paper [13]; 9.
The obtained results sustain proposed solutions and suggest future steps, such as robustness conditions designed for bumpless switching in multiple model control structures [24];