Interconnected photovoltaic micro-grid group decentralized energy transaction system based on block chain
By introducing a blockchain-based decentralized energy trading system into the traditional energy trading system, the problems of single point failure, easy attack, high maintenance costs and low transaction efficiency of the centralized system are solved, and more stable, efficient and secure energy trading is achieved.
Patent Information
- Application Number
- CN202510055663.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-14
- Publication Date
- 2025-05-30
- Estimated Expiration
- 2045-01-14
AI Technical Summary
Traditional centralized energy trading systems have problems such as risk of single point failure, easy to become targets of attack, high maintenance costs and low transaction efficiency, especially in the context of the rapid development of distributed renewable energy.
The decentralized energy trading system of interconnected photovoltaic microgrid group based on blockchain is adopted. By setting up a photovoltaic microgrid group and a blockchain energy trading platform, the two-way connection between the photovoltaic microgrid is realized, and an information collection module, prediction function module, transaction function module and block verification module are set up in each photovoltaic microgrid to perform energy transactions and block verification.
It improves the stability and efficiency of the power trading network, realizes self-produced, used and sold energy, balances the net load of the photovoltaic microgrid, reduces the single-point failure risk and maintenance cost of the system, and enhances the security of the system and the transparency of transactions.
Smart Images

Figure CN120070051A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of energy trading, and particularly to a decentralized energy trading system for interconnected photovoltaic microgrid groups based on blockchain. Background Art
[0002] With the development and utilization of various distributed renewable energies represented by photovoltaic and wind power, the power grid is gradually evolving from a centralized smart grid to a decentralized new power system. However, a series of serious problems have emerged in the traditional centralized energy trading mechanism, and it is urgent to propose new solutions to overcome these challenges.
[0003] Disadvantages of the prior art: First, there is a risk of single-point failure in the centralized system, that is, if the central node of the system fails, the entire system will be paralyzed, affecting the continuity of business. Second, the centralized system is more likely to become a target of attack because the attacker only needs to break through one node to prevent the normal operation of the entire system, causing huge losses. Third, the maintenance and operation of the centralized system require high costs. Especially with the continuous penetration of various distributed renewable energies, the huge amount of energy trading data and high-frequency trading requests will lead to low energy trading efficiency of the entire system. Summary of the Invention
[0004] A decentralized energy trading system for interconnected photovoltaic microgrid groups based on blockchain provided by the present invention effectively improves the stability and efficiency of the power trading network.
[0005] To achieve the above object, a decentralized energy trading system for interconnected photovoltaic microgrid groups based on blockchain provided by the present invention is characterized in that: a photovoltaic microgrid group and a blockchain energy trading platform are provided, and the photovoltaic microgrid group is bidirectionally connected to the blockchain energy trading platform;
[0006] The photovoltaic microgrid group includes N photovoltaic microgrids, N≥3, and each photovoltaic microgrid is provided with an information collection module, a prediction function module, a trading function module, and a block verification module connected in sequence;
[0007] The information collection module is connected to a meteorological sensor network, at least two power users, and at least two photovoltaic power generation stations. The information collection module is used to collect the electricity consumption information of all power users in the coverage area of the current photovoltaic microgrid and the power generation information of all photovoltaic power generation stations at the current trading moment, and collect environmental meteorological information by using the meteorological sensor network deployed in the coverage area of the current photovoltaic microgrid, and then store the electricity consumption information, power generation information, and environmental meteorological information in the edge server as a historical data set for training the prediction function module;
[0008] The prediction function module is used to perform predictions on the photovoltaic power generation and electricity demand at the next trading moment based on the historical data set, obtain the photovoltaic power generation information and electricity demand information of the current photovoltaic microgrid at the next trading moment, and calculate the net load based on the photovoltaic power generation information and electricity demand information;
[0009] The trading function module is used to execute peer-to-peer energy trading in the blockchain energy trading platform according to the energy deficit or surplus information generated by the net load, purchase or sell energy as needed, and generate a smart contract;
[0010] The block verification module is responsible for executing the blockchain consensus mechanism to achieve block verification or generation of the energy trading smart contract.
[0011] Through the above design, each network node, that is, the physical layer of the photovoltaic microgrid, consists of several dispersed small-scale photovoltaic power generation stations integrated with energy storage and electricity users. At the energy agent layer, each network node is equipped with an edge server and a communication network to execute functions such as information collection, prediction, trading, and block verification. According to the characteristics of decentralization and immutability of blockchain technology, the present invention promotes spontaneous energy trading between photovoltaic microgrids, balances their own net load, and realizes self-generation, self-use, and self-sale of energy, thereby achieving the technical effects of enhancing the stable energy trading market and promoting the development of clean energy such as photovoltaic power generation; realizing the trading architecture of photovoltaic microgrid groups of different scales, and further enhancing the stability and efficiency of the power trading network.
[0012] Preferably: The information collection module is connected and communicates with the prediction function module through a programmable interface. The information collection module is provided with a user electricity consumption information collection module, a photovoltaic power generation information collection module, and a climate condition information collection module;
[0013] Among them, the user electricity consumption information collection module is used to collect and record the historical electricity consumption information of all users in the current photovoltaic microgrid area, providing a reference basis for the subsequent transaction price formulation;
[0014] The photovoltaic power generation information collection module is used to collect and record the historical power generation information of all distributed photovoltaic power stations in the current photovoltaic microgrid area, providing a reference basis for the subsequent transaction price formulation;
[0015] The climate condition information collection module is used to collect and record the historical environmental meteorological information in the current photovoltaic microgrid area, providing a meteorological data set for the subsequent photovoltaic power generation prediction model.
[0016] Preferably: The environmental meteorological information includes, but is not limited to, irradiance, temperature, humidity, and wind speed information in the microgrid area.
[0017] The climate condition information collection module is specifically used to measure relevant meteorological conditions such as irradiance, temperature, humidity, and wind speed that affect the photovoltaic power generation in the photovoltaic microgrid area. After obtaining relevant information, it is stored as a data set according to its specific geographical location to guide the establishment of photovoltaic power stations and the prediction of photovoltaic power generation in the entire area.
[0018] Preferably, the prediction function module is provided with a deep neural network DNN and a long short-term memory network LSTM. The deep neural network DNN and the long short-term memory network LSTM are used to extract the time dimension features and space dimension features in the historical data set and output the photovoltaic power generation information and electricity demand information of the current photovoltaic microgrid at the next trading moment.
[0019] The prediction function module is specifically used to predict the user electricity consumption information and photovoltaic power generation information at the next moment. After obtaining relevant information, it calculates the net load of electricity to guide the power adjustment and trading strategy in the entire area.
[0020] Preferably, the trading function module is provided with a trading party identity recognition unit, a trading price adjustment unit, and a trading matching unit;
[0021] Among them, the trading party identity recognition unit is used to generate a purchase smart contract or a sale smart contract for the corresponding photovoltaic microgrid according to the energy deficit or surplus information of the current photovoltaic microgrid;
[0022] The trading price adjustment unit is used to adjust the electricity trading price at each trading moment according to the electricity price adjustment mechanism, divide the trading cycle according to the peak period and non-peak period of the electricity transaction, and then obtain the initial selling electricity price based on the total transaction electricity volume according to the electricity consumption demand and electricity selling demand at the next moment;
[0023] The trading matching unit is used to adjust its own contract quotation during the matching process of the generated purchase smart contract and sale smart contract on the blockchain energy trading platform; in order to avoid malicious manipulation or vicious competition in the energy trading market, the blockchain energy trading platform adopts a double-blind form in which the trading contract parties do not share the price for contract matching. The blockchain energy trading platform conducts multiple rounds of matchmaking. When no transaction is reached in each round of contract, the buyer and the seller respectively increase and decrease their own contract quotations.
[0024] Preferably, the trading cycle division rule is as follows:
[0025] The division of the trading cycle is mainly due to the intermittency and volatility of photovoltaic power output. To improve the practicality of the trading mechanism, more refined and unequal trading cycles are adopted for trading settlement. The main output time of photovoltaic power generation is from 6:00 to 18:00, and there is almost no output at other times. For off-grid photovoltaic microgrids, only by dispatching the reserve energy of the energy storage system can the electricity demand be met. The reserve energy owned by the energy storage system is relatively stable, and the trading cycle can be appropriately increased. In addition, the electricity consumption of users fluctuates violently from 6:00 to 18:00.
[0026] To formulate more reasonable electricity prices during peak and off-peak electricity consumption periods respectively, the following more refined and unequal trading cycle division rules are adopted: Taking 24 hours a day as a unit, the two non-peak electricity consumption periods from 0:00 to 6:00 and from 18:00 to 24:00 are divided into 6 trading cycles, each trading period is 2 hours, and they are respectively recorded in chronological order as h 1 ,h 2 ,h 3 and h 28 ,h 29 ,h 30 ; The period from 6:00 to 18:00 is the peak electricity consumption period. To perform more accurate energy allocation during this period, a more refined trading cycle division is adopted in this period. It is divided into 24 trading cycles, each trading period is 0.5 hours, and they are respectively recorded in chronological order as h 4 ,h 5 ,…,h 27 . Therefore, a day is divided into 30 trading periods.
[0027] The identification of the photovoltaic microgrid identity is mainly because each photovoltaic microgrid is equipped with an edge server, and the built-in prediction function module can be used to predict the energy demand and photovoltaic power generation in the trading period according to historical electricity consumption data and photovoltaic power generation data. Generally speaking, the energy demand and photovoltaic power generation of different photovoltaic microgrids in different trading periods are dynamically changing.
[0028] The trading party identity identification unit records the energy demand and photovoltaic power generation predicted by the i-th photovoltaic microgrid in the trading period t∈{h 1 ,h 2 ,…,h 30} as P i,l (t),P i,g (t), i = 1,…, N, calculates the difference between the energy demand and the photovoltaic power generation to obtain the net load P i,net (t) = P i,l (t) - P i,g (t), i = 1,…, N;
[0029] P i,net (t) < 0 indicates an energy surplus of the photovoltaic microgrid i, P i,net(t) > 0 indicates an energy deficit of the photovoltaic microgrid i, and P i,net (t) = 0 indicates the energy supply - demand balance of the photovoltaic microgrid i;
[0030] For P i,net (t) ≠ 0, t ∈ {h 1 , h 2 , …, h 30} of all trading periods, the prediction function module forwards the P i,net (t) information to the trading function module. The trading function module identifies the photovoltaic microgrid with a negative net load as an energy seller and generates a sell smart contract; it identifies the photovoltaic microgrid with a positive net load as an energy buyer and generates a purchase smart contract, that is:
[0031]
[0032] The contract matching and electricity price adjustment mechanism is mainly from an economic perspective. In any transaction, the interests between the buyer and the seller are in conflict. On the one hand, in order to reduce the energy usage cost, the buyer will try to lower the quotation as much as possible. On the other hand, in order to obtain more sales revenue, the seller will try to raise the quotation as much as possible. To facilitate the transaction, both the buyer and the seller need to adjust their quotations.
[0033] The multi - agent peer - to - peer network formed by the interconnected photovoltaic microgrid group is interconnected. The blockchain energy trading platform adopts multi - round matching to execute contract matching according to the net load P i,net (t) in the sell smart contract and the purchase smart contract; the photovoltaic microgrid with energy surplus, i.e., the seller, provides a pre - determined sell smart contract, and the quotation is denoted as while the photovoltaic microgrid with energy deficit, i.e., the buyer, provides a pre - determined purchase smart contract, and the quotation is denoted as
[0034] The goal of both the buyer and the seller is to match and execute their own contracts to meet their respective net load requirements. The contract matching process is as follows:
[0035] The first step: The seller starts from the initial quotation and provides lower and lower sell quotations to potential buyers; the buyer starts from the initial quotation and provides higher and higher purchase quotations to potential sellers;
[0036] The second step: For the r - th round of matching, consider the following situation for autonomous contract matching: If the contract is concluded at the price of ; if The buyer moves on to the next seller contract and continues contract matching; if there are unmatched contracts after this round of trading, the seller lowers the asking price; the buyer raises the bid price and continues the next round of matching.
[0037] Step 3: All contract matching is completed, and the trading for this trading period ends.
[0038] Preferably, the electricity price adjustment mechanism includes a seller electricity price adjustment rule and a buyer electricity price adjustment rule; taking the i-th photovoltaic microgrid as an example, for simplicity, the photovoltaic microgrid index i is omitted in the following description.
[0039] The seller's electricity price adjustment is based on the fact that if the surplus energy is not sold, it can only be stored or discarded; if the transaction cannot be reached, the loss of energy discard has to be borne, so it is necessary to appropriately lower the asking price. In addition, due to the real-time nature of the power generation of the photovoltaic power station and the power consumption of the power users, and the randomness of the charging and discharging behavior of the energy storage device within a trading period, the specific charging and discharging rates are not considered, but the degradation cost caused by the overcharging and discharging behavior of the energy storage device to the service life of the device is converted into the depreciation cost of the photovoltaic device.
[0040] The seller electricity price adjustment rule is as follows:
[0041] In trading period t, if P i,net (t) < 0, it is determined that the photovoltaic microgrid i is an energy seller, and the trading function module generates a selling smart contract, including the surplus energy to be sold and the asking price;
[0042] The asking price for the r-th round of matching is calculated as follows:
[0043]
[0044] where is the initial asking price, C bss is the operating cost of the energy storage device, P batt is the capacity of the energy storage device, C life is the depreciation cost of the photovoltaic device, P ini is the installed capacity of the photovoltaic device, C cur is the energy discard cost, α is the energy discard ratio; C tr is the energy transmission cost, and the energy transmission cost depends on the energy transmission distance and quantity; {A a,b} is the transmission distance matrix of the photovoltaic microgrid group, a is the buyer index, b is the seller index; A a,b represents the transmission distance between buyer a and seller b; tanh(r) is an inverse proportional function, representing a trend in price calculation.
[0045] Initial sales offer Determined based on the following rules: According to economic principles, price is inversely proportional to the relationship between supply and demand. When supply is greater than demand, the price will decrease; when supply is less than demand, the price will increase. In the interconnected photovoltaic microgrid group energy trading market, sellers attempt to sell energy at a price higher than the export electricity price of the grid company to obtain higher profits. To ensure market stability and prevent sellers from manipulating prices, the initial sales offer should be set with a maximum threshold referring to the export electricity price of the grid company Different from many current energy markets that mainly adopt time-of-use electricity price rules, the present invention comprehensively considers the changes in time and electricity consumption, and further calculates the supply-demand ratio based on the photovoltaic power generation and electricity demand in all 30 trading periods divided according to the daily peak and off-peak electricity consumption periods
[0046] Determine the initial selling offer based on market economy principles The calculation expression is as follows:
[0047]
[0048] Among them, min is the minimum value function, represents the export electricity price of the grid company, represents the import electricity price of the grid company, represents the initial selling offer at a certain moment, and the function tanh(x)=(e x -e -x ) / (e x +e -x ), e is a constant, and SDR represents the supply-demand ratio of photovoltaic microgrid's daily energy, defined as represents the total supply, that is, the surplus energy volume in 30 trading periods, represents the total demand, that is, the lacking energy volume in 30 trading periods
[0049] If the submitted smart contract is not matched in the first round, the seller reduces the sales offer by considering factors such as the operating cost of the energy storage device, the depreciation cost of the photovoltaic device, and the energy transmission cost
[0050] The buyer's electricity price adjustment rule is as follows:
[0051] The buyer's electricity price adjustment is based on the fact that if the deficit energy is not purchased, either obtain energy supplementation from the energy storage device or turn off the electrical equipment to balance the net load. Therefore, it is necessary to appropriately increase the purchase offer
[0052] In trading period t, if P i,net (t)>0, it is determined that the photovoltaic microgrid i is an energy buyer, and set The trading function module generates a purchase smart contract, including the required deficit energy and the purchase offer;
[0053] The purchase offer for the r - th round of matching The calculation expression is as follows:
[0054]
[0055] Among them, is the initial purchase offer, C bss is the operating cost of the energy storage device, P batt is the capacity of the energy storage device, C life is the depreciation cost of the photovoltaic device, P ini is the installed capacity of the photovoltaic device, C sh is the load shedding cost, and β is the load shedding ratio. Only when the deficit energy is higher than the energy storage capacity of the energy storage device per round, there is a load shedding situation, and the load shedding amount per round is
[0056] Initial purchase offer is determined based on the following rules: In the energy trading market of the interconnected photovoltaic micro - grid group, the buyer tries to purchase energy at a price lower than the grid company's inlet price to reduce the electricity cost. To ensure market stability and avoid price manipulation by the buyer, the initial purchase offer should set a minimum threshold with reference to the grid company's inlet price
[0057] Furthermore, calculate the supply - demand ratio SDR based on the photovoltaic power generation and electricity demand of all 30 trading periods on the day before, and determine the initial purchase offer based on the market economy principle The calculation expression of
[0058]
[0059] Among them, max is the maximum value function, represents the initial purchase offer at a certain moment.
[0060] If the submitted smart contract is not matched in the first round, the buyer increases the purchase offer by considering factors such as the operating cost of the energy storage device, the depreciation cost of the photovoltaic device, and the load shedding cost.
[0061] Preferably: The block verification module is provided with a contract data encryption unit, a blockchain transaction settlement unit, and a consensus mechanism verification unit;
[0062] Among them, the contract data encryption unit is used to encrypt the electricity quantity and price information in the smart contract generated by the trading function module with a secret key, and then upload the encrypted smart contract to the blockchain energy trading platform for matching. Only the smart contracts uploaded by authorized legal photovoltaic microgrids have the corresponding decryption keys that meet a specific attribute set, and contract matching operations are performed; this method not only ensures data privacy and security, but also ensures the legality and compliance of transactions.
[0063] The consensus mechanism verification unit is used to verify the successfully matched smart contract by using the consensus mechanism, confirm the effectiveness and legality of the smart contract, and then link the block generated by the verified legal smart contract to the blockchain.
[0064] The blockchain transaction settlement unit generates a ledger copy according to the distributed ledger of the blockchain, and then sends the ledger copy to the photovoltaic microgrid serving as a verification node, and each verification node maintains a ledger copy.
[0065] The distributed ledger is composed of blocks linked into a blockchain, and each block is composed of the detailed information of the final smart contract successfully matched on the blockchain energy trading platform, including the network addresses of the buyer and the seller, the trading volume, the contract execution price, the contract execution timestamp, and the hash value from the previous block, realizing a trusted settlement of energy transactions.
[0066] Through the above design, taking advantage of the decentralized and immutable characteristics of blockchain technology, the contract information reached by the transaction is generated into a distributed ledger, propagated to each verification node for a consensus mechanism vote, and finally the valid blocks passed the verification are linked to the blockchain.
[0067] Preferably: the consensus mechanism is a blockchain consensus mechanism based on the cascade of PoR and Ripple. Through the POR mechanism, a part of the photovoltaic microgrids with higher trading activity are selected from all photovoltaic microgrids, and then the selected photovoltaic microgrids are used as the verification nodes of the Ripple consensus mechanism, specifically as follows:
[0068] First, execute the PoR mechanism. Each photovoltaic microgrid, that is, the network node, calculates its own reputation value according to the number of transactions participated in during the current trading period and the proportion of the trading volume in all transactions, and broadcasts its own reputation value to all network nodes; each network node sorts all network nodes including itself according to the reputation value, and selects a part of the network nodes with high reputation values as the verification node set, and the network nodes in the verification node set have the opportunity to participate in consensus verification and block generation.
[0069] Then execute the Ripple algorithm. All verification nodes selected based on PoR adopt a voting mechanism to verify the newly generated block. The consensus process is as follows: First, transaction verification: When a certain node in the verification node set receives the transaction information, that is, the successfully matched smart contract, it verifies the validity of the transaction information through the local ledger data. Only legal transactions will be accepted and enter the consensus process. Second, proposal broadcasting: This verification node packages the verified transaction information to be confirmed into a proposal and broadcasts it to other nodes in the verification node set. Third, voting and confirmation: The verification nodes that receive the proposal verify the transaction information in the proposal and vote according to their own ledger status. After more than 50% of the verification nodes vote to pass the proposal, the transaction is confirmed and enters the next round of consensus process. Proposals that do not exceed 50% are reserved for confirmation in the next round of consensus process. Fourth, increase the voting threshold: In each round of consensus process, gradually increase the voting threshold to ensure that there are enough verification nodes participating in the consensus process and improve the security and credibility of transaction information. Fifth, final confirmation: When a certain proposal obtains more than 80% of the verification node votes to pass, the blockchain network reaches an agreement. This proposal will be officially confirmed, and the verification node that initially formed the proposal will generate a new block and link it to the blockchain.
[0070] Preferably, the purpose of executing the PoR mechanism is to select a set of verification nodes from all network nodes, and the basis is the node reputation value. The expression of the reputation value of the i-th network node in the trading period t is as follows:
[0071]
[0072] Among them, κ represents the penalty indicator. To avoid the centralization trend of verification nodes, when a certain node becomes a verification node three times in a row, when calculating the node reputation value for the fourth time, it is stipulated that κ = 0. M(t - 1) represents the total number of transactions of all network nodes in the trading period t - 1, and m i (t - 1) represents the number of transactions of network node i in the trading period t - 1; P total (t - 1) represents the total trading volume of all network nodes in the trading period t - 1, and P i (t - 1) represents the trading volume of network node i in the trading period t - 1.
[0073] The beneficial effects of the present invention are as follows: First, predict the net load of the microgrid in the next trading period based on historical power generation data and power consumption demand information, calculate the initial quotes of both buyers and sellers based on the energy supply-demand ratio, and design a power price adjustment mechanism. Adopt multiple rounds of matching to promote the success of energy transactions and achieve win-win results to the greatest extent. Then, design a consensus mechanism based on the cascade of PoR and Ripple to ensure the security of transaction settlement and the integrity of transaction information. Furthermore, it can realize the transaction architecture of photovoltaic microgrid groups of different scales, and then improve the stability and efficiency of the power trading network.
[0074] Taking multiple adjacent administrative villages as a unit, a photovoltaic microgrid is formed, and all the photovoltaic microgrids finally form an off-grid interconnected photovoltaic microgrid group. Combining the intermittent and fluctuating characteristics of photovoltaic power output, the present invention adopts a more refined and unequal trading cycle to execute energy transactions, realizes self-production, self-use, and self-sale of energy, and achieves dynamic balance between supply and demand through energy sharing. It can not only guarantee the electricity consumption needs of residential users and industrial and commercial users in this area, but also avoid the grid connection impact on the large grid caused by the intermittency and volatility of photovoltaic power generation. Description of the Drawings
[0075] Figure 1 It is a framework diagram of a decentralized energy trading system for an interconnected photovoltaic microgrid group based on blockchain in the embodiment;
[0076] Figure 2 It is a schematic diagram of the trading mechanism process in the embodiment. Detailed Embodiment
[0077] The present invention will be further described in detail below in conjunction with the drawings and specific examples. The following embodiments or drawings are used to illustrate the present invention, but not to limit the scope of the present invention.
[0078] A decentralized energy trading system for an interconnected photovoltaic microgrid group based on blockchain is provided with a photovoltaic microgrid group and a blockchain energy trading platform, and the photovoltaic microgrid group is bidirectionally connected to the blockchain energy trading platform;
[0079] The photovoltaic microgrid group includes N photovoltaic microgrids, N≥3, and each photovoltaic microgrid is provided with an information collection module, a prediction function module, a trading function module, and a block verification module connected in sequence;
[0080] The information collection module is connected to a meteorological sensor network, at least two power users, and at least two photovoltaic power generation stations. The information collection module is used to collect the electricity consumption information of all power users in the coverage area of the current photovoltaic microgrid and the power generation information of all photovoltaic power generation stations at the current trading moment, and collect environmental meteorological information by using the meteorological sensor network deployed in the coverage area of the current photovoltaic microgrid, and then store the electricity consumption information, power generation information, and environmental meteorological information in the edge server as a historical data set for training the prediction function module;
[0081] The prediction function module is used to predict the photovoltaic power generation and electricity demand at the next trading moment according to the historical data set, obtain the photovoltaic power generation information and electricity demand information of the current photovoltaic microgrid at the next trading moment, and calculate the net load according to the photovoltaic power generation information and electricity demand information;
[0082] The trading function module is used to execute peer-to-peer energy trading in the blockchain energy trading platform according to the energy deficit or surplus information generated by the net load, purchase or sell energy as needed, and generate a smart contract;
[0083] The block verification module is responsible for executing the blockchain consensus mechanism to achieve the block verification or generation of the energy trading smart contract.
[0084] As Figure 1 shown: The physical layer of the photovoltaic microgrid is mainly composed of several decentralized small-scale photovoltaic power generation stations integrated with energy storage and power users; the energy agent layer of the photovoltaic microgrid is mainly composed of an edge server and a communication network, which are used to execute functions such as information collection, prediction, trading, and block verification; the blockchain layer mainly utilizes the decentralized and immutable characteristics of blockchain technology to generate a distributed ledger for the contract information reached by the transaction, spread it to each verification node for consensus mechanism voting, and finally link the valid blocks passed through the verification to the blockchain.
[0085] To save construction costs, the local energy storage battery capacity configured for each photovoltaic power generation station integrated with energy storage is limited. Therefore, it is necessary to cooperate among all photovoltaic microgrids to achieve the zero net load goal.
[0086] Furthermore, the information collection module is connected and communicates with the prediction function module through a programmable interface. The information collection module is provided with a user electricity consumption information collection module, a photovoltaic power generation information collection module, and a climate condition information collection module;
[0087] Among them, the user electricity consumption information collection module is used to collect and record the historical electricity consumption information of all users in the current photovoltaic microgrid area, providing a reference basis for the subsequent transaction price formulation;
[0088] The photovoltaic power generation information collection module is used to collect and record the historical power generation information of all distributed photovoltaic power stations in the current photovoltaic microgrid area, providing a reference basis for the subsequent transaction price formulation;
[0089] The climate condition information collection module is used to collect and record the historical environmental meteorological information in the current photovoltaic microgrid area, providing a meteorological data set for the subsequent prediction model of photovoltaic power generation.
[0090] Furthermore, the environmental meteorological information includes irradiance, temperature, humidity, and wind speed information in the microgrid area.
[0091] The prediction function module not only utilizes historical electricity consumption information, but also introduces corresponding climate conditions as feature inputs, which can increase the accuracy and interpretability of the prediction. For example, in a hot summer, electrical appliances such as air conditioners and fans of users will increase the usage duration and intensity according to the rising temperature.
[0092] Furthermore, the prediction function module is provided with a deep neural network DNN and a long short-term memory network LSTM. The deep neural network DNN and the long short-term memory network LSTM are used to extract the time dimension features and space dimension features in the historical dataset, and output the photovoltaic power generation information and electricity demand information of the current photovoltaic microgrid at the next trading moment.
[0093] Furthermore, the trading function module is provided with a trading party identity recognition unit, a trading price adjustment unit, and a trading matching unit;
[0094] Among them, the trading party identity recognition unit is used to generate a purchase smart contract or a sale smart contract corresponding to the photovoltaic microgrid according to the energy deficit or surplus information of the current photovoltaic microgrid;
[0095] The trading price adjustment unit is used to adjust the electricity trading price at each trading moment according to the electricity price adjustment mechanism, divide the trading cycle according to the peak period and non-peak period of the electricity trading, and then obtain the initial selling electricity price based on the total trading electricity volume according to the electricity demand and selling electricity demand at the next moment;
[0096] The trading matching unit is used to adjust its own contract quotation during the matching process of the generated purchase smart contract and sale smart contract on the blockchain energy trading platform; in order to avoid malicious manipulation or vicious competition in the energy trading market, the blockchain energy trading platform adopts a double-blind form in which the two parties of the trading contract do not share the price for contract matching. The blockchain energy trading platform conducts multiple rounds of matchmaking. When no transaction is reached in each round of contract, the buyer and the seller respectively increase and decrease their own contract quotations.
[0097] During the contract matching process, if the seller knows the buyer's bid information in advance, the transaction can be manipulated in the following ways: one is that if it is known that the buyer raises the bid due to energy demand, the selling price can be increased and wait for a better price; the other is to reduce the contract selling price to weaken competitors and execute more contracts. For buyers who manipulate the purchase price, the situation is the opposite. Therefore, in order to avoid manipulating market transactions, in the present invention, the buyer and the seller do not share quotation information.
[0098] Furthermore, the trading cycle division rule is as follows:
[0099] Taking 24 hours a day as a unit, two non-peak electricity consumption periods from 0 to 6 o'clock and from 18 to 24 o'clock are divided into 6 trading cycles, each trading period is 2 hours, and they are respectively recorded as h in chronological order 1 , h 2 , h 3 and h 28 , h 29 , h 30 ; The period from 6 to 18 o'clock is the peak electricity consumption period. In order to perform more accurate energy allocation, a finer trading cycle division is adopted in this period. It is divided into 24 trading cycles, each trading period is 0.5 hours, and they are respectively recorded as h in chronological order 4 , h 5 , …, h 27 , so a day is divided into 30 trading periods;
[0100] The trading party identity recognition unit records the predicted energy demand and photovoltaic power generation of the i-th photovoltaic microgrid in the trading period t ∈ {h 1 , h 2 , …, h 30} as P i,l (t), P i,g (t), i = 1, …, N, calculates the difference between the energy demand and the photovoltaic power generation to obtain the net load P i,net (t) = P i,l (t) - P i,g (t), i = 1, …, N;
[0101] P i,net (t) < 0 indicates an energy surplus of the photovoltaic microgrid i, P i,net (t) > 0 indicates an energy deficit of the photovoltaic microgrid i, P i,net (t) = 0 indicates an energy supply-demand balance of the photovoltaic microgrid i;
[0102] For all trading periods with P i,net (t) ≠ 0, t ∈ {h 1 , h 2 , …, h 30}, the prediction function module forwards the P i,net (t) information to the trading function module. The trading function module identifies the photovoltaic microgrid with a negative net load as an energy seller and generates a selling smart contract; it identifies the photovoltaic microgrid with a positive net load as an energy buyer and generates a purchasing smart contract, that is:
[0103]
[0104] The blockchain energy trading platform according to the net load P in the selling smart contract and the purchasing smart contract i,net(t), multi-round matching is adopted to execute contract matching; the PV microgrid with energy surplus, i.e., the seller, provides a pre-determined selling smart contract, and the quoted price is recorded as while the PV microgrid with energy deficit, i.e., the buyer, provides a pre-determined purchasing smart contract, and the quoted price is recorded as
[0105] As Figure 2 shown, the goals of the buyer and the seller are to match and execute their own contracts to meet their respective net load requirements. The contract matching process is as follows:
[0106] The first step: Starting from the initial quoted price by the seller, increasingly lower selling quotes are provided to potential buyers; starting from the initial quoted price by the buyer, increasingly higher purchasing quotes are provided to potential sellers;
[0107] The second step: For the r-th round of matching, autonomous contract matching is performed considering the following situations: If the contract is concluded at the price of ; if the buyer moves to the next seller's contract and continues to execute contract matching; if there are unmatched contracts after this round of trading, the seller reduces the selling quote; the buyer increases the purchasing quote and continues to execute the next round of matching;
[0108] The third step: All contract matching is completed, and the trading in this trading period ends.
[0109] The power transactions proposed by the present invention are all advanced to reach trading contracts, that is, the electricity consumption demand and power generation volume used to reach the trading contract are both based on the results of the next trading cycle of the prediction function module. Such trading behaviors help to improve the user's electricity consumption experience and the adjustment of the energy dispatching strategy. Each trading cycle is once every half hour, which can effectively regulate the imbalance of the supply-demand relationship caused by the change in the photovoltaic power generation capacity due to climate change.
[0110] Furthermore, the electricity price adjustment mechanism includes a seller electricity price adjustment rule and a buyer electricity price adjustment rule;
[0111] The seller electricity price adjustment rule is as follows:
[0112] During the trading period t, if P i,net (t) < 0, it is determined that the PV microgrid i is an energy seller, and the trading function module generates a selling smart contract, which includes the surplus energy to be sold and the selling quote;
[0113] The selling quote for the r-th round of matching is calculated as follows:
[0114]
[0115] Among them, is the initial selling price, C bss is the operating cost of the energy storage device, P batt is the capacity of the energy storage device, C life is the depreciation cost of the photovoltaic device, P ini is the installed capacity of the photovoltaic device, C cur is the energy discard cost, α is the energy discard ratio, C tr is the energy transmission cost; {A a,b} is the power transmission distance matrix of the photovoltaic microgrid group, a is the buyer index, and b is the seller index; A a,b represents the power transmission distance between buyer a and seller b; tanh(r) is an inverse function, representing a trend of price calculation;
[0116] Initial selling price The calculation expression is as follows:
[0117]
[0118] Among them, min is the minimum value function, represents the export electricity price of the power grid company, represents the import electricity price of the power grid company, represents the initial selling price at a certain moment, and the function tanh(x)=(e x -e -x ) / (e x +e -x ), e is a constant, and SDR represents the ratio of the supply and demand of photovoltaic microgrid's day-ahead energy, defined as represents the total supply, that is, the surplus energy volume in 30 trading periods, represents the total demand, that is, the lacking energy volume in 30 trading periods;
[0119] The buyer electricity price adjustment rule is as follows:
[0120] In trading period t, if P i,net (t)>0, it is determined that the photovoltaic microgrid i is an energy buyer, and set The trading function module generates a purchase smart contract, including the required deficit energy and the purchase price;
[0121] The purchase price in the r-th round of matching is calculated as follows:
[0122]
[0123] Among them, is the initial purchase price, Cbss is the operating cost of the energy storage device, P batt is the capacity of the energy storage device, C life is the depreciation cost of the photovoltaic device, P ini is the installed capacity of the photovoltaic device, C sh is the load shedding cost, and β is the load shedding ratio;
[0124] Initial purchase offer The calculation expression is as follows:
[0125]
[0126] where max is the maximum value function, represents the initial purchase offer at a certain moment.
[0127] Furthermore, the block verification module is provided with a contract data encryption unit, a blockchain transaction settlement unit, and a consensus mechanism verification unit;
[0128] Among them, the contract data encryption unit is used to perform key encryption on the electricity quantity and price information in the smart contract generated by the transaction function module, and then upload the encrypted smart contract to the blockchain energy trading platform for matching. Only the smart contracts uploaded by authorized legal photovoltaic microgrids have the corresponding decryption keys that meet a specific attribute set, and perform contract matching operations; this method not only guarantees data privacy and security, but also ensures the legality and compliance of transactions.
[0129] The consensus mechanism verification unit is used to verify the matched smart contract by using the consensus mechanism, confirm the validity and legality of the smart contract, and then link the block generated by the verified legal smart contract to the blockchain;
[0130] The blockchain transaction settlement unit generates a ledger copy according to the distributed ledger of the blockchain, and then sends the ledger copy to the photovoltaic microgrid as a verification node, and each verification node maintains a ledger copy;
[0131] The distributed ledger is composed of blocks linked into a blockchain, and each block is composed of the detailed information of the final smart contract successfully matched on the blockchain energy trading platform, including the network addresses of the buyer and seller, the trading volume, the contract execution price, the contract execution timestamp, and the hash value from the previous block, realizing the trusted settlement of energy transactions.
[0132] Furthermore, the consensus mechanism is a blockchain consensus mechanism based on the cascade of PoR and Ripple. Through the POR mechanism, a part of the photovoltaic microgrids with higher trading activity are selected from all photovoltaic microgrids, and then the selected photovoltaic microgrids are used as the verification nodes of the Ripple consensus mechanism, specifically as follows:
[0133] First, execute the PoR mechanism. Each photovoltaic microgrid, i.e., network node, calculates its own reputation value based on the number of transactions participated in and the proportion of the trading volume in all transactions during the current trading period, and broadcasts its own reputation value to all network nodes; each network node sorts all network nodes including itself according to the reputation value, and selects some network nodes with high reputation values as the verification node set. The network nodes in the verification node set have the opportunity to participate in consensus verification and block generation;
[0134] Then, execute the Ripple algorithm. All verification nodes selected based on PoR adopt a voting mechanism to verify the newly generated block. The consensus process is as follows: First, transaction verification: When a certain node in the verification node set receives the transaction information, i.e., the successfully matched smart contract, it verifies the validity of the transaction information through the local ledger data. Only legal transactions will be accepted and enter the consensus process; Second, proposal broadcast: This verification node packs the verified transaction information to be confirmed into a proposal and broadcasts it to other nodes in the verification node set; Third, voting and confirmation: The verification nodes that receive the proposal verify the transaction information in the proposal and vote according to their own ledger status. After more than 50% of the verification nodes vote in favor of the proposal, the transaction is confirmed and enters the next round of consensus process. Proposals that do not exceed 50% are left for confirmation in the next round of consensus process; Fourth, increase the voting threshold: In each round of consensus process, gradually increase the voting threshold to ensure that enough verification nodes participate in the consensus process and improve the security and credibility of the transaction information; Fifth, final confirmation: When a certain proposal obtains more than 80% of the verification node votes in favor, the blockchain network reaches an agreement, and this proposal will be officially confirmed, and the verification node that initially formed the proposal will generate a new block and link it to the blockchain.
[0135] Furthermore, the reputation value expression of the i-th network node in the trading period t is as follows:
[0136]
[0137] Among them, κ represents the penalty indicator. To avoid the centralization trend of verification nodes, when a certain node becomes a verification node three times in a row, when calculating the node's reputation value for the fourth time, it is stipulated that κ = 0. M(t - 1) represents the total number of transactions of all network nodes in the trading period t - 1, and m i (t - 1) represents the number of transactions of network node i in the trading period t - 1; P total (t - 1) represents the total trading volume of all network nodes in the trading period t - 1, and P i (t - 1) represents the trading volume of network node i in the trading period t - 1.
[0138] The node reputation value mentioned in the present invention is mainly for selecting the verification nodes of the consensus mechanism. Since all nodes in the entire transaction network are equal, in order to select verification nodes that all nodes can trust, the node reputation value is used for selection. Also, because the platform transactions of the blockchain are a type of distributed transactions, to avoid certain high-capacity nodes becoming verification nodes multiple times in multiple transactions, resulting in the concentration of verification power, a penalty mechanism is added, that is, when a certain node serves as a verification node three times in a row, it will be excluded when selecting verification nodes for the fourth time.
[0139] For interconnected photovoltaic microgrid clusters operating in off-grid mode, a decentralized energy trading mechanism is proposed, and a decentralized energy trading framework for interconnected photovoltaic microgrid clusters based on blockchain is designed. It is modeled as a multi-agent peer-to-peer network architecture, and the basic functions that each agent should possess are clarified, including prediction, trading, information collection, and block verification, etc. Given the characteristics of photovoltaic power output such as intermittency, volatility, and instability, a more refined and unequal trading cycle is adopted for trading settlement to improve the practicality of the trading mechanism. The energy supply-demand ratio relationship of different trading cycles is analyzed, and a pricing mechanism more in line with the market economy is proposed. The price matching is carried out by the way that the trading parties do not share the price with each other. On the one hand, it improves the efficiency of the buyer and seller to conclude a transaction, and on the other hand, it also avoids the risk of market price manipulation. The PoR and Ripple cascaded consensus mechanism ensures the security of trading settlement and the integrity of trading information. Furthermore, the trading architecture of photovoltaic microgrid clusters of different scales can be realized, thereby enhancing the stability and efficiency of the power trading network.
[0140] In the existing energy trading market in China, energy agents of the centralized energy trading system need to have a certain scale of energy capacity threshold. However, the energy capacity of some small-scale photovoltaic power stations deployed in some regions is relatively low and they cannot become energy agents. For example: Lingchuan County, Shanxi Province, located in the Taihang Mountains of China, has a dense ecological protection red line in the eastern region and lacks grid construction corridor resources. In order to meet the electricity demand of residential users in this area, a batch of small-scale photovoltaic power stations integrated with energy storage are planned to be built. For the convenience of management, photovoltaic microgrids are formed with multiple adjacent administrative villages as units, and all photovoltaic microgrids finally form an off-grid interconnected photovoltaic microgrid cluster to achieve self-generation, self-use, and self-sale of energy, which can not only guarantee the electricity demand of residential users and industrial and commercial users in this area, but also avoid the grid connection impact on the large grid caused by the intermittency and volatility of photovoltaic power generation. However, due to the imbalance of energy supply and demand in different photovoltaic microgrids, some have insufficient energy supply, while others have excessive energy supply. Therefore, it is necessary to form a photovoltaic microgrid alliance and innovate the energy trading mechanism to achieve dynamic balance of supply and demand through energy sharing. This is particularly suitable for areas where it is difficult to connect to the large grid or the trading cost is relatively high.
[0141] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and changes. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.
Claims
1. A decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain, characterized by: A photovoltaic microgrid group and a blockchain energy trading platform are provided, and the photovoltaic microgrid group and the blockchain energy trading platform are bidirectionally connected; The photovoltaic microgrid group includes N photovoltaic microgrids, each of which is provided with an information collection module, a prediction function module, a transaction function module and a block verification module connected in sequence; The information collection module is connected to a meteorological sensor network, at least two electricity users and at least two photovoltaic power stations. The information collection module is used to collect the power consumption information of all electricity users and the power generation information of all photovoltaic power stations in the current photovoltaic microgrid coverage area at the current trading moment, and use the meteorological sensor network deployed in the current photovoltaic microgrid coverage area to collect environmental meteorological information, and then store the power consumption information, power generation information and environmental meteorological information in the edge server as a historical data set for training the prediction function module; The prediction function module is used to perform the prediction of photovoltaic power generation and power demand at the next trading moment according to the historical data set, obtain the photovoltaic power generation information and power demand information of the current photovoltaic microgrid at the next trading moment, and calculate the net load according to the photovoltaic power generation information and power demand information; The transaction function module is used to perform peer-to-peer energy transactions in the blockchain energy trading platform according to the energy deficit or surplus information generated by the net load, purchase or sell energy on demand, and generate a smart contract; The block verification module is responsible for executing the blockchain consensus mechanism to realize block verification or generation of energy transaction smart contracts.
2. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 1 is characterized in that: The information collection module is connected and communicated with the prediction function module through a programmable interface, and the information collection module is provided with a user power consumption information collection module, a photovoltaic power generation information collection module and a climate condition information collection module; Wherein, the user electricity consumption information collection module is used to collect and record the historical electricity consumption information of all users in the current photovoltaic microgrid area; The photovoltaic power generation information collection module is used to collect and record the historical power generation information of all distributed photovoltaic power stations in the current photovoltaic microgrid area; The climate condition information collection module is used to collect and record the historical environmental meteorological information in the current photovoltaic microgrid area.
3. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 1 or 2 is characterized in that: The environmental meteorological information includes but is not limited to irradiance, temperature, humidity and wind speed information in the microgrid area.
4. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 1 is characterized in that: The prediction function module is provided with a deep neural network DNN and a long short-term memory network LSTM, and the deep neural network DNN and the long short-term memory network LSTM are used to extract the time dimension features and space dimension features in the historical data set, and output the photovoltaic power generation information and electricity demand information of the current photovoltaic microgrid at the next trading moment.
5. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 1 is characterized in that: The transaction function module is provided with a transaction party identity identification unit, a transaction price adjustment unit and a transaction matching unit; The transaction party identity identification unit is used to generate a purchase smart contract or a sale smart contract corresponding to the photovoltaic microgrid according to the current energy deficit or surplus information of the photovoltaic microgrid; The transaction price adjustment unit is used to adjust the power transaction price at each transaction time according to the power price adjustment mechanism, and divide the transaction cycle according to the peak period and non-peak period of power transaction, and then obtain the initial power selling price based on the total transaction power according to the power demand and power selling demand at the next moment; The transaction matching unit is used to adjust its own contract quotation during the process of matching the generated purchase smart contract and the sale smart contract on the blockchain energy trading platform; the blockchain energy trading platform adopts a double-blind form of contract matching in which the two parties to the transaction contract do not share the price, and the blockchain energy trading platform conducts multiple rounds of matching. When no transaction is reached in each round of contracts, the buyer and the seller respectively increase and decrease their own contract quotations.
6. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 5 is characterized by: The trading cycle division rules are as follows: Taking a 24-hour day as a unit, the two non-peak periods of electricity consumption from 0 to 6 o'clock and from 18 to 24 o'clock are divided into 6 trading cycles, each of which is 2 hours, which are recorded in time order as h 1 ,h 2 ,h 3 and h 28 ,h 29 ,h 30 ; 6-18 o'clock is the peak period of electricity consumption, which is divided into 24 trading cycles, each trading period is 0.5 hours, and is recorded in time order as h 4 ,h 5 ,…,h 27 , so a day is divided into 30 trading periods; The transaction party identity identification unit identifies the i-th photovoltaic microgrid in the transaction period t∈{h 1 ,h 2 ,…,h 30 The predicted energy demand and photovoltaic power generation are denoted as P i,l (t),P i,g (t), i = 1, ..., N, calculate the difference between energy demand and photovoltaic power generation to obtain the net load P i,net (t) = P i,l (t)-P i,g (t),i=1,…,N; P i,net (t)<0 indicates the energy surplus of PV microgrid i, P i,net (t)>0 indicates the energy deficit of PV microgrid i, P i,net (t) = 0 means that the energy supply and demand of PV microgrid i is balanced; For P i,net (t)≠0,t∈{h 1 ,h 2 ,…,h 30 }, the prediction function module will i,net (t) The information is forwarded to the transaction function module, which identifies the photovoltaic microgrid with negative net load as the energy seller and generates a selling smart contract; it identifies the photovoltaic microgrid with positive net load as the energy buyer and generates a purchasing smart contract, namely: The blockchain energy trading platform is based on the net load P in the selling smart contract and the purchasing smart contract. i,net (t), multiple rounds of matching are used to perform contract matching; the PV microgrid with energy surplus, i.e. the seller, provides a pre-determined selling smart contract, and the bid is recorded as The PV microgrid with energy deficit is a buyer who provides a pre-determined purchase smart contract, and the offer is recorded as The goal of buyers and sellers is to match and execute their contracts to meet their respective net load requirements. The contract matching process is: Step 1: The seller starts with an initial offer Starting with lower and lower sales offers to potential buyers; buyers start with an initial offer Start by making increasingly higher purchase offers to potential sellers; Step 2: For the rth round of matching, consider the following situations for autonomous contract matching: The contract is If The buyer transfers to the next seller contract and continues to execute contract matching; if there is an unmatched contract after this round of transactions, the seller lowers the selling price; the buyer increases the buying price and continues to execute the next round of matching; Step 3: All contracts are matched and the transaction in this trading period ends.
7. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 6 is characterized by: The electricity price adjustment mechanism includes seller electricity price adjustment rules and buyer electricity price adjustment rules; The seller's electricity price adjustment rules are as follows: In trading period t, if P i,net (t)<0, the PV microgrid i is identified as the energy seller, and the The transaction function module generates a sales smart contract, which includes the surplus energy to be sold and the sales quotation; The selling price of the rth round of matching The calculation expression is as follows: in, is the initial selling price, C bss is the operating cost of the energy storage device, P batt is the capacity of the energy storage device, C life is the depreciation cost of the photovoltaic equipment, P ini is the installed capacity of the photovoltaic equipment, C cur is the energy discard cost, α is the energy discard ratio, C tr is the energy transmission cost; a,b } is the transmission distance matrix of the photovoltaic microgrid group, a is the buyer index, and b is the seller index; A a,b Represents the transmission distance between buyer a and seller b; tanh(r) is an inversely proportional function, representing a trend in price calculation; Initial sale offer The calculation expression is as follows: Among them, min is the minimum function, represents the export electricity price of the power grid company, represents the inlet electricity price of the power grid company, represents the initial selling price at a certain moment, function tanh(x)=(e x -e -x ) / (e x +e -x ), e is a constant, SDR represents the day-ahead energy supply-demand ratio of the photovoltaic microgrid, and is defined as Represents the total supply or surplus energy for 30 trading cycles, It represents the total demand for 30 trading cycles, i.e. the amount of energy that is lacking; The buyer's electricity price adjustment rules are as follows: In trading period t, if P i,net (t)>0, the PV microgrid i is identified as the energy buyer, and the The transaction function module generates a purchase smart contract, including the required deficit energy and the purchase quotation; Purchase quotation of the rth round of matching The calculation expression is as follows: in, is the initial purchase offer, C bss is the operating cost of the energy storage device, P batt is the capacity of the energy storage device, C life is the depreciation cost of the photovoltaic equipment, P ini is the installed capacity of the photovoltaic equipment, C sh is the load shedding cost, β is the load shedding ratio; Initial purchase offer The calculation expression is as follows: Among them, max is the maximum value function, Represents the initial purchase price at a certain moment.
8. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 1 is characterized by: The block verification module is provided with a contract data encryption unit, a blockchain transaction settlement unit and a consensus mechanism verification unit; The contract data encryption unit is used to encrypt the electricity and price information in the smart contract generated by the transaction function module, and then upload the encrypted smart contract to the blockchain energy trading platform for matching. Only the smart contract uploaded by the authorized legal photovoltaic microgrid has the corresponding decryption key and performs the contract matching operation; The consensus mechanism verification unit is used to verify the successfully matched smart contract using the consensus mechanism, confirm the validity and legality of the smart contract, and then link the block generated by the verified legal smart contract to the blockchain; The blockchain transaction settlement unit generates a copy of the ledger according to the distributed ledger of the blockchain, and then sends the copy of the ledger to the photovoltaic microgrid as a verification node, and each verification node maintains a copy of the ledger; The distributed ledger consists of blocks linked into a blockchain, each of which consists of detailed information from the final smart contract successfully matched by the blockchain energy trading platform, including the network addresses of the buyer and seller, the transaction volume, the contract execution price, the contract execution timestamp, and the hash value from the previous block.
9. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 8 is characterized by: The consensus mechanism is a blockchain consensus mechanism based on PoR and Ripple cascade. Through the POR mechanism, a part of photovoltaic microgrids with high transaction activity are selected from all photovoltaic microgrids, and then the selected photovoltaic microgrids are used as verification nodes of the Ripple consensus mechanism, as follows: First, the PoR mechanism is implemented. Each photovoltaic microgrid, i.e., network node, calculates its own reputation value based on the number of transactions it participates in during the current trading period and the proportion of its transaction volume in all transactions, and broadcasts its own reputation value to all network nodes. Each network node sorts all network nodes including itself according to the reputation value, and selects some network nodes with high reputation values as the verification node set. The network nodes in the verification node set have the opportunity to participate in consensus verification and block generation. Then the Ripple algorithm is executed. All verification nodes selected based on PoR use a voting mechanism to verify the newly generated blocks. The consensus process is as follows: First, transaction verification: After a node in the verification node set receives the transaction information, that is, after the smart contract is successfully matched, the validity of the transaction information is verified through the local ledger data. Only legal transactions will be accepted and enter the consensus process; Second, proposal broadcasting: The verification node packages the verified transaction information to be confirmed into a proposal and broadcasts it to other nodes in the verification node set; Third, voting and confirmation: The verification nodes that receive the proposal verify the transaction information in the proposal and vote according to their own ledger status. When more than 50% of the verification nodes vote in favor of the proposal, the transaction is confirmed and enters the next round of consensus process. Proposals that do not exceed 50% will be left for confirmation in the next round of consensus process. Fourth, increase the voting threshold: in each round of consensus, gradually increase the voting threshold to ensure that enough verification nodes participate in the consensus process; Fifth, final confirmation: when a proposal is voted through by more than 80% of the verification nodes, the blockchain network reaches a consensus, the proposal will be formally confirmed, and the verification node that initially formed the proposal will generate a new block and link it to the blockchain.
10. The decentralized energy trading system for interconnected photovoltaic microgrids based on blockchain according to claim 9 is characterized in that: The reputation value expression of the i-th network node in transaction period t is as follows: Where κ represents the penalty indicator, M(t-1) represents the total number of transactions of all network nodes in transaction period t-1, and m i (t-1) represents the number of transactions of network node i in transaction period t-1; P total (t-1) represents the total transaction volume of all network nodes in transaction period t-1, P i (t-1) represents the transaction volume of network node i in transaction period t-1.
Citation Information
Patent Citations
Photovoltaic microgrid transaction method based on block chain technology
CN108711077A
Extensible distributed power transaction method in multi-microgrid environment
CN110826940A
Block chain-based micro-grid distributed energy transaction method and system
CN113643131A
Energy storage system based on distributed energy resources P2P energy trading system using blockchain technology and method thereof
KR101942543B1
Method for operating multiple micro-grid based on hierarchical block chain and apparatus for the same
KR102058539B1
Cited By
Distributed microgrid group cooperative control method and system
CN121308129A
Indoor air purification energy-saving control method and system based on photovoltaic energy supply
CN122041274A