An Integrated Energy Service Transaction Model Based on Energy Blockchain

An Integrated Energy Service Transaction Model Based on Energy Blockchain

Qinzhe LiuBingbing Tong Dongliang Li Yan Lu Yuhong Fu Lei Chen Kuangyi Zhao 

Beijing Jingyan Power Engineering Design Co., Ltd., Beijing 100038, China

Economic and Technical Research Institute of State Grid Jibei Electric Power Co., Ltd., Beijing 100038, China

Corresponding Author Email:
8 February 2020
23 April 2020
30 June 2020
| Citation



To improve the security of integrated energy service transactions and realize intelligent and transparent transactions, this paper proposes an integrated energy service transaction model based on the energy blockchain. By constructing an integrated energy service network with “multi-chain” mode, the model is proposed to improve the accuracy and security of transactions; then on this basis, the paper also proposes a consensus mechanism of the Improved Proof of Work (IPOW), and adopts blockchain technology and smart contract mechanism to realize the processes of value transfer and data storage. The analysis of a calculation example shows that the blockchain-based integrated energy service transaction model can ensure the security of the transactions, and the relevant transaction data cannot be tampered with.


energy blockchain, integrated energy service, electricity transaction, consensus mechanism, smart contract

1. Introduction

In order to cope with problems such as unbalanced energy supply and demand, environmental pollution, excess production capacity, and low use efficiency [1, 2], in recent years, the energy Internet has developed vigorously, and the Internet information technology, the renewable energy technology, and the electricity power market have been fused into the integrated energy service, and this service mode has become the new direction for improving energy efficiency, reducing energy costs, and promoting cooperation between industries. Under the coverage of the “source-network-sales-load” full-link value-added business, there’re many problems with the integrated energy services, such as multiple business types, different customer needs, diversified negotiation mechanisms and transaction modes, high requirements in transaction safety and real-time services, different operation system management and control, and the society has a high demand for the credibility of power grid companies, etc. [3, 4]. Blockchain is a new application mode for computer technologies such as distributed data storage, point-to-point transmission, consensus mechanism and encryption algorithm, etc. Applying blockchain technology to the integrated energy service system can further build an integrated energy service operation management and control system, improve the efficiency of the integrated energy service negotiation mechanism, the security of transactions, and the real-time services, so as to meet various users’ satisfaction with the integrated energy service companies and corresponding businesses.

At present, scholars at home and abroad have conducted a lot of research on the application of blockchain in electricity transactions. Kumar [5] proposed a method of weak-centralized electricity transactions, its core content is to make use of the blockchain technology to store the electricity transaction information in the form of smart contracts and perform money transfers automatically; Noor et al. [6] summarized and analyzed the application of blockchain technology in the energy Internet from three dimensions of functions, subjects, and attributes, etc.; Foti and Vavalis [7] completed transaction matching through the continuous two-way auction mechanism, and adopted blockchain system to realize the exchange of digital certificates and fees for electricity transactions; Teufel et al. [8] designed a heterogeneous blockchain transaction system suitable for multi-energy systems, and proposed application scenarios for side chain management, data retrieval and autonomous management to support heterogeneous blockchain transactions under multi-energy systems.

At this stage, existing literatures have studied the multiple application methods of blockchain in electricity transactions, and realized intelligent and transparent transactions. However, the analysis and description of the application of blockchain technology in integrated energy services is not sufficient and it lacks a targeted research scheme. Focusing on the application of blockchain technology in integrated energy services, this paper analyzes the evolution path of integrated energy services from the three stages of traditional energy services, distributed energy services and integrated energy services [9-13]. Based on the “multi-chain” blockchain, this paper constructs an integrated energy service network consisted of energy, power grids, electricity companies, users, and other node types; then on this basis, it analyzes the decentralized transaction process of integrated energy services, elaborates the method of using smart contract mechanisms to realize value transfer, and explains the storage principle of transaction data; at last, through the analysis of a calculation example, it demonstrates that the blockchain technology can effectively improve the security of the integrated energy service network transactions and ensure that the transaction data cannot be tampered with.

2. Evolution Path of Integrated Energy Services

According to business and management modes, the evolution of energy services can be divided into three stages: traditional energy services, distributed energy services, and integrated energy services, as shown in Figure 1.

With the development of technologies such as big data, cloud computing, mobile Internet, Internet of Things (IoT), and smart grids [14-16], the regional microgrid technology that integrates clean energy and renewable energy has gradually matured; in addition, with the opening of the electricity market, new-type integrated energy service modes have begun to emerge. As the core business of the integrated energy services, the electric power service forms a multi-energy supply system together with public heating and cooling, and gas and oil. The integrated energy service platform is used to carry out product marketing and data value-added services, the traditional engineering technology service mode is transformed into the mode that directly provides services for users, so as to give full play to the advantages of energy market, resources and data, etc.

The integrated energy service business mode is different from the traditional energy service business mode and the distributed energy service business mode; the integrated energy service business mode faces different customer groups, which can break market barriers to the maximum extent and share the benefits of energy reform. A typical mode is the energy-saving service companies, which take energy performance contracting (EMC) as a market-oriented service mechanism to obtain profits through sharing and recovering investment, and achieve energy-saving project reconstruction by reducing energy costs.

Figure 1. Evolution path of integrated energy services

3. Blockchain-Based Integrated Energy Service Transaction Model

3.1 Blockchain-based integrated energy service network framework

The integrated energy service business can be divided into three stages: the first stage is mainly market expansion and risk control, the market expansion refers to the expansion of business scale, and the risk control mainly contains policy control and price strategies: the second stage is mainly the integrated energies and the integrated services. Integrated energies develop the energy technologies to meet the rigid needs of users, while the integrated services develop the information technologies to dig the potential needs of users; the third stage is mainly the smart energy and the "Internet +", the smart energy innovates the business modes and enlarges the profit space; while the "Internet +" copies the scale and expands rapidly. In these three stages, the first stage is the value flow, the second stage is the energy flow, and the third stage is the information flow. In the entire processes, business integration is the key [17].

The integrated energy service business structure can be roughly divided into four parts: user services, market transactions, production operations and business support [18]. User services include marketing settlement and consulting training; market transactions include energy purchase and energy sale; production operations include operation scheduling and operation management; business supports include information platforms and energy systems. In the application scenarios of the integrated energy services, due to the different requirements for the degree of decentralization of source, network, sales, and loads, the integrated energy service blockchain network architecture was designed as a multi-chain form ("multi-chain" refers to the combination of multiple private chains + consortium blockchains), as shown in Figure 2.

In the energy transaction recording process, for some data, the nodes do not want to share them internally or publish them externally, it involves specific data privacy and security issues; therefore, among each master node and its slave nodes, a “master-slave” private chain model could be formed using the multi-chain architecture. In this model, each master node has the administrator rights of the master-slave chain [19], including the setting and publishing of the number of master (slave) chain blocks, making transaction decisions with other master nodes in the blockchain network, releasing transaction requirements of the master-slave chain, and acquiring transaction information released by other master nodes, etc.; each internal slave node only transmits transaction data with its related master node, the relevant information is stored in the private chain of each slave node, and the private chains form the main chain according to the types of the nodes. In the entire blockchain network, among each master node, the form of consortium blockchain is adopted to realize the open interconnection and sharing of information, which provides security guarantee for the integrated energy services in the network and improves the security of the transactions.

Figure 2. Integrated energy service blockchain network architecture

3.2 Integrated energy service transaction model

The blockchain network supports the safe and efficient operation of the integrated energy service system, which is divided into two parts based on the two major tasks of integrated energies and integrated services. The integrated energy service transaction model is shown in Figure 3. The model includes source-end master chain, network-end master chain, sales-end master chain, and load-end master chain; each master chain is composed of several slave chains. The four types of master chains are interconnected in the form of consortium blockchains, and they constitute the entire integrated energy service blockchain information interaction network; at the same time, the government is given the supervision authority to supervise the reliability of the information of service transactions among the master chains.

The main transaction processes are as follows:

(1) The network-end nodes and the integrated energy service company node broadcast service information to the blockchain network, including the types, requirements, and prices of available services; and each master node receives the service information and publishes it to each slave chain;

(2) During the transaction period, the user nodes at the load-end uploads the requested services to the master chain; after the current service request period is over, the main chain integrates the service requests during this period and broadcasts to the entire network according to the three categories of the user’s direct electricity purchase business, the common electricity supply business (purchase electricity from the grids or the electricity sales companies), and the auxiliary service business;

(3) The source-end, sales-end, and network-end receive transaction information of their respective business categories, and their master chains judge and feed-back whether they accept these service requests. If they accept a service request, they would integrate the service transaction information and distribute it to the execution slave chain. Then the corresponding slave chain would calculate and analyze it, broadcast the transaction results to the blockchain network via the master chain, and the master chain connects with the transaction entities at the load-end; after the transaction is completed, it’s recorded, and packed to the chain.

(4) The grids and the electricity sales companies are the main bodies to execute the integrated services, their businesses can be divided into power supply business and auxiliary service business. When conducting power supply business transactions, each user node at the load-end needs to integrate the electricity demand information of the same time period, broadcasts it to the blockchain network, and waits for responses.

Figure 3. Integrated energy service transaction model

3.3 Consensus mechanism for integrated energy service transactions

The goal of the blockchain consensus mechanism is to make the data saved by all nodes in the blockchain network consistent and credible. Common consensus algorithms include Proof of Work (PoW), Proof of Stake (PoS), and Delegated Proof of Stake (DPoS), etc. [20].

In the blockchain, a common form of the POW algorithm is: H(param||nonce)<target, wherein, param represents data related to block information, nonce represents a random number, target represents the target value. According to the properties of the hash function, if we want to find a nonce that satisfies the conditions, it must be achieved by exhaustively enumerating nonce, and nodes that meet the nonce value of the above inequation obtained the rights to keep accounts. The process of the POW algorithm is simple, and the participation process does not require identity validation, but the algorithm is a waste of computing resources, it is low in efficiency, and easily leads to concentration of computing power.

This paper proposes an improved Proof of Work (IPOW) consensus mechanism to ensure the accuracy of information in the blockchain. In the blockchain-based integrated energy service transaction model, the nodes of both parties of the transaction need to agree on the information on the chain, such as whether the transaction electricity of the power supply business is reasonable, whether there are line congestion problems under the current transaction scheme, and whether the content of auxiliary services is accurate, etc. These validation processes are defined as the workload proof of the nodes, and the corresponding incentives are given to the nodes according to the workloads of the nodes, the incentives are expressed in the form of transaction priority. In addition, in order to avoid malicious nodes appearing in the network in large amount, consensus supervision nodes are added in the system to reduce computing power to a certain extent and promote the entire system to enter a virtuous circle. The specific process of the IPOW consensus mechanism is shown in Figure 4.

Figure 4. IPOW consensus mechanism

In the process of transaction validation, the transaction set to be evaluated that has not yet been validated is denoted as T; in set T, the number of lines to be evaluated is denoted as Count; after the nodes complete the validation of the transaction Tk to be evaluated, the set of workload proof that is fed back to the consensus supervision node is denoted as Z(Tk); Z(Tk,e) represents the calculation or validation of node e to the transaction Tk to be evaluated. The response processes represented by each letter in Figure 4 are shown in Table 1.

In the IPOW consensus mechanism, the consensus supervision node randomly allocates computing tasks to each node. The consensus supervision node plays a certain guiding role, and the information docking between each node cannot be achieved, which can effectively avoid the problem of Byzantine Failures. In the election of committer nodes, each node is no longer a meaningless exhaustive random number, which effectively saves computing time and ensures the accuracy of calculation.

Table 1. Meaning of the letters


When a transaction node e is idle, it can perform transaction validation, it submits a job application to the consensus supervision node.


When a transaction node e has completed the validation of the transaction Tk, it submits the proof of work Z(Tk,e) to the consensus supervision node.


The consensus supervision node broadcasts to the entire network, indicating that the transaction validation of this period has begun, and each node can submit validation applications.


The consensus supervision nodes randomly publish the transaction Tk to be evaluated to the node e that has applied for calculation for validation; it requires that node e has never participated in the validation of Tk.


The consensus supervision node updates the transaction set T to be evaluated in real time according to Z(Tk,e) that has been fed back. When the number of work proofs in Z(Tk) is large enough and more than half of the work proofs are consistent, it judges that Tk has obtained correct evaluations, then T and Count are updated.


The transaction validation of this time period is completed, the consensus supervision node broadcasts to the entire network, and each node waits for W1 of the next time period.

3.4 Storage of smart contracts and transaction data

The programmable, decentralized, and highly transparent features of blockchain technology provide a technical support for the establishment of smart contracts. Smart contracts exist in the blockchain in the form of codes and are jointly maintained by all nodes in the network. When conducting a transaction, both parties of the contract store the transaction content, transaction rules, and their signatures in the smart contract. The transaction content includes the transaction electricity, transaction time, transaction price, and the penalty for breach of the contract. When conducting electricity transactions, the intelligent electric meters in the network will record the transacted electricity of both parties, when the contract execution time comes, both parties transfer the money according to the completion degree of the transaction content. If an electricity sales company has provided the electricity required by the purchaser in the contract within the specified time, the electricity fee will be automatically transferred from the purchaser’s account to the electricity sales company’s account; if the seller fails to complete the transaction within the specified time, the corresponding liquidated damages will be deducted. The entire process runs automatically by a pre-programmed program without any party's intervention, which ensures the fairness and safety of the transaction, reduces the transaction costs, and improves the operational efficiency.

After a smart contract is generated, the system broadcasts the contract to every node through the P2P network and waits for the consensus on the contract. After the consensus process is over, the nodes will save the final contract set in the blocks in the form of a hash tree. Hash tree is a kind of binary tree. After transaction information is subject to hash encoding, it’s recorded on the branch nodes of the hash tree. The upper-level nodes of these branch nodes are coded as the sum of the hash values of the branch nodes, thus ensuring the traceability of the data. If the information of a certain transaction is changed, the hash code of the transaction will change as well, further, the transaction’s corresponding branch nodes, upper-level nodes, and root node will also change, and such connections make the information difficult to be tampered with. The node sends the block formed after the consensus to other nodes in the network, and other nodes compare the hash value to verify whether the contract sets contained in the blocks are consistent, and meanwhile send a set of contracts approved by themselves to other validation nodes, and finally obtaining the consistency of the entire network. By giving full scope to the traceability and high security features of the blockchain, it can ensure that the data cannot be tampered with, and the integrity of the data could be guaranteed, which is very suitable for the storage of transaction data.

4. Example Analysis

Suppose that a regional energy market adopted the blockchain-based integrated energy service transaction model. Taking the power supply business as an example, the sales-end selected 4 electricity sales nodes, the load-end selected 4 purchaser nodes. Their initial information was calculated and analyzed, after the game, the power supply prices of each electricity sales company are shown in Table 2, and the final transaction electricity matrix is shown as Eq. 1:

$F=\left[ \begin{matrix}   0 & 0 & 0 & 0 & 10.98 & 10.54 & 0 & 0  \\   0 & 0 & 0 & 0 & 5.33 & 0 & 25.65 & 37.43  \\   0 & 0 & 0 & 0 & 0 & 0 & 25.65 & 3.65  \\   0 & 0 & 0 & 0 & 0 & 23.76 & 0 & 8.48  \\   -10.98 & -5.33 & 0 & 0 & 0 & 0 & 0 & 0  \\   -10.54 & 0 & 0 & -23.76 & 0 & 0 & 0 & 0  \\   0 & -25.65 & -25.65 & 0 & 0 & 0 & 0 & 0  \\   0 & -37.43 & -3.65 & -8.48 & 0 & 0 & 0 & 0  \\\end{matrix} \right]$  (1)

Table 2. Power supply prices of electricity sales companies

Number of electricity sales companies










The transaction electricity of each transaction entity could be known from the transaction matrix, taking f15as an example, it represents the electricity provided by the No. 1 electricity sales company (seller) to the No. 5 purchaser, its value is 10.98. The power purchase fee is calculated according to the power supply price of seller No.1; and both parties of the transaction also need to bear the corresponding electricity transmission costs, the unit electricity transmission cost is set as 1.5; in order to prevent the seller from breaking the contract, a penalty for the breach of the contract must be agreed in advance, so the liquidated damages by agreement is set to be 15 per unit; the contract also needs to agree on the transaction time, here it’s set to be 18:00; to facilitate recording, the address of electricity seller No. 1 is recorded as 0x20, the address of electricity purchaser No. 5 is recorded as 0x25, and the address of electricity transmission company is recorded as 0x28. Therefore, the content of this transaction can be recorded as Table 3.

After the transaction is completed, the seller, the purchaser, and the transmission company will sign the contract with a private key, encrypt it, broadcast it in the blockchain network, and exist as a branch node of the hash tree in the blockchain. Multiple transactions would form multiple branch nodes, and finally creating a hash tree, which is stored in the block that is generated the latest at the end of the blockchain, which ensured the traceability of these transactions and the information cannot be tempered with, as shown in Figure 5.

According to the hash value, the position of the transaction in the hash tree can be found quickly and the detailed information of the transaction could be viewed easily; once a transaction has been tempered with, the hash value would change, and then the nodes connected to the transaction in the entire hash tree would change accordingly, and the hash value of the root node will change eventually. In case of f15, as the transaction electricity changes from 10.98 to 12.71, the corresponding hash value of the transaction has changed, as shown in Figure 6.

Smart contracts are characterized by high credibility. When the transaction settlement time comes, the smart contracts will conduct value transfer automatically. If a transaction is successfully completed and each purchaser has obtained the corresponding electricity, and there is no default, the money will be deducted from the purchaser’s account and transferred to the seller’s account automatically; if one party has a default, corresponding liquidated damages will be automatically deducted, and the smart contracts will conduct value transfer on this basis. In the example, the automatic money transfer situations are shown as Table 4.

The smart contract technology effectively avoids the intervention of traders or third parties, enables safe money transfer, promotes transaction automation, and optimizes transaction costs and transaction efficiency, therefore, this technology can be introduced into electricity transactions.

Figure 5. Hash tree

Figure 6. The modified hash tree

Table 3. Transaction content of f15

Address of electricity seller

Address of electricity purchaser

Address of electricity transmission company

Unit power supply price of the electricity seller

Transaction electricity






Electricity transmission cost

Electricity purchase cost

Liquidated damages

Transaction time








Table 4. Money transfer

Transaction entities

Change in account balance (USD)

Penalty for breach of contract (USD)

Electricity transmission company

(+) 192.02

(-) 35.19

Seller 1

(+) 332.91

(-) 30.60

Seller 2

(+) 1020.3

(-) 68.40

Seller 3

(+) 471.01

(-) 24.15

Seller 4

(+) 514.06

(-) 17.40

Purchaser 1

(-) 297.44

(-) 4.651

Purchaser 2

(-) 529.29

(-) 60.30

Purchaser 3

(-) 892.37

(-) 46.35

Purchaser 4

(-) 813.78

(-) 66.75

5. Conclusion

This paper studied an integrated energy service transaction model based on energy blockchain. First, it analyzed the evolution process of integrated energy services from traditional energy services and distributed energy services, and studied the business model of integrated energy services; the paper took into account the diversity of integrated energy service businesses, applied different types of blockchains, adopted the "multi-chain" approach to build an integrated energy service network based on the blockchain technology, and analyzed the processes of the integrated energy service transactions based on the blockchain technology; moreover, to improve the accuracy and security of the transactions, an improved IPOW consensus mechanism was proposed, and the process of using blockchain technology and smart contract mechanism to realize value transfer and data storage was analyzed in detail; at last, the paper used an example to demonstrate that the blockchain-based integrated energy service transaction model can effectively solve the trust problem of both transaction parties, improve the security of the transactions, and ensure that the transaction data cannot be tampered with.


[1] Lazarevic, D., Kivimaa, P., Lukkarinen, J., Kangas, H.L. (2019). Understanding integrated-solution innovations in sustainability transitions: Reconfigurative building-energy services in Finland. Energy Research & Social Science, 56: 101209.

[2] Wang, D., Jia, H., Hou, K., Du, W., Chen, N., Wang, X., Fan, M. (2019). Integrated demand response in district electricity-heating network considering double auction retail energy market based on demand-side energy stations. Applied Energy, 248: 656-678.

[3] Wang, J., You, S., Zong, Y., Træholt, C., Zhou, Y., Mu, S. (2019). Optimal dispatch of combined heat and power plant in integrated energy system: A state of the art review and case study of Copenhagen. Energy Procedia, 158: 2794-2799.

[4] Tikka, V., Mashlakov, A., Kulmala, A., Repo, S., Aro, M., Keski-Koukkari, A., Honkapuro, S., Järventausta, P., Partanen, J. (2019). Integrated business platform of distributed energy resources–Case Finland. Energy Procedia, 158: 6637-6644.

[5] Kumar, N.M. (2018). Blockchain: Enabling wide range of services in distributed energy system. Beni-Suef University Journal of Basic and Applied Sciences, 7(4): 701-704.

[6] Noor, S., Yang, W., Guo, M., van Dam, K.H., Wang, X. (2018). Energy demand side management within micro-grid networks enhanced by blockchain. Applied Energy, 228: 1385-1398.

[7] Foti, M., Vavalis, M. (2019). Blockchain based uniform price double auctions for energy markets. Applied Energy, 254: 113604.

[8] Teufel, B., Sentic, A., Barmet, M. (2019). Blockchain energy: Blockchain in future energy systems. Journal of Electronic Science and Technology, 17(4): 100011.

[9] Wu, D., Ma, H., Mao, J., Ma, K., Zheng, H., Bo, Z. (2019). A unified model for diagnosing energy usage abnormalities in regional integrated energy service systems. Global Energy Interconnection, 2(4): 361-367.

[10] Dolšak, J., Hrovatin, N., Zorić, J. (2019). Can loyalty programs be effective in promoting integrated energy services? Evidence from Slovenian electricity consumers. Energy Research & Social Science, 48: 246-256.

[11] Zhou, Y., Wei, Z., Sun, G., Cheung, K.W., Zang, H., Chen, S. (2018). A robust optimization approach for integrated community energy system in energy and ancillary service markets. Energy, 148: 1-15.

[12] Zhang, X., Chan, K. W., Wang, H., Hu, J., Zhou, B., Zhang, Y., Qiu, J. (2019). Game-theoretic planning for integrated energy system with independent participants considering ancillary services of power-to-gas stations. Energy, 176: 249-264.

[13] Meesenburg, W., Ommen, T., Elmegaard, B. (2018). Dynamic exergoeconomic analysis of a heat pump system used for ancillary services in an integrated energy system. Energy, 152: 154-165.

[14] Gong, X., De Paola, A., Angeli, D., Strbac, G. (2019). A game-theoretic approach for price-based coordination of flexible devices operating in integrated energy-reserve markets. Energy, 189: 116153.

[15] Cremades, R., Mitter, H., Tudose, N.C., Sanchez-Plaza, A., Graves, A., Broekman, A., Bender, S., Giupponi, C., Koundouri, P., Bahri, M., Cheval, S., Cortekar, J., Moreno, Y., Melo, O., Karner, K., Ungurean, C., Davidescu, S.O., Kropf, B., Marin, M. (2019). Ten principles to integrate the water-energy-land nexus with climate services for co-producing local and regional integrated assessments. Science of the Total Environment, 693: 133662.

[16] Wang, D., Wang, C., Lei, Y., Zhang, Z., Zhang, N. (2019). Prospects for key technologies of new-type urban integrated energy system. Global Energy Interconnection, 2(5): 402-412.

[17] Ahl, A., Yarime, M., Tanaka, K., Sagawa, D. (2019). Review of blockchain-based distributed energy: Implications for institutional development. Renewable and Sustainable Energy Reviews, 107: 200-211.

[18] Chaudhary, R., Jindal, A., Aujla, G.S., Aggarwal, S., Kumar, N., Choo, K.K.R. (2019). BEST: Blockchain-based secure energy trading in SDN-enabled intelligent transportation system. Computers & Security, 85: 288-299.

[19] Li, Z., Bahramirad, S., Paaso, A., Yan, M., Shahidehpour, M. (2019). Blockchain for decentralized transactive energy management system in networked microgrids. The Electricity Journal, 32(4): 58-72.

[20] Truby, J. (2018). Decarbonizing Bitcoin: Law and policy choices for reducing the energy consumption of Blockchain technologies and digital currencies. Energy Research & Social Science, 44: 399-410.