scieee AI-readable full text Open interactive document viewer

A systematic review of machine learning techniques related to local energy communities

Hernández Matheus, Alejandro Henrique,Löschenbrand, Markus,Berg, Kjersti,Fuchs, Ida,Aragüés Peñalba, Mònica,Bullich Massagué, Eduard,Sumper, Andreas

Abstract

In recent years, digitalisation has rendered machine learning a key tool for improving processes in several sectors, as in the case of electrical power systems. Machine learning algorithms are data-driven models based on statistical learning theory and employed as a tool to exploit the data generated by the power system and its users. Energy communities are emerging as novel organisations for consumers and prosumers in the distribution grid. These communities may operate differently depending on their objectives and the potential service the community wants to offer to the distribution system operator. This paper presents the conceptualisation of a local energy community on the basis of a review of 25 energy community projects. Furthermore, an extensive literature review of machine learning algorithms for local energy community applications was conducted, and these algorithms were categorised according to forecasting, storage optimisation, energy management systems, power stability and quality, security, and energy transactions. The main algorithms reported in the literature were analysed and classified as supervised, unsupervised, and reinforcement learning algorithms. The findings demonstrate the manner in which supervised learning can provide accurate models for forecasting tasks. Similarly, reinforcement learning presents interesting capabilities in terms of control-related applications.

Full text

Renewable and Sustainable Energy Reviews 170 (2022) 112651 Available online 3 October 2022 1364-0321/© 2022 The Author(s). Published by Elsevier Ltd. This is an open access article under the CC BY-NC license (http://creativecommons.org/licenses/bync/4.0/). Contents lists available at ScienceDirect Renewable and Sustainable Energy Reviews journal homepage: www.elsevier.com/locate/rser Review article A systematic review of machine learning techniques related to local energy communities Alejandro Hernandez-Matheusa,∗ , Markus Löschenbrandb, Kjersti Bergb,c, Ida Fuchsc, Mònica Aragüés-Peñalbaa, Eduard Bullich-Massaguéa, Andreas Sumpera aCentre d’Innovacin Tecnológica en Convertidors Estàtics i Accionaments (CITCEA-UPC), Department dEnginyeria Elèctrica, Universitat Politècnica de Catalunya, UPC, Av. Diagonal 647, Pl. 2., Barcelona, 08028, Catalunya, Spain bDepartment of Energy Systems, SINTEF Energy Research, Sem Sælands vei 11, Trondheim 7034, Norway cDepartment of Electric Power Engineering, Norwegian University of Science and Technology (NTNU), O. S. Bragstads plass 2E, Trondheim 7034, Norway ARTICLE INFO Keywords: Local energy communities Machine learning Energy decentralisation Energy forecasting Energy management systems Energy transactions ABSTRACT In recent years, digitalisation has rendered machine learning a key tool for improving processes in several sectors, as in the case of electrical power systems. Machine learning algorithms are data-driven models based on statistical learning theory and employed as a tool to exploit the data generated by the power system and its users. Energy communities are emerging as novel organisations for consumers and prosumers in the distribution grid. These communities may operate differently depending on their objectives and the potential service the community wants to offer to the distribution system operator. This paper presents the conceptualisation of a local energy community on the basis of a review of 25 energy community projects. Furthermore, an extensive literature review of machine learning algorithms for local energy community applications was conducted, and these algorithms were categorised according to forecasting, storage optimisation, energy management systems, power stability and quality, security, and energy transactions. The main algorithms reported in the literature were analysed and classified as supervised, unsupervised, and reinforcement learning algorithms. The findings demonstrate the manner in which supervised learning can provide accurate models for forecasting tasks. Similarly, reinforcement learning presents interesting capabilities in terms of control-related applications. 1. Introduction Recent technological developments in renewable energy have enabled a shift in the energy generation capacity closer to the consumption. This evolution has led to a decentralisation process that is required for the coordination of generation and demand in electric power systems. A part of this process involves the management of a greater number of active consumers and so-called prosumers, i.e., consumers who also produce electricity in the grid. Consequently, the energy sector is transitioning towards a more decentralised control owing to these prosumers and active consumers, who cooperate for the management and control of storage systems and flexible demand. A resulting framework attempting to solve the challenges associated with this decentralisation is that of local energy communities (LECs) representing local, self-organising entities that operate autonomously or semi-autonomously within an electricity grid [1]. The shift towards a more community-focused approach from a traditionally centralised ∗Corresponding author at: Centre d’Innovacin Tecnológica en Convertidors Estàtics i Accionaments (CITCEA-UPC), Department dEnginyeria Elèctrica, Universitat Politècnica de Catalunya, UPC, Av. Diagonal 647, Pl. 2., Barcelona, 08028, Catalunya, Spain. E-mail address: [email protected] (A. Hernandez-Matheus). power system is further amplified by the increasing digitalisation of these systems, for example, in terms of the metering and control of energy. In this context, recently popularised technologies such as distributed ledgers [2], big data applications and artificial intelligence have shown promising results for shaping the future of decentralised power systems [3]. This paper focuses on the recently growing field of machine learning, which is a subcategory of the research field of artificial intelligence. Machine learning is based on the development of computer systems that can learn from data without explicitly following instructions. This learning is achieved via algorithms and statistical models to analyse and draw inferences from the data patterns. In several research fields such as those of medicine and finance, machine learning has been used to solve high-complexity problems. Moreover, community-based power systems are no exception to the advent of machine learning [4]. This study aims to discover a relationship between the operation of LECs and https://doi.org/10.1016/j.rser.2022.112651 Received 6 September 2021; Received in revised form 17 May 2022; Accepted 30 May 2022 Renewable and Sustainable Energy Reviews 170 (2022) 112651 2 A. Hernandez-Matheus et al. existing machine learning algorithms on the basis of recent research reported in the literature. 1.1. Research questions and contributions This study aims to provide a systematic review on the state-of-the- art of machine learning that are applicable for LECs. Towards this end, an in-depth discussion and conceptualisation has been provided to answer the following question: ‘what constitutes as a local energy community?’; the LEC characteristics have been defined from the perspective of European electricity systems. Following this general conceptualisation, an extensive review was conducted on the basis of the previously derived characteristics of LECs to answer the following question: ‘which machine learning literature is related to local energy communities’. Eventually, an answer has been presented to the following question: ‘what future trends and conclusions can be drawn from machine learning utilised in local energy communities?’. In summary, the contributions of this paper are as follows: 1. A conceptualisation of LECs from a European perspective 2. An extensive review of state-of-the-art machine learning literature associated with LECs 3. Detailed applications of machine learning methods within LECs 4. An evaluation of and the future outlook on machine learning methods that are utilised in LECs 1.2. Outline This paper is structured as follows: In Section 2, LEC definitions within regulatory frameworks and existing community-based energy projects are presented. Furthermore, the criteria for conceptualising an LEC are explored in detail. In Section 3a meta-review of the associated literature, aiming to better contextualise the present work with respect to the existing literature reviews, is presented. In Section 4, an initial overview of the different machine learning tasks and techniques are listed. Furthermore, the different practical applications of machine learning in LECs have been analysed, and a structured evaluation of these applications is presented in Section 5. Finally, a summary of the main research findings as well as an outline of current developments, potential trends in the future, and suggestions for further research direction are presented in Section 6. 2. Local energy communities Although it has been indirectly defined in literature, for example, the general definition within the regulatory framework of the European Union (EU) for energy communities, to the best of the authors’ knowledge, no direct definition of LEC has been reported in the relevant literature. To close this research gap, the authors of this study analysed 25 existing community-based energy projects on the basis of two EU regulatory definitions of energy communities. Accordingly, a definition of an LEC is presented in this study. This definition serves as the foundation for the identification of the areas of application for machine learning methods. 2.1. Classification of local energy communities In the existing literature, an LEC has been perceived mainly as a technical rather than a structural concept. However, the definition of an LEC extends beyond purely technical, social, and organisational aspects [5]. In a study [6], the authors analysed different approaches and terms for the integration of local energy systems into a larger centralised energy system. They investigated community microgrids, virtual power plants, energy hubs, prosumer community groups, community energy systems, and integrated community energy systems. Subsequently, the authors introduced a comprehensive concept for integrated community energy systems, which is similar to the concept of LEC and is presented in Section 2.2. In another study [7], the authors defined ‘clean energy communities’ as social and organisational structures that are formed to achieve the specific goals of its members, primarily in terms of clean energy production, consumption, supply, and distribution. They analysed the long-term dynamics and possible pathways of the transition from centralised to decentralised systems in the energy sector as well as the co-evolution of energy systems and energy communities. This study aims to explore the manner in which different machine learning techniques can assist in the operation of LECs and optimisation of their local energy systems. As presented in the following sections, the foundation for a framework for LECs has been established on the basis of two different definitions within the EU regulatory framework and analyses of 25 existing community-based energy projects. 2.1.1. Regulatory definitions As mentioned, the EU has issued two directives with official definitions that are proximate to those of LECs: ‘Renewable Energy Community’ (REC) [8] and ‘Citizen Energy Community’ (CEC) [9]. These definitions are listed in Table 1. Member states must revise national laws to comply with the EU rules, and therefore, they must develop national-level definitions for citizen and renewable energy communities. The specific differences between citizen and renewable energy communities are further explored in detail in the literature [1]. The authors explored renewable energy communities to showcase certain characteristics that are not inherited by the citizen energy communities: a specific geographical scope owing to the required proximity to renewable energy projects, a more restricted membership, i.e., participants cannot join the renewable energy community as their primary economic activity, a need for autonomy from individual participants or stakeholders, and the possibility of grid control by enterprises located in the proximity of the renewable energy project. Furthermore, unlike the renewable energy community, a citizen energy community generally follows technology-neutral policies, and thus, it incorporates both renewable and conventional sources of electrical energy. 2.1.2. Existing energy community projects A review of functional energy communities in Europe was performed to identify the characteristics of an LEC. The following keywords were used to search for energy community projects (Oct. 2020): ‘energy community’, ‘renewable energy community’, ‘citizen energy community’, ‘local energy market’, ‘electric energy community’, ‘microgrid’, ‘renewable energy market’, ‘local energy system’, ‘micro energy system’, ‘zero emission neighbourhood’, ‘smart neighbourhood’, and ‘micro markets’. This search resulted in approximately 200 projects, 60 of which were investigated in more detail in this study. For a project to be included in the review, it had to: (a) fit the definitions of citizen and/or renewable energy communities, (b) focus on electrical energy systems, and (c) possess sufficient information regarding the structure, stakeholders, technology, and motivation of the project. By applying these criteria, the initial number of 60 projects was reduced to the 25 projects that are listed in Table 2. The research findings on the structure, stakeholders, technology, and motivation of the 25 projects are detailed herein. Structure In terms of composition, an energy community can be distinguished by its physical and organisational structure. The physical structure involves the geographical area and location of the grid as well as the electrical grid topology. In contrast, an energy community’s organisational structure can be categorised into seven types, as described in the relevant literature [1]: energy cooperatives, limited partnerships, community trusts and foundations, housing associations, non-profit customer-owned enterprises, public–private partnerships and public Renewable and Sustainable Energy Reviews 170 (2022) 112651 3 A. Hernandez-Matheus et al. Table 1 Comparison of definitions of renewable and citizen energy community. Renewable energy community [8] Citizen energy community [9] (a) ‘‘which, in accordance with the applicable national law, is based on open and voluntary participation, is autonomous, and is effectively controlled by shareholders or members that are located in the proximity of the renewable energy projects that are owned and developed by that legal entity’’; (a) ‘‘is based on voluntary and open participation and is effectively controlled by members or shareholders that are natural persons, local authorities, including municipalities, or small enterprises’’; (b) ‘‘the shareholders or members of which are natural persons, SMEs [small and medium-sized enterprises] or local authorities, including municipalities’’; and (b) ‘‘has for its primary purpose to provide environmental, economic, or social community benefits to its members or shareholders or to the local areas where it operates rather than to generate financial profits’’; and (c) ‘‘the primary purpose of which is to provide environmental, economic or social community benefits for its shareholders or members or for the local areas where it operates, rather than financial profits’’ (c) ‘‘may engage in generation, including from renewable sources, distribution, supply, consumption, aggregation, energy storage, energy efficiency services or charging services for electric vehicles or provide other energy services to its members or shareholders’’ Table 2 Existing energy community projects. Project Country Motivation Participants BeauVent [1] Belgium Increase renewable energy production >5000 Courant d’Air [10] Belgium Provide renewable energy to consumers >2000 Ecopower [11] Belgium Increase renewable and local energy production 56,000 Svalin Energy Collective [12] Denmark Increase renewable and local energy production, reduce climate impact 20 households Cornwall Local Energy Market [13] England Test market-based flexibility provision, reduce climate impact 100 households, 100 businesses Larsmo Vindkraft Ab [14] Finland Increase renewable and local energy production, lower costs 200 Enercoop [15] France Increase renewable energy production, lower costs 92,000 Fermes de Figeac [16] France Increased income for members 321 Jühnde Bioenergiedorf [17] Germany Local solutions for solving climate change 660 Elektrizitätswerke Schönau [18] Germany Increase renewable energy production, energy democratisation 185,000 Sprakebüll Village [19] Germany Increase renewable energy production, self-sufficiency 247 Wildspoldsried microgrid [20] Germany Self-sufficiency with renewable energy, research on microgrids 2500 Aran Islands Energy Cooperative [14] Ireland Self-sufficiency with renewable energy, research on microgrids 100 stakeholders Erris Energy Community [21] Ireland Energy efficiency, increase renewable energy production, community aspect Unspecified Amelander Energie Coöperatie [22] Netherlands Self-sufficiency, increase renewable energy production 286 Brattøra [23] Norway Energy efficiency, positive energy block 3 office buildings Elnett21 [24] Norway Reduce fossil fuels in transport and enterprises, avoid grid congestion Port, airport, businesses Spoldzielnia Nasza Energia [1] Poland Energy independency, lower costs 300 Slupsk pilot [1] Poland Energy poverty, reduce air pollution 200 households Edinburgh Community Solar [25] Scotland Reduce climate change, energy poverty, energy security 540 Isle of Eigg [26] Scotland Increase renewable energy, lower costs 96 BRF Lyckansberg [27] Sweden Local renewable energy production, export surplus electricity 85 apartments Farmarenergi Eslöv [28] Sweden Reduce fossil fuels 9 farmers Simris Energy System [29] Sweden Increase renewable and local energy production, avoid congestion 140 households Quartierstrom [30] Switzerland Local market to balance power from renewable energy 37 households utility companies. A review of the 25 community projects revealed numerous organisational structures. Certain projects, such as Svalin [1] and the Isle of Eigg [31] are organised in collectives through citizen engagement with the social aspects of sharing at its core. Other projects were registered as companies owned by local citizens, such as Amelander [32] and Jühnde [1]. As displayed in Table 2, the number of members in these projects greatly vary, with three members in Brattøra [23], and 56,000 members in Ecopower [11]. Furthermore, a few of these projects have emerged from scientific research and are not initiated by citizen participants. In certain studies [32,33], researchers investigated the importance of social and organisational aspects in energy communities. Reportedly, factors such as a shared vision, the level of activity in the community, the type of organisation, and the organisation’s affiliations on local, regional, or national levels can significantly influence the success of the energy community. Stakeholders Stakeholders in an energy community can either serve as active participants forming the energy community or passive actors with invested interests in the project. Within the 25 aforementioned projects, the stakeholders comprise citizens, municipalities, technology providers, distribution system operators (DSOs), universities, local businesses, energy generation companies, and housing associations. In addition to the aforementioned examples, the relevant literature [34] lists research centres, consultancies, information and communications technology (ICT), telecommunication companies, utilities and engineering service providers, retail companies, transmission system operators (TSOs), industry organisations, real estate developers, energy service providers, public utilities, energy cooperatives, and transport solution companies as potential stakeholders. Generation, load, storage and flexible resources For the reviewed projects, the typical generation technologies in energy communities comprise photovoltaic (PV) panels, wind turbines, small-scale hydropower plants, and combined heat and power plants. Additionally, thermal energy systems for heat production are incorporated in most of the reviewed communities, typically through combined heat and power generation, or geothermal and solar heating. Energy storage for back-up or other grid services was realised through either diesel generators or battery-based energy storage systems. These generation and storage technologies can be observed either at the household level or as shared assets in the community. The various types of load sources in these 25 reviewed energy community projects were categorised as households, prosumers, office buildings, industry/farms, and public buildings. The yearly load demands of these categories differ on daily and seasonal scales. Typical flexible resources available within load categories comprise electric vehicles (EVs), heat pumps, and water boilers. Optimal control of these flexible resources and energy storage systems is crucial to minimise the energy costs of the community. Renewable and Sustainable Energy Reviews 170 (2022) 112651 4 A. Hernandez-Matheus et al. An energy management system will be required by the community to control its flexible resources, through which the community can ultimately decide the period and manner of energy utilisation, thereby lowering the overall energy costs. Motivation and benefits The energy community projects, reviewed in this study, address environmental concerns and the related goal of increasing the share of renewable energy, which comprise the core motivation for establishing an energy community. For example, both BeauVent [1] and Sprakebüll [19] aimed to achieve 100% renewable energy production in the community, whereas Svalin [12] aimed to consume renewable energy that was entirely produced locally. Similarly, the common motivation behind energy community projects involves further investment in sustainable energy infrastructure for the community [1]. Furthermore, several projects such as Amelander [22], Aran [14] and Wildpoldsried microgrid [20] have highlighted the importance of self-sufficiency. Such requirements for self-sufficiency may be motivated by economics, security of supply (especially relevant in energy communities, which are microgrids), or a demand for greater transparency regarding the origin of the consumed electricity. The economic incentives of communities typically lead to reduced wholesale market expenses owing to increased self-consumption of locally produced energy, revenue generation through feed-in of excess power generation, or a reduction in costs to the DSO owing to a lowered peak power consumption (caused by load shifting). Certain energy communities provide balancing and frequency control services to the TSO, such as the Cornwall Local Energy Market [13] and Wildpolsried microgrid [20]. 2.2. Definition of a local energy community As detailed in Section 2.1, the regulatory definitions and review of existing energy community projects facilitate the establishment of a definition of an LEC. This definition can be achieved by incorporating the five criteria that are fundamental to an energy community, which can be referred to as an LEC: 1. Locality: The community should possess a large proportion of local investment and ownership and be managed locally. A community is located within a defined geographical area and is typically connected at the distribution-grid level. 2. Energy sustainability: The community or its members fully or partially own the process of renewable energy generation, energy storage, EV chargers, or other relevant assets or infrastructure. These assets and infrastructure are shared by the community; from an energy system perspective, they are established at a single customer location. 3. Community engagement: Most of the participants are active members of the community, i.e., they are invested in the energyrelated assets and provide flexible demand options. The main objective of the community is not profit-oriented; however, it aims to provide environmental, economic, or social benefits for its members/shareholders and/or the local area where it operates. The community participants may be individuals, small- and medium-sized enterprises, or local authorities, including municipalities. 4. ICT: The community possesses ICT infrastructure of varying degrees. Typically, this includes smart meters and communication, control, and energy management systems. Such infrastructure can enable the flexible operation and optimisation of the local system and facilitate interaction with national power systems in the form of transmission grids and wholesale electricity markets. 5. Transactions: The community allows for energy-related financial transactions amongst its members. This feature is generally implemented in local energy markets; however, such a feature is not mandatory. The transactions conducted not only consist of local transactions but also include transactions between the community and the national power system, for example, via wholesale electricity markets. Criteria 1, 2, and 3 are closely related to the definitions of citizen and renewable energy communities. Criterion 4 indicates that an energy community must exercise some degree of ICT technology for the control of assets, communication amongst its members, and data collection. According to Criterion 5, a mechanism is required to share the energyrelated costs and benefits amongst the members in the community. Table 3 depicts the relationship between the criteria defined for the applications, which are further detailed in Section 5. To summarise this definition, an LEC is illustrated in Fig. 1 as a part of the larger power system. 3. Associated literature reviews On the basis of the definition of an LEC provided in Section 2.2, a recent body of literature reviews associated with the topic has been identified, as listed in Table 4. The associated literature reviews were selected according to their relevance to the topic of LECs by considering the commonalities in the fundamental criteria established in the previous section. The exception to this has been reported in several studies [50–52], which possesses no direct relation but relates tangentially to locality and ICT infrastructure. The associated methods are explored in detail in the following section. A range of literature reviews specialise in topics related to LEC; however, they do not specifically focus on local applications. Within the topic of forecasting, in a review [35] recurrent neural network models focusing on the specific problem of solar power forecasting were analysed with data from the South Korean power grid. Furthermore, an overview of deep learning in renewable electricity forecasting has been reported [37]. A review [39] specifically focused on time-series drift in terms of flexibility in power system flexibility, whereas another review [40] explored load forecasting from short to long term periods. Most of reviews of energy management systems highlight the topic of locality, except for the review [48] which presents a general view on reinforcement learning and its application in problems concerning power system control, and excluding the review [42] that explores energy storage and EVs. With regard to the protection, stability and quality of power systems, none of the reviews consider locality. In a review [50], methods such as support vector machines, neural networks and genetic algorithms were analysed in the context of fault detection. Moreover, deep learning has been analysed in the context of power quality [51]. Furthermore, the review [52] explores applications of machine learning in reliability assessment and control (specifically on the topics of security assessment, emergency control, preventive control, error measurement and power flow predictions). Most reviews of machine learning in smart grids do not consider locality. The emerging importance of machine learning and autonomous control in power systems has been reported [53]; although the review was not specifically focused on decentralised solutions, the reported topics were strongly related to such solutions. Furthermore, machine learning in smart grids has been analysed with a focus on data and data security [54]. The relevance of artificial intelligence to sustainable energy systems has been investigated in a general context [56]. In a review [55] machine learning in power systems has been investigated with a focus on topics such as forecasting, failure analysis, demand side management, and cyber security. Additionally, a review of the last decade of machine learning in power systems has been established [4]. The remaining related literature reviews focus on the subcategories of the field of machine learning. Reinforcement learning is a core topic in studies that focus on control aspects. The Markov decision process, i.e., the heating and storage of heat in water boilers, has been explored, and Q-learning has been identified as the state-of-the-art for dealing with control in such decision processes [43]. Researches [44] Renewable and Sustainable Energy Reviews 170 (2022) 112651 5 A. Hernandez-Matheus et al. Table 3 Value matrix criteria—applications. Application Locality Energy sustainability Community ICT Transactions Forecasting Generates information for short-term planning of the resources in the LEC The individual and community assets are optimally managed by having information of future DER and related asset behaviour (such as storage) Individuals can better coordinate with better prediction on their demand and supply A condition for data security in forecasting systems Energy and price forecasting provides operational inputs allowing the LEC to conduct an optimised economic dispatch Storage optimisation Enables localised storage as a grid asset, increases self-consumption of local renewable resources in the LEC Storage assets are coordinated with other assets in the community and investments can be shared Automated control of the storage system and associated information streams Local assets interact with the larger power grid via wholesale markets, e.g. in form of virtual power plants Demand response Decentralised demand response becomes a feasible asset in the power system Time-flexible demand can increase the consumption of intermittent renewable energy in the community Demand response can be aggregated and coordinated with other community members Local assets interact with the larger power grid via wholesale markets. e.g. as virtual power plants Energy management system Decentralised coordination of resources More optimal coordination provides more efficient utilisation of renewable energy and lowers emissions Provides the sense of common welfare and a central coordination point within an LEC Data storage and monitoring systems constitute the core of an EMS Power quality, stability and security Practices that secure proper functioning and handling of the equipment owned in the LEC Towards energy sustainability goals, energy generated and dispatched from LEC has to comply with the quality standards of power grids Akin to centralised power systems, in decentralised systems such as LEC, the grid remains a shared asset Grid data collection, maintenance and security - Energy transactions Transactions are moved to the local level, consumers and prosumers financially interact with each other within an LEC Local markets trade mainly local, renewable generation Transactions within a community lead to higher level of self-consumption LEC members are able to make better informed decisions about the sourcing of their energy supply; because to information sensitivity, transactions must also be secure Local markets are integrated into wholesale markets and also have to provide proper supply/demand on balancing and regulating markets Fig. 1. Visualisation of a local energy community in the larger power system. The local energy community consists of two levels: the community and the individual level. The individual level consists of the participants in the community, such as residential consumers, prosumers, and enterprises. The participants own individual assets such as EVs, PV panels and batteries. Moreover, the ICT infrastructure, such as smart meters and energy management systems, are also incorporated into this system. The community level consists of shared assets, such as community-owned PV panels, wind turbines, batteries and charging stations for EVs. approached the topic from the perspective of building management and discussed the real-world challenges involved in the implementation of reinforcement-learning frameworks. Similarly, control problems in buildings have been addressed through reinforcement learning, focusing on demand response control [45] and the latter focusing on its practical applications [46]. Another literature review focusing on the Renewable and Sustainable Energy Reviews 170 (2022) 112651 6 A. Hernandez-Matheus et al. Table 4 Literature reviews on machine learning applied on associated topics. Source Year Topic Locality Energy sustainability Community engagement ICT Transactions Forecasting [35] 2019 PV generation forecasting x ✓x x x [36] 2019 PV generation forecasting ✓ ✓ x x x [37] 2019 Renewable energy forecasting x ✓x x x [38] 2019 Load prediction with smart meter data ✓ ✓ x✓x [39] 2020 Forecasting of flexible resources x ✓x x x [40] 2020 Load forecasting x ✓x x x Energy management system [41] 2020 Battery state estimation ✓ ✓ x✓x [42] 2020 Battery control methods x x ✓x✓ [43] 2018 Water heater control ✓x✓x x [44] 2019 Energy management systems of buildings ✓ ✓ ✓ x x [45] 2021 Energy management of appliances in buildings ✓x✓x x [46] 2019 Demand response control ✓x✓x x [47] 2020 Demand response ✓x✓x x [48] 2019 General control problems in power systems x x ✓x✓ [49] 2020 EV flexibility ✓x✓x x Power system protection, stability and quality [50] 2017 Fault detection ∼x x ∼x [51] 2019 Power quality analysis x x x ∼x [52] 2020 Reliability assessment and control x x x ∼x Machine learning in smart grids [53] 2019 Role of machine learning in power systems x x x ✓x [54] 2019 Machine learning in smart grids x x x ✓x [55] 2020 Machine learning in smart grids x ✓ ✓ ✓ x [4] 2020 Deep learning in smart grids x ✓x✓ ✓ [56] 2020 Sustainable development x ✓x x x [57] 2020 Distributed smart grids ✓x✓x x [*] – Local energy communities ✓ ✓ ✓ ✓ ✓ * this paper, ✓related, ∼tangentially related. subcategory of supervised learning has been reported [41], focusing on methods dealing with battery state estimations, namely Markov processbased methodologies such as Kalman filters. Compared to these sources, literature reviews focusing on local applications and considering multiple subcategories of machine learning focus on specific problems. A review of applications, utilising smart meter data, such as load forecasting and related issues, including screening for energy theft and demand response forecasting, has been reported in the literature [38]. Additionally, solar energy predictions in microgrids have been surveyed [36], and the demand response and associated methods for operation, prediction, and segmentation have been highlighted [47]. Finally, a method for charging demand prediction of electric vehicles have been reported in literature [49]. In terms of the existing literature, a prior research has been reported, which is most relevant to this study [57]. However, the prior research focuses on single assets, especially energy management systems, whereas the present study focuses on energy communities, especially LECs, as an integrative unit. Although these approaches overlap, the research presented herein will dive deeper into specific applications such as agent-based coordination and classification from a communal perspective. 4. Machine learning methods This section provides a short introduction to machine learning and its main categories as well as the main topics related to LECs, which were revealed in literature review performed in Section 3. Popularised by a study [58], machine learning algorithms are traditionally classified into three main categories: (a) Supervised Learning, (b) Unsupervised Learning, and (c) Reinforcement Learning. The three categories, with their respective associated algorithms, are illustrate in Fig. 2. The essence of these classifications lies in the interaction of the algorithms with the data and environment. A comprehensive review of these methods and associated concepts have been reported in [59]. Supervised Learning algorithms are supplied with knowledge pertaining to the data in the form of so-called labels and are used to predict new and unknown data labels. This process can occur in the form of tasks such as classification, where labels represent categories, and regression tasks where the labels represent the values to be predicted. In this study, the regression tasks are referred from traditional linear regression, advanced models such as Lasso regression, or Ridge regression to models such as support vector machines, a method that can be fit on nonlinear data sets. In the context of LECs, regression methods are primarily used to predict and forecast of uncertain parameters. This forecast applies to both the demand side (e.g. household loads or utilisation of devices) and the supply side (e.g. available PV capacity) [60,61]. However, classification problems rely on prediction tasks for categorical or qualitative outputs [59]. Consequently, classification methods are generally used in scenarios wherein the problem involves the detection of specific cases in datasets on the basis of historical examples. The main applications of such methods related to LECs comprise fault detection and error classification [62]. Finally, probabilistic tasks refer to methods that consider uncertainty in the data not only to optimise the expected value but also to infer the distribution of such uncertainty. A simple example is provided by the probabilistic form of regression, such as Bayesian regression. Applications of probabilistic methods in LECs include the fitting of stochastic processes or determination of the parameters of distributions for renewable energy installations, household loads, or usage patterns of electric vehicles and electric devices. Deep learning, commonly referred to as a neural network, can perform any of the aforementioned tasks. These methods employ function approximations consisting of stacks of differentiable linear regression ‘layers’ and nonlinear ‘activation functions’. Hence, neural networks are built with different configurations of layers to solve the problem and handle the nonlinearities of such problems. Such models are widely used in LECs, including neural networks for forecasts [63] and predictions of deep learning models for optimal control [4,64]. A more in-depth discussion on deep learning topics has been reported in [65]. Renewable and Sustainable Energy Reviews 170 (2022) 112651 7 A. Hernandez-Matheus et al. Fig. 2. Machine learning methods and algorithms. In contrast to supervised learning, unsupervised learning aims to describe associations and patterns between unlabelled input data [59]. Clustering techniques aim to find commonalities in data sets and classify the closest data points as clusters. In the context of LECs, clustering methods are primarily found in applications for load profiling and segmentation. The last category, reinforcement learning (RL), from the other two categories. It not only passively observes and labels the data but also exerts active control on a given system. A common textbook source for RL algorithm is provided [66]. However, in the traditional literature on electrical engineering, these RL algorithms have also been referred to in the context of optimal control under the name of ‘approximate dynamic programming’. Further background information on this topic is currently available [67]. 5. Applications in the operation of local energy communities The literature review presented in Table 4 demonstrates the range of potential applications of machine learning within microgrids, smart grids and other energy communities. However, considering the criteria in the definition of an LEC, as depicted in Section 2, applications such as forecasting, energy management system, power system protection, stability, quality, and optimisation and energy transactions have been selected as a result of a categorisation of the discovered literature associated with the aforementioned topics. The following section presents the analyses and further classification of the studies and models targeted specifically at the aforementioned applications related to LECs. 5.1. Forecasting Forecasting is the process of predicting a variable in the future by analysing historical data trends. Demand and generation forecasting are of great importance to the system operators of electrical grids. The frequency of occurrence of the algorithms that were used in the reviewed studies for each forecast application is illustrated in Fig. 3. Forecasting studies are commonly classified to their time horizon prediction: short-term, medium-term, and long-term [57]. However, certain studies approach the problem on a very short-term horizon [61, 68]. The forecasting interval depends on the purpose on the forecast. For daily operation tasks, very short-term and short-term are the Table 5 Forecast time horizons. Forecast horizon Time interval Very short-term 1 s to less than 1 h Short-term Few minutes to few days Medium-term Few days to few months Long-term Months, quarters, years required time horizon, whereas for grid planning and investment evaluation, a long-term horizon is preferred [40]. Table 6 shows the machine learning algorithms in the literature review for different forecast tasks classified according to time horizons listed in Table 5. 5.1.1. Demand forecasting The literature on demand forecasting represents the largest share of the recent literature on energy forecasting. This is because of the increased uncertainty in the operation owing to the addition of new actors to the energy system, such as prosumers or new assets, which can act as flexible loads and shift or reduce their consumption during specific periods [48]. An accurate prediction of demand helps to improve the operation of an LEC [97,98]. For LECs with controllable loads, several control strategies rely on an accurate forecasting model [99]. Demand forecasting can be performed at individual, community, or asset level facilitated by the data gathering ability of smart meters and ICT infrastructure. In terms of the asset level, machine learning regression models such as K-nearest neighbours (KNN), decision trees and neural networks (NNs) have been explored to accurately predict the consumption of two machine tools in a factory in a very short-term horizon [68]. A combination of an autoregressive integrated moving average (ARIMA) model with a nonlinear support vector machine (SVM) has been used to predict the electrical consumption of an air conditioner by employing the data retrieved from smart meters [81]. Similarly, [80] compared linear models, linear and nonlinear SVMs, and NNs to predict annual heating and cooling loads in residential spaces in a long-term prediction task; the optimal results were obtained using nonlinear SVMs. At individual level, researches [73] approached the short-term forecast of the energy consumption of three households in a nanogrid via smart meter data by reviewing several supervised learning algorithms. Refs. [74,76] have discussed on the high volatility and uncertainty of residential load profiles; Long short-term memory neural networks Renewable and Sustainable Energy Reviews 170 (2022) 112651 8 A. Hernandez-Matheus et al. Fig. 3. Machine learning techniques used for forecasting in literature. Table 6 Machine learning (ML) techniques for forecasting. Forecast topic Task ML Algorithm Forecast horizon Year Source Demand forecasting Load curve SVM Short term, medium term 2021 [69] Hybrid models Short term, long term 2020 [70] CNN Short term 2019 [71] LSTM Short term 2020 [72] Households Various Short term 2020 [73] Linear models Short term 2018 [74] Various medium term 2020 [75] LSTM, SVM Short term 2019 [76] LSTM Short term 2018 [77] Households and SME Markov Model Short term 2019 [78] Appliances LSTM Short term 2020 [79] Residential space heating and cooling loads CNN Long term 2020 [80] Machine tools SVM, NN Very short term 2020 [68] Power demand for different facilities LSTM Short term, long term 2020 [63] AC energy consumption LSTM Short term 2019 [81] Rural microgrid NN Short term 2020 [82] Renewable energy forecasting PV generation LSTM Short term 2019, 2020 [83,84] Various Short term 2019 [85] Various Various 2019 [61] PV generation, wind generation and demand NARX NN Short term 2019 [86] Wind forecasting Various Various 2020 [87] Flexibility forecasting Demand side flexibility LSTM - MILP Short term 2021 [88] Boosted decision trees Short term, medium term 2020 [89] GLME Medium term 2019 [90] Decision trees – 2021 [91] EV charging demand prediction Boosted decision trees – 2020 [49] EV charging navigation Q-learning – 2020 [92] Price forecasting Price forecasting Turkish market Various Short term 2018 [93] Price forecasting Iberian market NN Short term 2018 [94] Price forecasting EPEX Various Short term, long term 2019 [95] Various Price, generation, demand Various Short term 2021 [96] (LSTMS) were used to obtain short-term household forecasts, yielding minimal prediction errors. At community level, load forecasts are usually performed by considering aggregated load. For example, different algorithms have been used to forecast one day-ahead energy consumption in a residential building [77]. The authors first reviewed several single algorithms and subsequently combined these algorithms with an optimisation technique, thereby achieving improved results with the latter technique. Ref. [63] forecasted short-term and long-term energy consumption of different buildings, ranging from a residential to a factory and hospital, and the challenges of each profile have been reported. The authors compare mixed-data sampling method with LSTMs and a combination of both methods, resulting in a more accurate result. In contrast to deterministic methods, probabilistic methods have been applied in certain studies. These methods extend the capabilities of the deterministic model by quantifying the uncertainty factors in the load forecasting task. As exemplified in [71], the authors trained recurrent neural networks (RNNs) using a probabilistic objective function to forecast the day-ahead load consumption. Probabilistic output prediction provides information on risk and related scenarios for decision making in the operation planning of the energy system [78]. Moreover, a semi-hidden Markov model have been developed to predict short-term consumption of home appliances [79]. 5.1.2. Renewable generation forecasting Most LECs will have renewable energy sources to fulfil their energy needs and sustainability goals. Accordingly, the nature of these energy generation sources results in a significant level of uncertainty in the energy supply [37,100]. An example has been reported [101], wherein multiple methods were reviewed, including nonlinear autoregressive exogenous neural networks (NARX NN), Gaussian process regression, and SVM, to forecast the behaviour of wind generation, PV generation, Renewable and Sustainable Energy Reviews 170 (2022) 112651 9 A. Hernandez-Matheus et al. and demand for households. The authors assessed the inputs needed for each predictive task and highlighted the NARX NN as a robust model for wind and PV generation by conducting a sensitivity analysis. As reported in the literature [96], the results for wind generation forecasts were improved through the incorporation of exogenous information when comparing deterministic and probabilistic methods. Similarly, NARX NNs have been used [102,103] for wind and PV generation. As mentioned in Section 2.1, PV generation is one of the most popular technologies for the generation of renewable energy in households and communities. Therefore, a number of studies have focused on this particular application. For instance, the statistical and machine learning methods for PV generation forecast have been comparatively analysed [61]. Finally, the authors compared a hybrid combination of two methods and an optimisation theorem, concluding hybrid methods increase the forecasting accuracy by adding benefits of individual methods. The performances of several machine learning algorithms have been analysed to predict the PV generation for a power plant [85]; the importance of input data, such as weather, for the prediction performance has been analysed to predict of PV generation for a power plant. The optimal results were obtained using random forest. RNNs have been extensively explored in the literature for forecast tasks concerning PV generation; for example, LSTMs have been implemented to predict the output power of different PV generation plants for a short-term time horizon [83,84]. 5.1.3. Flexibility forecasting From a prosumer’s perspective, flexibility can be defined as the ability to modulate generation/consumption behaviour via an external signal, such as a change in the energy price [104]. Flexibility is a service that can be provided within the LEC at both household and community levels (refer to Fig. 1). Flexibility forecasting is based on load forecasting, considering the available flexibility sources [90]. Accurate flexibility estimation allows the LEC and its participants to generate revenue by selling flexibility to a system operator, such as Cornwall Local Energy Market [13]. In accordance with the classification reported in [105], flexible assets can be classified as demand side, supply side, and storage assets. This section focuses on the demand side flexibility and storage. For flexibility estimation, [88] the economic optimisation of an energy management system has been attempted in an urban microgrid, considering the flexibility of ancillary services. The load consumption forecast was performed using LSTM. Furthermore, mixed integer linear programming (MILP) was used to optimise the energy dispatch in the day-ahead operation of the microgrid with three different types of loads: building, smart homes with and without available PV capacity, and differently clustered loads. In another study [89], the authors forecast the loads’ total consumption and flexibility using boosted trees for both day-ahead and week-ahead time horizons in a commercial building. In a study [90], the flexibility was calculated for a single household for one month using generalised linear mixed-effect models (GLMM). The present study also analyses the flexibility at the household asset level. With the novel vehicle-to-grid (V2G) technology, EV charging stations in the grid serve as a flexible asset. V2G can operate as an available energy storage device, thereby acting as a flexibility source [106]. In addition, they can be considered as a mobile energy storage system [105]. Therefore, they are also subject of study for forecasting flexibility calculations. To this end [49], prediction methods for the EV charging demand during charging sessions have been studied to optimise the management of the electric grid. Models such as linear regression, boosted decision trees, random forest, and SVM were used to predict the charging demand of EVs for flexibility predictions. Ref. [92] proposes a storage optimisation problem for EVs incorporating uncertainty caused by traffic solved by a RL model-free Q-learning algorithm. The use of decision trees has been evaluated for flexibility-based operational planning dispatch in a microgrid system connected to the grid, with storage, renewable generation, critical loads, and an industrial controller [91]. The authors comment on the feasibility of implementing decision tree-based rule programming in a PLC-based controller and highlight its interpretability in the dispatch rules compared to other state-of-the-art alternatives such as NNs. 5.1.4. Electricity price forecasting Electricity price forecasting is an application for both community and peer-to-peer market-level configurations. A forecast of the energy price at a specific time in the future provides valuable information for handling load consumption and flexibility more efficiently [107]. Moreover, price forecasting helps to create optimised programs to efficiently dispatch the energy within the LEC, by supporting efficient resource scheduling decisions [57]. In this section, although most of the studies focus on centralised energy markets, they are highly relevant for LECs. Most of the studies on LECs focus on the day-ahead electricity price forecasting. The price forecasting has been analysed in the Turkish day-ahead market using an RNN, and the method was compared with several other NN architectures [93]. The optimal results were obtained using the gated recurrent unit configuration of RNN. The authors highlight the capabilities of this algorithm to capture spikes and volatility. Similarly, scholars [94] implemented a regression technique using NN to predict day-ahead prices in the Iberian electricity market. Additionally, researches [95] approached electricity price forecasting for both day-ahead and a four-week time horizon in EPEX1in Germany/Austria. Reportedly, amongst the algorithms tested, the optimal results were achieved using NNs. 5.2. Energy management systems An optimised energy management system allows efficient energy consumption scheduling through the coordination of the assets in the system, such as PV generation, storage, EVs, and flexible loads via demand response programs. As reported in the existing literature [104, 108], an energy management system can be used to process price signals and perform cost-efficient dispatch within a wholesale market framework. Furthermore, the relevant literature indicates that datadriven algorithms support automatic optimisation of energy management systems at both individual and community levels. The distribution of machine learning techniques in the reviewed literature for energy management system is displayed Fig. 4. 5.2.1. Energy management system and control The majority of the studies focus on the energy management optimisation by data-driven algorithms. As reported in [109], an energy management system has been developed using stochastic processes for an islanded microgrid. Additionally, researches in [110] exposed a method which optimises the power exchanged with the utility through a probabilistic approach using a Gaussian process model and model predictive control for interconnected microgrids. Supervised learning algorithm algorithms were used by researches [111], who presented a multi-agent day-ahead energy management system of a microgrid incorporating various methods from machine learning and operations research. Specifically, it demonstrates the incorporation of forecasting via RNNs and convolutional neural networks (CNNs) into distributed optimisation via the alternate direction method of multipliers. Furthermore, a framework has been introduced to optimise the cost of networked microgrids featuring wind turbine generation, EV charging, and battery storage [112]. The output power of the wind turbines is predicted via SVM and a battery optimisation algorithm is used to find 1European Power Exchange SE is an electric power exchange operating in Austria, Belgium, Denmark, Finland, France, Germany, Great Britain, Luxembourg, the Netherlands, Norway, Sweden and Switzerland. Renewable and Sustainable Energy Reviews 170 (2022) 112651 16 A. Hernandez-Matheus et al. [23] +CityxChange. Trondheim. 2021, https://cityxchange.eu/our-cities/trondheim/. [Accessed 21 July 2021]. [24] Elnett21. About elnett21. 2021, https://www.elnett21.no/om-elnett21. [Accessed 22 July 2021]. [25] Edinburgh Community Solar Co-operative. How it works. 2021, https:// www.edinburghsolar.coop/projects/how-the-co-op-works/. [Accessed 26 March 2021]. [26] The Isle of Eigg. Eigg electric. 2021, http://isleofeigg.org/eigg-electric/. [Accessed 22 July 2021]. [27] BRF Lyckansberg Växjö. Solceller. 2021, https://www.hsb.se/sydost/brf/ lyckansberg/miljo/solceller/. [Accessed 22 July 2021]. [28] Lantbrukarnas Riksförbund. Mer om Farmarenergi i Eslöv AB. 2021, https://www.lrf.se/foretagande/forskning-och-framtid/innovation-och- inspiration/de-tog-steget/framtidsforetag/farmarenergi-i-eslov-ab-skane/merom-farmarenergi-i-eslov-ab/. [Accessed 22 July 2021]. [29] Interflex. The Swedish demonstrator - Simris. 2021, https://interflex-h2020. com/interflex/project-demonstrators/sweden-simris/. [Accessed 22 July 2021]. [30] Ableitner L, Bättig I, Beglinger N, Brenzikofer A, Carle G, Dürr C, et al. Community energy network with prosumer focus. Tech. rep, Swiss Federal Office of Energy SFOE; 2020. [31] Chmiel Z, Bhattacharyya SC. Analysis of off-grid electricity system at isle of Eigg (Scotland): Lessons for developing countries. Renew Energy 2015;81:578–88. [32] Van Der Schoor T, Van Lente H, Scholtens B, Peine A. Challenging obduracy: How local communities transform the energy system. Energy Res Soc Sci 2016;13:94–105. [33] Van Der Schoor T, Scholtens B. Power to the people: Local community initiatives and the transition to sustainable energy. Renew Sustain Energy Rev 2015;43:666–75. [34] Marinopoulos A, Vasiljevska J, Mengolini A. Local energy communities: An insight from European smart grid projects. In: CIRED workshop - Ljubljana. 2018, p. 7–8. [35] Aslam M, Lee JM, Kim HS, Lee SJ, Hong S. Deep learning models for long-term solar radiation forecasting considering microgrid installation: A comparative study. Energies 2019;13(1). [36] Aslam S, Herodotou H, Ayub N, Mohsin SM. Deep learning based techniques to enhance the performance of microgrids: A review. In: Proceedings - 2019 international conference on frontiers of information technology. 2019, p. 116–21. [37] Wang H, Lei Z, Zhang X, Zhou B, Peng J. A review of deep learning for renewable energy forecasting. Energy Convers Manag 2019;198. [38] Wang Y, Chen Q, Hong T, Kang C. Review of smart meter data analytics: Applications, methodologies, and challenges. IEEE Trans Smart Grid 2019;10(3):3125–48. [39] Hammami Z, Sayed-Mouchaweh M, Mouelhi W, Ben Said L. Neural networks for online learning of non-stationary data streams: A review and application for smart grids flexibility improvement. Artif Intell Rev 2020;53:6111–54. [40] Ahmad T, Zhang H, Yan B. A review on renewable energy and electricity requirement forecasting models for smart grid and buildings. Sustainable Cities Soc 2020;55(October 2019):102052. [41] Wang Y, Tian J, Sun Z, Wang L, Xu R, Li M, et al. A comprehensive review of battery modeling and state estimation approaches for advanced battery management systems. Renew Sustain Energy Rev 2020;131. [42] Machlev R, Zargari N, Chowdhury NR, Belikov J, Levron Y. A review of optimal control methods for energy storage systems - energy trading, energy balancing and electric vehicles. J Energy Storage 2020;32(August):101787. [43] Ruelens F, Claessens BJ, Quaiyum S, De Schutter B, Babuška R, Belmans R. Reinforcement learning applied to an electric water heater: From theory to practice. IEEE Trans Smart Grid 2018;9(4):3792–800. [44] Mason K, Grijalva S. A review of reinforcement learning for autonomous building energy management. Comput Electr Eng 2019;78:300–12. [45] Kathirgamanathan A, De Rosa M, Mangina E, Finn DP. Data-driven predictive control for unlocking building energy flexibility: A review. Renew Sustain Energy Rev 2021;135(August 2020):110120. [46] Vázquez-Canteli JR, Nagy Z. Reinforcement learning for demand response: A review of algorithms and modeling techniques. Appl Energy 2019;235(November 2018):1072–89. [47] Antonopoulos I, Robu V, Couraud B, Kirli D, Norbu S, Kiprakis A, et al. Artificial intelligence and machine learning approaches to energy demand-side response: A systematic review. Renew Sustain Energy Rev 2020;130. [48] Zhang Z, Zhang D, Qiu RC. Deep reinforcement learning for power system: An overview. CSEE J Power Energy Syst 2019. [49] Almaghrebi A, Aljuheshi F, Rafaie M, James K, Alahmad M. Data-driven charging demand prediction at public charging stations using supervised machine learning regression methods. Energies 2020;13(6). [50] Gururajapathy SS, Mokhlis H, Illias HA. Fault location and detection techniques in power distribution systems with distributed generation: A review. Renew Sustain Energy Rev 2017;74:949–58. [51] Mishra M. Power quality disturbance detection and classification using signal processing and soft computing techniques: A comprehensive review. Int Trans Electr Energy Syst 2019;29(8). [52] Duchesne L, Karangelos E, Wehenkel L. Recent developments in machine learning for energy systems reliability management. Proc IEEE 2020;108(9):1656–76. [53] Prostejovsky AM, Brosinsky C, Heussen K, Westermann D, Kreusel J, Marinelli M. The future role of human operators in highly automated electric power systems. Electr Power Syst Res 2019;175. [54] Hossain E, Khan I, Un-Noor F, Sikander SS, Sunny MSH. Application of big data and machine learning in smart grid, and associated security concerns: A review. IEEE Access 2019;7:13960–88. [55] Ibrahim MS, Dong W, Yang Q. Machine learning driven smart electric power systems: Current trends and new perspectives. Appl Energy 2020;272(May):115237. [56] Vinuesa R, Azizpour H, Leite I, Balaam M, Dignum V, Domisch S, et al. The role of artificial intelligence in achieving the sustainable development goals. Nat Commun 2020;11(1). [57] Ali SS, Choi BJ. State-of-the-art artificial intelligence techniques for distributed smart grids: A review. Electronics (Switzerland) 2020;9(6):1–28. [58] Bishop CM. Pattern recognition and machine learning. Springer; 2006. [59] Hastie T, Tibshirani R, Friedman J. The elements of statistical learning: Data mining, inference, and prediction. Springer Science & Business Media; 2009. [60] Huang B, Wang J. Deep reinforcement learning-based capacity scheduling for PV-battery storage system. IEEE Trans Smart Grid 2020;12(3):2272–83. [61] Akhter MN, Mekhilef S, Mokhlis H, Shah NM. Review on forecasting of photovoltaic power generation based on machine learning and metaheuristic techniques. IET Renew Power Gener 2019;13(7):1009–23. [62] Mishra M, Rout PK. Detection and classification of micro-grid faults based on HHT and machine learning techniques. IET Gener, Transm Distrib 2017;12(2):388–97. [63] Choi E, Cho S, Kim DK. Power demand forecasting using long short-term memory (LSTM) deep-learning model for monitoring energy sustainability. Sustainability (Switzerland) 2020;12(3). [64] Löschenbrand M. Modeling competition of virtual power plants via deep learning. Energy 2021;214. [65] Goodfellow I, Bengio Y, Courville A. Deep learning, Vol. 1. 2nd ed.. MIT Press; 2016. [66] Sutton RS, Barto AG. Reinforcement learning: An introduction. MIT Press; 2018. [67] Bersekas DP. Reinforcement learning and optimal control. Athena Scientific; 2019. [68] Dietrich B, Walther J, Weigold M, Abele E. Machine learning based very short term load forecasting of machine tools. Appl Energy 2020;276(February):115440. [69] Jeyaraj PR, Nadar ERS. Computer-assisted demand-side energy management in residential smart grid employing novel pooling deep learning algorithm. Int J Energy Res 2021;(December 2020):1–13. [70] Solyali D. A comparative analysis of machine learning approaches for short- /long-term electricity load forecasting in Cyprus. Sustainability (Switzerland) 2020;12(9). [71] Zhang W, Quan H, Srinivasan D. An improved quantile regression neural network for probabilistic load forecasting. IEEE Trans Smart Grid 2019;10(4):4425–34. [72] Huang Q, Li J, Zhu M. An improved convolutional neural network with load range discretization for probabilistic load forecasting. Energy 2020;203:117902. [73] Caliano M, Buonanno A, Graditi G, Pontecorvo A, Sforza G, Valenti M. Consumption based-only load forecasting for individual households in nanogrids: A case study. In: 2020 AEIT international annual conference. IEEE; 2020, p. 1–6. [74] Shi H, Xu M, Li R. Deep learning for household load forecasting-a novel pooling deep RNN. IEEE Trans Smart Grid 2018;9(5):5271–80. [75] Aurangzeb K, Alhussein M. Deep learning framework for short term power load forecasting, a case study of individual household energy customer. In: 2019 International conference on advances in the emerging computing technologies. 2020. [76] Kong W, Dong ZY, Jia Y, Hill DJ, Xu Y, Zhang Y. Short-term residential load forecasting based on LSTM recurrent neural network. IEEE Trans Smart Grid 2019;10(1):841–51. [77] Chou JS, Tran DS. [DUPLICATE] Forecasting energy consumption time series using machine learning techniques based on usage patterns of residential householders. Energy 2018;165:709–26. [78] Yang Y, Hong W, Li S. Deep ensemble learning based probabilistic load forecasting in smart grids. Energy 2019;189. [79] Ji Y, Buechler E, Rajagopal R. Data-driven load modeling and forecasting of residential appliances. IEEE Trans Smart Grid 2020;11(3):2652–61. [80] Li X, Yao R. A machine-learning-based approach to predict residential annual space heating and cooling loads considering occupant behaviour. Energy 2020;212. [81] Chou JS, Hsu SC, Ngo NT, Lin CW, Tsui CC. Hybrid machine learning system to forecast electricity consumption of smart grid-based air conditioners. IEEE Syst J 2019;13(3):3120–8. [82] Moradzadeh A, Zakeri S, Shoaran M, Mohammadi-Ivatloo B, Mohammadi F. Short-term load forecasting of microgrid via hybrid support vector regression and long short-term memory algorithms. Sustainability (Switzerland) 2020;12(17). Renewable and Sustainable Energy Reviews 170 (2022) 112651 17 A. Hernandez-Matheus et al. [83] Rosato A, Member S, Panella M, Member S, Araneo R, Member S, et al. A neural network based prediction system of distributed generation for the management of microgrids. IEEE Trans Ind Appl 2019;55(6):7092–102. [84] Yu D, Choi W, Kim M, Liu L. Forecasting day-ahead hourly photovoltaic power generation using convolutional self-attention based long short-term memory. Energies 2020;13(15). [85] Kim SG, Jung JY, Sim MK. A two-step approach to solar power generation prediction based on weather data using machine learning. Sustainability (Switzerland) 2019;11(5). [86] Sharifzadeh M, Sikinioti-Lock A, Shah N. Machine-learning methods for integrated renewable power generation: A comparative study of artificial neural networks, support vector regression, and Gaussian process regression. Renew Sustain Energy Rev 2019;108(April):513–38. [87] Sim MK, Jung JY. A short review on predictions for wind power generation – its limitation and future directions. ICIC Express Lett, Part B: Appl 2020;11(10):995–1000. [88] Arkhangelski J, Mahamadou AT, Lefebvre G. Day-ahead optimal power flow for efficient energy management of urban microgrid. IEEE Trans Ind Appl 2021;9994(c). [89] Krishnadas G, Kiprakis A. A machine learning pipeline for demand response capacity scheduling. Energies 2020;13(7):1–25. [90] Ahmadiahangar R, Häring T, Rosin A, Korõtko T, Martins J. Residential load forecasting for flexibility prediction using machine learning-based regression model. In: Proceedings - 2019 IEEE international conference on environment and electrical engineering and 2019 IEEE industrial and commercial power systems Europe. 2019. [91] Huo Y, Bouffard F, Joós G. Decision tree-based optimization for flexibility management for sustainable energy microgrids. Appl Energy 2021;290(February):116772. [92] Qian T, Shao C, Wang X, Shahidehpour M. Deep reinforcement learning for EV charging navigation by coordinating smart grid and intelligent transportation system. IEEE Trans Smart Grid 2020;11(2):1714–23. [93] Ugurlu U, Oksuz I, Tas O. Electricity price forecasting using recurrent neural networks. Energies 2018;11(5):1–23. [94] Chinnathambi RA, Plathottam SJ, Hossen T, Nair AS, Ranganathan P. Deep neural networks (DNN) for day-ahead electricity price markets. In: 2018 IEEE electrical power and energy conference. IEEE; 2018. [95] Windler T, Busse J, Rieck J. One month-ahead electricity price forecasting in the context of production planning. J Cleaner Prod 2019;238:117910. [96] Mashlakov A, Kuronen T, Lensu L, Kaarna A, Honkapuro S. Assessing the performance of deep learning models for multivariate probabilistic energy forecasting. Appl Energy 2021;285(September 2020). [97] Fathi S, Srinivasan R, Fenner A, Fathi S. Machine learning applications in urban building energy performance forecasting: A systematic review. Renew Sustain Energy Rev 2020;133. [98] Yildiz B, Bilbao JI, Sproul AB. A review and analysis of regression and machine learning models on commercial building electricity load forecasting. Renew Sustain Energy Rev 2017;73:1104–22. [99] Coignard J, Janvier M, Debusschere V, Moreau G, Chollet S, Caire R. Evaluating forecasting methods in the context of local energy communities. Int J Electr Power Energy Syst 2021;131(August 2020). [100] do Amaral Burghi AC, Hirsch T, Pitz-Paal R. Artificial learning dispatch planning for flexible renewable-energy systems. Energies 2020;13(6):1–21. [101] Sharifzadeh M, Sikinioti-Lock A, Shah N. Machine-learning methods for integrated renewable power generation: A comparative study of artificial neural networks, support vector regression, and Gaussian process regression. Renew Sustain Energy Rev 2019;108:513–38. [102] Boussaada Z, Curea O, Remaci A, Camblong H, Bellaaj NM. A nonlinear autoregressive exogenous (NARX) neural network model for the prediction of the daily direct solar radiation. Energies 2018;11(3). [103] Sarkar R, Julai S, Hossain S, Chong WT, Rahman M. A comparative study of activation functions of NAR and NARX neural network for long-term wind speed forecasting in Malaysia. Math Probl Eng 2019;2019. [104] Sumper A. Micro and local power markets. John Wiley & Sons, Ltd; 2019, p. 1–265. [105] Degefa MZ, Sperstad IB, Sæle H. Comprehensive classifications and characterizations of power system flexibility resources. Electr Power Syst Res 2021;194(December 2020):107022. [106] Habib S, Kamran M, Rashid U. Impact analysis of vehicle-to-grid technology and charging strategies of electric vehicles on distribution networks - A review. J Power Sources 2015;277:205–14. [107] Khalid R, Javaid N, Al-zahrani FA, Aurangzeb K, Qazi EUH, Ashfaq T. Electricity load and price forecasting using jaya-long short term memory (JLSTM) in smart grids. Entropy 2020;22(1):10. [108] Barja-Martinez S, Aragüés-Peñalba M, Munné-Collado Í, Lloret-Gallego P, Bullich-Massagué E, Villafafila-Robles R. Artificial intelligence techniques for enabling big data services in distribution networks: A review. Renew Sustain Energy Rev 2021;150:111459. [109] Sadek SM, Omran WA, Hassan MA, Talaat HE. Data driven stochastic energy management for isolated microgrids based on generative adversarial networks considering reactive power capabilities of distributed energy resources and reactive power costs. IEEE Access 2021;9:5397–411. [110] Gan LK, Zhang P, Lee J, Osborne MA, Howey DA. Data-driven energy management system with Gaussian process forecasting and MPC for interconnected microgrids. IEEE Trans Sustain Energy 2021;12(1):695–704. [111] Afrasiabi M, Mohammadi M, Rastegar M, Kargarian A. Multi-agent microgrid energy management based on deep learning forecaster. Energy 2019;186. [112] Vosoogh M, Rashidinejad M, Abdollahi A, Ghaseminezhad M. An intelligent day ahead energy management framework for networked microgrids considering high penetration of electric vehicles. IEEE Trans Ind Inf 2021;17(1):667–77. [113] Lopez KL, Gagne C, Gardner MA. Demand-side management using deep learning for smart charging of electric vehicles. IEEE Trans Smart Grid 2019;10(3):2683–91. [114] Xu X, Xu X, Jia Y, Xu Y, Xu Z, Xu Z, et al. A multi-agent reinforcement learningbased data-driven method for home energy management. IEEE Trans Smart Grid 2020;11(4):3201–11. [115] Zeng P, Li H, He H, Li S. Dynamic energy management of a microgrid using approximate dynamic programming and deep recurrent neural network learning. IEEE Trans Smart Grid 2019;10(4):4435–45. [116] Nakabi TA, Toivanen P. Deep reinforcement learning for energy management in a microgrid with flexible demand. Sustain Energy, Grids Networks 2021;25:100413. [117] Bi W, Shu Y, Dong W, Yang Q. Real-time energy management of microgrid using reinforcement learning. In: Proceedings - 2020 19th distributed computing and applications for business engineering and science. 2020, p. 38–41. [118] Zhou H, Erol-Kantarci M. Correlated deep Q-learning based microgrid energy management. In: IEEE international workshop on computer aided modeling and design of communication links and networks, Vol. 2020-Septe. 2020, p. 0–5. [119] Hu R, Kwasinski A. Energy management for isolated renewable-powered microgrids using reinforcement learning and game theory. In: 2020 22nd European conference on power electronics and applications. 2020, p. 1–9. [120] Ye Y, Ye Y, Qiu D, Wu X, Strbac G, Ward J. Model-free real-time autonomous control for a residential multi-energy system using deep reinforcement learning. IEEE Trans Smart Grid 2020;11(4):3068–82. [121] Du Y, Zandi H, Kotevska O, Kurte K, Munk J, Amasyali K, et al. Intelligent multi-zone residential HVAC control strategy based on deep reinforcement learning. Appl Energy 2021;281. [122] Ruano A, Hernandez A, Ureña J, Ruano M, Garcia J. NILM techniques for intelligent home energy management and ambient assisted living: A review. Energies 2019;12(11):1–29. [123] Mengistu MA, Girmay AA, Camarda C, Acquaviva A, Patti E. A cloud-based on-line disaggregation algorithm for home appliance loads. IEEE Trans Smart Grid 2019;10(3):3430–9. [124] Cui G, Liu B, Luan W, Yu Y. Estimation of target appliance electricity consumption using background filtering. IEEE Trans Smart Grid 2019;10(6):5920–9. [125] Prasad A, Dusparic I. Multi-agent deep reinforcement learning for zero energy communities. 2018, p. 0–4, arXiv. [126] Wang Y, Chen Q, Gan D, Yang J, Kirschen DS, Kang C. Deep learning-based socio-demographic information identification from smart meter data. IEEE Trans Smart Grid 2019;10(3):2593–602. [127] Sun G, Cong Y, Hou D, Fan H, Xu X, Yu H. Joint household characteristic prediction via smart meter data. IEEE Trans Smart Grid 2019;10(2):1834–44. [128] Khodayar M, Wang J, Wang Z. Energy disaggregation via deep temporal dictionary learning. IEEE Trans Neural Netw Learn Syst 2020;31(5):1696–709. [129] Du Y, Li F. Intelligent multi-microgrid energy management based on deep neural network and model-free reinforcement learning. IEEE Trans Smart Grid 2020;11(2):1066–76. [130] Sperstad IB, Degefa MZ, Kjølle G. The impact of flexible resources in distribution systems on the security of electricity supply: A literature review. Electr Power Syst Res 2020;188(December 2019):106532. [131] Koirala BP, van Oost E, van der Windt H. Community energy storage: A responsible innovation towards a sustainable energy system? Appl Energy 2018;231(June):570–85. [132] Cao D, Hu W, Zhao J, Zhang G, Zhang B, Liu Z, et al. Reinforcement learning and its applications in modern power and energy systems: A review. J Mod Power Syst Clean Energy 2020;8(6):1029–42. [133] Shang Y, Wu W, Guo J, Ma Z, Sheng W, Lv Z, et al. Stochastic dispatch of energy storage in microgrids: An augmented reinforcement learning approach. Appl Energy 2020;261(December 2019):114423. [134] François-lavet V, Fonteneau R, Ernst D. Deep reinforcement learning solutions for energy microgrids management. In: European workshop on reinforcement learning, (no. 2015):2016, p. 1–7. [135] Qiu X, Nguyen TA, Crow ML. Heterogeneous energy storage optimization for microgrids. IEEE Trans Smart Grid 2016;7(3):1453–61. [136] Bui VH, Hussain A, Kim HM. Double deep q -learning-based distributed operation of battery energy storage system considering uncertainties. IEEE Trans Smart Grid 2020;11(1):457–69. Renewable and Sustainable Energy Reviews 170 (2022) 112651 18 A. Hernandez-Matheus et al. [137] Zhang Q, Dehghanpour K, Wang Z, Huang Q. A learning-based power management method for networked microgrids under incomplete information. IEEE Trans Smart Grid 2020;11(2):1193–204. [138] Domínguez-Barbero D, García-González J, Sanz-Bobi MA, Sánchez-Úbeda EF. Optimising a microgrid system by deep reinforcement learning techniques. Energies 2020;13(11). [139] Pan Z, Yu T, Li J, Qu K, Chen L, Yang B, et al. Stochastic transactive control for electric vehicle aggregators coordination: A decentralized approximate dynamic programming approach. IEEE Trans Smart Grid 2020;11(5):4261–77. [140] Balijepalli VSM, Pradhan V, Khaparde SA, Shereef RM. Review of demand response under smart grid paradigm. In: 2011 IEEE PES international conference on innovative smart grid technologies-India. 2011, p. 236–43. [141] Claessens BJ, Vrancx P, Ruelens F. Convolutional neural networks for automatic state-time feature extraction in reinforcement learning applied to residential load control. IEEE Trans Smart Grid 2018;9(4):3259–69. [142] Chung H-M, Maharjan S, Zhang Y, Eliassen F. Distributed deep reinforcement learning for intelligent load scheduling in residential smart grids. IEEE Trans Ind Inf 2021;17(4):2752–63. [143] Bahrami S, Wong VW, Huang J. An online learning algorithm for demand response in smart grid. IEEE Trans Smart Grid 2018;9(5):4712–25. [144] Kim BG, Zhang Y, Van Der Schaar M, Lee JW. Dynamic pricing and energy consumption scheduling with reinforcement learning. IEEE Trans Smart Grid 2016;7(5):2187–98. [145] Wang X, Wang H, Ahn SH. Demand-side management for off-grid solarpowered microgrids: A case study of rural electrification in Tanzania. Energy 2021;224:120229. [146] Sun M, Wang Y, Teng F, Ye Y, Strbac G, Kang C. Clustering-based residential baseline estimation: A probabilistic perspective. IEEE Trans Smart Grid 2019;10(6):6014–28. [147] Khezeli K, Bitar E. Risk-sensitive learning and pricing for demand response. IEEE Trans Smart Grid 2018;9(6):6000–7. [148] Vázquez-Canteli JR, Ulyanin S, Kämpf J, Nagy Z. Fusing TensorFlow with building energy simulation for intelligent energy management in smart cities. Sustainable Cities Soc 2019;45(July 2018):243–57. [149] Wang B, Li Y, Ming W, Wang S. Deep reinforcement learning method for demand response management of interruptible load. IEEE Trans Smart Grid 2020;11(4):3146–55. [150] Li H, Wan Z, He H. Real-time residential demand response. IEEE Trans Smart Grid 2020;11(5):4144–54. [151] Wen Z, O’Neill D, Maei H. Optimal demand response using device-based reinforcement learning. IEEE Trans Smart Grid 2015;6(5):2312–24. [152] Zhang X, Biagioni D, Cai M, Graf P, Rahman S. An edge-cloud integrated solution for buildings demand response using reinforcement learning. IEEE Trans Smart Grid 2021;12(1):420–31. [153] Smpoukis K, Steriotis K, Efthymiopoulos N, Tsaousoglou G, Makris P, Varvarigos EM. Network and market-aware bidding to maximize local RES usage and minimize cost in energy islands with weak grid connections. Energies 2020;13(15). [154] Sapountzoglou N, Lago J, Raison B. Fault diagnosis in low voltage smart distribution grids using gradient boosting trees. Electr Power Syst Res 2020;182(September 2019):106254. [155] Balouji E, Backstrom K, Hovila P. A deep learning approach to earth fault classification and source localization. In: IEEE PES innovative smart grid technologies conference Europe, vol. 2020-Octob, 2020, p. 635–9. [156] Letizia NA, Tonello AM. Supervised fault detection in energy grids measuring electrical quantities in the PLC band. In: 2020 IEEE international symposium on power line communications and its applications. 2020. [157] Fahim SR, Sarker SK, Muyeen SM, Sheikh MRI, Das SK. Microgrid fault detection and classification: Machine learning based approach, comparison, and reviews. Energies 2020;13(13). [158] Patnaik B, Mishra M, Bansal RC, Jena RK. MODWT-XGBoost based smart energy solution for fault detection and classification in a smart microgrid. Appl Energy 2021;285(October 2020):116457. [159] Cepeda C, Orozco-Henao C, Percybrooks W, Pulgarín-Rivera JD, Montoya OD, Gil-González W, et al. Intelligent fault detection system for microgrids. Energies 2020;13(5). [160] Fei W, Moses P. Fault current tracing and identification via machine learning considering distributed energy resources in distribution networks. Energies 2019;12(22):1–12. [161] Lin H, Sun K, Tan ZH, Liu C, Guerrero JM, Vasquez JC. Adaptive protection combined with machine learning for microgrids. IET Gener, Transm Distrib 2019;13(6):770–9. [162] Chen Z, Han F, Wu L, Yu J, Cheng S, Lin P, et al. Random forest based intelligent fault diagnosis for PV arrays using array voltage and string currents. Energy Convers Manage 2018;178(August):250–64. [163] Yuan H, Zhang Z, Yuan P, Wang S, Wang L, Yuan Y. A microgrid alarm processing method based on equipment fault prediction and improved support vector machine learning. J Phys Conf Ser 2020;1639(1). [164] Zhou W, Ardakanian O, Zhang HT, Yuan Y. Bayesian learning-based harmonic state estimation in distribution systems with smart meter and DPMU data. IEEE Trans Smart Grid 2020;11(1):832–45. [165] Al Karim M, Currie J, Lie TT. Dynamic event detection using a distributed feature selection based machine learning approach in a self-healing microgrid. IEEE Trans Power Syst 2018;33(5):4706–18. [166] Wang C, Yu H, Chai L, Liu H, Zhu B. Emergency load shedding strategy for microgrids based on dueling deep Q-learning. IEEE Access 2021;9:1. [167] Gong R, Ruan T. A new convolutional network structure for power quality disturbance identification and classification in micro-grids. IEEE Access 2020;8:88801–14. [168] Wang W, Yu N, Gao Y, Shi J. Safe off-policy deep reinforcement learning algorithm for volt-svar control in power distribution systems. IEEE Trans Smart Grid 2020;11(4):3008–18. [169] Fu X, Guo Q, Sun H. Statistical machine learning model for stochastic optimal planning of distribution networks considering a dynamic correlation and dimension reduction. IEEE Trans Smart Grid 2020;11(4):2904–17. [170] Zhong T, Zhang H-T, Li Y, Liu L, Lu R. Bayesian learning-based multi-objective distribution power network reconfiguration. IEEE Trans Smart Grid 2020;1. [171] Sun W, Zamani M, Hesamzadeh MR, Zhang HT. Data-driven probabilistic optimal power flow with nonparametric Bayesian modeling and inference. IEEE Trans Smart Grid 2020;11(2):1077–90. [172] Dobbe R, Sondermeijer O, Fridovich-Keil D, Arnold D, Callaway D, Tomlin C. Toward distributed energy services: Decentralizing optimal power flow with machine learning. IEEE Trans Smart Grid 2020;11(2):1296–306. [173] Ye Z, Yang H, Zheng M. Using modified prediction interval-based machine learning model to mitigate data attack in microgrid. Int J Electr Power Energy Syst 2021;129(February):106847. [174] Kavousi-Fard A, Su W, Jin T. A machine-learning-based cyber attack detection model for wireless sensor networks in microgrids. IEEE Trans Ind Inf 2021;17(1):650–8. [175] Kurt MN, Ogundijo O, Li C, Wang X. Online cyber-attack detection in smart grid: A reinforcement learning approach. IEEE Trans Smart Grid 2018;10(5):5174–85. [176] Karimipour H, Dehghantanha A, Parizi RM, Choo KKR, Leung H. A deep and scalable unsupervised machine learning system for cyber-attack detection in large-scale smart grids. IEEE Access 2019;7:80778–88. [177] Ismail M, Shaaban MF, Naidu M, Serpedin E. Deep learning detection of electricity theft cyber-attacks in renewable distributed generation. IEEE Trans Smart Grid 2020;11(4):3428–37. [178] Ozay M, Esnaola I, Yarman Vural FT, Kulkarni SR, Poor HV. Machine learning methods for attack detection in the smart grid. IEEE Trans Neural Netw Learn Syst 2016;27(8):1773–86. [179] Azad S, Sabrina F, Wasimi S. Transformation of smart grid using machine learning. In: 2019 29th Australasian universities power engineering conference. 2019. [180] Xiao X, Dai C, Li Y, Zhou C, Xiao L. Energy trading game for microgrids using reinforcement learning. In: Lecture Notes of the Institute for Computer Sciences, Social-Informatics and Telecommunications Engineering, LNICST, vol. 212, 2017, p. 131–40. [181] Chen T, Su W. Local energy trading behavior modeling with deep reinforcement learning. IEEE Access 2018;6:62806–14. [182] Chen T, Su W. Indirect customer-to-customer energy trading with reinforcement learning. IEEE Trans Smart Grid 2019;10(4):4338–48. [183] Chen T, Bu S. Realistic peer-to-peer energy trading model for microgrids using deep reinforcement learning. In: Proceedings of 2019 IEEE PES innovative smart grid technologies Europe. IEEE; 2019. [184] Zhang X, Bao T, Yu T, Yang B, Han C. Deep transfer Q-learning with virtual leader-follower for supply-demand Stackelberg game of smart grid. Energy 2017;133:348–65. [185] Zhou S, Hu Z, Gu W, Jiang M, Zhang X-P. Artificial intelligence based smart energy community management: A reinforcement learning approach. CSEE J Power Energy Syst 2019;(June 2020). [186] Lu X, Xiao X, Xiao L, Dai C, Peng M, Poor HV. Reinforcement learning-based microgrid energy trading with a reduced power plant schedule. IEEE Internet Things J 2019;6(6):10728–37. [187] Boukas I, Ernst D, Cornelusse B. Real-time bidding strategies from micro-grids using reinforcement learning. In: CIRED workshop 2018, (no. 0440):2018, p. 7–8. [188] Jamil F, Iqbal N, Imran, Ahmad S, Kim DH. Peer-to-peer energy trading mechanism based on blockchain and machine learning for sustainable electrical power supply in smart grid. IEEE Access 2021;39193–217.