Intelligent control method and system of brushless direct current motor, and storage medium
Through the improved Sand Cat Group algorithm optimization algorithm, combined with Cubic chaos mapping, Gaussian random walk strategy and sparrow alert mechanism, the speed PID controller parameters of brushless DC motor are optimized, which solves the problems of cumbersome and low efficiency of traditional tuning methods and achieves more efficient control effects.
Patent Information
- Application Number
- CN202510501385.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-21
- Publication Date
- 2025-06-20
AI Technical Summary
The parameter setting of traditional PID controllers relies on industrial knowledge and expert experience, resulting in large differences in results, cumbersome processes and difficult to promote. Especially in brushless DC motor control, it is difficult to achieve efficient control effects.
The improved Sandmax group algorithm optimization algorithm is adopted to build a mathematical model and simulation model of the speed and current dual closed-loop speed regulation system of brushless DC motors, and the initial population position is generated using Cubic chaos mapping and Gaussian random walk strategy, and combined with the sparrow alert mechanism, the parameters of the speed PID controller are optimized.
It improves the accuracy and efficiency of parameter tuning of PID controllers, reduces local optimal value interference, can find the global optimal solution more effectively, and improves the control performance of brushless DC motors.
Smart Images

Figure CN120185448A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of optimizing PID control technology, and particularly to an intelligent control method, system and storage medium for a brushless DC motor. Background Art
[0002] As a controller widely used in industrial production processes, the PID controller is based on three parts: proportional, integral and differential of the error, and controls the stability, accuracy and response speed of the system by adjusting the output of the controller.
[0003] When the PID controller is used to control a brushless DC motor, the setting of its parameters directly affects the quality of the control effect. Therefore, the tuning of the PID controller parameters has always been a concern. Traditionally, the tuning of the PID controller parameters mainly relies on industrial knowledge and expert experience, resulting in differences in the tuning results, making the process cumbersome and difficult to popularize. To solve this problem, researchers have used optimization algorithms to adjust fuzzy rules to improve the performance of the control system.
[0004] As a recently proposed swarm intelligence optimization algorithm, the sand cat swarm algorithm has better optimization performance than traditional algorithms, but it is easily interfered by local optimal values, resulting in the algorithm being easily trapped in local optima and unable to find the global optimal solution. Summary of the Invention
[0005] In order to accurately and effectively solve the problem of difficult tuning of PID controller parameters, the present invention provides an intelligent control method, system and storage medium for a brushless DC motor.
[0006] The present invention is implemented by the following technical solutions: In the first aspect, the present application proposes an intelligent control method for a brushless DC motor, and the method includes: constructing a mathematical model of a speed and current double closed-loop speed regulation system of the brushless DC motor and a simulation model of the brushless DC motor control system, where the simulation model includes a speed PID controller, and using an improved sand cat swarm algorithm optimization algorithm to control the speed PID controller; using the improved sand cat swarm algorithm optimization algorithm to control the speed PID controller, including the following steps: obtaining a plurality of parameters to be optimized of the speed PID controller; using Cubic chaotic mapping to generate the initial individual positions of the sand cat swarm, calculating the initial fitness of each in the sand cat swarm according to the evaluation function, and updating the global optimal position of the sand cat individual with the best fitness to the current optimal position; executing the sand cat swarm algorithm, searching for the parameters to be optimized by simulating the search behavior or attack behavior of the sand cats, and updating the population positions of the sand cat swarm according to the search behavior or the attack behavior; using the sparrow warning mechanism to update the population positions of the sand cat swarm again; when the set termination condition is satisfied, outputting the global optimal position of the sand cat individual corresponding to the current population position of the sand cat swarm, and obtaining the target value of the parameters to be optimized according to the solution corresponding to the global optimal position of the sand cat individual; controlling the brushless DC motor based on the target value of the parameters to be optimized.
[0007] As a further improvement of the above solution, the mathematical model of the search behavior is generated according to the Gaussian random walk strategy and the position update formula introduced in the sand cat swarm algorithm in the prey search stage; where the expression of the mathematical model of the search behavior is as follows:
[0008]
[0009] where, Pos t bc represents the current optimal individual position; Pos t c represents the current iterative individual position; Pos t+1 c represents the updated individual position.
[0010] As a further improvement of the above solution, the mathematical model of the sparrow warning mechanism is as follows:
[0011]
[0012] where, Pos t bc represents the current optimal individual position; β represents a random number obeying a normal distribution with a mean of 0 and a variance of 1; Pos t wc represents the global worst position where the current sand cat individual is located; fit iRepresents the fitness value of the current sand cat individual; fit g Represents the best fitness value of the current sand cat individual; fit w Represents the worst fitness value of the current sand cat individual; both k and ε are constants.
[0013] As a further improvement of the above solution, the mathematical model of the Cubic chaotic mapping is as follows:
[0014]
[0015] Among them, ρ is the control parameter.
[0016] As a further improvement of the above solution, the multiple parameters to be optimized include the proportional coefficient, integral coefficient, and differential coefficient of the speed PID controller.
[0017] As a further improvement of the above solution, the mathematical model of the evaluation function is as follows:
[0018]
[0019] Among them, Δe(t) represents the change rate of the speed feedback signal; e(t) represents the error signal; u 2 (t) represents the quadratic value of the output signal of the speed PID controller.
[0020] As a further improvement of the above solution, the mathematical model of the search behavior is as follows:
[0021]
[0022] Among them, Pos r Represents a random individual near the optimal individual; Pos t bc Represents the position of the current optimal individual; Pos t c Represents the position of the current iterative individual; Pos t+1 c Represents the updated individual position; β represents a random number that follows a normal distribution with a mean of 0 and a variance of 1.
[0023] In a second aspect, the present application also proposes an intelligent control system for a brushless DC motor, and the system includes:
[0024] A control model construction module, which is used to construct the mathematical model of the speed and current double closed-loop speed regulation system of the brushless DC motor and the simulation model of the brushless DC motor control system. The simulation model includes a speed PID controller, and the improved sand cat swarm algorithm is used to optimize and control the speed PID controller;
[0025] An algorithm construction module, which is used to optimize the algorithm control of the rotational speed PID controller by using an improved sand cat swarm algorithm, including the following steps: obtaining a plurality of parameters to be optimized of the rotational speed PID controller; generating the initial individual positions of the sand cat swarm by using Cubic chaotic mapping, calculating the initial fitness of each in the sand cat swarm according to the evaluation function, and updating the global optimal position of the sand cat individual with the optimal fitness as the current optimal position; executing the sand cat swarm algorithm, searching for the parameters to be optimized by simulating the searching behavior or attacking behavior of the sand cats, and updating the population positions of the sand cat swarm according to the searching behavior or the attacking behavior; using the sparrow vigilance mechanism to update the population positions of the sand cat swarm again;
[0026] A parameter target value acquisition module, which is used to output the global optimal position of the sand cat individual corresponding to the current population position of the sand cat swarm when the set termination condition is satisfied, and obtain the target value of the parameter to be optimized according to the solution corresponding to the global optimal position of the sand cat individual;
[0027] An execution module, which is used to control the brushless DC motor based on the target value of the parameter to be optimized.
[0028] In a third aspect, the present application also proposes a computer terminal, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the method for intelligent control of the brushless DC motor as described is implemented.
[0029] In a fourth aspect, the present application also proposes a computer-readable storage medium. The computer-readable storage medium stores a computer program, characterized in that when the computer program is executed by a processor, the method for intelligent control of the brushless DC motor as described is implemented.
[0030] The intelligent control method of the brushless DC motor of the present invention has the following beneficial effects:
[0031] The server in this application first constructs the mathematical model of the speed and current double closed-loop speed regulation system of the brushless DC motor and the simulation model of the brushless DC motor control system. The simulation model includes a speed PID controller, and uses the improved sand cat swarm algorithm to optimize the algorithm to control the speed PID controller. Using the improved sand cat swarm algorithm to optimize the algorithm to control the speed PID controller includes the following steps: obtaining multiple parameters to be optimized of the speed PID controller; using Cubic chaotic mapping to generate the initial individual positions of the sand cat swarm, calculating the initial fitness of each in the sand cat swarm according to the evaluation function, and updating the global optimal position of the sand cat individual with the best fitness as the current optimal position; executing the sand cat swarm algorithm, searching for the parameters to be optimized by simulating the search behavior or attack behavior of the sand cats, and updating the population positions of the sand cat swarm according to the search behavior or the attack behavior; using the sparrow warning mechanism to update the population positions of the sand cat swarm again; when the set termination condition is satisfied, outputting the global optimal position of the sand cat individual corresponding to the current population position of the sand cat swarm, and obtaining the target value of the parameter to be optimized according to the solution corresponding to the global optimal position of the sand cat individual; controlling the brushless DC motor based on the target value of the parameter to be optimized; improving the sand cat swarm optimization algorithm, integrating the Gaussian random walk strategy and the warning mechanism of the sparrow algorithm, and introducing chaotic mapping to optimize the initial population, and using it for the optimization of fuzzy rules to improve the convergence speed and accuracy of finding fuzzy rules, and more effectively solve the problem of difficult tuning of PID controller parameters. Description of the Drawings
[0032] Figure 1 It is a schematic flow chart of the intelligent control of the brushless DC motor according to the embodiment of the present invention.
[0033] Figure 2 It is a structural diagram of the double closed-loop speed regulation system of the brushless DC motor in the embodiment of the present invention. Detailed Embodiment
[0034] In order to make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0035] Please refer to Figure 1 , an intelligent control method for a brushless DC motor is proposed in the embodiment of this application. The method includes the following steps:
[0036] S1, constructing the mathematical model of the speed and current double closed-loop speed regulation system of the brushless DC motor and the simulation model of the brushless DC motor control system. The simulation model includes a speed PID controller, and using the improved sand cat swarm algorithm to optimize the algorithm to control the speed PID controller;
[0037] Specifically, as Figure 2 shown, the control system of the brushless DC motor adopts double closed-loop control, that is, speed and current double closed-loop control. The speed loop adopts fuzzy PID control, and the inner loop is the current loop, which adopts hysteresis control.
[0038] S2. Use the improved sand cat swarm algorithm to optimize the algorithm to control the speed PID controller, including the following steps: obtain multiple parameters to be optimized of the speed PID controller; use Cubic chaotic mapping to generate the initial individual positions of the sand cat swarm, calculate the initial fitness of each in the sand cat swarm according to the evaluation function, and update the global optimal position of the sand cat individual with the best fitness to the current optimal position; execute the sand cat swarm algorithm, search for the parameters to be optimized by simulating the search behavior or attack behavior of the sand cats, and update the population positions of the sand cat swarm according to the search behavior or the attack behavior; use the sparrow warning mechanism to update the population positions of the sand cat swarm again.
[0039] S3. When the set termination condition is satisfied, output the global optimal position of the sand cat individual corresponding to the current population position of the sand cat swarm, and obtain the target value of the parameter to be optimized according to the solution corresponding to the global optimal position of the sand cat individual.
[0040] S4. Control the brushless DC motor based on the target value of the parameter to be optimized.
[0041] In the embodiment of the present application, through the improved sand cat swarm optimization algorithm, the Gaussian random walk strategy and the warning mechanism of the sparrow algorithm are integrated, and chaotic mapping is introduced to optimize the initial population, which is used for the optimization of fuzzy rules to improve the convergence speed and accuracy of finding fuzzy rules, and more effectively solve the problem of difficult tuning of PID controller parameters.
[0042] In an embodiment of the application, the mathematical model of the search behavior is generated according to the Gaussian random walk strategy and the position update formula introduced in the search for prey stage in the sand cat swarm algorithm; wherein, the expression of the mathematical model of the search behavior is as follows:
[0043]
[0044] Among them, Pos t bc represents the current optimal individual position; Pos t c represents the current iterative individual position; Pos t+1 c represents the updated individual position. Gaussian(Pos t bc , σ) is a Gaussian distribution with Pos t bc as the expectation and σ as the variance.
[0045] The mathematical model of the attack behavior is as follows:
[0046]
[0047] Among them, Pos r represents a random individual near the optimal individual; Pos t bc represents the position of the current optimal individual; Pos t c represents the position of the current iterative individual; Pos t+1 c represents the updated individual position; β represents a random number obeying the normal distribution with a mean of 0 and a variance of 1
[0048] In the embodiment of the present application, the Gaussian random walk strategy is introduced into the position update formula in the stage of searching for prey, so as to realize the diversified search path of the sand cat in the process of adjusting its own position; the introduction of the Gaussian random walk strategy improves the randomness of the sand cat group's action in the search space, enhances the global search ability in the early stage of the search, significantly increases the possibility of jumping out of the local optimum, and effectively improves the performance of the sand cat group algorithm.
[0049] In an embodiment of the application, the mathematical model of the sparrow warning mechanism is as follows:
[0050]
[0051] Among them, Pos t bc represents the position of the current optimal individual; β represents a random number obeying the normal distribution with a mean of 0 and a variance of 1; Pos t wc represents the global worst position where the current sand cat individual is located; fit i represents the fitness value of the current sand cat individual; fit g represents the best fitness value of the current sand cat individual; fit w represents the worst fitness value of the current sand cat individual; k and ε are both constants.
[0052] When fit i >fit g , it means that this individual is at the edge of the population and needs to move to a safe area, and β is the sand cat movement step adjustment parameter. When fit i =fit g , it indicates that the individuals located in the middle of the population need to get closer to other sand cats, and k represents the direction of the sand cat movement, further adjusting the position of the sand cat individual to maximize the overall safety of the group.
[0053] In an embodiment of the application, the mathematical model of the Cubic chaotic mapping is as follows:
[0054]
[0055] where ρ is a control parameter.
[0056] In the embodiment of the present application, the Cubic chaotic mapping has better randomness and ergodicity. Using the Cubic chaotic mapping for the generation of the initial population can better improve the diversity of the initial population and achieve a faster convergence speed.
[0057] In an embodiment of the application, the mathematical model of the evaluation function is as follows:
[0058]
[0059] where Δe(t) represents the change rate of the rotational speed feedback signal; e(t) represents the error signal; u 2 (t) represents the quadratic value of the output signal of the rotational speed PID controller.
[0060] In the embodiment of the present application, the PID output signal u(t) is introduced and weighted to prevent the system from overshooting due to excessive control performance; for the overshoot phenomenon, a penalty measure is added when overshooting, and the integral of the overshoot amount is added to the fitness function. The smaller the fitness function value, the better the control performance.
[0061] In an embodiment of the application, an intelligent control system for a brushless DC motor is proposed, which is characterized in that the system includes:
[0062] A control model construction module, which is used to construct the mathematical model of the speed and current double-closed-loop speed regulation system of the brushless DC motor and the simulation model of the brushless DC motor control system. The simulation model includes a rotational speed PID controller, and the improved sand cat swarm algorithm is used to optimize the control of the rotational speed PID controller;
[0063] An algorithm construction module, which is used to optimize the control of the rotational speed PID controller by using the improved sand cat swarm algorithm, including the following steps: obtaining a plurality of parameters to be optimized of the rotational speed PID controller; using the Cubic chaotic mapping to generate the initial individual positions of the sand cat swarm, calculating the initial fitness of each in the sand cat swarm according to the evaluation function, and updating the global optimal position of the sand cat individual with the best fitness to the current optimal position; executing the sand cat swarm algorithm, searching for the parameters to be optimized by simulating the search behavior or attack behavior of the sand cats, and updating the population positions of the sand cat swarm according to the search behavior or the attack behavior; using the sparrow warning mechanism to update the population positions of the sand cat swarm again;
[0064] A parameter target value acquisition module, which is used to output the global optimal position of the fennec fox individual corresponding to the population position of the current fennec fox group when a set termination condition is satisfied, and obtain the target value of the parameter to be optimized according to the solution corresponding to the global optimal position of the fennec fox individual;
[0065] An execution module, which is used to control a brushless DC motor based on the target value of the parameter to be optimized.
[0066] Compared with the prior art, the intelligent control system of this brushless DC motor has the same advantages as the intelligent control method of the brushless DC motor, which will not be elaborated here.
[0067] In an application embodiment, a computer terminal is provided, which includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, the steps of the method for detecting the atmospheric boundary layer height of the wind speed variance profile shape are implemented. When this method is applied, it can be applied in the form of software, such as designed as an independently running program and installed on the computer terminal. The computer terminal can be a computer, a smart phone, a control system, and other Internet of Things devices, etc. This method can also be designed as an embedded running program and installed on the computer terminal, such as installed on a single-chip microcomputer.
[0068] In an application embodiment, this embodiment provides a computer-readable storage medium, on which a computer program is stored. When the program is executed by the processor, the steps of the method for rapid evaluation of facial paralysis based on deep learning are implemented. When this method is applied, it can be applied in the form of software, such as designed as an independently running program of the computer-readable storage medium. The computer-readable storage medium can be a USB flash drive, designed as a USB key, and designed as a program that starts the entire method through external triggering through the USB flash drive.
[0069] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. An intelligent control method for a brushless DC motor, characterized in that: The method comprises: Constructing a mathematical model of a brushless DC motor speed and current dual closed-loop speed control system and a simulation model of a brushless DC motor control system, wherein the simulation model includes a speed PID controller, and the speed PID controller is controlled by using an improved sand cat swarm algorithm optimization algorithm; The speed PID controller is controlled by using an improved sand cat swarm algorithm optimization algorithm, comprising the following steps: obtaining a plurality of parameters to be optimized of the speed PID controller; generating the initial individual positions of the sand cat swarm by using a Cubic chaotic map, calculating the initial fitness of each of the sand cat swarm according to an evaluation function, and updating the global optimal position of the sand cat individual with the best fitness as the current optimal position; executing the sand cat swarm algorithm, searching for the parameters to be optimized by simulating the search behavior or attack behavior of the sand cat, and updating the population position of the sand cat swarm according to the search behavior or the attack behavior; and updating the population position of the sand cat swarm again by using a sparrow alert mechanism; When the set termination condition is met, the global optimal position of the sand cat individuals corresponding to the current population position of the sand cat group is output, and the target value of the parameter to be optimized is obtained according to the solution corresponding to the global optimal position of the sand cat individuals; Based on the target value of the parameter to be optimized, the brushless DC motor is controlled.
2. The intelligent control method of a brushless DC motor according to claim 1, characterized in that: The mathematical model of the search behavior is generated according to the Gaussian random walk strategy and the position update formula introduced in the prey search phase in the sand cat swarm algorithm; wherein the mathematical model of the search behavior is expressed as follows: Among them, Pos t bc Indicates the current optimal individual position; Pos t c Indicates the individual position of the current iteration; Pos t+1 c Represents the updated individual position.
3. The intelligent control method of a brushless DC motor according to claim 1, characterized in that: The mathematical model of the sparrow warning mechanism is as follows: Among them, Pos t bc represents the current optimal individual position; β represents a random number that follows a normal distribution with a mean of 0 and a variance of 1; Pos t wc Indicates the global worst position of the current sand cat individual; fit i Indicates the fitness value of the current sand cat individual; fit g Indicates the current optimal fitness value of the sand cat individual; fit w Indicates the worst fitness value of the current sand cat individual; k and ε are both constants.
4. The intelligent control method of a brushless DC motor according to claim 1, characterized in that: The mathematical model of the Cubic chaos map is as follows: Among them, ρ is the control parameter.
5. The intelligent control method of a brushless DC motor according to claim 1, characterized in that: The multiple parameters to be optimized include a proportional coefficient, an integral coefficient and a differential coefficient of the speed PID controller.
6. The intelligent control method of a brushless DC motor according to claim 1, characterized in that: The mathematical model of the evaluation function is as follows: Wherein, Δe(t) represents the rate of change of the speed feedback signal; e(t) represents the error signal; u 2 (t) represents the quadratic value of the output signal of the speed PID controller.
7. The intelligent control method of a brushless DC motor according to claim 1, characterized in that: The mathematical model of the attack behavior is as follows: Among them, Pos r Represents a random individual near the optimal individual; Pos t bc Indicates the current optimal individual position; Pos t c Indicates the individual position of the current iteration; Pos t+1 c represents the updated individual position; β represents a random number that obeys a normal distribution with a mean of 0 and a variance of 1.
8. An intelligent control system for a brushless DC motor, characterized in that: The system comprises: A control model building module, which is used to build a mathematical model of a brushless DC motor speed and current dual closed-loop speed control system and a simulation model of a brushless DC motor control system, wherein the simulation model includes a speed PID controller, and the speed PID controller is controlled by using an improved sand cat swarm algorithm optimization algorithm; An algorithm construction module, which is used to control the speed PID controller using an improved sand cat group algorithm optimization algorithm, includes the following steps: obtaining multiple parameters to be optimized of the speed PID controller; using Cubic chaotic mapping to generate the initial individual positions of the sand cat group, calculating the initial fitness of each of the sand cat group according to an evaluation function, and updating the global optimal position of the sand cat individual with the best fitness as the current optimal position; executing the sand cat group algorithm, searching for the parameters to be optimized by simulating the search behavior or attack behavior of the sand cat, and updating the population position of the sand cat group according to the search behavior or the attack behavior; and updating the population position of the sand cat group again using a sparrow alert mechanism; A parameter target value acquisition module, which is used to output the global optimal position of the sand cat individual corresponding to the current population position of the sand cat group when the set termination condition is met, and obtain the target value of the parameter to be optimized according to the solution corresponding to the global optimal position of the sand cat individual; An execution module is used to control the brushless DC motor based on the target value of the parameter to be optimized.
9. A computer terminal comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the method according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Cited By
Motor position and speed double-closed-loop control method based on improved carbon black quadrangle algorithm
CN121832250A
A motor position and speed double closed loop control method based on improved carbon black four-angle bee algorithm
CN121832250B