A speed sensorless control method and system for a permanent magnet synchronous motor
By using the speed error to train the LSTM neural network and combining it with the motor rotor acceleration limit, the problems of limited sensor usage and high model complexity in the permanent magnet synchronous motor control system are solved, and high-precision speed observation and stable motor operation are achieved.
Patent Information
- Application Number
- CN202510026870.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-08
- Publication Date
- 2025-09-26
- Estimated Expiration
- 2045-01-08
AI Technical Summary
In permanent magnet synchronous motor control systems, the use of sensors is limited by manufacturing costs and space, and mechanical failures and electromagnetic interference affect performance. At the same time, neural network models have problems in speed observation, such as inaccurate modeling, low observation accuracy, and high complexity, resulting in insufficient control accuracy and stability.
The speed error is used as the output of the training set. The neural network model is improved by combining the LSTM neural network and the motor rotor acceleration limiter. The motor three-phase stator current and voltage are used as input. A motor speed observation model based on the LSTM neural network is constructed to perform speed observation and processing.
It improves the speed observation accuracy and motor operation stability, reduces the burden of neural network training, enhances the model's interpretability and adjustment capabilities, and improves motor control performance.
Smart Images

Figure CN119766020B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of motor control technology, and specifically relates to a speed sensorless control method and system for a permanent magnet synchronous motor. Background Art
[0002] Permanent magnet synchronous motor control systems typically require speed sensors for closed-loop control. However, in practical applications, factors such as manufacturing cost and installation space restrict the use of sensors. Furthermore, mechanical failures of sensors and electromagnetic interference of the detection signals can negatively impact the performance of motor control systems. Therefore, research on sensorless control has become crucial.
[0003] During the operation of the motor, the motor parameters will change due to the influence of the nonlinearity of the motor magnetic circuit, electromagnetic and mechanical inertia, and it is easily affected by harmonic disturbances. This makes the direct use of the mathematical model of the motor for sensorless control have problems such as inaccurate modeling, complex observer structure, and low observation accuracy, which affects the control accuracy of the motor and the operating performance of the motor system.
[0004] Using neural networks for sensorless control offers several advantages. Through their self-learning capabilities, neural networks can effectively handle complex systems with high-dimensional, nonlinear characteristics. They can adapt to the dynamics of permanent magnet synchronous motors under varying loads and operating conditions, effectively capture long-term dependencies in data, and model and observe time series data.
[0005] In closed-loop motor control systems, neural networks typically use current and voltage as inputs to the neural network, while speed is directly used as the output for training. However, since speed feedback directly affects the changes in inputs like current and voltage, significant deviations between observed and actual values can cause dramatic fluctuations in current and voltage, further deteriorating subsequent observations and impacting the motor system's control performance. Furthermore, due to the high dynamics and complexity of current and speed data, neural networks struggle to capture all possible variations. Even by enhancing the neural network's generalization or expanding the dataset through the addition of perturbations, it's difficult to completely eliminate motor system imbalances caused by accumulated observation errors. This necessitates extremely high accuracy when applying neural networks to motor control systems, increasing the training burden. Furthermore, as "black-box" models, neural networks present challenges in interpreting and understanding their behavior. The observed motor outputs can sometimes misrepresent the motor's operating characteristics, further limiting their application in motor control systems. Summary of the Invention
[0006] Based on the above problems, the present invention uses the speed error as the training set output to train the neural network model, and improves the model based on the motor rotor acceleration limit. The technical solution is as follows:
[0007] A speed sensorless control method for a permanent magnet synchronous motor comprises the following steps:
[0008] S1. Establish a mathematical model of the permanent magnet synchronous motor and obtain the difference between the actual value of the motor speed and the value calculated by the mathematical model;
[0009] S2. The three-phase stator current and voltage of the permanent magnet synchronous motor are used as the input of the neural network, and the calculated error of the motor speed is used as the output. This output is added to the speed calculated by the mathematical model to obtain the actual value of the motor speed. Based on this, a motor speed observation model based on the LSTM neural network is constructed.
[0010] S3. Improve the motor speed observation of the LSTM neural network model based on the motor rotor acceleration limit, and process the speed value observed by the neural network model.
[0011] Preferably, in step S1, a mathematical model of the permanent magnet synchronous motor in the abc coordinate system is established, and the voltage equation is:
[0012] (1);
[0013] in, 、 、 is the stator three-phase voltage, is the winding resistance, 、 、 is the three-phase current, 、 、 is the stator flux; transform the mathematical model in the abc coordinate system to the αβ coordinate system, and the transformation relationship between the two coordinate systems is:
[0014] (2);
[0015] After coordinate transformation, the mathematical model in the αβ coordinate system can be obtained:
[0016] (3);
[0017] (4) ;
[0018] (5);
[0019] in, 、 is the αβ axis voltage, 、 is the αβ axis current, and the differential operator Instead of d / dt, 、 is the αβ axis magnetic flux; is the electromagnetic torque of the motor, is the number of motor pole pairs; is the calculated motor speed; is the moment of inertia of the motor; is the motor load torque.
[0020] Preferably, in step S1, during the operation of the motor, there is an error between the actual speed value of the motor and the value calculated by the mathematical model, and the relationship between them is expressed as:
[0021] (6);
[0022] in, is the actual speed of the motor; is the motor speed error calculated using the motor mathematical model.
[0023] Preferably, in step S2, in order to make the current data meet the input requirements of the neural network, it is normalized, a normalization coefficient K is introduced, and K is set to:
[0024] (7);
[0025] Introduce the floating point relative error limit eps, let , the processed three-phase current can be expressed as:
[0026] (8);
[0027] The other training data are preprocessed using the maximum and minimum normalization method, and the preprocessed data set is divided into a training set and a test set. The training set is used to train the neural network, and the test set is used to evaluate the performance of the trained neural network.
[0028] Preferably, in step S2, the speed value observed by the neural network model is processed, and the model is improved based on the motor rotor acceleration limit. The relationship between the electromagnetic torque and the load torque difference is:
[0029] (9);
[0030] in, is the electromagnetic torque and load torque The maximum torque difference , the maximum rotor acceleration :
[0031] (10);
[0032] Therefore, the motor speed output by the observation model is adjusted to:
[0033] (11);
[0034] in, is the motor speed at the current moment; is the motor speed at the previous moment; is the motor speed acceleration at the current moment; is the sampling period of the discrete model.
[0035] A speed sensorless control system for a permanent magnet synchronous motor includes a data acquisition module, a data processing module and an output module;
[0036] Data acquisition module: obtains the three-phase stator current, voltage and motor speed parameters of the permanent magnet synchronous motor;
[0037] Data processing module: Build a motor speed observation model based on the LSTM neural network. The three-phase stator current and voltage of the permanent magnet synchronous motor are used as the input of the neural network. The calculated error of the motor speed is used as the output. This output is added to the speed calculation value of the mathematical model to obtain the actual value of the motor speed. The motor speed observation of the LSTM neural network model is improved based on the motor rotor acceleration limit, and the speed value observed by the neural network model is processed.
[0038] Output module: output the results visually.
[0039] Compared with the prior art, this application has the following beneficial effects:
[0040] 1) Based on the mathematical model of the motor, the speed difference between the actual motor output and the calculated value of the mathematical model is used as the output of the data set to train the neural network model. This effectively overcomes the problem of difficulty in establishing an accurate motor mathematical model caused by factors such as motor magnetic circuit nonlinearity, electromagnetic and mechanical inertia. It also solves the problem that the application of neural network models trained directly using the actual motor speed is limited in control systems, reducing the burden of neural network training and model complexity.
[0041] 2) Integrating the motor operating characteristics into the neural network and improving the model output enhances the interpretability and adjustment capabilities of the neural network, effectively improving the speed observation accuracy and motor operation stability. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] Figure 1 This is the flow chart for this application;
[0043] Figure 2 A schematic diagram of an embodiment of a physical model of a permanent magnet synchronous motor in the abc coordinate system and the αβ coordinate system provided by the present invention;
[0044] Figure 3 To apply the model trained using speed as output to the motor vector control system, a comparison chart of the actual motor speed and the observed value;
[0045] Figure 4 A comparison chart of the actual motor speed and the observed value in order to apply the model trained with the speed error as the output to the motor vector control system;
[0046] Figure 5 Diagram of sensorless control system of permanent magnet synchronous motor;
[0047] Figure 6 In order to apply the improved model to the motor vector control system, the actual motor speed and the observed value are compared as shown in the figure. DETAILED DESCRIPTION
[0048] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the embodiments of the present invention and the accompanying drawings. Obviously, the embodiments described are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0049] The purpose of the invention of this application is to provide a speed sensorless control scheme for a permanent magnet synchronous motor. Based on the mathematical model of the motor, the speed difference between the actual output of the motor and the calculated value of the mathematical model is used as the output of the data set to train the neural network model. This effectively overcomes the problem of difficulty in establishing an accurate mathematical model of the motor due to factors such as the nonlinearity of the motor magnetic circuit, electromagnetic and mechanical inertia, and solves the problem of limited application of the neural network model trained directly using the actual speed of the motor in the control system, thereby reducing the burden of neural network training and the complexity of the model; the motor operating characteristics are integrated into the neural network, the model is improved, the interpretability and adjustment capabilities of the neural network are enhanced, and the speed observation accuracy and the stability of the motor operation are effectively improved.
[0050] Combine Figure 1 Come and see, Figure 1 The present invention provides a flow chart of a sensorless control method for a permanent magnet synchronous motor. The method mainly includes the following steps:
[0051] Step 1: Establish a mathematical model of the permanent magnet synchronous motor and obtain the difference between the actual value of the motor speed and the value calculated by the mathematical model (i.e., the error calculated by the mathematical model).
[0052] Establish the mathematical model of the permanent magnet synchronous motor in the abc coordinate system, and the voltage equation is:
[0053] (1);
[0054] in, 、 、 is the stator three-phase voltage, is the winding resistance, 、 、 is the three-phase current, 、 、 is the stator flux; transform the mathematical model in the abc coordinate system to the αβ coordinate system, combined with Figure 2 Come and see, Figure 2 This is a schematic diagram of an embodiment of the permanent magnet synchronous motor physical model of the abc coordinate system and the αβ coordinate system provided by the present invention. The transformation relationship between the two coordinate systems can be obtained as follows:
[0055] (2);
[0056] After coordinate transformation, the mathematical model in the αβ coordinate system can be obtained:
[0057] (3);
[0058] (4) ;
[0059] (5);
[0060] in, 、 is the αβ axis voltage, 、 is the αβ axis current, and the differential operator Instead of d / dt, 、 is the αβ axis magnetic flux; is the electromagnetic torque of the motor, is the number of motor pole pairs; is the calculated motor speed; is the moment of inertia of the motor; is the motor load torque.
[0061] During motor operation, due to the influence of factors such as magnetic circuit nonlinearity, electromagnetic and mechanical inertia, there is usually a certain error between the actual motor speed value and the value calculated by the mathematical model. The relationship between them can be expressed as:
[0062] (6);
[0063] in, is the actual speed of the motor; is the motor speed error calculated using the motor mathematical model.
[0064] In step 2, using the LSTM neural network, the three-phase stator current and voltage of the permanent magnet synchronous motor are used as the input of the neural network, and the calculated error of the motor speed is used as the output. The output is added to the speed calculation value of the mathematical model to obtain the actual value of the motor speed. Based on this, a motor speed observation model based on the LSTM neural network is constructed.
[0065] The LSTM neural network is a special type of recurrent neural network designed specifically for processing and observing time series data. Motor observation data, such as current, voltage, and speed, varies over time and contains time series information. LSTM neural networks effectively capture long-term dependencies in the data, enabling modeling and observation of time series data. Using LSTM neural networks to process motor observation data provides powerful support for motor speed measurement.
[0066] In order to make the current data meet the input requirements of the neural network, it is normalized. The normalization coefficient K is introduced and set to:
[0067] (7);
[0068] In order to prevent zero division errors and avoid numerical instability, the floating point relative error limit eps is introduced. eps can be regarded as an infinitesimal quantity, usually ranging from 1×10-10 to 1×10-8. The processed three-phase current can be expressed as:
[0069] (8);
[0070] From formula (8), we can see that the current input to the neural network is adjusted to [-1, 1] after normalization.
[0071] The other training data are preprocessed using the maximum and minimum normalization method, and the preprocessed data set is divided into a training set and a test set. The training set is used to train the neural network, and the test set is used to evaluate the performance of the trained neural network.
[0072] Since the motor speed value is relatively large and has large fluctuations, this will increase its training burden and increase the complexity of the model; while the speed error value is relatively small, using the speed error as the output for training significantly improves its accuracy when applied in the motor control system, and also reduces the neural network training burden and model complexity. This is not only beneficial to neural network training, but also can reduce the impact of excessive error fluctuations in motor control on input quantities such as current and voltage, helping to maintain stable operation of the system. The model trained using speed as the output is applied to the motor vector control system, and the actual motor speed is compared with the observed value. Figure 3 As shown in the figure, the model trained with speed error as output is applied to the motor vector control system to compare the actual motor speed with the observed value. Figure 4 As shown in Figure 2, the two models have the same parameter settings during training.
[0073] Step 3: Process the speed value observed by the neural network model and improve the model based on the motor rotor acceleration limit. The permanent magnet synchronous motor rotor acceleration can be obtained from formula (6): The relationship between the electromagnetic torque and the load torque difference is:
[0074] (9);
[0075] in, is the electromagnetic torque and load torque difference.
[0076] Considering that the motor has a maximum torque difference when running , so the rotor acceleration has a maximum value :
[0077] (10);
[0078] Therefore, the motor speed output by the observation model is adjusted to:
[0079] (11);
[0080] Among them, among them, is the motor speed at the current moment; is the motor speed at the previous moment; is the motor speed acceleration at the current moment; is the sampling period of the discrete model. Figure 5 As shown in the figure, the actual motor speed is compared with the observed value. Figure 6 shown.
[0081] A speed sensorless control system for a permanent magnet synchronous motor includes a data acquisition module, a data processing module and an output module;
[0082] Data acquisition module: obtains the three-phase stator current, voltage and motor speed parameters of the permanent magnet synchronous motor;
[0083] Data processing module: Build a motor speed observation model based on the LSTM neural network. The three-phase stator current and voltage of the permanent magnet synchronous motor are used as the input of the neural network. The calculated error of the motor speed is used as the output. This output is added to the speed calculation value of the mathematical model to obtain the actual value of the motor speed. The motor speed observation of the LSTM neural network model is improved based on the motor rotor acceleration limit, and the speed value observed by the neural network model is processed.
[0084] Output module: output the results visually.
[0085] The method embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, i.e., they may be located in one location or distributed across multiple network elements. Some or all of the modules may be selected based on actual needs to achieve the objectives of the present embodiment. Persons of ordinary skill in the art will be able to understand and implement the present invention without inventive effort.
[0086] The system is constructed to run the method of the present application. Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus the necessary general hardware platform, or of course, by hardware. Based on this understanding, the essence of the above technical solution or the part that contributes to the existing technology can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or certain parts of the embodiments.
[0087] It will be easily understood by those skilled in the art that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A speed sensorless control method for a permanent magnet synchronous motor, characterized in that: The following steps are involved: S1. Establish a mathematical model of the permanent magnet synchronous motor and obtain the difference between the actual value of the motor speed and the value calculated by the mathematical model; (5); ω is the calculated motor speed; J is the moment of inertia of the motor; T L is the motor load torque, T e is the electromagnetic torque of the motor; During the operation of the motor, there is a certain error between the actual speed value of the motor and the value calculated by the mathematical model. The relationship between them is expressed as: (6); in, ω r is the actual speed of the motor; Δ ω is the motor speed error calculated using the motor mathematical model; S2. Use the three-phase stator current and voltage of the permanent magnet synchronous motor as the input of the neural network and the calculated error of the motor speed as the output. Based on this, a motor speed observation model based on the LSTM neural network is constructed. In order to make the current data meet the input requirements of the neural network, it is normalized and the normalization coefficient is introduced K , and set K for: (7); i a 、 i b 、 i c is the three-phase current; Introduce the floating point relative error limit eps, let K eps = K +eps, the processed three-phase current can be expressed as: (8); The other training data are preprocessed using the maximum and minimum normalization method, and the preprocessed data set is divided into a training set and a test set. The training set is used to train the neural network, and the test set is used to evaluate the performance of the trained neural network. S3. Improve the motor speed observation of the LSTM neural network model based on the motor rotor acceleration limit, and process the speed value observed by the neural network model.
2. The speed sensorless control method for a permanent magnet synchronous motor according to claim 1, characterized in that: In step S1, a mathematical model of the permanent magnet synchronous motor in the abc coordinate system is established, and the voltage equation is: (1); in, u a 、 u b 、 u c is the stator three-phase voltage, R s is the winding resistance, i a 、 i b 、 i c is the three-phase current, ψ a 、 ψ b 、 ψ c is the stator flux; transform the mathematical model in the abc coordinate system to the αβ coordinate system, and the transformation relationship between the two coordinate systems is: (2); After coordinate transformation, the mathematical model in the αβ coordinate system can be obtained: (3); (4); in, u α 、 u β is the αβ axis voltage, R s is the winding resistance, i α 、 i β is the αβ axis current, and the differential operator p replace d / dt , ψ α 、 ψ β is the αβ axis magnetic flux; n p is the number of motor pole pairs.
3. The speed sensorless control method for a permanent magnet synchronous motor according to claim 1, characterized in that: In step S2, the speed value observed by the neural network model is processed, and the model is improved based on the motor rotor acceleration limit. a The relationship between the electromagnetic torque and the load torque difference is: (9); Among them, Δ T is the electromagnetic torque T e and load torque T L The difference between the maximum torque difference Δ T max , the maximum rotor acceleration : (10); Therefore, the motor speed output by the observation model is adjusted to: (11); in, ω * is the motor speed at the current moment; ω 0 is the motor speed at the previous moment; a * is the motor speed acceleration at the current moment; t is the sampling period of the discrete model.
4. A speed sensorless control system for a permanent magnet synchronous motor, using the speed sensorless control method for a permanent magnet synchronous motor according to any one of claims 1 to 3, characterized in that: Including data acquisition module, data processing module and output module; Data acquisition module: obtains the three-phase stator current, voltage and motor speed parameters of the permanent magnet synchronous motor; Data processing module: Build a motor speed observation model based on the LSTM neural network. The three-phase stator current and voltage of the permanent magnet synchronous motor are used as the input of the neural network. The calculated error of the motor speed is used as the output. This output is added to the speed calculation value of the mathematical model to obtain the actual value of the motor speed. The motor speed observation of the LSTM neural network model is improved based on the motor rotor acceleration limit, and the speed value observed by the neural network model is processed. Output module: output the results visually.
Citation Information
Patent Citations
Compressor control method and system based on neural network, and storage medium
CN110518851A
Sensorless control method for asynchronous motor of neural network rotating speed estimator
CN117639594A