A power distribution network island-grid smooth switching control method and system
By acquiring and extracting the voltage signals of the islanded distribution network and the main grid in real time, and using the inrush current prediction model and inverter regulation, a smooth grid connection switching between the islanded distribution network and the main grid was achieved. This solved the problem of inrush current impact during closing in existing technologies and improved power supply reliability and equipment safety.
Patent Information
- Application Number
- CN202511456923.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-13
- Publication Date
- 2026-02-03
- Estimated Expiration
- 2045-10-13
AI Technical Summary
Existing islanded grid-connected switching control technology for distribution networks is unable to achieve high-precision smooth switching, resulting in inrush current impacting equipment and affecting power supply reliability.
By acquiring and extracting the characteristics of the islanded and main grid voltage signals in real time, the inrush current range is predicted using the inrush current prediction model. The inverter output characteristic parameters are adjusted, and current information is collected for iterative optimization to generate grid-connected control commands to achieve smooth switching.
It significantly improves the smoothness and reliability of grid connection switching, reduces the impact of inrush current on equipment, and enhances the adaptability and robustness of the control system.
Smart Images

Figure CN120934067B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of grid-connected power distribution network, and particularly relates to a grid-connected smooth switching control method and system for islanded power distribution network. BACKGROUND
[0002] In modern power distribution networks with wide access of distributed power sources (such as photovoltaic and wind power), island operation is a common working condition. When the main grid fails, the load is adjusted or overhauled, the power distribution network containing distributed power sources will be separated from the main grid to form an island to ensure the power supply of local important loads. When the main grid is restored, the island needs to be reconnected to the grid. However, after the island and the main grid operate independently for a long time, there are significant differences in voltage amplitude, frequency and phase on both sides. When the island is connected to the grid, the closing inrush current will be generated due to the mismatch of parameters. If the inrush current is not controlled, it will cause insulation damage of circuit breakers, transformers and other equipment, and even affect the power supply reliability of surrounding users. Therefore, to realize the smooth switching control of the grid-connected islanded power distribution network is the key to ensuring the safety of power distribution network equipment and improving the power supply reliability.
[0003] The existing grid-connected switching control technology for islanded power distribution network mainly focuses on "parameter adjustment" and "closing timing selection", but has significant limitations and cannot meet the smooth switching requirements. Firstly, the traditional method often adopts fixed phase point closing (such as preset voltage zero crossing point), which only relies on historical experience or static parameter setting to determine the closing time, without real-time monitoring of the dynamic changes of voltage amplitude difference, frequency difference and phase difference between the island and the main grid, and cannot adapt to dynamic working conditions. Secondly, although some technologies introduce simple phase compensation, they only roughly adjust the phase difference through hardware circuit, and the closing decision relies on artificial experience, which is highly blind. Thirdly, the existing inverter adjustment is mainly "open-loop control", which does not collect output current information to form a feedback closed loop, and cannot meet the high-precision requirements of modern power distribution network for smooth grid connection. SUMMARY
[0004] The present application provides a grid-connected smooth switching control method and system for islanded power distribution network, which can realize the smooth switching of the islanded power distribution network and the main grid.
[0005] An embodiment of the present application provides a grid-connected smooth switching control method for islanded power distribution network, comprising:
[0006] characteristic values are obtained by extracting features from the obtained first voltage signal on the island side of the power distribution network and the second voltage signal on the main grid side;
[0007] The quantized characteristic values are input into a pre-trained inrush current prediction model to output a closing inrush current prediction range under different phase timings, and based on the closing inrush current prediction range, the width value and peak amplitude of the prediction range corresponding to each phase timing are calculated to identify the target phase interval of inrush current fluctuation, and the stability contribution of each phase timing is evaluated in the target phase interval to determine the target closing timing.
[0008] The inverter's output characteristic parameters are adjusted according to the target closing timing to obtain the adjusted inverter output signal. Current information in the inverter output signal is collected. When the current information meets the preset conditions, iterative optimization is performed to adjust the phase difference compensation to obtain the phase difference correction result. Based on the phase difference correction result, a grid connection control command is generated to control the smooth switching of islanded grid connection in the distribution network.
[0009] This application embodiment acquires voltage signals from both the islanded side and the main grid side in real time and extracts features, discretizing the continuous voltage signals on both sides into quantifiable features, providing a precise basis for inrush current prediction. Through the inrush current prediction model, the inrush current range under different phase sequences can be predicted, thereby achieving proactive anticipation and precise suppression of closing inrush current, avoiding blind closing and huge impacts caused by the inability to predict in traditional methods. Calculating the width and peak amplitude of the prediction range helps assess the fluctuation degree of inrush current, identify the target phase interval (i.e., the interval with smaller inrush current), and evaluate the stability contribution of each sequence, ensuring the selection of the most stable closing point. This makes the final decision no longer based on a single parameter, but on the optimal solution under multi-objective optimization, thus significantly improving the smoothness and reliability of grid connection switching. By adjusting inverter parameters and collecting output current information for feedback, phase difference can be compensated in real time, and iterative optimization can handle system uncertainties (such as load changes and noise), improving control accuracy and enhancing the adaptability and robustness of the control system under different operating conditions, ensuring the stability of the smooth switching effect. Compared with existing technologies, the present invention can more effectively and reliably limit the inrush current to the safe range of the equipment, minimize the impact on the power grid and equipment, and significantly improve the smoothness, safety and automation level of the islanding and grid-connection switching process of the distribution network.
[0010] Furthermore, the step of extracting features from the first voltage signal on the islanded side of the distribution network and the second voltage signal on the main grid side to obtain quantized feature values is as follows:
[0011] The first voltage signal on the islanded side of the distribution network and the second voltage signal on the main network side are obtained respectively;
[0012] The first voltage signal and the second voltage signal are respectively subjected to time-domain truncation and zero-point supplementation preprocessing to obtain the first processing result and the second processing result;
[0013] Fourier transforms are performed on the first processing result and the second processing result respectively to obtain the spectral distribution data of the island side and the main network side respectively. The spectral distribution data are then feature extracted and integrated to obtain quantized feature values, wherein the quantized feature values include voltage amplitude difference, frequency difference and phase difference data.
[0014] By acquiring voltage signals from both the island side and the main grid side in real time and extracting features, the continuous voltage signals on both sides can be discretized into quantized features, providing an accurate basis for inrush prediction.
[0015] Furthermore, the step of inputting the quantized feature values into the pre-trained inrush prediction model to output the predicted range of closing inrush current under different phase timings specifically involves:
[0016] The quantized feature values are combined into an input sequence according to different phase time sequences and input into the surge prediction model to obtain the probability distribution of the closing surge amplitude under each phase time sequence. The surge prediction model is obtained by training a long short-term memory network model with monitoring data in historical grid connection records and corresponding closing surge level labels.
[0017] The expected value and standard deviation of the closing inrush current amplitude are calculated based on the probability distribution, and the predicted range of the closing inrush current amplitude under different phase sequences is determined according to the expected value and the standard deviation.
[0018] By using the inrush prediction model, the inrush range under different phase timings can be predicted, thereby enabling proactive prediction and precise suppression of closing inrush, avoiding blind closing and huge impacts caused by the inability to predict in traditional methods.
[0019] Furthermore, based on the inrush current prediction range, the calculation of the width and peak amplitude of the prediction range corresponding to each phase timing to identify the target phase interval of the inrush current fluctuation specifically involves:
[0020] Calculate the width and peak amplitude of the inrush current prediction range corresponding to each phase timing, wherein the width value is the difference between the upper limit and the lower limit of the inrush current prediction range;
[0021] Based on the width value and peak amplitude, a surge characteristic mapping relationship is constructed to determine the overlap of the closing surge prediction range of adjacent phase timings, and adjacent timings with an overlap exceeding a preset threshold are merged into a timing group;
[0022] Calculate the volatility coefficient of each time series group and classify the stability level based on the volatility coefficient, wherein the volatility coefficient is the ratio of the standard deviation to the mean of the prediction range within the time series group;
[0023] The comprehensive risk assessment value is calculated based on the stability level and the preset safety margin, and the time series group with the smallest comprehensive risk assessment value is identified as the target phase interval. The safety margin is calculated by combining the rated upper limit of the equipment and the maximum predicted value within the time series group.
[0024] Calculating the width and peak amplitude of the prediction range helps assess the fluctuation of the inrush flow, identify the target phase interval (i.e., the interval with smaller inrush flow), and evaluate the stability contribution of each timing sequence. This ensures the selection of the most stable closing point, so that the final decision is no longer based on a single parameter, but on the optimal solution under multi-objective optimization, thereby significantly improving the smoothness and reliability of grid connection switching.
[0025] Furthermore, the step of evaluating the stability contribution of each phase timing within the target phase interval to determine the target closing timing specifically involves:
[0026] Within the target phase interval of the surge fluctuation, the difference between the predicted surge value of each phase time series and the average value of all time series within the interval is calculated, and the stability contribution weight is determined based on the difference value.
[0027] For each phase timing sequence, the stability contribution weight is multiplied by the width value to obtain the stability score of each timing sequence;
[0028] All phase timing sequences are sorted based on the stability score, and the timing sequence with the highest stability score is selected as the target closing timing sequence.
[0029] This approach first uses the difference value to determine the stability weight, accurately selecting time series with small inrush current fluctuations to reduce grid connection impact risks. Then, it combines the prediction range width value to calculate a score, balancing inrush current fluctuations and prediction uncertainties to avoid misselection based on a single dimension. Finally, it selects the time series with the highest score, ensuring that the inrush current amplitude is stable and controllable under that time series. Based on this, adjusting the inverter and phase difference compensation can minimize the impact of closing inrush current on the grid and equipment, ensuring a smooth voltage and current transition when islanded and connected to the main grid, effectively achieving a smooth switching.
[0030] Furthermore, the step of adjusting the inverter's output characteristic parameters according to the target closing timing to obtain the adjusted inverter output signal specifically involves:
[0031] The instantaneous values of the three-phase voltage and the three-phase current at the inverter output are collected, and the instantaneous values of the three-phase voltage and the three-phase current are converted into direct-axis components and quadrature-axis components in a rotating coordinate system, respectively.
[0032] Active power and reactive power are calculated based on the direct-axis component and the quadrature-axis component, respectively, and the current power factor is calculated based on the active power and the reactive power.
[0033] Calculate the time difference between the target closing time and the current time corresponding to the target closing sequence. If the time difference is less than a preset threshold, generate voltage amplitude adjustment and phase adjustment based on the difference between the current power factor and the target power factor.
[0034] The inverter's reference voltage vector is corrected according to the voltage amplitude adjustment and the phase adjustment, respectively. The corrected reference voltage vector is then decomposed using a space vector pulse width modulation algorithm to obtain the adjusted inverter output signal.
[0035] This process involves first converting voltage and current into components in a rotating coordinate system to accurately calculate active and reactive power and power factor, providing precise data for regulation. Then, the timing of regulation is determined by the time difference to avoid premature regulation that could lead to parameter deviations. The regulation amount is generated based on the power factor difference, enabling the inverter output to match the main grid demand and reducing power fluctuations. Finally, the output signal is corrected by vector correction and pulse width modulation to ensure a smooth transition of inverter output voltage and current, significantly reducing the impact of electrical parameters during grid connection and facilitating a smooth switch between distribution network islands and the main grid.
[0036] Furthermore, the current information in the inverter output signal is collected. When the current information meets a preset condition, iterative optimization is performed to adjust the phase difference compensation, and the phase difference correction result is obtained. Specifically:
[0037] The current signal in the inverter output signal is collected by a current transformer, and the current signal is processed by a sliding window to calculate the effective value and instantaneous peak value of the current in each window.
[0038] The peak factor is calculated based on the effective value of the current and the instantaneous peak value. When the peak factor exceeds a first preset threshold, the estimated value of the impact current is determined.
[0039] If the estimated inrush current reaches a preset proportion of the upper limit of the rated short-time withstand current of the equipment, an iterative optimization process is initiated. During the iterative optimization process, the deviation between the islanded voltage phase drift rate and the main grid phase is calculated in real time. If the deviation exceeds a second preset threshold, the compensation correction amount is increased proportionally until the estimated inrush current drops to within the safe range of the rated short-time withstand current of the equipment, and the phase difference correction result is determined.
[0040] This method uses current transformers to collect current in real time and analyze it through a sliding window, combined with peak factor to accurately identify the risk of inrush current. When the inrush current approaches the equipment's tolerance limit, the compensation amount is dynamically and iteratively adjusted according to the phase deviation to reduce the inrush current to a safe range, effectively avoiding current surges during grid connection, ensuring equipment safety, and facilitating a smooth switch between islanded and main grid systems.
[0041] Furthermore, the step of generating grid-connected control commands based on the phase difference correction results to control the smooth switching of islanded distribution network connections specifically includes:
[0042] Based on the correction results, the real-time phase difference between the islanded voltage and the main grid voltage is calculated, and the real-time phase difference is compared with a preset phase difference tolerance. When the real-time phase difference is less than or equal to the preset phase difference tolerance, a grid connection closing command is generated and sent to the grid connection circuit breaker to perform the closing operation, thereby realizing a smooth switching between islanded and grid-connected distribution networks.
[0043] By calculating the real-time phase difference between the islanded and main grid voltages based on the correction results, the phase matching status of the voltages on both sides can be accurately controlled. Comparing this with a preset phase difference tolerance allows for the selection of safe closing times with minimal phase difference. Sending a command to close the circuit breaker at this point significantly reduces inrush current, minimizes impact on grid-connected equipment, and avoids disturbances such as voltage fluctuations and current surges during grid connection. This ensures a smooth switching between the islanded and main grids from the critical phase matching stage, improving the stability and safety of the grid connection process.
[0044] Furthermore, after generating grid-connected control commands based on the phase difference correction results to control the smooth switching of islanded grid connection in the distribution network, the method further includes:
[0045] The actual waveform of the inrush current during closing is monitored in real time, and inrush current parameters are extracted from the actual waveform. A deviation feature vector is calculated based on the inrush current parameters and the predicted values. The inrush current parameters include inrush current peak value, duration, and attenuation characteristic parameters.
[0046] When the root mean square error of the deviation feature vector exceeds a preset threshold, the weight factor of the surge prediction model is adjusted using the backpropagation algorithm, and the model parameters are updated based on the learning rate decay strategy to obtain an optimized surge prediction model.
[0047] By monitoring the actual waveform of the inrush current in real time, calculating the deviation, and optimizing the model, the accuracy of subsequent inrush current prediction can be improved, thereby determining a better closing sequence, reducing the impact of inrush current on the power grid, avoiding equipment failure or power grid fluctuations caused by excessive inrush current during switching, and ensuring a smoother and more stable switching between distribution network islands and the main grid.
[0048] Another embodiment of the present invention provides a distribution network islanding and grid-connected smooth switching control system, including: an acquisition module, a prediction module and a control module;
[0049] The acquisition module is used to extract features from the first voltage signal on the island side of the distribution network and the second voltage signal on the main grid side, respectively, to obtain quantized feature values;
[0050] The prediction module is used to input the quantized feature values into the pre-trained inrush prediction model to output the inrush prediction range under different phase timings, and based on the inrush prediction range, calculate the width and peak amplitude of the prediction range corresponding to each phase timing to identify the target phase interval of the inrush fluctuation, and evaluate the stability contribution of each phase timing within the target phase interval to determine the target closing timing.
[0051] The control module is used to adjust the output characteristic parameters of the inverter according to the target closing sequence to obtain the adjusted inverter output signal, and to collect the current information in the inverter output signal. When the current information meets the preset conditions, iterative optimization is performed to adjust the phase difference compensation to obtain the phase difference correction result, and a grid connection control command is generated based on the phase difference correction result to control the smooth switching of the distribution network islanded grid connection. Attached Figure Description
[0052] To more clearly illustrate the technical solution of this application, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0053] Figure 1 This is a flowchart illustrating one embodiment of the distribution network islanding and grid-connected smooth switching control method provided in this application;
[0054] Figure 2 This is a flowchart illustrating one embodiment of steps S201 to S204 provided in this application;
[0055] Figure 3 This is a flowchart illustrating one embodiment of steps S301 to S304 provided in this application;
[0056] Figure 4 This is a flowchart illustrating one embodiment of steps S401 to S403 provided in this application;
[0057] Figure 5 This is a flowchart illustrating one embodiment of steps S501 to S502 provided in this application;
[0058] Figure 6 This is a schematic diagram of an embodiment of the distribution network islanding and grid-connected smooth switching control system provided in this application. Detailed Implementation
[0059] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below with reference to the accompanying drawings of the embodiments. 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.
[0060] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the application; the terms “comprising” and “having”, and any variations thereof, in the specification, claims, and foregoing description of the drawings are intended to cover non-exclusive inclusion.
[0061] In the description of the embodiments of this application, technical terms such as "first" and "second" are used only to distinguish different objects and should not be construed as indicating or implying relative importance or implicitly specifying the number, specific order, or primary and secondary relationship of the indicated technical features. In the description of the embodiments of this application, "multiple" means two or more, unless otherwise explicitly defined.
[0062] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0063] In the description of the embodiments in this application, the term "and / or" 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, and B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.
[0064] In the description of the embodiments of this application, the term "multiple" refers to two or more (including two), similarly, "multiple sets" refers to two or more (including two sets), and "multiple pieces" refers to two or more (including two pieces).
[0065] In the description of the embodiments of this application, unless otherwise expressly specified and limited, technical terms such as "installation," "connection," "joining," and "fixing" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. For those skilled in the art, the specific meaning of the above terms in the embodiments of this application can be understood according to the specific circumstances.
[0066] In modern distribution networks with widespread integration of distributed power sources such as photovoltaics and wind power, islanding is a common operating condition: during main grid failures, load adjustments, or maintenance, the distribution network containing distributed power sources will detach from the main grid to form an island, ensuring power supply to local critical loads; after the main grid recovers, it needs to be reconnected. However, after long-term independent operation between the island and the main grid, significant differences in voltage amplitude, frequency, and phase can easily occur on both sides. The inrush current generated by parameter mismatch during grid connection can, at best, damage the insulation of circuit breakers, transformers, and other equipment, and at worst, affect the reliability of power supply to surrounding areas. Therefore, achieving smooth switching between islanded and grid-connected systems is crucial to ensuring equipment safety and improving power supply reliability. Although existing control technologies revolve around "parameter adjustment" and "closing sequence selection," they are insufficient to meet the requirements for high-precision smooth grid connection.
[0067] See Figure 1 To achieve a smooth switching between distribution network islanding and main grid connection, an embodiment of the present invention provides a smooth switching control method for distribution network islanding and main grid connection, including steps S101 to S103.
[0068] Step S101: Extract features from the first voltage signal on the islanded side of the distribution network and the second voltage signal on the main network side to obtain quantized feature values.
[0069] In some embodiments, step S101 includes: acquiring a first voltage signal on the islanded side of the distribution network and a second voltage signal on the main grid side; performing time-domain truncation and zero-point supplementation preprocessing on the first voltage signal and the second voltage signal to obtain a first processing result and a second processing result; performing Fourier transform on the first processing result and the second processing result to obtain spectral distribution data on the islanded side and the main grid side, respectively; and extracting and integrating the spectral distribution data to obtain quantized feature values, wherein the quantized feature values include voltage amplitude difference, frequency difference, and phase difference data. Specifically, firstly, a high-speed data acquisition card with a sampling frequency of 12.8kHz is used to acquire the first voltage signal on the islanded side of the distribution network and the second voltage signal on the main grid side to ensure that a sufficient number of sampling points are acquired in each power frequency cycle, avoiding deviations in subsequent signal feature extraction due to insufficient sampling density. Secondly, based on the actual operating characteristics of the distribution network, the window length is set to 10 to 30 preset power frequency cycles to truncate the voltage signal in the time domain. Then, it is determined whether the amount of data in the current signal acquisition buffer meets the window length requirement (1024 points). If it does, the time domain truncation processing of the first voltage signal and the second voltage signal is triggered. If the number of truncated data points does not meet the preset threshold of the Fourier transform (such as 1024 points or 2048 points), zero values are added to the end of the signal sequence to make the number of data points meet the requirements. Then, window functions are applied to the supplemented first voltage signal and second voltage signal for weighted processing to suppress spectral leakage. Finally, the first processing result and the second processing result are obtained. Then, Fourier transforms are performed on the first and second processing results respectively to obtain island-side and main network-side spectrum distribution data in complex form. From the two types of spectrum distribution data, the fundamental frequency component is determined by searching for the maximum amplitude spectral line near 50Hz. Feature extraction is then performed to extract voltage amplitude difference, frequency difference, and phase difference data. The voltage amplitude difference, frequency difference, and corrected phase difference data are integrated. To further improve accuracy, when the voltage amplitude difference exceeds 0.05 per unit or the frequency difference exceeds 0.1Hz, a compensation table based on historical data statistics (input is the amplitude difference / frequency difference interval, output is the compensation angle) is queried to correct the phase difference, thus obtaining the quantized feature value.
[0070] It should be noted that the choice of window function directly affects the suppression effect of spectral leakage. Different window functions such as Hanning window, Hamming window or Blackman window can be used. The specific selection should be based on the harmonic content and frequency resolution requirements of the distribution network. This application does not impose any restrictions.
[0071] It should be noted that, for the voltage amplitude difference, the fundamental frequency amplitudes on the island side and the main grid side are normalized by dividing them by their respective rated voltage values, and the difference between the normalized fundamental frequency amplitudes on both sides is calculated; for the frequency difference, the frequency index difference corresponding to the peak values of the fundamental frequencies on both sides is first calculated, and then multiplied by the frequency resolution obtained by "sampling rate / number of Fourier transform points" to obtain the frequency difference data; for the phase difference, based on the initial phase value of the fundamental frequency component, the cumulative phase difference method (adding or subtracting an integer multiple of 2π for compensation when the phase difference between adjacent time windows exceeds π radians) is used to handle the periodic phase jumps. The specific feature extraction method is not the focus of this application, so it will not be elaborated here.
[0072] By acquiring voltage signals from both the island side and the main grid side in real time and extracting features, the continuous voltage signals on both sides can be discretized into quantized features, providing an accurate basis for inrush prediction.
[0073] Step S102: Input the quantized feature value into the pre-trained inrush prediction model to output the inrush prediction range under different phase timings. Based on the inrush prediction range, calculate the width and peak amplitude of the prediction range corresponding to each phase timing to identify the target phase interval of inrush fluctuation. Evaluate the stability contribution of each phase timing within the target phase interval to determine the target closing timing.
[0074] In some embodiments, the inrush current prediction model is a long short-term memory network model, and its training process is as follows: Historical grid-connected records (including complete electrical parameter records during islanded operation and grid-connected switching times) are extracted from the distribution network data acquisition and monitoring system. Monitoring data sequences of voltage amplitude difference, frequency difference, and phase difference during islanded operation and grid-connected switching times, along with corresponding measured inrush current waveforms, are obtained. Then, the inrush current waveform is segmented using a sliding time window (window width 100 milliseconds, step size 20 milliseconds). The peak inrush current within each window is identified, and the ratio of peak current to rated current is used as the basis for prediction. The flow rate was divided into four levels. Then, a training sample set was constructed, with each sample containing monitoring data sequences from 10 consecutive time steps as input features. The corresponding flow rate level labels were encoded using one-hot encoding. Subsequently, the network was trained using mini-batch gradient descent with a batch size of 32 and a cross-entropy loss function. The initial learning rate was 0.001 with exponential decay (decay rate 0.9). During training, 20% of the data was reserved as a validation set. An early stopping mechanism was triggered when the validation set loss no longer decreased after 5 consecutive training epochs to prevent overfitting. Finally, the trained flow prediction model was obtained.
[0075] In some embodiments, the step of inputting the quantized feature values into a pre-trained inrush current prediction model to output the predicted range of closing inrush current under different phase sequences specifically involves: combining the quantized feature values into an input sequence according to different phase sequences, inputting it into the inrush current prediction model, and obtaining the probability distribution of the closing inrush current amplitude under each phase sequence. The inrush current prediction model is obtained by training a long short-term memory network model with monitoring data from historical grid connection records and corresponding closing inrush current level labels. Based on the probability distribution, the expected value and standard deviation of the closing inrush current amplitude are calculated, and the predicted range of the closing inrush current amplitude under different phase sequences is determined according to the expected value and the standard deviation. Specifically, the following steps are taken: First, the quantized feature values are combined into an input sequence according to different phase time sequences, and this input sequence is fed into a pre-trained surge prediction model. The model output layer converts the original output into a probability distribution of the closing surge amplitude under each phase time sequence through a softmax activation function, so as to reflect the possibility of the surge falling into different level ranges under a specific phase time sequence. Then, based on the probability distribution, the expected value of the closing surge amplitude is calculated by combining the center value of each surge level with the corresponding probability using a weighted average method. At the same time, the standard deviation, which represents the prediction uncertainty, is calculated. The closing surge amplitude prediction range under different phase time sequences is determined according to the expected value and the standard deviation. For example, the expected value plus or minus twice the standard deviation is used as the boundary of the prediction range. If the standard deviation exceeds a preset threshold, the phase time sequence sampling interval can be reduced by interpolation and then re-predicted to optimize the range accuracy.
[0076] It should be noted that the phase timing is represented in electrical angles, covering a complete cycle from 0 to 360 degrees, and each phase timing corresponds to a set of feature vectors containing voltage amplitude difference, frequency difference, and phase difference.
[0077] By using the inrush prediction model, the inrush range under different phase timings can be predicted, thereby enabling proactive prediction and precise suppression of closing inrush, avoiding blind closing and huge impacts caused by the inability to predict in traditional methods.
[0078] Please refer to Figure 2 In some embodiments, the step of calculating the width and peak amplitude of the prediction range corresponding to each phase timing based on the inrush current prediction range to identify the target phase interval of the inrush current fluctuation includes steps S201 to S204:
[0079] Step S201: Calculate the width value and peak amplitude of the inrush current prediction range corresponding to each phase timing, wherein the width value is the difference between the upper limit and the lower limit of the inrush current prediction range.
[0080] In some embodiments, the prediction ranges of inrush currents at different phase timings are stored in the form of structured data, and each phase timing corresponds to a prediction interval of "upper limit value - lower limit value". Then, for each prediction interval, calculate its width value, i.e., the difference between the upper limit value and the lower limit value; at the same time, considering the conservative principle of equipment protection, extract the upper limit value of each prediction interval as the peak amplitude of the inrush current at this phase timing, so as to quantify the maximum potential impact of the inrush current on the equipment.
[0081] Step S202: Based on the width value and the peak amplitude, construct an inrush current feature mapping relationship to determine the overlap degree of the prediction ranges of the inrush currents at adjacent phase timings, and merge the adjacent timings with the overlap degree exceeding the preset threshold into a timing group;
[0082] In some embodiments, with each phase timing, take the width value as the abscissa and the peak amplitude as the ordinate to construct a scatter plot distribution diagram, forming an intuitive inrush current feature mapping relationship (where the density of the scatter points can reflect the distribution law of the inrush current characteristics in different phase intervals). Then, based on the inrush current feature mapping relationship, use the interval intersection judgment method to calculate the overlap degree of the prediction ranges of adjacent phase timings. Among them, when there is an intersection between the upper limit value and the lower limit value of adjacent phase timings, it is determined as an overlap. At this time, calculate the ratio of the length of the overlapping interval to the length of the original interval as the overlap degree. If the overlap degree exceeds the preset threshold (such as 0.3), it is considered that the inrush current characteristics of the two phase timings are similar, and then the two adjacent timings are merged into a timing group, and the original prediction data of all timings within the group are retained to simplify subsequent analysis. This grouping reduces the dimension of the decision space and improves the efficiency of subsequent risk assessment.
[0083] Exemplarily, assume that the prediction ranges of adjacent timings are [L1, U1] and [L2, U2] respectively. When max(L1, L2) < min(U1, U2) is satisfied, it is determined that there is an overlap, and the overlap degree is the ratio of "the length of the overlapping interval (min(U1, U2) - max(L1, L2))" to "the smaller value of the lengths of the two intervals (min(U1 - L1, U2 - L2))". If the overlap degree exceeds the preset threshold (such as 0.3).
[0084] Step S203: Calculate the fluctuation coefficient of each timing group, and divide the stability level based on the fluctuation coefficient, where the fluctuation coefficient is the ratio of the standard deviation to the mean of the prediction ranges within the timing group;
[0085] In some embodiments, for each merged time series group, the mean and standard deviation of the midpoint values of all phase time series prediction ranges within the group are first calculated. Then, the volatility coefficient is calculated by "standard deviation ÷ mean". Stability levels are then classified based on the quantiles of the volatility coefficients for all time series groups. For example, after sorting the volatility coefficients from smallest to largest, the top 25% are classified as Level 1 stable (minimum volatility), 25%-50% as Level 2 stable, 50%-75% as Level 3 stable, and over 75% as Level 4 stable (maximum volatility), providing a quantitative basis for stability in subsequent risk assessments.
[0086] It should be noted that the fluctuation coefficient reflects the consistency of inrush prediction within the time series group. The smaller the fluctuation coefficient, the stronger the consistency of inrush prediction among the time series within the group, and the lower the uncertainty at grid connection.
[0087] Step S204: Calculate the comprehensive risk assessment value based on the stability level and the preset safety margin, and identify the time series group with the smallest comprehensive risk assessment value as the target phase interval. The safety margin is calculated by combining the rated withstand limit of the equipment and the maximum predicted value within the time series group.
[0088] In some embodiments, firstly, the safety margin of each timing group is calculated by combining the rated withstand limit of the equipment with the maximum predicted value within the timing group. Then, the stability level is converted into a numerical value and added to the safety margin according to a preset ratio to obtain a comprehensive risk assessment value. The formula for calculating the comprehensive risk assessment value is: V = αS + βM, where V is the comprehensive risk assessment value, S is the numerical value corresponding to the stability level (Level 1 = 1, Level 2 = 2, Level 3 = 3, Level 4 = 4), M is the per-unit value of the safety margin, and α and β are preset weighting coefficients (typically α = 0.6 and β = 0.4, emphasizing stability and equipment safety respectively). Next, the comprehensive risk assessment values of all timing groups are sorted in ascending order, and the timing group with the smallest assessment value is selected. From this group, the single-phase timing with the narrowest prediction range and the lowest peak value is selected as the target phase interval for inrush fluctuations. This target phase interval possesses both high stability and high safety margin, laying the foundation for the subsequent selection of target closing timings.
[0089] It should be noted that the safety margin calculation takes into account the rated withstand capacity of the equipment, specifically the rated short-circuit current withstand value of the equipment minus the maximum value of all predicted upper limits in the timing group. The larger the safety margin, the lower the risk of equipment overload.
[0090] It should be noted that when selecting the target phase interval from the time series group, the prediction range width of each time series needs to be compared first, and the time series with the narrowest width is selected. If there are multiple time series with the same width, their peak amplitudes are further compared, and the time series with the lowest peak amplitude is selected.
[0091] Calculating the width and peak amplitude of the prediction range helps assess the fluctuation of the inrush flow, identify the target phase interval (i.e., the interval with smaller inrush flow), and evaluate the stability contribution of each timing sequence. This ensures the selection of the most stable closing point, so that the final decision is no longer based on a single parameter, but on the optimal solution under multi-objective optimization, thereby significantly improving the smoothness and reliability of grid connection switching.
[0092] In some embodiments, the step of evaluating the stability contribution of each phase timing sequence within the target phase interval to determine the target closing timing sequence specifically involves: within the target phase interval where the inrush current fluctuates, calculating the difference between the inrush current prediction value of each phase timing sequence and the average value of all timing sequences within the interval, and determining the stability contribution weight based on the difference value; for each phase timing sequence, multiplying the stability contribution weight by the width value to obtain a stability score for each timing sequence; sorting all phase timing sequences based on the stability score, and selecting the timing sequence with the highest stability score as the target closing timing sequence. Specifically, firstly, the arithmetic mean of the inrush current prediction values of all phase timing sequences within the interval is calculated to determine the baseline reference level; then, using the Euclidean distance quantization method, the difference between the inrush current prediction value of each phase timing sequence and the central reference value is calculated, and the difference values of all timing sequences need to be reciprocally normalized to finally obtain the stability contribution weight of each phase timing sequence, which directly reflects the degree of contribution of the timing sequence to the overall stability of the interval. Subsequently, for each phase time series, its stability contribution weight is multiplied by the corresponding prediction range width value to obtain a stability score. Through this calculation, the two key characteristics of the time series are transformed into directly comparable quantitative scores, providing a clear basis for subsequent selection of target time series. Finally, after obtaining the stability scores of all phase timing sequences, they are first sorted in descending order of score to prioritize the timing sequence with the best overall stability and controllability. If multiple timing sequences have the same stability score after sorting (i.e., it is impossible to distinguish their quality directly through the score), a secondary screening criterion is introduced: first, the prediction range width values of these timing sequences are compared, and the timing sequence with the smaller width value is selected (to further ensure that the inrush current fluctuation is controllable); if the width values are still the same, the peak amplitude of the inrush current prediction range of each timing sequence is compared (i.e., the upper limit of the prediction range; the lower the peak value, the smaller the impact on the distribution network equipment), and the timing sequence with the lowest peak amplitude is selected. Through the method of "primary score sorting + secondary criterion screening", a unique phase timing sequence that combines high stability, low uncertainty, and low equipment impact risk is finally determined as the target closing timing sequence, providing a precise timing basis for subsequent inverter regulation and grid connection control.
[0093] It should be noted that the smaller the difference value, the closer the inrush characteristics of the time series are to the average level within the interval, and the stronger the stability and representativeness of the inrush state during grid connection.
[0094] It should be noted that if a time series has a high stability contribution weight (indicating that its inrush characteristics are more stable) and a small width value (indicating that inrush fluctuations are controllable), the product result (i.e., stability score) will be higher, meaning that the time series has better overall performance in terms of "stability" and "controllability". Conversely, if the weight is low or the width value is large, the score will be lower, indicating that its stability risk or uncertainty during grid connection is higher.
[0095] This approach first uses the difference value to determine the stability weight, accurately selecting time series with small inrush current fluctuations to reduce grid connection impact risks. Then, it combines the prediction range width value to calculate a score, balancing inrush current fluctuations and prediction uncertainties to avoid misselection based on a single dimension. Finally, it selects the time series with the highest score, ensuring that the inrush current amplitude is stable and controllable under that time series. Based on this, adjusting the inverter and phase difference compensation can minimize the impact of closing inrush current on the grid and equipment, ensuring a smooth voltage and current transition when islanded and connected to the main grid, effectively achieving a smooth switching.
[0096] Step S103: Adjust the output characteristic parameters of the inverter according to the target closing timing to obtain the adjusted inverter output signal, and collect the current information in the inverter output signal. When the current information meets the preset conditions, perform iterative optimization to adjust the phase difference compensation, obtain the phase difference correction result, and generate a grid connection control command based on the phase difference correction result to control the smooth switching of the distribution network islanded grid connection.
[0097] Please refer to Figure 3 In some embodiments, adjusting the inverter's output characteristic parameters according to the target closing timing to obtain the adjusted inverter output signal includes steps S301 to S304:
[0098] Step S301: Collect the instantaneous values of the three-phase voltage and the three-phase current at the inverter output terminal, and convert the instantaneous values of the three-phase voltage and the three-phase current into direct-axis components and quadrature-axis components in a rotating coordinate system, respectively.
[0099] In some embodiments, voltage transformers and current transformers installed on the three-phase busbars at the inverter output are used to collect the instantaneous values of the three-phase voltage and the three-phase current, respectively. Then, Parker transformation is used to convert the AC quantities in the three-phase stationary coordinate system into direct-axis components (Ud, Id) and quadrature-axis components (Uq, Iq) in the rotating coordinate system, thereby realizing the conversion of AC signals to DC signals and providing convenience for subsequent power calculation and steady-state processing of the controller.
[0100] It should be noted that the voltage transformer and the current transformer are installed on the three-phase bus at the output of the inverter. The voltage transformer adopts an electromagnetic structure with a transformation ratio of 10kV / 100V and an accuracy class of 0.2. The current transformer adopts a through-type structure with a transformation ratio of 1000A / 5A and an accuracy class of 0.5S.
[0101] It should be noted that the mathematical essence of the Parker transformation is to convert the abc coordinate system of a three-phase symmetrical system into the dq0 coordinate system, where the d-axis coincides with the direction of the rotor magnetic field, and the q-axis leads the d-axis by 90 electrical degrees. Through this transformation, the three-phase AC voltage and current are decomposed into direct-axis and quadrature-axis components. Active power P equals the product of direct-axis voltage Ud and direct-axis current Id plus the product of quadrature-axis voltage Uq and quadrature-axis current Iq. Reactive power Q equals the product of quadrature-axis voltage Uq and direct-axis current Id minus the product of direct-axis voltage Ud and quadrature-axis current Iq. Apparent power S is obtained by taking the square root of the sum of the squares of active and reactive power. The power factor is the ratio of active power to apparent power, reflecting the utilization efficiency of the inverter's output power.
[0102] Step S302: Calculate the active power and reactive power based on the direct-axis component and the quadrature-axis component respectively, and calculate the current power factor based on the active power and the reactive power.
[0103] In some embodiments, based on the direct-axis and quadrature-axis components obtained by the Parker transform, the active power (P=Ud×Id + Uq×Iq) and reactive power (Q=Uq×Id - Ud×Iq) are calculated according to the formula; then, the current power factor is obtained by the ratio of active power to apparent power. The current power factor directly reflects the utilization efficiency of the inverter's output power, is a key indicator for evaluating whether the output characteristics meet the grid connection requirements, and is also a core reference quantity for subsequent adjustment of output characteristic parameters.
[0104] Step S303: Calculate the time difference between the target closing time and the current time corresponding to the target closing sequence. If the time difference is less than a preset threshold, generate voltage amplitude adjustment and phase adjustment based on the difference between the current power factor and the target power factor.
[0105] In some embodiments, the time difference between the target closing time and the current time corresponding to the target closing timing is first calculated. When the time difference is less than a preset threshold (e.g., 200 milliseconds), it indicates that a fast response is required to ensure the closing timing. At this time, based on the difference between the current power factor and the target power factor, a proportional-integral-derivative (PID) controller is started. The DID controller contains a proportional term, an integral term, and a derivative term. The proportional term (Kp) generates an instantaneous response based on the deviation, the integral term (Ki) accumulates the deviation to eliminate steady-state error, and the derivative term (Kd) predicts the deviation change to suppress overshoot. The three work together to output voltage amplitude adjustment and phase adjustment to achieve directional adjustment of the inverter output characteristics.
[0106] Step S304: Correct the inverter's reference voltage vector according to the voltage amplitude adjustment and the phase adjustment, respectively, and decompose the corrected reference voltage vector using a space vector pulse width modulation algorithm to obtain the adjusted inverter output signal.
[0107] In some embodiments, firstly, the reference voltage vector of the inverter is corrected using voltage amplitude adjustment and phase adjustment; then, the corrected reference voltage vector is decomposed into the action time of adjacent basic vectors (including 6 non-zero vectors and 2 zero vectors) using a space vector pulse width modulation algorithm, and six switching drive signals are generated according to a preset switching sequence (such as seven-segment or five-segment) to control the on / off state of the inverter power devices, and finally the adjusted inverter output signal is obtained, so that the output characteristics match the target closing timing and provide stable electrical conditions for smooth grid connection switching.
[0108] It should be noted that space vector pulse width modulation (SVM) combines the three-phase reference voltages into a single rotating voltage vector, approximating the reference vector through a combination of eight basic voltage vectors. These basic vectors include six non-zero vectors and two zero vectors. Two adjacent non-zero vectors are selected based on the sector containing the reference vector. The duration of each vector is calculated, and a PWM signal is output according to a seven-segment or five-segment switching sequence to drive the six power switching devices of the inverter, achieving precise control of the output voltage amplitude and phase.
[0109] This process involves first converting voltage and current into components in a rotating coordinate system to accurately calculate active and reactive power and power factor, providing precise data for regulation. Then, the timing of regulation is determined by the time difference to avoid premature regulation that could lead to parameter deviations. The regulation amount is generated based on the power factor difference, enabling the inverter output to match the main grid demand and reducing power fluctuations. Finally, the output signal is corrected by vector correction and pulse width modulation to ensure a smooth transition of inverter output voltage and current, significantly reducing the impact of electrical parameters during grid connection and facilitating a smooth switch between distribution network islands and the main grid.
[0110] Please refer to Figure 4In some embodiments, the step of collecting current information from the inverter output signal, and when the current information meets preset conditions, performing iterative optimization to adjust the phase difference compensation to obtain the phase difference correction result, includes steps S401 to S403:
[0111] Step S401: Acquire the current signal in the inverter output signal through the current transformer, and perform sliding window processing on the current signal to calculate the effective value and instantaneous peak value of the current in each window;
[0112] In some embodiments, a current transformer is installed on the connection line between the inverter output and the grid-connected circuit breaker, and a current signal is captured at a sampling frequency of 10kHz or higher. The current signal is then processed by a sliding window, wherein the window width is set to one power frequency cycle and the moving step size is half a cycle. Through this continuous monitoring method, the effective value of the current (reflecting the average current magnitude) and the instantaneous peak value (reflecting the extreme value of current fluctuation) within each window are calculated, providing basic data for the subsequent identification of inrush current.
[0113] Step S402: Calculate the peak factor based on the effective value of the current and the instantaneous peak value. When the peak factor exceeds a first preset threshold, determine the estimated value of the impact current.
[0114] In some embodiments, when the effective value of the current and the instantaneous peak value are obtained, a peak factor is calculated based on the effective value of the current and the instantaneous peak value to determine whether there is an inrush current. When the peak factor is detected to exceed a first preset threshold (e.g., 2.5), it is determined that there is an inrush current component, and the maximum peak value within three consecutive windows is taken as the estimated value of the inrush current. This estimated value intuitively reflects the intensity of the current inrush.
[0115] Step S403: If the estimated value of the inrush current reaches a preset proportion of the upper limit of the rated short-time withstand current of the equipment, the iterative optimization process is started. During the iterative optimization process, the deviation between the phase drift rate of the islanded voltage and the phase of the main grid is calculated in real time. If the deviation exceeds the second preset threshold, the compensation correction amount is increased proportionally until the estimated value of the inrush current drops to the safe range of the rated short-time withstand current of the equipment, and the phase difference correction result is determined.
[0116] In some embodiments, when the estimated inrush current reaches a preset proportion (e.g., 80%) of the upper limit of the rated short-time withstand current of the equipment, an iterative optimization process is initiated. During this process, the predicted range of the inrush current under different time sequences is read to establish the correspondence between the phase difference adjustment and the inrush current amplitude. Then, the gradient descent method is used to calculate the phase difference compensation value that minimizes the inrush current. At the same time, the deviation between the islanded voltage phase drift rate (obtained through the phase change of adjacent cycles) and the main grid phase is calculated in real time. If the deviation exceeds a second preset threshold, the compensation correction amount is increased proportionally to the deviation value. The iteration continues until the estimated inrush current drops to a safe range (e.g., below 60% of the rated short-time withstand current of the equipment) or the maximum number of iterations is reached. The final determined phase difference compensation value is the phase difference correction result, ensuring that the current impact during grid connection is within the equipment's withstand range.
[0117] In some embodiments, during the iterative optimization process, the gradient descent method is used to find the phase difference compensation amount that minimizes the closing inrush current. First, based on the obtained closing inrush current prediction range data under different phase timings, the relationship between the inrush current amplitude f and the phase difference adjustment amount Δφ is fitted as a quadratic function. In the formula, f represents the inrush amplitude, Δφ represents the phase difference adjustment, and a, b, and c are the coefficient parameters of a quadratic function obtained by fitting inrush prediction data under different phase time series. This function is the optimization objective function. The specific update formula of the gradient descent method is as follows: In the formula, This indicates the phase difference compensation value for the next iteration. This represents the current phase difference, α represents the learning rate (initial value is 0.1 radians), and the sign function represents the sign of the gradient. The gradient estimate is calculated using numerical differentiation, and the formula is as follows: ,in Let I represent the gradient estimate at the k-th iteration, and let I represent the surge amplitude function. The current phase difference value is represented by h, which represents the small step size in the neighborhood. The gradient is obtained by calculating the rate of change of the inrush current amplitude between two points in the phase difference neighborhood. During the iteration process, the estimated inrush current value is monitored in real time. When it drops below 60% of the rated short-time withstand current of the equipment or reaches the maximum number of iterations, the iteration stops, and the value at this time is recorded. This is determined to be the final phase difference correction result.
[0118] It should be noted that the convergence mechanism of iterative control is based on a dual criterion. The first criterion is that the estimated inrush current falls below a safe range, defined as below 60% of the equipment's rated short-time withstand current. The second criterion is an iteration limit to prevent infinite loops. When convergence is not achieved after exceeding a preset upper limit, the system selects the phase difference compensation value with the smallest inrush current during the current iteration as the suboptimal solution. The increase in the compensation correction adopts a proportional control principle; the correction is equal to the deviation value multiplied by a proportional coefficient, which is pre-calibrated based on the system response characteristics. This iterative mechanism ensures the stability and reliability of the control process.
[0119] This method uses current transformers to collect current in real time and analyze it through a sliding window, combined with peak factor to accurately identify the risk of inrush current. When the inrush current approaches the equipment's tolerance limit, the compensation amount is dynamically and iteratively adjusted according to the phase deviation to reduce the inrush current to a safe range, effectively avoiding current surges during grid connection, ensuring equipment safety, and facilitating a smooth switch between islanded and main grid systems.
[0120] In some embodiments, generating grid-connected control commands based on the phase difference correction results to control the smooth switching of distribution network islanding to grid connection specifically involves: calculating the real-time phase difference between the islanded voltage and the main grid voltage based on the correction results, comparing the real-time phase difference with a preset phase difference tolerance, and generating a grid-connected closing command when the real-time phase difference is less than or equal to the preset phase difference tolerance. This command is then sent to the grid-connected circuit breaker to execute the closing operation, thereby achieving smooth switching of distribution network islanding to grid connection. Specifically, firstly, based on the phase difference correction results obtained through iterative optimization, and combined with the real-time acquired first voltage signal on the islanded side and second voltage signal on the main grid side, the real-time phase difference between the two is calculated using a Fourier transform algorithm. Secondly, the calculated real-time phase difference is compared with a preset phase difference tolerance. If the real-time phase difference is greater than the preset tolerance, the phase difference compensation amount is adjusted through the inverter until the condition is met; if the real-time phase difference is less than or equal to the preset tolerance, it indicates that the current phase state meets the requirements for smooth grid connection. At this time, the system generates a grid-connected closing command that includes the precise closing time (determined based on the target closing timing), the final phase compensation amount (from the correction result), and voltage regulation parameters. After receiving the grid-connected closing command, the circuit breaker performs the closing operation at the specified time, completing the smooth switching between the distribution network island and the main network. The entire process ensures that the inrush current is within the safe range of the equipment through millisecond-level timing control and degree-level phase control, achieving impact-free grid connection.
[0121] It should be noted that the process of calculating the real-time phase difference between the two using the Fourier transform algorithm simultaneously takes into account the cumulative deviation between the islanded voltage phase drift rate and the main grid phase. The drift rate is obtained by continuously measuring the phase change of adjacent cycles, reflecting the frequency deviation between the islanded system and the main grid.
[0122] It should be noted that the preset phase difference tolerance is set based on the equipment's safety margin, and usually corresponds to a phase difference range where the inrush current amplitude is less than twice the rated current.
[0123] It should be noted that the grid connection closing command uses a standardized data frame format (including timestamp, checksum, and other fields) and is transmitted to the control unit of the grid-connected circuit breaker via fiber optic communication.
[0124] By calculating the real-time phase difference between the islanded and main grid voltages based on the correction results, the phase matching status of the voltages on both sides can be accurately controlled. Comparing this with a preset phase difference tolerance allows for the selection of safe closing times with minimal phase difference. Sending a command to close the circuit breaker at this point significantly reduces inrush current, minimizes impact on grid-connected equipment, and avoids disturbances such as voltage fluctuations and current surges during grid connection. This ensures a smooth switching between the islanded and main grids from the critical phase matching stage, improving the stability and safety of the grid connection process.
[0125] Please refer to Figure 5 In some embodiments, after generating grid-connected control commands based on the phase difference correction results to control the smooth switching of islanded distribution network connections, steps S501 to S502 are further included:
[0126] Step S501: Monitor the actual waveform of the closing inrush current in real time, extract the inrush current parameters from the actual waveform, and calculate the deviation feature vector based on the inrush current parameters and the predicted value. The inrush current parameters include the peak value, duration and attenuation characteristic parameters of the inrush current.
[0127] In some embodiments, after generating grid-connected control commands based on phase difference correction results and completing the islanded grid-connected switching of the distribution network, a high-speed data acquisition device with a 10kHz sampling rate monitors the actual waveform of the inrush current in real time, continuously monitoring for a duration covering 5 power frequency cycles to fully capture the initial impact and attenuation process of the inrush current. Then, three core inrush current parameters are extracted from the actual waveform: peak inrush current (the maximum value in the waveform), duration (the time interval from when the inrush current amplitude exceeds 1.1 times the rated current to when it falls back below that threshold), and attenuation characteristic parameters (the attenuation time constant of the inrush current envelope). These actual parameters are then compared point-by-point with the corresponding predicted values output by the inrush current prediction model to calculate a deviation feature vector. Simultaneously, the overall root mean square error and the maximum deviation value are calculated to quantify the prediction accuracy.
[0128] It should be noted that the deviation feature vector includes peak deviation (the ratio of the difference between the actual peak value and the predicted peak value to the predicted peak value), time deviation (the difference between the actual peak value time and the predicted peak value time), and decay rate deviation (the difference between the actual and predicted decay time constants).
[0129] Step S502: When the root mean square error of the deviation feature vector exceeds a preset threshold, the weight factor of the surge prediction model is adjusted by backpropagation algorithm, and the model parameters are updated based on the learning rate decay strategy to obtain an optimized surge prediction model.
[0130] In some embodiments, when the root mean square error of the deviation feature vector exceeds a preset threshold, the optimization mechanism of the surge prediction model is activated to update the deviation correction value. Simultaneously, the current deviation correction value is fused with historical deviation data according to time weights (recent data has higher weights, decreasing exponentially over time), updating the model's weight matrix and bias vector. The model is then stored after being labeled with a version number (timestamp + sequence number), ultimately resulting in an optimized surge prediction model to improve the prediction accuracy of subsequent grid connection processes.
[0131] It should be noted that the backpropagation algorithm is used, with mean squared error as the loss function. The partial derivatives of the loss function with respect to the weight parameters of each layer of the model are calculated using the chain rule to determine the direction of weight updates. The weight adjustment is the product of the negative gradient and the current learning rate. The learning rate adopts an exponential decay strategy, dynamically decreasing according to the formula "current learning rate = initial learning rate × decay rate ^ number of iterations" (the initial learning rate is set to 0.01, and the decay rate is 0.95), balancing rapid convergence in the early stages of training with fine-tuning in the later stages.
[0132] By monitoring the actual waveform of the inrush current in real time, calculating the deviation, and optimizing the model, the accuracy of subsequent inrush current prediction can be improved, thereby determining a better closing sequence, reducing the impact of inrush current on the power grid, avoiding equipment failure or power grid fluctuations caused by excessive inrush current during switching, and ensuring a smoother and more stable switching between distribution network islands and the main grid.
[0133] This application embodiment acquires voltage signals from both the islanded side and the main grid side in real time and extracts features, discretizing the continuous voltage signals on both sides into quantifiable features, providing a precise basis for inrush current prediction. Through the inrush current prediction model, the inrush current range under different phase sequences can be predicted, thereby achieving proactive anticipation and precise suppression of closing inrush current, avoiding blind closing and huge impacts caused by the inability to predict in traditional methods. Calculating the width and peak amplitude of the prediction range helps assess the fluctuation degree of inrush current, identify the target phase interval (i.e., the interval with smaller inrush current), and evaluate the stability contribution of each sequence, ensuring the selection of the most stable closing point. This makes the final decision no longer based on a single parameter, but on the optimal solution under multi-objective optimization, thus significantly improving the smoothness and reliability of grid connection switching. By adjusting inverter parameters and collecting output current information for feedback, phase difference can be compensated in real time, and iterative optimization can handle system uncertainties (such as load changes and noise), improving control accuracy and enhancing the adaptability and robustness of the control system under different operating conditions, ensuring the stability of the smooth switching effect. Compared with existing technologies, the present invention can more effectively and reliably limit the inrush current to the safe range of the equipment, minimize the impact on the power grid and equipment, and significantly improve the smoothness, safety and automation level of the islanding and grid-connection switching process of the distribution network.
[0134] like Figure 6 As shown, based on the above method embodiments, corresponding apparatus embodiments are provided;
[0135] One embodiment of the present invention provides a distribution network islanding and grid-connected smooth switching control system, including: an acquisition module 100, a prediction module 200 and a control module 300;
[0136] The acquisition module 100 is used to extract features from the first voltage signal on the island side of the distribution network and the second voltage signal on the main network side, respectively, to obtain quantized feature values.
[0137] The prediction module 200 is used to input the quantized feature values into the pre-trained inrush prediction model to output the closing inrush prediction range under different phase timings, and based on the closing inrush prediction range, calculate the width value and peak amplitude of the prediction range corresponding to each phase timing to identify the target phase interval of inrush fluctuation, and evaluate the stability contribution of each phase timing within the target phase interval to determine the target closing timing.
[0138] The control module 300 is used to adjust the output characteristic parameters of the inverter according to the target closing sequence to obtain the adjusted inverter output signal, and to collect the current information in the inverter output signal. When the current information meets the preset conditions, iterative optimization is performed to adjust the phase difference compensation to obtain the phase difference correction result, and a grid connection control command is generated based on the phase difference correction result to control the smooth switching of the distribution network islanded grid connection.
[0139] It is understood that the above-described device embodiments correspond to the method embodiments of the present invention, and can implement the distribution network islanding and grid-connected smooth switching control method provided by any of the above-described method embodiments of the present invention.
[0140] It should be noted that the device embodiments described above are merely illustrative, and some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the device embodiments provided by this invention, the connection relationships between modules indicate that they have communication connections, which can specifically be implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.
[0141] Based on the above embodiments of the distribution network islanding and grid-connected smooth switching control method, another embodiment of the present invention provides a terminal device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements the distribution network islanding and grid-connected smooth switching control method of any embodiment of the present invention.
[0142] For example, in this embodiment, the computer program can be divided into one or more modules, which are stored in the memory and executed by the processor to complete the present invention. The one or more modules may be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program in the terminal device.
[0143] The terminal device may be a desktop computer, laptop, handheld computer, or cloud server, etc. The terminal device may include, but is not limited to, a processor and a memory.
[0144] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the terminal device, connecting all parts of the terminal device via various interfaces and lines.
[0145] Based on the above-described method embodiments, another embodiment of the present invention provides a computer-readable storage medium including a stored computer program, wherein, when the computer program is executed, it controls the device where the computer-readable storage medium is located to execute the distribution network islanding and grid-connected smooth switching control method described in any of the above-described method embodiments of the present invention.
[0146] The modules / units integrated in the device / terminal equipment, if implemented as software functional units and sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the above embodiments of the present invention can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium, etc.
[0147] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications are also considered to be within the scope of protection of the present invention.
Claims
1. A method for smooth switching control between islanded and grid-connected distribution networks, characterized in that, include: Feature extraction was performed on the first voltage signal from the islanded side of the distribution network and the second voltage signal from the main grid side to obtain quantized feature values; The quantized feature values are input into a pre-trained inrush current prediction model to output the predicted range of closing inrush current under different phase sequences. Based on the predicted range of closing inrush current, the width and peak amplitude of the predicted range corresponding to each phase sequence are calculated to identify the target phase interval of inrush current fluctuation. The stability contribution of each phase sequence is evaluated within the target phase interval to determine the target closing sequence. Specifically, the step of inputting the quantized feature values into the pre-trained inrush current prediction model to output the predicted range of closing inrush current under different phase sequences involves: combining the quantized feature values into an input sequence according to different phase sequences and inputting it into the inrush current prediction model to obtain the probability distribution of the closing inrush current amplitude under each phase sequence. The inrush current prediction model is obtained by training a long short-term memory network model with monitoring data from historical grid connection records and corresponding closing inrush current level labels. Based on the probability distribution, the expected value and standard deviation of the closing inrush current amplitude are calculated, and the predicted range of the closing inrush current amplitude under different phase sequences is determined according to the expected value and the standard deviation. The inverter's output characteristic parameters are adjusted according to the target closing timing to obtain the adjusted inverter output signal. Current information in the inverter output signal is collected. When the current information meets the preset conditions, iterative optimization is performed to adjust the phase difference compensation to obtain the phase difference correction result. Based on the phase difference correction result, a grid connection control command is generated to control the smooth switching of islanded grid connection in the distribution network.
2. The distribution network islanding and grid-connected smooth switching control method according to claim 1, characterized in that, The process involves extracting features from the first voltage signal on the islanded side of the distribution network and the second voltage signal on the main grid side to obtain quantized feature values, specifically as follows: The first voltage signal on the islanded side of the distribution network and the second voltage signal on the main network side are obtained respectively; The first voltage signal and the second voltage signal are respectively subjected to time-domain truncation and zero-point supplementation preprocessing to obtain the first processing result and the second processing result; Fourier transforms are performed on the first processing result and the second processing result respectively to obtain the spectral distribution data of the island side and the main network side respectively. The spectral distribution data are then feature extracted and integrated to obtain quantized feature values, wherein the quantized feature values include voltage amplitude difference, frequency difference and phase difference data.
3. The distribution network islanding and grid-connected smooth switching control method according to claim 1, characterized in that, Based on the inrush current prediction range, the width and peak amplitude of the prediction range corresponding to each phase time sequence are calculated to identify the target phase interval of the inrush current fluctuation. Specifically: Calculate the width and peak amplitude of the inrush current prediction range corresponding to each phase timing, wherein the width value is the difference between the upper limit and the lower limit of the inrush current prediction range; Based on the width value and peak amplitude, a surge characteristic mapping relationship is constructed to determine the overlap of the closing surge prediction range of adjacent phase timings, and adjacent timings with an overlap exceeding a preset threshold are merged into a timing group; Calculate the volatility coefficient of each time series group and classify the stability level based on the volatility coefficient, wherein the volatility coefficient is the ratio of the standard deviation to the mean of the prediction range within the time series group; The comprehensive risk assessment value is calculated based on the stability level and the preset safety margin, and the time series group with the smallest comprehensive risk assessment value is identified as the target phase interval. The safety margin is calculated by combining the rated upper limit of the equipment and the maximum predicted value within the time series group.
4. The distribution network islanding and grid-connected smooth switching control method according to claim 1, characterized in that, The step of evaluating the stability contribution of each phase timing within the target phase interval to determine the target closing timing specifically involves: Within the target phase interval of the surge fluctuation, the difference between the predicted surge value of each phase time series and the average value of all time series within the interval is calculated, and the stability contribution weight is determined based on the difference value. For each phase timing sequence, the stability contribution weight is multiplied by the width value to obtain the stability score of each timing sequence; All phase timing sequences are sorted based on the stability score, and the timing sequence with the highest stability score is selected as the target closing timing sequence.
5. The distribution network islanding and grid-connected smooth switching control method according to claim 1, characterized in that, The step of adjusting the inverter's output characteristic parameters according to the target closing timing to obtain the adjusted inverter output signal is as follows: The instantaneous values of the three-phase voltage and the three-phase current at the inverter output are collected, and the instantaneous values of the three-phase voltage and the three-phase current are converted into direct-axis components and quadrature-axis components in a rotating coordinate system, respectively. Active power and reactive power are calculated based on the direct-axis component and the quadrature-axis component, respectively, and the current power factor is calculated based on the active power and the reactive power. Calculate the time difference between the target closing time and the current time corresponding to the target closing sequence. If the time difference is less than a preset threshold, generate voltage amplitude adjustment and phase adjustment based on the difference between the current power factor and the target power factor. The inverter's reference voltage vector is corrected according to the voltage amplitude adjustment and the phase adjustment, respectively. The corrected reference voltage vector is then decomposed using a space vector pulse width modulation algorithm to obtain the adjusted inverter output signal.
6. The distribution network islanding and grid-connected smooth switching control method according to claim 1, characterized in that, The process involves collecting current information from the inverter output signal. When the current information meets preset conditions, iterative optimization is performed to adjust the phase difference compensation, resulting in a phase difference correction result. Specifically: The current signal in the inverter output signal is collected by a current transformer, and the current signal is processed by a sliding window to calculate the effective value and instantaneous peak value of the current in each window. The peak factor is calculated based on the effective value of the current and the instantaneous peak value. When the peak factor exceeds a first preset threshold, the estimated value of the impact current is determined. If the estimated inrush current reaches a preset proportion of the upper limit of the rated short-time withstand current of the equipment, an iterative optimization process is initiated. During the iterative optimization process, the deviation between the islanded voltage phase drift rate and the main grid phase is calculated in real time. If the deviation exceeds a second preset threshold, the compensation correction amount is increased proportionally until the estimated inrush current drops to within the safe range of the rated short-time withstand current of the equipment, and the phase difference correction result is determined.
7. The distribution network islanding and grid-connected smooth switching control method according to claim 1, characterized in that, The generation of grid connection control commands based on the phase difference correction results to control the smooth switching of islanded distribution network connections specifically includes: Based on the correction results, the real-time phase difference between the islanded voltage and the main grid voltage is calculated, and the real-time phase difference is compared with a preset phase difference tolerance. When the real-time phase difference is less than or equal to the preset phase difference tolerance, a grid connection closing command is generated and sent to the grid connection circuit breaker to perform the closing operation, thereby realizing a smooth switching between islanded and grid-connected distribution networks.
8. The distribution network islanding and grid-connected smooth switching control method according to any one of claims 1-7, characterized in that, After generating grid-connected control commands based on the phase difference correction results to control the smooth switching of islanded distribution network connections, the method further includes: The actual waveform of the inrush current during closing is monitored in real time, and inrush current parameters are extracted from the actual waveform. A deviation feature vector is calculated based on the inrush current parameters and the predicted value. The inrush current parameters include inrush current peak value, duration, and attenuation characteristic parameters. When the root mean square error of the deviation feature vector exceeds a preset threshold, the weight factor of the surge prediction model is adjusted using the backpropagation algorithm, and the model parameters are updated based on the learning rate decay strategy to obtain an optimized surge prediction model.
9. A smooth switching control system for islanded grid connection in a distribution network, characterized in that, include: Acquisition module, prediction module, and control module; The acquisition module is used to extract features from the first voltage signal on the island side of the distribution network and the second voltage signal on the main grid side, respectively, to obtain quantized feature values; The prediction module is used to input the quantized feature values into a pre-trained inrush current prediction model to output the predicted range of closing inrush current under different phase sequences. Based on the predicted range of closing inrush current, it calculates the width and peak amplitude of the predicted range corresponding to each phase sequence to identify the target phase interval of inrush current fluctuations, and evaluates the stability contribution of each phase sequence within the target phase interval to determine the target closing sequence. Specifically, inputting the quantized feature values into the pre-trained inrush current prediction model to output the predicted range of closing inrush current under different phase sequences involves: combining the quantized feature values into an input sequence according to different phase sequences and inputting it into the inrush current prediction model to obtain the probability distribution of the closing inrush current amplitude under each phase sequence. The inrush current prediction model is obtained by training a long short-term memory network model with monitoring data from historical grid connection records and corresponding closing inrush current level labels. Based on the probability distribution, the expected value and standard deviation of the closing inrush current amplitude are calculated, and the predicted range of the closing inrush current amplitude under different phase sequences is determined according to the expected value and the standard deviation. The control module is used to adjust the output characteristic parameters of the inverter according to the target closing sequence to obtain the adjusted inverter output signal, and to collect the current information in the inverter output signal. When the current information meets the preset conditions, iterative optimization is performed to adjust the phase difference compensation to obtain the phase difference correction result, and a grid connection control command is generated based on the phase difference correction result to control the smooth switching of the distribution network islanded grid connection.
Citation Information
Patent Citations
A control method and a system of a grid-connected inverter
CN109245149A
Grid-connected inverter control method based on virtual synchronous generator
CN117614001A