An energy flow direction monitoring method based on internet of things big data analysis

By generating unique records to be assigned through IoT big data analysis, the problem of non-unique electricity ownership in the park's comprehensive energy management has been solved, enabling accurate monitoring and verification of electricity consumption.

CN122153348BActive Publication Date: 2026-07-03AMIKEN (XIAMEN) POWER TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
AMIKEN (XIAMEN) POWER TECH CO LTD
Filing Date
2026-05-07
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

In the integrated energy management of the park, the existing technology cannot effectively solve the problem of establishing a unique record to be assigned for the incremental power released by the upper-level node in the scenario of shared bus and multi-source power supply. This leads to the distortion of energy flow monitoring results and the problem of the same power being repeatedly assigned.

Method used

By using IoT big data analytics, a unique record to be assigned is generated. The record is then assigned level by level along a closed connection, the remaining power is deducted, the connection changes are reconstructed, and the flow direction is closed and spliced ​​together to ensure that each unit of power has a unique attribution chain and avoid duplicate assignments.

Benefits of technology

It enables unique recording of electricity ownership under shared bus and multi-source power supply conditions, improving the accuracy and verifiability of energy flow monitoring results and reducing interference from duplicate correspondence.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122153348B_ABST
    Figure CN122153348B_ABST
Patent Text Reader

Abstract

This invention discloses an energy flow monitoring method based on IoT big data analysis, specifically relating to the field of energy monitoring and data processing. The method includes acquiring the incoming and outgoing electricity, point number, upstream number, downstream number, switch value, and time of each metering point within the same monitoring period; organizing the connected upstream and downstream relationships into closed connections; converting the time to the same time base; and outputting a periodic point set. This invention generates a unique record to be assigned for the electricity released by the upstream node, and performs hierarchical assignment, remaining electricity deduction, connection change reconstruction, and flow closure splicing along the closed connection to downstream nodes. This addresses the problem of distorted energy flow monitoring results caused by the same segment of released electricity being repeatedly matched with different downstream changes under shared bus and multi-source power supply conditions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of energy monitoring and data processing technology, and more specifically, to a method for monitoring energy flow based on Internet of Things big data analysis. Background Technology

[0002] In the process of integrated energy management in the park, the current focus is usually on clarifying the energy destination between each energy supply unit, transmission node and energy user. The common approach is to collect the metering information and operating status of each node by smart meters, edge gateways, switch status acquisition units and equipment control interfaces, and then combine the network connection relationship, record the arrival time sequence and the corresponding relationship between node changes to restore the energy transfer relationship between each node under the cloud collaborative architecture.

[0003] For park energy networks that simultaneously connect to mains power, photovoltaics, energy storage, and diesel backup power, multiple power sources supply energy to multiple branches such as air compressor groups, cooling stations, data centers, and production lines via the same busbar. The equipment on each branch may start and stop at close intervals, and energy storage devices may frequently switch between charging and discharging states. On-site monitoring is required to be continuous and cannot rely on manual verification of each item. Under these conditions, the existing processing method is prone to situations where the incremental power released by the upper-level node at the same time period is repeatedly corresponded to different downstream changes. Specifically, multiple flow records are formed in the system, each of which can be valid. However, the recipient, loss attribution, and settlement results of these records are inconsistent. Furthermore, the same branch power is repeatedly counted, the same part of the power destination cannot be closed, and the flow records before and after the switch are directly connected and displayed in series, which are results that can be directly verified. The root cause is that the existing solution reverses the flow relationship based on the changes in node values, but does not establish a unique attribution process that cannot be repeatedly occupied for each incremental power released by the upper-level node.

[0004] Therefore, the technical problem to be solved by this application is: how to establish a unique record to be assigned to the incremental power released by the upper-level node in the scenario of shared bus and multi-source power supply under cloud collaboration, and determine the final destination through downstream step-by-step verification, so as to avoid the same power being repeatedly assigned and causing the energy flow monitoring results to be distorted. Summary of the Invention

[0005] To overcome the aforementioned deficiencies of the prior art, embodiments of the present invention provide an energy flow monitoring method based on Internet of Things big data analysis. This method generates a unique record to be assigned to the electricity released by the upstream node, and performs hierarchical assignment, deduction of remaining electricity, reconstruction of connection changes, and flow closure splicing on the downstream nodes along the closed connection. This solves the problem that the same segment of released electricity is repeatedly matched with different downstream changes under conditions of shared bus and multi-source power supply, resulting in distorted energy flow monitoring results.

[0006] To achieve the above objectives, the present invention provides the following technical solution: a method for monitoring energy flow based on Internet of Things big data analysis, comprising:

[0007] S1. Obtain the incoming power, outgoing power, point number, upstream number, downstream number, switch value and time of each metering point in the same monitoring cycle, organize the connected upstream and downstream relationships into closed connections, convert the time to the same time base, and output the cycle point set.

[0008] S2. Perform a subtraction operation on the output and input of each metering point in the periodic point set, determine the difference that is greater than zero as the released power, and generate a unique record to be assigned according to the release point number, released power, remaining power, monitoring cycle and closed connection, and output the set to be assigned.

[0009] S3. For each unique record to be assigned in the set to be assigned, extract the next downstream point by closed connection, calculate the power capacity of each downstream point, write the assigned sub-record from the current point to the corresponding downstream point in the order of time and point number, and deduct the remaining power capacity at the same time, and output the updated set to be assigned.

[0010] S4. For the only record to be assigned in the updated assignment set with a remaining power greater than zero, write the last downstream point as the current point and continue assignment; when the first different downstream point appears in the downstream sequence of the current and next cycles, stop the original assignment, and reconstruct the unique record to be assigned according to the remaining power at the corresponding time, the current point, and the changed closed connection, and output the closed assignment set.

[0011] S5. For the only record to be assigned in the closed set where the remaining power is zero, the record is spliced ​​together according to the release point number, the preceding and following point numbers in each assigned sub-record, the power of the sub-record, and the writing order to generate a formal energy flow record, and the energy flow monitoring result is output.

[0012] In a preferred embodiment, S1 includes:

[0013] S1-1. Extract the incoming power, outgoing power, point number, upstream number, downstream number, switch value and time within the same monitoring period by point number, sort them in ascending order by time and take the first time as the reference time of the point, and output the point record.

[0014] S1-2. Subtract the corresponding reference time from the time recorded at each point to obtain the periodic time difference with the reference time as the same time reference, and extract the upstream and downstream numbers where the switch value is turned on, and output the closed connection.

[0015] S1-3. Write the periodic time difference, input power, output power, point number, and closed connection from each point record into the same record structure according to the point number, and output the periodic point set.

[0016] In a preferred embodiment, S2 includes:

[0017] S2-1. Subtract the output and input quantities of each metering point in the periodic point set, determine the metering points with a difference greater than zero as release points, and determine the difference as the release quantity of the corresponding release point, and output the release point set;

[0018] S2-2. For each release point in the release point set, take the release point number as the current point number, extract the downstream number with the current point number as the upstream number from the closed connection, and write it into the reachable downstream sequence in the extraction order. Then replace the downstream number with the new current point number and continue extraction until there is no downstream number with the current point number as the upstream number in the closed connection or the extracted downstream number has been written into the reachable downstream sequence. Output the reachable downstream sequence set.

[0019] In a preferred embodiment, S2 further includes:

[0020] S2-3. Assign the released power of each release point in the reachable downstream sequence set to the remaining power, and concatenate the release point number, monitoring period and the writing order in the reachable downstream sequence to generate a record number, and output the base record set to be assigned.

[0021] S2-4. Write the release point number, released power, remaining power, monitoring cycle, closed connection, reachable downstream sequence and record number of the base record set to be assigned into the same record structure to generate a unique record to be assigned and output the set to be assigned.

[0022] In a preferred embodiment, S3 includes:

[0023] S3-1. Extract the current point, remaining power, and closed connection from each unique record to be assigned from the set of unassigned records. Extract the next downstream point with the current point as the upstream number from the set of periodic points. Subtract the incoming power and outgoing power of each next downstream point. If the difference is greater than zero, write the difference as the power received by the next downstream point. Otherwise, write the power received by the next downstream point as zero and output the candidate assignment set.

[0024] S3-2. For each candidate attribution item in the candidate attribution item set, check whether the received electricity is greater than zero, check whether the time difference obtained by subtracting the time of the current point from the time of the next downstream point is greater than or equal to zero, and check whether the next downstream point has already appeared in the existing attribution path of the corresponding unique record to be attributed; when the received electricity is greater than zero, the time difference is greater than or equal to zero, and the next downstream point has not appeared in the existing attribution path, write the candidate attribution item as an attributable item; otherwise, write the candidate attribution item as a fallback item and output the attribution item set.

[0025] In a preferred embodiment, S3 further includes:

[0026] S3-3. For the attributable items in the attribution item set, first sort them in ascending order by time difference, then in descending order by received electricity, and finally in ascending order by point number. Perform attribution calculations sequentially according to the sorting results. When the remaining electricity is greater than or equal to the received electricity of the current attributable item, the received electricity is determined as the attributable electricity, and the attributable electricity is subtracted from the remaining electricity. When the remaining electricity is less than the received electricity of the current attributable item and the remaining electricity is greater than zero, the remaining electricity is determined as the attributable electricity, and the remaining electricity is reduced to zero. When the remaining electricity is equal to zero, stop the attribution calculation of subsequent attributable items, rewrite the attributable items that did not participate in the attribution calculation as rollback items, and output the attribution update record set.

[0027] S3-4. Perform write-back based on each unique pending record in the ownership update record set. When there is ownership of electricity in this round, generate ownership sub-records according to the current point, the corresponding next-level downstream point, ownership electricity, and the writing order. Replace the next-level downstream point in the last generated ownership sub-record with the new current point, and write back the deducted remaining electricity, the rollback item, and the ownership sub-record to the corresponding unique pending record. When there is no ownership of electricity in this round, keep the original current point unchanged, and write back the remaining electricity and the rollback item to the corresponding unique pending record. When the remaining electricity is equal to zero, output the updated pending set.

[0028] In a preferred embodiment, S4 includes:

[0029] S4-1. Extract the unique record to be assigned from the updated set of records to be assigned, which has a remaining power greater than zero. Extract the last generated sub-record of each unique record to be assigned. Write the downstream point of each last generated sub-record as the current point of the corresponding unique record to be assigned. Output the set of records to be assigned.

[0030] S4-2. Extract the closed connections of each current point in the current monitoring period and the closed connections of the next monitoring period from the recurrence record set. Extract downstream points one by one from the current point to form the downstream sequence before the change and the downstream sequence after the change. Compare the downstream points in the two downstream sequences bit by bit in the writing order. When all downstream points are the same, write the recurrence mark. When the first different downstream point appears, write the recording time corresponding to the different downstream point as the change time, and write the downstream sequence after the change as the closed connection after the change. Output the connection determination set.

[0031] In a preferred embodiment, S4 further includes:

[0032] S4-3. For the only record to be assigned in the connection decision set with the continued assignment mark, keep the current point, remaining power and closed connection unchanged; for the only record to be assigned in the connection decision set with the change time, stop continuing to assign according to the downstream sequence before the change, and write the remaining power, current point and closed connection after the change time as the reconstruction content, and output the reconstruction record set.

[0033] S4-4. For each unique record to be assigned in the reconstructed record set, extract the next-level downstream point in the corresponding closed connection with the current point as the upstream number. When the next-level downstream point is extracted, write the unique record to be assigned back to update the set to be assigned and continue to perform the next-level assignment. Otherwise, write the existing assigned sub-record into the closed set to be assigned and output the closed set to be assigned.

[0034] In a preferred embodiment, S5 includes:

[0035] S5-1. Extract the unique record to be assigned from the closed assignment set where the remaining power is zero, and extract the release point number and assignment sub-record from each unique record to be assigned. Arrange the assignment sub-records in the order of writing and output the assignment fragment set.

[0036] S5-2. For adjacent sub-records in the set of sub-records, extract the last point number of the previous sub-record and the first point number of the next sub-record and perform an equality comparison. When the comparison results are equal, write the adjacent sub-records into the same splice segment. Otherwise, write the adjacent sub-records into the two adjacent splice segments respectively, and output the splice segment set.

[0037] In a preferred embodiment, S5 further includes:

[0038] S5-3. For each splicing segment in the splicing segment set, perform sequential splicing according to the release point number, the preceding and following point numbers in each assigned sub-record, the sub-record electricity level, and the writing order, and perform cumulative calculation on the sub-record electricity level in each assigned sub-record to generate a formal energy flow record and output the flow record set.

[0039] S5-4. For each formal energy flow record in the flow record set, generate a result record according to the release point number, the preceding and following point numbers in each subordinate sub-record, the sub-record electricity amount, and the writing order, and output the energy flow monitoring result.

[0040] The technical effects and advantages of this invention are as follows:

[0041] 1. By generating a unique record to be assigned based on the release point number, released power, remaining power, and closed connection, and then combining it with downstream step-by-step verification, the same upstream released power can be mapped to a single attribution chain, which can relatively suppress duplicate mapping in scenarios with shared bus and multiple sources, thereby improving the problem of distortion in energy flow monitoring results.

[0042] 2. By performing point number merging, time conversion and conduction relationship extraction on the original records, a set of periodic points with consistent time base and clear connection relationship is formed, which can provide a unified input for the calculation of released power and downstream extraction, and relatively reduce the interference caused by the mixing of original records to subsequent flow direction judgment.

[0043] 3. By extracting the downstream sequence along the closed connection and synchronously writing the release point number as the current point to generate a unique record to be assigned, each released electricity can have a clear starting point, reachable range and record identifier from the time of generation, thereby relatively improving the problems of unclear release source and difficulty in distinguishing multiple records to be assigned;

[0044] 4. By sequentially performing acceptance checks, timing checks, and existing attribution path checks on the next downstream point, and then completing the attribution calculation according to the time difference, the received electricity volume, and the point number, the allocation of attribution electricity volume can have a sequential basis and path constraints, which can relatively suppress reverse attribution, duplicate attribution, and over-attribution.

[0045] 5. By comparing the downstream sequence corresponding to the current point in the current monitoring cycle and the next monitoring cycle, and stopping the original attribution when the first different downstream point appears, and reconstructing the unique record to be assigned according to the closed connection after the change, the unassigned power after the connection change can continue to be processed along the actual conduction path, thereby alleviating the problem of the flow direction records before and after the switch being directly connected in series.

[0046] 6. By forming splicing segments from the sub-records of the closed set of attribution according to the continuous relationship of the point numbers before and after, and generating formal energy flow records and energy flow monitoring results accordingly, the output results can simultaneously retain the release point number, path sequence and the corresponding relationship of the sub-record electricity, thereby improving the verifiability of the flow results and the value of settlement reference. Attached Figure Description

[0047] Figure 1 This is a flowchart of the method steps of the present invention. Detailed Implementation

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

[0049] Refer to the instruction manual appendix Figure 1 The present invention provides a method for monitoring energy flow based on Internet of Things (IoT) big data analysis, comprising:

[0050] S1. Obtain the incoming power, outgoing power, point number, upstream number, downstream number, switch value and time of each metering point in the same monitoring cycle, organize the connected upstream and downstream relationships into closed connections, convert the time to the same time base, and output the cycle point set.

[0051] In this implementation, the original records reported by each metering point within the same monitoring period are first merged, time-unified, and continuity relationships extracted. Then, the sorted time field, power field, and connection field are written into a unified record structure to form a set of periodic points directly used for subsequent power release calculation and attribution calculation. It should be noted that the point number is used to uniquely identify a metering point, and the same original record corresponds to only one point number. Incoming and outgoing power refer to the periodic power values ​​obtained by the metering point within the current monitoring period using the same metering caliber. The upstream and downstream numbers represent the direct connection relationships recorded by the metering point within the current monitoring period. The switch value indicates whether the connection relationship is in a conductive state. The time indicates the collection time of the original record. To ensure time comparability between subsequent points, a reference time is first determined within the point number range, and then the times of each record under the same point number are uniformly converted into periodic time differences. To ensure a clear basis for subsequent connection extraction, closed connections are generated from the continuity records and written into the unified record structure along with the same point power field.

[0052] The processing procedure is as follows:

[0053] First, the original records for the current monitoring period are merged according to the point number. After collecting the incoming and outgoing electricity, point number, upstream number, downstream number, switch value, and time from each metering point for the current monitoring period, records with empty point numbers, missing times, or missing both incoming and outgoing electricity are first removed. The remaining records are grouped by point number, so that all records corresponding to the same point number enter the same processing unit. Then, the records in each point number group are sorted in ascending order by time, with only the original time value used as the comparison basis during sorting. After sorting, the time of the first record in the record group is taken as the reference time of that point in the current monitoring period. After this processing, each point number corresponds to one point record, which retains the point number, all sorted original records for that point, and the reference time of that point for subsequent time conversion and connection extraction.

[0054] Subsequently, a unified conversion is performed on the time field in each point record, and closed connections are extracted from the conduction records. For each original record in a point record, the time of the original record is subtracted from the reference time of the point, and the difference is written as the periodic time difference of the original record. When there is only one original record in a point, the periodic time difference of the record is written as zero. In this way, all records in the same point are converted into periodic time differences with the corresponding reference time as a unified reference. At the same time, the switch value of each original record in the point record is checked. When the switch value indicates conduction, the upstream and downstream numbers in the original record are extracted, and a closed connection item is generated in the direction from upstream to downstream. When there are multiple conduction records in the same point, closed connection items are generated for each conduction record and all are retained without merging. When the switch value does not indicate conduction, no closed connection item is generated. The closed connections obtained in this way only reflect the direct connection relationship that is actually in the conduction state in the current monitoring period, and the upstream and downstream relationship corresponding to the point can be obtained accordingly in the future.

[0055] After completing time conversion and connection extraction, the same-point fields are written into a unified record structure to form a periodic point set. Specifically, for each point number, the periodic time difference, incoming power, outgoing power, and point number corresponding to each original record in the point record are read, and all closed connection items generated for that point are associated with the above fields and written into the same record structure according to the point number. This record structure at least includes the point number, monitoring period, periodic time difference, incoming power, outgoing power, and the closed connection items associated with that point, so that subsequent processing can directly obtain the periodic power field of that point and directly obtain the conduction connection relationship corresponding to that point in the current monitoring period. After all point numbers are written, all record structures are summarized according to point numbers to form a periodic point set, which serves as the input data for subsequent power release calculation and attribution calculation.

[0056] Through the above processing, the original records reported separately within the same monitoring period are organized into a set of periodic points with consistent field caliber, consistent time base, and clear connection relationship. This avoids the loss of basis for subsequent power difference calculation and downstream extraction when using the original records directly due to the mixing of multiple records at the same point, the inability to directly compare the original times, and the failure to extract the conduction relationship separately.

[0057] In practical applications: For example, in a park power distribution network, metering point A01 sequentially reports three records within a certain monitoring cycle, with times of 08:00:02, 08:00:05, and 08:00:09 respectively. The corresponding input power, output power, and switch value change with sampling updates. During processing, the three records are first arranged in ascending order of time, and 08:00:02 is taken as the base time for A01. Then, 08:00:02 is subtracted from the times of the other two records to obtain the cycle. The time difference is 3 seconds and 7 seconds. If the switch values ​​of two records indicate that the circuit is on, and the corresponding upstream and downstream numbers are M01 to A01 and A01 to B03 respectively, then two closed connections, M01 to A01 and A01 to B03, are generated respectively. Then, the cycle time difference, incoming power, outgoing power, point number, and the above closed connection items corresponding to A01 are written into a unified record structure. After processing other metering points in the same way, a cycle point set covering the current monitoring cycle can be formed for direct use in subsequent processing.

[0058] S2. Perform a subtraction operation on the output and input of each metering point in the periodic point set, determine the difference that is greater than zero as the released power, and generate a unique record to be assigned according to the release point number, released power, remaining power, monitoring cycle and closed connection, and output the set to be assigned.

[0059] In this embodiment, metering points that release electricity within the current monitoring period are first identified from the periodic point set. Then, a downstream sequence is extracted along a closed connection around each release point. The released electricity, remaining electricity, monitoring period, and downstream sequence are written into a unified record structure to form a set to be assigned that is directly used in subsequent assignment calculations. It should be noted that a release point refers to a metering point where the outgoing electricity is greater than the incoming electricity within the current monitoring period; the released electricity is the difference between the outgoing and incoming electricity of the metering point within the current monitoring period; the downstream sequence is a sequence of downstream point numbers extracted sequentially along a closed connection starting from the release point number; the remaining electricity is taken as the initial value of the released electricity corresponding to the release point when generating the set to be assigned, and is subsequently deducted sequentially during assignment calculations; the record number is used to distinguish the records to be assigned corresponding to different release points within the same monitoring period.

[0060] The implementation process includes the following steps:

[0061] First, release identification is performed on each metering point within the periodic point set. Specifically, the point number, input power, and output power of the periodic point set are read one by one. For each metering point, the output power is subtracted from the input power to obtain the power difference of that metering point in the current monitoring period. When the difference is greater than zero, the metering point is identified as a release point, and the difference is written as the release power corresponding to that release point. When the difference is equal to zero or less than zero, the metering point is not written into the release point set. After this processing, each record in the release point set contains at least the release point number, the release power, and the monitoring period. The direct calculation method of subtracting the input power from the output power is used here because the previous processing has unified the input power and output power to the same monitoring period and the same metering caliber. The difference result can directly reflect the net power output of that metering point in the current monitoring period.

[0062] Subsequently, reachable downstream sequences are extracted around each release point. Specifically, for each release point in the release point set, the release point number of that release point is first written as the current point number, and then the downstream number with the current point number as the upstream number is extracted from the closed connection. When only one downstream number is extracted, the downstream number is written into the reachable downstream sequence according to the current extraction order, and the downstream number is replaced with a new current point number to continue extraction. When multiple downstream numbers are extracted, they are written in ascending order of the downstream number, and each downstream number is used as a new current point number to continue extraction, so that different conduction branches form their own reachable downstream sequences. When there is no downstream number with the current point number as the upstream number in the closed connection, the extraction of that sequence is stopped. When a newly extracted downstream number has already appeared in the current reachable downstream sequence, the extraction of that sequence is also stopped to avoid circular writing within the same sequence. After this processing, each release point can correspond to one or more reachable downstream sequences. The point numbers in the reachable downstream sequences are arranged according to the actual extraction order, and the subsequent attribution calculation is directly performed layer by layer downward according to this order and connection relationship.

[0063] After obtaining the reachable downstream sequences, a base record to be assigned is established for each sequence. Specifically, for each reachable downstream sequence in the set of reachable downstream sequences, the released power of the corresponding release point is first read, and the released power is directly assigned to the initial value of the remaining power of the corresponding record. Then, the release point number and monitoring period corresponding to the release point are read, and a record number is generated by concatenating the release point number, monitoring period, and the generation order of the reachable downstream sequence. If multiple reachable downstream sequences are generated for the same release point number in the same monitoring period, different sequence order values ​​are assigned according to the generation order of the reachable downstream sequences to ensure that different record numbers can be distinguished from each other. After this processing, each record in the set of base records to be assigned contains at least the release point number, released power, remaining power, monitoring period, reachable downstream sequence, and record number, which can reflect a path to be assigned for the release point in the current monitoring period and its initial power status.

[0064] After completing the above field organization, the base records to be assigned are written into a unified record structure to generate unique records to be assigned. Specifically, the release point number, released power, remaining power, monitoring period, closed connection, reachable downstream sequence, and record number of each record in the base record set to be assigned are read one by one and written into the same record structure in a unified field order. During writing, the release point number is synchronously written as the initial value of the current point so that subsequent assignment calculations can directly extract the next layer of downstream points from the current point. At the same time, the closed connection corresponding to the release point is retained so that subsequent processing does not need to return to the period point set to re-retrieve the connection relationship. After all the base records to be assigned are written, a set to be assigned is generated. Each unique record to be assigned in the set corresponds to a reachable downstream sequence and an initial remaining power of a release point in the current monitoring period. Subsequent assignment calculations directly use this as input.

[0065] Through the above processing, metering points with only net release characteristics in the periodic point set are screened as release points and further converted into a set to be assigned with reachable downstream sequences and initial remaining electricity, thus providing clear input for subsequent stratified assignment, successive deduction and path reconstruction; at the same time, by synchronously writing the current point, closed connection and record number when generating the record to be assigned, the starting point, reachable range and record uniqueness of the subsequent assignment chain have clear basis, avoiding problems such as unclear release source, unclear downstream range or indistinguishable multiple records;

[0066] In practical applications: For example, within a certain monitoring cycle, the output power of the cycle point A01 is 120 kWh and the input power is 35 kWh. Subtracting the input power from the output power yields a difference of 85 kWh, which is greater than zero. Therefore, A01 is designated as the release point, and 85 kWh is written as the release power corresponding to A01. If there are two branches in the closed connection: A01 to B03, B03 to C02, and A01 to B05, then first extract the downstream numbers B03 and B05 using A01 as the current point number, and then press... After the serial number is written in ascending order, it continues to be extracted downwards to form two reachable downstream sequences corresponding to A01. One reachable downstream sequence is B03 and C02, and the other reachable downstream sequence is B05. Then, the released electricity of 85 kWh of A01 is assigned as the initial value of the remaining electricity of the two base records to be assigned. Then, A01, the current monitoring cycle number and the generation order of the two reachable downstream sequences are concatenated to form different record numbers. Finally, two unique records to be assigned are generated and written into the set to be assigned for direct use in subsequent assignment calculations.

[0067] S3. For each unique record to be assigned in the set to be assigned, extract the next downstream point by closed connection, calculate the power capacity of each downstream point, write the assigned sub-record from the current point to the corresponding downstream point in the order of time and point number, and deduct the remaining power capacity at the same time, and output the updated set to be assigned.

[0068] In this embodiment, each unique record to be assigned in the set represents a released power that has not yet been confirmed for destination. The purpose of subsequent processing is to search for a node that can actually receive the released power, layer by layer, from the current point corresponding to the unique record to the next downstream point, within the scope defined by the closed connection. Each confirmed assigned power is written into the assigned sub-record, and the remaining power is deducted simultaneously, thus forming a continuously advancing assignment chain. It should be noted that the current point represents the node position at which the assignment process is currently progressing; the remaining power represents the remaining power balance in the unique record to be assigned that has not yet been assigned; and the next downstream point refers to the node in the current monitoring cycle. During the period, the downstream points directly connected in the closed connection are those with the current point as the upstream number; the received power is the positive difference between the incoming power and outgoing power of the next downstream point in the current monitoring period; the existing attribution path is formed by connecting all the attribution sub-records generated in the unique attribution record in the writing order, which is used to prevent the same attribution chain from being written back to points that have already been passed; the attribution power is the power value actually allocated to a certain downstream point in the next layer from the remaining power in this round; in order to ensure that the attribution chain can advance layer by layer without reverse attribution, duplicate attribution and over-attribution, candidate attribution items are generated first, then attribution determination is performed, and then attribution calculation is completed in a unified order and written back to the unique attribution record.

[0069] The implementation process includes the following steps:

[0070] First, the current point, remaining power, and closed connections of each unique record to be assigned are read one by one from the set of records to be assigned. Then, the next-level downstream points are extracted around the current point, and the power received by each downstream point is calculated. Specifically, for a unique record to be assigned, the current point is read first, and all downstream points with the current point as the upstream number are searched in the set of periodic points. During the search, only downstream points that are consistent with the closed connections in the unique record to be assigned are retained, and no other connection relationships are introduced. For each searched downstream point, the incoming power and outgoing power of the downstream point in the current monitoring period are read in the set of periodic points, and the difference is obtained by subtracting the outgoing power from the incoming power. When the difference is greater than zero, the difference is written as the received electricity of the next downstream point; when the difference is equal to zero or less than zero, the received electricity of the next downstream point is written as zero; at the same time, the point number, corresponding time and the unique pending record of the next downstream point are written into the candidate attribution item, so that each candidate attribution item can clearly correspond to the candidate attribution relationship between a current point and a next downstream point; after this processing, each candidate attribution item in the candidate attribution item set contains at least the current point, the next downstream point, the received electricity, the corresponding time and the unique pending record identifier to which it belongs, and subsequent judgment and attribution calculation are based on this.

[0071] After obtaining the candidate attribution set, each candidate attribution item is sequentially subjected to acceptance checks, timing checks, and duplication checks to determine whether it qualifies for participation in this round of attribution calculation. Specifically, first, it checks whether the received electricity in the candidate attribution item is greater than zero. If the received electricity is equal to zero, it means that the next-level downstream point has not shown net acceptance characteristics in the current monitoring period, and the candidate attribution item is directly written as a rollback item. If the received electricity is greater than zero, the time of the next-level downstream point and the time of the current point are read, and the time difference is obtained by subtracting the time of the current point from the time of the next-level downstream point. If the time difference is less than zero, it means that the record of the next-level downstream point occurred before the current point, which does not conform to the time order of attribution along the connection direction, and the candidate attribution item is written as a rollback item. If the time difference is greater than or equal to zero, it checks whether the next-level downstream point has already been included in the unique attribution calculation. The candidate node appears in the existing attribution path of the record to be assigned. The specific checking method is as follows: Read all the attribution sub-records generated in the unique record to be assigned, extract the previous point number and the next point number in each attribution sub-record in the writing order to form an existing path node set, and then compare the next downstream point in the current candidate attribution item with the node set one by one; if the next downstream point has already appeared in the node set, it means that the point has participated in the attribution chain of the unique record to be assigned. In order to avoid forming a loop, the candidate attribution item is written as a backtracking item; only when the received power is greater than zero, the time difference is greater than or equal to zero and the next downstream point does not appear in the existing attribution path, is the candidate attribution item written as an attributable item; after this processing, it is determined that each attributable item in the attribution item set satisfies the requirements of reception, time sequence and path uniqueness, while other candidate attribution items are uniformly converted into backtracking items.

[0072] After the determination is completed, the attributable items in the determination attribution item set are sorted and attribution calculated. Specifically, for all attributable items belonging to the same unique record to be attributed, they are first sorted in ascending order by time difference, so that attributable items with smaller time differences are given priority in attribution. When the time differences are the same, they are then sorted in descending order by the amount of electricity received, so that attributable items with larger amounts of electricity received at the same time and location are given priority in attribution. When both the time difference and the amount of electricity received are the same, they are then sorted in ascending order by the location number. If there are still completely identical sorting conditions after the above three sortings, the attributable items are processed in the order in which they were generated in the determination attribution item set. After the sorting result is determined, the attributable items are read one by one in sequence, and the remaining electricity in the unique record to be attributed is calculated. The remaining electricity is compared with the received electricity in the current attributable item. When the remaining electricity is greater than or equal to the received electricity, the received electricity is determined as the attributable electricity, and the attributable electricity is subtracted from the remaining electricity. When the remaining electricity is less than the received electricity and the remaining electricity is greater than zero, the remaining electricity is determined as the attributable electricity, and the remaining electricity is reduced to zero. When the remaining electricity is equal to zero, the attribution calculation of subsequent attributable items is stopped, and all attributable items that have not yet participated in the attribution calculation are rewritten as rollback items. In this way, the attributable electricity is never greater than the received electricity of the current attributable item, nor greater than the remaining electricity of the unique record to be attributed, thus ensuring that the same released electricity is not repeatedly allocated, nor is it over-deducted in a single round of attribution.

[0073] After completing the attribution calculation, the results of this round of calculation are written back to the corresponding unique record to be attributed. Specifically, for the unique record to be attributed with attributable electricity in this round, an attribution sub-record is generated according to the current point, the corresponding next-level downstream point, the attributable electricity, and the writing order. When the same unique record to be attributed forms multiple attribution sub-records in this round, they are written according to the actual order of the attribution calculation, with the writing order starting from 1 and incrementing sequentially. Then, the next-level downstream point in the last generated attribution sub-record is read, and this next-level downstream point is written as the new current point of the unique record to be attributed. The remaining electricity after deduction, the rollback item, and all the newly generated attribution sub-records in this round are also written back to the unique record to be attributed. The reason for taking the last generated sub-record is... The next downstream point in the completed sub-record is used as the new current point because this point corresponds to the final advancement position after the completion of the current round of attribution calculation, and subsequent attribution continues to be executed from this position downwards; for the unique record to be assigned that has no assigned power in the current round, the original current point is kept unchanged, and only the remaining power and the rollback item are written back to the unique record to be assigned; for the unique record to be assigned that has reduced the remaining power to zero, no new current point is generated, only the already written sub-record is retained and the unique record to be assigned is merged into the updated set of records to be assigned; after this processing, each unique record to be assigned in the updated set of records to be assigned has a clear current point, remaining power and generated sub-record, and can directly enter the subsequent reassignment or closure process;

[0074] Through the above processing, the unique record to be assigned in the set to be assigned is transformed into an updated set to be assigned with the assignment path and the remaining power status. This means that the confirmation of the destination of released power is no longer based on static connection relationships, but is implemented as a continuous execution process that starts from the current point, is taken over by the next downstream point, is filtered according to time sequence and path restrictions, and is deducted one by one according to the remaining power. This ensures that the value of the receiving point is based on the actual power, and also ensures that the assignment chain will not be reversed, looped, or over-allocated.

[0075] In practical applications: For example, in a unique record to be assigned, the current point is A01 with a remaining power of 85 kWh. The closed connection shows that A01 corresponds to two downstream points B03 and B05 in the current monitoring cycle. Reading the input and output power of B03 in the cycle point set, which are 60 kWh and 10 kWh respectively, its received power is 50 kWh. Reading the input and output power of B05, which are 40 kWh and 5 kWh respectively, its received power is 35 kWh. If the time of B03 is 5 seconds, the time of B05 is 7 seconds, and the time of A01 is 3 seconds, then the time difference between them is 2 seconds and 4 seconds respectively, both greater than zero. Since neither B03 nor B05 appears in the existing assigned path of this unique record to be assigned, both are written as assignable items. Then, the time difference is used to determine the appropriate item. Next, sort by the received electricity and point number. B03 participates in the attribution calculation first. Its remaining electricity of 85 kWh is greater than its received electricity of 50 kWh, so 50 kWh is written as the attribution electricity and the remaining electricity is reduced to 35 kWh. Then, B05 participates in the attribution calculation. At this time, the remaining electricity of 35 kWh is equal to its received electricity of 35 kWh, so 35 kWh is written as the attribution electricity and the remaining electricity is reduced to zero. Then, the first attribution sub-record is generated according to the order of A01, B03, 50 kWh and the corresponding writing. Then, the second attribution sub-record is generated according to the order of A01, B05, 35 kWh and the corresponding writing. B05 in the last generated attribution sub-record is written as the new current point. In this way, the same 85 kWh of released electricity completes the attribution for this round and can directly enter the subsequent processing.

[0076] S4. For the only record to be assigned in the updated assignment set with a remaining power greater than zero, write the last downstream point as the current point and continue assignment; when the first different downstream point appears in the downstream sequence of the current and next cycles, stop the original assignment, and reconstruct the unique record to be assigned according to the remaining power at the corresponding time, the current point, and the changed closed connection, and output the closed assignment set.

[0077] In this embodiment, the unique record to be assigned in the updated set has completed at least one round of assignment calculation, but some records still have remaining power that has not been reduced to zero, indicating that the destination of the corresponding released power is not completely closed. The purpose of subsequent processing is to determine, while keeping the existing assigned sub-records valid, whether the unique record to be assigned can continue to be assigned downwards along the original closed connection, or whether the original assignment needs to be stopped and the assigned path rebuilt due to changes in the connection relationship after the monitoring cycle switch. The last generated assigned sub-record reflects the actual endpoint of the current assignment calculation, so its downstream point is used as the subsequent continuation point. The current point of attribution; the downstream sequence before the change is used to represent the downstream path that can be extracted from the current point in the current monitoring period; the downstream sequence after the change is used to represent the downstream path that can be extracted from the same current point in the next monitoring period; the change time is used to represent the periodic time difference of the different downstream points in the corresponding downstream sequence after the change when the two downstream sequences first appear different downstream points; the closed connection after the change is used to represent the connection relationship that should be adopted when continuing attribution after the change time; by comparing the downstream sequences of the two monitoring periods one by one, records that can still be attributed according to the original path can be distinguished from records that need to stop the original attribution and be reconstructed;

[0078] The implementation process includes the following steps:

[0079] First, the unique record to be assigned is filtered out from the updated set of records to be assigned, and its current point is redefined. Specifically, each unique record to be assigned in the updated set of records to be assigned is read one by one, and its remaining power is checked. When the remaining power is greater than zero, the unique record to be assigned is retained for subsequent processing. When the remaining power is equal to zero, it is no longer subject to the reassignment judgment. For each unique record to be assigned that is subject to subsequent processing, all the assigned sub-records in the record are read in the order of writing, the last generated assigned sub-record is taken, and the downstream point in the assigned sub-record is extracted and written as the current point of the unique record to be assigned. If a unique record to be assigned has not generated a new assigned sub-record in the updated set of records to be assigned in this round, the original current point of the unique record to be assigned remains unchanged. After the above processing is completed, the record containing the current point, remaining power, original closed connection and existing assigned sub-record is written into the reassignment record set, so that subsequent comparisons and reconstructions are all performed around the position that has actually been advanced to, rather than regressing to the release point number or an earlier node position.

[0080] Subsequently, the downstream sequences of each unique record to be assigned in the reassignment record set are compared between the two monitoring periods. Specifically, the closed connections of the unique record to be assigned in the current monitoring period are read first, and then the closed connections in the next monitoring period are obtained in the same way. Here, the closed connections in the next monitoring period come from the results of the conduction relationship processing performed on the original records of the next monitoring period in the same way as the period point set generation process. Then, starting from the current point, downstream points are extracted successively in the closed connections of the current monitoring period to form the downstream sequence before the change. Downstream points are extracted successively in the closed connections of the next monitoring period to form the downstream sequence after the change. The extraction method is as follows: the point number obtained in the previous round is used as the upstream number, and the corresponding downstream number in the closed connection is retrieved and written into the sequence in ascending order of the downstream number. If there is only one downstream number, the extraction continues directly with the downstream number as the new upstream number. If multiple downstream numbers exist, they are written in ascending order of downstream number, but the comparison is performed bit by bit in the order after writing. When there is no downstream number in the closed connection that is upstream of the previous round point number, or when the newly extracted downstream number has already appeared in the current sequence, the extraction of the sequence is stopped. After obtaining the downstream sequence before the change and the downstream sequence after the change, the downstream points in the two sequences are compared bit by bit in the writing order. When the downstream points at the same position in the two sequences are the same, the unique record to be assigned is written into the continuation marker. When the first different downstream point appears, the comparison is stopped immediately, and the period difference corresponding to the different downstream point in the changed downstream sequence is written as the change time. At the same time, the closed connection corresponding to the changed downstream sequence is written as the changed closed connection. After this processing, each unique record to be assigned in the connection determination set clearly falls into one of the two categories of continuation or reconstruction, and there is no uncovered state.

[0081] After completing the sequence comparison, the unique records to be assigned for different judgment results are processed separately. For the unique records to be assigned with the continuation marker written in the connection judgment set, their current point, remaining power, and closed connection remain unchanged, and no new reconstruction content is generated. This type of record indicates that starting from the current point, the downstream sequence consistent with the current monitoring cycle can still be continued to be assigned in the next monitoring cycle. Therefore, the assignment can continue to be performed along the original closed connection. For the unique records to be assigned with the change time written in the connection judgment set, the assignment according to the downstream sequence before the change is stopped, and the original closed connection is no longer used as the basis for subsequent assignment. At the same time, the remaining power, current point, and closed connection after the change time are read, and these three items, together with the release point number, record number, and existing assigned sub-record in the original unique record to be assigned, are written as reconstruction content to generate a reconstruction record set. The reason for retaining the existing assigned sub-record is that the assignment chain completed before the change time is still valid, and only the unassigned part after the change time needs to be processed under the new connection relationship. The reason for using the remaining power corresponding to the change time is to fix the reconstruction starting point at the position where the connection relationship actually forks, rather than redistributing the remaining power at an earlier or later position.

[0082] Finally, the unique unassigned record in the reconstructed record set is subjected to subsequent destination confirmation, and two results are distinguished: continued assignment and closed assignment. Specifically, for each reconstructed record, the current point and the changed closed connection are read, and the next-level downstream point is extracted from the changed closed connection using the current point as the upstream number. The extraction method is the same as the aforementioned downstream sequence extraction method, that is, all downstream numbers in the changed closed connection with the current point as the upstream number are retrieved and written in ascending order of the downstream number. If at least one next-level downstream point is extracted, it means that the unique unassigned record still has a direction that can be continued to be assigned under the changed closed connection. At this time, the unique unassigned record along with the reconstructed content is written back to the next-level downstream connection. A new set of entities to be assigned is created, and the assignment calculation is performed again in subsequent monitoring cycles to ensure that the remaining power continues to be distributed along the changed path. If no downstream point is extracted, it means that the unique entity to be assigned record has no nodes to continue to advance under the closed connection after the change. At this time, the set of entities to be assigned is not updated. Instead, the existing assigned sub-records in the unique entity to be assigned record, along with the corresponding release point number, remaining power, and record number, are merged into the closed set of entities to be assigned. The closure here does not require that the remaining power has been reduced to zero. Rather, it means that under the current connection relationship, there are no further executable downstream extraction results for this set of entities to be assigned. Subsequently, it can directly enter the generation of formal flow records or be retained abnormally as needed by business.

[0083] Through the above processing, the only unclosed record in the updated set of records to be assigned is further divided into records that can continue along the original path and records that need to be re-assigned according to the changed closed connection. This ensures that the change in connection relationship before and after the monitoring cycle switch will not directly interrupt the entire assignment chain, nor will it invalidate the already formed sub-records. At the same time, by locking the change point to the position where the difference first appears in the downstream sequence before and after, the subsequent reconstruction only applies to the remaining power portion that has not yet been closed, and the path that has been assigned remains unchanged.

[0084] In practical applications: For example, if the remaining electricity of a unique record to be assigned is 20 kWh at the end of the current monitoring period, and the final assigned sub-records are B05 to C02, then C02 is first written as the current point of the unique record to be assigned. Then, in the closed loop of the current monitoring period, extraction continues from C02 to obtain the pre-change downstream sequence C02, D01, and E03. In the closed loop of the next monitoring period, extraction continues from C02 to obtain the post-change downstream sequence C02, D04, and E06. During position-by-position comparison, the first position C02 is the same, but the second position D01 and D04 are different. Therefore, the period difference corresponding to D04 in the post-change downstream sequence is written as the change time, and the next monitoring period's C02 is written as the change time. The connection relationship from 2 to D04 to E06 is written as the closed connection after the change; then, the attribution according to the original path from C02 to D01 to E03 is stopped, and the remaining 20 kWh of electricity, the current point C02, and the closed connection after the change are written as the reconstruction content; if D04 can still be extracted in the closed connection with C02 as the upstream number, then the unique record to be assigned is written back to the updated set of records to be assigned, and the attribution continues from C02 to D04; if no downstream point can be extracted with C02 as the upstream number, then the existing assigned sub-record is merged into the closed attribution set; in this way, when the connection relationship changes, the attribution chain can still continue to advance along the actual conductive path or have a clear closed exit when there is no subsequent path.

[0085] S5. For the only record to be assigned in the closed assignment set with zero remaining power, the record is spliced ​​together according to the release point number, the previous and next point numbers in each sub-record, the power of the sub-record and the writing order to generate a formal energy flow record, and the energy flow monitoring result is output.

[0086] In this embodiment, the unique record to be assigned in the closed attribution set has completed the attribution closure of the released electricity to the downstream path. The purpose of subsequent processing is to organize these closed attribution results into a formal energy flow record that can be directly output, and further form an energy flow monitoring result. Here, the remaining electricity equal to zero indicates that the released electricity corresponding to the unique record to be assigned has been completely assigned. The attribution sub-record is used to describe the electricity distribution relationship between the preceding and following points in each attribution calculation. The attribution fragment is used to represent the sequence of attribution sub-records arranged in the writing order. The splicing segment is used to represent the set of consecutive attribution sub-records. The formal energy flow record is used to represent the complete flow direction formed by starting from the release point number and connecting multiple preceding and following points in sequence. The result record is used to represent the result structure after organizing the formal energy flow record according to the output fields. In order to ensure that the output result can accurately reflect the preceding and following flow relationship and maintain the consistency of the electricity value and the writing order, the attribution fragment is extracted first, then the splicing segment is formed according to the consecutive relationship of the preceding and following points, then the formal energy flow record is generated, and finally the energy flow monitoring result is output.

[0087] The implementation process includes the following steps:

[0088] First, the unique unassigned records that have completed closure are screened from the closed attribution set, and their attribution sub-records are organized. Specifically, each unique unassigned record in the closed attribution set is read one by one, and its remaining power is checked. When the remaining power is zero, the unique unassigned record is retained for subsequent processing. When the remaining power is not zero, it is not processed in this part. For each unique unassigned record that enters subsequent processing, the release point number and all attribution sub-records are extracted, and then sorted in ascending order according to the writing order of the attribution sub-records. When a unique unassigned record contains only one attribution sub-record, the sorting result is that single attribution sub-record. When it contains multiple attribution sub-records, they are sorted in ascending order according to the writing order, without changing the original order. After this processing, each unique unassigned record corresponds to a set of attribution sub-records arranged in the writing order, and is written into the attribution fragment set along with the corresponding release point number, so that subsequent splicing processing is always based on the release point number and the existing attribution order.

[0089] Subsequently, adjacent attribution sub-records in the attribution segment set are compared for continuity, and spliced ​​segments are formed. Specifically, for attribution segments corresponding to the same release point number, adjacent two attribution sub-records are read one by one in the sorted writing order. The last point number of the previous attribution sub-record and the first point number of the next attribution sub-record are extracted and an equality comparison is performed. When the comparison results are equal, it means that the end point of the previous attribution sub-record and the start point of the next attribution sub-record are the same, and the two attribution sub-records are continuous on the path. At this time, the adjacent attribution sub-records are written into the same spliced ​​segment. When the comparison results are not equal, it means that the previous attribution sub-record and the next attribution sub-record are not continuous on the path. If the segments are discontinuous, the previous attribution sub-record is used as the last attribution sub-record of the previous splicing segment, and the next attribution sub-record is used as the first attribution sub-record of the next splicing segment. These two are then written into the two adjacent splicing segments respectively. For the first attribution sub-record corresponding to a certain release point number, it is first written into the first splicing segment. After that, each time an adjacent attribution sub-record is compared, it is decided whether the next attribution sub-record continues to be written into the current splicing segment or a new splicing segment is started. After this process, each splicing segment in the splicing segment set corresponds to a set of attribution sub-records with consecutive consecutive point numbers, and one or more splicing segments may be formed under the same release point number.

[0090] After obtaining the splicing segment set, sequential splicing and power accumulation are performed on each splicing segment to generate a formal energy flow record. Specifically, for a given splicing segment, its corresponding release point number is read first, and then the previous point number, next point number, and power of each sub-record are extracted sequentially according to the writing order of the sub-records within the splicing segment. During path splicing, the previous point number of the first sub-record is used as the starting point number of the splicing segment, and then the next point numbers of subsequent sub-records are connected sequentially to form a sequence of previous and next point numbers corresponding to the release point number. During power processing, all sub-records within the splicing segment are processed. The sub-record electricity amounts in the record are accumulated one by one. The initial accumulation value is the electricity amount of the first belonging sub-record. After that, each time a belonging sub-record is read, the electricity amount of that belonging sub-record is added to the current accumulation value until all belonging sub-records in the splicing segment have been processed. After the path splicing and electricity accumulation are completed, the release point number, the sequence of the preceding and following point numbers corresponding to the splicing segment, the electricity amounts of the sub-records in each belonging sub-record, and the writing order are written together to form a formal energy flow record. After the above processing is completed for all splicing segments in the splicing segment set, a flow record set is formed.

[0091] Finally, result records are generated for each formal energy flow record in the flow record set, and the energy flow monitoring results are output. Specifically, each formal energy flow record in the flow record set is read one by one, and the release point number, the preceding and following point numbers in each subordinate sub-record, the sub-record electricity amount, and the writing order are extracted and written into the result record according to a unified field order. The result record does not change the path order and electricity order in the formal energy flow record; it only organizes the output fields uniformly to ensure that the same type of information is arranged in a consistent manner in different formal energy flow records. After the result records for all formal energy flow records are generated, all result records are summarized and output as the energy flow monitoring results. In the energy flow monitoring results obtained in this way, each result record can be traced back to the corresponding release point number, subordinate path, and sub-record electricity amount, which can directly reflect the flow relationship of energy from the release point to subsequent nodes and maintain consistency with the aforementioned subordinate processing process.

[0092] Through the above processing, the unique record to be assigned in the closed attribution set that has been closed is converted into an energy flow monitoring result that can be directly displayed and called, so that the path relationship and power relationship obtained by the previous attribution calculation can be output stably in a structured form; at the same time, by comparing the point numbers of adjacent attribution sub-records, continuous paths and discontinuous paths can be clearly separated, avoiding the direct splicing of disjoint attribution sub-records into a flow record, and ensuring that the path order, power order and attribution order in the result record correspond to each other.

[0093] In practical applications: For example, in a unique record to be assigned at release point A01, three sub-records are generated in the writing order: A01 to B03 (sub-record power 30 kWh), B03 to C02 (sub-record power 20 kWh), and D01 to E04 (sub-record power 15 kWh). During processing, the three sub-records are first written to the assignment fragment set in the writing order. Then, adjacent sub-records are compared. The last point number B03 of the first sub-record is equal to the first point number B03 of the second sub-record, so the first two sub-records are written to the same concatenation segment. The last point number C02 of the second sub-record is not equal to the first point number D01 of the third sub-record, so the second sub-record is... The attribution sub-record serves as the last attribution sub-record of the previous splicing segment, and the third attribution sub-record serves as the first attribution sub-record of the next splicing segment, ultimately forming two splicing segments. Then, the first splicing segment is completed by splicing the preceding and following point numbers in the order of A01, B03, and C02, and the 30 kWh and 20 kWh are added together to obtain 50 kWh, generating a formal energy flow record. The second splicing segment is completed by splicing D01 and E04, and 15 kWh is used as the corresponding electricity amount, generating another formal energy flow record. Finally, the result record is generated and summarized and output according to the release point number, the preceding and following point numbers in each attribution sub-record, the electricity amount of the sub-record, and the writing order. This yields an energy flow monitoring result consistent with the actual attribution chain.

[0094] Working Principle: This scheme unifies and organizes the incoming and outgoing electricity, point number, upstream and downstream relationships, switch values, and times reported by each metering point within the same monitoring cycle, forming a periodic point set with closed connections and a unified time base in a cloud-based collaborative environment. Then, it identifies release points where the outgoing electricity is greater than the incoming electricity, calculates the released electricity, and extracts the reachable downstream sequence along the closed connection, generating a unique record to be assigned. Next, starting from the current point in the unique record to be assigned, it searches for the next layer of downstream points layer by layer, calculates the electricity received by each downstream point, and combines the time sequence and existing assignment paths to screen out truly eligible objects for assignment, and then sorts them according to the order of events. The remaining electricity is gradually distributed to these downstream points, generating assigned sub-records. If the connection relationship changes in subsequent monitoring cycles, the assignment along the original path is stopped, and the record to be assigned is reconstructed according to the changed closed connection. When the remaining electricity of a record is reduced to zero, the continuously connected assigned sub-records in that record are spliced ​​together to form a formal energy flow record, and finally the energy flow monitoring results are output. In general, this solution does not simply look at which point is changing, but rather connects the entire process of a released electricity from generation, transmission, continuation, reconstruction to final closure, forming a complete flow chain with source, destination, and path.

[0095] In practical implementation, for example, if an industrial park is simultaneously connected to mains power, photovoltaic power, and energy storage, and air compressors, cooling plants, and production lines draw power from the same bus branch, the various metering points on site will continuously report data. This solution will first organize these scattered records by point number and monitoring cycle on a cloud-based collaborative platform, and then identify which points have released net electricity in the current cycle. Assuming that a certain point has released 85 kWh in this cycle, the system will search down the connected upstream and downstream layers to see which downstream points have actually shown net absorption during this period, and gradually distribute these 85 kWh according to time sequence and path continuity. If half of the 85 kWh has been allocated, the next monitoring cycle will begin. When the switch status changes, causing the original downstream path to no longer hold true, the system will not mechanically continue calculating along the old path. Instead, it will start from the changed position and use the remaining unassigned electricity and the new connection relationship to trace downstream again. Finally, after all 85 kilowatt-hours have been assigned, the system will organize the entire transmission path into a formal energy flow record, such as which release point it started from, which points it passed through in sequence, and how much electricity was allocated to each point. In this way, in the scenarios of integrated energy management in the park, power distribution monitoring in the factory, or multi-source energy supply, the managers will no longer see scattered meter changes, but rather the energy flow results that can directly correspond to the actual transmission path.

[0096] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. An energy flow monitoring method based on Internet of Things big data analysis, characterized in that, include: S1. Obtain the incoming power, outgoing power, point number, upstream number, downstream number, switch value and time of each metering point in the same monitoring cycle, organize the connected upstream and downstream relationships into closed connections, convert the time to the same time base, and output the cycle point set. S2. Perform a subtraction operation on the output and input of each metering point in the periodic point set, determine the difference that is greater than zero as the released power, and generate a unique record to be assigned according to the release point number, released power, remaining power, monitoring cycle and closed connection, and output the set to be assigned. S3. For each unique record to be assigned in the set to be assigned, extract the next downstream point by closed connection, calculate the power capacity of each downstream point, write the assigned sub-record from the current point to the corresponding downstream point in the order of time and point number, and deduct the remaining power capacity at the same time, and output the updated set to be assigned. S4. For the only record to be assigned in the updated assignment set with a remaining power greater than zero, write the last downstream point as the current point and continue assignment; when the first different downstream point appears in the downstream sequence of the current and next cycles, stop the original assignment, and reconstruct the unique record to be assigned according to the remaining power at the corresponding time, the current point, and the changed closed connection, and output the closed assignment set. S5. For the unique record to be assigned in the closed assignment set with zero remaining energy, concatenate the release point number, the preceding and following point numbers in each assignment sub-record, the sub-record energy, and the writing order to generate a formal energy flow record, and output the energy flow monitoring results; including: S5-1. Extract the unique record to be assigned from the closed assignment set where the remaining power is zero, and extract the release point number and assignment sub-record from each unique record to be assigned. Arrange the assignment sub-records in the order of writing and output the assignment fragment set. S5-2. For adjacent sub-records in the sub-segment set, extract the last point number of the previous sub-record and the first point number of the next sub-record and perform an equality comparison. If the comparison results are equal, write the adjacent sub-records into the same splice segment. Otherwise, write the adjacent sub-records into the two adjacent splice segments respectively, and output the splice segment set. S5-3. For each splicing segment in the splicing segment set, perform sequential splicing according to the release point number, the preceding and following point numbers in each assigned sub-record, the sub-record electricity level, and the writing order, and perform cumulative calculation on the sub-record electricity level in each assigned sub-record to generate a formal energy flow record and output the flow record set. S5-4. For each formal energy flow record in the flow record set, generate a result record according to the release point number, the preceding and following point numbers in each subordinate sub-record, the sub-record electricity amount, and the writing order, and output the energy flow monitoring result.

2. The energy flow monitoring method based on IoT big data analysis according to claim 1, characterized in that: S1 includes: S1-1. Extract the incoming power, outgoing power, point number, upstream number, downstream number, switch value and time within the same monitoring period by point number, sort them in ascending order by time and take the first time as the reference time of the point, and output the point record. S1-2. Subtract the corresponding reference time from the time recorded at each point to obtain the periodic time difference with the reference time as the same time reference, and extract the upstream and downstream numbers where the switch value is turned on, and output the closed connection. S1-3. Write the periodic time difference, incoming power, outgoing power, point number, and closed connection from each point record into the same record structure according to the point number, and output the periodic point set.

3. The energy flow monitoring method based on Internet of Things big data analysis according to claim 2, characterized in that: S2 includes: S2-1. Subtract the output and input quantities of each metering point in the periodic point set, determine the metering points with a difference greater than zero as release points, and determine the difference as the release quantity of the corresponding release point, and output the release point set; S2-2. For each release point in the release point set, take the release point number as the current point number, extract the downstream number with the current point number as the upstream number from the closed connection, and write it into the reachable downstream sequence in the extraction order. Then replace the downstream number with the new current point number and continue extraction until there is no downstream number with the current point number as the upstream number in the closed connection or the extracted downstream number has been written into the reachable downstream sequence. Output the reachable downstream sequence set.

4. The energy flow monitoring method based on IoT big data analysis according to claim 3, characterized in that: S2 further includes: S2-3. Assign the released power of each release point in the reachable downstream sequence set to the remaining power, and concatenate the release point number, monitoring period and the writing order in the reachable downstream sequence to generate a record number, and output the base record set to be assigned. S2-4. Write the release point number, released power, remaining power, monitoring cycle, closed connection, reachable downstream sequence and record number of the base record set to be assigned into the same record structure to generate a unique record to be assigned and output the set to be assigned.

5. The energy flow monitoring method based on Internet of Things big data analysis according to claim 4, characterized in that: S3 includes: S3-1. Extract the current point, remaining power, and closed connection from each unique record to be assigned from the set of unassigned records. Extract the next downstream point with the current point as the upstream number from the set of periodic points. Subtract the incoming power and outgoing power of each next downstream point. If the difference is greater than zero, write the difference as the power received by the next downstream point. Otherwise, write the power received by the next downstream point as zero and output the candidate assignment set. S3-2. For each candidate attribution item in the candidate attribution item set, check whether the received electricity is greater than zero, check whether the time difference obtained by subtracting the time of the current point from the time of the next downstream point is greater than or equal to zero, and check whether the next downstream point has already appeared in the existing attribution path of the corresponding unique record to be attributed; when the received electricity is greater than zero, the time difference is greater than or equal to zero, and the next downstream point has not appeared in the existing attribution path, write the candidate attribution item as an attributable item; otherwise, write the candidate attribution item as a fallback item and output the attribution item set.

6. The energy flow monitoring method based on Internet of Things big data analysis according to claim 5, characterized in that: S3 further includes: S3-3. For the attributable items in the attribution item set, first sort them in ascending order by time difference, then in descending order by received electricity, and finally in ascending order by point number. Perform attribution calculations sequentially according to the sorting results. When the remaining electricity is greater than or equal to the received electricity of the current attributable item, the received electricity is determined as the attributable electricity, and the attributable electricity is subtracted from the remaining electricity. When the remaining electricity is less than the received electricity of the current attributable item and the remaining electricity is greater than zero, the remaining electricity is determined as the attributable electricity, and the remaining electricity is reduced to zero. When the remaining electricity is equal to zero, stop the attribution calculation of subsequent attributable items, rewrite the attributable items that did not participate in the attribution calculation as rollback items, and output the attribution update record set. S3-4. Perform write-back based on each unique pending record in the ownership update record set. When there is ownership of electricity in this round, generate ownership sub-records according to the current point, the corresponding next-level downstream point, ownership electricity, and the writing order. Replace the next-level downstream point in the last generated ownership sub-record with the new current point, and write back the deducted remaining electricity, the rollback item, and the ownership sub-record to the corresponding unique pending record. When there is no ownership of electricity in this round, keep the original current point unchanged, and write back the remaining electricity and the rollback item to the corresponding unique pending record. When the remaining electricity is equal to zero, output the updated pending set.

7. The energy flow monitoring method based on Internet of Things big data analysis according to claim 6, characterized in that: S4 includes: S4-1. Extract the unique record to be assigned from the updated set of records to be assigned, which has a remaining power greater than zero. Extract the last generated sub-record of each unique record to be assigned. Write the downstream point of each last generated sub-record as the current point of the corresponding unique record to be assigned. Output the set of records to be assigned. S4-2. Extract the closed connections of each current point in the current monitoring period and the closed connections of the next monitoring period from the recurrence record set. Extract downstream points one by one from the current point to form the downstream sequence before the change and the downstream sequence after the change. Compare the downstream points in the two downstream sequences bit by bit in the writing order. When all downstream points are the same, write the recurrence mark. When the first different downstream point appears, write the recording time corresponding to the different downstream point as the change time, and write the downstream sequence after the change as the closed connection after the change. Output the connection determination set.

8. The energy flow monitoring method based on IoT big data analysis according to claim 7, characterized in that: S4 further includes: S4-3. For the only record to be assigned in the connection decision set with the continued assignment mark, keep the current point, remaining power and closed connection unchanged; for the only record to be assigned in the connection decision set with the change time, stop continuing to assign according to the downstream sequence before the change, and write the remaining power, current point and closed connection after the change time as the reconstruction content, and output the reconstruction record set. S4-4, for each unique record to be attributed in the reconstructed record set, extract the next layer of downstream points in the corresponding closed connection with the current point as the upstream number; when the next layer of downstream points is extracted, write the unique record to be attributed back to update the set of records to be attributed and continue to execute the attribution of the next layer; otherwise, write the existing attribution sub-record into the closed attribution set and output the closed attribution set.