Source-linked AI summary

Peer-to-Peer Energy Trading in a Microgrid Leveraged by Smart Contracts

Guilherme Vieira, Jie Zhang

arXiv:2201.04944v1cs.MAcs.GT

TL;DR

The aging centralized grid was built for one-way power flow, while local energy markets need secure and transparent management. The paper develops two blockchain- and auction-based frameworks for autonomous trading in microgrids. It reports lower average daily household costs for P2P trading than for using the national grid alone.

  • Problem

    The centralized grid was built for one-way power flow and incurs transmission losses, while autonomous local energy markets need secure, reliable, and transparent management.

    Source: §1 · pp. 1–3
  • Method

    The paper develops two frameworks that use auction mechanisms, agent logic, and smart contracts to aggregate local energy demand and supply and trade for prosumers.

    Source: §1 · p. 3, §2.1 · p. 5
  • Results

    Average total trading cost was about $0.74 per household per day, compared with $2.18 per household per day for using the national grid.

    Source: §3 · p. 11
  • Takeaways & Limitations

    The authors conclude that decentralized microgrids could complement the centralized grid and potentially reduce transmission dissipation and grid load.

    Source: §5 · p. 14

    Further testing needs more extensive simulations and a consistent framework across both market mechanisms; the cost analysis also omits transmission and distribution costs and battery inefficiencies.

    Source: §4 · p. 13

Abstract

from arXiv · show

The current electricity networks were not initially designed for the high integration of variable generation technologies. They suffer significant losses due to the combustion of fossil fuels, the long-distance transmission, and distribution of the power to the network. Recently, \emph{prosumers}, both consumers and producers, emerge with the increasing affordability to invest in domestic solar systems. Prosumers may trade within their communities to better manage their demand and supply as well as providing social and economic benefits. In this paper, we explore the use of Blockchain technologies and auction mechanisms to facilitate autonomous peer-to-peer energy trading within microgrids. We design two frameworks that utilize the smart contract functionality in Ethereum and employ the continuous double auction and uniform-price double-sided auction mechanisms, respectively. We validate our design by conducting A/B tests to compare the performance of different frameworks on a real-world dataset. The key characteristics of the two frameworks and several cost analyses are presented for comparison. Our results demonstrate that a P2P trading platform that integrates the blockchain technologies and agent-based systems is promising to complement the current centralized energy grid. We also identify a number of limitations, alternative solutions, and directions for future work.

1 Introduction

The introduction frames P2P microgrid trading as a response to a centralized grid built for one-way power flow and describes blockchain-enabled auction frameworks as a way to organize autonomous local energy markets. It situates the proposal among prior blockchain trading work and established auction mechanisms.

1 Introduction

  • Long-distance transmission creates power losses, while the centralized grid does not match demand and supply in real time, contributing to overproduction.The introduction notes that excess production during low-demand periods can result in negative electricity prices.Source: §1 · pp. 1–2
  • Microgrids group prosumers into local energy markets that trade within communities and can support real-time pricing and local balancing of generation and consumption.The introduction also identifies potential community self-sustainability and reduced latency in managing congestion and distribution faults.Source: §1 · p. 2
  • Autonomous local markets require secure, reliable, transparent management and user-friendly applications; the paper presents blockchain as a potential platform for these needs.The cited background describes blockchain records as distributed and immutable.Source: §1 · pp. 2–3
  • The paper proposes two auction-based frameworks that aggregate local demand and supply, use agents to trade for prosumers, and enable autonomous transactions through smart contracts.Its evaluation compares their costs with households relying on the national grid and reflects on assumptions, challenges, and future work.Source: §1 · p. 3

1.1 Related Work

  • Prior work includes cooperative blockchain negotiation, smart-contract electricity trading, a conceptual microgrid market, and comparisons of blockchain protocols for trading platforms.The introduction describes as an energy trading platform for decentralized renewable-energy sales and purchases, and names TransActive Grid.Source: §1.1 · pp. 3–4
  • The paper examines continuous double auctions, where crossing bids and asks can match trades, and uniform-price double-sided auctions, which set an interval price from aggregated demand and supply.The introduction notes the former's use in financial exchanges and the latter's use in day-ahead energy markets.Source: §1.1 · p. 4

2 Framework Design and Implementation

This section specifies the model inputs and auction rules, then describes two Ethereum-based trading architectures and their agent and application implementation.

2.1 Components of the Model

  • Ethereum is selected for its smart-contract business logic; public blockchains favor decentralization and security, while permissioned ones favor efficiency, and Ethereum's then-current PoW is criticized for electricity use.The paper contrasts Ethereum with Hyperledger Fabric and NEO as smart-contract platforms.Source: §2.1 · pp. 4–5
  • Ethereum state-changing operations incur gas costs; the model sets gas price to 2e10 Wei, Ether at $250, and account transfers at 21,000 gas.Gas limit sets the maximum gas a user is willing to pay for a transaction.Source: §2.1 · p. 5
  • The continuous double auction matches a bid above the lowest ask; the uniform-price auction clears hourly at the intersection of aggregated supply and demand.All participants trade at the resulting equilibrium price, then the market resets for the next hour.Source: §2.1 · p. 5
  • The Pecan Street dataset, drawn from over a thousand homes, included 250 households with installed solar systems, mainly in Austin, and provided household energy profiles, load, demand, grid use, and utility composition.Each agent instance represents a household.Source: §2.1 · p. 6
  • Household LCOE uses system cost and generation, with battery scenarios and biomass priced at 5–12 cents/kWh; offer prices are bounded by seller LCOE and national-grid price.The model assigns those two bounds two standard deviations below and above the mean, respectively, in a truncated normal distribution.Source: §2.1 · p. 6

2.2 Two Frameworks

  • Framework 1 keeps storage, computation, and trading on-chain, while Framework 2 moves computation and offer matching off-chain and removes household contracts and the factory.Framework 2's application calculates the uniform price and matches offers at the end of each epoch.Source: §2.2 · pp. 6–7
  • Agents check energy surplus or shortage and battery thresholds, sell when prices are high, buy when low, forecast needs up to 10 hours ahead, and use grid backup below 20% battery.Agents act independently without coordination.Source: §2.2 · pp. 7–9
  • The JavaScript simulation models households as independent agents; contracts are tested with Mocha before a React/Next.js interface is built, with Ganache-cli and Web3 supporting local testing and access.Simulation output is exported to CSV for Python analysis.Source: §2.2 · pp. 8–9

3 Evaluation

The evaluation compares two auction frameworks on trading costs, prices, battery behavior, and system design. P2P trading costs were lower than national-grid costs, while the auctions differed in prices, trading volume, and decentralization trade-offs.

3 Evaluation

  • Framework 1 keeps storage, computation, and value exchange on-chain, making it more decentralized and secure but slower; Framework 2 computes externally, reducing transactions but relying on a less-secure centralized server.The uniform-price calculation was too computationally demanding for a smart contract.Source: §3 · p. 10
  • Figure 4 shows average prices of about 8.0 cents per kWh for the continuous double auction and 4.4 cents for the uniform-price auction.In six-month simulations excluding zero-activity periods, averages were 8.1 and 4.2 cents per kWh, respectively; the uniform-price auction traded more electricity but could produce negative producer utility when prices fell below the 7-cent average producer cost.Source: §3 · pp. 10–11, Figure 4 · p. 11
  • Figure 5 shows average P2P trading costs of $0.74 per household per day, versus $2.18 for national-grid electricity.Longer simulations showed national-grid costs around three-fold those of the blockchain P2P platform.Source: §3 · p. 11, Figure 5 · p. 12
  • Figure 6 shows battery charge patterns in both frameworks; the uniform-price auction’s 50% threshold prompts purchases intended to cover the next 10 hours.Battery charge in the continuous double auction tended not to drop much below 50%.Source: §3 · p. 11, Figure 6 · p. 12

4 Reflection and Future Work

The uniform-price auction traded more energy at lower prices than the other mechanism. The reflection identifies modeling assumptions and blockchain constraints, and proposes optimization, alternative contract designs, and further testing.

4 Reflection and Future Work

  • The uniform-price auction traded more energy at lower prices than the continuous double auction.The mechanisms were implemented with real-world data.Source: §4 · p. 12
  • The solar-energy price calculations omit transmission and distribution costs, as well as battery charging and discharging inefficiencies.These omissions reflect the paper’s focus on overall architecture design.Source: §4 · p. 13
  • Ethereum throughput was not a concern for hourly trading in the closed test, but 1- or 5-minute intervals could leave transactions unprocessed and market information incomplete.The paper notes Ethereum’s 15-second block intervals.Source: §4 · p. 13
  • The authors describe IOTA as a potentially scalable, low-cost alternative, but note that its framework was still academic and untested.They also note that IOTA’s smart-contract layer was under development.Source: §4 · p. 13
  • Agent-logic optimization could improve transaction costs and efficiency, but comparing which market mechanism is most applicable requires broader simulations and a consistent framework.The proposed optimization includes order timing, price, battery charge and discharge levels, and household constraints such as battery depth of discharge and inefficiencies.Source: §4 · p. 13
  • A proposed alternative would let agents contact a continuous-double-auction smart contract directly, but automatic matching cannot transfer value between user accounts without trade-specific contracts.The cost of creating those contracts remains to be tested against the current approach.Source: §4 · p. 13
  • The framework should account for agents’ strategic behavior; candidate continuous-double-auction strategies include ZI, ZIP, and GD.The paper identifies bidding strategy as an important problem in auction mechanisms.Source: §4 · pp. 13–14

5 Conclusion

The authors conclude that decentralized models could potentially reduce grid burdens if fully developed. They envision microgrids complementing the national grid in a greener, more economical energy market.

5 Conclusion

  • If fully developed, decentralized models could potentially minimize power transmission dissipation.Source: §5 · p. 14
  • If fully developed, decentralized models could potentially reduce the probability of cascade failure through inherent islanding capability.Source: §5 · p. 14
  • The authors propose that autonomous microgrids and the centralized national grid complement each other in a greener, more economical energy market.Source: §5 · p. 14
Loading 2201.04944v1…