Household optical storage all-in-one machine dynamic clustering method and system considering space-time factors

Through dynamic clustering methods that consider spatiotemporal factors, combined with KNN algorithm and DBSCAN algorithm, parameters are determined adaptively, and clustered by user optical storage all-in-one machines, the problem of ignoring spatial position and time factors in the existing technology is solved, and the problem of ignoring spatial position and time factors is realized More efficient energy management and grid operation efficiency.

CN119167118APending Publication Date: 2024-12-20NARI TECH CO LTD +3
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411361193.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-27
Publication Date
2024-12-20

AI Technical Summary

Technical Problem

The existing clustering method of household photo storage all-in-one machine ignores spatial location and time factors, resulting in low energy management and scheduling efficiency, making it difficult to achieve optimal energy utilization.

Method used

A dynamic clustering method that takes into account spatiotemporal factors is adopted to receive the distribution network node information, generate a feature matrix, and use the KNN algorithm to adaptively determine the parameters of the DBSCAN algorithm, perform clustering, and perform quadratic classification to obtain the final clustering result.

Benefits of technology

Achieve more precise dynamic clustering, improve the efficiency of household electricity management and energy storage resource allocation, optimize the grid operation efficiency and energy utilization economy, reduce the subjectivity of artificially set parameters, and enhance the robustness of the system and exception point handling capability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119167118A_ABST
    Figure CN119167118A_ABST
Patent Text Reader

Abstract

The invention discloses a household optical storage all-in-one machine dynamic clustering method and system considering space-time factors, and relates to the technical field of power system operation, and the method comprises the steps: receiving the node information of a power distribution network, including the number of nodes in the power distribution network, the distance between the nodes, and the branch unit impedance; light storage all-in-one machine user related data is obtained based on the power distribution network node information, the light storage all-in-one machine user related data is preprocessed, a feature matrix is generated, and the light storage all-in-one machine user related data comprises household light storage all-in-one machine equipment information, user position information, household power consumption data and photovoltaic power generation data; on the basis of the feature matrix, unknown parameter values of a density-based clustering method DBSCAN with noise points are obtained in a self-adaptive mode by applying a KNN algorithm, and the unknown parameter values comprise a neighborhood distance threshold value Eps and a neighborhood sample number threshold value MinPts with the distance of a certain sample being Eps; and clustering all household optical storage all-in-one machines according to eps and MinPts, classifying the clustered noise points, repeating the steps, and carrying out secondary clustering to obtain a final clustering result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of power system operation, and in particular to a method and system for dynamically clustering household photovoltaic and storage integrated devices taking time and space factors into consideration. Background Art

[0002] With the rapid development of renewable energy technology, solar photovoltaic systems have attracted widespread attention due to their clean and renewable characteristics. As a type of solar photovoltaic system, household photovoltaic energy storage integrated machine integrates photovoltaic power generation, energy storage and intelligent control functions, which can achieve self-sufficiency in household electricity and improve energy efficiency. However, existing clustering methods for household photovoltaic energy storage integrated machines often ignore the impact of spatial location on system performance, making it difficult to achieve optimal energy management and scheduling in practical applications. For example, there are significant differences in lighting conditions, grid access points and user electricity demand in different geographical locations, which have an important impact on the operating efficiency and economy of photovoltaic energy storage integrated machines. Summary of the invention

[0003] In order to solve the deficiencies mentioned in the above background technology, the purpose of the present invention is to provide a method and system for dynamic clustering of household photovoltaic and storage devices taking into account spatiotemporal factors, so as to realize dynamic clustering of household photovoltaic and storage devices with changing spatiotemporal factors.

[0004] In a first aspect, the purpose of the present invention can be achieved by the following technical solution: a method for dynamic clustering of household photovoltaic storage devices considering time and space factors, the method comprising the following steps:

[0005] Receiving distribution network node information, including: the number of nodes in the distribution network, the distance between nodes, and the unit impedance of branches;

[0006] Based on the distribution network node information, the photovoltaic and storage integrated machine user-related data is obtained, and the photovoltaic and storage integrated machine user-related data is preprocessed to generate a feature matrix, wherein the photovoltaic and storage integrated machine user-related data includes household photovoltaic and storage integrated machine equipment information, user location information, household electricity consumption data, and photovoltaic power generation data;

[0007] Based on the feature matrix, the unknown parameter values ​​of the density-based clustering method DBSCAN with noise points are adaptively obtained by using the KNN algorithm, including the neighborhood distance threshold eps and the threshold MinPts of the number of samples in the neighborhood of a certain sample with a distance of eps.

[0008] According to eps and MinPts, all household photovoltaic storage devices are clustered, and the clustered noise points are classified. The above steps are repeated for secondary clustering to obtain the final clustering results.

[0009] In combination with the first aspect, in certain implementations of the first aspect, the method further includes: the preprocessing of the user's electricity usage related data includes cleaning and normalizing all data of the user's electricity usage related data.

[0010] In combination with the first aspect, in some implementations of the first aspect, the method further includes: a process of constructing the feature matrix includes:

[0011]

[0012]

[0013] Among them, x i (t) represents the characteristic vector of the optical storage device at time t, is the load of user i, is the photovoltaic power generation power of node i, is the energy storage capacity, is the initial capacity of energy storage, is the resistance distance between the user's optical storage integrated device and the reference node, is the reactance distance between the location of user i’s integrated optical storage device and the reference node, and T is the total scheduling period.

[0014] In combination with the first aspect, in some implementations of the first aspect, the method further includes: the number of nodes is marked as K, the distance between nodes is marked as d ij , the process of adaptively obtaining unknown parameter values ​​of the density-based clustering method DBSCAN with noise points by using the KNN algorithm includes the following steps:

[0015] Calculate the Euclidean distance between the characteristic vectors of each household photovoltaic storage device, calculate the distance from each point to its k-th nearest neighbor and the distance from the k-th nearest neighbor, arrange the nearest neighbor distance data points from small to large and number them, draw a k-distance graph with the data point sequence number as the horizontal axis and the distance from the data point to its nearest neighbor as the vertical axis, and solve the first-order derivative of the obtained distance curve, select the function value with the largest adjacent derivative difference among all data points as the eps value in the DBSCAN clustering algorithm, and the k value as the MinPts value in the clustering algorithm.

[0016] In combination with the first aspect, in some implementations of the first aspect, the method further includes: the process of calculating the Euclidean distance between the feature vectors of each household photovoltaic storage device:

[0017]

[0018] Among them, distance ij,tis the Euclidean distance between the characteristic vectors of the household photovoltaic and storage integrated device at node i and node j at time t, where i,j∈{1,,2,…,N}, N is the number of photovoltaic and storage integrated device users within the low-voltage distribution network area, is the load of user i at time t, is the load of user j at time t, is the photovoltaic power generation of node i at time t, is the photovoltaic power generation of node j at time t, is the energy storage capacity of node i at time t, is the energy storage capacity of node j at time t, is the initial energy storage capacity of node i at time t, is the initial energy storage capacity of node j at time t, is the resistance distance between the location of the optical storage integrated device of user i and the reference node at time t, is the resistance distance between the location of user j's optical storage integrated device and the reference node at time t, is the reactance distance between the location of the optical storage integrated device of user i and the reference node at time t, is the reactance distance from the location of user j’s integrated optical storage device to the reference node at time t.

[0019] In combination with the first aspect, in some implementations of the first aspect, the method further includes: the process of calculating the distance from each point to its k-th nearest neighbor and the distance from the k-th nearest neighbor includes:

[0020] Calculate the distance from each point to its kth nearest neighbor. Assume that the Euclidean distance set of the feature vectors of all nodes of the household optical storage integrated machine is distance. Repeat the following formula k-1 times so that the number of sets obtained by iteration is reduced by k-1 compared with the previous one. The iteration formula is as follows:

[0021] ditance=distance-min{distance}

[0022] The kth point's nearest neighbor distance k for:

[0023] ditance k =min{distance}.

[0024] In combination with the first aspect, in some implementations of the first aspect, the method further includes: a calculation process of the eps and MinPts values:

[0025] Arrange and number the nearest neighbor distance data points from small to large, draw a k-distance graph with the data point number as the horizontal axis and the distance from the data point to its nearest neighbor as the vertical axis, and solve the first-order derivative of the distance curve:

[0026]

[0027] Where, d n ′ is the first-order derivative value of the nth data point, y n is the independent variable of the curve function of the nth data point in the k-distance graph, distance n,k is the curve variable of the nth data point in the k-distance graph;

[0028] The function value with the largest adjacent derivative difference among all data points is selected as the eps value in the DBSCAN clustering algorithm, and the k value is selected as the MinPts value in the clustering algorithm. The formula is as follows;

[0029] eps=distance n,k (y n )

[0030] MinPts=k

[0031] Where, distance n,k is the curve variable of the nth data point in the k-distance graph, y n The data point number value taken is the maximum value of the derivative difference between adjacent points max{d n ' +1 -d n ′} corresponds to the data point number.

[0032] In combination with the first aspect, in some implementations of the first aspect, the method further includes: a process of clustering all household photovoltaic storage devices and classifying the clustered noise points:

[0033] Select a point whose feature vector is the Euclidean distance of a household optical storage device that has not been visited. ij As a starting point, mark it as visited and add all its density-reachable neighbors to a set;

[0034] For each data point q in the set, calculate the density of all points in the neighborhood, and add the points whose density is greater than or equal to the threshold to the set. If q is a core point, add all points in its neighborhood to the set; if q is a boundary point, only add the points whose density is greater than or equal to the threshold in its neighborhood.

[0035] Repeat the above steps until all data points in the set have been visited;

[0036] For each unvisited data point, if it is not included in any set, it is marked as a noise point, otherwise, it is classified into the same cluster as its set;

[0037] Find the cluster point with the smallest distance between the noise point and its neighbors, and classify it into the cluster to ensure that all household photovoltaic storage devices belong to the divided cluster.

[0038] In a second aspect, in order to achieve the above-mentioned purpose, the present invention discloses a household photovoltaic storage integrated machine dynamic clustering system considering time and space factors, comprising:

[0039] A data acquisition module is used to receive the node information of the power distribution network, including: the number of nodes in the power distribution network, the distance between nodes, and the unit impedance of branches;

[0040] A data processing module is used to obtain the user-related data of the photovoltaic and storage integrated machine based on the distribution network node information, pre-process the user-related data of the photovoltaic and storage integrated machine and generate a feature matrix, wherein the user-related data of the photovoltaic and storage integrated machine includes household photovoltaic and storage integrated machine equipment information, user location information, household electricity consumption data and photovoltaic power generation data;

[0041] The adaptive update module is used to adaptively obtain the unknown parameter values ​​of the density-based clustering method DBSCAN with noise points based on the feature matrix by using the KNN algorithm, including the neighborhood distance threshold eps and the sample number threshold MinPts in the neighborhood of a certain sample with a distance of eps;

[0042] The dynamic clustering module is used to cluster all household photovoltaic storage devices according to EPS and MinPts, and classify the clustered noise points. The above steps are repeated for secondary clustering to obtain the final clustering result.

[0043] In another aspect of the present invention, in order to achieve the above-mentioned purpose, a terminal device is disclosed, including a memory, a processor, and a computer program stored in the memory and capable of running on the processor, wherein the memory stores a computer program capable of running on the processor, and when the processor loads and executes the computer program, a dynamic clustering method for household optical storage devices that considers time and space factors as described above is adopted.

[0044] Beneficial effects of the present invention:

[0045] The present invention achieves more accurate dynamic clustering by comprehensively considering the spatial location of household photovoltaic storage devices and time-related electricity consumption data and photovoltaic power generation data. This method can more effectively manage and dispatch household electricity consumption, optimize the allocation of energy storage resources, and thus improve the operating efficiency of the entire power grid and the economy of energy utilization.

[0046] By using the KNN algorithm to adaptively determine the key parameters of the DBSCAN clustering algorithm, namely the neighborhood distance threshold (eps) and the sample number threshold (MinPts), the present invention can adapt to clustering requirements under different scenarios and conditions. This adaptive mechanism reduces the subjectivity of artificial parameter setting and improves the robustness and accuracy of the clustering algorithm.

[0047] The present invention pays special attention to the classification of noise points after clustering, and ensures that all household photovoltaic storage devices can be reasonably divided into corresponding clusters through a secondary classification process. This processing not only improves the integrity of the clustering results, but also enhances the system's tolerance for abnormal points, further improving the robustness of the system. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0049] Figure 1 It is a schematic flow chart of the method of the present invention;

[0050] Figure 2 The present invention is a distribution network topology diagram of a low-voltage 43-node area in a certain province containing line and node information;

[0051] Figure 3 It is a schematic diagram of clustering of household photovoltaic and storage integrated devices after the dimension of the feature matrix is ​​reduced by the PCA method in the present invention;

[0052] Figure 4 This is a clustering effect diagram of household photovoltaic and storage integrated devices in the low-voltage distribution network of the present invention;

[0053] Figure 5 It is a schematic diagram of the system structure of the present invention. DETAILED DESCRIPTION

[0054] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0055] Embodiment 1:

[0056] The following is an introduction to the relevant terms involved in the embodiments of the present application:

[0057] The distribution network refers to the power grid that receives electric energy from the transmission network or regional power plants and distributes it locally or step by step according to voltage to various users through distribution facilities. It is composed of overhead lines, cables, towers, distribution transformers, disconnectors, reactive power compensators and some ancillary facilities, and plays an important role in distributing electric energy in the power grid.

[0058] like Figure 1 As shown, a method for dynamic clustering of household photovoltaic and storage integrated devices considering time and space factors includes the following steps:

[0059] S101: Receive distribution network node information, including: the number of nodes in the distribution network, the distance between nodes, and the branch unit impedance;

[0060] Specifically, the entire power distribution network is traversed, and the number of nodes in the power distribution network of this embodiment is counted as N=43, and the node number of the household photovoltaic storage integrated device is already Figure 2 The impedance of each branch also needs to be counted.

[0061] Consider an actual distribution network, where 43 distribution network nodes are numbered using natural numbers 1, 2, …, 43, and the distance between nodes is represented by dij. The unit length data is obtained based on the ij branch cable model, and Rij and Xij represent the actual resistance and actual reactance between the i-th node and the j-th node, where i, j∈1, 2, …, 43.

[0062] S102: acquiring user-related data of the photovoltaic and photovoltaic storage integrated machine based on the power distribution network node information, preprocessing the user-related data of the photovoltaic and photovoltaic storage integrated machine and generating a feature matrix, wherein the user-related data of the photovoltaic and photovoltaic storage integrated machine includes household photovoltaic and photovoltaic storage integrated machine equipment information, user location information, household electricity consumption data and photovoltaic power generation data;

[0063] The construction process of the feature matrix includes:

[0064]

[0065]

[0066] Among them, x i (t) represents the characteristic vector of the optical storage device at time t, is the load of user i, is the photovoltaic power generation power of node i, is the energy storage capacity, is the initial capacity of energy storage, is the resistance distance between the user's optical storage integrated device and the reference node, is the reactance distance between the location of user i’s integrated optical storage device and the reference node, and T is the total scheduling period.

[0067] S103: Based on the feature matrix, by using the KNN algorithm, the unknown parameter values ​​of the density-based clustering method DBSCAN with noise points are adaptively obtained, including the neighborhood distance threshold eps and the sample number threshold MinPts in the neighborhood of a certain sample whose distance is eps;

[0068] The process of adaptively obtaining unknown parameter values ​​of the density-based clustering method DBSCAN with noise points by using the KNN algorithm includes the following steps:

[0069] Calculate the Euclidean distance between the characteristic vectors of each household photovoltaic storage device, calculate the distance from each point to its k-th nearest neighbor and the distance from the k-th nearest neighbor, arrange the nearest neighbor distance data points from small to large and number them, draw a k-distance graph with the data point sequence number as the horizontal axis and the distance from the data point to its nearest neighbor as the vertical axis, and solve the first-order derivative of the obtained distance curve, select the function value with the largest adjacent derivative difference among all data points as the eps value in the DBSCAN clustering algorithm, and the k value as the MinPts value in the clustering algorithm.

[0070] The process of calculating the Euclidean distance between the feature vectors of each household's integrated photovoltaic and storage device:

[0071]

[0072] Among them, distance ij,t is the Euclidean distance between the feature vectors of the household photovoltaic storage integrated device of node i and node j at time t, where i,j∈{1,,2,…,25}, is the load of user i at time t, is the load of user j at time t, is the photovoltaic power generation of node i at time t, is the photovoltaic power generation of node j at time t, is the energy storage capacity of node i at time t, is the energy storage capacity of node j at time t, is the initial energy storage capacity of node i at time t, is the initial energy storage capacity of node j at time t, is the resistance distance between the location of the optical storage integrated device of user i and the reference node at time t, is the resistance distance between the location of user j's optical storage integrated device and the reference node at time t, is the reactance distance between the location of the optical storage integrated device of user i and the reference node at time t, is the reactance distance from the location of user j’s integrated optical storage device to the reference node at time t.

[0073] The process of calculating the distance from each point to its kth nearest neighbor and the distance from the kth nearest neighbor includes:

[0074] Calculate the distance from each point to its kth nearest neighbor. Assume that the Euclidean distance set of the feature vectors of all nodes of the household optical storage integrated machine is distance. Repeat the following formula k-1 times so that the number of sets obtained by iteration is reduced by k-1 compared with the previous one. The iteration formula is as follows:

[0075] ditance=distance-min{distance}

[0076] The kth point's nearest neighbor distance k for:

[0077] ditance k =min{distance}

[0078] Calculation process of eps and MinPts values:

[0079] Arrange and number the nearest neighbor distance data points from small to large, draw a k-distance graph with the data point number as the horizontal axis and the distance from the data point to its nearest neighbor as the vertical axis, and solve the first-order derivative of the distance curve:

[0080]

[0081] Where, d n ′ is the first-order derivative value of the nth data point, y n is the independent variable of the curve function of the nth data point in the k-distance graph, distance n,k is the curve variable of the nth data point in the k-distance graph;

[0082] The function value with the largest adjacent derivative difference among all data points is selected as the eps value in the DBSCAN clustering algorithm, and the k value is selected as the MinPts value in the clustering algorithm. The formula is as follows;

[0083] eps=distance n,k (y n )

[0084] MinPts=k

[0085] Where, distance n,k is the curve variable of the nth data point in the k-distance graph, y n The data point number value taken is the maximum value of the derivative difference between adjacent points max{d n ' +1 -d n ′} corresponds to the data point number.

[0086] S104: Cluster all household photovoltaic storage devices according to eps and MinPts, and classify the clustered noise points, repeat the above steps, perform secondary clustering, and obtain the final clustering result.

[0087] The basic idea of ​​the DBSCAN algorithm is to first select a data point as the starting point and calculate the density of all points in its neighborhood. If the density is greater than or equal to a pre-set threshold, then this point is a core point; if the density is less than the threshold, then this point is a noise point. For each core point, a neighborhood radius eps is used to calculate the density of all points in the neighborhood. If the density is greater than or equal to the threshold, then these points can form a cluster. For each boundary point, if it is in the neighborhood of a core point, then it can be classified into the cluster where the core point is located. If it is not in the neighborhood of any core point, then it is a noise point. In the end, all data points classified as clusters are clustering results, and all noise points are noise results. The specific process is as follows:

[0088] (1) Select a point whose characteristic vector of a household photovoltaic storage device has not been visited and whose distance is the Euclidean distance. ij As a starting point, mark it as visited and add all its density-reachable neighbors to a set.

[0089] (2) For each data point q in the set, calculate the density of all points in its neighborhood and add the points whose density is greater than or equal to the threshold to the set. If q is a core point, add all points in its neighborhood to the set. If q is a boundary point, only add the points whose density is greater than or equal to the threshold in its neighborhood.

[0090] (3) Repeat step (2) until all data points in the set have been visited.

[0091] (4) For each unvisited data point, if it is not included in any set, it is marked as a noise point. Otherwise, it is assigned to the same cluster as the set it belongs to.

[0092] (5) Find the cluster point with the smallest distance between the noise point and its neighbors, and classify it into the cluster, ensuring that all household photovoltaic storage devices belong to the divided cluster.

[0093] According to the above steps, combined with the distribution network line information, node user load information and household photovoltaic storage integrated machine operation data, the machine learning library (such as sklearn, pytorch, etc.) is used to solve the household photovoltaic storage integrated machine dynamic clustering strategy that takes into account the temporal and spatial factors.

[0094] In this embodiment, since the clustering feature vector is a high-dimensional matrix, the PCA is used for dimensionality reduction. The covariance matrix of the data is calculated and the eigenvalue decomposition is performed. Then, the principal components are extracted and the projection matrix is ​​constructed. The visual clustering effect is as follows: Figure 3 The actual clustering effect of household photovoltaic storage integrated devices in the low-voltage topology is shown in the figure, where the same color corresponds to a cluster in the visualized clustering result. In this clustering division, there are three clusters in total, and the reference node is selected as node "1". Figure 4 As shown in the figure, it can be seen from the clustering results that the resistance distance from the reference node has a certain influence on the spatial division of clusters, but it is also necessary to take into account the influence of parameters such as the user's power load curve, photovoltaic output curve and energy storage performance indicators.

[0095] Specifically, the present invention is further described below by way of embodiments:

[0096] In order to verify the effectiveness of the method proposed in the present invention, a comparative example is given, in which: Method 1: Adaptive change of DBSCAN unknown parameters is not performed using the KNN algorithm; Method 2: No second-stage clustering is performed on noise points. The results of the comparative clustering method are shown in Table 1 below:

[0097] Table 1 Comparison of cost and average load loss rate

[0098]

[0099] As can be seen from the table, method 1 is a scheme without adaptive changes in clustering parameters. Under the artificial custom parameters, the parameter eps may be selected too large or too small, resulting in unclear cluster division in typical scenarios. For example, only one cluster is divided in the low-voltage area, making cluster division meaningless. Method 2 is a scheme that does not perform secondary cluster division on noise points, which will cause some users to be excluded from cluster division, affecting the generation of further cluster control strategies.

[0100] Embodiment 2: In the second aspect, as Figure 5 As shown, in order to achieve the above-mentioned purpose, the present invention discloses a household photovoltaic storage integrated machine dynamic clustering system considering time and space factors, including:

[0101] The data acquisition module 11 is used to receive the node information of the power distribution network, including: the number of nodes in the power distribution network, the distance between nodes and the unit impedance of branches;

[0102] The data processing module 12 is used to obtain the photovoltaic and storage integrated machine user-related data based on the distribution network node information, pre-process the photovoltaic and storage integrated machine user-related data and generate a feature matrix, wherein the photovoltaic and storage integrated machine user-related data includes household photovoltaic and storage integrated machine equipment information, user location information, household electricity consumption data and photovoltaic power generation data;

[0103] The adaptive updating module 13 is used to adaptively obtain unknown parameter values ​​of the density-based clustering method DBSCAN with noise points based on the feature matrix by using the KNN algorithm, including the neighborhood distance threshold eps and the sample number threshold MinPts in the neighborhood of a certain sample whose distance is eps;

[0104] The dynamic clustering module 14 is used to cluster all household photovoltaic storage devices according to EPS and MinPts, and classify the clustered noise points, repeat the above steps, perform secondary clustering, and obtain the final clustering result.

[0105] Based on the same inventive concept, the present invention also provides a computer device, which includes: one or more processors, and a memory for storing one or more computer programs; the program includes program instructions, and the processor is used to execute the program instructions stored in the memory. The processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. It is the computing core and control core of the terminal, which is used to implement one or more instructions, specifically for loading and executing one or more instructions in a computer storage medium to implement the above method.

[0106] It needs to be further explained that, based on the same inventive concept, the present invention also provides a computer storage medium, on which a computer program is stored, and the computer program is executed by a processor to execute the above method. The storage medium can adopt any combination of one or more computer-readable media. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electrical, magnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of computer-readable storage media include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.

[0107] In the description of this specification, the description with reference to the terms "one embodiment", "example", "specific example", etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present disclosure. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.

[0108] The above shows and describes the basic principles, main features and advantages of the present disclosure. Those skilled in the art should understand that the present disclosure is not limited by the above embodiments, and the above embodiments and descriptions are only for explaining the principles of the present disclosure. Without departing from the spirit and scope of the present disclosure, the present disclosure may have various changes and improvements, and these changes and improvements fall within the scope of the present disclosure to be protected.

Claims

1. A method for dynamic clustering of household photovoltaic and storage devices considering time and space factors, characterized in that: The method comprises the following steps: Receiving distribution network node information, including: the number of nodes in the distribution network, the distance between nodes, and the unit impedance of branches; Based on the distribution network node information, the photovoltaic and storage integrated machine user-related data is obtained, and the photovoltaic and storage integrated machine user-related data is preprocessed to generate a feature matrix, wherein the photovoltaic and storage integrated machine user-related data includes household photovoltaic and storage integrated machine equipment information, user location information, household electricity consumption data, and photovoltaic power generation data; Based on the feature matrix, the unknown parameter values ​​of the density-based clustering method DBSCAN with noise points are adaptively obtained by using the KNN algorithm, including the neighborhood distance threshold eps and the threshold MinPts of the number of samples in the neighborhood of a certain sample with a distance of eps. According to eps and MinPts, all household photovoltaic storage devices are clustered, and the clustered noise points are classified. The above steps are repeated for secondary clustering to obtain the final clustering results.

2. According to the method of dynamic clustering of household photovoltaic and storage devices considering time and space factors as described in claim 1, it is characterized in that: The preprocessing of the optical fiber storage integrated machine user related data includes cleaning and normalizing all the optical fiber storage integrated machine user related data.

3. According to the method of dynamic clustering of household photovoltaic and storage devices considering time and space factors as described in claim 1, it is characterized in that: The construction process of the feature matrix includes: Among them, x i (t) represents the characteristic vector of the optical storage device at time t, is the load of user i, is the photovoltaic power generation power of node i, is the energy storage capacity, is the initial capacity of energy storage, is the resistance distance between the user's optical storage integrated device and the reference node, is the reactance distance between the location of user i’s integrated optical storage device and the reference node, and T is the total scheduling period.

4. According to the method of dynamic clustering of household photovoltaic and storage devices considering time and space factors as described in claim 1, it is characterized in that: The number of nodes is marked as K, and the distance between nodes is marked as d ij , the process of adaptively obtaining unknown parameter values ​​of the density-based clustering method DBSCAN with noise points by using the KNN algorithm includes the following steps: Calculate the Euclidean distance between the characteristic vectors of each household photovoltaic storage device, calculate the distance from each point to its k-th nearest neighbor and the distance from the k-th nearest neighbor, arrange the nearest neighbor distance data points from small to large and number them, draw a k-distance graph with the data point sequence number as the horizontal axis and the distance from the data point to its nearest neighbor as the vertical axis, and solve the first-order derivative of the obtained distance curve, select the function value with the largest adjacent derivative difference among all data points as the eps value in the DBSCAN clustering algorithm, and the k value as the MinPts value in the clustering algorithm.

5. According to claim 4, a method for dynamic clustering of household photovoltaic and storage devices taking into account time and space factors, characterized in that: The process of calculating the Euclidean distance between the characteristic vectors of each household photovoltaic storage device: Among them, distance ij,t is the Euclidean distance between the characteristic vectors of the household photovoltaic and storage integrated device at node i and node j at time t, where i,j∈{1,,2,…,N}, N is the number of photovoltaic and storage integrated device users within the low-voltage distribution network area, is the load of user i at time t, is the load of user j at time t, is the photovoltaic power generation of node i at time t, is the photovoltaic power generation power of node j at time t, is the energy storage capacity of node i at time t, is the energy storage capacity of node j at time t, is the initial energy storage capacity of node i at time t, is the initial energy storage capacity of node j at time t, is the resistance distance between the optical storage integrated device of user i and the reference node at time t, is the resistance distance between the location of user j's optical storage integrated device and the reference node at time t, is the reactance distance between the location of the integrated optical storage device of user i and the reference node at time t, is the reactance distance from the location of user j’s integrated optical storage device to the reference node at time t.

6. The method for dynamic clustering of household photovoltaic and storage devices considering time and space factors according to claim 5, characterized in that: The process of calculating the distance from each point to its k-th nearest neighbor and the distance from the k-th nearest neighbor includes: Calculate the distance from each point to its kth nearest neighbor. Assume that the Euclidean distance set of the feature vectors of all nodes of the household optical storage integrated machine is distance. Repeat the following formula k-1 times so that the number of sets obtained by iteration is reduced by k-1 compared with the previous one. The iteration formula is as follows: ditance=distance-min{distance} The kth point's nearest neighbor distance k for: ditance k =min{distance}。 7. The method for dynamic clustering of household photovoltaic and storage devices considering time and space factors according to claim 6, characterized in that: The calculation process of the eps and MinPts values ​​is: Arrange and number the nearest neighbor distance data points from small to large, draw a k-distance graph with the data point number as the horizontal axis and the distance from the data point to its nearest neighbor as the vertical axis, and solve the first-order derivative of the distance curve: Where, d n ′ is the first-order derivative value of the nth data point, y n is the independent variable of the curve function of the nth data point in the k-distance graph, distance n,k is the curve variable of the nth data point in the k-distance graph; The function value with the largest adjacent derivative difference among all data points is selected as the eps value in the DBSCAN clustering algorithm, and the k value is selected as the MinPts value in the clustering algorithm. The formula is as follows; eps=distance n,k (y n ) MinPts=k Where, distance n,k is the curve variable of the nth data point in the k-distance graph, y n The data point number value taken is the maximum value of the derivative difference between adjacent points max{d n ' +1 -d n ′} corresponds to the data point number.

8. The method for dynamic clustering of household photovoltaic and storage devices considering time and space factors according to claim 1, characterized in that: The process of clustering all household photovoltaic and storage devices and classifying the clustered noise points: Select a point whose feature vector is the Euclidean distance of a household optical storage device that has not been visited. ij As a starting point, mark it as visited and add all its density-reachable neighbors to a set; For each data point q in the set, calculate the density of all points in the neighborhood, and add points with density greater than or equal to the threshold to the set. If q is a core point, add all points in its neighborhood to the set. If q is a boundary point, only the points whose density in its neighborhood is greater than or equal to the threshold are added; Repeat the above steps until all data points in the set have been visited; For each unvisited data point, if it is not included in any set, it is marked as a noise point, otherwise, it is classified into the same cluster as its set; Find the cluster point with the smallest distance between the noise point and its neighbors, and classify it into the cluster to ensure that all household photovoltaic storage devices belong to the divided cluster.

9. A household photovoltaic storage integrated machine dynamic clustering system considering time and space factors, characterized in that: include: A data acquisition module is used to receive the node information of the power distribution network, including: the number of nodes in the power distribution network, the distance between nodes, and the unit impedance of branches; A data processing module is used to obtain the user-related data of the photovoltaic and storage integrated machine based on the distribution network node information, pre-process the user-related data of the photovoltaic and storage integrated machine and generate a feature matrix, wherein the user-related data of the photovoltaic and storage integrated machine includes household photovoltaic and storage integrated machine equipment information, user location information, household electricity consumption data and photovoltaic power generation data; The adaptive update module is used to adaptively obtain the unknown parameter values ​​of the density-based clustering method DBSCAN with noise points based on the feature matrix by using the KNN algorithm, including the neighborhood distance threshold eps and the sample number threshold MinPts in the neighborhood of a certain sample with a distance of eps; The dynamic clustering module is used to cluster all household photovoltaic storage devices according to EPS and MinPts, and classify the clustered noise points. The above steps are repeated for secondary clustering to obtain the final clustering result.

10. A terminal device, comprising a memory, a processor, and a computer program stored in the memory and capable of running on the processor, characterized in that: The memory stores a computer program that can be run on the processor. When the processor loads and executes the computer program, a dynamic clustering method for household photovoltaic storage devices taking into account time and space factors as described in any one of claims 1 to 8 is adopted.

Citation Information

Cited By

  • Method and system for monitoring running state of intelligent coffee machine

    CN119622606A