Batch power flow solving method and device based on hybrid architecture of CPU and GPU
By employing a batch power flow solution method with a hybrid CPU and GPU architecture, combining the parallel computing capabilities of GPUs and the node adjustment capabilities of CPUs, the problem of low power flow calculation efficiency in large-scale power systems is solved, and efficient updating of power flow calculation results is achieved.
Patent Information
- Application Number
- CN202411982009.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-11-07
- Estimated Expiration
- 2044-12-31
AI Technical Summary
Traditional CPU-based serial batch power flow solving techniques are computationally inefficient when dealing with large-scale power systems, and GPU parallel computing struggles to handle node overrun issues in power flow calculations.
A hybrid CPU and GPU architecture is adopted. The CPU obtains multiple power flow calculation case groups, and the GPU performs parallel power flow calculation. It determines whether there are nodes that exceed the limit in the parallel results. If there are nodes that exceed the limit, the CPU adjusts the node type and recalculates, and finally updates the result set.
It improves the efficiency of power flow calculation, shortens the calculation time, makes up for the low efficiency of using the CPU alone, and solves the problem that the GPU has difficulty in handling node overruns.
Smart Images

Figure CN119987864B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of power systems, in particular to a batch power flow solving method and device based on a CPU and GPU hybrid architecture, a computer device, a storage medium and a computer program product. BACKGROUND
[0002] With the development of power systems, the scale of power systems is continuously expanding and the number of nodes is continuously increasing. In order to analyze the operating state of each node in the power system, engineers gradually evolved from manually calculating power flow to solving power flow problems by computer.
[0003] The traditional batch power flow solving scheme is usually a serial batch power flow solving technology based on CPU (Central Processing Unit). The technology depends on the single-core performance of the CPU to sequentially solve multiple power flow calculation examples. After completing the solution of one power flow calculation example, the solution of the next power flow calculation example is performed.
[0004] However, with the increase in power flow calculation examples and the expansion of the scale of power systems, the calculation time of the traditional scheme will significantly increase, resulting in low efficiency of power flow calculation. SUMMARY
[0005] Therefore, it is necessary to provide a batch power flow solving method and device based on a CPU and GPU hybrid architecture, which can improve the efficiency of power flow calculation.
[0006] In a first aspect, the present application provides a batch power flow solving method based on a CPU and GPU hybrid architecture. The method comprises:
[0007] obtaining a plurality of power flow calculation example groups based on a CPU, the power flow calculation examples in the same power flow calculation example group having consistent power network structures;
[0008] performing parallel power flow calculation on the plurality of power flow calculation example groups based on a GPU to obtain a first power flow calculation result set, the first power flow calculation result set including first power flow calculation results of each power flow calculation example group, and judging in parallel whether there are out-of-limit power flow calculation examples in the plurality of power flow calculation example groups according to the first power flow calculation result set, the out-of-limit power flow calculation examples including out-of-limit nodes;
[0009] In a case where the over-limit power flow calculation example exists in the power flow calculation example group, the node type of the over-limit node in the over-limit power flow calculation example is adjusted based on the CPU, power flow calculation is performed on the adjusted over-limit power flow calculation example, and a second power flow calculation result set is obtained, the second power flow calculation result set including second power flow calculation results of each adjusted over-limit power flow calculation example;
[0010] The first power flow calculation result set is updated based on the CPU according to the second power flow calculation result set, and a target power flow calculation result set is obtained, the target power flow calculation result set including target power flow calculation results of each power flow calculation example group.
[0011] In a second aspect, the present application further provides a batch power flow solving device. The device comprises:
[0012] A data acquisition module is configured to acquire a plurality of power flow calculation example groups based on a CPU, the power flow calculation examples in a same power flow calculation example group corresponding to a same power network structure;
[0013] A parallel power flow calculation module is configured to perform parallel power flow calculation on the plurality of power flow calculation example groups based on a GPU, obtain a first power flow calculation result set, and perform parallel judgment on whether an over-limit power flow calculation example exists in the plurality of power flow calculation example groups according to the first power flow calculation result set, the over-limit power flow calculation example including an over-limit node.
[0014] An over-limit node processing module is configured to, in a case where the over-limit power flow calculation example exists in the power flow calculation example group, adjust the node type of the over-limit node in the over-limit power flow calculation example based on the CPU, perform power flow calculation on the adjusted over-limit power flow calculation example, and obtain a second power flow calculation result set, the second power flow calculation result set including second power flow calculation results of each adjusted over-limit power flow calculation example.
[0015] A result updating module is configured to update the first power flow calculation result set based on the CPU according to the second power flow calculation result set, and obtain a target power flow calculation result set, the target power flow calculation result set including target power flow calculation results of each power flow calculation example group.
[0016] In a third aspect, the present application further provides a computer device. The computer device comprises a memory and a processor, the memory storing a computer program, and the processor implementing the steps in the batch power flow solving method embodiments described above when executing the computer program.
[0017] In a fourth aspect, the present application also provides a computer readable storage medium. The computer readable storage medium has a computer program stored thereon, and the computer program, when executed by a processor, implements the steps in the batch power flow solving method embodiments described above.
[0018] In a fifth aspect, the present application also provides a computer program product. The computer program product comprises a computer program, and the computer program, when executed by a processor, implements the steps in the batch power flow solving method embodiments described above.
[0019] The batch power flow solving method, device, computer device, storage medium and computer program product based on the hybrid architecture of CPU and GPU described above are different from the traditional single-core CPU serial batch power flow solving technology. The present application introduces a GPU parallel computing mechanism to realize parallel power flow calculation. Specifically, a plurality of power flow calculation case groups are first obtained based on the CPU. The power flow calculation cases in each power flow calculation case group correspond to the same power network structure. Therefore, the GPU can more efficiently and quickly perform parallel batch power flow calculation for each power flow calculation case group. The powerful parallel computing capability of the GPU is fully utilized to accelerate large-scale power flow calculation, greatly shortening the overall calculation time. Moreover, the present application also takes into account the possibility that the parallel power flow calculation mechanism may have difficulty in handling the node over-limit problem in power flow calculation. Therefore, in the case where there are over-limit power flow calculation cases in the plurality of power flow calculation case groups, the node types of the over-limit nodes in the over-limit power flow calculation cases are adjusted by the CPU. The adjusted over-limit power flow calculation cases are subjected to power flow calculation to obtain a second power flow calculation result set. Thus, the node conversion problem is effectively solved. Finally, the first power flow calculation result set is updated according to the second power flow calculation result set to obtain a target power flow calculation result set. In this way, the advantages of the efficiency of GPU parallel batch power flow calculation and the advantages of CPU processing of small-scale tasks that are difficult to parallelize, such as node conversion, can be fully combined. The deficiencies of low efficiency of CPU alone in processing batch power flow solving tasks and the difficulty of GPU in effectively handling node type conversion problems caused by over-limit can be effectively made up. Thus, the power flow calculation efficiency is effectively improved. BRIEF DESCRIPTION OF DRAWINGS
[0020] Figure 1 An application environment diagram of the batch power flow solving method based on the hybrid architecture of CPU and GPU in one embodiment;
[0021] Figure 2 A flowchart of the batch power flow solving method based on the hybrid architecture of CPU and GPU in one embodiment;
[0022] Figure 3 A flowchart of the batch power flow solving method based on the hybrid architecture of CPU and GPU in another embodiment;
[0023] Figure 4 This is a schematic diagram of the process for adjusting over-limit nodes based on a hybrid CPU and GPU architecture in one embodiment;
[0024] Figure 5 This is a flowchart illustrating a batch power flow solution method based on a hybrid CPU and GPU architecture in another embodiment.
[0025] Figure 6 This is a flowchart illustrating a batch power flow solution method based on a hybrid CPU and GPU architecture in a detailed embodiment.
[0026] Figure 7 This is a structural block diagram of a batch power flow solving device based on a hybrid CPU and GPU architecture in one embodiment;
[0027] Figure 8 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0028] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0029] The batch power flow solution method based on a CPU and GPU hybrid architecture provided in this application can be applied to, for example... Figure 1 In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104, or it can be located in the cloud or on another network server.
[0030] Specifically, power system personnel can upload multiple power flow calculation case sets to server 104 via terminal 102. The power network structure corresponding to the power flow calculation cases in each power flow calculation case set is consistent. Server 104 performs parallel power flow calculations on multiple power flow calculation case sets to obtain a first power flow calculation result set. The first power flow calculation result set includes the first power flow calculation results of each power flow calculation case set. Based on the first power flow calculation result set, server 104 determines in parallel whether there are any over-limit power flow calculation cases in the multiple power flow calculation case sets. Over-limit power flow calculation cases include over-limit nodes. Further, if there are over-limit power flow calculation cases in the power flow calculation case set, server 104 adjusts the node type of the over-limit nodes in the over-limit power flow calculation cases and performs power flow calculations on the adjusted over-limit power flow calculation cases to obtain a second power flow calculation result set. The second power flow calculation result set includes the second power flow calculation results of each adjusted over-limit power flow calculation case. Finally, server 104 updates the first power flow calculation result set based on the second power flow calculation result set to obtain a target power flow calculation result set. The target power flow calculation result set includes the target power flow calculation results of each power flow calculation case set.
[0031] The terminal 102 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices can include smart speakers, smart TVs, smart air conditioners, and smart in-vehicle systems. Portable wearable devices can include smartwatches, smart bracelets, and head-mounted devices. The server 104 can be implemented using a standalone server or a server cluster consisting of multiple servers.
[0032] In one embodiment, such as Figure 2 As shown, a batch power flow solution method based on a CPU and GPU hybrid architecture is provided, and this method is applied to... Figure 1 Taking server 104 as an example, the following steps are included:
[0033] S100 acquires multiple power flow calculation case groups based on the CPU, and the power network structure corresponding to the power flow calculation cases in each power flow calculation case group is consistent.
[0034] Power flow calculation is an electrical calculation that studies the steady-state operation of a power system. It mainly uses the given power system network structure (including nodes, branches and their connection methods), the injected power of each node (such as the power generated by generators and the power consumed by loads), and the voltage amplitude and phase angle of some nodes as known conditions to solve for the voltage amplitude and phase angle of all nodes in the power system, and then calculate the power of each branch (including active power and reactive power).
[0035] When performing power system flow calculation, different operating conditions or parameter settings need to be considered, so there may be several flow calculation examples for a power system. In order to facilitate subsequent parallel flow calculation, the flow calculation examples with consistent power network structure can be divided into the same group according to the corresponding power network structure of the flow calculation examples, for example, the flow calculation examples in a flow calculation example group may be for a specific regional power grid (including the same node and branch connection conditions), only the specific operating parameters such as load size and generator output are different. It should be noted that this process can be completed by the CPU (Graphic Processing Unit, graphic processing unit) in the server.
[0036] S300, performing parallel flow calculation on the multiple flow calculation example groups based on the GPU to obtain a first flow calculation result set, and judging whether there is an out-of-limit flow calculation example in the multiple flow calculation example groups according to the first flow calculation result set.
[0037] The first flow calculation result set includes the first flow calculation results of each flow calculation example group, and the out-of-limit flow calculation example includes an out-of-limit node. In a power system, each node has a specified voltage range and power range. If the voltage amplitude of a node obtained by flow calculation exceeds the voltage range or the power value exceeds the power range, the node is an out-of-limit node, and the flow calculation example in which the node is located is an out-of-limit flow calculation example. Parallel flow calculation refers to using a unit with parallel computing capability or running multiple threads in parallel, for example, using the GPU to simultaneously perform flow calculation on multiple flow calculation example groups. Traditional flow calculation is performed on different flow calculation examples one by one. Parallel flow calculation can perform flow calculation on multiple flow calculation example groups simultaneously, greatly improving the efficiency of flow calculation.
[0038] For example, assuming that there are three flow calculation example groups, parallel flow calculation is equivalent to starting three flow calculation threads at the same time, and performing flow calculation on the three flow calculation example groups respectively. The node voltage, branch power and other related parameters of each flow calculation example in each flow calculation example group are calculated. The flow calculation method for each flow calculation example can be Newton-Raphson method, P-Q decomposition method, etc.
[0039] After parallel flow calculation, the first flow calculation result corresponding to each flow calculation example group can be obtained. Each first flow calculation result contains the voltage amplitude, phase angle and branch power of the nodes in the flow calculation example group, and other specific flow calculation related information. The first flow calculation results of different flow calculation example groups are summarized to form a first flow calculation result set.
[0040] Further, based on the first set of power flow calculation results, whether there is an out-of-limit power flow calculation example in the plurality of power flow calculation example groups is also determined in a parallel manner. For example, if the voltage amplitude of a node exceeds the specified upper and lower limits, or the reactive power of a generator node exceeds its allowed output range, etc., the node is considered to be an out-of-limit node, and the power flow calculation example containing such an out-of-limit node is referred to as an out-of-limit power flow calculation example.
[0041] S500, in the case where there is an out-of-limit power flow calculation example in the power flow calculation example group, the node type of the out-of-limit node in the out-of-limit power flow calculation example is adjusted based on the CPU, and power flow calculation is performed on the adjusted out-of-limit power flow calculation example to obtain a second set of power flow calculation results.
[0042] The second set of power flow calculation results includes the second power flow calculation results of each adjusted out-of-limit power flow calculation example.
[0043] In the above step, when it is determined that there is an out-of-limit power flow calculation example in a certain power flow calculation example group, the node type of the out-of-limit node in the out-of-limit power flow calculation example can be adjusted according to the pre-set adjustment rule. For example, if the reactive power of a generator node is out of limit, it can be converted from the original PV node (a node type with known active power and voltage amplitude) to a PQ node (a node type with known active power and reactive power), and if the voltage amplitude of a load node is out of limit, it can be converted from a PQ node to a PV node, etc. At the same time, the out-of-limit node parameter values (such as voltage amplitude and reactive power value) are adjusted accordingly to bring them back to a reasonable range.
[0044] After the out-of-limit power flow calculation example is adjusted, power flow calculation is performed again on these adjusted out-of-limit power flow calculation examples, and a new set of power flow calculation results is obtained. The power flow calculation results of all the adjusted out-of-limit power flow calculation examples are summarized to form a second set of power flow calculation results. It should be noted that the above process of performing power flow calculation on the adjusted out-of-limit power flow calculation examples can be repeated multiple times, because in the process of power flow calculation, some out-of-limit nodes may need to be restored to the state before adjustment, such as restoring the node type and node parameter values, etc., until there is no longer an out-of-limit node in the power flow calculation example. The finally obtained power flow calculation results are summarized to obtain the second set of power flow calculation results.
[0045] S700, based on the CPU, the first set of power flow calculation results is updated according to the second set of power flow calculation results to obtain a target set of power flow calculation results.
[0046] The target set of power flow calculation results includes the target power flow calculation results of each power flow calculation example group.
[0047] After the above steps, after obtaining the first power flow calculation result set, the CPU updates the first power flow calculation result set according to the second power flow calculation result set. Specifically, the results of the groups of power flow calculation examples in the first power flow calculation result set that have exceeded the limit and have been adjusted and recalculated are replaced by the corresponding second power flow calculation results in the second power flow calculation result set to obtain a target power flow calculation result set. The target power flow calculation result set contains the target power flow calculation results of all groups of power flow calculation examples, and also includes the power flow calculation examples that do not converge in the entire power flow calculation process, the over-limit node information, the over-limit condition, etc. It reflects the accurate power flow state of the entire power system under the working conditions represented by different groups of examples after considering the over-limit condition and adjusting, so the target power flow calculation result set can be used for subsequent further power system analysis, operation decision, etc.
[0048] The above batch power flow solving method based on the hybrid architecture of CPU and GPU is different from the traditional single-core CPU serial batch power flow solving technology. The present scheme introduces a GPU parallel computing mechanism to realize parallel power flow calculation. Specifically, a plurality of groups of power flow calculation examples are first obtained based on the CPU, and the power flow calculation examples in each group of power flow calculation examples correspond to the same power network structure. Therefore, the GPU can more efficiently and quickly perform parallel batch power flow calculation on each group of power flow calculation examples in the subsequent step, fully utilizes the powerful parallel computing capability of the GPU to accelerate large-scale power flow calculation, greatly shortens the overall calculation time, and considers that the parallel power flow calculation mechanism may have difficulty in handling the node over-limit problem in power flow calculation. Therefore, in the case where there are over-limit power flow calculation examples in the plurality of groups of power flow calculation examples, the node types of the over-limit nodes in the over-limit power flow calculation examples are adjusted by the CPU, the adjusted over-limit power flow calculation examples are subjected to power flow calculation, and a second power flow calculation result set is obtained, thereby effectively solving the node conversion problem. Finally, the first power flow calculation result set is updated according to the second power flow calculation result set to obtain a target power flow calculation result set. In this way, the advantages of the efficiency of GPU parallel batch power flow calculation and the advantage of CPU processing of small-scale tasks that are difficult to parallel can be fully combined, which can effectively make up for the defects of low efficiency of CPU alone in processing batch power flow solving tasks and the difficulty of GPU in effectively handling the node type conversion problem caused by over-limit, thereby effectively improving the power flow calculation efficiency.
[0049] In one embodiment, as shown in FIG. 3, Figure 3 The method before S300 further includes:
[0050] S200, for each group of power flow calculation examples, the CPU selects a basic power flow calculation example from the group of power flow calculation examples based on the CPU, and determines the node admittance matrix and the B matrix structure of the group of power flow calculation examples according to the basic power flow calculation example.
[0051] The GPU-based parallel power flow calculation is performed on the plurality of power flow calculation example groups to obtain a first power flow calculation result set, including: performing, based on the GPU, a power flow calculation task for each power flow calculation example group to obtain the first power flow calculation result set, and the power flow calculation task for each power flow calculation example group is executed in the following steps: determining a power flow solution matrix of the power flow calculation example group according to the node admittance matrix, the B matrix structure, the preset initial voltage vector of each node in the power flow calculation example group, and the preset node constraint vector of each node, and performing power flow calculation on the power flow solution matrix to obtain the first power flow calculation result of the power flow calculation example group.
[0052] The node admittance matrix is used to describe the admittance relationship between nodes in the power network, and the order of the matrix is equal to the number of nodes in the electrical network. The node admittance matrix can be determined based on the topology (nodes) of the power network and the admittance between nodes, and reflects the electrical connection relationship and admittance characteristics between nodes in the power system network. When using the P-Q decomposition method for power flow calculation, the B matrix is needed to decouple the active power and reactive power equations. The B matrix includes two matrices, B' matrix (related to active power) and B'' matrix (related to reactive power), thereby simplifying the power flow calculation process.
[0053] In order to accelerate the subsequent batch power flow calculation of the plurality of power flow calculation example groups, the power flow calculation example groups can be preprocessed. Specifically, when processing the plurality of power flow calculation example groups, for each power flow calculation example group, a power flow calculation example can be randomly selected as a basic power flow calculation example, and the node admittance matrix and the B matrix structure can be generated according to the basic power flow calculation example. For example, according to the selected basic power flow calculation example, the node type, branch connection relationship, branch admittance value and other information of each node in the power flow calculation example group to which the basic power flow calculation example belongs can be determined, and then the structure of the node admittance matrix can be determined, including but not limited to the dimension, position and value of non-zero elements of the node admittance matrix, and the B matrix structure can be determined in combination with the structure of the node admittance matrix and the node type, including but not limited to the dimension, position and value of non-zero elements of the B matrix.
[0054] It should be noted that in the process of determining the node admittance matrix and the B matrix structure, the column offset and the row offset of the admittance matrix structure and the B matrix can be recorded in the form of a COO (Coordinate Format) matrix, and the position of each COO matrix in the CSR (Compressed Sparse Row) matrix can be recorded. In this way, only the non-zero elements in the matrix can be retained, thereby reducing the computational consumption of subsequent parallel batch power flow calculation. Further, parallel power flow calculation of multiple power flow calculation example groups can be realized by simultaneously executing power flow calculation tasks using multiple threads, such as simultaneously executing power flow calculation tasks using multiple GPUs, thereby improving the calculation efficiency.
[0055] Specifically, each thread is responsible for the power flow calculation task of one power flow calculation example group. For each power flow calculation example group, the initial voltage vector of each node in the power flow calculation example group is batch-constructed according to the voltage initial value of the bus and the motor in the power grid structure corresponding to each power flow calculation example, including the voltage amplitude and the voltage phase angle. Similarly, the node constraint vector of each node in the power flow calculation example group is batch-constructed according to the constraint information of the bus and the motor in the power grid structure corresponding to each power flow calculation example, such as the power value range, the voltage amplitude range, and other constraint information. Finally, the node admittance matrix, the B matrix structure, the initial voltage vector of each node, and the node constraint vector of each node are integrated together to generate the power flow solution matrix of the power flow calculation example group. For example, the COO matrix constructed based on the node admittance matrix and the B matrix structure in the above steps, and the position of the COO matrix in the CSR matrix are combined to further generate the CSR matrix numerical vector. The corresponding non-zero element values are extracted from the COO matrix, and the corresponding CSR matrix numerical vector is generated according to the requirements of the CSR matrix format to accelerate the generation of the power flow solution matrix of the subsequent power flow calculation example group. Then, the power flow solution matrix of the power flow calculation example group is generated according to the initial voltage vector, the node constraint vector, and the CSR matrix numerical vector.
[0056] After the power flow solution matrix is determined, the P-Q decomposition method can be used to batch-solve the power flow solution matrix. Specifically, the unbalanced power calculation and the forward generation backtracking calculation can be batch-performed on the power flow solution matrix until all the power flow calculation examples converge (for example, the difference between the active power value and the reactive power value of each node is less than a pre-set threshold, that is, the injected power and the outflow power of each node are balanced), or the maximum number of iterations is reached and the power flow calculation is stopped (at this time, the information of the power flow calculation example that does not converge needs to be recorded), thereby obtaining the first power flow calculation result of each power flow calculation example group.
[0057] In this embodiment, by simultaneously processing power flow calculation tasks of different power flow calculation example groups through multiple threads, the advantages of parallel processing can be well utilized, and multiple power flow calculation example groups can be efficiently and comprehensively processed to obtain the operating state information of the power system under different examples.
[0058] In one embodiment, the power flow calculation is performed on the power flow solution matrix to obtain the first power flow calculation result of the power flow calculation example group, including:
[0059] For each power flow calculation example in the power flow calculation example group, the P-Q decomposition method is used to perform power flow calculation on the power flow solution matrix to obtain the voltage vector of each node in the power flow calculation example. According to the voltage vector of each node, the injected power and the outflow power of each node are determined. If the difference between the injected power and the outflow power is greater than a preset difference threshold, the voltage vector is corrected according to the difference between the injected power and the outflow power. The step of determining the injected power and the outflow power of each node according to the voltage vector of each node is returned until the preset iteration end condition is met, the iteration is stopped, the power flow calculation result of the power flow calculation example is obtained, and the power flow calculation results of all power flow calculation examples are collected to obtain the first power flow calculation result of the power flow calculation example group.
[0060] Specifically, in the process of iterative calculation by the P-Q decomposition method, the voltage vector of each node is actually iteratively calculated. Starting from the initial voltage vector of each node, based on the basic principles of the power system and the node admittance matrix, the injected power (including active injected power and reactive injected power) and the outflow power of each node can be determined. For example, for a generator node, the injected power is the active power and reactive power generated by the generator; for a load node, the injected power is the active power and reactive power consumed by the load, and the outflow power is the power flowing to other nodes connected to the node.
[0061] After the injection power and the outflow power of each node are calculated, the difference between them needs to be compared. If the difference between the injection power and the outflow power is greater than a preset difference threshold, it indicates that the power condition corresponding to the current node voltage vector does not meet the power balance state under the stable operation requirement of the power system, and the power system has a power imbalance. At this time, the voltage vector of each node needs to be corrected according to the difference. The voltage vector can be corrected according to the difference between the injection power and the outflow power. For example, for active power imbalance, the correction amount of the phase angle of the voltage vector can be calculated by using the B' matrix related to the active power and the power difference, and then the phase angle part of the voltage vector is corrected. For reactive power imbalance, the correction amount of the amplitude of the voltage vector can be calculated by using the B'' matrix and the power difference, and the amplitude part of the voltage vector is adjusted, so as to obtain the updated voltage vector. After the voltage vector is corrected, the step of "determining the injection power and the outflow power of each node according to the voltage vector of each node" needs to be performed again to recalculate the new injection power and the outflow power of each node, and then it is continuously judged whether the difference between the new injection power and the outflow power of each node meets the requirement, and so on, until a preset iteration end condition is met, for example, the difference between the injection power and the outflow power of all nodes is less than or equal to the preset difference threshold, or the number of iterations reaches a preset maximum number of iterations, and the power flow calculation result of each power flow calculation example is obtained.
[0062] When the iteration end condition is met, the power flow calculation result of each power flow calculation example obtained at this time includes the voltage vector, the injection power, the outflow power and other information of each node. The power flow calculation results of each example are collected to obtain a first power flow calculation result set of the power flow calculation example group.
[0063] In this embodiment, the P-Q decomposition method is used for power flow calculation, iteration correction and finally obtaining the power flow calculation result. Through continuous adjustment and calculation, a more accurate first power flow calculation result set that is more consistent with the actual operation of the power system is obtained.
[0064] In one embodiment, as shown in FIG. 5, Figure 4 S500 includes:
[0065] S510, in the case that the out-of-limit node is a generator node and the reactive power value of the generator node exceeds the upper and lower limits, the node type of the generator node is adjusted from the PV node to the PQ node, and the reactive power value of the generator node is adjusted to a preset reactive power value.
[0066] S520, in the case that the out-of-limit node is a load node and the voltage amplitude of the load node exceeds the upper and lower limits, the node type of the load node is adjusted from the PQ node to the PV node, and the voltage amplitude of the load node is adjusted to a preset voltage amplitude.
[0067] S530, performing power flow calculation on the adjusted over-limit power flow calculation example to determine the voltage amplitude of the adjusted generator node and the reactive power value of the adjusted load node.
[0068] S540, in the case that the generator node is over the upper limit and the adjusted voltage amplitude is smaller than the voltage amplitude before adjustment, or in the case that the generator node is over the lower limit and the adjusted voltage amplitude is larger than the voltage amplitude before adjustment, restoring the node type and voltage amplitude of the generator node to the node type and voltage amplitude before adjustment.
[0069] S550, in the case that the load node is over the upper limit and the adjusted reactive power is smaller than the reactive power before adjustment, or in the case that the load node is over the lower limit and the adjusted reactive power is larger than the reactive power before adjustment, restoring the node type and reactive power value of the load node to the node type and reactive power value before adjustment.
[0070] Specifically, when the over-limit node is a generator node, and the reactive power value of the generator node is out of the specified upper and lower limit range, the node type of the generator node is adjusted from the original PV node to PQ node, and the out-of-limit value (i.e. the reactive power value) is modified to the preset reactive power value, which is an in-range value within the reactive power range of the generator node. Then, power flow calculation is performed on the over-limit power flow calculation example after the above adjustment, and the voltage amplitude of the adjusted generator node can be determined through the power flow calculation. If the generator node is originally over the upper limit of the reactive power value, and after adjusting the node type and performing power flow calculation again, the adjusted voltage amplitude is smaller than the voltage amplitude before adjustment, it means that the over-limit condition of the node has been solved, and at this time, the node type and voltage amplitude of the generator node need to be restored to the node type and voltage amplitude before adjustment. Similarly, when the generator node is over the lower limit of the reactive power value, and the adjusted voltage amplitude is larger than the voltage amplitude before adjustment, it means that the adjusted result makes the voltage amplitude fall back to a reasonable range, so the node type and voltage amplitude of the generator node also need to be restored to the state before adjustment.
[0071] If the out-of-limit node is a load node and the voltage amplitude of the load node exceeds the upper and lower limit range, the node type of the load node is adjusted from a PQ node to a PV node, and the voltage amplitude of the load node is adjusted to a preset voltage amplitude, which is also an in-range value within the voltage amplitude range of the load node. Similarly, the adjusted out-of-limit power flow calculation example containing the load node is subjected to power flow calculation. If the load node originally exceeds the upper limit of the voltage amplitude, and the adjusted reactive power is less than the unadjusted reactive power, it indicates that the adjustment solves the out-of-limit situation of the node, so it is necessary to restore the node type and the reactive power value of the load node to the node type and the reactive power value before the adjustment. If the load node is the lower limit of the voltage amplitude, and the adjusted reactive power value is greater than the unadjusted reactive power value, the node type and the reactive power value of the load node also need to be restored to the state before the adjustment, so as to restore the power system to a relatively more stable operating state.
[0072] In the embodiment, when the generator node and the load node in the power system are out of limit, the generator node and the load node are dynamically adjusted and restored, the node type is reasonably changed, the node parameters are adjusted, and the power system can maintain a stable, safe and efficient operating state as much as possible when facing various out-of-limit situations.
[0073] In one embodiment, S500 includes: performing power flow calculation on the adjusted out-of-limit power flow calculation example to obtain an adjusted power flow calculation result set; returning to the step of adjusting the node type of the out-of-limit node in the out-of-limit power flow calculation example until the adjusted out-of-limit power flow calculation example does not include the out-of-limit node, and determining the adjusted power flow calculation result set as the second power flow calculation result, when the adjusted power flow calculation result set represents that the adjusted out-of-limit power flow calculation example includes the out-of-limit node.
[0074] After the adjustment and recovery of the over-limit nodes in the over-limit power flow calculation examples, the power flow calculation is performed again on the adjusted over-limit power flow calculation examples. The specific process of the power flow calculation has been described in detail above and will not be repeated here. A new set of power flow calculation results is obtained, including the power flow calculation results corresponding to each adjusted over-limit power flow calculation example. Then, based on the adjusted set of power flow calculation results, it is further analyzed whether the adjusted power flow calculation examples still include over-limit nodes. If the adjusted power flow calculation examples still include over-limit nodes, it means that the adjustment has not completely solved the over-limit problem in the power system, and the step of adjusting the node type of the over-limit nodes in the over-limit power flow calculation examples needs to be returned to, and the corresponding node type adjustment and node parameter correction of the newly appeared over-limit nodes are performed again. Then, the power flow calculation is performed on the newly adjusted power flow calculation examples, and the process of adjustment and power flow calculation is repeated until the adjusted power flow calculation examples no longer include over-limit nodes. At this time, the obtained adjusted set of power flow calculation results can be determined as the second set of power flow calculation results.
[0075] In this embodiment, the over-limit power flow calculation examples in the power system are repeatedly adjusted and verified to eliminate the over-limit situation in the power system as much as possible, and finally the power flow calculation results that can make the power system stable are calculated.
[0076] In one embodiment, as shown in FIG. 1, Figure 5 S100 includes:
[0077] S110, a plurality of power flow calculation examples are obtained, and the plurality of power flow calculation examples are divided into different power flow calculation example groups according to the node type, the number of each type of node, and the number of branches of the power flow calculation examples.
[0078] In the process of power system power flow calculation related analysis, it is often necessary to consider various different operating scenarios, network structure changes or parameter setting conditions of the power system, so it is necessary to obtain a plurality of power flow calculation examples. Each of these power flow calculation examples represents a specific power system state, such as different load levels, generator output configurations, and power system conditions under network topology adjustment. Each power flow calculation example contains information such as node type, node number, and branch number.
[0079] Specifically, a plurality of power flow calculation examples are acquired, and the acquired power flow calculation examples are parsed, for example, the node types, the number of nodes, the number of branches and the like in the power flow calculation examples are extracted. The node types include but are not limited to balanced nodes, PV nodes and PQ nodes, and the like. Since different types of nodes have different known conditions and processing methods in power flow calculation, the nodes can be rearranged according to the node types, so that the order of the rearranged nodes is more in line with the logical flow of power flow calculation. Since the nodes have been rearranged, the node numbers and the like of the nodes may have changed, so the mapping relationship between the new and old node numbers needs to be maintained, for example, it is recorded that the original number 5 of the node corresponds to the new number 3 after rearrangement. When it is necessary to find a certain original parameter of the node or to write the calculation result back to the original data structure, the mapping relationship can be used for accurate positioning and operation. Similarly, the branches are connected to different nodes, and when the node numbers change due to rearrangement, the branch numbers connected thereto also need to be updated accordingly, and the mapping relationship between the new and old branches needs to be maintained.
[0080] Further, in order to improve the efficiency of subsequent batch power flow calculation, the power flow calculation examples can be grouped according to the node types, the number of each type of node and the number of branches. This is because the node types, the number of each type of node and the number of branches determine the power network structure of the power system, and the power network structure affects the structure of the related matrix in power flow calculation. Therefore, according to the node types, the number of each type of node and the number of branches, the plurality of power flow calculation examples are divided into different power flow calculation example groups. The dimensions, element distribution and calculation rules of the matrix for power flow calculation, such as node admittance matrix and B matrix, are the same or similar in the same power flow calculation example group, which facilitates unified matrix generation and batch power flow calculation operation.
[0081] In the embodiment, through the above preprocessing and grouping of the plurality of power flow calculation examples, subsequent batch power flow calculation work can be efficiently and accurately performed, so that the matrix construction, power flow calculation and result analysis and the like can be carried out in an orderly manner when processing a plurality of different power flow calculation examples, and the power flow calculation efficiency is improved.
[0082] In order to make the CPU and GPU hybrid architecture-based batch power flow solving method provided by the present application clearer, the following will be described in combination with the accompanying drawings. Figure 6 and One The detailed embodiments include the following steps:
[0083] A plurality of power flow calculation examples are obtained, and the plurality of power flow calculation examples are divided into different power flow calculation example groups according to node types of the power flow calculation examples, numbers of nodes of different types, and numbers of branches.
[0084] For each power flow calculation example group, a basic power flow calculation example is selected from the power flow calculation example group, a node admittance matrix and a B matrix structure of the power flow calculation example group are determined according to the basic power flow calculation example, and a power flow solution matrix of the power flow calculation example group is determined according to the node admittance matrix, the B matrix structure, preset initial voltage vectors of nodes in the power flow calculation example group, and preset node constraint vectors of the nodes.
[0085] For each power flow calculation example in the power flow calculation example group, a P-Q decomposition method is used to perform power flow calculation on the power flow solution matrix to obtain voltage vectors of nodes in the power flow calculation example.
[0086] According to the voltage vectors of the nodes, injected power and outflow power of the nodes are determined, and in a case where a difference between the injected power and the outflow power is greater than a preset difference threshold, the voltage vectors are corrected according to the difference between the injected power and the outflow power.
[0087] Returning to the step of determining the injected power and the outflow power of the nodes according to the voltage vectors of the nodes, until a preset iteration end condition is met, the iteration is stopped, a power flow calculation result of the power flow calculation example is obtained, power flow calculation results of the power flow calculation examples are collected, and a first power flow calculation result of the power flow calculation example group is obtained.
[0088] Parallelly, it is judged whether there is an out-of-limit power flow calculation example in the plurality of power flow calculation example groups, in a case where there is an out-of-limit power flow calculation example in the power flow calculation example group, a node type of an out-of-limit node in the out-of-limit power flow calculation example is adjusted, power flow calculation is performed on the adjusted out-of-limit power flow calculation example, and an adjusted power flow calculation result set is obtained.
[0089] In a case where the adjusted power flow calculation result set represents that the out-of-limit node is included in the adjusted power flow calculation example, the step of adjusting the node type of the out-of-limit node in the out-of-limit power flow calculation example is returned until the out-of-limit node is not included in the adjusted out-of-limit power flow calculation example.
[0090] The adjusted power flow calculation result set is determined as a second power flow calculation result set, the first power flow calculation result set is updated according to the second power flow calculation result set, and a target power flow calculation result set is obtained.
[0091] For example, taking the steps of the single-threaded processing performed by the CPU and the steps of the multi-threaded parallel processing performed by the GPU as examples, the batch power flow solving method based on the hybrid architecture of the CPU and the GPU provided in the present application can refer to the attached Figure 6The flowchart shown.
[0092] It should be understood that, although each step in the flowchart involved in each embodiment as described above is shown in sequence according to the direction of the arrow, these steps are not necessarily executed in the order indicated by the arrow. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least part of the steps in the flowchart involved in each embodiment as described above can include multiple steps or multiple stages, which are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily sequential, but can be alternately executed with at least part of other steps or steps or stages in other steps.
[0093] Based on the same inventive concept, the embodiments of the present application also provide a batch power flow solving device for implementing the batch power flow solving method described above. The implementation scheme for solving problems provided by the device is similar to the implementation scheme described in the above method, so the specific limitations in one or more batch power flow solving device embodiments provided below can refer to the limitations of the batch power flow solving method described above, which will not be repeated here.
[0094] In one embodiment, as shown in Figure 7 a CPU and GPU hybrid architecture-based batch power flow solving device 700 is provided, including a data acquisition module 710, a parallel power flow calculation module 720, an out-of-limit node processing module 730, and a result updating module 740.
[0095] The data acquisition module 710 is configured to acquire a plurality of power flow calculation case groups based on the CPU, and the power flow calculation cases in each power flow calculation case group correspond to the same power network structure.
[0096] The parallel power flow calculation module 720 is configured to perform parallel power flow calculation on the plurality of power flow calculation case groups based on the GPU to obtain a first power flow calculation result set, the first power flow calculation result set including first power flow calculation results of each power flow calculation case group, and to determine whether there is an out-of-limit power flow calculation case in the plurality of power flow calculation case groups based on the first power flow calculation result set, the out-of-limit power flow calculation case including an out-of-limit node.
[0097] The out-of-limit node processing module 730 is configured to, in the case that there is an out-of-limit power flow calculation case in the power flow calculation case group, adjust the node type of the out-of-limit node in the out-of-limit power flow calculation case based on the CPU, perform power flow calculation on the adjusted out-of-limit power flow calculation case to obtain a second power flow calculation result set, and the second power flow calculation result set includes second power flow calculation results of each adjusted out-of-limit power flow calculation case.
[0098] The result updating module 740 is configured to update the first power flow calculation result set based on the CPU to obtain a target power flow calculation result set, and the target power flow calculation result set includes target power flow calculation results of each power flow calculation case group.
[0099] In an embodiment, the batch power flow solving device 700 is further configured to, for each power flow calculation case group, select a basic power flow calculation case from the power flow calculation case group based on the CPU, and determine a node admittance matrix and a B matrix structure of the power flow calculation case group according to the basic power flow calculation case, and the parallel power flow calculation module 720 is further configured to perform a power flow calculation task for each power flow calculation case group in parallel based on the GPU to obtain the first power flow calculation result set, and the power flow calculation task for each power flow calculation case group is performed in the following steps: determining a power flow solving matrix of the power flow calculation case group according to the node admittance matrix, the B matrix structure, a preset initial voltage vector of each node in the power flow calculation case group, and a preset node constraint vector of each node, performing power flow calculation on the power flow solving matrix, and obtaining the first power flow calculation result of the power flow calculation case group.
[0100] In an embodiment, the parallel power flow calculation module 720 is further configured to, for each power flow calculation case in the power flow calculation case group, perform power flow calculation on the power flow solving matrix by using a P-Q decomposition method to obtain a voltage vector of each node in the power flow calculation case, determine injected power and outflow power of each node according to the voltage vector of each node, in a case where a difference between the injected power and the outflow power is greater than a preset difference threshold, correct the voltage vector according to the difference between the injected power and the outflow power, and perform again the step of determining the injected power and the outflow power of each node according to the voltage vector of each node until a preset iteration end condition is met, stop iteration, obtain a power flow calculation result of the power flow calculation case, and collect the power flow calculation results of the power flow calculation cases to obtain the first power flow calculation result of the power flow calculation case group.
[0101] In an embodiment, the out-of-limit node processing module 730 is further configured to, in a case where the out-of-limit node is a generator node and the reactive power value of the generator node exceeds the upper and lower limits, adjust the node type of the generator node from a PV node to a PQ node, and adjust the reactive power value of the generator node to a preset reactive power value; in a case where the out-of-limit node is a load node and the voltage amplitude of the load node exceeds the upper and lower limits, adjust the node type of the load node from a PQ node to a PV node, and adjust the voltage amplitude of the load node to a preset voltage amplitude; perform power flow calculation on the adjusted out-of-limit power flow calculation case; determine the voltage amplitude of the adjusted generator node and the reactive power value of the adjusted load node; in a case where the generator node exceeds the upper limit and the adjusted voltage amplitude is less than the voltage amplitude before adjustment, or in a case where the generator node exceeds the lower limit and the adjusted voltage amplitude is greater than the voltage amplitude before adjustment, restore the node type and the voltage amplitude of the generator node to the node type and the voltage amplitude before adjustment; in a case where the load node exceeds the upper limit and the adjusted reactive power is less than the reactive power before adjustment, or in a case where the load node exceeds the lower limit and the adjusted reactive power is greater than the reactive power before adjustment, restore the node type and the reactive power value of the load node to the node type and the reactive power value before adjustment.
[0102] In an embodiment, the out-of-limit node processing module 730 is configured to perform power flow calculation on the adjusted out-of-limit power flow calculation case to obtain an adjusted power flow calculation result set, and in a case where the adjusted power flow calculation result set indicates that the adjusted out-of-limit power flow calculation case includes the out-of-limit node, return to the step of adjusting the node type of the out-of-limit node in the out-of-limit power flow calculation case until the adjusted out-of-limit power flow calculation case does not include the out-of-limit node, and determine the adjusted power flow calculation result set as the second power flow calculation result set.
[0103] In an embodiment, the data acquisition module 710 is further configured to acquire a plurality of power flow calculation cases, and divide the plurality of power flow calculation cases into different power flow calculation case groups according to the node types of the power flow calculation cases, the number of each type of node, and the number of branches.
[0104] The above various modules in the batch power flow solving apparatus can be realized by software, hardware, or a combination thereof, in whole or in part. The above various modules can be embedded in or independent of a processor in a computer device in a hardware form, or stored in a memory in a computer device in a software form, so as to be called and executed by a processor to perform the operations corresponding to the above various modules.
[0105] In an embodiment, a computer device is provided, which can be a server, and an internal structure diagram of the computer device can be as shown in FIG. 8. Figure 8As shown in the figure. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through the system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capability. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data such as power flow calculation example group. The input / output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with the terminal outside through the network connection. The computer program is executed by the processor to realize a batch power flow solving method.
[0106] Those skilled in the art can understand that, Figure 8 The structure shown in the figure is only a block diagram of part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. The specific computer device can include more or fewer components than those shown in the figure, or combine certain components, or have a different component arrangement.
[0107] In one embodiment, a computer device is provided, including a memory and a processor, the memory stores a computer program, and the processor executes the computer program to realize the steps in the above batch power flow solving method embodiments.
[0108] In one embodiment, a computer readable storage medium is provided, which stores a computer program, and the computer program is executed by the processor to realize the steps in the above batch power flow solving method embodiments.
[0109] In one embodiment, a computer program product is provided, including a computer program, and the computer program is executed by the processor to realize the steps in the above batch power flow solving method embodiments.
[0110] It should be noted that the user information (including but not limited to user equipment information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present application are all information and data authorized by the user or authorized by all parties, and the collection, use and processing of related data need to comply with relevant laws, regulations and standards of relevant countries and regions.
[0111] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer readable storage medium, and when the computer program is executed, the processes of the above-mentioned embodiments of the methods can be included. Any reference to memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical storage, high-density embedded non-volatile memory, resistive memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration but not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM), etc. The database involved in the embodiments provided in the present application can include at least one of a relational database and a non-relational database. The non-relational database can include a distributed database based on a block chain, etc., without being limited thereto. The processor involved in the embodiments provided in the present application can be a general-purpose processor, a central processing unit, a graphics processing unit, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., without being limited thereto.
[0112] Any combination of the technical features of the above embodiments can be made. In order to make the description simple, all possible combinations of the technical features in the above embodiments are not described, however, as long as the combination of the technical features does not exist, it should be considered as the scope of the present application.
[0113] The above embodiments only express several implementation manners of the present application, and the description is more specific and detailed, but it should not be understood as a limitation on the scope of the patent of the present application. It should be pointed out that for ordinary skilled in the art, without departing from the concept of the present application, a number of modifications and improvements can be made, which are within the scope of protection of the present application. Therefore, the protection scope of the present application should be subject to the appended claims.
Claims
1. A batch power flow solving method based on a hybrid architecture of CPU and GPU, characterized in that, The method comprises: obtaining a plurality of power flow calculation example groups based on a CPU, the power flow calculation examples in the same power flow calculation example group having consistent power network structures; performing parallel power flow calculation on the plurality of power flow calculation example groups based on a GPU to obtain a first power flow calculation result set, the first power flow calculation result set including first power flow calculation results of each power flow calculation example group, and judging whether there are out-of-limit power flow calculation examples in the plurality of power flow calculation example groups based on the first power flow calculation result set, the out-of-limit power flow calculation examples including out-of-limit nodes; in the case where the out-of-limit power flow calculation examples exist in the power flow calculation example groups, adjusting the node types of the out-of-limit nodes in the out-of-limit power flow calculation examples based on a CPU, performing power flow calculation on the adjusted out-of-limit power flow calculation examples to obtain a second power flow calculation result set, the second power flow calculation result set including second power flow calculation results of each adjusted out-of-limit power flow calculation example; updating the first power flow calculation result set based on a CPU according to the second power flow calculation result set to obtain a target power flow calculation result set, the target power flow calculation result set including target power flow calculation results of each power flow calculation example group; the adjustment of the node types of the out-of-limit nodes in the out-of-limit power flow calculation examples comprises: in the case where the out-of-limit node is a generator node and the reactive power value of the generator node exceeds the upper and lower limits, adjusting the node type of the generator node from a PV node to a PQ node and adjusting the reactive power value of the generator node to a preset reactive power value; in the case where the out-of-limit node is a load node and the voltage amplitude of the load node exceeds the upper and lower limits, adjusting the node type of the load node from a PQ node to a PV node and adjusting the voltage amplitude of the load node to a preset voltage amplitude; performing power flow calculation on the adjusted out-of-limit power flow calculation examples to determine the voltage amplitude of the adjusted generator node and the reactive power value of the adjusted load node; in the case where the generator node exceeds the upper limit and the adjusted voltage amplitude is less than the voltage amplitude before adjustment, or in the case where the generator node exceeds the lower limit and the adjusted voltage amplitude is greater than the voltage amplitude before adjustment, restoring the node type and voltage amplitude of the generator node to the node type and voltage amplitude before adjustment; in the case where the load node exceeds the upper limit and the adjusted reactive power is less than the reactive power before adjustment, or in the case where the load node exceeds the lower limit and the adjusted reactive power is greater than the reactive power before adjustment, restoring the node type and reactive power value of the load node to the node type and reactive power value before adjustment.
2. The method of claim 1, wherein, Before the parallel power flow calculation on the plurality of power flow calculation example groups, the method further comprises: for each power flow calculation example group, selecting a basic power flow calculation example from the power flow calculation example group based on a CPU, and determining the node admittance matrix and B matrix structure of the power flow calculation example group according to the basic power flow calculation example; The GPU-based parallel power flow calculation is performed on the multiple power flow calculation case groups to obtain a first power flow calculation result set, including: The GPU-based parallel power flow calculation is performed on the multiple power flow calculation case groups to obtain a first power flow calculation result set, including: The power flow calculation task of each power flow calculation case group is executed in the following steps:
3. The method of claim 2, wherein, The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps:
4. The method of claim 1, wherein, The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps:
5. The method according to any one of claims 1 to 3, characterized in that, The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps:
6. A batch power flow solving device based on a hybrid architecture of CPU and GPU, characterized in that, The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed in the following steps: The power flow calculation task of each power flow calculation case group is executed a parallel power flow calculation module configured to perform parallel power flow calculation on the multiple power flow calculation case groups based on a GPU to obtain a first power flow calculation result set, wherein the first power flow calculation result set comprises first power flow calculation results of the multiple power flow calculation case groups, and determine whether there is an out-of-limit power flow calculation case in the multiple power flow calculation case groups based on the first power flow calculation result set, wherein the out-of-limit power flow calculation case comprises an out-of-limit node; an out-of-limit node processing module configured to, when there is the out-of-limit power flow calculation case in the multiple power flow calculation case groups, adjust a node type of the out-of-limit node in the out-of-limit power flow calculation case based on a CPU, perform power flow calculation on the adjusted out-of-limit power flow calculation case to obtain a second power flow calculation result set, wherein the second power flow calculation result set comprises second power flow calculation results of the adjusted out-of-limit power flow calculation case; a result updating module configured to update the first power flow calculation result set based on the second power flow calculation result set based on a CPU to obtain a target power flow calculation result set, wherein the target power flow calculation result set comprises target power flow calculation results of the multiple power flow calculation case groups; the out-of-limit node processing module is further configured to, when the out-of-limit node is a generator node and a reactive power value of the generator node exceeds an upper limit or a lower limit, adjust the node type of the generator node from a PV node to a PQ node and adjust the reactive power value of the generator node to a preset reactive power value; when the out-of-limit node is a load node and a voltage amplitude of the load node exceeds the upper limit or the lower limit, adjust the node type of the load node from the PQ node to the PV node and adjust the voltage amplitude of the load node to a preset voltage amplitude; perform power flow calculation on the adjusted out-of-limit power flow calculation case to determine a voltage amplitude of the adjusted generator node and a reactive power value of the adjusted load node; when the generator node exceeds the upper limit and the adjusted voltage amplitude is less than a voltage amplitude before adjustment, or when the generator node exceeds the lower limit and the adjusted voltage amplitude is greater than the voltage amplitude before adjustment, restore the node type and the voltage amplitude of the generator node to the node type and the voltage amplitude before adjustment; when the load node exceeds the upper limit and the adjusted reactive power is less than a reactive power before adjustment, or when the load node exceeds the lower limit and the adjusted reactive power is greater than the reactive power before adjustment, restore the node type and the reactive power value of the load node to the node type and the reactive power value before adjustment.
7. The apparatus of claim 6, wherein, The device is also used for: for each of the power flow calculation case group, based on the CPU, selecting a basic power flow calculation case from the power flow calculation case group, and determining a node admittance matrix and a B matrix structure of the power flow calculation case group according to the basic power flow calculation case; the parallel power flow calculation module is also used for performing a power flow calculation task for each power flow calculation case group in parallel based on the GPU, to obtain a first power flow calculation result set, and the power flow calculation task for each power flow calculation case group is executed in the following steps: according to the node admittance matrix, the B matrix structure, a preset initial voltage vector of each node in the power flow calculation case group, and a preset node constraint vector of each node, determining a power flow solution matrix of the power flow calculation case group, performing power flow calculation on the power flow solution matrix, and obtaining a first power flow calculation result of the power flow calculation case group.
8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that, The computer program, when executed by the processor, implements the steps of the method of any one of claims 1 to 5.
9. A computer-readable storage medium having stored thereon a computer program, characterized in that, The computer program, when executed by the processor, implements the steps of the method of any one of claims 1 to 5.
10. A computer program product comprising a computer program, characterized in that, The computer program, when executed by the processor, implements the steps of the method of any one of claims 1 to 5. The computer program, when executed by the processor, implements the steps of the method of any one of claims 1 to 5.
Citation Information
Patent Citations
Parallel computing method and system for CFD (Computational Fluid Dynamics)
CN104331271A
Static security analysis double-layer parallel method based on GPU-CUP heterogeneous computing platform
CN105576648A