A Consensus and Incentive Program For Charging Piles Based On Consortium Blockchain
A Consensus and Incentive Program For Charging Piles Based On Consortium Blockchain
4, DECEMBER 2018
Abstract—Charging piles are used for charging electric vehicles been used to build the Internet of Things (IoT) system in
and are directly accessible to users in an energy internet the form of Ethereum, an open source software program.
entrance, while playing an important role in energy consumption. Keys are managed using RSA (Rivest—Shamir—Adleman),
Currently, each enterprise constructs the center of operation
and maintenance of their systems independently, along with a public key cryptosystem in which the public keys are stored
their respective APP payment programs. This results in high in Ethereum and the private keys are saved on individual
operating costs, poor user experience, and low utilization rate devices. In this way, it is easy to manage configuration of IoT
of the pile, which limits the promotion and popularization of devices and build a key management system [5]. A blockchain-
electric vehicles. To overcome this limitation, there is a need based smart home framework has also been proposed [6]. The
for a multi-center, fair, and transparent consortium blockchain,
which can conform to the application requirements of a unified various core components and functions of the smart home
payment system and accommodate a range of diverse enterprise tier are outlined and described in detail; each smart home is
charging piles. In this paper, the design for a consensus and equipped with an always online, high resource device known
incentive program for consortium blockchain is presented. First, as a “miner” that is responsible for handling all communication
the application status of blockchain in an energy internet is within and external to the home. The miner also preserves
described. Then, the logical structure and hierarchical model
of the consortium blockchain are analyzed. Next, multicycle a private and secure BC, used for controlling and auditing
accounting and limiting the amount of accounting nodes in each communications [6].
round is presented to ensure the overhead of consensus remain The energy internet today provides an open framework
constant. Finally, the accounting incentive mechanism and the for integrating individual pieces of equipment involved in
bidding encouragement strategy based on “electric beans” are energy generation, transmission, distribution, transformation,
designed.
storage, exchange, and consumption to existing information
Index Terms—Charging pile, consortium blockchain, energy and communication technologies (ICT). An important capabil-
internet, payment solution, power profit bean. ity enabled by the energy internet is that standard and modular
autonomous energy units, such as solar panels, wind turbines,
electric vehicles, fuel cells, batteries, hydrogen storage, etc.,
can be controlled through a standardized plug-and-play inter-
I. I NTRODUCTION face [7].
The energy internet also allows for the main functions of
ATOSHI Nakamoto’s paper, titled “Bitcoin: a point-to-
S point electronic cash system,” published in 2008, paved
the way for research into blockchain (BC) [1], [2]. BC has
distribution, dispersion, and sharing via decentralized schedul-
ing and management operations [8], [9]. The characteristics of
blockchain techniques, such as decentralization, transparency,
been used in cryptocurrency and other applications, including
fairness, and openness are consistent with the spirit of the
but not limited to finance and the Internet of Things (IoT). For
energy internet, which is why use of BC technology in the
example, Quoc Khanh Nguyen proposed that blockchain could
energy internet is expected to have a profound impact [10],
be helpful for separating the functions of money transfers,
[11].
which led to the launching of a start-up where currency ex-
At present, examples of blockchain applications in the
changes, including the U.S. dollar, could be sent and received
energy internet in the U.S. include companies such as LO3
more easily [3]. In [4], Wang Shuo provides an overview
Energy and Consensus Systems, jointly established as a sales
of blockchain applications in the financial field, and explores
platform using the blockchain—TransActive Grid, which made
the possibility of using blockchain to simplify the costly and
the local residents able to buy and sell their own green energy
time-consuming post-trade settlement process. Blockchain has
on this platform [12]. IDEO CoLab (a shared platform for
Manuscript received September 25, 2017; revised May 4, 2018; accepted researching the potential of emerging technologies) integrated
July 11, 2018; date of publication December 30, 2018; date of current version blockchains and IoT technologies to automatically track and
November 2, 2018. This research is supported by the Science and Technology
Project of State Grid Corporation of China (SAP No. 52110417000G). record solar power generation, and then generated RECs
Q. S. He, Y. Xu (corresponding author, email: [email protected]), J. (renewable energy certificates).
S. Wang, Q. Z. Han and L. L. Li are with State Grid Electronic Commerce The European Union implemented a project called Scanergy
Co., LTD. Beijing 100053, China.
Y. Yan is with State Grid Zhejiang Electric Power Company, Hangzhou to enable direct green energy transactions between small users.
310007, China.
DOI: 10.17775/CSEEJPES.2017.00960
In Germany, the RWE Power Company applied the blockchain blockchain. This paper adopts the following program for node
technology to electric vehicles in the design of the rental allocation:
charging pile and the electric vehicle V2G (the effect of First, the number of accounting nodes need to be determined
vehicle-to-grid) automatic response program. In Russia, the for which two strategies are adopted:
Qiwi Company operated a blockchain project to track energy 1) To avoid excessive data transmission in different ac-
trading. In Austria, Grid Singularity used blockchain technol- counting nodes and reduce the space occupied by the copies
ogy to build a decentralized energy trading platform with data of global ledger in the consortium blockchain, according to
analysis and smart grid management functions. In Finland, the scale of the consortium blockchain, the total number of
Fortum implemented a demand-side response project based accounting nodes should be limited under N (for example,
on blockchain. Here, the user can control the smart appliance N ≤ 200).
through the Internet based on real-time information of the 2) To ensure sufficient nodes to maintain the global ledger
power price. and store its copies, the total number of accounting nodes
China has promulgated a variety of policies to support should not be less than K (for example, K ≥ 20).
the development of electric vehicles, including working to Second, the proportion of accounting nodes need to be
standardize electric vehicle applications and investing in more determined. To ensure fairness and justice in the system, the
charging facilities since 2014. In February 2017, the Na- largest proportion of an enterprise holding accounting nodes
tional Energy Administration stated, “China will strive to add in the alliance must be less than 50%. This will also avoid the
800,000 charging piles including 700,000 special piles and “one vote veto” phenomenon when new companies join the
100,000 public piles.” However, for the actual operation of alliance. Each enterprise in the alliance occupies at least one
the charging pile, currently individual enterprises have set up accounting node to ensure that all enterprises have the right
their own centers of operation and maintenance independent to the account.
of each other, which has not only resulted in inconvenience to
users, but also seriously reduced consumer desire to purchase
electric vehicles. Development of blockchain technology can Accounting nodes
help to bridge this gap with new applications for charging
vehicles that can popularize electric vehicles.
In this paper, we provide a consensus and incentive program
based on consortium blockchains. The paper has six sections.
Section I introduces the application status of blockchain in
the energy internet. Section II presents the logical structure
and hierarchical model of consortium blockchains. Section III Internet
presents a design of the consensus mechanism of the consor-
tium blockchains. Sections IV and V propose the accounting
incentive mechanism and the bidding encouragement strategy
based on “power profit bean.” In the final section, the research
is summarized.
Charging piles
II. T HE C ONSORTIUM B LOCKCHAIN M ODEL FOR
C HARGING P ILE A LLIANCE
Each charging pile in the charging pile alliance can be
Fig. 1. The logical structure of charging pile alliance.
seen as a node, and all nodes consist of the structure of
the consortium blockchain. In this paper, the consortium
blockchain is presented as a decentralized structure including Based on the above basic requirements, two types of ac-
the transaction nodes and accounting nodes. A transaction counting node distribution schemes can be devised:
node, i.e., a charging pile, can be viewed as a payment Scheme 1: The charging resources will determine how to
account that is used to conduct daily transactions, and enables allocate the number of accounting nodes. Here, the weighted
functions such as making payments, transmitting transaction average method is adopted to allocate the number of ac-
information, and performing other such internet interactions. counting nodes while taking into consideration factors such
An accounting node will function as a local data center. It is as number of charging piles, user registration number, average
responsible for providing accounting services and maintaining charge volume per month, average turnover per month, average
a global ledger for the consortium blockchain. The logical profit per month, and geographical distribution of the charging
structure is shown in Fig 1. piles in each company. Although this program can guarantee
According to the definition of transaction nodes and ac- the fairness of the accounting node allocation to a certain
counting nodes, an accounting node is a core of the consor- extent, the enterprises in the alliance may find it difficult to
tium blockchain. How to determine the number of account- reach an agreement because the authenticity of the average
ing nodes and allocate the accounting nodes in the consor- charge per month and other historical information is hard to
tium blockchain is the primary problem for the consortium verify.
454 CSEE JOURNAL OF POWER AND ENERGY SYSTEMS, VOL. 4, NO. 4, DECEMBER 2018
Scheme 2: Allocation of the number of accounting nodes is tocol. The encryption algorithm is not based on SHA256, but
based on the deposits. Enterprises in the alliance can get the adopted SM3. The consensus mechanism utilizes the byzantine
accounting nodes through auctions. They pay a certain deposit fault tolerant consensus, rather than proof of work (PoW). The
to acquire the right number of accounting nodes. The amount incentive layer achieve the accounting encouragement and the
of deposit may be fixed or they can capture the accounting charging pricing game by designing “power profit bean” and
node by auction. The advantage of this scheme is that the the contract layer is programmed based on the standardized
initial pool of funds can be set with a deposit, which can then contract template [13].
be used for the promotion scheme of the alliance development
and user incentive plans. It is important, however, that the III. T HE C ONSENSUS M ECHANISM BASED ON THE
deposit model sets the right threshold for accounting. The B YZANTINE FAULT T OLERANT
model will also need to build in some economic incentives
At present, the alternative consensus includes proof of
to facilitate the acceptance of the scheme.
work (PoW), proof of stake (PoS), delegated proof-of-stake
After considering the advantages and disadvantages of the (DPoS), ripple consensus and practical byzantine fault toler-
two plans, this paper adopts the deposit program to realize ance (PBFT). Since each accounting node of the consortium
the distribution of the accounting right. In this program, blockchains can record accurately and reliably the transaction
the consortium blockchain model consists of the data layer, data, the consensus algorithm is mainly used to solve the fault
network layer, consensus layer, incentive layer, contract layer tolerance problem in this paper.
and application layer. In the consortium blockchain model, the As a general algorithm for solving the fault-tolerant problem
data layer uses data encapsulation, data encryption, timestamp of a distributed system, the practical PBFT can tolerate some
and other technologies; the network layer mainly adopts the defaults caused by software bugs and security vulnerabili-
distributed network, data transmission, and data validation ties [13], [14]. For example, in a distributed system with
technology. The consensus algorithm of the network nodes M nodes, the practical byzantine fault tolerant algorithm
is encapsulated in the consensus layer; the economic factors guarantees that when all nodes participate in the consensus
are integrated into the blockchain system through the incentive process, some nodes make mistakes; however, the mistake
layer. The contract layer encapsulates the scripts, algorithms, amount f is less than or equal to (M − 1)/3. In this way,
and the intelligent contract, which forms the basis of pro- the system still maintains security and activity. The detailed
grammable characteristics of the blockchain. The application derivation and step for the PBFT algorithm are written in the
layer encapsulates the various unified payment application sce- following papers: [13], [15].
narios for power charge of the charging pile. The logical figure The consensus based on byzantine fault tolerance has been
of consortium blockchain model of charging pile alliance is applied to the blockchain, such as IBM introducing PBFT in
shown in Fig 2. Hyperledger fabric, and Onchain releasing antshares consensus
In the consortium blockchain model of the charging pile algorithm dBFT (delegated BFT) [15]. The data consistency of
alliance, both the data and network layers adopt the linked traditional blockchain cannot always be maintained between
storage structure similar to the bitcoin and P2P network pro- different replicas, and the same block may reach different
Cooperative operation
Hedging generate
electric Data block
beans
Openness Transparency
Fairness
Consensus
Electricity bill
Smart
Access restrictions Peer to Peer contract
Transaction
Fig. 2. The logical figure of consortium blockchain model of charging pile alliance.
HE et al.: A CONSENSUS AND INCENTIVE PROGRAM FOR CHARGING PILES BASED ON CONSORTIUM BLOCKCHAIN 455
nodes at different times, which leads to the bifurcation of the New transactions with the
signature of the sender from
blockchain. However, it is expected that the BFT consensus transaction nodes are broadcasted
will not be bifurcated within the fault tolerance. to all billing nodes
PBFT requires a quadratic number of messages in the
number of participants. Thus, the major bottleneck in scaling Current accounting node broadcasts
the block to all accounting nodes
classical byzantine consensus algorithms is network capac-
ity [14]. In order to save the payment time to ensure strong user
experience, the consortium blockchain of the charging pile Whether the Block No
alliance needs to reduce the block packing time. The overhead is accepted
for BFT consensus increases with number of participating
Yes To Record in the Mth block
nodes. If the number of participating nodes is limited (e.g.,
M = 20), the processing communication overhead will remain
The Mth block No
constant.
All accounting nodes in the consortium blockchain can Yes
participate in the consensus process, but the enterprises’
involvement or withdrawal will change the total number of To generate the accounting order
accounting nodes. By using multicycle accounting in the and information of accounting
nodes of the next round
charging pile alliance, we can see that each accounting round
contains M accounting nodes to ensure participation in the
consensus processing. To store in the Mth block
A. The Whole Process of Each Accounting Round Fig. 3. Each round of accounting process.
accounting nodes. pile. In addition, due to the different operating costs and
1) The first accounting node Idxi1 is generated from the set business strategies, their charge standards are also diverse.
of [1 ∼ Ni ] according to uniform distribution. The different charging pricing methods will make the checkout
2) Excluding the Idxi1 , the second accounting node Idxi2 process complex and “price confusion” for users.
is generated from the set of [1 ∼ Ni − 1] according to even To solve the above problems, the incentive strategy for
distribution. electrovalence competition is adopted in this paper, as follows:
3) Excluding the selected accounting nodes, the selection 1) Various identifiers are used to distinguish charging piles
method of subsequent accounting nodes is the same as above, that different enterprises in the alliance manage.
and the process will be over until IdxiM̂i is selected. 2) The electrovalence of different enterprises should be the
same.
D. Accounting Order of Each Cycle 3) Each enterprise, according to their own needs, issues the
The specific steps of the accounting order in each account- corresponding number of electric beans on the basis of the
ing cycle are as follows: achieved reward.
Step1: The selected accounting nodes should be arranged in 4) The electric beans are assigned to the users by means
order of the following method, of a charging rebate, selling or dispatching red envelopes.
The electric beans can be equivalent to the electrovalence, for
[Idx11 , Idx12 , · · · , Idx1M̂1 , IdxC1 , IdxC2 , · · · , IdxCM̂C ]
example, one electric bean is equivalent to assets per KWH
Step 2: The first accounting node P1 is generated from the (kilowatt hour) but only limited to the charging piles of the
set of [1 ∼ M ] according to uniform distribution. companies that give “electric beans” to the users.
Step 3: The second accounting node P2 is generated from
the set of [1 ∼ M − 1] according to even distribution, but VI. S IMULATION TEST
excluding the accounting node P1 in step 2. A. Test Environment
Step 4: The remainder of the accounting nodes is generated
in accordance with the method above. The result is then sorted Consensus nodes run on Amazon EC2 instances, and con-
in the set [P1 , P2 , · · · , PM ]. sensus node configuration is as follows: 2 CPU and 4GB
memory.
IV. I NCENTIVE M ECHANISM FOR ACCOUNTING B. Test Results
In order to encourage the enterprises in the alliance to In order to determine the best performance of the consor-
compete in the accounting rights, a corresponding accounting tium blockchain, a series of scenarios is designed with these
incentive mechanism needs to be designed. In this paper, the simulation results:
consortium blockchain achieves the incentive mechanism by 1) Throughput Under Different Block Sizes and Node Num-
means of generating “electric beans” as follows; bers
1) A percentage of fees is charged for all transactions in When block sizes and node numbers are different, the
each accounting cycle, and a reward funding pool is set up. throughput of the consortium blockchain is very different and
2) When producing the Mth block in each accounting cycle, has the following characteristics:
some commission fees are assigned to the nodes participating When a node number is determined, the throughput in-
in the accounting work. That is to say, if an accounting node creases with an increase in block size until it reaches a peak,
does not generate a block in an accounting cycle, it will not at which point there is a gradual decrease thereafter.
get the fee. When a block size is determined, the throughput of the con-
3) The assigned fee is momentarily frozen in the Mth block. sortium blockchain reduces when the node number increases.
4) According to the commission assigned to their reward Specifically, when the block size is big, the throughput drops
fee, each enterprise issues a certain number of electric beans, significantly.
for example, per kilowatt hour is equivalent to an electric bean. The test result is shown as Fig 4.
Electric beans equal to the reward fee given to the enterprises
in value. Block size
5) All enterprises can send electric beans to the user by 18,000
16,000
means of selling or giving bonus. 14,000
6) Users can use electric beans for charging transactions, 12,000
and then, the assigned fee is unfrozen. 10,000
So far, electric bean is able to complete the whole life 8,000
6,000
cycle. This incentive method thus does not yield extra fees 4,000
and excessive workflow and is simple and practicable. 2,000
0
128 256 512 1,024 2,048 4,096 8,192 16,384 32,768
V. T HE B IDDING E NCOURAGING S TRATEGY
4 node 16 node 32 node 64 node 128 node
Because the relationship between the enterprises in the
alliance is both cooperative and competitive, everyone will Fig. 4. Transactions per-second under different block size and node number.
strive to allow more users to charge in their own charging
HE et al.: A CONSENSUS AND INCENTIVE PROGRAM FOR CHARGING PILES BASED ON CONSORTIUM BLOCKCHAIN 457
32.9
2) Block Packing Time Under Different Block Size and Node
Numbers
When blocks size and node numbers are different, the block
16.5
packing time of the consortium blockchain is very different
and has the following characteristics:
When the node numbers are determined, as block size in-
0.116
creases, block packing time also increases. In the initial stage, 13:00 13:15 13:30 13:45
block packing time increases slowly with block size. When the CPU Utilization Network ln Network Out
block size reaches 4096, block packing time increases rapidly.
After reaching a peak, the increase levels off. Fig. 6. CPU utilization of the consensus node of the consortium blockchain.
When block size is determined, as the node number in-
creases, block packing time also increases. 920M
The test result is shown as Fig 5.
Fig. 5. Block packing time under different block size and node number.
467M
In general, the factors that affect the block packing time of
the consortium blockchain include throughput and block size.
At the beginning, block packing time is determined by the 56.0
throughput. With an increase in node number, block packing 13:00 13:15 13:30 13:45
time is determined by block size. CPU Utilization Network ln Network Out
A series of tests were conducted on security transactions.
The growth rate of block packing and throughput, as well Fig. 8. Network output of the consensus node of the consortium blockchain.
as performance of a consortium blockchain with 16 nodes
and 8,192 transactions in a block was shown to be excellent.
Moreover, the test demonstrated that the performance of the the consortium blockchain uses the practical byzantine fault
consortium blockchain can better account for security, speed, tolerance algorithm. To ensure the constant communication
and other indicators. overhead of the consensus mechanism, the method of multi-
3) System Performance of the Consortium Blockchain With 16 cycle accounting is proposed, and the amount of accounting
Nodes and 8,192 Transactions In A Block. nodes in every accounting cycle is limited. Enterprises are
encouraged to campaign for an accounting right, for which an
The CPU utilization, network input and network output
accounting incentive mechanism is provided and a bidding
of the consensus node of the consortium blockchain are
strategy proposed using the “electric beans” concept. This
respectively shown in Figs. 6–8.
paper looks forward to being helpful for promoting the de-
velopment of charging pile infrastructure so as to speed up
VII. C ONCLUSION the popularization of electric vehicles, which will eventually
At present, several enterprises have shown interest in doing promote the development of energy internet.
direct sale of charging piles to customers. The drawback,
however, is that these enterprises operate independently with R EFERENCES
each having its own pile infrastructure. As a result, each
[1] D. Kraft, “Difficulty control for blockchain-based consensus systems,”
enterprise has its own independent operation and maintenance Peer-to-Peer Networking and Applications, vol. 9, no. 2, pp. 397−413,
centers with respective APP payment programs. This results Mar. 2016.
in higher operating costs, poor user experience, and low [2] D. Wilson and G. Ateniese, “From pretty good to great: enhancing
PGP using bitcoin and the blockchain,” in Proceedings of the 9th
utilization rate of the pile, thereby ultimately hindering serious International Conference on Network and System Security, New York,
growth in electric vehicles. USA, 2015, pp. 368−375.
To solve the above problem, this paper proposes reach- [3] Q. K. Nguyen, “Blockchain – a financial technology for future sustain-
able development,” in Proceedings of the 3rd International Conference
ing a consensus and offering an incentive program based on Green Technology and Sustainable Development, Taiwan, China,
on a consortium blockchain. The consensus mechanism of 2016, pp. 51–54.
458 CSEE JOURNAL OF POWER AND ENERGY SYSTEMS, VOL. 4, NO. 4, DECEMBER 2018
[4] S. Wang, “Research status and innovation trend of blockchain technol- Yong Yan received the the B.S. and M.S. de-
ogy in financial field,” Shanghai Finance, no. 2, pp. 26–29, 2016. (in grees from South China University of Technology,
Chinese). Guangzhou, in 2009. His research interests include
[5] S. Huh, S. Cho, and S. Kim, “Managing IoT devices using blockchain blockchain, artificial intelligence (AI), and internet
platform,” in Proceedings of the 2017 19th International Conference technology.
on Advanced Communication Technology, Bongpyeong, South Korea,
2017, pp. 464–467.
[6] A. Dorri, S. S. Kanhere, R. Jurdak, and P. Gauravaram, “Blockchain
for IoT security and privacy: the case study of a smart home,” in
Proceedings of 2017 IEEE International Conference on Pervasive
Computing and Communications Workshops, Kona, HI, USA, 2017,
pp. 618–623.
[7] W. Ding, “Block chain based instrument data management system,”
China Instrumentation, no. 10, pp. 15−17, 2015.
[8] J. W. Cao, M. B. Yang, D. H. Zhang, Y. Y. Ming, K. Meng, Z.
Chen, and C. Lin, “Energy internet: an infrastructure for cyber-energy Junsheng Wang received the B.S. degree in Com-
integration,” Southern Power System Technology, vol. 8, no. 4, pp. 1– munications Engineering from Beijing University of
10, 2014. Posts and Telecommunications, Beijing, in 2003.
[9] J .W Cao, K. Meng, J. Y. Wang, M. B. Yang, Z. Chen, W. Z. Li, and He is the senior engineer and his research interests
C. Lin, “An energy internet and energy routers,” SCIENTIA SINICA include Communication and information technology,
Information , vol. 44, no. 6, pp. 714–727, 2014. Machine Learning (ML), and Internet Technology.
[10] J. Y. Wang, J. H. Guo, J. W. Cao, L. C. Gao, Z. W. Hu, J. Zhou, Y.
Y. Ming, and Z. W. Fang, “Review on information and communication
key technologies of energy internet,” Smart Grid, vol. 3, no. 6, pp.
473–485, 2015.
[11] F. Yang, C. F. Bai, and Y. B. Zhang, “Research on the value and
implementation framework of energy internet,” Proceedings of the
CSEE, vol. 35, no. 14, pp. 3495–3502, Jul. 2015.
[12] C. Nguyen. (2016, Mar. 18). An indie, off-the-grid, blockchain-
traded solar power market comes to brooklyn[Online]. Available: Qingzhi Han received the M.S. degree in control
https://motherboard.vice.com/en us/article/yp3pvm/the-plan-to-power- engineering from University of Science and Tech-
brooklyn-with-a-blockchain-based-microgrid-transactive-solar nology Liaoning, Anshan, in 2016. His research in-
[13] M. Castro and B. Liskov, “Practical byzantine fault tolerance and terests include human face recognition and machine
proactive recovery,” ACM Transactions on Computer Systems, vol. 20, learning (ML).
no. 4, pp. 398–461, Nov. 2002.
[14] J. Fan, L. T. Yi, and J. W. Shu, “Research on the technologies of
byzantine system,” Journal of Software, vol. 24, no. 6, pp. 1346–1360,
2013.
[15] Z. W. Zhang. A byzantine fault-tolerant algorithm for blockchains
(2016)[Online]. Available: http://docs.neo.org/zh-cn/basic/consensus/
whitepaper.html (in Chinese).