A user side resource reactive voltage control method and device based on neural network derivable safety correction

CN122931844APending Publication Date: 2026-10-16CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611066989.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-17
Publication Date
2026-10-16

AI Technical Summary

Technical Problem

基于规则的方法实现简单,但难以适应高比例光伏引起的快速波动;基于优化模型的方法能够显式处理安全约束,但在实时场景中计算负担较重,且需要精确模型和完整预测信息;基于神经网络的方法可在在线阶段快速输出控制动作,但其输出结果通常不能严格保证满足电压上下限、逆变器容量、无功出力上下限等安全约束

Benefits of technology

本发明提供了一种基于神经网络可导安全修正的用户侧资源无功电压控制方法及装置,包括:将配用电网运行状态作为预先训练的神经网络模型的输入,得到预先训练的神经网络模型输出的各无功调节设备的无功动作参考向量;判断所述各无功调节设备的无功动作参考向量是否满足预设硬性约束,若是,则将所述各无功调节设备的无功动作参考向量作为各无功调节设备的初始无功动作,否则,以所述各无功调节设备的无功动作参考向量为自适应矩估计Adam算法的迭代初值,执行Adam算法得到无功动作修正量,并将所述无功动作修正量作为各无功调节设备的初始无功动作。本发明提供的技术方案,通过针对性设计,成功达成无功电压控制目标,兼具保护范围和工程可实施性,具体的:

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122931844A_ABST
    Figure CN122931844A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of new energy grid-connected operation, and specifically provides a user-side resource reactive voltage control method and device based on neural network derivable safety correction, comprising: taking the power distribution grid operation state as the input of the pre-trained neural network model to obtain the reactive action reference vector of each reactive regulation device output by the pre-trained neural network model; judging whether the reactive action reference vector of each reactive regulation device meets the preset hard constraint, if yes, taking the reactive action reference vector of each reactive regulation device as the initial reactive action of each reactive regulation device, otherwise, taking the reactive action reference vector of each reactive regulation device as the iteration initial value of the Adam algorithm of the self-adaptive matrix estimation, executing the Adam algorithm to obtain the reactive action correction, and taking the reactive action correction as the initial reactive action of each reactive regulation device. Through targeted design, the scheme successfully achieves the reactive voltage control target, and has protection range and engineering implementability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of new energy grid-connected operation technology, specifically to a user-side resource reactive power and voltage control method and device based on neural network-based differentiable safety correction. Background Technology With the large-scale integration of distributed photovoltaic (PV) power into the distribution grid, the traditional unidirectional power flow is gradually transforming into a bidirectional, random, and highly volatile power flow pattern. During midday when PV power generation is high and load is low, voltage rises are likely to occur at the feeder ends; conversely, in the evening when PV power generation rapidly declines and load increases, localized low voltages may occur. If the voltage at distribution grid nodes consistently or frequently exceeds limits, it will lead to a decline in power quality for users, malfunctions of protection devices, inverter disconnection from the grid, accelerated aging of equipment insulation, and even restrictions on renewable energy consumption and operational safety risks to the distribution grid.

[0002] Existing reactive power and voltage control methods mainly include rule-based segmented control, optimization model-based centralized control, and neural network-based intelligent control. Rule-based methods are simple to implement but struggle to adapt to rapid fluctuations caused by high-proportion photovoltaic systems. Optimization model-based methods can explicitly handle safety constraints, but they have a heavy computational burden in real-time scenarios and require accurate models and complete prediction information. Neural network-based methods can quickly output control actions in the online phase, but their output results often cannot strictly guarantee compliance with safety constraints such as voltage upper and lower limits, inverter capacity, and reactive power output upper and lower limits.

[0003] Therefore, there is an urgent need for a reactive voltage safety control method that is fast, feasible, and trainable, so that the neural network can learn control laws using historical operating data and eliminate the risk of exceeding limits through a differentiable safety correction process after output action, thereby meeting the real-time control requirements of a high proportion of photovoltaic power grid. Summary of the Invention

[0004] To overcome the above-mentioned shortcomings, this invention proposes a user-side resource reactive voltage control method and device based on neural network-based differentiable safety correction.

[0005] Firstly, a user-side resource reactive power and voltage control method based on neural network differentiable safety correction is provided, the user-side resource reactive power and voltage control method based on neural network differentiable safety correction includes: The operating status of the power grid is used as the input to a pre-trained neural network model to obtain the reactive power action reference vector of each reactive power regulation device output by the pre-trained neural network model. Determine whether the reactive power action reference vector of each reactive power regulation device meets the preset hard constraints. If yes, use the reactive power action reference vector of each reactive power regulation device as the initial reactive power action of each reactive power regulation device. Otherwise, use the reactive power action reference vector of each reactive power regulation device as the initial value of the adaptive moment estimation Adam algorithm, execute the Adam algorithm to obtain the reactive power action correction amount, and use the reactive power action correction amount as the initial reactive power action of each reactive power regulation device.

[0006] Preferably, the operating status of the power grid includes at least one of the following: node voltage, load power, photovoltaic active power output, equipment reactive power capacity, network topology, and branch impedance parameters.

[0007] Furthermore, the preset hard constraints are as follows:

[0008]

[0009]

[0010]

[0011] In the above formula, This is the lower limit of the square of the node voltage. To pre-set a safety margin, Let be the square of the node voltage corresponding to the reactive power action reference vector of each reactive power regulation device at time t. This represents the upper limit of the square of the node voltage. This is the lower limit of the node voltage. This is the upper limit of the node voltage. This represents the lower limit of the reactive power operating power for each reactive power regulation device. Let be the reactive power action reference vector for each reactive power regulation device at time t. This refers to the upper limit of reactive power operating power for each reactive power regulation device. Let be the reactive power operation reference vector of the i-th reactive power regulation device at time t. Let be the active power output of the i-th reactive power regulating device at time t. Let be the apparent power capacity of the i-th reactive power regulation device at time t. This represents the reactive power operation of each reactive power regulation device after correction at time t-1. To adjust the upper limit of the quantity.

[0012] Furthermore, the squared node voltages corresponding to the reactive power operation reference vectors of each reactive power regulation device at time t are as follows:

[0013] In the above formula, Let be the initial squared value of the node voltage at time t. This is the active power-voltage sensitivity matrix. The net active power injection at node t is the basic active power injection. This is the reactive power-voltage sensitivity matrix. The net reactive power injection at node t is the basic reactive power injection at time t. This is the correlation matrix from reactive power regulation equipment to nodes. For compensation coefficient, This is the loss compensation vector.

[0014] Preferably, the step of using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and executing the Adam algorithm to obtain the reactive power action correction amount, includes: The reactive power correction amount obtained in the k-th iteration during the execution of the Adam algorithm is determined by the following formula. :

[0015] In the above formula, This refers to the reactive power correction amount obtained in the (k-1)th iteration during the execution of the Adam algorithm. To correct the step size, This is the first-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. It is a preset positive number.

[0016] Furthermore, the first-order moment deviation correction and second-order moment deviation correction corresponding to the k-th iteration during the execution of the Adam algorithm are as follows:

[0017] In the above formula, Let be the first moment corresponding to the k-th iteration during the execution of the Adam algorithm. This refers to the first-order moment decay coefficient corresponding to the k-th iteration in the Adam algorithm. This represents the second moment corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment decay coefficient corresponding to the k-th iteration during the execution of the Adam algorithm.

[0018] Furthermore, the first and second moments corresponding to the k-th iteration during the execution of the Adam algorithm are as follows:

[0019]

[0020] In the above formula, This represents the first moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. This represents the second moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. Let be the gradient of the differentiable modified target with respect to the previous action in the k-th iteration of the Adam algorithm. This indicates element-wise multiplication.

[0021] Furthermore, the gradient of the differentiable corrected objective corresponding to the k-th iteration during the execution of the Adam algorithm with respect to the previous action is as follows:

[0022] In the above formula, These are the gradient coefficients. The objective function is a differentiable modified function.

[0023] Furthermore, regarding the aforementioned The differentiable correction objective function is as follows:

[0024] In the above formula, For voltage over-limit violation degree, This constitutes a violation of the limit due to unproductive activity. For exceeding capacity limits, For exceeding the limit while climbing, This is a violation of the degree weighting rule due to excessive reactive power. This violates the degree weighting rule by exceeding the capacity limit. For exceeding the limit while climbing, violating the degree weight, The coefficient for the action proximity term. Let t be the initial reactive power operation of each reactive power regulating device.

[0025] Furthermore, the voltage over-limit violation degree is as follows:

[0026] The reactive power limit violation rates are as follows:

[0027] The capacity over-limit violation rates are as follows:

[0028] The following are the degrees of violation for exceeding the climbing limit: .

[0029] Furthermore, the loss function used in the training process of the pre-trained neural network model is as follows:

[0030] In the above formula, The value of the loss function. To control the effect loss value, The reactive power correction amount is obtained by using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and then executing the Adam algorithm to obtain the reactive power action correction amount. As the first weight, It is the second weight.

[0031] Furthermore, the control effect loss value is as follows:

[0032] In the above formula, As the first coefficient, As the second coefficient, At time t The square of the corresponding node voltage after the action, This represents the squared value of the desired voltage.

[0033] Secondly, a user-side resource reactive power voltage control device based on neural network differentiable safety correction is provided, the user-side resource reactive power voltage control device based on neural network differentiable safety correction includes: The first analysis module is used to take the operating status of the power grid as input to a pre-trained neural network model to obtain the reactive power action reference vector of each reactive power regulation device output by the pre-trained neural network model. The second analysis module is used to determine whether the reactive power action reference vector of each reactive power regulation device meets the preset hard constraints. If so, the reactive power action reference vector of each reactive power regulation device is used as the initial reactive power action of each reactive power regulation device. Otherwise, the reactive power action reference vector of each reactive power regulation device is used as the initial value of the adaptive moment estimation Adam algorithm, the Adam algorithm is executed to obtain the reactive power action correction amount, and the reactive power action correction amount is used as the initial reactive power action of each reactive power regulation device.

[0034] Thirdly, a computer device is provided, comprising: one or more processors; The processor is used to store one or more programs; When the one or more programs are executed by the one or more processors, the user-side resource reactive voltage control method based on neural network-guided safety correction is implemented.

[0035] Fourthly, a computer-readable storage medium is provided having a computer program stored thereon, wherein when the computer program is executed, it implements the user-side resource reactive voltage control method based on neural network-based differentiable safety correction.

[0036] The above-described technical solutions of the present invention have at least one or more of the following beneficial effects: This invention provides a user-side resource reactive power and voltage control method and apparatus based on neural network differentiable safety correction, comprising: using the operating state of the distribution grid as input to a pre-trained neural network model to obtain reactive power action reference vectors of each reactive power regulation device output by the pre-trained neural network model; determining whether the reactive power action reference vectors of each reactive power regulation device meet preset hard constraints; if so, using the reactive power action reference vectors of each reactive power regulation device as the initial reactive power action of each reactive power regulation device; otherwise, using the reactive power action reference vectors of each reactive power regulation device as the initial iteration value of the Adam algorithm for adaptive moment estimation, executing the Adam algorithm to obtain the reactive power action correction amount, and using the reactive power action correction amount as the initial reactive power action of each reactive power regulation device. The technical solution provided by this invention, through targeted design, successfully achieves the reactive power and voltage control target, and has both protection range and engineering feasibility. Specifically: This invention combines rapid neural network action generation with differentiable safety correction, enabling the rapid generation of reactive actions that meet voltage safety constraints during the online control phase, thus avoiding the inability to perform actions that may occur with simple neural network control.

[0037] This invention establishes voltage safety constraints based on the relationship between the reactive power operation reference vector of the reactive power regulation equipment and the square of the node voltage. This not only preserves the physical influence of the distribution grid topology and branch impedance on voltage changes, but also avoids the high computational burden brought about by complete nonlinear power flow optimization, making it suitable for real-time control.

[0038] This invention uses the Adam method to perform reactive action correction. The parameters are simple to implement and it is suitable for batch sample parallel computing and end-to-end training of neural networks.

[0039] This invention reduces the magnitude of online corrections and improves the smoothness of control actions and device-friendly operation by correcting the distance penalty before and after the correction. Attached Figure Description

[0040] Figure 1 This is a schematic diagram of the main steps of the user-side resource reactive voltage control method based on neural network differentiable safety correction according to an embodiment of the present invention. Detailed Implementation

[0041] The specific embodiments of the present invention will be further described in detail below with reference to the accompanying drawings.

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

[0043] Example 1 See appendix Figure 1 , Figure 1 This is a schematic flowchart illustrating the main steps of a user-side resource reactive power and voltage control method based on neural network-based differentiable safety correction, according to an embodiment of the present invention. Figure 1 As shown, the user-side resource reactive power and voltage control method based on neural network differentiable safety correction in this embodiment of the invention mainly includes the following steps: Step S101: Use the operating status of the power grid as the input to the pre-trained neural network model to obtain the reactive power operation reference vector of each reactive power regulation device output by the pre-trained neural network model; Step S102: Determine whether the reactive power action reference vector of each reactive power regulation device satisfies the preset hard constraint. If yes, use the reactive power action reference vector of each reactive power regulation device as the initial reactive power action of each reactive power regulation device. Otherwise, use the reactive power action reference vector of each reactive power regulation device as the initial value of the adaptive moment estimation Adam algorithm, execute the Adam algorithm to obtain the reactive power action correction amount, and use the reactive power action correction amount as the initial reactive power action of each reactive power regulation device.

[0044] This correction process does not solve constrained optimization problems. Instead, it unifies over-limit voltage, equipment over-limit, and action deviation into an unconstrained differentiable optimization process through a differentiable violation function, thereby facilitating end-to-end backpropagation.

[0045] In this embodiment, the neural network model can be a multilayer feedforward neural network as the main implementation, or it can be extended to a graph neural network, a Transformer network, or a temporal neural network. After receiving the state vector, the neural network outputs the initial reactive power action, which represents the reactive power that each reactive power regulation device should inject or absorb at the current moment.

[0046] In this embodiment, the operating status of the power grid includes at least one of the following: node voltage, load power, photovoltaic active power output, equipment reactive power capacity, network topology, and branch impedance parameters.

[0047] In one implementation, the preset hard constraint is as follows:

[0048]

[0049]

[0050]

[0051] In the above formula, This is the lower limit of the square of the node voltage. To pre-set a safety margin, Let be the square of the node voltage corresponding to the reactive power action reference vector of each reactive power regulation device at time t. This represents the upper limit of the square of the node voltage. This is the lower limit of the node voltage. This is the upper limit of the node voltage. This represents the lower limit of the reactive power operating power for each reactive power regulation device. Let be the reactive power action reference vector for each reactive power regulation device at time t. This refers to the upper limit of reactive power operating power for each reactive power regulation device. Let be the reactive power operation reference vector of the i-th reactive power regulation device at time t. Let be the active power output of the i-th reactive power regulating device at time t. Let be the apparent power capacity of the i-th reactive power regulation device at time t. This represents the reactive power operation of each reactive power regulation device after correction at time t-1. To adjust the upper limit of the quantity.

[0052] In the main embodiment, the lower and upper limits of the voltage amplitude are 0.95 pu and 1.05 pu, respectively.

[0053] In one implementation, the squared node voltages corresponding to the reactive power operation reference vectors of each reactive power regulation device at time t are as follows:

[0054] In the above formula, Let be the initial squared value of the node voltage at time t. This is the active power-voltage sensitivity matrix. The net active power injection at node t is the basic active power injection. This is the reactive power-voltage sensitivity matrix. The net reactive power injection at node t is the basic reactive power injection at time t. This is the correlation matrix from reactive power regulation equipment to nodes. For compensation coefficient, This is the loss compensation vector.

[0055] In this embodiment, the step of using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and executing the Adam algorithm to obtain the reactive power action correction amount, includes: The reactive power correction amount obtained in the k-th iteration during the execution of the Adam algorithm is determined by the following formula. :

[0056] In the above formula, This refers to the reactive power correction amount obtained in the (k-1)th iteration during the execution of the Adam algorithm. To correct the step size, This is the first-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. It is a preset positive number.

[0057] In one implementation, the first-order moment deviation correction and the second-order moment deviation correction corresponding to the k-th iteration during the execution of the Adam algorithm are as follows:

[0058] In the above formula, Let be the first moment corresponding to the k-th iteration during the execution of the Adam algorithm. This refers to the first-order moment decay coefficient corresponding to the k-th iteration in the Adam algorithm. This represents the second moment corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment decay coefficient corresponding to the k-th iteration during the execution of the Adam algorithm.

[0059] In one implementation, the first and second moments corresponding to the k-th iteration during the execution of the Adam algorithm are as follows:

[0060]

[0061] In the above formula, This represents the first moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. This represents the second moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. Let be the gradient of the differentiable modified target with respect to the previous action in the k-th iteration of the Adam algorithm. This indicates element-wise multiplication.

[0062] In one implementation, the gradient of the differentiable corrected objective corresponding to the k-th iteration of the Adam algorithm with respect to the previous action is as follows:

[0063] In the above formula, These are the gradient coefficients. The objective function is a differentiable modified function.

[0064] In one implementation, for the The differentiable correction objective function is as follows:

[0065] In the above formula, For voltage over-limit violation degree, This constitutes a violation of the limit due to unproductive activity. For exceeding capacity limits, For exceeding the limit while climbing, This is a violation of the degree weighting rule due to excessive reactive power. This violates the degree weighting rule by exceeding the capacity limit. For exceeding the limit while climbing, violating the degree weight, The coefficient for the action proximity term. Let t be the initial reactive power operation of each reactive power regulating device.

[0066] Satisfy during iteration If the value is less than the preset threshold, the process will stop early; if the threshold requirement is not met early, the process will stop when the maximum number of iterations K is reached, and the final correction action will be output. In one implementation, the voltage over-limit violation is as follows:

[0067] The reactive power limit violation rates are as follows:

[0068] The capacity over-limit violation rates are as follows:

[0069] The following are the degrees of violation for exceeding the climbing limit: .

[0070] In one implementation, the loss function used during the training of the pre-trained neural network model is as follows:

[0071] In the above formula, The value of the loss function. To control the effect loss value, The reactive power correction amount is obtained by using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and then executing the Adam algorithm to obtain the reactive power action correction amount. As the first weight, It is the second weight.

[0072] In one implementation, the control effect loss value is as follows:

[0073] In the above formula, As the first coefficient, As the second coefficient, At time t The square of the corresponding node voltage after the action, This represents the squared value of the desired voltage.

[0074] Finally, the corrected safe reactive power action is sent as the control command for the current moment to each reactive power regulation device. If the controlled object is a photovoltaic inverter, the reactive power setpoint or power factor setpoint is sent according to the inverter communication protocol; if the controlled object includes SVG, SVC, capacitor bank or energy storage converter, it is converted into the corresponding control command according to the device type.

[0075] In another embodiment, the single-moment state can be extended to a sequence of states including photovoltaic forecasts, load forecasts, and equipment capacity forecasts for multiple future moments, and the neural network outputs a reactive power action sequence. A differentiable safety correction module performs Adam corrections on this action sequence moment-by-moment or as a whole, thereby forming a rolling time-domain reactive power and voltage safety control method.

[0076] In one specific implementation, in a medium-to-low voltage radial distribution grid with a high proportion of distributed photovoltaic (PV) access, multiple feeder nodes are connected to distributed PV inverters. The distribution automation system collects data on the voltage of each node, the active and reactive power of the load, the active power output of the PV system, and the available capacity of the inverters every 5 minutes, and normalizes the data to form a state vector.

[0077] At each control moment, the neural network outputs the initial reactive power output of each photovoltaic inverter based on the current state. Subsequently, the system constructs a device correlation matrix based on the feeder topology, branch resistance and reactance, and photovoltaic inverter access nodes, and estimates the squared voltage of each node using the relationship between the reactive power action reference vector of the reactive power regulation device and the squared voltage of the node. If the initial action causes the voltage of some nodes to exceed 1.05 pu or fall below 0.95 pu, the differentiated safety correction module calculates the voltage violation degree and inverter capacity violation degree, and uses the Adam method to iteratively correct the initial action to obtain the safe reactive power action.

[0078] For a single photovoltaic inverter, its current active power output and rated apparent power determine the available reactive power range. The system ultimately converts the safe reactive power action into the inverter's reactive power setpoint and issues it. If an inverter experiences a communication failure or insufficient available capacity, the system can set its upper and lower reactive power limits to zero or reduce its weight, and re-perform the correction for the remaining controllable devices.

[0079] In this embodiment, the neural network backbone employs a three-layer fully connected network, with ReLU activation function in the hidden layers and tanh function in the output layer, scaled according to device capacity. The Adam correction steps can be set to 5 to 20 steps, the learning rate to 0.001 to 0.01, the first-order moment decay coefficient to 0.9, and the second-order moment decay coefficient to 0.999. During training, a training set is constructed using a mixture of historical running samples and power flow simulation samples, and the neural network parameters are updated through end-to-end backpropagation.

[0080] Example 2 Based on the same inventive concept, this invention also provides a user-side resource reactive power voltage control device based on neural network differentiable safety correction, the user-side resource reactive power voltage control device based on neural network differentiable safety correction includes: The first analysis module is used to take the operating status of the power grid as input to a pre-trained neural network model to obtain the reactive power action reference vector of each reactive power regulation device output by the pre-trained neural network model. The second analysis module is used to determine whether the reactive power action reference vector of each reactive power regulation device meets the preset hard constraints. If so, the reactive power action reference vector of each reactive power regulation device is used as the initial reactive power action of each reactive power regulation device. Otherwise, the reactive power action reference vector of each reactive power regulation device is used as the initial value of the adaptive moment estimation Adam algorithm, the Adam algorithm is executed to obtain the reactive power action correction amount, and the reactive power action correction amount is used as the initial reactive power action of each reactive power regulation device.

[0081] Preferably, the operating status of the power grid includes at least one of the following: node voltage, load power, photovoltaic active power output, equipment reactive power capacity, network topology, and branch impedance parameters.

[0082] Furthermore, the preset hard constraints are as follows:

[0083]

[0084]

[0085]

[0086] In the above formula, This is the lower limit of the square of the node voltage. To pre-set a safety margin, Let be the square of the node voltage corresponding to the reactive power action reference vector of each reactive power regulation device at time t. This represents the upper limit of the square of the node voltage. This is the lower limit of the node voltage. This is the upper limit of the node voltage. This represents the lower limit of the reactive power operating power for each reactive power regulation device. Let be the reactive power action reference vector for each reactive power regulation device at time t. This refers to the upper limit of reactive power operating power for each reactive power regulation device. Let be the reactive power operation reference vector of the i-th reactive power regulation device at time t. Let be the active power output of the i-th reactive power regulating device at time t. Let be the apparent power capacity of the i-th reactive power regulation device at time t. This represents the reactive power operation of each reactive power regulation device after correction at time t-1. To adjust the upper limit of the quantity.

[0087] Furthermore, the squared node voltages corresponding to the reactive power operation reference vectors of each reactive power regulation device at time t are as follows:

[0088] In the above formula, Let be the initial squared value of the node voltage at time t. This is the active power-voltage sensitivity matrix. The net active power injection at node t is the basic active power injection. This is the reactive power-voltage sensitivity matrix. The net reactive power injection at node t is the basic reactive power injection at time t. This is the correlation matrix from reactive power regulation equipment to nodes. For compensation coefficient, This is the loss compensation vector.

[0089] Preferably, the step of using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and executing the Adam algorithm to obtain the reactive power action correction amount, includes: The reactive power correction amount obtained in the k-th iteration during the execution of the Adam algorithm is determined by the following formula. :

[0090] In the above formula, This refers to the reactive power correction amount obtained in the (k-1)th iteration during the execution of the Adam algorithm. To correct the step size, This is the first-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. It is a preset positive number.

[0091] Furthermore, the first-order moment deviation correction and second-order moment deviation correction corresponding to the k-th iteration during the execution of the Adam algorithm are as follows:

[0092] In the above formula, Let be the first moment corresponding to the k-th iteration during the execution of the Adam algorithm. This refers to the first-order moment decay coefficient corresponding to the k-th iteration in the Adam algorithm. This represents the second moment corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment decay coefficient corresponding to the k-th iteration during the execution of the Adam algorithm.

[0093] Furthermore, the first and second moments corresponding to the k-th iteration during the execution of the Adam algorithm are as follows:

[0094]

[0095] In the above formula, This represents the first moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. This represents the second moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. Let be the gradient of the differentiable modified target with respect to the previous action in the k-th iteration of the Adam algorithm. This indicates element-wise multiplication.

[0096] Furthermore, the gradient of the differentiable corrected objective corresponding to the k-th iteration during the execution of the Adam algorithm with respect to the previous action is as follows:

[0097] In the above formula, These are the gradient coefficients. The objective function is a differentiable modified function.

[0098] Furthermore, regarding the aforementioned The differentiable correction objective function is as follows:

[0099] In the above formula, For voltage over-limit violation degree, This constitutes a violation of the limit due to unproductive activity. For exceeding capacity limits, For exceeding the limit while climbing, This is a violation of the degree weighting rule due to excessive reactive power. This violates the degree weighting rule by exceeding the capacity limit. For exceeding the limit while climbing, violating the degree weight, The coefficient for the action proximity term. Let t be the initial reactive power operation of each reactive power regulating device.

[0100] Furthermore, the voltage over-limit violation degree is as follows:

[0101] The reactive power limit violation rates are as follows:

[0102] The capacity over-limit violation rates are as follows:

[0103] The following are the degrees of violation for exceeding the climbing limit: .

[0104] Furthermore, the loss function used in the training process of the pre-trained neural network model is as follows:

[0105] In the above formula, The value of the loss function. To control the effect loss value, The reactive power correction amount is obtained by using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and then executing the Adam algorithm to obtain the reactive power action correction amount. As the first weight, It is the second weight.

[0106] Furthermore, the control effect loss value is as follows:

[0107] In the above formula, As the first coefficient, As the second coefficient, At time t The square of the corresponding node voltage after the action, This represents the squared value of the desired voltage.

[0108] Example 3 Based on the same inventive concept, this invention also provides a computer device, which includes a processor and a memory. The memory stores a computer program, which includes program instructions. The processor executes the program instructions stored in the computer storage medium. The processor may 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. It is the computing and control core of the terminal, suitable for implementing one or more instructions, specifically suitable for loading and executing one or more instructions in the computer storage medium to implement corresponding method flows or corresponding functions, thereby realizing the steps of the user-side resource reactive power voltage control method based on neural network-guided safety correction in the above embodiments.

[0109] Example 4 Based on the same inventive concept, this invention also provides a storage medium, specifically a computer-readable storage medium (Memory), which is a memory device in a computer device used to store programs and data. It is understood that the computer-readable storage medium here can include both the built-in storage medium in the computer device and extended storage media supported by the computer device. The computer-readable storage medium provides storage space that stores the terminal's operating system. Furthermore, this storage space also stores one or more instructions suitable for loading and execution by a processor. These instructions can be one or more computer programs (including program code). It should be noted that the computer-readable storage medium here can be high-speed RAM or non-volatile memory, such as at least one disk storage device. The processor can load and execute one or more instructions stored in the computer-readable storage medium to implement the steps of the user-side resource reactive power voltage control method based on neural network-differentiated safety correction in the above embodiments.

[0110] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0111] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0112] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0113] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0114] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. A user-side resource reactive power and voltage control method based on neural network differentiable safety correction, characterized in that, The method includes: The operating status of the power grid is used as the input to a pre-trained neural network model to obtain the reactive power action reference vector of each reactive power regulation device output by the pre-trained neural network model. Determine whether the reactive power action reference vector of each reactive power regulation device meets the preset hard constraints. If yes, use the reactive power action reference vector of each reactive power regulation device as the initial reactive power action of each reactive power regulation device. Otherwise, use the reactive power action reference vector of each reactive power regulation device as the initial value of the adaptive moment estimation Adam algorithm, execute the Adam algorithm to obtain the reactive power action correction amount, and use the reactive power action correction amount as the initial reactive power action of each reactive power regulation device.

2. The method as described in claim 1, characterized in that, The operating status of the distribution network includes at least one of the following: node voltage, load power, photovoltaic active power output, equipment reactive power capacity, network topology, and branch impedance parameters.

3. The method as described in claim 1, characterized in that, The preset hard constraints are as follows: In the above formula, This is the lower limit of the square of the node voltage. To pre-set a safety margin, Let be the square of the node voltage corresponding to the reactive power action reference vector of each reactive power regulation device at time t. This represents the upper limit of the square of the node voltage. This is the lower limit of the node voltage. This is the upper limit of the node voltage. This represents the lower limit of the reactive power operating power for each reactive power regulation device. Let be the reactive power action reference vector for each reactive power regulation device at time t. This refers to the upper limit of reactive power operating power for each reactive power regulation device. Let be the reactive power operation reference vector of the i-th reactive power regulation device at time t. Let be the active power output of the i-th reactive power regulating device at time t. Let be the apparent power capacity of the i-th reactive power regulation device at time t. This represents the reactive power operation of each reactive power regulation device after correction at time t-1. To adjust the upper limit of the quantity.

4. The method as described in claim 3, characterized in that, The squared node voltages corresponding to the reactive power action reference vectors of each reactive power regulation device at time t are as follows: In the above formula, Let be the initial squared value of the node voltage at time t. This is the active power-voltage sensitivity matrix. The net active power injection at node t is the basic active power injection. This is the reactive power-voltage sensitivity matrix. The net reactive power injection at node t is the basic reactive power injection at time t. This is the correlation matrix from reactive power regulation equipment to nodes. For compensation coefficient, This is the loss compensation vector.

5. The method as described in claim 1, characterized in that, The step of using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and executing the Adam algorithm to obtain the reactive power action correction amount, includes: The reactive power correction amount obtained in the k-th iteration during the execution of the Adam algorithm is determined by the following formula. : In the above formula, This refers to the reactive power correction amount obtained in the (k-1)th iteration during the execution of the Adam algorithm. To correct the step size, This is the first-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment deviation correction amount corresponding to the k-th iteration during the execution of the Adam algorithm. It is a preset positive number.

6. The method as described in claim 5, characterized in that, The first-order moment deviation correction and second-order moment deviation correction for the k-th iteration during the execution of the Adam algorithm are as follows: In the above formula, Let be the first moment corresponding to the k-th iteration during the execution of the Adam algorithm. This refers to the first-order moment decay coefficient corresponding to the k-th iteration in the Adam algorithm. This represents the second moment corresponding to the k-th iteration during the execution of the Adam algorithm. This is the second-order moment decay coefficient corresponding to the k-th iteration during the execution of the Adam algorithm.

7. The method as described in claim 6, characterized in that, The first and second moments corresponding to the k-th iteration during the execution of the Adam algorithm are as follows: In the above formula, This represents the first moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. This represents the second moment corresponding to the (k-1)th iteration during the execution of the Adam algorithm. Let be the gradient of the differentiable modified target with respect to the previous action in the k-th iteration of the Adam algorithm. This indicates element-wise multiplication.

8. The method as described in claim 7, characterized in that, The gradient of the differentiable corrected objective with respect to the previous action in the k-th iteration of the Adam algorithm is as follows: In the above formula, These are the gradient coefficients. The objective function is a differentiable modified function.

9. The method as described in claim 8, characterized in that, Regarding the above The differentiable correction objective function is as follows: In the above formula, For voltage over-limit violation degree, This constitutes a violation of the limit due to unproductive activity. For exceeding capacity limits, For exceeding the limit while climbing, This is a violation of the degree weighting rule due to excessive reactive power. This violates the degree weighting rule by exceeding the capacity limit. For exceeding the limit while climbing, violating the degree weight, The coefficient for the action proximity term. Let t be the initial reactive power operation of each reactive power regulating device.

10. The method as described in claim 9, characterized in that, The voltage over-limit violation rate is as follows: The reactive power limit violation rates are as follows: The capacity over-limit violation rates are as follows: The following are the degrees of violation for exceeding the climbing limit: 。 11. The method as described in claim 10, characterized in that, The loss function used in the training process of the pre-trained neural network model is as follows: In the above formula, The value of the loss function. To control the effect loss value, The reactive power correction amount is obtained by using the reactive power action reference vector of each reactive power regulation device as the initial value for the adaptive moment estimation Adam algorithm, and then executing the Adam algorithm to obtain the reactive power action correction amount. As the first weight, It is the second weight.

12. The method as described in claim 11, characterized in that, The control effect loss value is as follows: In the above formula, As the first coefficient, As the second coefficient, At time t The square of the corresponding node voltage after the action, This represents the squared value of the desired voltage.

13. A user-side resource reactive power voltage control device based on neural network differentiable safety correction as described in any one of claims 1-12, characterized in that, The device includes: The first analysis module is used to take the operating status of the power grid as input to a pre-trained neural network model to obtain the reactive power action reference vector of each reactive power regulation device output by the pre-trained neural network model. The second analysis module is used to determine whether the reactive power action reference vector of each reactive power regulation device meets the preset hard constraints. If so, the reactive power action reference vector of each reactive power regulation device is used as the initial reactive power action of each reactive power regulation device. Otherwise, the reactive power action reference vector of each reactive power regulation device is used as the initial value of the adaptive moment estimation Adam algorithm, the Adam algorithm is executed to obtain the reactive power action correction amount, and the reactive power action correction amount is used as the initial reactive power action of each reactive power regulation device.

14. A computer device, characterized in that, include: One or more processors; The processor is used to execute one or more programs; When the one or more programs are executed by the one or more processors, the user-side resource reactive voltage control method based on neural network differentiable safety correction as described in any one of claims 1 to 12 is implemented.

15. A computer-readable storage medium, characterized in that, It contains a computer program, which, when executed, implements the user-side resource reactive voltage control method based on neural network differentiable safety correction as described in any one of claims 1 to 12.