Hourly-level green electricity transaction method and system for improving new energy consumption potential, electronic equipment and medium
By combining time series alignment and supply-demand matching models with blockchain-based evidence storage, the problem of balancing matching accuracy and efficiency in hourly green electricity transactions has been solved, thereby improving the accuracy and efficiency of green electricity transactions and enhancing the accuracy of traceability and authentication as well as the credibility of the system.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-12
- Publication Date
- 2026-03-17
AI Technical Summary
Existing technologies struggle to balance matching accuracy and computational efficiency in hourly green electricity transactions, failing to meet the dynamic spatiotemporal correlation requirements of high-frequency data processing and multilateral transactions, resulting in limited traceability and authentication accuracy and low computational efficiency.
By standardizing high-frequency production and consumption data through time series alignment, combining it with a supply and demand matching model for feature analysis and optimization calculations, and utilizing a blockchain network to perform verification and consensus notarization, a trusted transaction block is generated and settlement is carried out.
It enables precise matching and efficient calculation of hourly green electricity transactions, improves the accuracy of traceability certification and the credibility of the system, and meets the needs of rapid and accurate carbon footprint accounting in international mutual recognition scenarios.
Smart Images

Figure CN121684902A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of power market and energy management, in particular to a method and system for promoting the consumption potential of new energy, an electronic device and a medium. BACKGROUND
[0002] With the continuous and rapid development of green power market, the consumption and transaction scale of green power in the UHV power grid is expanding, and the actual demand for precise matching and tracing of hour-level green power production and consumption is increasingly urgent. Hour-level green power transaction involves multi-load characteristics, randomness of new energy output and multi-lateral transaction relationship. Whether the fine tracing and authentication of green power and the fair distribution of consumption rights can be realized is directly related to the transparency and international recognition of the green power market. Therefore, the efficient tracing of hour-level green power transaction for promoting the consumption potential of new energy has become a key task in the green energy management system.
[0003] In the field of green power transaction and tracing, the existing technology has made certain development. Based on the decentralization and non-tamperability of the blockchain-based rights tracing method, it has been widely used in the field of green power consumption classification accounting. The current mainstream green power transaction system relies on distributed ledger technology to realize consumption weight calculation and rights certificate generation through smart contracts to improve the credibility of tracing. However, the hour-level green power transaction environment for promoting the consumption potential of new energy has high frequency and dynamics, and the transaction data often has the characteristics of fine time granularity and complex spatio-temporal correlation. The existing technology still has obvious limitations in dealing with these problems.
[0004] Prior art document 1 (application publication number CN 119515411 A) discloses a method and system for classifying and accounting for green electricity consumption and tracing its rights through multi-dimensional accounts. This method verifies green electricity transaction matching data by constructing a distributed ledger node network and generates consumption levels and rights certificates based on smart contracts to improve the accuracy of green electricity consumption accounting. However, this method mainly targets transaction matching in the conventional time dimension. Its feature verification logic and accounting objectives are more suitable for monthly or annual statistical scenarios, failing to fully consider the high redundancy characteristics of high-frequency data in hourly green electricity transactions aimed at enhancing the potential of new energy consumption, as well as the dynamic spatiotemporal correlation requirements under multilateral transactions. Specifically, existing technologies generally suffer from two prominent problems: firstly, they fail to effectively handle redundant information in hourly time-series transactions, especially invalid data generated by frequent short-term transactions, significantly increasing the computational burden and reducing processing efficiency; secondly, their ability to model spatiotemporal correlations across multiple time scales is insufficient, making it difficult to accurately capture the real-time matching patterns of green electricity production and consumption, resulting in limited accuracy in traceability and authentication. These problems, when combined, make it difficult for existing technologies to balance accuracy and computational efficiency in the practical application of hourly green electricity trading aimed at enhancing the potential of renewable energy consumption. They also fail to meet the demands for rapid and accurate carbon footprint accounting in internationally recognized scenarios. Therefore, existing electricity trading traceability technologies suffer from the technical challenge of achieving a balance between matching accuracy and computational efficiency. Summary of the Invention
[0005] In response to the above-mentioned shortcomings or disadvantages, this invention provides an hourly green electricity trading method, system, electronic device and medium to enhance the potential of new energy consumption, which can solve the technical problem that existing power trading traceability technologies cannot balance matching accuracy and calculation efficiency.
[0006] This invention provides an hourly green electricity trading method to enhance the potential of new energy consumption, comprising: Acquire hourly green electricity production and consumption data, and perform time series alignment processing on the production and consumption data.
[0007] The production and consumption data, after being aligned with the time series, are input into a pre-set supply and demand matching model. The model then performs supply and demand characteristic analysis and optimization calculations to generate hourly green electricity transaction matching results.
[0008] Based on the hourly green electricity transaction matching results, the transaction matching results are verified and consensus-based notarization is performed through a pre-set blockchain network to generate a trusted transaction block corresponding to the transaction matching results.
[0009] Hourly green electricity transaction settlement is performed based on trusted transaction blocks.
[0010] According to a second aspect, this invention provides an hourly green electricity trading system to enhance the potential of new energy consumption, comprising: The production and consumption data acquisition module is used to acquire hourly green electricity production and consumption data, and to perform time series alignment processing on the production and consumption data.
[0011] The transaction matching result generation module is used to input the production data and consumption data after time series alignment into a preset supply and demand matching model, and perform supply and demand feature analysis and optimization calculation through the supply and demand matching model to generate hourly green electricity transaction matching results.
[0012] The trusted transaction block generation module is used to verify and consensus-based notarization of the transaction matching results based on the hourly green electricity transaction matching results through a preset blockchain network, and generate trusted transaction blocks containing the transaction matching results.
[0013] The green electricity transaction settlement module is used to perform hourly green electricity transaction settlement based on trusted transaction blocks.
[0014] According to a third aspect, the present invention provides an electronic device comprising: At least one processor; and a memory communicatively connected to the at least one processor; The memory stores instructions that can be executed by the at least one processor, which enables the at least one processor to execute any of the hourly green electricity trading methods for enhancing the potential of new energy consumption in the embodiments of the present invention.
[0015] According to another aspect of the present invention, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to cause a computer to execute any of the hourly green electricity trading methods for enhancing the potential of new energy consumption in the embodiments of the present invention.
[0016] The present invention provides a method for hourly green electricity trading to enhance the consumption potential of new energy sources. This method is achieved through four core steps: data alignment processing, supply and demand matching calculation, blockchain notarization, and transaction settlement. Specifically, the method involves acquiring hourly green electricity production and consumption data and performing time series alignment processing to eliminate time reference deviations between different data sources and achieve data synchronization; inputting the aligned data into a supply and demand matching model and performing supply and demand feature analysis and optimization calculations to generate accurate transaction matching relationships; verifying and storing the transaction matching results through a blockchain network to generate corresponding immutable and trustworthy transaction blocks; and performing transaction settlement based on the trustworthy transaction blocks to automatically clear funds and green rights.
[0017] In this technical solution, the present invention addresses the problem of poor handling of redundant information mentioned in the background technology by performing time series alignment processing to standardize, clean, and synchronize the original high-frequency production and consumption data. This effectively filters out invalid and conflicting data entries in the time dimension, reducing the redundancy of subsequent processing. Addressing the issue of insufficient spatiotemporal correlation modeling, the invention performs supply and demand feature analysis and optimization calculations through a supply and demand matching model. Within a unified time framework, it deeply mines the dynamic correlation and coupling patterns between production and consumption curves, achieving accurate modeling and optimization of complex spatiotemporal matching relationships. Therefore, the technical solution of this invention solves the technical problem of the difficulty in balancing matching accuracy and computational efficiency in existing power trading traceability technologies, improving the accuracy, processing efficiency, and system credibility of green electricity trading at the traceability and authentication level. Attached Figure Description
[0018] Figure 1 This is a flowchart of an hourly green electricity trading method for enhancing the potential of new energy consumption according to an embodiment of the present invention; Figure 2 This is a structural block diagram of an hourly green electricity trading system for enhancing the potential of new energy consumption, according to some embodiments of the present invention. Figure 3 This is a block diagram of an electronic device used to implement embodiments of the present invention. Detailed Implementation
[0019] The following description, in conjunction with the accompanying drawings, illustrates exemplary embodiments of the present invention, including various details to aid understanding. These details should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope of the invention. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.
[0020] During the development of this invention, the inventors, through extensive experiments and data analysis, revealed the intrinsic relationship between the time alignment accuracy of high-frequency time series data and the computational efficiency of the supply-demand matching model: the effectiveness of time series alignment processing directly determines the complexity of subsequent supply-demand matching calculations and the accuracy of the final transaction matching results. Based on this relationship, the inventors innovatively proposed this technical solution, which utilizes time series alignment technology to eliminate the time deviation between production and consumption data, and combines the supply-demand matching model to perform in-depth feature analysis and optimization calculations on the aligned data, thereby improving overall computational efficiency while ensuring hourly transaction matching accuracy.
[0021] Specifically, through comparative experiments, the invention team discovered two major technical flaws in traditional current differential protection methods: First, directly matching the original asynchronous time-series data introduces a large amount of invalid calculations due to inconsistent time bases, resulting in high computational redundancy. Second, using simple weighted averages or fixed-period aggregation methods fails to accurately depict the dynamic spatiotemporal correlation of supply and demand curves at the hourly scale, leading to limited matching accuracy. These technical flaws result in low reliability of transaction matching results and high system processing latency, making it difficult to meet the dual requirements of real-time performance and accuracy for hourly green electricity transactions. The time-series alignment processing method proposed in this invention improves data quality, laying the foundation for accurate matching; through feature analysis and optimization calculations performed by the supply and demand matching model, effective supply and demand features can be quickly extracted from massive amounts of data, generating the optimal matching scheme.
[0022] Therefore, this invention provides an hourly green electricity trading method to enhance the potential of new energy consumption, based on the first aspect. This method can be applied to a green electricity trading and traceability system (hereinafter referred to as the "system"). The system can operate in a network environment composed of multiple computing nodes through centralized scheduling or distributed collaboration to automate the entire process from green electricity trading matching and blockchain notarization to final settlement. Specifically, this system can be deployed in various hardware environments, including but not limited to: virtualized server clusters in the cloud, local server clusters in power dispatch centers, and edge computing gateways close to the data source. This flexible deployment architecture allows the system to meet the needs of provincial power trading centers for high-concurrency processing of massive amounts of data, while also adapting to the low-latency, high-real-time transaction verification requirements of local distribution networks or park microgrids.
[0023] like Figure 1 As shown, the method may include: Step S110: Obtain hourly green electricity production and consumption data, and perform time series alignment processing on the production and consumption data.
[0024] The time series alignment process refers to the process of unifying time series data from different sources and with different sampling frequencies onto the same time coordinate axis to eliminate matching deviations caused by inconsistencies in data acquisition time points.
[0025] Specifically, the system can periodically obtain raw data from the monitoring systems of green power production enterprises and the energy management systems of power consumption enterprises through application programming interfaces (APIs) or message queues.
[0026] For example, the system can obtain power generation data at 15-minute intervals from the monitoring system of a photovoltaic power station, and simultaneously collect electricity load data at 1-hour intervals from the smart meters of a manufacturing enterprise. By interpolating and resampling the two data, a unified time series dataset based on 1 hour is generated.
[0027] Step S120: Input the production data and consumption data after time series alignment into the preset supply and demand matching model, perform supply and demand characteristic analysis and optimization calculation through the supply and demand matching model, and generate hourly green electricity transaction matching results.
[0028] The supply and demand matching model refers to a mathematical programming model based on constrained optimization theory. Its objective function is to maximize the amount of green electricity consumed, and the constraints include grid transmission capacity, load balance equations, etc.
[0029] Specifically, the system can solve the model by calling mathematical programming solvers (such as Gurobi and CPLEX) to obtain the optimal matching solution. Gurobi and CPLEX are commercial mathematical optimization solver software used to efficiently solve complex mathematical optimization problems such as linear programming and integer programming.
[0030] For example, the system can match the surplus power generation capacity of a wind farm in a certain region with the demand of multiple adjustable load users in the region, and output the green electricity quota that should be allocated to each user in that period and the corresponding transaction price.
[0031] Step S130: Based on the hourly green electricity transaction matching results, the transaction matching results are verified and consensus notarized through a preset blockchain network to generate a trusted transaction block corresponding to the transaction matching results.
[0032] The blockchain network employs a Byzantine Fault Tolerance (BFT) consensus mechanism to ensure data consistency even with a small number of malicious nodes. BFT is a distributed system fault-tolerance mechanism that ensures correct consensus is reached even when a certain percentage of nodes experience any type of failure (including malicious behavior). Specifically, the system can automatically verify the format compliance, signature validity, and balance adequacy of transaction data through smart contracts.
[0033] For example, when it is detected that the account balance of an electricity-consuming enterprise in a transaction is insufficient, the smart contract will automatically reject the transaction from being recorded on the blockchain and send an alarm message to the relevant parties. The transaction verification process will be re-initiated after the recharge is completed.
[0034] Step S140: Execute hourly green electricity transaction settlement based on trusted transaction blocks.
[0035] The settlement process includes fund transfers, Green Electricity Certificate (GEC) generation, and carbon emission verification. A GEC is a tradable electronic certificate used to record and prove the production, trading, and consumption of green electricity. It typically represents the environmental value of a certain amount of green electricity (e.g., one certificate corresponds to one megawatt-hour).
[0036] Specifically, the system can achieve cross-platform automated settlement by connecting with bank payment gateways and green electricity certificate registration systems.
[0037] For example, after confirming that a 100 MWh green electricity transaction has been successfully recorded on the blockchain, the system will automatically deduct the corresponding electricity fee from the electricity-consuming enterprise's account to the power generation enterprise's account, and at the same time issue an equivalent number of green electricity certificates to the electricity-consuming enterprise and update its carbon emission inventory data.
[0038] Therefore, according to the above implementation method, the system acquires hourly green electricity production and consumption data and performs time series alignment processing to eliminate time base deviations between different data sources and achieve data synchronization; the aligned data is input into a supply and demand matching model and supply and demand feature analysis and optimization calculations are performed to generate accurate transaction matching relationships; based on the transaction matching results, verification and consensus notarization are performed through a blockchain network to generate corresponding tamper-proof trusted transaction blocks; and transaction settlement is performed based on the trusted transaction blocks to complete the automatic clearing of funds and green rights.
[0039] Specifically, in this implementation, addressing the issue of inadequate handling of redundant information mentioned in the background technology, time series alignment processing is performed to standardize, clean, and synchronize the original high-frequency production and consumption data. This effectively filters out invalid and conflicting data entries in the time dimension, reducing the redundancy of subsequent processing. Regarding the insufficient spatiotemporal correlation modeling, a supply-demand matching model is used to perform supply-demand feature analysis and optimization calculations. Within a unified time framework, the dynamic correlation and coupling patterns between production and consumption curves are deeply explored, achieving accurate modeling and optimization of complex spatiotemporal matching relationships. Therefore, this implementation's technical solution solves the technical problem of balancing matching accuracy and computational efficiency in existing power trading traceability technologies, improving the accuracy, processing efficiency, and system credibility of green electricity trading at the traceability and authentication level.
[0040] In some embodiments, production data includes power generation plan data and real-time output data of green electricity producers, and consumption data includes electricity load data and multi-load characteristic data of electricity consumers; hourly green electricity production and consumption data are acquired, and time series alignment processing is performed on the production and consumption data, including: Data on power generation plans and real-time output are collected from the energy management systems of green power production enterprises to generate time series of production loads.
[0041] The energy management system refers to a computer monitoring system used to monitor and control the operation of power generation equipment.
[0042] Specifically, the system can establish a data connection with the energy management system through the Open Platform Communications Unified Architecture (OPC UA) protocol. OPC UA is a platform-independent, service-oriented industrial interoperability standard used to enable secure and reliable data exchange between industrial automation equipment and systems.
[0043] For example, the system collects power generation plan data for the next 24 hours and current actual output data from the energy management system of a wind farm every 15 minutes. The accuracy of the plan data is 0.1 MW, and the sampling interval for real-time data is 1 minute.
[0044] Electricity load data and multi-various load characteristic data are collected from the smart metering terminals of electricity-consuming enterprises or the data platforms of load aggregators to generate a consumption load time series.
[0045] The multi-dimensional load characteristic data refers to a set of parameters that describe characteristics such as load adjustability and response speed.
[0046] Specifically, the system can collect data from smart meters through the Message Queuing Telemetry Transport (MQTT) protocol.
[0047] For example, the system collects active power data from smart meters in an industrial park every 15 minutes, and also obtains their load characteristic parameters, including an interruptible load capacity of 5 megawatts and a load adjustment response time of 10 minutes.
[0048] The production load time series and consumption load time series are discretized to obtain discretized production series and discretized consumption series.
[0049] Discretization refers to the process of converting a continuous time series into equally spaced data points.
[0050] Specifically, the system can use a linear interpolation algorithm to convert unequal interval data into a 15-minute interval sequence.
[0051] For example, the real-time power output data of a wind farm at 1-minute intervals can be converted into data at 15-minute intervals by averaging, generating a daily series containing 96 data points.
[0052] Based on the discretized production and consumption sequences, time-point mapping and alignment operations are performed to obtain production and consumption data after time-series alignment.
[0053] Among them, time point mapping and alignment operations refer to the process of establishing the correspondence between production and consumption data time points.
[0054] Specifically, the system can use the Dynamic Time Warping (DTW) algorithm to achieve sequence alignment. DTW is an algorithm used to measure the similarity between two time series data sequences of different lengths or with temporal distortion. It uses dynamic programming to find an optimal "warping path", allowing the sequences to be non-linearly stretched or compressed locally on the time axis to achieve the best match.
[0055] For example, the system maps wind power output sequences to industrial load sequences at specific times, and can establish an accurate point-to-point correspondence even if there is a time difference of less than 15 minutes between the two.
[0056] Therefore, according to the above implementation method, the system can achieve standardized processing of multi-source heterogeneous data, providing a high-quality data foundation for subsequent accurate matching. The alignment operation effectively eliminates matching errors caused by different data collection times, improving the timing accuracy of hourly green electricity transactions.
[0057] In some embodiments, the step of generating hourly green electricity transaction matching results by performing supply and demand characteristic analysis and optimization calculations through a supply and demand matching model includes: Based on the discretized production sequence and the discretized consumption sequence, a feature distance matrix is constructed between the production sequence and the consumption sequence. The feature distance matrix is used to quantify the degree of difference between the data at each time point of the production sequence and the data at each time point of the consumption sequence.
[0058] The feature distance matrix refers to a two-dimensional matrix with production sequence time points as rows and consumption sequence time points as columns, and the matrix element values are the Euclidean distances between the corresponding row and column time point data.
[0059] Specifically, the system can use vector difference operations to calculate the distance value at each location.
[0060] For example, for a wind farm output sequence [80,85,90] MW and a factory load sequence [75,82,88] MW, the characteristic distance at time point t1 is: Megawatts, based on which a 3×3 feature distance matrix is constructed.
[0061] Based on the feature distance matrix, a dynamic path planning algorithm is used to search for the optimal matching path, and the matching sequence is determined based on the optimal matching path.
[0062] The dynamic path planning algorithm refers to an optimization algorithm that finds the path with the minimum cumulative distance through a recursive approach.
[0063] Specifically, the system can use the DTW algorithm to perform path search. For example, the system searches for a path from (1,1) to (3,3) in the feature distance matrix that minimizes the total distance. The coordinates of the points traversed by the path constitute the optimal matching sequence, such as [(1,1),(2,2),(3,3)], which indicates that all three time points are perfectly matched.
[0064] In response to the matching sequence satisfying the applied load balancing constraints, hourly green electricity trading matching results are generated. The load balancing constraints refer to the condition that the difference between the generated electricity and the consumed electricity during the matching period does not exceed a preset threshold.
[0065] The preset threshold is set according to the power grid operation procedures, and is usually 5% to 10% of the matching power.
[0066] Specifically, the system can calculate the absolute difference between the electricity production points and the electricity consumption points within the matching time period.
[0067] For example, in a 3-hour matching period, if the electricity generated is 250 MWh and the electricity consumed is 240 MWh, the difference of 10 MWh is less than the threshold of 12.5 MWh (calculated at 5%), then the load balance constraint is satisfied.
[0068] Therefore, according to the above implementation method, the system can achieve accurate spatiotemporal matching of supply and demand curves, ensure the optimality of matching results through dynamic path planning, and ensure the feasibility of matching schemes by combining load balancing constraints, and finally generate reliable hourly green electricity trading matching schemes.
[0069] In some embodiments, based on the hourly green electricity transaction matching results, the transaction matching results are verified and consensus-based notarization is performed through a pre-defined blockchain network to generate a trusted transaction block containing the transaction matching results, including: The hourly green electricity transaction matching results are submitted to the transaction pool of the blockchain network, which includes green electricity production enterprise nodes, grid dispatch nodes, and electricity consumption enterprise nodes.
[0070] The transaction pool refers to a memory buffer used to temporarily store transaction data to be processed.
[0071] Specifically, the system can submit transaction data to the transaction pool through the Remote Procedure Call (RPC) interface. RPC is a communication protocol that allows computer programs to execute functions or procedures on another computer (server) over a network as if calling local functions, and it is the core technology for realizing function calls between distributed systems.
[0072] For example, the system submits the matching result of a 100 megawatt-hour green electricity transaction between a wind farm and a data center to the transaction pool for temporary storage in JSON (JavaScript Object Notation, a lightweight text data exchange format) format via HTTPS (Hypertext Transfer Protocol Secure).
[0073] After the transaction matching result passes the identity qualification verification and transaction compliance verification, the verified transaction matching result is packaged and a new block is generated using a preset consensus algorithm. The identity qualification verification and transaction compliance verification are performed by the verification nodes in the blockchain network.
[0074] The verification node refers to a specific node that is authorized to participate in transaction verification.
[0075] Specifically, verification nodes can use digital signature technology to verify the authenticity of the transacting parties' identities.
[0076] For example, the verification node uses a wind farm's digital certificate (X.509 format) to verify its identity and legitimacy, while checking whether the 200 MW of electricity traded is within the 300 MW remaining capacity of the grid transmission channel.
[0077] The new block is broadcast to all nodes in the blockchain network to achieve consensus confirmation on the validity and data consistency of the new block.
[0078] The consensus confirmation refers to the process by which nodes reach an agreement on the validity of a new block.
[0079] Specifically, the system can use the Byzantine Fault Tolerance (BFT) algorithm to achieve consensus confirmation.
[0080] For example, when 4 out of 5 nodes reach a consensus on the hash value of a new block, the consensus is considered complete, and the block is recognized as a valid block.
[0081] After reaching a consensus, the new block is added to the distributed ledger, generating a trusted transaction block corresponding to the transaction matching result. The distributed ledger is an immutable chain of transaction data records jointly maintained by all nodes in the blockchain network.
[0082] The "add" operation refers to linking a new block to the end of the blockchain via a hash pointer.
[0083] Specifically, the system can use the SHA-256 algorithm to calculate the hash value of a new block. The SHA-256 algorithm is a cryptographically secure hash algorithm that can map input data of arbitrary length to a unique and irreversible hash value of fixed length (256 bits). It is widely used in security fields such as data integrity verification, digital signatures, and blockchain.
[0084] For example, a new block is assigned a block height of 1588, and its block header contains the hash value 0x7d3a...c9b2 of the previous block (height 1587). This chain structure ensures the immutability of the data.
[0085] Therefore, based on the above implementation method, the system can establish a complete and trusted transaction evidence storage chain, ensuring the authenticity and integrity of transaction data through multi-node verification and consensus mechanisms, providing reliable technical support for hourly green electricity transactions. The immutability of the distributed ledger effectively prevents malicious modification of transaction data, enhancing the security and credibility of the entire transaction system.
[0086] In some embodiments, performing hourly green electricity transaction settlement based on trusted transaction blocks includes: Extract transaction matching results from trusted transaction blocks. The transaction matching results include the matched electricity amount, the matched timestamp, and the transaction party identifier.
[0087] The extraction operation refers to the process of obtaining the value of a specific field by parsing the blockchain data structure.
[0088] Specifically, the system can extract data by calling the query function of the smart contract.
[0089] For example, system calls The function extracts the matching transaction results from the transaction record at block height 1588, which has a matching electricity amount of 200 megawatt-hours, a timestamp of 10:00 on December 19, 2024, and transaction party identifiers of FD001 and EP002. A function is a query interface function provided by a smart contract or blockchain node. Its purpose is to retrieve and return the complete transaction record data on the blockchain based on a specified transaction hash (TxHash) as input parameter. Based on the transaction matching results, the settlement electricity volume and settlement amount of each transaction party are calculated through the settlement smart contract.
[0090] The settlement smart contract includes business logic such as electricity fee calculation rules and revenue sharing ratios.
[0091] Specifically, the system can trigger the contract. The method performs the calculation. The method is a core computation function pre-installed in the settlement smart contract. Its function is to automatically perform precise calculations of electricity fees, network access fees, and revenue sharing among all parties based on the verified transaction matching results.
[0092] For example, based on a transaction volume of 200 megawatt-hours and an agreed electricity price of 0.6 yuan / kWh, the settlement smart contract automatically calculates that the electricity user should pay 120,000 yuan in electricity fees, the power generator should receive 118,000 yuan in electricity fees, and the power grid company should collect 2,000 yuan in grid access fees.
[0093] Fine-grained green electricity certificates are generated based on the settled electricity volume, and these green electricity certificates are then linked to the corresponding trading party's account.
[0094] The binding operation refers to establishing an association between a certificate and an account in the registration system.
[0095] Specifically, the system can complete the binding by calling the certificate management system's API.
[0096] For example, the system generates certificate number GEC202412191001, which records 200 megawatt-hours of green electricity consumption rights, and binds the certificate to the environmental protection account of the electricity-consuming enterprise EP002.
[0097] The electricity quota and fund balance of each trading party are updated through the blockchain network to complete the hourly green electricity transaction settlement.
[0098] The update operation refers to modifying the numerical field of an account in the blockchain state database.
[0099] Specifically, the system can change the balance by sending a status update transaction.
[0100] For example, in block height 1589, it is recorded that: RMB 120,000 is deducted from the account of the electricity-consuming enterprise EP002, RMB 118,000 is added to the account of the power generation enterprise FD001, and RMB 2,000 is added to the grid account. At the same time, the green electricity quota statistics of all parties are updated.
[0101] Among them, the settlement smart contract is program code pre-deployed on the blockchain network and used to execute settlement logic, while the fine-grained green electricity certificate refers to a green electricity consumption right certificate issued on an hourly basis.
[0102] Specifically, the system can write smart contracts using Solidity (a statically typed high-level programming language for smart contracts, designed for writing and deploying automatically executable decentralized application logic on blockchain platforms such as the Ethereum Virtual Machine (EVM)) and deploy them to the Ethereum Virtual Machine (EVM) environment.
[0103] For example, a settlement smart contract contains the following core functions: Used for authentication, Used for monetary calculation. Used for certificate issuance.
[0104] Therefore, according to the above implementation method, the system can realize a fully automated transaction settlement process, ensure the accurate execution of settlement rules through smart contracts, accurately record environmental rights and interests using fine-grained green electricity certificates, and ultimately complete a credible, transparent and efficient green electricity transaction settlement.
[0105] In some embodiments, after the transaction matching result passes identity verification and transaction compliance verification, a preset consensus algorithm is used to package the verified transaction matching result and generate a new block, including: The transaction matching results submitted to the transaction pool are checked for duplicates using a Bloom filter, and the first occurrence of the transaction matching result is retained in the transaction pool.
[0106] The duplicate detection refers to the process of identifying and filtering processed duplicate transaction data.
[0107] Specifically, the system can perform hash mapping queries based on the bit array of the Bloom filter.
[0108] For example, the system uses a Bloom filter with 1 million bits to perform three hash operations on the transaction hash value. If all corresponding bits are 1, it is determined that the transaction may be duplicated and further verification is required; otherwise, it is directly retained.
[0109] The verification node verifies the identity information of the transaction participants in the transaction matching results based on the digital certificate, thus completing the identity and qualification verification.
[0110] The digital certificate is an electronic document containing a public key and identity information, issued by an authoritative certification authority.
[0111] Specifically, the system can use an X.509 standard format certificate for verification.
[0112] For example, the verification node uses the root certificate of a CA (Certificate Authority) to verify the validity period and signature legality of a photovoltaic power station's digital certificate, ensuring that the certificate status is normal.
[0113] The verification node determines the compliance of the traded electricity volume and price in the transaction matching results based on the real-time operation status information of the power grid and the market benchmark price information, thus completing the transaction compliance verification.
[0114] The real-time operating status information of the power grid includes real-time monitoring data such as line load rate and substation capacity.
[0115] Specifically, the system can obtain real-time data from the power grid dispatching system through the data bus.
[0116] For example, the verification node checks whether a 500 MWh transaction exceeds the remaining 600 MWh transmission capacity of the current transmission channel, and confirms that the transaction price of 0.52 yuan / kWh is within the market guidance price range of 0.48 to 0.55 yuan / kWh.
[0117] A verifiable random function algorithm is used to select block generation nodes from the blockchain network. The block generation nodes then package a batch of verified transaction matching results to generate new blocks.
[0118] The verifiable random function is a random number generation algorithm that can be publicly verified.
[0119] Specifically, the system can use the VRF (Verifiable Random Function) algorithm to calculate and select weights based on node staked equity and a random seed. The VRF algorithm is a cryptographic primitive capable of generating publicly verifiable random numbers. While outputting a seemingly random numerical value (or hash value), it generates a corresponding zero-knowledge proof. Any verifier can use this proof to confirm that the random number was indeed correctly calculated by a specific holder (holding the private key) based on specific inputs, and that the result is deterministic, unpredictable, and unmanipulated.
[0120] For example, the system selects the block generation node for this round based on the number of 1,000 to 5,000 staked tokens of each node, combined with the current block hash as a random seed.
[0121] Among them, identity and qualification verification includes confirming the qualifications of green power production enterprises and reviewing the access qualifications of power consumption enterprises; transaction compliance verification includes determining whether the transaction volume exceeds the available capacity of the power grid transmission channel and whether the transaction price deviates from a reasonable range.
[0122] Specifically, the system can establish a multi-level review mechanism to ensure the completeness of verification. For example, for the access review of newly established wind power companies, their qualification documents such as power business licenses and grid connection acceptance reports need to be verified simultaneously; for large transactions, dual compliance verification is required.
[0123] Therefore, according to the above implementation method, the system can ensure the legality and compliance of transaction data through a multi-verification mechanism and guarantee the fairness of block generation through a random selection mechanism, thereby constructing a secure and reliable hourly green electricity trading blockchain network. This design effectively prevents security issues such as duplicate transactions and identity theft, and improves the credibility and stability of the entire trading system.
[0124] In some embodiments, after consensus is reached, a new block is added to the distributed ledger to generate a trusted transaction block, including: Calculate the block header hash of the new block and link the new block to the latest block in the distributed ledger via a hash pointer.
[0125] Here, a hash pointer is a reference pointer that contains the hash value of the previous block.
[0126] Specifically, the system can use the SHA-256 algorithm to calculate the hash value of a new block.
[0127] For example, the system calculates the hash value of the new block as follows: 0x7d3a8c9b2e1f4a6d5c8e3b7a2f9d1e4c6b5a8d3e7f2a1b9c4e6d8, and use this hash value as the head pointer value for the next new block.
[0128] Based on the transaction matching results contained in the new block, update the state data of each transaction party's account in the blockchain network and generate a new state root hash.
[0129] The status data includes dynamic information such as account balance and transaction limit.
[0130] Specifically, the system can use a Merkle Patricia Trie (MPT) structure to manage state data. MPT is a hybrid tree data structure that combines the cryptographic verification properties of Merkle trees with the efficient storage properties of Patricia trees. It is widely used in blockchain systems (such as Ethereum) to organize and manage key-value pair data such as account states and transaction records. Its core function is to achieve efficient retrieval and updating of large-scale state data while ensuring data integrity and verifiability.
[0131] For example, based on the 10 transaction records in the new block, the system updates the account balances of the corresponding 20 transacting parties and calculates and generates a new state root hash: 0xa3d8f2e7c1b4a9d6e5f8c3b7a2d9e1f4.
[0132] The updated state data and the new state root hash are stored in the state database corresponding to the distributed ledger.
[0133] The state database uses a key-value pair storage structure.
[0134] Specifically, the system can use LevelDB (Level Database) for state storage. LevelDB is an open-source, high-performance, embedded key-value storage engine developed by Google. Its core design is based on a log structure merge tree model, which is suitable for application scenarios that require high-throughput writes and efficient range queries. It is often used as the underlying local state storage for distributed systems, blockchain nodes, etc.
[0135] For example, the system uses the account address as the key and information such as account balance and number of transactions as the value to form a key-value pair and stores it in the state database. At the same time, it writes the new state root hash into the block header.
[0136] Historical transaction data in the distributed ledger is stored in shards based on geographical region or business type, and status change information is synchronized between different data shards through state channels.
[0137] Among them, fragmented storage refers to the technique of dividing and storing a complete dataset according to specific rules.
[0138] Specifically, the system can segment data according to provincial administrative divisions.
[0139] For example, transaction data for East China is stored in shard 1, and transaction data for North China is stored in shard 2. Each shard periodically synchronizes important status changes through a status channel.
[0140] Among them, the state root hash refers to the cryptographic digest value that represents the global account state data of the blockchain network at a specific block height, and the state channel refers to the auxiliary communication link used for high-frequency state interaction and verification outside the main chain of the blockchain network.
[0141] Specifically, the system can achieve state channel communication by establishing point-to-point encrypted connections.
[0142] For example, a state channel is established between two shards to synchronize the state changes of important accounts every 5 minutes, and only the final state summary is submitted to the main chain.
[0143] Therefore, based on the above implementation method, the system can achieve efficient storage and state synchronization of the distributed ledger, improve system processing capabilities through sharding technology, and reduce the main chain load using a state channel mechanism, thereby constructing a scalable hourly-level green electricity trading blockchain infrastructure. This architecture ensures data security while improving the overall performance of the system, meeting the high-concurrency processing requirements of large-scale green electricity trading scenarios.
[0144] Figure 2 This is a structural block diagram of an hourly green electricity trading system for enhancing the consumption potential of new energy, according to an embodiment of the present invention.
[0145] like Figure 2 As shown, this hourly green electricity trading system, designed to enhance the potential of new energy consumption, includes: The production and consumption data acquisition module 210 is used to acquire hourly green electricity production and consumption data, and to perform time series alignment processing on the production and consumption data.
[0146] The transaction matching result generation module 220 is used to input the production data and consumption data after time series alignment into a preset supply and demand matching model, and perform supply and demand characteristic analysis and optimization calculation through the supply and demand matching model to generate hourly green electricity transaction matching results.
[0147] The trusted transaction block generation module 230 is used to verify and consensus-store the transaction matching results based on the hourly green electricity transaction matching results through a preset blockchain network, and generate trusted transaction blocks containing the transaction matching results.
[0148] The green electricity transaction settlement module 240 is used to perform hourly green electricity transaction settlement based on trusted transaction blocks.
[0149] The specific functions and examples of each module and submodule of the device in this embodiment of the invention can be found in the relevant descriptions of the corresponding steps in the above method embodiments, and will not be repeated here.
[0150] According to embodiments of the present invention, the above-described method of the present invention can be applied to an electronic device and a readable storage medium.
[0151] Figure 3A schematic block diagram of an example electronic device 600 that can be used to implement embodiments of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.
[0152] like Figure 3 As shown, the electronic device 600 includes a computing unit 601, which can perform various appropriate actions and processes based on a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. The RAM 603 may also store various programs and data required for the operation of the electronic device 600. The computing unit 601, ROM 602, and RAM 603 are interconnected via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0153] Multiple components in electronic device 600 are connected to I / O interface 605, including: input unit 606, such as keyboard, mouse, etc.; output unit 607, such as various types of displays, speakers, etc.; storage unit 608, such as disk, optical disk, etc.; and communication unit 609, such as network card, modem, wireless transceiver, etc. Communication unit 609 allows electronic device 600 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0154] The computing unit 601 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 performs the various methods and processes described above, such as an hourly green electricity trading method to enhance the potential of renewable energy consumption. For example, in some embodiments, an hourly green electricity trading method to enhance the potential of renewable energy consumption can be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 600 via ROM 602 and / or communication unit 609. When the computer program is loaded into RAM 603 and executed by the computing unit 601, one or more steps of the hourly green electricity trading method to enhance the potential of renewable energy consumption described above can be performed. Alternatively, in other embodiments, the computing unit 601 may be configured, by any other suitable means (e.g., by means of firmware), to execute an hourly green electricity trading method to enhance the potential for renewable energy consumption.
[0155] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0156] The program code used to implement the methods of the present invention can be written in any combination of one or more programming languages. This program code can be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing device, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code can be executed entirely on the machine, partially on the machine, as a standalone software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.
[0157] In the context of this invention, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. Machine-readable media can include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0158] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).
[0159] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.
[0160] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact via communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other. Servers can be cloud servers, servers in distributed systems, or servers incorporating blockchain technology.
[0161] It should be understood that the various forms of processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution disclosed in this invention can be achieved, and this is not limited herein.
[0162] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the principles of this invention should be included within the scope of protection of this invention.
Claims
1. An hour-level green electricity transaction method for promoting new energy consumption potential, characterized in that, The method comprises the following steps: obtaining production data and consumption data of hourly green power, and performing time series alignment processing on the production data and the consumption data; inputting the production data and the consumption data after the time series alignment processing into a preset supply-demand matching model, performing supply-demand feature analysis and optimization calculation through the supply-demand matching model, and generating an hourly green power transaction matching result; based on the hourly green power transaction matching result, performing verification and consensus storage of the transaction matching result through a preset blockchain network, and generating a trusted transaction block corresponding to the transaction matching result; performing hourly green power transaction settlement according to the trusted transaction block.
2. The method of claim 1, wherein, The production data includes power generation plan data and real-time output data of a green power production enterprise, and the consumption data includes power consumption load data and multi-element load characteristic data of a power consumption enterprise; the method of obtaining production data and consumption data of hourly green power, and performing time series alignment processing on the production data and the consumption data comprises the following steps: comprising: collecting the power generation plan data and the real-time output data from an energy management system of the green power production enterprise to generate a production load time series; collecting the power consumption load data and the multi-element load characteristic data from an intelligent metering terminal of the power consumption enterprise or a data platform of a load aggregator to generate a consumption load time series; performing discretization processing on the production load time series and the consumption load time series to obtain a discretized production sequence and a discretized consumption sequence; based on the discretized production sequence and the discretized consumption sequence, performing time point mapping and alignment operation to obtain the production data and the consumption data after the time series alignment processing.
3. The method of claim 2, wherein, The step of generating an hourly green power transaction matching result through the supply-demand matching model comprises the following steps: based on the discretized production sequence and the discretized consumption sequence, constructing a feature distance matrix between the production sequence and the consumption sequence, the feature distance matrix being used to quantify the difference between the data at each time point of the production sequence and the data at each time point of the consumption sequence; based on the feature distance matrix, searching for an optimal matching path by using a dynamic path planning algorithm, and determining a matching sequence based on the optimal matching path; in response to the matching sequence satisfying an applied load balance constraint condition, generating the hourly green power transaction matching result, the load balance constraint condition being a condition that requires the difference between the production power and the consumption power in a matching period to be less than a preset threshold.
4. The method of claim 3, wherein, The step of generating a trusted transaction block containing the transaction matching result based on the hourly green power transaction matching result and performing verification and consensus storage of the transaction matching result through a preset blockchain network comprises the following steps: submitting the hourly green power transaction matching result to a transaction pool of the blockchain network, the blockchain network including a green power production enterprise node, a power grid dispatching node, and a power consumption enterprise node; After the transaction matching result passes the identity qualification verification and the transaction compliance verification, a preset consensus algorithm is used to package and generate a new block for the verified transaction matching result, and the identity qualification verification and the transaction compliance verification are performed by a verification node in the blockchain network; The new block is broadcast to all nodes in the blockchain network for consensus confirmation of the validity and data consistency of the new block; After consensus is reached, the new block is added to a distributed ledger to generate a trusted transaction block corresponding to the transaction matching result, and the distributed ledger is a chain of transaction data records that is maintained by all nodes in the blockchain network and is tamper-proof.
5. The method of claim 4, wherein, The hour-level green electricity transaction settlement according to the trusted transaction block includes: Extracting the transaction matching result from the trusted transaction block, the transaction matching result including matched power, matched timestamp, and transaction party identifier; Based on the transaction matching result, the settlement smart contract is used to calculate the settlement power and settlement amount of each transaction party; According to the settlement power, a fine-grained green power certificate is generated, and the green power certificate is bound to the corresponding transaction party account; The electricity quota and fund balance of each transaction party are updated through the blockchain network to complete the hour-level green electricity transaction settlement; The settlement smart contract is a program code for executing settlement logic pre-deployed on the blockchain network, and the fine-grained green power certificate refers to a green power consumption right certificate issued in units of hours.
6. The method of claim 4, wherein, After the transaction matching result passes the identity qualification verification and the transaction compliance verification, a preset consensus algorithm is used to package and generate a new block for the verified transaction matching result, and the identity qualification verification and the transaction compliance verification are performed by a verification node in the blockchain network; The transaction matching result submitted to the transaction pool is detected for duplication by a Bloom filter, and the first occurrence of the transaction matching result is retained in the transaction pool; The identity information of the transaction participants in the transaction matching result is verified by the verification node based on a digital certificate to complete the identity qualification verification; The transaction power and transaction price in the transaction matching result are determined for compliance by the verification node according to real-time operating state information and market benchmark price information of the power grid to complete the transaction compliance verification; A verifiable random function algorithm is used to select a block generation node from the blockchain network, and the block generation node packages a batch of verified transaction matching results to generate the new block; The identity qualification verification includes confirmation of the qualification of green power generation enterprises and audit of the access qualification of electricity consumption enterprises, and the transaction compliance verification includes determination of whether the transaction power exceeds the available capacity of the power grid transmission channel and determination of whether the transaction price deviates from a reasonable range.
7. The method of claim 6, wherein, After consensus is reached, the new block is added to a distributed ledger to generate a trusted transaction block corresponding to the transaction matching result, and the distributed ledger is a chain of transaction data records that is maintained by all nodes in the blockchain network and is tamper-proof. According to a transaction matching result contained in the new block, state data of each transaction party account in the blockchain network is updated, and a new state root hash is generated; The updated state data and the new state root hash are stored in a state database corresponding to the distributed ledger; Historical transaction data in the distributed ledger is stored in slices based on geographical areas or business types, and state change information is synchronized between different data slices through a state channel; The state root hash refers to a cryptographic digest value representing global account state data of the blockchain network at a specific block height, and the state channel refers to an auxiliary communication link for high-frequency state interaction and verification outside the main chain of the blockchain network.
8. An hour-level green electricity transaction system for promoting new energy consumption potential, characterized in that, Comprise: A production and consumption data acquisition module for acquiring hourly green power production data and consumption data, and performing time series alignment processing on the production data and consumption data; A transaction matching result generation module for inputting the time series alignment processed production data and consumption data into a preset supply and demand matching model, performing supply and demand feature analysis and optimization calculation through the supply and demand matching model, and generating an hourly green power transaction matching result; A trusted transaction block generation module for performing verification and consensus evidence on the transaction matching result through a preset blockchain network based on the hourly green power transaction matching result, and generating a trusted transaction block containing the transaction matching result; A green power transaction settlement module for performing hourly green power transaction settlement according to the trusted transaction block.
9. An electronic device, comprising: Comprise: At least one processor; And a memory connected in communication with the at least one processor; Wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-7.
10. A non-transitory computer-readable storage medium having stored thereon computer instructions, wherein the computer instructions, when executed by a processor, cause the processor to perform the method of any one of claims 1-9. Wherein, The computer instructions are used to make the computer execute the method according to any one of claims 1-7.
Citation Information
Patent Citations
Green power consumption classification accounting and right traceability method and system of multi-dimensional account
CN119515411A