Currently, energy is primarily produced by large, centralized energy-plant rendering through Nonrenewable Energy Sources (NRESs). The use of centralized energy plants run by NRESs causes energy losses during power transmission and environmental degradation. The high penetration of Renewable Energy Sources (RESs) into the power system reduces the environmental crisis and the energy losses as energy is generated close to where it is consumed. Another solution to centralized energy generation is the introduction of Distributed Energy Resources (DERs). DER increases the overall cost savings for the customer, allows consumers to control their power, and reduces gas emissions by shifting from NRES to RES.
As a result of the rapid increase in DERs’ connections, conventional consumers of energy are transforming into prosumers, i.e., someone who simultaneously generates and consumes energy. DER simply mean electricity resources, which are connected directly to Low Voltage (LV) or Medium Voltage (MV) distributed system [1
]. DERs include both energy storage technology and generation units such as flywheels, batteries, Superconducting Magnetic Energy Storage (SMES), Photovoltaics (PVs), micro-turbines, and Electric Vehicles (EV) as illustrated in Figure 1
, and Nomenclature shows the list of abbreviations and symbols in this research work. The figure depicts the technologies that support the DER system. For more information about technologies mentioned in the figure, please refer to Reference [1
]. It is challenging to forecast the intermittent energy generation of DER. Due to this issue, prosumers curtail their surplus electricity, store it in a device, transport it to the main grid, or trade it with neighbors (other consumers) [2
]. Customer in this paper refers to both consumer and prosumer, especially in a situation where both perform the same function. The direct buying or selling of energy among prosumers and consumers is known as Peer-to-Peer (P2P) trading of energy. Trading of energy among prosumers and consumers is one of the rapidly growing concepts in distributed networks. The sharing economy model is the foundation of P2P energy exchange in a distributed local electricity network [3
]. A node in a network of energy trading is referred to as local energy prosumer or consumer. A node is also known as a peer who directly sells or purchases energy with other peers without the involvement of an intermediary controller. The current energy markets lack the ability to react in real-time or near real-time to the intermittent and volatile nature of RES generation [4
]. In addition, market prices are usually set at the national level, which does not show the availability of local surplus energy or energy supply shortages [5
]. However, modern market techniques must also reflect the locality of their services in order to promote DER’s inclusion into the power system. Microgrids are a geographically small community of numerous connected DER and loads [6
] and can also improve energy supply stability since they provide the opportunity to supply power in the case of superordinate grid energy failures [7
The advancement in information and communication technology allows P2P energy trading to take place. In conventional energy trading, the flow of transactions is unidirectional, whereby energy is transmitted from a single source of energy generation to customers from a very long distance while the flow of cash goes the other way round. However, P2P energy trading needs multidirectional trading within a local area and allows advanced communication. The challenges identified in P2P energy trading are information security, information leakages, privacy, loss of data, etc. Most of these problems can be addressed using blockchain technology.
The evolving technology, blockchain [8
], brings new potential for decentralized network designs and provides transparent and user-friendly frameworks [9
]. It creates opportunities for energy users to be involved in making choices about who supplies their energy and the technologies used to generate it.
In recent years, industries, academics, and research domains are involved in utilizing blockchain technology with its potentials to decentralize the complex energy market’s networks and P2P energy trading. The authors in Reference [10
] propose a small machine-to-machine energy market based on blockchain with a customer and two suppliers in a chemical industry. The proposed system uses proof-of-concept algorithm for consensus. The proposed work shows that blockchain can create a small-scale energy market. In another work [11
], the authors examine neighborhood energy growth into local self-sufficient utility production. The authors further explore the opportunities of microgrid energy markets based on blockchain for the development of distributed RES platforms and the associated problems for Australia’s conventional power grid. It is explicitly stated that the usage of modern distributed ledger (blockchain) in transactions of energy makes microgrids more robust by establishing confidence among the agents involved, particularly with regard to energy delivery and financial payments processes. The authors in Reference [12
] utilize blockchain-based technology to establish a continuous auction platform. The auction mechanism in the model allows supply and demand to keep adding and matching without discrete clearing steps. The authors in Reference [13
] present a P2P negotiation model in Local Energy Market (LEM) that has randomized sellers and buyers matching without a central authority. The trading takes place between directly affected parties on a bilateral basis. LEM is a regionally limited market system with special sale price mechanisms among interdependent customers (generators, prosumers, and consumers). The customers can either have an energy generation or demand at any given time slot.
In Reference [14
], the authors present a combinatorial double auction technique for pricing and distribution of energy resources, taking into account the needs of energy consumers and prosumers in particular. In this research work, we propose a secure, decentralized, anonymous, transparent, immutable, and verifiable energy trading mechanism. The objective of the proposed work is to maximize energy supplies and economic benefits at all levels for both the community and end-users.
The remaining part of this paper is organized as follows: related work and problem statement are discussed in Section 2
and Section 3
. Section 4
presents the proposed system model and its description. Section 5
elaborates price model and cost model of consumers and prosumers and discusses self-sufficiency and self-consumption, while security analysis and simulation results are presented in Section 6
and Section 7
. Finally, the conclusion and future work are presented in Section 8
2. Related Work
The authors in Reference [8
] proposed an NRGcoin model, also called a novel decentralized digital currency. The model allows locally generated renewable energy from prosumers to be sold using the digital currency organized by the market paradigm of buyers and sellers of green energy in a smart grid. The authors in Reference [12
] presented an adaptive aggressive strategy in a microgrid using blockchain-based Continuous Double Auction (CDA), putting forward a new perspective on an energy market. However, various bid combinations may have distinct initial conditions, and there is an inadequate flexibility to change the bid quantity during the CDA bid process.
Similarly, in Reference [15
], the authors presented a secure credit-based system of payment by reducing wait times for transaction confirmation of the energy chain in permissioned blockchain-based Industrial Internet of Things (IIoTs). Reducing the wait time makes electricity trading faster and responses more frequent. The authors also used an optimal pricing mechanism by exploring the idea of stackelberg game theory to optimize bank utility credit-based loans.
The authors in Reference [16
] proposed a P2P Electricity Trading system with COnsortium blockchaiN (PETCON) model to conduct secure private P2P trading of energy between plugin hybrid electric vehicles. The study focused on establishing trust and used the anonymous property of blockchains to defend the user’s privacy. In Reference [17
], an approach based on the power quality perceived by a specific economical category is proposed. However, the proposed model does not consider security issues, privacy leakages, and single point of failure.
The authors in Reference [20
] attempted to provide a decentralize and secure transaction using blockchain technology in the smart grid. In the research, participants anonymously negotiate the trading price and perform secure transactions using anonymous, encrypted messaging streams and multi-signatures. The proposed work is different from this research work by willingly allowing or encouraging all prosumers to become sellers and self-sufficient consumers in peak hours of energy generation. Similarly, in Reference [21
], the authors proposed a system of distributed energy trading to encourage P2P sharing of electricity between prosumers. There are two layers in the proposed model. In the first layer, the agent coalition mechanism is proposed to allow prosumers to establish a coalition and to negotiate energy trading. A blockchain-based settlement of transactions is proposed in the second layer. A distributed approach to control Demand Response (DR) systems in a smart grid context is proposed in Reference [22
]. The elements of the grid are integrated with the smart contract’s blockchain framework to ensure the verification of DR agreements, the programmatic definition of expected energy flexibility levels, the balance within production and demand of energy, and the validation of DR agreements. In Reference [23
], Thakur et al. presented a distributed, scalable, and secure blockchain-based network for coalition structure creation and microgrid energy trading. However, the determination of the trading price between the parties is difficult to reach via negotiation. Similarly, the research work in Reference [24
] aimed to provide an energy trading model that will facilitate a sustainable transaction of energy ecosystems among smart homes’ consumers and prosumers. However, energy and profit optimizations are not considered.
The work proposed in Reference [25
] not only decreases the peak to average ratio, benefiting the grid, but also smoothens the dips of the profile load caused by constraints in supply. Also, the work proposed an enhanced blockchain approach to implement a distributed microgrid network that handles the micro-payment along with the exchange of energy and information. Furthermore, a noncooperative theoretical game approach is proposed for a Demand Side Management (DSM) model that incorporates storage components. Privacy has been highlighted as a major barrier to customer engagement in the research. The authors in Reference [26
] proposed an Internet of Things (IoT) system to account for power flows as well as a blockchain platform to resolve the need for a centralized entity. It allows LEM to manage the decentralized transfers of energy without the need for central control. On the other hand, a new approach for smart city network architecture is proposed [27
]. The architecture combined the benefits of blockchain technology and emerging Software-Defined Network (SDN). The rapid growth in volume and number for the connected IoT devices came with challenges: for instance, bandwidth bottleneck, scalability, privacy, and high latency in the current architecture of smart city networks. The current limitations are drastically reduced by introducing blockchain and by dividing the architecture into the core and edge networks. However, there are still some issues that are left unresolved, such as memory scalability, high latency, and efficient deployment of edge nodes. An interesting lab-scale implementation is proposed in Reference [28
]. For the sake of sharing solar energy, this framework depends on a hyperledger fabric blockchain platform.
In another work [29
], the authors propose a survey on distributed energy trading principles in a smart grid. The authors discussed topics like the advantages of distributed energy trading and reasons behind its implementation, the technology needed to develop these framework, and a review of past literature work. Mengelkamp et al. [30
] identified seven microgrid electricity market principles and assessed the Brooklyn Microgrid in compliance with those principles. The authors developed and modeled a local power market with a more realistic emphasis on a private Ethereum blockchain that allows users to exchange locally generated energy supply on a distributed and decentralized exchange system without the involvement of control authority. However, efficient allocation and pricing mechanisms are not developed. Furthermore, Table 1
gives a summary of the related work.
3. Problem Statement
The authors in Reference [30
] proposed a decentralized market mechanism using a private blockchain and an auction method to determine the price. However, trading of surplus energy through auction or bidding is logically impossible for all users [33
]. The reason is that some consumers or prosumers cannot participate in the trading due to limited time, lack of expertise, and above all, lack of technology. Similarly, another problem arose in References [31
], and there is a possibility for the occurrence of single point of failure since the proposed models allowed a third party to serve as a controller to manage or control prosumers’ batteries and all transaction information. Moreover, the system is prone to privacy threats, i.e., information disclosure and security concern. Additionally, including a third party requires a central processing center to process and collect the information of all participants, which is challenging in DER. Two problems naturally arise when relying on a third party. Firstly, intensive communication infrastructures are needed in the case of a central controller. Secondly, it is difficult to encourage a large number of participants in energy trading. The exponential development of energy trading shows the importance of related research.
Generally, according to the literature discussed in References [30
], most of the research do not emphasize how to resolve the privacy and security challenges and a single point of failure problem. Moreover, none of the literature explicitly considers resolving the issues of energy hoarders in peak generation hours. Also, the research work does not consider combining the conventional LEM mechanism, HEM system, and blockchain technology concurrently. Combining these mechanisms will centrally merge their benefits in a single pool. We propose an LEM using private blockchain by considering the HEM system and demurrage mechanism in a community with residential PV energy generations. The proposed model allows prosumers and consumers to manage their resources and information in a decentralized, secure, trustful, transparent, anonymous, and verifiable manner. The comparison of existing work with proposed model is given in Table 2
. The main research contributions of the proposed work are as follows:
an LEM using private blockchain is proposed, which considers both HEM system and demurrage mechanism simultaneously,
a dynamic pricing mechanism is proposed for energy trading to take place. This mechanism ensures that all members participating in local energy trading gain better economic benefits. This pricing model is modified from the Supply and Demand Ratio (SDR) mechanism [32
] to include demurrage value, and
a thorough assessment is conducted in the research to evaluate the economic benefits of the buyers and sellers of locally generated energy in a residential community. Also, based on the proposed system, the potential security risks of the energy trading system are analyzed. Conclusively, a complete security protection technique is provided against these security vulnerabilities in the system.
8. Conclusions and Future Work
In this work, we propose an LEM using private blockchain within a small community with many PV systems. In this research, users perform trading using a simple exchange mechanism to eradicate the problem of auctions, as stated in the literature. A dynamic pricing model and HEM system are introduced to increase economic benefits at both the community and individual levels. The simulation findings demonstrate that the proposed method reduces electricity cost and optimizes energy consumption, especially at peak hours. With CPP, the electricity costs are reduced up to 44.73% when the scheduling algorithm is applied. It reduced the electricity cost up to 65.17% when the P2P price model and demurrage are used. Furthermore, it reduced the electricity cost up to 51.80% when applying the P2P pricing model and the scheduling algorithm with demurrage at peak hours. Similarly, with the RTP scheme, the proposed method that implements the P2P price model with demurrage mechanism and scheduling algorithm reduces the electricity cost up to 44.37% as compared to 28.55% when scheduling algorithm is used and to 35.09% when P2P pricing model with demurrage mechanism is applied at peak hours. Moreover, the proposed method achieves optimal electricity cost for each time slot as compared to the utility prices and falls within the FR range. Additionally, the proposed model balances the local energy demand and generation of households without violating the customers’ comfort. Furthermore, security vulnerability analysis is carried out, and the results show that the energy trading smart contract is secure and bug-free against the known vulnerabilities and attacks.
In the future, penalty policy will be incorporated to evaluate prediction deviations in the forecast profile and to improve trading within the neighborhoods. Additionally, a robust mechanism will be developed to solve the issues of the creation of rebounce in off-peak hours.