Harmonic voltage suppression-based parallel active power filter control method

By combining a system consisting of sensors, digital controllers, and inverters with a second-order bandpass filter and an AI model, the harmonic compensation current is dynamically adjusted, solving the safety and stability problem of parallel active power filters under capacitive load conditions, and achieving effective suppression of harmonic voltage and stable operation of the power grid.

CN120879593APending Publication Date: 2025-10-31BEIJING ACCUENERGY TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511074027.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-01
Publication Date
2025-10-31

AI Technical Summary

Technical Problem

When the load is capacitive, parallel active power filters may cause a sharp increase in load current and active power filter output current, resulting in load or line damage and energy waste. Existing technologies cannot provide a safe and stable control method.

Method used

The system, consisting of sensors, digital controllers, current control loops, PWM drive modules, and voltage-source inverters, calculates harmonic compensation current commands through a second-order bandpass filter. It then combines an LSTM network and a GAN model to predict grid voltage changes, dynamically adjusts the filter gain and compensation current, and constructs a digital twin model for real-time control.

Benefits of technology

It effectively suppresses harmonic voltages, improves the safety and stability of the system and the effect of harmonic mitigation, can respond to load changes in advance, provides quantitative mitigation scores, and ensures the stable operation of the power grid.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120879593A_ABST
    Figure CN120879593A_ABST
Patent Text Reader

Abstract

The invention relates to a control method for a parallel active power filter based on harmonic voltage suppression, and belongs to the technical field of power control. Three-phase power grid voltages are respectively obtained through a sensor, and a compensation current instruction of each selected subharmonic of each phase is calculated and determined through a second-order band-pass filter bank of selected subharmonic; determining an instantaneous value instruction of the compensation current of each selected subharmonic of each phase according to the transfer function, summing the instantaneous value instruction of the compensation current of each selected subharmonic corresponding to each phase, determining a total instruction of the selected subharmonic of each phase, and sending the total instruction to a current control loop; and the current control loop modulates and drives the voltage type inverter through the PWM driving module, so that the compensation current waveform formed by the voltage type inverter is consistent with the total instruction current waveform, and the compensation current is input to the power grid. The safety and stability of the harmonic suppression process are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of power control, and in particular to a control method based on a parallel active power filter for harmonic voltage suppression. Background Technology

[0002] Parallel active power filters are widely used in low-voltage power systems for harmonic mitigation. By detecting load harmonics, they calculate the various harmonic components contained therein, and according to actual needs, control the voltage-source inverter to inject reverse harmonic current into the grid. By canceling out the harmonic current components in the grid, load harmonics are mitigated.

[0003] When a parallel active power filter is in operation, it is equivalent to a current source controlled by the load current. During harmonic mitigation, the reverse-injected harmonic current flows to the load. When the load is capacitive, the load and the active power filter form an active positive feedback network, causing a sharp increase in the load current and the output current of the active power filter. This may cause damage to the load or the line, and also result in a huge waste of electrical energy.

[0004] Therefore, how to provide a safe and stable control method for parallel active power filters has become a key issue. Summary of the Invention

[0005] To improve the safety and stability of the harmonic voltage suppression process, this application provides a control method for a parallel active power filter based on harmonic voltage suppression.

[0006] This application provides a control method for a parallel active power filter based on harmonic voltage suppression, employing the following technical solution: The parallel active power filter includes a sensor, a digital controller, a current control loop, a PWM drive module, and a voltage source inverter connected in sequence. The sensor is connected to the power grid or to a load. The voltage source inverter is connected to the power grid, and its output feedback is connected to the digital controller. The method is executed by the digital controller and includes: The three-phase grid voltage is obtained through the sensors. m = a, b, c; The compensation current command for each selected harmonic in each phase is determined by calculating a second-order bandpass filter bank with selected harmonics. The transfer function in the frequency domain is as follows: ; Where n is the selected harmonic order, The gain of each bandpass filter, Here are the damping coefficients of each bandpass filter. The fundamental angular frequency, For grid voltage The frequency domain representation is the nth harmonic compensation current command; Instructions for determining the instantaneous value of the compensation current for each selected harmonic in each phase based on the transfer function. ; The instantaneous values ​​of the compensation current for each corresponding selected harmonic are summed to determine the total command for each phase selected harmonic. The general command is sent to the current control loop, which then drives the voltage source inverter through the PWM drive module to make the compensation current waveform generated by the voltage source inverter consistent with the general command current waveform, and inputs the compensation current to the power grid.

[0007] By adopting the above technical solution, this application determines the general command for selected harmonics in each phase based on the grid voltage and a second-order bandpass filter, and generates a compensation current based on the general command and inputs it into the grid. The second-order bandpass filter only allows signals within a specific frequency range to pass through, thereby forming a low-impedance circuit at the target harmonic frequency. This causes the harmonic current to preferentially flow into the filter rather than the grid, limiting its consumption or circulation within the filter, thus reducing pollution to the grid.

[0008] This application simulates the characteristics of a second-order bandpass filter to provide a low-impedance discharge path for selected subharmonic currents, thereby reducing harmonic voltage. It constructs multiple virtual single-tuned passive power filter banks through an algorithm to remove harmonics. At the same time, it combines the advantages of passive power filters (which do not amplify load harmonic currents) and active power filters (which can be flexibly configured), improving the safety and stability of the harmonic suppression process.

[0009] Furthermore, the instruction to determine the instantaneous value of the compensation current for each selected harmonic in each phase based on the transfer function... ,include: Will Substituting into the transfer function, where, The sampling period is For the backward shift operator, discretization using zero-order preservation or first-order preservation yields the second-order difference equation: ; in, For the m-phase voltage, Select the compensation current command for phase m, number n. , , , and The coefficients are the calculated values; The instantaneous values ​​of the compensation current commands for each phase and each selected harmonic are determined based on the second-order difference equation. .

[0010] By adopting the above technical solution, the continuous domain transfer function is converted into a discrete difference equation, which can be efficiently implemented in a digital controller. Furthermore, the bilinear transformation has the characteristic of small frequency distortion, more accurately preserving the frequency response characteristics of the original continuous system, reducing the phase lag and gain error introduced by discretization. Moreover, the second-order difference equation only requires the voltage and current command values ​​of the current and the previous two time steps, resulting in low computational complexity and making it suitable for real-time control scenarios.

[0011] Furthermore, before calculating and determining the compensation current command for each selected harmonic in each phase using a second-order bandpass filter bank of selected harmonics, the method further includes: When a load switching signal or a change in grid operation mode is detected, the three-phase grid voltage is collected. and The fundamental component is used to calculate the impedance using the phasor method, and the result of the delay impedance calculation is applied using FPGA. Based on the identified impedance changes, the second-order bandpass filter is dynamically adjusted. : ; in, The updated gain of each bandpass filter, The gain of each bandpass filter before the update. Given the current grid impedance, This is the grid impedance before the update.

[0012] By adopting the above technical solution, the APF can automatically adapt to changes in the power grid structure and maintain a stable harmonic suppression effect by dynamically adjusting the gain of the bandpass filter in real time and identifying changes in the power grid impedance.

[0013] Furthermore, the digital controller is connected to an AI acceleration chip, and if a known load exists, the method further includes: Obtain the load characteristics of a known load; Obtain historical characteristics of various loads and their corresponding historical grid voltages, and use them as a dataset; Using the AI ​​acceleration chip, an LSTM network model is established. The LSTM network model is trained using the dataset to obtain an LSTM network voltage prediction model. Based on the load characteristics and the LSTM network voltage prediction model, the predicted grid voltage at a future preset time is predicted. Receive the predicted grid voltage sent by the AI ​​acceleration chip, and calculate the total predicted compensation current command for each phase selected harmonic based on the predicted grid voltage. When the known load is switched on or off, the predicted compensation current command is sent to the current control loop, and the current control loop then drives the voltage source inverter through the PWM drive module to make the compensation current waveform generated by the voltage source inverter consistent with the predicted compensation current command current waveform, and inputs the compensation current to the power grid.

[0014] By adopting the above technical solution, the future grid voltage is predicted through the LSTM network, enabling the APF to generate compensation current commands in advance before the known load switching. Compared with the traditional real-time detection method, the dynamic response is 1 to 2 fundamental frequency cycles ahead, and the AI ​​acceleration chip has strong parallel computing capabilities, thus improving computing efficiency.

[0015] Furthermore, the acquisition of historical characteristics of various loads and their corresponding historical grid voltages, as a dataset, includes: Acquire historical characteristics of various loads at different time scales and corresponding historical grid voltages; The historical characteristics of each load and the corresponding historical grid voltage are grouped into data groups; The data group trains a GAN model for each load and makes the data output by the GAN model satisfy the physical rules of electricity. A random noise vector is generated, and the random noise vector and historical features are input into the GAN model trained for each load to obtain multiple sets of simulated load features and corresponding simulated grid voltage for each load. The dataset consists of historical characteristics of various loads and their corresponding historical grid voltages, as well as simulated load characteristics and their corresponding simulated grid voltages.

[0016] By adopting the above technical solution, the dataset size is expanded by generating simulated load characteristics and grid voltage through GAN, and massive generalized samples are generated by combining random noise vectors to cover extreme operating conditions not included in historical data. This solves the problem of scarce rare operating condition data in the power system and improves the prediction accuracy of the LSTM prediction model.

[0017] Furthermore, the digital controller is connected to an AI acceleration chip, and the method further includes: Obtain the load current; Using the AI ​​acceleration chip, a twin model of the power grid-load-parallel active power filter is constructed, and the twin model is updated synchronously with the power grid voltage, the load current, and the compensation current. When the parallel active power filter inputs compensation current to the power grid, it determines whether the total harmonic current is greater than the preset value. If so, then generate feedback information; Otherwise, the governance score of the current compensation current is determined based on the total harmonic current.

[0018] By adopting the above technical solutions, a digital twin model of power grid-load-APF is constructed. The model status is updated synchronously by real-time collection of power grid voltage, load current and compensation current, so as to achieve accurate mapping of the dynamic characteristics of the system, predict future harmonic change trends, calculate the mitigation score based on total harmonic current, provide quantitative basis for APF control strategy optimization, realize real-time visualization and trend analysis of compensation effect, and assist operation and maintenance personnel in equipment status assessment.

[0019] Furthermore, the step of determining the governance score of the current compensation current based on the total harmonic current includes: The fundamental current and nth harmonic current before the input compensation current are obtained, as well as the nth harmonic current, RMS value, peak value, voltage phase and current phase after the input compensation current; The total number of times the nth harmonic current is monitored within a preset time period after the input compensation current is obtained. Calculate the total harmonic current distortion rate before compensation based on the nth harmonic current before and after the input compensation current. and the total harmonic current distortion rate after compensation , k=1 or 2, where The amplitude of the fundamental current. for The amplitude of the nth harmonic current; according to The reduction is calculated, and the reduction is compared with multiple first preset rating levels to determine the first rating. Each first preset rating level corresponds to a reduction within a preset range. The larger the reduction, the larger the corresponding first rating. The number of times the nth harmonic current after the input compensation current is less than the preset standard limit is determined as the number of times the standard is met, and the ratio of the number of times the standard is met to the total number of monitoring times is determined as the compliance rate. The pass rate is compared with the second preset rating level to determine the second rating. Each second preset rating level corresponds to multiple pass rates. The higher the pass rate, the higher the corresponding second rating. Calculate the ratio C of the effective value to the peak value of the nth harmonic current after input compensation current, determine the difference between the ratio C and the waveform factor of the ideal sine wave, and determine the third score by comparing the difference with the third preset score level. Each third preset score level corresponds to multiple differences. The smaller the difference, the larger the corresponding third score. The phase difference is calculated based on the voltage phase and the current phase. The power factor is determined based on the cosine value of the phase difference. The result of comparing the power factor with 1 is compared with the fourth preset level to determine the fourth score. Each fourth preset level corresponds to multiple power factors. The closer the fourth score is to 1, the larger the corresponding fourth score is. A governance score is calculated based on the first score, the second score, the third score, the fourth score, and their corresponding weights.

[0020] By adopting the above technical solution, a scoring system is constructed based on four dimensions: harmonic distortion frequency reduction, compliance rate, waveform factor, and power factor. This enables a comprehensive quantitative evaluation of the harmonic control effect, avoiding the one-sidedness of a single indicator. Furthermore, the scoring is calculated based on multiple monitoring data within a preset time period, capturing the characteristics of harmonic fluctuations and reflecting the dynamic stability of the control process. The weighted scoring provides a data-driven basis for adjusting the control parameters of parallel active power filters and upgrading equipment.

[0021] In summary, this application includes at least one of the following beneficial technical effects: 1. This application provides a low-impedance discharge path for selected subharmonic currents by simulating the characteristics of a second-order bandpass filter, thereby reducing harmonic voltage. Multiple virtual single-tuned passive power filter banks are constructed through an algorithm to remove harmonics. At the same time, it achieves the advantages of passive power filters in not amplifying load harmonic currents and active power filters in terms of flexible configuration. 2. By identifying changes in grid impedance in real time and dynamically adjusting the gain of the bandpass filter, the APF can automatically adapt to changes in grid structure and maintain a stable harmonic suppression effect. 3. By predicting future grid voltage through an LSTM network, the APF can generate compensation current commands in advance before the known load switching, thus providing a more dynamic response in advance compared to traditional real-time detection methods; 4. Construct a digital twin model of the power grid-load-APF, and update the model state synchronously by collecting real-time power grid voltage, load current and compensation current to achieve accurate mapping of the system's dynamic characteristics and predict future harmonic variation trends; 5. The governance score is calculated based on the total harmonic current, providing a quantitative basis for optimizing the APF control strategy. Attached Figure Description

[0022] Figure 1 This is a structural block diagram of each component in the parallel active power filter in the embodiments of this application.

[0023] Figure 2 This is a flowchart illustrating the control method of a parallel active power filter based on harmonic voltage suppression in the embodiments of this application. Detailed Implementation

[0024] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0025] Furthermore, the term "and / or" in this article is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, the character " / " in this article, unless otherwise specified, generally indicates that the preceding and following related objects have an "or" relationship.

[0026] This application discloses a control method for a parallel active power filter based on harmonic voltage suppression, which is applied to a parallel active power filter.

[0027] Reference Figure 1 The parallel active power filter is connected in sequence to a sensor, a digital controller, a current control loop, a PWM drive module, and a voltage source inverter. The sensor is connected to the power grid or to the load, and the voltage source inverter is connected to the power grid and its output feedback is connected to the digital controller.

[0028] Current / voltage sensors acquire grid / load signals and transmit them via analog cables to the A / D interface of the digital controller. After conversion into digital signals, these signals are used in calculations. The digital controller outputs PWM pulses, which are then optically isolated and input to the PWM drive module. The PWM drive module amplifies the signal to a suitable drive voltage for the IGBT / MOSFET. The output of the PWM drive module is directly connected to the gate of the inverter's power switching devices, controlling the switching on and off to achieve DC-to-AC energy conversion.

[0029] The compensation current output by the voltage-source inverter is sampled by a current sensor and fed back to the digital controller. After being compared with the reference current, an error signal is generated to correct the PWM pulse width, forming a closed loop of "sampling-control-execution-feedback".

[0030] The control method based on the harmonic voltage suppression parallel active power filter is executed by a digital controller, referring to... Figure 2 This includes (steps S101 to S105): Step S101: Obtain the three-phase grid voltages using sensors. , =a, b, c.

[0031] Specifically, the sensor acquires the three-phase grid voltage. , and This information is then sent to the digital controller.

[0032] Step S102: Calculate and determine the compensation current command for each selected harmonic in each phase using a second-order bandpass filter bank with selected harmonics. The transfer function in the frequency domain is: ; Where n is the selected harmonic order, The gain of each bandpass filter, Here are the damping coefficients of each bandpass filter. The fundamental angular frequency, For grid voltage The frequency domain representation, for Command for compensating the nth harmonic of a phase.

[0033] Specifically, nonlinear loads generate harmonic currents of a specific order, which may cause distortion of the power grid waveform tube. Selective harmonic compensation can suppress the target harmonics. Second-order bandpass filters are chosen as tools for extracting specific harmonics because of their simple structure and highly adjustable parameters.

[0034] In determining the gain of each bandpass filter, the amplitude of the nth harmonic voltage in the power grid can be measured or estimated. The permissible target harmonic compensation current amplitude is determined according to the harmonic standard. Then the gain can be calculated. ...

[0035] The damping factor must ensure that the filter has sufficient attenuation near the resonant point to prevent parallel resonance with the grid impedance. ,in The value can be selected based on the power grid type; for example, for a high-voltage power grid, then... =8~12, corresponding to =0.04~0.06; if the power grid, then =5~8, corresponding to =0.06~0.1.

[0036] In a stable power grid, the fundamental frequency is usually fixed, so a theoretical value can be used. However, if real-time performance and stability are to be further considered, the fundamental frequency can be updated in real time from the measured grid voltage using phase-locked loop (PLL) technology.

[0037] In another possible implementation, the gain of the bandpass filter will change when the load is switched or the grid operation mode changes. Therefore, the gain of the second-order bandpass filter needs to be updated before calculating the harmonic compensation current command (steps S11 to S12). Step S11: When a load switching signal or a change in grid operating mode is detected, the three-phase grid voltage is collected. and The fundamental component is used to calculate the impedance using the phasor method, and the delay impedance calculation results are used with FPGA.

[0038] The digital controller can determine whether the load should be switched on or off based on current changes. First, it obtains the current value within the current sampling period. and the current value in the previous sampling period. Then calculate the rate of change of current. ,like The current change threshold is used to determine whether the load should be switched on or off. This threshold can be adjusted based on the load type and can be selected as a multiple of the load's rated starting current.

[0039] Digital controllers can determine whether the power grid operation mode has changed, such as line switching, based on voltage distribution. This is done according to the voltage of each phase. , and Determine the maximum voltage among them. and minimum voltage And calculate the average value of each phase voltage. Then calculate the voltage imbalance. ,like A balance threshold is used to determine if the power grid's operating mode has changed. This balance threshold can be selected as a value between 2% and 3%.

[0040] When the digital controller detects a load switching signal or a change in the power grid operating mode, it acquires the voltage phasor. Current phasor Then the impedance phasor impedance amplitude Impedance phase .in, For voltage phase angle, It represents the current phase angle.

[0041] To match the action time of the digital controller with the timing of load switching or changes in grid operation, the delay impedance calculation results of the FPGA can be applied.

[0042] Step S12: Dynamically adjust the second-order bandpass filter based on the identified impedance changes. : ; in, The updated gain of each bandpass filter, The gain of each bandpass filter before the update. Given the current grid impedance, This is the grid impedance before the update.

[0043] Specifically, the digital controller updates the gain of each bandpass filter in real time based on changes in the grid impedance.

[0044] When the digital controller acquires the three-phase grid voltage respectively , and Then, the three-phase nth harmonic compensation current commands are calculated based on the transfer function. , and Among them, the selected harmonic order can be chosen based on the load characteristics, such as the 3rd, 5th, 7th, 11th, etc.

[0045] Step S103: Determine the instantaneous value of the compensation current for each selected harmonic in each phase based on the transfer function. This includes (steps S1031 to S1032): Step S1031: ... Substituting into the transfer function, where, The sampling period is For the backward shift operator, discretization using zero-order preservation or first-order preservation yields the second-order difference equation: ; in, For the m-phase voltage, Select the compensation current command for phase m, number n. , , , and These are the calculated coefficients.

[0046] Step S1032: Determine the instantaneous value of the compensation current command for each selected harmonic in each phase according to the second-order difference equation. .

[0047] Specifically, the digital controller substitutes s into the transfer function for discretization, obtaining a second-order difference equation that can calculate the instantaneous value of the compensation current, and then calculates the voltage of each phase. , and Substituting into the second-order difference equation, we obtain the instantaneous value of the compensation current command corresponding to the selected subharmonic. .

[0048] Step S104: Sum the instantaneous values ​​of the compensation current for each corresponding selected harmonic to determine the total command for each phase selected harmonic.

[0049] For example, after the digital controller calculates the instantaneous values ​​of the compensation current for the 3rd, 5th, 7th and 11th harmonics of phase a, it sums them to obtain the total command for the selected harmonic of phase a.

[0050] Step S105: The general command is sent to the current control loop, and then the current control loop modulates the voltage source inverter through the PWM drive module to make the compensation current waveform formed by the voltage source inverter consistent with the general command current waveform, and inputs the compensation current to the grid.

[0051] Specifically, when the compensation current is input into the power grid, the total harmonic current injected into the power grid will decrease, the voltage drop across the power grid impedance will decrease, the harmonic voltage drop will also decrease, and the output of the compensation current will also decrease after the harmonic voltage is reduced, thus avoiding positive feedback between the active power filter and the load, so that the harmonic voltage and harmonic current on the power grid side meet the requirements of relevant standards.

[0052] Therefore, in this application, the second-order bandpass filter only allows signals within a specific frequency range to pass through, thereby forming a low-impedance circuit at the target harmonic frequency. Since the power grid system impedance is relatively high, harmonic current preferentially flows into the filter rather than the power grid, confining it within the filter for consumption or circulation, thus reducing pollution to the power grid. Furthermore, when the filter resonates at the 5th harmonic (250Hz), its bandpass characteristics allow harmonics near 250Hz to pass through (i.e., be absorbed by the filter), while the fundamental frequency (50Hz) and other frequency harmonics are blocked by high impedance because they are outside the passband, thus achieving harmonic suppression.

[0053] This application simulates the characteristics of a second-order bandpass filter to provide a low-impedance discharge path for selected subharmonic currents, thereby reducing harmonic voltage. It constructs multiple virtual single-tuned passive power filter banks through algorithms to remove harmonics, thus achieving the advantages of passive power filters in not amplifying load harmonic currents and active power filters in terms of flexible configuration.

[0054] In another possible implementation, the compensation current can be predicted based on the load's operating conditions. For example, the power grid changes before and after the load is switched on or off. Therefore, to improve the adjustment speed, the digital controller is connected to an AI acceleration chip for loading the calculation process, and the above method includes (steps S21 to S25): Step S21: Obtain the load characteristics of the known load.

[0055] Specifically, the digital controller obtains the load current through sensors, and then separates load characteristics such as harmonic current and reactive power from the load current.

[0056] Step S22: Obtain the historical characteristics of various loads and their corresponding historical grid voltages, and use them as a dataset.

[0057] Specifically, the digital controller stores historical characteristics of various loads and corresponding historical grid voltages. These historical characteristics include historical harmonic currents and historical reactive power. This data can be real data or extended simulated data. To effectively expand the diversity of training samples, the method further includes (steps S221–S225): Step S221: Obtain historical characteristics of various loads at different time scales and the corresponding historical grid voltages.

[0058] Step S222: Form a data group by combining the historical characteristics of each load with the corresponding historical grid voltage.

[0059] Step S223: Train a GAN model for each load based on the data group, and make the data output by the GAN model satisfy the physical rules of electricity.

[0060] Specifically, in order to improve the authenticity of the extended data, a corresponding GAN model can be built for each type of load. GAN (Generative Adversarial Networks) is a deep learning model that generates data through adversarial training. It can make the generator output samples that approximate the real data distribution through the mutual adversarial interaction between the generator and the discriminator.

[0061] Therefore, we use data sets corresponding to each load to train a GAN model for each load, so that the output sample data closely resembles the real load data.

[0062] Step S224: Generate a random noise vector, input the random noise vector and historical features into the GAN model trained for each load, and obtain multiple sets of simulated load features and corresponding simulated grid voltages for each load.

[0063] Step S225: Collect the historical characteristics of various loads and their corresponding historical grid voltages, and the simulated load characteristics and their corresponding simulated grid voltages as a dataset.

[0064] Step S23: Using an AI acceleration chip, establish an LSTM network model, train the LSTM network model using a dataset, obtain an LSTM network voltage prediction model, and predict the grid voltage at a preset time in the future based on load characteristics and the LSTM network voltage prediction model.

[0065] Specifically, grid voltage is closely related to load characteristics. In order to facilitate the prediction of grid voltage based on load characteristics, an LSTM network voltage prediction model is pre-trained.

[0066] The LSTM model is trained using the dataset, so that the input of the trained LSTM network voltage prediction model is the load characteristics, and the output is the predicted grid voltage at a preset future time.

[0067] Step S24: Receive the predicted grid voltage sent by the AI ​​acceleration chip, and calculate the total command of the predicted compensation current for each phase selected harmonic based on the predicted grid voltage.

[0068] Step S25: When the load is known to be switching, the total predicted compensation current command is sent to the current control loop. The current control loop then modulates the voltage source inverter through the PWM drive module to make the compensation current waveform generated by the voltage source inverter consistent with the current waveform of the total predicted compensation current command, and inputs the compensation current to the grid.

[0069] Specifically, after the AI ​​acceleration chip obtains the predicted grid voltage, it inputs the predicted grid voltage into the transfer function, which then calculates the total predicted compensation current command. Therefore, when the load switching is known, the digital controller can directly select and apply the total predicted compensation current command to reduce harmonic current and improve processing speed.

[0070] Furthermore, after the digital controller inputs the compensation current to the power grid, the harmonic current is effectively controlled, thus the compensation effect can be evaluated, which facilitates the optimization of the generated compensation current. Therefore, the above method also includes (steps S31 to S35): Step S31: Obtain the load current.

[0071] Step S32: Apply an AI acceleration chip to build a twin model of the grid-load-parallel active power filter, and update the state of the twin model synchronously with grid voltage, load current and compensation current.

[0072] Step S33: After the parallel active power filter inputs compensation current to the power grid, determine whether the total harmonic current is greater than the preset value.

[0073] If so, proceed to step S24: Generate feedback information.

[0074] Specifically, after the compensation current is input into the power grid, the digital controller acquires the power grid current signal through sensors, converts the time-domain current signal into a frequency-domain signal, and thus analyzes the content of each harmonic to obtain the total harmonic current. After the compensation current is input into the power grid, the total harmonic current should decrease. To this end, the digital controller sets a preset value. When the total harmonic current exceeds the preset value, feedback information is generated to indicate that the current harmonic mitigation effect is unsatisfactory.

[0075] Otherwise, proceed to step S35: determine the governance score of the current compensation current based on the total harmonic current.

[0076] If the total harmonic current is not greater than the preset value, the current compensation current treatment status can be scored, making it easier to intuitively determine the treatment result based on the score. The specific method includes (steps S351 to S357): Step S351: Obtain the fundamental current and nth harmonic current before the input compensation current, and also the nth harmonic current, RMS value, peak value, voltage phase and current phase after the input compensation current.

[0077] Specifically, the digital controller acquires grid data before and after the input compensation current through sensors.

[0078] Step S352: Obtain the total number of harmonic monitoring times for the nth harmonic current after inputting the compensation current.

[0079] Step S353: Calculate the total harmonic current distortion rate before compensation based on the nth harmonic current before and after the input compensation current. and the total harmonic current distortion rate after compensation , k=1 or 2, where is the amplitude of the fundamental current. for The amplitude of the nth harmonic current; according to The reduction is calculated and compared with multiple first preset rating levels to determine the first rating. Each first preset rating level corresponds to a reduction within a preset range. The larger the reduction, the larger the corresponding first rating.

[0080] Specifically, the total harmonic current distortion rate (THD) characterizes the proportion of harmonic components relative to the fundamental frequency; a higher value indicates a greater deviation of the current waveform from a sine wave. Therefore, AI acceleration chips utilize... The reduction in harmonic current after compensation current treatment is calculated; the greater the reduction, the better the treatment result.

[0081] Therefore, the digital controller sets multiple first preset rating levels, each corresponding to a decrease within a preset range. The decrease is then compared with each preset range to determine the preset range into which the decrease falls as the first preset range. The first preset rating level within the first preset range is defined as a pending level, and the lower limit and interval values ​​of the pending level are obtained. The first rating is calculated as: First Rating = Lower Limit + Interval Value × .

[0082] For example, the first preset rating levels include: Preset range of reduction First preset rating level 60% ≤ Decrease < 100% 8-12 40% ≤ Decrease < 60% 6-8 20% ≤ Decrease < 40% 4-6 0 ≤ Decrease < 20% 2-4 Decrease < 0 1 point Therefore, if the reduction is 64%, comparing 64% with each preset range, the first one in the table is determined as the first preset range. The first first preset rating level is then set as the pending level, with a corresponding lower limit of 8 points and a rating range of 4 points. Therefore, the first rating is calculated as 8 + 4 × =8.4.

[0083] Step S354: The number of times the nth harmonic current after inputting the compensation current is less than the preset standard limit is determined as the number of times the standard is met, and the ratio of the number of times the standard is met to the total number of monitoring times is determined as the compliance rate.

[0084] The pass rate is compared with the second preset rating level to determine the second rating. Each second preset rating level corresponds to multiple pass rates. The higher the pass rate, the higher the corresponding second rating.

[0085] Specifically, the digital controller continuously monitors the power grid, thereby determining the total number of monitoring times within a preset time period. When the compensation current is input into the power grid, if the nth harmonic current is less than the preset standard limit, the treatment is deemed to have met the standard, and the harmonic number of the compliant harmonic is incremented by one. The preset standard limit can be set based on historical records.

[0086] For example, we can select key harmonic orders to analyze the compliance rate, such as the 3rd, 5th, and 7th harmonics. If the total number of tests within a preset time period is 9, the specific details are as follows: Harmonic order (n) Preset standard limit (A) Compensated harmonic current (A) Does it meet the standard (< the limit)? 3 9 8 yes 3 9 8.3 yes 3 9 8.8 yes 5 7.2 6 yes 5 7.2 7 yes 5 7.2 6.9 yes 7 5.8 6 no 7 5.8 5.5 yes 7 5.8 5 yes If the target was met 8 times, the pass rate would be 88.89%.

[0087] The second preset scoring levels are set as follows: ≥90% pass rate, 5 points for the second score; 80%≤pass rate<90% pass rate, 4 points for the second score; 70%≤pass rate<80% pass rate, 3 points for the second score; 60%≤pass rate<70% pass rate, 2 points for the second score; and <60% pass rate, 1 point for the second score.

[0088] Therefore, when the pass rate is 88.89%, the second score is 4 points.

[0089] Step S355: Calculate the ratio C of the effective value to the peak value of the nth harmonic current after inputting the compensation current, determine the difference between the ratio C and the waveform factor of the ideal sine wave, and determine the third score by comparing the difference with the third preset score level. Each third preset score level corresponds to multiple differences. The smaller the difference, the larger the corresponding third score.

[0090] Specifically, harmonic current waveform distortion causes the relationship between the effective value and peak value of the current to deviate from the sinusoidal law. Therefore, by comparing the ratio C with the waveform factor of an ideal sine wave, the degree of harmonic current distortion can be determined. The effective value of the harmonic current is the square root of the sum of the squares of the effective values ​​of all n harmonics, and the peak value is the algebraic sum of the peak values ​​of all harmonics. The waveform factor of the ideal sine wave is calculated as the ratio of the effective value to the peak value of the ideal sine wave, and its value is taken as 0.707. The smaller the difference, the closer the harmonic current waveform is to a sine wave after the input compensation current, and the better the mitigation effect.

[0091] The digital controller then sets multiple third preset rating levels for evaluating the magnitude of the difference: 5 points for difference ≤ 0.05; 4 points for difference ≤ 0.1; 3 points for difference ≤ 0.15; 2 points for difference ≤ 0.15; and 1 point for difference > 0.2.

[0092] If the difference is 0.15, the corresponding third score is 3 points.

[0093] Step S356: Calculate the phase difference based on the voltage phase and current phase, determine the power factor based on the cosine value of the phase difference, compare the power factor with 1 with the fourth preset level, and determine the fourth score. Each fourth preset level corresponds to multiple power factors. The closer the fourth score is to 1, the larger the corresponding fourth score is.

[0094] Specifically, the compensation current directly adjusts the phase of the total current and voltage by offsetting the reactive component of the load, thereby changing the power factor. Therefore, given that the harmonic mitigation effect of the compensation current is reflected through the distortion factor, the higher the power factor, the better the harmonic mitigation effect of the compensation current.

[0095] Therefore, this application sets a fourth preset level: power factor ≥ 0.95, fourth score 5 points; 0.9 ≤ power factor < 0.95, fourth score 4 points; 0.8 ≤ power factor < 0.9, fourth score 3 points; 0.7 ≤ power factor < 0.8, fourth score 2 points; power factor < 0.7, fourth score 1 point.

[0096] Step S357: Calculate the governance score based on the first score, second score, third score, fourth score and their corresponding weights.

[0097] Specifically, the digital controller can determine the corresponding weights based on the importance of each evaluation indicator, and the sum of the weights is 1. For example, the weights corresponding to the first score, second score, third score, and fourth score can be assigned to 0.4, 0.3, 0.2, and 0.1 respectively.

[0098] Furthermore, the digital controller can upload the governance score to the cloud, allowing staff to intuitively obtain the current harmonic governance effect based on the provided score.

[0099] The above are all preferred embodiments of this application, and are not intended to limit the scope of protection of this application. Therefore, all equivalent changes made in accordance with the structure, shape and principle of this application should be covered within the scope of protection of this application.

[0100] Additionally, it should be understood that relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. The terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.

Claims

1. A control method for a parallel active power filter based on harmonic voltage suppression, wherein the parallel active power filter comprises a sensor, a digital controller, a current control loop, a PWM drive module, and a voltage source inverter connected in sequence, wherein the sensor is connected to the power grid or to a load, the voltage source inverter is connected to the power grid and its output is fed back to the digital controller, characterized in that, The method is executed by the digital controller and includes: The three-phase grid voltage is obtained through the sensors. , =a, b, c; The compensation current command for each selected harmonic in each phase is determined by calculating a second-order bandpass filter bank with selected harmonics. The transfer function in the frequency domain is as follows: ; Where n is the selected harmonic order, The gain of each bandpass filter, Here are the damping coefficients of each bandpass filter. The fundamental angular frequency, For grid voltage The frequency domain representation, for Phase nth harmonic compensation current command; Instructions for determining the instantaneous value of the compensation current for each selected harmonic in each phase based on the transfer function. ; The instantaneous values ​​of the compensation current for each corresponding selected harmonic are summed to determine the total command for each phase selected harmonic. The general command is sent to the current control loop, which then drives the voltage source inverter through the PWM drive module to make the compensation current waveform generated by the voltage source inverter consistent with the general command current waveform, and inputs the compensation current to the power grid.

2. The method according to claim 1, characterized in that, The command to determine the instantaneous value of the compensation current for each selected harmonic in each phase based on the transfer function. ,include: Will Substituting into the transfer function, where, The sampling period is For the backward shift operator, discretization using zero-order preservation or first-order preservation yields the second-order difference equation: ; in, For the m-phase voltage, Select the compensation current command for phase m, number n. , , , and The coefficients obtained from the calculation; The instantaneous values ​​of the compensation current commands for each selected harmonic in each phase are determined based on the second-order difference equation. .

3. The method according to claim 1 or 2, characterized in that, Before calculating and determining the compensation current command for each selected harmonic of each phase using a second-order bandpass filter bank of selected harmonics, the method further includes: When a load switching signal or a change in grid operation mode is detected, the three-phase grid voltage is collected. and The fundamental component is used to calculate the impedance using the phasor method, and the result of the delay impedance calculation is applied using FPGA. Based on the identified impedance changes, the second-order bandpass filter is dynamically adjusted. : ; in, The updated gain of each bandpass filter, The gain of each bandpass filter before the update. Given the current grid impedance, This is the grid impedance before the update.

4. The method according to claim 1, characterized in that, The digital controller is connected to an AI acceleration chip. If a known load exists, the method further includes: Obtain the load characteristics of a known load; Obtain historical characteristics of various loads and their corresponding historical grid voltages, and use them as a dataset; Using the AI ​​acceleration chip, an LSTM network model is established. The LSTM network model is trained using the dataset to obtain an LSTM network voltage prediction model. Based on the load characteristics and the LSTM network voltage prediction model, the predicted grid voltage at a future preset time is predicted. Receive the predicted grid voltage sent by the AI ​​acceleration chip, and calculate the total predicted compensation current command for each phase selected harmonic based on the predicted grid voltage. When the known load is switched on or off, the predicted compensation current command is sent to the current control loop, and the current control loop then drives the voltage source inverter through the PWM drive module to make the compensation current waveform generated by the voltage source inverter consistent with the predicted compensation current command current waveform, and inputs the compensation current to the power grid.

5. The method according to claim 4, characterized in that, The acquisition of historical characteristics of various loads and their corresponding historical grid voltages, and the use of this data as a dataset, includes: Acquire historical characteristics of various loads at different time scales and corresponding historical grid voltages; The historical characteristics of each load and the corresponding historical grid voltage are grouped into data groups; The data group is used to train a GAN model for each load, and the data output by the GAN model is made to satisfy the physical rules of electricity. A random noise vector is generated, and the random noise vector and the historical features are input into the GAN model trained for each load to obtain multiple sets of simulated load features and corresponding simulated grid voltages for each load. The historical characteristics of various loads and their corresponding historical grid voltages, as well as the simulated load characteristics and their corresponding simulated grid voltages, are used as a dataset.

6. The method according to claim 1, characterized in that, The digital controller is connected to an AI acceleration chip, and the method further includes: Obtain the load current; Using the AI ​​acceleration chip, a twin model of the power grid-load-parallel active power filter is constructed, and the twin model is updated synchronously with the power grid voltage, the load current, and the compensation current. After the parallel active power filter inputs compensation current to the power grid, it is determined whether the total harmonic current is greater than a preset value. If so, then generate feedback information; Otherwise, the governance score of the current compensation current is determined based on the total harmonic current.

7. The method according to claim 6, characterized in that, The determination of the governance score for the current compensation current based on the total harmonic current includes: The fundamental current and nth harmonic current before the input compensation current are obtained, as well as the nth harmonic current, RMS value, peak value, voltage phase and current phase after the input compensation current are obtained. The total number of times the nth harmonic current is monitored within a preset time period after the input compensation current is obtained. The total harmonic current distortion rate before compensation is calculated based on the nth harmonic current before the input compensation current and the nth harmonic current after the input compensation current. and the total harmonic current distortion rate after compensation , k=1 or 2, where The amplitude of the fundamental current. for The amplitude of the nth harmonic current; according to The reduction is calculated, and the reduction is compared with multiple first preset rating levels to determine the first rating. Each first preset rating level corresponds to a reduction within a preset range. The larger the reduction, the larger the corresponding first rating. The number of times the nth harmonic current after the input compensation current is less than the preset standard limit is determined as the number of times the standard is met, and the ratio of the number of times the standard is met to the total number of monitoring times is determined as the compliance rate. The pass rate is compared with the second preset rating level to determine the second rating. Each second preset rating level corresponds to multiple pass rates. The higher the pass rate, the higher the corresponding second rating. Calculate the ratio C of the effective value to the peak value of the nth harmonic current after input compensation current, determine the difference between the ratio C and the waveform factor of the ideal sine wave, and determine the third score by comparing the difference with the third preset score level. Each third preset score level corresponds to multiple differences. The smaller the difference, the larger the corresponding third score. The phase difference is calculated based on the voltage phase and the current phase. The power factor is determined based on the cosine value of the phase difference. The result of comparing the power factor with 1 is compared with the fourth preset level to determine the fourth score. Each fourth preset level corresponds to multiple power factors. The closer the fourth score is to 1, the larger the corresponding fourth score is. A governance score is calculated based on the first score, the second score, the third score, the fourth score, and their corresponding weights.

8. The method according to claim 7, characterized in that, The step of comparing the reduction with multiple first preset rating levels to determine a first rating, where each first preset rating level corresponds to a reduction within a preset range, includes: The decrease is compared with each preset range, and the preset range into which the decrease falls is determined to be the first preset range; The first preset rating level within the first preset range is determined as the undetermined level, and the lower limit value and rating interval value of the undetermined level are obtained. Calculate the first score, where the first score = lower limit of the score + score interval value × .