A model predictive pulse pattern optimization method and system
Patent Information
- Application Number
- CN202611495708.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-24
- Publication Date
- 2026-10-30
AI Technical Summary
[0002]在大功率飞轮储能、海上风电及全电推进船舶等应用场景中,受功率半导体器件开关损耗与散热条件的限制,逆变器被迫运行于极低载波比工况,导致系统稳态谐波抑制与动态响应速度之间存在固有矛盾
[0034]基于以上内容,本发明相对于离线优化脉冲模式、标准解析梯度型模型预测脉冲模式控制以及有限控制集模型预测控制,具有以下技术效果。
Smart Images

Figure CN123019483A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power electronic converter control technology, and more specifically, to a model prediction pulse mode optimization method and system. Background Technology
[0002] In applications such as high-power flywheel energy storage, offshore wind power, and all-electric propulsion ships, inverters are forced to operate at extremely low carrier ratios due to limitations in switching losses and heat dissipation of power semiconductor devices. This leads to an inherent contradiction between steady-state harmonic suppression and dynamic response speed. While existing offline optimized pulse mode control possesses excellent steady-state harmonic performance, it is essentially open-loop control with slow dynamic response. Standard model predictive pulse mode control relies on analytical gradients for online correction, which requires high accuracy of motor parameters and involves unpredictable computational complexity for high-dimensional searches. Finite control set model predictive control suffers from inconsistent switching frequencies and severe steady-state current distortion. Therefore, there is an urgent need for an online pulse optimization control scheme that can balance steady-state harmonic quality, dynamic response speed, and real-time computation. Summary of the Invention
[0003] In view of the above problems, the present invention provides a method for optimizing model prediction pulse patterns.
[0004] This invention does not rely on simple combinations of offline optimized impulse mode (OPP) and model predictive control, the golden ratio, or switching angle order constraints as its inventive basis. Instead, it provides a systematic solution to three interrelated problems existing in standard model predictive impulse mode control (MP3C): First, it reliably obtains the descent direction of the switching angle without explicitly calculating analytical gradients, reducing the sensitivity of direction discrimination to motor parameter mismatch; second, when multiple switching angles are coupled, it compresses the high-dimensional search into a controllable joint activity subspace, making the worst-case computational cost predictable; third, it simultaneously performs feasibility pruning and cost lower bound pruning within a fixed evaluation budget, ensuring that dynamic correction does not change the original impulse topology and controlled switching frequency. The improvements of this invention compared to existing technologies are: obtaining the descent direction and sensitivity by directly comparing candidate costs through feasible trial perturbations, rather than relying on analytical Jacobian matrices; constructing a joint feasible region for multiple switching angles through a sensitivity activity set, achieving low-dimensional compression of the high-dimensional problem; and solving the joint correction amount while maintaining the original impulse topology through partitioned lower bounds and fixed budget pruning.
[0005] The method includes:
[0006] S1: The control unit establishes a multi-step prediction model of the stator current of the AC motor, and performs homogeneous initialization or residual correction on the nominal candidate trajectory and the disturbance candidate trajectory with the current measured current.
[0007] S2: The control unit calculates the modulation index of the current operating condition, extracts the nominal switching angle vector from the offline optimized pulse mode lookup table, and determines the stator voltage vector sequence in the prediction time domain based on the rotor flux angle and load angle.
[0008] S3: The control unit constructs a comprehensive cost function that includes a current tracking accuracy term and a switching angle deviation penalty term, and calculates the nominal cost corresponding to the nominal switching angle vector;
[0009] S4: Within the feasible region satisfying the switching angle order and minimum pulse width constraints, the control unit applies positive-direction feasible trial disturbances, negative-direction feasible trial disturbances, or unilateral feasible trial disturbances to each nominal switching angle, respectively, and calculates the positive cost difference after applying the positive-direction feasible trial disturbance and the negative cost difference after applying the negative-direction feasible trial disturbance to each nominal switching angle; the descent direction is determined based on the smaller value between the positive cost difference and the negative cost difference, and the positive part of the ratio of the opposite of the smaller value to the disturbance amplitude is used as the cost descent sensitivity; only when the smaller value is less than the opposite of the direction dead zone threshold is it determined that the corresponding switching angle has a valid descent direction, and the switching angle is selected as a candidate active angle; the candidate active angles are sorted from high to low according to the cost descent sensitivity, and the switching angles that are ranked first and whose number does not exceed the maximum size of the preset active set are selected to form an active set; the switching angles not selected into the active set remain unchanged in the current control cycle.
[0010] S5: The control unit constructs a joint feasible region for multiple switching angles for the activity set, partitions the joint feasible region into multiple search nodes, performs feasibility pruning and lower bound pruning on the search nodes, and obtains the joint correction amount of the activity switching angle within a fixed cost evaluation budget; wherein, the feasibility pruning includes deleting search nodes that have no intersection with the joint feasible region; the lower bound pruning includes: determining the lower bound of the node cost of the search node, and deleting the search node when the lower bound of the node cost is not better than the difference between the current optimal cost and the pruning tolerance, wherein the lower bound of the node cost is determined based on the upper bound of the conservative direction slope and the width of the search node in the activity dimension;
[0011] S6: The control unit superimposes the joint correction amount onto the nominal switching angle vector, outputs the actual switching angle sequence that satisfies the minimum spacing constraint between adjacent switching angles, and generates the inverter switching trigger signal.
[0012] Furthermore, the multi-step prediction model in step S1 is established based on the Euler discrete mathematical model of the asynchronous motor. In its recursive prediction in the α-β coordinate system, the predicted value of the stator current at the next moment is obtained by linear combination of the stator current at the current moment, the rotor flux linkage at the current moment, and the stator voltage at the current moment through a coefficient matrix. The predicted value of the rotor flux linkage at the next moment is obtained by linear combination of the rotor flux linkage at the current moment and the stator current at the current moment through a coefficient matrix. The coefficient matrix is jointly determined by the stator resistance, rotor resistance, stator self-inductance, rotor self-inductance, stator-rotor mutual inductance, rotor angular velocity, and discrete sampling period.
[0013] Furthermore, the modulation index in step S2 is calculated in real time from the DC bus voltage, rotor angular velocity, and stator flux reference amplitude given by the outer loop controller. The control unit addresses the offline optimized pulse mode lookup table according to the modulation index and the preset pulse number to extract the nominal switching angle vector.
[0014] Furthermore, in step S2, when determining the stator voltage vector spatial angle, the control unit superimposes two orthogonal phase compensation terms based on the sum of the rotor flux linkage spatial observation angle and the stator and rotor load angles. The first orthogonal phase compensation term is based on Faraday's law of electromagnetic induction and is used to compensate for the orthogonal phase of the stator voltage spatial vector leading the stator flux linkage vector. The second orthogonal phase compensation term is used to compensate for the deviation between the spatial angle of the synthesized voltage vector and the phase defined by the pulse sequence of the offline optimized pulse mode.
[0015] Furthermore, the comprehensive cost function in step S3 includes the sum of the squares of the differences between the stator α-axis predicted current and the α-axis reference current at each step in the prediction time domain, the sum of the squares of the differences between the stator β-axis predicted current and the β-axis reference current, and the product of the square of the switching angle deviation and the penalty weight coefficient; the penalty weight coefficient is used to limit the jump of the transient switching frequency.
[0016] Further, the residual correction in step S3 specifically involves: the control unit calculating the one-step prediction residual of the previous control cycle, applying the same residual correction term to the nominal candidate trajectory and all disturbance candidate trajectories to update the prediction current, so that the common initial value deviation in each candidate prediction is corrected from the same source.
[0017] Further, in step S4, the control unit determines the feasible positive disturbance amplitude and feasible negative disturbance amplitude of each nominal switching angle based on the interval between each nominal switching angle and adjacent switching angles and the minimum pulse width protection amount, and limits the feasible positive disturbance amplitude and feasible negative disturbance amplitude to below a preset disturbance upper limit; when only one direction is feasible, a single-sided trial disturbance candidate is generated; when both directions are feasible, a positive direction trial disturbance candidate and a negative direction trial disturbance candidate are generated.
[0018] Furthermore, the directional dead zone threshold is not less than the upper bound of the candidate cost differential error, so that the common mode deviation in the cost estimation of the nominal candidate and the perturbation candidate is differentially canceled in the calculation of the positive cost difference and the negative cost difference; the control unit updates the switching angle only after the actual cost decrease exceeds the upper bound of the candidate cost differential error.
[0019] Furthermore, the joint feasible region described in step S5 simultaneously satisfies the direction constraint, the single-angle correction amplitude constraint, the coupling constraint that the distance between adjacent switching angles is not less than the minimum pulse width protection amount, and the constraint that the distance between zero and half of the range is equal to the minimum pulse width protection amount. Endpoint constraints within the range; the correction for inactive switching angles is zero;
[0020] In the lower bound pruning, the control unit projects the geometric center of the search node into the joint feasible region to obtain a feasible representative point, calculates the candidate cost of the feasible representative point, and updates the current optimal cost and the current optimal joint correction amount if the candidate cost is better than the current optimal cost. The lower bound of the node cost is equal to the candidate cost of the feasible representative point minus the sum of the products of the upper bound of the conservative direction slope in each activity dimension and half the width of the search node in the corresponding dimension.
[0021] The control unit selects the split dimension based on the product of sensitivity and node width, and splits the node at a preset ratio;
[0022] When any of the following conditions are met: the maximum node width is lower than the angle threshold, the optimal cost improvement in two consecutive rounds is less than the cost threshold, or the cumulative cost evaluation count reaches the preset upper limit, the control unit terminates the search and outputs the current optimal joint correction amount.
[0023] The present invention also provides a model prediction impulse mode optimization system, comprising:
[0024] The data acquisition module is used to collect the three-phase current, rotor angular velocity and DC bus voltage of the AC motor in real time, and output the collected data to the rolling prediction and cost calculation module.
[0025] The reference value calculation module is used to calculate the stator current reference value and the stator flux reference amplitude based on the output of the outer loop controller, and output the calculation results to the rolling prediction and cost calculation module and the optimal pulse mode addressing module, respectively.
[0026] The optimal pulse mode addressing module is used to store offline pre-calculated optimal pulse mode data, extract the nominal switching angle vector based on the real-time modulation index and pulse number, and output the nominal switching angle vector to the disturbance cost trend identification module and the pulse sequence reconstruction module.
[0027] The voltage vector phase angle compensation module is used to calculate the stator voltage vector space angle by combining the rotor flux angle, load angle and orthogonal phase compensation, determine the three-phase voltage vector sequence, and output the three-phase voltage vector sequence to the rolling prediction and cost calculation module.
[0028] The rolling prediction and cost calculation module is used to perform multi-step recursive prediction in the prediction time domain based on discrete state equations, calculate the comprehensive cost function including current tracking accuracy term and switching angle deviation penalty term, and output the nominal cost and disturbance candidate cost to the disturbance cost trend identification module.
[0029] The disturbance cost trend identification module is used to apply positive, negative, or unilateral feasible disturbances to each nominal switching angle within the feasible domain, compare the cost difference between the disturbance candidates and the nominal candidates, and output the descent direction, sensitivity, and active switching angle set to the multi-switching angle joint bounded pruning module; wherein, the disturbance cost trend identification module only considers switching angles with effective descent directions and cost descent sensitivity greater than zero as candidate active angles, sorts the candidate active angles from high to low according to cost descent sensitivity, and selects the switching angles that are ranked first and whose number does not exceed the maximum size of the preset active set to form the active switching angle set;
[0030] The multi-switching angle joint bounded pruning module is used to construct an active angle joint feasible region that includes direction constraints, magnitude constraints, adjacent angle spacing constraints, and endpoint constraints, perform node splitting, feasibility pruning, cost lower bound pruning, and fixed budget termination, and output the joint correction amount to the pulse sequence reconstruction module.
[0031] The pulse sequence reconstruction module is used to superimpose the joint correction amount onto the nominal switching angle vector to generate a corrected pulse mode that maintains the original pulse quantity and topology, and output the inverter switching trigger signal.
[0032] The present invention also provides an electronic control device, including a processor and a memory, wherein the memory stores a computer program, and when the computer program is executed by the processor, it implements the model prediction pulse pattern optimization method as described above.
[0033] The present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the above-described model prediction pulse pattern optimization method is implemented.
[0034] Based on the above, this invention has the following technical advantages compared to offline optimized impulse mode, standard analytical gradient model predictive impulse mode control, and finite control set model predictive control.
[0035] First, this invention directly determines the descent direction by the cost difference between positive and negative feasible trial disturbances, without explicitly deriving the analytical Jacobian matrix of the cost function with respect to the switching angle or the recursive state sensitivity. The common-mode deviation in the cost estimation of nominal and disturbance candidates is differentially canceled in the calculation of the positive and negative cost differences, and the setting of the direction dead zone threshold further shields the direction reversal that may be caused by differential errors. This mechanism significantly reduces the sensitivity of direction discrimination to unmodeled non-ideal factors such as stator and rotor resistance temperature rise drift, mutual inductance changes, dead zone effects, and sampling delays, and can still reliably obtain the true descent direction of the cost function even when model parameters have deviations. Under the same switching frequency of approximately 250 Hz, this invention reduces the total harmonic distortion rate of the stator current in finite control set model predictive control from 9.36% to 4.52%, a relative reduction of approximately 51.7%, and the peak-to-peak torque ripple from 12% to less than 10%.
[0036] Second, this invention compresses the high-dimensional joint optimization problem into a low-dimensional activity subspace search by activating only key switching angles that do not exceed the maximum size of a preset activity set through sensitivity sorting. Within the joint feasible region, nodes that do not intersect with the joint feasible region are removed through feasibility pruning, and node regions that cannot be better than the current optimal solution are removed through cost lower bound pruning. The optimal joint correction amount is obtained within a fixed evaluation budget. In the multi-pulse embodiment, the online joint optimization dimension is reduced from five to two, the number of nodes is limited by a preset node upper limit, and the number of cost evaluations is capped by a preset evaluation budget upper limit, making the worst-case computational workload clearly predictable and meeting the real-time requirements of the embedded control cycle.
[0037] Third, the joint feasible region of this invention simultaneously satisfies directional constraints, single-angle correction amplitude constraints, coupling constraints such as the distance between adjacent switching angles not being less than the minimum pulse width protection amount, and endpoint constraints. The output solution only moves the original pulse edges without adding, deleting, or crossing pulses, maintaining the number of pulses and switching topology of the original optimized pulse mode, and the equivalent switching frequency is strictly locked near the preset value. In the zero-to-rated load torque step response test, this invention shortens the response time from approximately ten milliseconds in finite control set model prediction control to approximately five milliseconds, achieving a unity of steady-state harmonic suppression, dynamic response speed, and real-time calculation reliability. It is suitable for high-power, low-carrier-ratio application scenarios such as flywheel energy storage systems, offshore wind power generation systems, and all-electric propulsion ship systems. Attached Figure Description
[0038] Figure 1 This is a topology diagram of the medium-voltage drive system to which this invention applies;
[0039] Figure 2 This is a flowchart of the cost trend guidance and bounded pruning optimization of the present invention;
[0040] Figure 3This is a schematic diagram illustrating the adjustment of the switching angle using the pruning algorithm of this invention;
[0041] Figure 4 This is a waveform diagram of the steady-state three-phase switch state of the present invention;
[0042] Figure 5 This is a waveform diagram of the three-phase switch state during the dynamic process of this invention;
[0043] Figure 6 This is a waveform diagram of the steady-state electromagnetic torque of the present invention;
[0044] Figure 7 This is a waveform diagram of the electromagnetic torque during the dynamic process of this invention;
[0045] Figure 8 This is a waveform diagram of the steady-state three-phase stator current of the present invention;
[0046] Figure 9 This is a waveform diagram of the three-phase stator current during the dynamic process of this invention;
[0047] Figure 10 This is the stator current spectrum diagram of the present invention;
[0048] Figure 11 This is a frequency dynamic response diagram of the flywheel energy storage system under MPC control of the present invention when connected to the power grid;
[0049] Figure 12 This is a frequency dynamic response diagram of the flywheel energy storage system under MP3C control of the present invention when connected to the power grid;
[0050] Figure 13 This is the active power response diagram of the flywheel energy storage system under MPC control of the present invention when connected to the power grid;
[0051] Figure 14 This is the active power response diagram of the flywheel energy storage system under MP3C control of the present invention when connected to the power grid. Detailed Implementation
[0052] like Figures 1-14 As shown, this invention provides a method and system for optimizing model prediction impulse modes. The technical details are explained in detail below with reference to a specific application scenario.
[0053] like Figure 1As shown, this invention is applicable to high-power medium-voltage AC motor drive systems, particularly asynchronous motor drives powered by multi-level inverters and operating under low carrier ratio conditions. Typical applications include flywheel energy storage systems, offshore wind power systems, all-electric propulsion ship power systems, and high-pressure, high-capacity rolling mill drive systems. In these applications, power semiconductor devices are limited by heat dissipation conditions and switching losses, and the equivalent switching frequency of the inverter is typically strictly limited to within several hundred hertz, with a carrier ratio below 10. This invention, under these extreme operating conditions, achieves suppression of stator current harmonic distortion and improvement of torque dynamic response by online optimization of the inverter's pulse mode.
[0054] like Figure 2 As shown, the model prediction pulse mode optimization method provided by this invention is executed by a control unit, which includes a digital signal processor (DSP) and a field-programmable gate array (FPGA). The DSP is responsible for performing prediction calculations and optimization iterations, while the FPGA is responsible for pulse signal generation and dead-zone compensation. The method includes the following steps.
[0055] S1: Establish a multi-step prediction model
[0056] In step S1, the control unit establishes a multi-step prediction model for the stator current of the AC motor, and performs homogeneous initialization or residual correction on the nominal candidate trajectory and the disturbance candidate trajectory using the current measured current. This multi-step prediction model is based on the Euler discrete mathematical model of the asynchronous motor.
[0057] Physically, the multi-step prediction model runs as a software algorithm module within the prediction computation unit of the digital signal processor. The input data for this module includes: the stator current vector at time k of the current control cycle (i.e., the two current components in the α-β coordinate system); the rotor flux linkage vector at time k of the current control cycle (i.e., the two flux linkage components in the α-β coordinate system); and the stator voltage vector at time k of the current control cycle (i.e., the two voltage components in the α-β coordinate system). Both the current and flux linkage components are stored in floating-point format with a numerical precision of 32 bits. The voltage components are provided by the stator voltage vector sequence determined in subsequent step S2.
[0058] In the signal flow direction, the multi-step prediction module obtains the three-phase stator current at the current moment from the data acquisition module, and obtains the current component in the α-β coordinate system after Clarke transformation; it obtains the rotor flux linkage component at the current moment from the state observation module; and it obtains the stator voltage components at the current moment and for multiple future control cycles from the voltage vector phase angle compensation module. This module is triggered to execute once in each discrete sampling cycle, and the execution cycle is equal to the sampling cycle of the control system.
[0059] In terms of working principle, the multi-step prediction module performs recursive iterations based on the following discrete state-space equations. The predicted value of the stator current at the next moment... From the current stator current Rotor flux at the current moment and the stator voltage at the current moment Through the first coefficient matrix Second coefficient matrix and the third coefficient matrix The linear combination yields the expression:
[0060] ;
[0061] Next-moment prediction of rotor flux linkage From the rotor flux at the current moment and the stator current at the current moment Through the fourth coefficient matrix and the fifth coefficient matrix The linear combination yields the expression:
[0062] ;
[0063] The coefficient matrix described above is determined by the motor parameters and the speed coupling term. The motor parameters include stator resistance, rotor resistance, stator self-inductance, rotor self-inductance, stator-rotor mutual inductance, rotor angular velocity, and the discrete sampling period. The discrete sampling period is denoted as [equation missing]. The rotor angular velocity is The stator is self-conscious as The rotor's self-inductance is The mutual inductance between the stator and rotor is mutual inductance coefficient Defined as Leakage coefficient Defined as Equivalent resistance Defined as ,in For stator resistance, Rotor resistance. Rotor time constant. Defined as . This represents a second-order identity matrix. This represents a rotation matrix, with its first row and second column elements being... The element in the second row and first column is The diagonal elements are all zero. Based on the above definition, the expressions for each coefficient matrix are:
[0064] ;
[0065] ;
[0066] ;
[0067] ;
[0068] ;
[0069] Based on the above coefficient matrix, , , Substituting the expression into the stator current prediction equation This allows us to obtain the next predicted value of the stator current. Similarly, we can... , Substituting the expression into the rotor flux prediction equation This allows us to obtain the next predicted value of the rotor flux linkage. Through iterative recursion, the stator current value for multiple future control cycles can be predicted. This can be generalized to the [missing information - likely a specific control cycle or event]. Step, among which To predict the number of time-domain steps, the general term for current prediction is:
[0070] ;
[0071] in , and For a coefficient matrix , , , , The coefficient matrix of the mixed product is obtained by iteratively merging like terms.
[0072] For the nominal candidate trajectory and all disturbance candidate trajectories, the control unit reinitializes the initial prediction values of each candidate trajectory at the beginning of each control cycle using the measured quantum current, and calculates the one-step prediction residual from the previous control cycle. :
[0073] ;
[0074] in For the previous control cycle to the current moment The predicted current is calculated. The residual is equal to the current measured current minus the predicted current from the previous control cycle. The control unit uses this residual as a correction term, adding it with the same value to the predicted current of the nominal candidate trajectory and each disturbance candidate trajectory, ensuring that the common initial value deviation in all candidate predictions is corrected from the same source. This common residual correction mechanism eliminates system deviations caused by the inconsistency between the initial state of the prediction model and the actual state of the motor. In the multi-step prediction process, the voltage vector at each step is provided by the stator voltage vector sequence determined in the subsequent step S2.
[0075] The technical benefits of this step are: the multi-step prediction model provides current predictions for multiple future time points for subsequent cost function calculations; the common residual correction eliminates the common part of the prediction errors of the nominal candidate and the disturbance candidate, retaining only the differences caused by the change in switching angle, thus improving the reliability of cost comparison.
[0076] S2: Obtain the nominal switching angle vector and determine the voltage vector sequence
[0077] In step S2, the control unit calculates the modulation index of the current operating condition, extracts the nominal switching angle vector from the offline optimized pulse mode lookup table, and determines the stator voltage vector sequence in the prediction time domain based on the rotor flux angle and load angle.
[0078] In terms of physical structure, the offline optimized pulse pattern lookup table is pre-stored in the non-volatile memory of the digital signal processor in the form of a data table. Each row of the lookup table corresponds to a modulation index value and a pulse number combination, storing the corresponding nominal switching angle vector. The switching angle is defined as the angle value corresponding to the switching moment of the inverter's output pulse within a quarter of the fundamental cycle. The dimension of the nominal switching angle vector is determined by the preset pulse number. The voltage vector sequence generation unit is implemented in a field-programmable gate array in the form of digital logic circuits.
[0079] In the signal flow direction, the control unit obtains the DC bus voltage from the DC bus voltage sampling circuit. The measured value is obtained from the speed observation module to obtain the rotor angular velocity. The stator flux reference amplitude is obtained from the outer loop controller. The control unit calculates the modulation index in real time based on the values of the above three factors. The calculation formula is:
[0080] ;
[0081] The control unit uses the modulation index and preset number of pulses Linear interpolation addressing is performed in the offline optimized pulse mode lookup table to extract the nominal switching angle vector corresponding to the table entry that is closest to the modulation index. Simultaneously, the control unit obtains the rotor flux spatial observation angle from the flux observation module. Obtain the system power factor from the power factor calculation unit. Electromagnetic torque is obtained from the torque observation unit. The control unit calculates the stator and rotor load angles. The calculation formula is:
[0082] ;
[0083] in This is the reference amplitude of the rotor flux linkage. The control unit will use the spatial observation angle of the rotor flux linkage. With load angle Adding these together, and then superimposing two orthogonal phase compensation terms, yields the stator voltage vector space angle. :
[0084] ;
[0085] The first orthogonal phase compensation term is: Its physical basis comes from The inherent mathematical relationship between the voltage vector and the flux linkage vector in a coordinate system. In a two-phase stationary coordinate system, the stator voltage equation can be written as: Under sinusoidal steady-state conditions, The term corresponds to the time derivative of the flux linkage vector, which is expressed as a frequency domain term. The phase is ahead. Phase offset is an inherent relationship determined by coordinate system transformation and motor mathematical model. It is not an artificially introduced compensation, but a natural mathematical result of the superposition of Park transformation and Clark transformation.
[0086] The second orthogonal phase compensation term is: Its physical origin lies in the standardized alignment between the switching angle definition reference in the offline optimized pulse mode lookup table and the angular coordinate reference in the voltage vector space. The nominal switching angle vector in the offline OPP lookup table... It is defined in standard sine function form under the condition that the zero-crossing point of the fundamental voltage of phase A is taken as the reference phase, that is, each switching angle represents the electrical angular position relative to the zero-crossing point of the phase A voltage. The stator voltage vector space angle... Is Defined in a coordinate system, its phase reference datum is Axial direction. Because the phase of phase A voltage is... The existence of axis voltage components is determined by the Clark transform. Coordinate reference deviation: When applying the switching angle of the offline OPP meter to the voltage vector space angle, a fixed angular offset needs to be superimposed to unify the coordinate reference. This compensation amount is jointly determined by the selected coordinate transformation system (Clark transformation / Park transformation) and the phase definition of the offline OPP meter. Under the transformation system adopted in this invention, this value is... Therefore, the sum of the two orthogonal phase compensation terms is Its essence is the numerical superposition of phase shifts from two different physical sources, rather than artificial repeated compensation.
[0087] The control unit will adjust the stator voltage vector space angle. The output is sent to the pulse sequence reconstruction unit and the multi-step prediction module in step S1. The voltage vector sequence generation unit converts the stator voltage vector space angle into a switching state sequence of each phase voltage, which covers the voltage vector requirements of all sampling times in the prediction time domain.
[0088] The control unit will adjust the stator voltage vector space angle. The output is sent to the pulse sequence reconstruction unit and the multi-step prediction module in step S1. The voltage vector sequence generation unit converts the stator voltage vector space angle into a switching state sequence of each phase voltage, which covers the voltage vector requirements of all sampling times in the prediction time domain.
[0089] In terms of operating principle, the nominal switching angle vector represents the theoretically optimal switching moment that minimizes the stator current harmonics of the motor under the current modulation index. Since this nominal value is obtained based on offline optimization, its calculation does not depend on real-time motor parameters. Furthermore, the accurate calculation of the stator voltage vector space angle ensures that the voltage vector sequence used in the multi-step prediction model is in phase with the actual stator voltage of the motor.
[0090] The technical benefits of this step are: the offline lookup table provides a high-quality steady-state optimization benchmark, eliminating the need for online corrections to start from scratch; and precise voltage vector phase compensation keeps the prediction model synchronized with the actual system, avoiding prediction errors caused by phase deviations.
[0091] S3: Construct the comprehensive cost function and calculate the nominal cost.
[0092] In step S3, the control unit constructs a comprehensive cost function that includes a current tracking accuracy term and a switching angle deviation penalty term, and calculates the nominal cost corresponding to the nominal switching angle vector.
[0093] In terms of physical configuration, the comprehensive cost function runs as a software program within the cost calculation unit of the digital signal processor. The input data for this unit includes: the future stator predicted current components output by the multi-step prediction model in step S1, the future stator reference current components given by the outer loop controller, and the deviation of the switching angle vector to be evaluated from the nominal switching angle vector. All of the above data is stored in 32-bit floating-point format.
[0094] In the signal flow direction, the cost calculation unit reads the predicted current component from the multi-step prediction module, the reference current component from the reference value calculation module, and the current switching angle deviation to be evaluated from the disturbance cost trend identification module. The output of the cost calculation unit is a scalar value, which is passed to the disturbance cost trend identification module for subsequent comparison and judgment.
[0095] In terms of working principle, the comprehensive cost function The mathematical expression is:
[0096] ;
[0097] in and The outputs of the multi-step prediction model are respectively Future in coordinate system Stator predictor current component of the step; and The outer loop controller is given The first coordinate system The stator reference current component of the step; To predict the number of time-domain steps; This is the deviation between the switching angle vector to be evaluated and the nominal switching angle vector; The penalty weighting coefficient is used to suppress drastic jumps in the switching angle during transient processes, ensuring strict locking of the power device's switching frequency. The first part of the comprehensive cost function is the current tracking accuracy term, which equals the square of the difference between the stator α-axis predicted current and the α-axis reference current at each step in the prediction time domain, plus the square of the difference between the stator β-axis predicted current and the β-axis reference current, and then summed over all steps in the prediction time domain. This part measures the tracking accuracy of the predicted current trajectory to the reference current trajectory. The second part is the switching angle deviation penalty term, equal to the deviation amount... The square of the penalty weight coefficient The control unit will specify the nominal switching angle vector. Substituting into the above comprehensive cost function, the nominal cost is calculated. This nominal cost serves as the benchmark for comparing subsequent perturbation candidate costs. When calculating the cost of any candidate switching angle vector, if the switching angle deviation contains multiple non-zero components, then in the comprehensive cost function... The squared term represents the sum of the squares of all component deviations.
[0098] The technical benefits of this step are as follows: the current tracking accuracy term ensures the waveform quality and dynamic tracking capability of the motor current; the switching angle deviation penalty term suppresses the transient jump of the switching angle, ensuring that the switching frequency after online correction is strictly controlled.
[0099] S4: Feasible trial disturbance direction identification and activity angle screening
[0100] In step S4, within the feasible region satisfying the switching angle order and minimum pulse width constraints, the control unit applies positive-direction feasible trial disturbances, negative-direction feasible trial disturbances, or unilateral feasible trial disturbances to each nominal switching angle. It calculates the positive cost difference after applying the positive-direction feasible trial disturbance and the negative cost difference after applying the negative-direction feasible trial disturbance to each nominal switching angle. The descent direction is determined based on the smaller of the positive and negative cost differences, and the positive part of the ratio of the opposite of the smaller value to the disturbance amplitude is used as the cost descent sensitivity. Only when the smaller value is less than the opposite of the directional dead zone threshold is it determined that the corresponding switching angle has a valid descent direction, and this switching angle is selected as a candidate active angle. The candidate active angles are sorted from high to low according to their cost descent sensitivity, and the switching angles ranked first and whose number does not exceed the maximum size of the preset active set are selected to form an active set. Switching angles not selected into the active set remain unchanged in the current control cycle.
[0101] Physically, this step is executed jointly by the perturbation generation submodule and the cost comparison submodule in the digital signal processor. The perturbation generation submodule is responsible for calculating the feasible perturbation amplitude for each switching angle. The cost comparison submodule is responsible for storing the nominal cost value and the cost value of each perturbation candidate, and performing numerical comparison and sorting.
[0102] In the signal flow direction, the disturbance generation submodule obtains the nominal switching angle vector from step S2. Read the minimum pulse width protection value from memory And the preset disturbance upper limit. The cost comparison submodule obtains the nominal cost from step S3. The cost calculation unit obtains the candidate costs for each disturbance. The cost comparison submodule outputs the determined descent direction and sensitivity value to the multi-switching angle joint bounded pruning module.
[0103] In terms of working principle, let the nominal switching angle vector be... The nominal cost is recorded as The control unit defines the boundary switching angle. , For the first Each switching angle is checked by the control unit, which examines the interval between that switching angle and its adjacent switching angles. and Are all of them not less than the minimum pulse width protection amount? Check endpoint boundaries and Are they all not less than Determine the range of motion for each switching angle while maintaining the switching angle order and ensuring it is not less than the minimum pulse width protection value. For the first... Each switching angle, the control unit calculates the feasible positive disturbance amplitude. and feasible negative disturbance amplitude The positive disturbance amplitude is the maximum positive offset that satisfies all constraints. The negative disturbance amplitude is the absolute value of the maximum negative offset that satisfies all constraints. The control unit will set the positive disturbance amplitude... and negative disturbance amplitude Each is limited to a preset disturbance limit. The following applies: If a certain direction is feasible, the control unit generates a test disturbance candidate in that direction; if both directions are feasible, test disturbance candidates in both positive and negative directions are generated; if only one direction is feasible, only a single-sided test disturbance candidate is generated.
[0104] No. The candidate switching angle vectors after applying a positive perturbation to each switching angle are: ,in For the first A unit vector. The candidate switch angle vector after applying a negative direction perturbation is... The control unit substitutes the aforementioned candidate switch angle vectors for disturbances into the comprehensive cost function of step S3. Calculate the cost value corresponding to each perturbation candidate. Positive cost difference. Defined as:
[0105] ;
[0106] Negative cost difference Defined as:
[0107] ;
[0108] Control Unit Comparison and .like Less than and Less than the directional dead zone threshold the opposite number Then determine the first The downward direction of each switching angle The positive direction, that is .like Less than and Less than Then determine the first The downward direction of each switching angle In the negative direction, that is If neither of the above two conditions is met, then the first condition is determined to be... There is no effective downward direction for the switching angle, i.e. Cost reduction sensitivity Defined as:
[0109] ;
[0110] in This represents the actual amplitude of the applied disturbance. When only a one-sided disturbance is applied, Take the disturbance amplitude in that direction. The cost difference in that direction is taken. This sensitivity reflects the magnitude of the cost decrease caused by a unit angular displacement along the descent direction. The control unit applies this to all... After calculating the sensitivity for each switching angle, according to the sensitivity... Sort the switch angles from highest to lowest, and select those that are ranked first and whose number does not exceed the maximum size of the preset active set. The switching angle constitutes the active set The remaining switching angles not selected for the active set remain unchanged in the current control cycle. Direction dead zone threshold. It is a positive real number whose value is not less than the upper bound of the candidate cost difference error, so that the common mode deviation in the cost estimation of the nominal candidate and the disturbance candidate is differentially canceled in the cost difference calculation. The control unit only updates the switching angle after the actual cost decrease exceeds the upper bound of the error.
[0111] The technical benefits of this step are as follows: the cost descent direction is directly obtained through actual trial perturbation without the need to derive the analytical Jacobian matrix, thus reducing the algorithm's dependence on the accuracy of motor parameters; the common-mode deviation is canceled out in the differential operation, improving the robustness of direction discrimination; and sensitivity ranking prioritizes computational resources for the switching angle with the greatest potential for improvement, thereby compressing the high-dimensional problem into a low-dimensional activity set.
[0112] S5: Construction of Joint Feasible Region with Multiple Switch Angles and Bounded Pruning
[0113] In step S5, the control unit constructs a joint feasible region for multiple switching angles for the active set, divides the joint feasible region into multiple search nodes, performs feasibility pruning that has no intersection with the joint feasible region, and performs lower bound pruning based on the lower bound of node cost and the current optimal cost, and obtains the joint correction amount of the active switching angle within the fixed cost evaluation budget.
[0114] Physically, this step is executed by the branch and bound search module in the digital signal processor. This module includes a node storage unit, a splitting unit, a pruning decision unit, and an optimal solution update unit. The node storage unit stores the currently searched node in a tree data structure. The splitting unit is responsible for selecting the splitting dimension and generating child nodes. The pruning decision unit is responsible for performing feasibility determination and cost lower bound comparison. The optimal solution update unit is responsible for maintaining the current optimal cost and the corresponding joint correction vector.
[0115] In the signal flow direction, the branch delimitation search module receives the activity set from step S4. The switching angle numbers and the descent direction of each active switching angle are specified. and sensitivity value Obtain the corresponding component from the nominal switching angle vector in step S2. Read the minimum pulse width protection value from memory. Angle threshold Cost threshold and preset evaluation budget limit The joint correction amount output by this module It is passed to the pulse sequence reconstruction module.
[0116] In terms of working principle, the control unit only works on the active set. A correction is applied to the switching angles in the active set, while the correction for inactive switching angles is set to zero. Let the active set... Includes One switching angle, The control unit records the combined correction amount as... The control unit constructs a joint feasible domain. The joint feasible region simultaneously satisfies the following constraints. Directional constraints require... That is, the direction of the correction amount for each active switching angle is consistent with its corresponding downward direction. Single-angle correction amplitude constraint requirements. ,in For the first Maximum permissible amplitude of a single switching angle. Constraints on the order of adjacent switching angles. That is, the interval between any two adjacent switching angles after applying the correction amount is not less than the minimum pulse width protection amount. Endpoint constraint requirements That is, the correction amount applied to the first switching angle is not less than the minimum pulse width protection amount; and That is, the value after applying the correction to the last switching angle is no greater than half of π minus the minimum pulse width protection value. The above constraints constitute a constraint that includes coupling relationships. The feasible region of a polyhedron.
[0117] Control unit with joint feasible domain The outer hyperrectangle is used as the root node. The interval of this root node in each active dimension covers the entire range that the active switching angle can take in the joint feasible region. The control unit stores the root node in a node list. For each node in the node list, the control unit performs the following search iteration process.
[0118] First, the control unit checks the node and the joint feasible domain. The intersection of the nodes. If the node is with... If there is no overlap, the control unit immediately deletes the node and performs feasible pruning.
[0119] Second, the control unit projects the geometric center of the node onto the joint feasible region. Within, feasible representative points were obtained. The specific projection method is as follows: starting from the geometric center of the node, simultaneously contract inward along all dimensions until it falls into... Inside, the control unit calculates the candidate cost corresponding to the feasible representative point. .like Less than the current optimal cost The control unit updates the current optimal cost to The current optimal joint correction vector is then updated to the correction amount corresponding to the feasible representative point.
[0120] Third, the control unit calculates the lower bound of the cost for this node. Specifically, the control unit adopts a conservative upper bound on the directional slope. Calculate the lower bound of the node cost. Calculate the upper bound of the slope in the conservative direction. Indicates along the first The upper bound of the absolute value of the slope of the cost function in each switching angle direction is obtained offline within the working parameter envelope and corrected during online operation using the finite difference results of each node in step S4. Lower bound of node cost. The calculation formula is:
[0121] ;
[0122] in For this node at the th Width in each activity dimension. If Then the node is within the pruning tolerance. If the range cannot contain a solution better than the current best solution, the control unit deletes the node and performs lower bound pruning.
[0123] Fourth, for any nodes that have not been pruned, the control unit selects one of them to split. The criterion for selecting the split dimension is to choose one that makes the split dimension more pleasing. The largest dimension, i.e., the dimension with the largest product of the active switching angle sensitivity and the width of the node in the current dimension. At the midpoint of this dimension, the node is divided into two equal child nodes or split into two child nodes according to a preset ratio. The preset ratio is selected as the golden ratio. The control unit adds the child nodes generated by the split to the node list.
[0124] Fifth, after each round of search, the control unit lowers the cost bound of the nodes in the node list. Sort by size from smallest to largest, retaining only those nodes that appear at the top of the list and whose number does not exceed a preset limit. The node. When the maximum node width Below the preset angle threshold The optimal cost improvement in two consecutive rounds is less than the preset cost threshold. Or the cumulative number of cost evaluations reaches the preset evaluation budget limit. The control unit terminates the search when any of the conditions in step S3 are met. The cumulative cost evaluation count refers to the number of times the control unit calls the comprehensive cost function in step S3 during the search process. Calculate the cumulative number of times the cost value corresponding to the candidate switch angle vector is calculated. This cumulative number is capped by a preset evaluation budget. Direct constraint. Upon termination, the control unit outputs the current optimal joint correction vector. As the final search result.
[0125] The technical advantages of this step are as follows: the joint feasible region ensures that the output solution physically satisfies all switching constraints, moving only the original pulse edges without changing the pulse topology; the sensitivity and node width product criterion prioritizes the search along the direction with the greatest improvement potential; feasibility pruning and lower bound pruning significantly reduce invalid searches; and the fixed evaluation budget makes the worst-case computational cost clearly predictable, meeting the requirements of real-time control.
[0126] S6: Output optimized switching angle sequence and generate trigger signal
[0127] like Figure 3 As shown, in step S6, the control unit superimposes the joint correction amount onto the nominal switching angle vector, outputs the actual switching angle sequence that satisfies the minimum spacing constraint between adjacent switching angles, and generates the inverter switching trigger signal.
[0128] Physically, this step is performed by a pulse sequence reconstruction module, which is implemented as a digital logic circuit in a field-programmable gate array (FPGA). This module includes an adder unit, a constraint verification unit, and a pulse width modulation (PWM) generation unit. The adder unit adds the nominal switching angle vector to the joint correction value term by term. The constraint verification unit checks whether the added switching angle sequence satisfies all physical constraints. The PWM generation unit converts the angular switching angle sequence into a time-domain comparison value, generating a PWM trigger signal to drive the inverter's power switching devices.
[0129] In the signal flow direction, the adder unit receives the nominal switching angle vector from step S2. Receive joint correction amount from step S5 The adder unit outputs the superimposed actual switching angle sequence to the constraint verification unit. After the constraint verification unit passes the verification, it outputs the actual switching angle sequence to the pulse width modulation generation unit. The multi-channel pulse width modulation signal generated by the pulse width modulation generation unit is transmitted to the drive circuits of each power switching device in the inverter after being isolated by optical fiber.
[0130] In terms of working principle, the actual switching angle sequence equal to the nominal switching angle With correction amount The sum of ,in And the non-active switch angle Due to the joint correction amount It is the joint feasible region in step S5 The actual switching angle sequence, obtained internally, automatically satisfies all constraints: the interval between adjacent switching angles. Not less than the minimum pulse width protection amount The first switch angle Not less than The last switch angle Not greater than Therefore, online correction only moves the edge position of the existing pulses, without inserting new pulses, deleting existing pulses, or changing the pulse crossing order. The control unit converts the above angle sequence into a switching trigger signal that matches the inverter topology. For a three-level active midpoint clamped inverter topology, the switching trigger signal includes the turn-on and turn-off signals of each power switching device, and the signal level is the drive level after level shifting of the fiber optic transmitter. The control unit stores the optimal actual switching angle sequence obtained in this control cycle in the buffer as a warm-start anchor point for the next control cycle, allowing subsequent optimization searches to continue rolling optimization from existing better solutions. If the constraint verification unit finds any violation of constraints during the verification process, it rejects the correction amount and backtracks to the nominal switching angle vector or the optimal sequence of the previous cycle, ensuring that no pulse sequence violating physical constraints is output under any abnormal conditions.
[0131] The technical benefits of this step are: the actual switching angle sequence maintains the number and topology of the original optimized pulse mode, and the switching frequency is strictly controlled; the immediate issuance of the correction pulse enables rapid dynamic response; the warm-start mechanism reduces the fluctuation of computational load between cycles and improves the consistency of optimization.
[0132] Based on the prediction model and comprehensive cost function established in steps S1 to S3, step S4 of this invention uses cost difference of feasible trial perturbation. and The descent direction can be reliably obtained without relying on analytic derivatives. and sensitivity Step S5 compresses the high-dimensional optimization problem into... Dimensional activity set search, and through joint feasible domain The design ensures that the output solution satisfies all physical constraints, and bounded pruning ensures that the cumulative cost evaluation count does not exceed a certain threshold. The above mechanism enables this invention to meet the performance requirements of steady-state harmonic suppression, dynamic response speed, and real-time calculation reliability under low carrier ratio conditions.
[0133] In step S1, the multi-step prediction model is established based on the Euler discrete mathematical model of the asynchronous motor. In its recursive prediction in the α-β coordinate system, the predicted value of the stator current at the next moment is obtained by linear combination of the stator current at the current moment, the rotor flux linkage at the current moment, and the stator voltage at the current moment through a coefficient matrix. The predicted value of the rotor flux linkage at the next moment is obtained by linear combination of the rotor flux linkage at the current moment and the stator current at the current moment through a coefficient matrix. The coefficient matrix is jointly determined by the stator resistance, rotor resistance, stator self-inductance, rotor self-inductance, stator-rotor mutual inductance, rotor angular velocity, and discrete sampling period.
[0134] Based on the above implementation method, the multi-step prediction model in step S1 is specifically implemented in the digital signal processor as an iterative recursive algorithm. The prerequisite for executing this algorithm is obtaining all electromagnetic parameters of the motor, including stator resistance, rotor resistance, stator self-inductance, rotor self-inductance, and stator-rotor mutual inductance. These parameters are read from non-volatile memory during the control program initialization phase, or updated online by the parameter identification unit and written to the corresponding registers during operation. When the prediction calculation unit is triggered in each discrete sampling period, it reads the above parameters in parallel from the register set. Combining the current rotor angular velocity and the discrete sampling period, it first calculates six intermediate variables: mutual inductance coefficient, leakage flux coefficient, equivalent resistance, and rotor time constant. Then, it calculates all elements of the five coefficient matrices.
[0135] The expression for calculating the mutual inductance coefficient is:
[0136] ;
[0137] The expression for calculating the leakage flux coefficient is:
[0138] ;
[0139] The formula for calculating the equivalent resistance is:
[0140] ;
[0141] The expression for calculating the rotor time constant is:
[0142] ;
[0143] Based on the aforementioned intermediate variables, the expression for calculating the first coefficient matrix is as follows:
[0144] ;
[0145] The expression for calculating the second coefficient matrix is:
[0146] ;
[0147] The expression for calculating the third coefficient matrix is:
[0148] ;
[0149] The expression for calculating the fourth coefficient matrix is:
[0150] ;
[0151] The expression for calculating the fifth coefficient matrix is:
[0152] ;
[0153] After calculating all elements of the five coefficient matrices, the prediction calculation unit iteratively follows the stator current prediction equation and the rotor flux linkage prediction equation. The next predicted value of the stator current is equal to the first coefficient matrix multiplied by the current current, plus the second coefficient matrix multiplied by the current flux linkage, plus the third coefficient matrix multiplied by the current voltage. The next predicted value of the rotor flux linkage is equal to the fourth coefficient matrix multiplied by the current flux linkage, plus the fifth coefficient matrix multiplied by the current current.
[0154] This recursive iteration uses the measured stator current and observed rotor flux linkage sampled in the current control cycle as initial values. At each step within the prediction time domain, it sequentially calculates the predicted values of the stator current and rotor flux linkage, using the prediction result of the current step as the input for the next iteration, thus generating a complete current trajectory within the prediction time domain. The calculation of the coefficient matrix is performed once in each control cycle. With the discrete sampling cycle value fixed, the computational complexity of the coefficient matrix is independent of the number of switching angles and disturbance candidates; therefore, the calculation time for this step remains constant under rated operating conditions. In the specific numerical calculation of the coefficient matrix, the resistance parameter changes slowly with temperature rise. To eliminate the impact of resistance drift on prediction accuracy, the parameter identification unit performs online identification of the stator and rotor resistances at preset time intervals and writes the identification results into the register group for use in the coefficient matrix calculation of the next cycle. The mutual inductance parameter also shifts when the magnetic circuit saturation changes. In this case, the real-time mutual inductance estimate output by the flux linkage observer is used to replace the factory parameters for coefficient matrix updates.
[0155] The discrete state-space model based on the complete electromagnetic parameters of the asynchronous motor accurately describes the coupling relationship between the stator current and the rotor flux linkage, ensuring the accuracy of multi-step prediction; the explicit expressions of each coefficient matrix give the prediction calculation a clear mathematical form, which is convenient for fixed-point implementation by digital signal processors; the online parameter update mechanism enables the prediction model to follow the changes in the thermal state and magnetic circuit saturation state of the motor and continuously maintain the prediction accuracy.
[0156] In step S2, the modulation index is calculated in real time from the DC bus voltage, rotor angular velocity, and stator flux reference amplitude given by the outer loop controller. The control unit addresses the offline optimized pulse mode lookup table according to the modulation index and the preset pulse number to extract the nominal switching angle vector.
[0157] Based on the above implementation method, the modulation index calculation unit in step S2 is located after the output terminals of the speed loop and flux linkage loop of the digital signal processor and before the pulse mode lookup table. The inputs to this calculation unit are three physical quantities: the measured value of the DC bus voltage, the measured value of the rotor angular velocity, and the reference amplitude of the stator flux linkage. The measured value of the DC bus voltage is obtained by a DC bus voltage sampling circuit, which includes a voltage divider resistor network, an isolation amplifier, and an analog-to-digital converter, and outputs a digital value of the DC bus voltage. The measured value of the rotor angular velocity is provided by the speed observation module or the encoder speed measurement unit, and outputs a floating-point number in radians per second. The reference amplitude of the stator flux linkage is calculated by the outer loop flux linkage controller according to the operating conditions.
[0158] The modulation index calculation unit calculates the modulation index according to the following expression:
[0159] ;
[0160] The physical meaning of this expression is as follows: When the stator flux linkage rotates at an angular velocity in a rotating coordinate system, the product of its amplitude and the angular velocity determines the amplitude of the induced electromotive force. The ratio of this amplitude to the DC bus voltage reflects the modulation depth required to synthesize the desired voltage vector under the current DC bus voltage. When the DC bus voltage fluctuates, the modulation index changes accordingly, which is reflected in the selection of the pulse mode as an adjustment of the switching angle. Similarly, when the rotational speed or the stator flux linkage amplitude command changes, the modulation index is dynamically updated accordingly.
[0161] The control unit constructs the address key of a lookup table based on the calculated modulation index and the preset pulse number. The offline optimized pulse mode lookup table is stored in the flash memory of the digital signal processor. This lookup table is a two-dimensional table structure, with the modulation index as the first dimension and the pulse number as the second dimension. Each entry stores a sequence of switching angles with a length equal to the pulse number. During the offline phase, this lookup table is pre-filled using a numerical optimization algorithm, ensuring that each set of switching angle sequences represents the optimal solution that minimizes the total harmonic distortion of the motor stator current under the corresponding modulation index and pulse number conditions. The control unit performs two-dimensional linear interpolation in the lookup table using the current modulation index and the preset pulse number. Specifically, the control unit first locates the two table index values adjacent to the current modulation index in the modulation index dimension, then finds the entry in the pulse number dimension that perfectly matches the preset pulse number, and finally performs linear interpolation in the modulation index dimension. After calculating the interpolation weight, the interpolation result is output as the nominal switching angle vector.
[0162] During operation, if the DC bus voltage sampling value experiences a momentary jump, to prevent frequent pulse mode switching caused by sudden changes in the modulation index, the control unit sets up a first-order low-pass filter after the modulation index calculation module. The time constant of this filter matches the spectral distribution of the voltage sampling noise, thus filtering out high-frequency disturbances in the modulation index signal while retaining the useful signal. If the current modulation index exceeds the range covered by the lookup table, the control unit performs boundary limiting processing, restricting the modulation index to the maximum index value of the lookup table, and simultaneously reporting an over-modulation warning to the system management unit.
[0163] The modulation index is calculated in real time based on the DC bus voltage and speed, enabling the pulse mode to follow changes in system operating conditions. The offline lookup table interpolation addressing method provides deterministic computation time and storage space overhead, avoiding the uncertainty brought about by online numerical optimization. The use of the lookup table method makes the acquisition of the nominal switching angle independent of real-time motor parameters, reducing the control algorithm's dependence on the accuracy of motor parameter identification.
[0164] In step S2, when determining the stator voltage vector spatial angle, the control unit superimposes two orthogonal phase compensation terms based on the sum of the rotor flux spatial observation angle and the stator and rotor load angles. The first orthogonal phase compensation term is based on Faraday's law of electromagnetic induction and is used to compensate for the orthogonal phase of the stator voltage spatial vector leading the stator flux vector. The second orthogonal phase compensation term is used to compensate for the deviation between the spatial angle of the synthesized voltage vector and the phase defined by the pulse sequence of the offline optimized pulse mode.
[0165] Based on the above implementation method, the voltage vector phase angle compensation module in step S2 is implemented in a field-programmable gate array and a digital signal processor in the form of a combination of digital logic and software operation. The input of this module includes three data sources: the rotor flux spatial observation angle output by the flux observation module, the stator and rotor load angle output by the load angle calculation unit, and the phase compensation constant pre-stored in the register. The input of the load angle calculation unit is the power factor and the electromagnetic torque, wherein the power factor is obtained by power calculation from the voltage and current sampling values, and the electromagnetic torque is provided by the torque observation module.
[0166] The formula for calculating the load angle is:
[0167] ;
[0168] The control unit adds the rotor flux linkage spatial observation angle to the load angle to obtain the stator flux linkage vector spatial angle. Two orthogonal phase compensation terms are then superimposed on this to obtain the stator voltage vector spatial angle, expressed as:
[0169] ;
[0170] The first orthogonal phase compensation term is 90 degrees, based on Faraday's law of electromagnetic induction. Under sinusoidal steady-state conditions, the stator voltage space vector and the stator flux linkage vector have a 90-degree orthogonal phase relationship, meaning the voltage vector leads the flux linkage vector by 90 degrees. Without this compensation, the voltage vector phase used in the prediction model will deviate from the actual stator voltage phase by 90 degrees, resulting in a phase error between the predicted and measured currents. This compensation is implemented by a fixed phase offset register in the voltage vector phase angle compensation module, whose value is the digital angle value corresponding to 90 degrees.
[0171] The second orthogonal phase compensation term is 90 degrees, and its physical basis is the coordinate transformation relationship between the pulse sequence definition method of the offline optimized pulse mode and the three-phase voltage space vector synthesis. The offline optimized pulse mode usually defines the switching angle sequence in the form of a standard sine function, that is, the start and end times of the pulse are symmetrically distributed with respect to the zero-crossing point of the sine wave of the A-phase voltage. However, in the expression of the stator voltage vector synthesis in the α-β coordinate system, there is a 90-degree deviation between the spatial angle of the voltage vector and the phase angle of the three-phase voltage. This compensation ensures that the nominal switching angle vector extracted from the offline optimized pulse mode lookup table can be precisely aligned with the spatial angle of the voltage vector, avoiding pulse misalignment caused by inconsistent coordinate system definitions.
[0172] In the signal flow direction, the voltage vector phase angle compensation module receives the rotor flux spatial observation angle from the flux observation module in each control cycle. This angle is transmitted in the form of a digital angle value, ranging from 0 to 360 degrees. The load angle output by the load angle calculation unit is summed with the above angle in an adder. After modulo 360-degree normalization, it is summed with the two orthogonal phase compensation terms respectively to finally obtain the stator voltage vector spatial angle. This angle is output to the voltage vector sequence generation unit in the field programmable gate array, which determines the switching state combination of the three-phase voltages according to the current angle value.
[0173] Orthogonal phase compensation based on the law of electromagnetic induction ensures that the voltage vector in the prediction model is precisely aligned with the actual physical voltage in phase. The second orthogonal phase compensation defined for the pulse sequence of the offline optimized pulse mode allows the online optimization algorithm to directly use the nominal switching angle of the offline lookup table without the need for coordinate system transformation or recalculation of the lookup table. The two levels of compensation are independent and have clear physical meanings, which facilitates engineering implementation and debugging.
[0174] The comprehensive cost function mentioned in step S3 includes the sum of the squares of the difference between the stator α-axis predicted current and the α-axis reference current at each step in the prediction time domain, the sum of the squares of the difference between the stator β-axis predicted current and the β-axis reference current, and the product of the square of the switching angle deviation and the penalty weight coefficient; the penalty weight coefficient is used to limit the jump of the transient switching frequency.
[0175] Based on the above implementation method, the comprehensive cost function in step S3 is executed by the cost calculation unit, which receives two sets of input data. The first set is the predicted current component, including the α-axis predicted current and β-axis predicted current at each step in the prediction time domain, output by the multi-step prediction model in step S1. The second set is the reference current component, including the α-axis reference current and β-axis reference current in the same time series, provided by the reference value calculation module. The output of the cost calculation unit is a scalar cost value, which is passed to the cost comparison submodule in step S4 and the branch and bound search module in step S5.
[0176] The complete expression for the comprehensive cost function is:
[0177] ;
[0178] The value of the prediction time-domain steps is related to the sampling period of the control system and the desired dynamic response speed. Under the condition of a control period of 50 microseconds and a fundamental frequency of 50 Hz, the prediction time-domain steps range from 6 to 10, corresponding to a prediction time domain of approximately half a fundamental frequency period. The larger the prediction time-domain steps, the more future information can be foreseen during the dynamic response process, but the computational load of the cost function also increases accordingly.
[0179] The calculation of the current tracking accuracy term involves the summation of the squared current error at each step within the prediction time domain. For the _th ... In each step, the α-axis current error equals the predicted current minus the reference current, and the β-axis current error equals the predicted current minus the reference current. The control unit calculates the squared errors of the two components separately and then adds them together to obtain the instantaneous tracking error cost for that step. The sum of the instantaneous tracking error costs for all steps yields the total value of the current tracking accuracy term. During the calculation process, the reference current sequence is provided in advance by the outer loop controller and stored in a circular buffer. The cost calculation unit reads the corresponding reference value from the buffer according to the time index.
[0180] The switching angle deviation penalty term is equal to the square of the deviation multiplied by the penalty weight coefficient. The deviation is defined as the difference between the actual switching angle and the nominal switching angle. When multiple switching angles in the candidate switching angle vector to be evaluated deviate from the nominal value, the deviation is the square root of the sum of the squares of the deviations in each dimension, i.e., the vector norm. Therefore, the square of the deviation is the sum of the squares of the deviations in each dimension. The penalty weight coefficient is a positive real number, and its value determines the weight ratio of the switching angle deviation in the comprehensive cost function. The penalty weight coefficient is related to the prediction time-domain steps and the magnitude of the current tracking error. To ensure that the switching angle deviation penalty term and the current tracking accuracy term are numerically comparable, this coefficient is set in the following manner in the implementation: First, the average magnitude of the current tracking accuracy term under rated operating conditions is calculated offline. Then, the penalty weight coefficient is set so that the penalty term corresponding to a switching angle deviation of 0.02 radians is equal to the average magnitude of the current tracking accuracy term. This coefficient is written into the register during control program initialization and remains constant during operation, or is dynamically adjusted by the upper-level scheduling unit according to the system operating conditions. The penalty weight coefficient ranges from [0.01, 10], and preferably, λ is between 0.1 and 1.
[0181] The calculation of the comprehensive cost function is performed in the digital signal processor using single-precision floating-point arithmetic. The current tracking accuracy term and the switching angle deviation penalty term are accumulated and summed separately. The final result is then saturated to a predefined numerical range to prevent abnormal cost comparisons due to numerical overflow.
[0182] The current tracking accuracy term directly reflects the quality of the stator current waveform and its ability to follow a given current command. It is a unified measure of steady-state harmonic suppression and dynamic response performance. The switching angle deviation penalty term constrains the square of the switching angle offset to ensure that the online optimized switching angle does not deviate significantly from the nominal position, thereby limiting the fluctuation of the switching frequency within a preset range. The two terms achieve a performance trade-off through a penalty weighting coefficient. The value of this coefficient can be flexibly adjusted according to the thermal characteristics of the actual device, adapting to different power devices and heat dissipation conditions within the same algorithm framework.
[0183] The residual correction in step S3 specifically involves the control unit calculating the one-step prediction residual of the previous control cycle, applying the same residual correction term to the nominal candidate trajectory and all disturbance candidate trajectories to update the prediction current, so that the common initial value deviation in each candidate prediction is corrected from the same source.
[0184] Based on the above implementation method, the residual correction mechanism is embedded between the multi-step prediction model in step S1 and the cost calculation unit in step S3, serving as the final processing step before the predicted current output. The input to the residual correction unit is the original predicted current sequence output by the multi-step prediction model and the one-step prediction residual stored in the previous control cycle, and the output is the corrected predicted current sequence, which is directly used as the input to the cost calculation unit.
[0185] The residual correction unit performs the following operations in each control cycle. First, the control unit reads the one-step prediction residual vector stored in the data buffer from the previous control cycle. This residual vector is calculated at the end of the previous control cycle and is defined as the measured current at the current moment minus the predicted current at the current moment from the previous control cycle. Let the measured current be... Let the predicted current of the previous control cycle be denoted as . Then predict the residual in one step. The expression is:
[0186] ;
[0187] The residual vector contains two components, α and β, which are stored in a dedicated residual register in floating-point format. The residual register is updated once per control cycle, after the measured current sampling for the current cycle has been completed and the predicted current calculation for the previous cycle has been completed.
[0188] Secondly, the control unit vector-superimposes the original predicted currents of all candidate trajectories output by the multi-step prediction model within the current period with the prediction residuals of the first step. Specifically, for the nominal candidate trajectory, its corrected predicted current equals the original predicted current plus the residual vector; for the... The corrected predicted current of the positive-direction perturbation candidate trajectory is equal to the original predicted current of that perturbation candidate plus the same residual vector; for the For each negative-direction perturbation candidate trajectory, the corrected predicted current is equal to the original predicted current of that perturbation candidate plus the same residual vector. All candidate trajectories share the same residual vector for correction, and the value of the residual vector remains consistent across all candidate trajectories.
[0189] The physical significance of this common-source correction lies in the fact that the one-step prediction residual encompasses the combined effects of all error sources, including prediction model error, parameter mismatch error, unmodeled dynamic error, and numerical quantization error. Since the original predicted currents of all candidate trajectories are calculated based on the same set of motor parameters and the same initial state, the aforementioned error components they contain are highly correlated in amplitude and direction, essentially belonging to a common error source. By adding the same residual correction term to all candidate trajectories, the common error components in each candidate trajectory are completely eliminated, while the bifurcation of the state trajectory caused by the different switching angles between candidate trajectories is fully preserved. Therefore, the difference between the candidate costs after residual correction only reflects the true impact of switching angle changes on the system state, without being disturbed by the inherent errors of the prediction model.
[0190] In the signal flow direction, the residual correction unit is located after the multi-step prediction module and before the cost calculation unit. The corrected predicted current sequence is passed to the cost calculation unit along the paths of the nominal candidate and each disturbance candidate. The cost calculation unit then calculates the nominal cost and the cost of each disturbance candidate based on the corrected predicted current; common prediction biases in these costs have been pre-eliminated.
[0191] Homologous residual correction makes optimization algorithms based on the cost difference of comparison candidates no longer rely on the absolute accuracy of the prediction model, but only on the relative order preservation of the prediction model among local candidates. This mechanism greatly reduces the requirements for the accuracy of motor parameters, while also mitigating the impact of digital quantization error and discretization error on direction determination.
[0192] In step S4, the control unit calculates the positive cost difference between the candidate cost and the nominal cost after applying a positive directional disturbance to each nominal switching angle, and the negative cost difference between the candidate cost and the nominal cost after applying a negative directional disturbance. The descent direction is determined based on the smaller of the positive cost difference and the negative cost difference. The cost descent sensitivity is the positive part of the ratio of the opposite of the smaller of the positive cost difference and the negative cost difference to the disturbance amplitude. The control unit selects the corresponding switching angle as a candidate active angle only when the cost descent exceeds the directional dead zone threshold. The control unit sorts the candidate active angles from high to low according to their cost descent sensitivity, and selects the switching angles that are ranked first and whose number does not exceed the maximum size of the preset active set to form the active set.
[0193] Based on the above implementation method, the direction identification and sensitivity calculation in step S4 are performed by the disturbance cost comparison unit in the digital signal processor. The input data for this unit includes the nominal cost transmitted from step S3. Positive perturbation candidate costs Negative perturbation candidate costs And the feasible disturbance amplitude of each switching angle. and The output of this unit is a descent direction indicator and sensitivity value for each switching angle, which are then output to the branch delimitation search module in step S5.
[0194] Disturbance cost comparison unit for the first Each switching angle is calculated sequentially as follows. First, the control unit reads the nominal cost from the register. Given two perturbation candidate values, calculate the positive cost difference and the negative cost difference respectively. The expression for the positive cost difference is:
[0195] ;
[0196] The expression for the negative cost difference is:
[0197] ;
[0198] In the two expressions above, Indicates the first The switching angle shifts in the positive direction (i.e., the direction in which the angle increases). The change in cost relative to the nominal position; Indicates the first The switching angle shifts in the negative direction (i.e., the direction in which the angle decreases). The cost change relative to the nominal position. If a certain direction is not feasible due to boundary constraints, the corresponding cost difference is assigned a preset positive infinity value, indicating that the direction cannot be used as a candidate descent direction.
[0199] Secondly, the control unit selects the smaller value between the positive cost difference and the negative cost difference, denoted as... Its expression is:
[0200] ;
[0201] like Less than the directional dead zone threshold the opposite number Then determine the first Each switching angle has a valid downward direction. If equal Then the descent direction is the positive direction, and the flag position is... ;like equal If so, the descent direction is negative, and the flag will be set. .like Not less than If the switch angle has no effective downward direction, the flag will be set. .
[0202] After determining the effective descent direction, the control unit calculates the cost-descent sensitivity for that switching angle. Cost-descent sensitivity The defining formula is:
[0203] ;
[0204] in For corresponding The amplitude of the directional perturbation. When the minimum cost difference comes from the positive direction. When the minimum cost difference comes from the negative direction This expression contains two key operations: first, taking... The opposite of the cost difference is positive when the cost difference is negative (i.e., the cost decreases after the disturbance), reflecting the cost reduction corresponding to a unit switching angular displacement; secondly, it is divided by the disturbance amplitude. This normalizes the cost reduction to a unit angle, making the sensitivities between different switching angles comparable. A maximum value operation is embedded in the sensitivity expression, comparing it to 0 to ensure that when... When the value is positive or zero, the sensitivity is set to 0, indicating that this direction cannot reduce the cost and should not be used as an optimization direction.
[0205] Directional dead zone threshold It is a positive real number, and its value is directly related to the upper bound of the candidate cost difference error. The method for setting this threshold is as follows: under rated operating conditions, the fluctuation amplitude of each candidate cost difference value in multiple control cycles is statistically analyzed offline. 1.5 times the statistical fluctuation amplitude is used as the initial threshold, and an adjustment coefficient is reserved to match the actual numerical level of different control cycles. The mechanism of this threshold is as follows: when the cost reduction of the disturbance candidate relative to the nominal candidate is less than this threshold, the reduction may come from non-real factors such as numerical quantization error and model residual fluctuation rather than the real optimization effect of the switching angle adjustment. The control unit does not determine this reduction as a valid reduction, thereby avoiding repeated direction reversals due to numerical noise in the flat region of the cost function.
[0206] After completing all After calculating the sensitivity of each switching angle, the control unit will The switching angles are sorted from highest to lowest sensitivity, and the ones selected at the top of the list and whose number does not exceed the maximum size of the preset active set are chosen. The switching angles constitute the active set. For The switching angle, although it may have a local downslope in a certain direction, is considered invalid and not included in the active set because the cost reduction is not sufficient to exceed the noise threshold.
[0207] The local morphology of the cost function for each switching angle was fully evaluated by using positive and negative bidirectional perturbation, avoiding the possibility of missing the true descent direction when only testing a single direction; sensitivity normalization enabled the optimization potential of switching angles at different positions to be compared on a uniform scale; the direction dead zone threshold effectively suppressed false direction determinations caused by noise in the flat region of the cost function, improving the reliability of the activity set selection.
[0208] The directional dead zone threshold is not less than the upper bound of the candidate cost differential error, so that the common mode deviation in the cost estimation of the nominal candidate and the disturbance candidate is differentially canceled in the calculation of the positive cost difference and the negative cost difference; the control unit updates the switching angle only after the actual cost decrease exceeds the upper bound of the candidate cost differential error.
[0209] Based on the above implementation method, the setting of the directional dead zone threshold is closely related to the quantitative evaluation of the candidate cost difference error. The upper bound of the candidate cost difference error refers to the maximum possible offset of the cost difference caused by factors such as prediction model parameter deviation, numerical quantization error, and current sampling noise under the most unfavorable conditions. This error upper bound is calculated by the control unit during the system initialization phase or parameter identification and update phase, and is dynamically corrected according to changes in operating conditions during operation.
[0210] The main sources of candidate cost differential error include the following three aspects. First, the deviation between the motor parameters and the actual motor parameters in the multi-step prediction model. This deviation leads to amplitude and phase errors between the predicted current and the actual current, thus affecting the cost value. Second, the rounding error of floating-point operations in the digital signal processor. This error accumulates with the number of prediction time-domain steps during the summation process. Third, the quantization noise and analog front-end noise of the current sampling channel. This noise is independently superimposed on the measured current value at each sampling, affecting the accuracy of the initial value of the prediction model.
[0211] Let the total deviation in cost caused by the errors from the above sources be... Among them, common mode deviation This refers to the cost deviation, which is numerically identical in the cost estimates of both the nominal candidate and each disturbance candidate, caused by a combination of factors including prediction model parameter bias, numerical quantization error, current sampling noise, and residual correction error. Since both the nominal candidate and each disturbance candidate use the same prediction model, the same motor parameters, and the same residual correction, this common-mode deviation... The costs are equal among all candidates and are canceled out by the difference in subsequent cost difference calculations. Therefore, the cost estimate for the nominal candidate is... Equal to the true nominal cost Add common mode bias and random error Its expression is:
[0212] ;
[0213] Similarly, the cost estimate for positively perturbed candidates Equal to the actual cost of disturbance Add the same common mode deviation and random error Its expression is:
[0214] ;
[0215] Cost estimate of negative direction perturbation candidates Equal to the actual cost of disturbance Add the same common mode deviation and random error Its expression is:
[0216] ;
[0217] Common mode deviation in the above three expressions The common-mode deviation is exactly equal between the nominal candidate and all disturbance candidates because all candidate trajectories are predicted using the same prediction model, the same motor parameters, and the same residual correction. This is because the common-mode deviation is calculated when calculating the positive cost difference. They completely cancel each other out during the subtraction process:
[0218] ;
[0219] Similarly, the common-mode bias in the negative cost difference It also completely offsets:
[0220] ;
[0221] The remaining valid signal in the two expressions above is the true cost difference, i.e. or and differential random error, i.e. or The magnitude of the differential random error is typically less than the upper bound of the sum of the magnitudes of the candidate random errors. Orientation dead zone threshold. The conditions for its value are:
[0222] ;
[0223] This condition ensures that when At this time, the directional dead zone threshold is not less than the maximum possible magnitude of the differential error. Under this condition, if the observed cost reduction... Greater than The control unit cannot determine whether the decrease stems from the optimization effect of the actual switching angle adjustment or from random error fluctuations, therefore it does not classify it as a valid decrease. Only when the actual cost decrease exceeds the upper bound of the differential error... Only then will the control unit determine that the direction is a valid descent direction and include the corresponding switching angle in the active set.
[0224] In the implementation, the upper bound of the candidate cost difference error is... The system updates online as follows: The control unit records the residual vector between the measured current and the predicted current in each control cycle and calculates the norm of this residual as a real-time measure of model accuracy. When model accuracy decreases, The directional dead zone threshold will be adjusted accordingly. This increase in accuracy leads the control unit to more conservatively accept direction decisions in cases of severe parameter mismatch. Conversely, when the model accuracy is high, The downward adjustment reduces the directional dead zone threshold, enabling the control unit to respond more sensitively to the decrease in real cost.
[0225] The numerical correlation between the directional dead zone threshold and the upper bound of the candidate cost difference error makes the threshold physically settable, avoiding the blindness of adjusting parameters based on experience. The principle of canceling common mode deviation in cost difference ensures that the directional information of the algorithm is not sensitive to the absolute accuracy of the prediction model, making the optimized direction still reliable after the motor parameters drift due to temperature rise.
[0226] In step S5, the joint feasible region simultaneously satisfies the directional constraint, the single-angle correction amplitude constraint, the coupling constraint that the distance between adjacent switching angles is not less than the minimum pulse width protection amount, and the endpoint constraint within the range of zero to half of π; the correction amount of the inactive switching angle is zero; the lower bound pruning specifically involves: the control unit using a conservative upper bound of the directional slope to calculate the lower bound of the node cost; when the lower bound of the node cost is not better than the difference between the current optimal cost and the pruning tolerance, the corresponding node is deleted; the control unit selects the splitting dimension according to the product of sensitivity and node width, and splits the node at a preset ratio; when any of the following conditions are met: the maximum node width is lower than the angle threshold, the improvement of the optimal cost in two consecutive rounds is less than the cost threshold, or the cumulative number of cost evaluations reaches the preset upper limit, the control unit terminates the search.
[0227] Based on the above implementation method, the construction of the joint feasible region of multiple switching angles and the bounded pruning search in step S5 are performed by the branch and bound search module in the digital signal processor. This module first constructs the joint feasible region of the active switching angles, and then searches for the optimal joint correction amount within the feasible region using a branch and bound algorithm.
[0228] Construction of joint feasible region
[0229] The control unit will activate the set The switching angle correction in the vector constitutes the vector. Joint feasible domain Defined as all of the following four types of constraints A set of.
[0230] The directional constraint requires that the correction direction of each active switching angle be consistent with its descent direction. For any active switching angle... satisfy .in The descent direction marker determined in step S4, This indicates that only positive corrections are allowed. This indicates that only negative corrections are allowed. When When the switching angle does not enter the active set, no directional constraint is generated.
[0231] The single-angle correction amplitude constraint requires that the absolute value of the correction amount of each active switching angle does not exceed its maximum allowable single-angle amplitude. ,Right now The maximum permissible amplitude of a single angle is determined by half the interval between the switching angle and the adjacent switching angle, as well as the minimum pulse width protection value. For the first... A switching angle, the maximum allowable amplitude in the positive direction is The maximum allowable amplitude in the negative direction is The control unit takes As a unified upper bound for amplitude constraints, this upper bound works together with direction constraints to ensure that the correction amount does not exceed half of the midpoint of adjacent switching angles.
[0232] The adjacent switching angle sequence constraint requires that the interval between any two adjacent switching angles after applying the correction amount should not be less than the minimum pulse width protection amount. For adjacent active angles and The expression for this constraint is:
[0233] ;
[0234] When there is a non-active angle between two adjacent active angles, the correction amount of the non-active angle is zero, and its switching angle position is fixed, which is equivalent to being within the constraint. The physical meaning of this constraint is to prevent two adjacent pulse edges from approaching or even crossing each other during the optimization process, thereby ensuring that the minimum pulse width of the inverter output is not less than the minimum turn-on and turn-off times allowed by the power switching devices.
[0235] The endpoint constraints require that the correction applied to the first switching angle is not less than the minimum pulse width protection value, and the correction applied to the last switching angle is not greater than half of π minus the minimum pulse width protection value. The expression for this is:
[0236] ;
[0237] ;
[0238] The correction for the inactive switching angle is set to zero, that is, for any... , .
[0239] The above four types of constraints are uniformly expressed as a system of linear inequalities in branch and bound search. , where the matrix Each row corresponds to a constraint. When the control unit performs a feasibility assessment on each node during the search process, it only needs to check whether there are points within the hyperrectangular region corresponding to that node that satisfy all linear inequalities to perform feasibility pruning.
[0240] The lower bound pruning specifically includes the following steps. For each node in the node list... Let the node be at the th node. The interval width in each activity dimension is The geometric center of this node is projected onto the joint feasible region. The feasible representative points obtained after internal processing are The control unit reads the upper bound of the conservative directional slope for each active dimension from the register. The upper bound of the conservative direction slope is expressed as follows: In the direction of each switching angle, the comprehensive cost function The supremum of the absolute value of the local slope is calculated offline within the envelope of the working parameters. This ensures that the value is not less than the absolute value of the actual slope under all possible operating conditions, and is corrected and updated during online operation using the results of multiple finite difference calculations in step S4.
[0241] Lower bound of node cost The calculation expression is:
[0242] ;
[0243] The physical meaning of this expression is: the cost of any point within the node region cannot be lower than the cost of its central representative point minus the sum of the maximum possible decreases in each dimension of the region. The conservative upper bound on the slope ensures that this lower bound is a safe lower bound, preventing the erroneous pruning of nodes containing the optimal solution due to an underestimated slope.
[0244] when At that time, the control unit deletes the node. As the current optimal cost, The pruning tolerance is related to the directional dead zone threshold. Maintain the same order of magnitude. The meaning of this pruning condition is: even if searching at any position within the node region, the minimum possible cost is no better than the difference between the current optimal solution and the pruning tolerance. The node cannot contain a better correction vector than the current optimal solution, so there is no need to further refine the search.
[0245] When selecting the split dimension, the control unit calculates separately for each active dimension. The product of these terms is used, and the dimension with the largest product is selected as the split dimension. The cost reduction sensitivity is calculated in step S4 for the switching angle corresponding to this dimension. This represents the width of the node in the current dimension. The physical meaning of this criterion is that directions with high sensitivity have greater potential for cost improvement, while directions with large widths have greater uncertainty. The product of the two reflects the expected contribution of this dimension to the search quality, and prioritizing splitting along this dimension can most quickly narrow the search space.
[0246] The control unit divides a node into two child nodes at the midpoint of the selected split dimension, with a preset ratio of equal division, meaning each child node occupies half the width of the dimension. The preset ratio is the golden ratio. When, the split position is set in the interval. and At the designated location, the node is split into two overlapping child nodes. The resulting child nodes are then added to the node list after a feasibility assessment, awaiting processing in subsequent rounds.
[0247] The control unit performs node truncation after each round of search, that is, it performs a lower bound on the cost of all nodes in the node list. Sort by size from smallest to largest, retaining only those nodes that appear at the top of the list and whose number does not exceed a preset limit. The node that is selected is deleted, and all other nodes are removed. This truncation operation is performed once after each round of searching to ensure that the number of nodes in the node list is strictly controlled in the worst case. This indirectly limits the computational cost of each search round.
[0248] The control unit terminates the search and outputs the results when any of the following conditions are met: First, the maximum node width. Below the preset angle threshold This indicates that the search has reached the preset angular resolution limit, and further refinement will not improve the quality of the final solution as much as expected. Secondly, the improvement in optimal cost over two consecutive rounds is less than the preset cost threshold. This indicates that the search has converged to the neighborhood of a local optimum. Third, the cumulative number of cost evaluations reaches a preset upper limit. This indicates that the search budget has been exhausted. Under this condition, the control unit outputs the current optimal solution to ensure the real-time performance of the algorithm.
[0249] All constraints of the joint feasible region are expressed as a set of linear inequalities before the search, enabling feasibility pruning to be efficiently implemented through linear programming. The upper bound of the conservative directional slope ensures the reliability of the lower bound of the cost, fundamentally guaranteeing that the pruning operation will not mistakenly delete the optimal solution. The sensitivity and node width product criterion ensures that the allocation of search resources matches the optimization potential and current uncertainty of each switching angle. The fixed budget termination condition makes the computational load in the worst case clearly predictable, meeting the time limit requirements of the embedded real-time control system.
[0250] This invention also provides a model prediction pulse mode optimization system applied to a high-power medium-voltage AC motor drive device powered by a multi-level inverter and operating under low carrier ratio conditions. The core control hardware of the system includes a digital signal processor (DSP) and a field-programmable gate array (FPGA), connected via a parallel data bus. The DSP performs computationally intensive tasks such as prediction calculation, cost evaluation, direction identification, and branch-bound search, while the FPGA performs timing-sensitive tasks such as voltage vector sequence generation, pulse width modulation signal generation, and dead-time compensation. Data exchange between the DSP and the FPGA occurs through a dual-port random access memory (DRAM), which is divided into a state buffer, a cost buffer, a switching angle buffer, and a trigger signal buffer.
[0251] The data flow relationships between the modules are as follows: The data acquisition module outputs the acquired three-phase current, rotor angular velocity, and DC bus voltage to the rolling prediction and cost calculation module and the reference value calculation module, respectively. The reference value calculation module outputs the stator current reference value and stator flux linkage reference amplitude to the rolling prediction and cost calculation module and the optimal pulse mode addressing module, respectively. The optimal pulse mode addressing module outputs the nominal switching angle vector to the disturbance cost trend identification module and the pulse sequence reconstruction module. The voltage vector phase angle compensation module outputs the three-phase voltage vector sequence to the rolling prediction and cost calculation module. The rolling prediction and cost calculation module outputs the nominal cost and disturbance candidate cost to the disturbance cost trend identification module. The disturbance cost trend identification module outputs the descent direction, sensitivity, and active switching angle set to the multi-switching angle joint bounded pruning module. The multi-switching angle joint bounded pruning module outputs the joint correction amount to the pulse sequence reconstruction module. The pulse sequence reconstruction module outputs the inverter switching trigger signal to the inverter drive circuit.
[0252] The data acquisition module physically comprises a three-phase current sampling circuit, a DC bus voltage sampling circuit, and a rotor speed detection circuit. The three-phase current sampling circuit uses a Hall effect current sensor, which is mounted on the three-phase power cable between the inverter output and the motor stator windings. The sensor output is an analog voltage signal, which is converted to a digital value by an analog-to-digital converter and then input to the current sampling port of the digital signal processor. The DC bus voltage sampling circuit uses a resistor divider network with an isolation amplifier. The divided signal is converted to a digital value by an analog-to-digital converter and then input to the voltage sampling port of the digital signal processor. The rotor speed detection circuit includes a photoelectric encoder or resolver and a corresponding decoding chip. The digital speed output from the decoding chip is input to the digital signal processor via a serial peripheral interface bus.
[0253] In the signal flow direction, the digital output of the three-phase stator current from the three-phase current sampling circuit is updated to the current register group once per control cycle. The values in the current register group are passed to the Clarke transform unit via direct memory access. This unit transforms the three-phase current from the stationary three-phase coordinate system to the α-β two-phase stationary coordinate system, obtaining the stator α-axis current component and the stator β-axis current component. The digital output of the DC bus voltage sampling circuit is updated to the voltage register, and this voltage value is passed to the modulation index calculation unit and the voltage vector generation unit. The digital output of the rotor angular velocity from the rotor speed detection circuit is updated to the speed register, and this speed value is synchronously passed to the coefficient matrix calculation unit, modulation index calculation unit, and flux linkage observation unit in the multi-step prediction model. All outputs of this module are synchronously latched at the beginning of each control cycle to ensure that downstream modules use the system state information at the same time.
[0254] The use of Hall effect sensors enables non-invasive measurement of three-phase current, avoiding electrical connections to the main circuit; synchronous latching of each sampling channel ensures the temporal consistency of the initial values of the prediction model, eliminating initial value errors introduced by inconsistent sampling times.
[0255] The physical structure of the reference value calculation module includes a current reference generation unit and a flux linkage reference generation unit, both of which run as software algorithms within a digital signal processor. The module's input is the output of the outer loop controller, including torque current commands and flux linkage current commands obtained after proportional-integral adjustment of the speed error. These commands are then transformed from a rotating coordinate system to a stationary coordinate system to obtain the stator current reference value in the α-β coordinate system. This reference value is a time series, covering all steps within the prediction time domain, and is stored as an array in the reference value buffer. The stator flux linkage reference amplitude is directly given by the outer loop flux linkage controller based on the system operating conditions and is stored as a floating-point scalar.
[0256] In the signal flow direction, the current reference generation unit receives torque current commands and flux linkage current commands from the outer loop controller, obtains the α-axis reference current component and β-axis reference current component after coordinate transformation, and outputs the above reference current sequence to the reference value input terminal of the rolling prediction and cost calculation module. The flux linkage reference generation unit outputs the stator flux linkage reference amplitude to the modulation index calculation unit and the load angle calculation unit in the voltage vector phase angle compensation module.
[0257] The reference value calculation module transforms the output of the outer loop controller into the current reference trajectory for each step in the prediction time domain, so that the current tracking accuracy term in the cost function has the same time scale as the predicted current, thus achieving compatibility between predictive control and vector control frameworks.
[0258] The physical structure of the optimal pulse mode addressing module includes non-volatile memory and a lookup table addressing unit. The non-volatile memory stores an offline pre-computed optimal pulse mode lookup table, which is pre-filled using a numerical optimization algorithm before the system leaves the factory. Each entry corresponds to a set of nominal switching angle vectors. The lookup table addressing unit is implemented as a digital logic circuit within the digital signal processor.
[0259] In the signal flow direction, the lookup table addressing unit receives the real-time modulation index value from the modulation index calculation unit and the preset pulse number from the system configuration register. The addressing unit uses the modulation index value and the pulse number to construct the index key of a two-dimensional lookup table. First, it locates two adjacent table indices in the modulation index dimension; then, it locates the perfectly matching table entry in the pulse number dimension; finally, it performs linear interpolation in the modulation index dimension, calculates the interpolation weight, and outputs the interpolation result as the nominal switching angle vector. This nominal switching angle vector is stored as an array in the switching angle buffer and output to the disturbance cost trend identification module and the pulse sequence reconstruction module, respectively.
[0260] The use of offline lookup tables avoids the high computational overhead of online solution for the optimal pulse mode, making the acquisition time of the nominal switching angle the same as the access time of the modulation index lookup operation, thus meeting the time constraints of real-time control.
[0261] The physical components of the voltage vector phase angle compensation module include a rotor flux linkage angle input interface, a load angle calculation unit, and a phase compensation adder. The rotor flux linkage angle input interface receives the spatially observed rotor flux linkage angle from the flux linkage observation module. This angle is transmitted as a digital angle value, ranging from 0 to 360 degrees. The load angle calculation unit receives the power factor and electromagnetic torque from the power factor calculation unit and torque observation unit, and calculates the stator and rotor load angles based on the motor parameters. The phase compensation adder sequentially sums the spatially observed rotor flux linkage angle, the load angle, and two orthogonal phase compensation terms.
[0262] In the signal flow direction, the load angle calculation unit calculates the load angle according to the following expression:
[0263] ;
[0264] The phase-compensated adder superimposes the rotor flux spatial observation angle, load angle, and 180 degrees to obtain the stator voltage vector spatial angle:
[0265] ;
[0266] The angle is output to the voltage vector sequence generation unit in the field programmable gate array. The unit determines the switching state combination of the three-phase voltage according to the current angle value and generates a voltage vector sequence covering all sampling times in the prediction time domain. This sequence is output to the multi-step prediction model input terminal in the rolling prediction and cost calculation module.
[0267] The first orthogonal phase compensation based on Faraday's law of electromagnetic induction ensures that the voltage vector in the prediction model is precisely aligned with the actual physical voltage in phase; the second orthogonal phase compensation defined for the pulse sequence of the offline optimized pulse mode ensures that the nominal switching angle of the online addressing is completely consistent with the voltage vector space angle in phase reference.
[0268] The rolling prediction and cost calculation module physically comprises a multi-step prediction submodule and a cost calculation submodule, both running as software algorithms within a digital signal processor. The multi-step prediction submodule receives inputs from the stator current component at the current moment provided by the data acquisition module, the rotor flux linkage component at the current moment provided by the state observation module, and the voltage vector sequence provided by the voltage vector phase angle compensation module. This submodule iteratively recursively calculates the predicted current component for each step in the prediction time domain according to the discrete state-space equation established in step S1. The cost calculation submodule receives the predicted current component from the multi-step prediction submodule, the reference current component from the reference value calculation module, and the current switching angle deviation to be evaluated from the switching angle buffer, and calculates the scalar cost value according to the comprehensive cost function.
[0269] In the signal flow direction, the multi-step prediction submodule uses the stator current and rotor flux linkage at the current sampling moment as initial values and performs the following operations sequentially for each step in the prediction time domain. First, it calculates the next predicted value of the stator current based on the voltage vector and current state of the current step, then calculates the next predicted value of the rotor flux linkage, and uses the calculation result as the initial value for the next recursion until all prediction time domain steps are covered. The prediction result of each step is stored sequentially in the prediction current buffer. The cost calculation submodule reads the predicted current sequence in the prediction current buffer and the reference current sequence in the reference value buffer, accumulates the current tracking accuracy term item by item according to the comprehensive cost function, then reads the switching angle deviation to calculate the penalty term, and adds the two to obtain the final cost value.
[0270] The expression for the comprehensive cost function is:
[0271] ;
[0272] This module is called multiple times in each control cycle. The number of calls equals the nominal number of evaluations plus the total number of evaluations for all disturbance candidates, i.e., at least [number missing]. Each time it is called, the multi-step prediction submodule and the cost calculation submodule use the same prediction model parameters and the same reference current sequence, only the switching angle vector to be evaluated is different. The calculation results of this module are output to the disturbance cost trend identification module.
[0273] The separation of the multi-step prediction submodule and the cost calculation submodule enables pipelined execution of prediction calculation and cost evaluation, improving the computational efficiency of the digital signal processor. The same prediction model parameters and reference sequence are used in each evaluation, ensuring consistency between different candidate costs.
[0274] The physical structure of the disturbance cost trend identification module includes a disturbance generation submodule, a cost comparison submodule, and an activity set selection submodule. The disturbance generation submodule receives the nominal switching angle vector from the optimal pulse mode addressing module, reads the minimum pulse width protection value and the preset disturbance upper limit from memory, calculates feasible positive and negative disturbance amplitudes for each switching angle, and generates positive and negative disturbance candidate switching angle vectors. The cost comparison submodule receives the nominal cost value and the cost value of each disturbance candidate from the rolling prediction and cost calculation module, calculates the positive and negative cost differences, determines the descent direction of each switching angle, and calculates the sensitivity. The activity set selection submodule selects the set of activity angles based on the sensitivity ranking results.
[0275] In the signal flow direction, the disturbance generation submodule affects the nominal switching angle vector. The first in For each switching angle, calculate the feasible positive disturbance amplitude. and feasible negative disturbance amplitude Generate perturbation candidate vectors respectively and These candidate vectors are then output to the rolling prediction and cost calculation module. The cost comparison submodule receives the nominal cost. Positive perturbation candidate cost Negative direction perturbation candidate cost Calculate the positive cost difference and negative cost difference :
[0276] ;
[0277] ;
[0278] Cost Comparison Submodule Selection and The smaller value in is denoted as .like Less than the directional dead zone threshold the opposite number If so, then the direction is determined to be a valid descent direction. From the positive direction If it comes from the negative direction, then Cost reduction sensitivity Calculate according to the following formula:
[0279] ;
[0280] The activity set filtering submodule will include all The switching angles are sorted from highest to lowest sensitivity, and the ones selected at the top of the list and whose number does not exceed the maximum size of the preset active set are chosen. The switching angle constitutes the active set This module will determine the descent direction. Sensitivity and activity collection Output to the multi-switch angle combined bounded pruning module. Take no more than And an integer not less than 1, preferably with a value of , where P is the number of pulses within a quarter of the fundamental frequency period.
[0281] A bidirectional perturbation approach is used to fully evaluate the local morphology of the cost function in each switching angle direction, avoiding the problem of missing the descent direction that may occur with a single-direction perturbation approach. Sensitivity normalization enables the switching angles at different positions to be compared on the same scale to assess their optimization potential. The setting of the directional dead zone threshold makes the activity set screening immune to numerical noise in the flat region of the cost function.
[0282] The physical structure of the multi-switching angle joint bounded pruning module includes a node storage unit, a splitting unit, a pruning decision unit, and an optimal solution update unit. The node storage unit stores the currently searched nodes in a tree data structure. Each node records its interval boundaries, geometric center, and feasible representative points in each activity dimension. The splitting unit selects the splitting dimension based on the product of sensitivity and node width, generating child nodes. The pruning decision unit performs feasibility pruning and lower bound pruning. The optimal solution update unit maintains the current optimal cost and the corresponding joint correction vector.
[0283] In the signal flow direction, the node storage unit receives the activity set from the disturbance cost trend identification module. Switching angle number and descent direction in and sensitivity When constructing the root node, the node storage unit sets the initial search interval for each switching angle correction in the active set to be centered at 0 and based on the maximum allowable amplitude of a single angle. The interval with radius, i.e. The pruning decision unit checks the interval against the joint feasible region. If the intersection of the nodes is empty, the node is directly pruned. For nodes that pass feasibility pruning, the pruning decision unit projects the geometric center of the node onto the joint feasible region to obtain a feasible representative point. The optimal solution update unit calculates the candidate cost for the feasible representative point. If it is less than the current optimal cost Then update and the current optimal joint correction amount .
[0284] The pruning decision unit calculates the lower bound of the cost for this node. The calculation expression is:
[0285] ;
[0286] in As the upper bound of the slope in the conservative direction, For this node at the th Width in each activity dimension. If The pruning decision unit deletes the node.
[0287] For nodes that have not been pruned, the splitting unit is selected such that... The largest dimension is used as the splitting dimension, and nodes are split into two child nodes at a preset ratio position within this dimension. The splitting unit divides the current node's dimension interval into two sub-intervals according to a preferred ratio of 0.618, forming a left child node and a right child node, and adds the child nodes to the node list. After each round of search, the node storage unit updates the nodes in the node list according to the lower bound of the cost. Sort by size from smallest to largest, retaining only those nodes that appear at the top of the list and whose number does not exceed a preset limit. The node.
[0288] When the maximum node width Below the preset angle threshold The optimal cost improvement in two consecutive rounds is less than the preset cost threshold. Or the cumulative number of cost evaluations reaches the preset limit. When any of the conditions is met, the pruning decision unit terminates the search, and the optimal solution update unit outputs the current optimal joint correction vector. To the pulse sequence reconstruction module.
[0289] The node storage unit adopts a tree structure to realize the systematic traversal of the search space; the pruning decision unit performs dual pruning of feasibility and cost lower bound at the same time, which greatly reduces the amount of invalid search; the sensitivity and node width product criterion makes the computing resources prioritized for the switching angle direction with the most improvement potential; the dual constraints of fixed node upper limit and fixed evaluation budget make the worst computing cost clearly predictable.
[0290] The pulse sequence reconstruction module physically comprises an adder unit, a constraint verification unit, and a pulse width modulation (PWM) generation unit. The adder unit, implemented as a digital logic circuit in a field-programmable gate array (FPGA), adds the nominal switching angle vector and the joint correction value item by item. The constraint verification unit is a digital comparator array that checks whether the added switching angle sequence satisfies all physical constraints. The PWM generation unit contains multiple counter channels and comparator channels, converting the angular switching angle sequence into time-domain comparison values to generate PWM trigger signals for driving the inverter's power switching devices.
[0291] In the signal flow direction, the adder unit receives the nominal switching angle vector from the optimal pulse mode addressing module. Receive joint correction amount from multi-switching angle joint bounded pruning module The adder unit calculates the actual switching angle using the following expression:
[0292] ;
[0293] The correction amount for the inactive switching angle The adder unit will convert the actual switching angle sequence... The output is sent to the constraint verification unit. The constraint verification unit checks the following conditions one by one: the interval between adjacent switching angles. Are all of them not less than the minimum pulse width protection value? The first switch angle Is it not less than The last switch angle Is it not greater than If all conditions are met, the constraint verification unit outputs the switching angle sequence to the pulse width modulation generation unit. If any condition is not met, the constraint verification unit rejects the correction amount and outputs the nominal switching angle vector or the optimal sequence of the previous cycle back to the pulse width modulation generation unit.
[0294] The pulse width modulation (PWM) generation unit converts the received angle sequence into time-domain comparison values. Taking triangular carrier modulation as an example, the PWM generation unit converts the switching angles within a quarter of the fundamental frequency period... Multiply by the fundamental period and then divide by The corresponding turn-on and turn-off times are obtained, and pulse width modulation (PWM) switching signals for each phase arm are generated. These signals are then applied to the gates of each power switching device in the inverter after passing through an optical fiber isolation circuit and a drive amplification circuit. Simultaneously, the PWM generation unit stores the actual switching angle sequence output in the current control cycle in a buffer, serving as the warm-start anchor point for the next control cycle.
[0295] The cascaded design of the adder unit and the constraint verification unit ensures that the output switching angle sequence always meets the physical safety constraints of the inverter; the pulse width modulation generation unit directly converts the angle sequence into the switching drive signal, avoiding the delay that may be introduced by the intermediate numerical format conversion; the warm start anchor point buffer keeps the optimization solution of adjacent control cycles continuous and reduces pulse mutations during the cycle.
[0296] In this system, the data acquisition module, reference value calculation module, and voltage vector phase angle compensation module jointly provide the initial prediction value and reference trajectory for the rolling prediction and cost calculation module; the optimal pulse mode addressing module provides the steady-state optimization benchmark; and the disturbance cost trend identification module identifies the cost difference of the disturbance through positive and negative trial disturbances. and Identify the direction of descent and sensitivity The multi-switch angle joint bounded pruning module satisfies the joint feasible region. Under the premise of lower bound pruning and fixed budget termination of the search for joint correction amount; the pulse sequence reconstruction module superimposes the correction amount to the nominal value and outputs a switch trigger signal that satisfies all physical constraints. The above modules together realize online pulse mode optimization control that takes into account steady-state harmonic suppression, dynamic response speed and real-time calculation reliability under low carrier ratio conditions.
[0297] The method provided by this invention can be directly embedded in an electronic control device. This electronic control device includes a processor and a memory. The memory stores a computer program, which, when executed by the processor, implements all steps of the method of this invention (steps S1 to S6). The processor can be a digital signal processor, an ARM processor, or a heterogeneous computing core composed of an FPGA and a DSP. The memory includes non-volatile flash memory and volatile random access memory. The non-volatile flash memory stores the offline OPP lookup table and program firmware, while the random access memory temporarily stores the state variables of the prediction model, intermediate values of the cost function, and node data during the branch and bound search process. After the system is powered on, the processor loads and executes the program from the memory, synchronously sampling current, voltage, and speed according to each control cycle, performing multi-step prediction, disturbance cost comparison, branch and bound search, and pulse sequence reconstruction, and finally outputting a pulse width modulation trigger signal to drive the power switching devices of the inverter.
[0298] Furthermore, the method of the present invention can also be stored in the form of a computer program on a computer-readable storage medium. This storage medium includes, but is not limited to, non-volatile storage media such as EEPROM, solid-state drives, SD cards, USB flash drives, or CD-ROMs. When the program in the storage medium is read and executed by the processor of the electronic control device, the method of the present invention is implemented. The implementation methods of the electronic control device and storage medium described above are consistent with the technical essence of the foregoing method and system embodiments, and will not be repeated here.
[0299] Based on the above specific implementation methods, the following supplementary explanations are needed regarding the specific values of custom terms and some parameters.
[0300] The nominal candidate trajectory and the disturbance candidate trajectory are defined as follows: The nominal candidate trajectory is the predicted current trajectory obtained by substituting the nominal switching angle vector extracted in step S2 into the multi-step prediction model. This trajectory serves as the benchmark for all subsequent comparisons. The disturbance candidate trajectory is the predicted current trajectory obtained by applying a positive or negative disturbance to a certain switching angle in the nominal switching angle vector and then substituting the disturbed switching angle vector into the same multi-step prediction model. There is only one nominal candidate trajectory in each control cycle. The number of disturbance candidate trajectories depends on the number of feasible disturbance directions: two when both positive and negative directions are feasible, and one when only one direction is feasible. Homogeneous initialization means that all candidate trajectories use the same measured quantum current as the initial prediction value at the beginning of the current control cycle, ensuring that the prediction starting point of each candidate trajectory is consistent. Residual correction uses the one-step prediction residual from the previous control cycle as a correction term, superimposed with the same value into the predicted current of all candidate trajectories, so that the common prediction deviation in each candidate trajectory is differentially canceled. Homogeneous initialization and residual correction together constitute the initial value processing and error compensation links in the prediction evaluation architecture.
[0301] The active set is the set of switching angles selected from all nominal switching angles in step S4 that need to be jointly optimized within the current control cycle. The number of switching angles in the active set is limited by the preset maximum size of the active set. Switching angles outside the active set remain unchanged in nominal value within the current control cycle, and their correction is zero. The role of the active set is to compress the high-dimensional joint optimization problem into a low-dimensional subproblem. In the embodiment, when the number of pulses P=5, the maximum size of the active set is 2, reducing the dimension of online joint optimization from 5 to 2. The fixed cost evaluation budget refers to the upper limit of the cumulative number of times the control unit calls the comprehensive cost function to calculate the cost value corresponding to the candidate switching angle vector during the branch and bound search process in step S5. This upper limit is directly limited by the preset evaluation budget upper limit. In the embodiment, the value of this upper limit is related to the number of switching angles in the active set. When the size of the active set is 2, this upper limit is the number of actual split nodes in the search process multiplied by the number of child nodes generated by each split. The setting of the fixed cost evaluation budget ensures that the calculation time of the search process is controllable in the worst case, meeting the time limit requirements of the embedded real-time control system.
[0302] The minimum pulse width protection value is defined as the electrical angle value corresponding to the shortest time required for the inverter power switching device to fully turn on from receiving an on command and to fully turn off from receiving a off command. The value of the minimum pulse width protection value is jointly determined by the switching characteristic parameters of the power switching device and the DC bus voltage of the inverter, and in the embodiment, it is taken as the electrical angle corresponding to two percent of the fundamental period. This protection value is used to constrain the minimum spacing between any two adjacent switching angles in the switching angle sequence, ensuring that the on-time and off-time of each pulse output by the inverter are not less than the shortest allowed switching time of the power switching device, avoiding overheating or damage caused by the power switching device not being fully turned on or off due to excessively narrow pulse width. In step S4, the minimum pulse width protection value is used to calculate the feasible disturbance amplitude of each switching angle, and in step S5, it serves as a direct parameter for the adjacent angle order constraint and endpoint constraint of the joint feasible domain.
[0303] The disturbance amplitude is the angular displacement when the control unit applies a trial disturbance to the nominal switching angle in step S4. This amplitude is calculated independently in the positive and negative directions. The positive disturbance amplitude is the smaller of the maximum distance the switching angle can move in the direction of angle increase, constrained by the distance between the current switching angle and its adjacent switching angle, and the minimum pulse width protection amount, and a preset disturbance upper limit. The negative disturbance amplitude is the smaller of the maximum distance the switching angle can move in the direction of angle decrease, constrained by the distance between the current switching angle and its adjacent switching angle, and the minimum pulse width protection amount, and a preset disturbance upper limit. The disturbance amplitude appears as the denominator in the cost reduction sensitivity calculation in step S4, and its magnitude directly affects the sensitivity value. The smaller the disturbance amplitude, the more sensitive the response to the same cost reduction amount; conversely, the larger the amplitude, the less sensitive the response.
[0304] The directional dead zone threshold, a positive real number, is used to determine whether the decrease in the perturbation candidate cost is significant enough to be considered a valid descent direction. The value of the directional dead zone threshold is directly related to the upper bound of the candidate cost differential error. In this embodiment, the directional dead zone threshold is set to twice the upper bound of the candidate cost differential error. This setting ensures that only when the actual cost decrease exceeds the upper bound of the differential error is it adopted as a valid descent direction, avoiding false direction determinations caused by numerical quantization errors and fluctuations in the prediction model residuals. In step S4, the directional dead zone threshold is used in two determination stages: first, to determine whether there is a valid descent direction for each switching angle; and second, to determine the positive or negative polarity of the direction. The directional dead zone threshold and the pruning tolerance are on the same order of magnitude, and their combination ensures that the control unit remains stable in the flat region of the cost function and responds sensitively in the steep region of the cost function.
[0305] The conservative directional slope upper bound represents the supremum of the absolute value of the derivative of the comprehensive cost function with respect to the switching angle displacement along a certain active switching angle dimension. This upper bound is obtained offline by scanning and calculating all possible operating conditions within the envelope of the working parameters, ensuring that this value is not less than the maximum absolute value of the actual slope under any condition. During online operation, the control unit uses the results of multiple finite difference operations in step S4 to correct this upper bound, allowing it to adjust according to changes in motor parameters. In the node cost lower bound calculation in step S5, the conservative directional slope upper bound is multiplied by half the width of the node along that dimension, representing the maximum possible cost reduction along that dimension within the node region. The sum of the maximum reductions across multiple dimensions is subtracted from the cost of the central representative point to obtain the safe lower bound for the node. The conservatism of this upper bound ensures that the cost lower bound is always no greater than the true cost of any point within the node region, thus ensuring that the lower bound pruning operation will not mistakenly prune nodes containing the optimal solution.
[0306] Specifically, the upper bound of the conservative directional slope Offline calculation and online update can be performed in the following ways:
[0307] (1) Offline computing stage:
[0308] Within the range of motor parameter variations (stator and rotor resistance ±20%, inductance ±15%), speed range (0 to rated speed), and DC bus voltage range (rated voltage ±10%), all possible operating conditions are traversed. For each operating condition, the dimensions of each active switching angle are analyzed separately. At the nominal switching angle Apply small perturbations nearby (The range of values is) to (radians), calculate the corresponding change in the comprehensive cost function. To obtain the absolute value of the local slope in this dimension under this working condition:
[0309] ;
[0310] Take the maximum absolute value for all operating points as this dimension. upper bound of the initial conservative direction slope :
[0311] ;
[0312] This value is stored in the non-volatile memory of the control unit, ensuring that it is not less than the absolute value of the slope of the actual cost function under any operating condition.
[0313] (2) Online update phase:
[0314] After completing the probing disturbance in step S4 of each control cycle, the [missing information] is used... The actual disturbance cost difference of each switching angle With disturbance amplitude The ratio of the two slopes is used to calculate the absolute value of the measured slope under the current operating conditions:
[0315] ;
[0316] The control unit updates the upper bound of the conservative direction slope for this dimension using the following formula: Linew = max(Lioffline, α⋅Licurrent), where, This is a conservatism factor, preferably ranging from 1.2 to 1.5, used to ensure that the updated upper bound remains conservative (i.e., not less than the absolute value of the actual slope). The updated upper bound... The node cost lower bound is used for calculation in subsequent control cycles. The node width is the interval length of a node in a certain activity dimension during the branch-and-bound search process. The initial value of this width is equal to the full length of the search range of the activity switching angle in the joint feasible region. After each split operation, the width of the child node is the width of the parent node multiplied by the split ratio, and the node width gradually decreases as the search process progresses. The maximum node width is the maximum value of the width of all nodes in the current node list across all dimensions. When the maximum node width is lower than the angle threshold, it indicates that the search has reached the preset angle resolution limit, and further refinement of the search will not improve the quality of the final solution more than the expected benefit; therefore, it is used as one of the termination conditions.
[0317] Regarding the prediction time-domain steps, the prediction time-domain steps are the total number of forward recursion steps in a single prediction by the multi-step prediction model. In the embodiment, when the control period is 50 microseconds and the fundamental frequency is 50 Hz, the prediction time-domain steps range from 6 to 10, corresponding to a prediction time of approximately 0.12 milliseconds to 0.20 milliseconds. The value of the prediction time-domain steps is related to the sampling period and fundamental frequency of the control system. When the sampling period is shortened or the fundamental frequency is reduced, the prediction time-domain steps need to be increased accordingly to ensure that the prediction time-domain covers the same electrical angle range. Increasing the prediction time-domain steps linearly increases the accumulation count of the current tracking accuracy term in the comprehensive cost function. Therefore, under the premise of meeting the prediction time-domain coverage requirements, the minimum value of this number of steps is selected.
[0318] Regarding the range and boundary handling of the modulation index, its range is limited by the coverage of the offline optimized pulse pattern lookup table. When the real-time calculated modulation index exceeds the maximum index value of the lookup table, the control unit limits the modulation index to the maximum coverage range of the lookup table and reports the overmodulation status to the system management unit. When the modulation index is lower than the minimum index value of the lookup table, the control unit limits the modulation index to the minimum coverage range of the lookup table and outputs the switching angle sequence corresponding to the minimum modulation index. Within the allowable range of the modulation index, the offline optimized pulse pattern lookup table uses linear interpolation between two adjacent modulation index indices, and the interpolation weight is determined by the relative position of the current modulation index between two adjacent indices.
[0319] Regarding the alternative explanation for using the golden ratio of 0.618 as a preset splitting ratio in step S5, this ratio is only one implementation method for interval splitting and is not a necessary condition for direction identification or joint feasible region construction. When using an equal splitting ratio, the control unit divides the node into two child nodes of equal width at the midpoint of the selected splitting dimension. When using the golden ratio, the control unit generates two child nodes at positions 0.382 and 0.618 of the selected splitting dimension, respectively, with an overlapping area between the two child nodes. This overlapping area helps avoid the risk that the optimal solution might be split on the boundary between the two child nodes because the splitting position happens to be near the optimal solution. The equal splitting ratio is suitable for scenarios with limited computational resources and a relatively smooth cost function, while the golden ratio is suitable for scenarios with abundant computational resources and a local peak in the cost function. The control unit dynamically selects one of the two splitting ratios based on the remaining computational resources in the current control cycle.
[0320] Regarding the warm-start anchor point retention mechanism, the control unit stores the actual switching angle sequence obtained in each control cycle in a switching angle buffer. This sequence serves as the alternative initial value for the nominal switching angle vector in the next control cycle. In step S2 of the next control cycle, the control unit first checks whether the buffered warm-start anchor point satisfies the feasible region constraint under the current modulation index. If it does, the anchor point is used as the initial solution for the search, allowing the branch-and-bound search to start from an existing better solution rather than from the nominal switching angle vector. This mechanism utilizes the continuity of the system state between control cycles to maintain the continuity of solutions between adjacent cycles in the online search, reducing computational fluctuations and pulse abrupt changes between cycles.
[0321] To verify the technical effectiveness of the method and system described in this invention, simulation verification was conducted under low carrier ratio conditions. For example... Figure 4 As shown, the steady-state three-phase switch waveform demonstrates that the pulse edge distribution is regular and the switching frequency is fixed under the method of this invention; as Figure 5 As shown, the dynamic process three-phase switch state waveform displays that when the load changes abruptly, the pulse edges are finely adjusted online while the number of pulses and the topology remain unchanged; as shown... Figure 6 As shown, the steady-state electromagnetic torque waveform indicates relatively small torque ripple; as Figure 7 As shown, the dynamic process electromagnetic torque waveform displays a fast torque response and small overshoot; as Figure 8 As shown, the steady-state three-phase stator current waveform has good sinusoidal properties; as Figure 9 As shown, the dynamic process three-phase stator current waveforms demonstrate a rapid and smooth current transition; as... Figure 10 As shown, the stator current spectrum indicates that the amplitude of higher harmonics accounts for a small proportion of the fundamental frequency, which shows that the method of the present invention has excellent steady-state harmonic suppression performance.
[0322] like Figure 11 and Figure 12 The figures show a comparison of the frequency dynamic response of flywheel energy storage systems connected to the grid under MPC control and MP3C control, respectively. The method of this invention exhibits smaller frequency fluctuations and faster recovery. Figure 13 and Figure 14 The figures show a comparison of the active power response of the flywheel energy storage system when connected to the grid under MPC control and MP3C control, respectively. The active power response of the method of the present invention is more stable and has less fluctuation.
[0323] In summary, the online optimization method and system for model prediction pulse modes based on disturbance cost trend and multi-switching angle bounded pruning provided by this invention achieves high-performance control of AC motor drive systems under low carrier ratio conditions through the complete method flow of steps S1 to S6 and the system architecture of eight functional modules.
[0324] Step S1 establishes a multi-step prediction model for the asynchronous motor, providing an accurate predicted current trajectory for the cost function. Step S2 calculates the modulation index and searches for the optimal pulse mode offline, ensuring the optimal steady-state benchmark for the nominal switching angle vector under different operating conditions. Step S3 integrates the current tracking accuracy and switching angle deviation penalty into the same optimization objective through the comprehensive cost function. Step S4 identifies the descent direction and sensitivity by using the cost difference of positive and negative bidirectional feasible trial disturbances, reliably selecting the set of active switching angles without relying on analytical gradients. Step S5 performs feasibility pruning and cost lower bound pruning within the joint feasible region, obtaining the optimal joint correction amount that satisfies all physical constraints within a fixed evaluation budget. Step S6 superimposes the correction amount onto the nominal value and generates the inverter switching trigger signal.
[0325] The entire methodology, from state sampling, prediction calculation, direction identification, branch and bound search to pulse output, forms a complete real-time optimization closed loop. The system's eight modules correspond one-to-one with the steps described above: the data acquisition module provides the system state; the reference value calculation module and the voltage vector phase angle compensation module provide the reference trajectory and voltage sequence, respectively; the rolling prediction and cost calculation module performs prediction and evaluation; the disturbance cost trend identification module and the multi-switching angle joint bounded pruning module perform direction identification and bounded search, respectively; and the pulse sequence reconstruction module outputs a trigger signal that satisfies the constraints. The signal flow between each module is clear and explicit, collectively realizing all the functions of this invention.
[0326] This invention significantly improves dynamic response speed while maintaining offline optimized pulse mode steady-state harmonic suppression performance and fixed switching frequency. It also ensures the predictability of worst-case computational load through dual constraints of fixed evaluation budget and node upper limit. It is suitable for high-power, low-carrier-ratio applications with extremely strict requirements for heat dissipation and switching losses, such as flywheel energy storage systems, offshore wind power generation systems, and all-electric propulsion ship systems.
Claims
1. A method for optimizing model-predicted impulse modes, characterized in that, The method includes: S1: The control unit establishes a multi-step prediction model of the stator current of the AC motor, and performs homogeneous initialization or residual correction on the nominal candidate trajectory and the disturbance candidate trajectory with the current measured current. S2: The control unit calculates the modulation index of the current operating condition, extracts the nominal switching angle vector from the offline optimized pulse mode lookup table, and determines the stator voltage vector sequence in the prediction time domain based on the rotor flux angle and load angle. S3: The control unit constructs a comprehensive cost function that includes a current tracking accuracy term and a switching angle deviation penalty term, and calculates the nominal cost corresponding to the nominal switching angle vector; S4: Within the feasible region satisfying the switching angle order and minimum pulse width constraints, the control unit applies positive-direction feasible trial disturbances, negative-direction feasible trial disturbances, or unilateral feasible trial disturbances to each nominal switching angle, respectively, and calculates the positive cost difference after applying the positive-direction feasible trial disturbance and the negative cost difference after applying the negative-direction feasible trial disturbance to each nominal switching angle; the descent direction is determined based on the smaller value between the positive cost difference and the negative cost difference, and the positive part of the ratio of the opposite of the smaller value to the disturbance amplitude is used as the cost descent sensitivity; only when the smaller value is less than the opposite of the direction dead zone threshold is it determined that the corresponding switching angle has a valid descent direction, and the switching angle is selected as a candidate active angle; the candidate active angles are sorted from high to low according to the cost descent sensitivity, and the switching angles that are ranked first and whose number does not exceed the maximum size of the preset active set are selected to form an active set; the switching angles not selected into the active set remain unchanged in the current control cycle. S5: The control unit constructs a joint feasible region for multiple switching angles for the activity set, partitions the joint feasible region into multiple search nodes, performs feasibility pruning and lower bound pruning on the search nodes, and obtains the joint correction amount of the activity switching angle within a fixed cost evaluation budget; wherein, the feasibility pruning includes deleting search nodes that have no intersection with the joint feasible region; the lower bound pruning includes: determining the lower bound of the node cost of the search node, and deleting the search node when the lower bound of the node cost is not better than the difference between the current optimal cost and the pruning tolerance, wherein the lower bound of the node cost is determined based on the upper bound of the conservative direction slope and the width of the search node in the activity dimension; S6: The control unit superimposes the joint correction amount onto the nominal switching angle vector, outputs the actual switching angle sequence that satisfies the minimum spacing constraint between adjacent switching angles, and generates the inverter switching trigger signal.
2. The model prediction impulse mode optimization method according to claim 1, characterized in that, The multi-step prediction model in step S1 is based on the Euler discrete mathematical model of the asynchronous motor. In its recursive prediction in the α-β coordinate system, the predicted value of the stator current at the next moment is obtained by linear combination of the stator current at the current moment, the rotor flux linkage at the current moment, and the stator voltage at the current moment through a coefficient matrix. The predicted value of the rotor flux linkage at the next moment is obtained by linear combination of the rotor flux linkage at the current moment and the stator current at the current moment through a coefficient matrix. The coefficient matrix is jointly determined by the stator resistance, rotor resistance, stator self-inductance, rotor self-inductance, stator-rotor mutual inductance, rotor angular velocity, and discrete sampling period.
3. The model prediction impulse mode optimization method according to claim 1, characterized in that, The modulation index in step S2 is calculated in real time from the DC bus voltage, rotor angular velocity, and stator flux reference amplitude given by the outer loop controller. The control unit addresses the offline optimized pulse mode lookup table according to the modulation index and the preset pulse number to extract the nominal switching angle vector.
4. The model prediction impulse mode optimization method according to claim 1, characterized in that, In step S2, when determining the stator voltage vector spatial angle, the control unit superimposes two orthogonal phase compensation terms based on the sum of the rotor flux spatial observation angle and the stator and rotor load angles. The first orthogonal phase compensation term is based on Faraday's law of electromagnetic induction and is used to compensate for the orthogonal phase of the stator voltage spatial vector leading the stator flux vector. The second orthogonal phase compensation term is used to compensate for the deviation between the spatial angle of the synthesized voltage vector and the phase defined by the pulse sequence of the offline optimized pulse mode.
5. The model prediction impulse mode optimization method according to claim 1, characterized in that, The comprehensive cost function mentioned in step S3 includes the sum of the squares of the difference between the stator α-axis predicted current and the α-axis reference current at each step in the prediction time domain, the sum of the squares of the difference between the stator β-axis predicted current and the β-axis reference current, and the product of the square of the switching angle deviation and the penalty weight coefficient; the penalty weight coefficient is used to limit the jump of the transient switching frequency.
6. The model prediction impulse mode optimization method according to claim 1, characterized in that, The residual correction in step S3 specifically involves the control unit calculating the one-step prediction residual of the previous control cycle, applying the same residual correction term to the nominal candidate trajectory and all disturbance candidate trajectories to update the prediction current, so that the common initial value deviation in each candidate prediction is corrected from the same source.
7. The model prediction impulse mode optimization method according to claim 1, characterized in that: In step S4, the control unit determines the feasible positive disturbance amplitude and feasible negative disturbance amplitude of each nominal switching angle based on the interval between each nominal switching angle and the adjacent switching angle and the minimum pulse width protection amount, and limits the feasible positive disturbance amplitude and feasible negative disturbance amplitude to below the preset disturbance upper limit. When only one direction is feasible, generate a single-sided probing perturbation candidate; when both directions are feasible, generate a positive-direction probing perturbation candidate and a negative-direction probing perturbation candidate.
8. The model prediction impulse mode optimization method according to claim 7, characterized in that, The directional dead zone threshold is not less than the upper bound of the candidate cost differential error, so that the common mode deviation in the cost estimation of the nominal candidate and the perturbation candidate is differentially canceled in the calculation of the positive cost difference and the negative cost difference. The control unit updates the switching angle only after the actual cost decrease exceeds the upper bound of the candidate cost differential error.
9. The model prediction impulse mode optimization method according to claim 1, characterized in that: The joint feasible region described in step S5 simultaneously satisfies the direction constraint, the single-angle correction amplitude constraint, the coupling constraint that the distance between adjacent switching angles is not less than the minimum pulse width protection amount, and the constraint that the distance between zero and half of the range is equal to the minimum pulse width protection amount. Endpoint constraints within the range; the correction for inactive switching angles is zero; In the lower bound pruning, the control unit projects the geometric center of the search node into the joint feasible region to obtain a feasible representative point, calculates the candidate cost of the feasible representative point, and updates the current optimal cost and the current optimal joint correction amount if the candidate cost is better than the current optimal cost. The lower bound of the node cost is equal to the candidate cost of the feasible representative point minus the sum of the products of the upper bound of the conservative direction slope in each activity dimension and half the width of the search node in the corresponding dimension. The control unit selects the split dimension based on the product of sensitivity and node width, and splits the node at a preset ratio; When any of the following conditions are met: the maximum node width is lower than the angle threshold, the optimal cost improvement in two consecutive rounds is less than the cost threshold, or the cumulative cost evaluation count reaches the preset upper limit, the control unit terminates the search and outputs the current optimal joint correction amount.
10. A model prediction impulse mode optimization system, characterized in that, include: The data acquisition module is used to collect the three-phase current, rotor angular velocity and DC bus voltage of the AC motor in real time, and output the collected data to the rolling prediction and cost calculation module. The reference value calculation module is used to calculate the stator current reference value and the stator flux reference amplitude based on the output of the outer loop controller, and output the calculation results to the rolling prediction and cost calculation module and the optimal pulse mode addressing module, respectively. The optimal pulse mode addressing module is used to store offline pre-calculated optimal pulse mode data, extract the nominal switching angle vector based on the real-time modulation index and pulse number, and output the nominal switching angle vector to the disturbance cost trend identification module and the pulse sequence reconstruction module. The voltage vector phase angle compensation module is used to calculate the stator voltage vector space angle by combining the rotor flux angle, load angle and orthogonal phase compensation, determine the three-phase voltage vector sequence, and output the three-phase voltage vector sequence to the rolling prediction and cost calculation module. The rolling prediction and cost calculation module is used to perform multi-step recursive prediction in the prediction time domain based on discrete state equations, calculate the comprehensive cost function including current tracking accuracy term and switching angle deviation penalty term, and output the nominal cost and disturbance candidate cost to the disturbance cost trend identification module. The disturbance cost trend identification module is used to apply positive, negative, or unilateral feasible disturbances to each nominal switching angle within the feasible domain, compare the cost difference between the disturbance candidates and the nominal candidates, and output the descent direction, sensitivity, and active switching angle set to the multi-switching angle joint bounded pruning module; wherein, the disturbance cost trend identification module only considers switching angles with effective descent directions and cost descent sensitivity greater than zero as candidate active angles, sorts the candidate active angles from high to low according to cost descent sensitivity, and selects the switching angles that are ranked first and whose number does not exceed the maximum size of the preset active set to form the active switching angle set; The multi-switching angle joint bounded pruning module is used to construct an active angle joint feasible region that includes direction constraints, magnitude constraints, adjacent angle spacing constraints, and endpoint constraints, perform node splitting, feasibility pruning, cost lower bound pruning, and fixed budget termination, and output the joint correction amount to the pulse sequence reconstruction module. The pulse sequence reconstruction module is used to superimpose the joint correction amount onto the nominal switching angle vector to generate a corrected pulse mode that maintains the original pulse quantity and topology, and output the inverter switching trigger signal.
11. An electronic control device, characterized in that, It includes a processor and a memory, wherein the memory stores a computer program, which, when executed by the processor, implements the model prediction impulse mode optimization method as described in any one of claims 1 to 9.
12. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the model prediction impulse mode optimization method as described in any one of claims 1 to 9.
