Abstract
The rapid deployment of distributed photovoltaic (PV) systems in modern distribution networks challenges traditional centralized grid management, causing issues such as reverse power flow and voltage fluctuations. Peer-to-peer (P2P) energy trading offers a promising decentralized solution to enhance local self-consumption and lower electricity costs. However, managing highly dynamic, uncertain, and multi-actor interactions in P2P markets remains a formidable challenge. This paper proposes a novel Multi-Agent Deep Reinforcement Learning (MADRL) framework based on the Multi-Agent Deep Deterministic Policy Gradient (MADDPG) algorithm to facilitate decentralized P2P energy trading in microgrids with high PV penetration. Each prosumer is modeled as an autonomous agent that learns optimal pricing and trading strategies under local supply-demand fluctuations and time-varying utility tariffs, without sharing private operational data. To improve convergence and market efficiency, we incorporate a continuous action space and a customized reward function that balances individual economic benefits with local grid stability. Simulation results based on real-world consumption and generation profiles demonstrate that the proposed MADRL framework reduces average prosumer energy costs by up to 18.4% and lowers the peak-to-average ratio (PAR) of the microgrid by 22.1% compared to traditional peer-to-grid and rule-based trading baselines. These findings highlight the potential of decentralized, learning-based approaches in enabling resilient and self-organizing community energy systems.