Pressure has been introduced into power systems owing to the intermittent and uncertain nature of renewable energy. As a result, energy resource aggregators are emerging in the electricity market to realize sustainable and economic advantages through distributed generation, energy storage, and demand response resources. However, resource aggregators face the challenge of dealing with the uncertainty of renewable energy generation and setting appropriate incentives to exploit substantial energy flexibility in the building sector. In this study, a risk-aware optimal dispatch strategy that integrates probabilistic renewable energy prediction and bi-level building flexibility engagements is proposed. A natural gradient boosting algorithm (NGBoost), which requires no prior knowledge of uncertain variables, was adopted to develop a probabilistic photovoltaic (PV) forecasting model. The lack of suitable flexibility incentives is addressed by a novel interactive flexibility engagement scheme that can take into account building users’ willingness and optimize the building flexibility provision. The chance-constrained programming method was applied to manage the supply–demand balance of the resource aggregator and ensure risk-aware decision-making in power dispatch. The case study results show the strong economic and environmental performance of the proposed strategy. The proposed strategy leads to a win–win situation in which profit increases through a load reduction of 13% and a carbon emission reduction of 3% is achieved for different stakeholders, which also shows a trade-off between the economic benefits and the risk of supply shortage.
The green energy transition and carbon neutrality goals are driving renewable energy generation worldwide. Due to the intermittent, uncertain and weather-dependent nature of solar and wind power, electricity systems have inevitably come under supply and demand side pressures, making balancing electricity supply and demand on different time scales a major challenge. To deal with this problem, demand response (DR) is an effective measure to improve power system reliability, as it can reduce the use of expensive backup generators and enable higher penetration of intermittent renewables [1], [2]. End users from the demand side can adjust their electricity consumption according to the requirements of the power grid and act as flexible resources [3].
As numerous distributed energy resources are integrated into the power grid, the wholesale electricity market faces constraints in effectively accommodating a large number of entities, which results in limiting the direct participation of small-scale distributed energy resources. Consequently, with the development of remote control and communication technologies, operating entities such as microgrids [4], virtual power plants, energy hubs, and resource aggregators are emerging in the existing electricity market to take advantage of the complementary benefits of multiple distributed energy sources [5], [6]. They usually refer to a network of distributed power generation, energy storage systems, and demand–response resources that are operated together as a single unit. They have received considerable attention due to their potential to improve grid stability, support the integration of renewable energy, and provide valuable flexibility services [7]. However, there are several challenges in operating aggregators when it comes to integrating renewable energy generation with various flexible demand-side resources.
First, by pooling multiple resources, an aggregator creates a more diverse and balanced portfolio of energy assets to mitigate the inherent variability and intermittency of renewable resources. Renewable resource generation must be predictable and reliable for day-ahead scheduling [8]. Deterministic and probabilistic forecasting are the two main techniques for predicting renewable generation [9]. The deterministic approach provides exact point forecasts for any given time step, which has been thoroughly investigated in existing studies, but does not take uncertainty into account. A probabilistic approach can provide prediction intervals (PIs) and the corresponding probability density functions of renewable generation, considering them as random variables. It is more valuable than the deterministic approach because it can characterize the inherent uncertainty in the data and incorporate the risk attitude for decision-making [10], [11]. The integration of data-driven probabilistic forecasting and chance-constrained programming can provide an effective, risk-aware scheduling method to account for uncertainty in aggregator operation.
Secondly, an appropriate incentive mechanism is required to unlock demand-side flexibility in the coordinated optimization of aggregator operation. As the aggregation entity, the aggregator purchases electricity directly on the wholesale market and provides electricity supply services to the demand-side at fixed retail prices. The retail prices are usually higher than the wholesale prices for electricity in most time slots. As wholesale prices fluctuate, the aggregator has to take risks in times of high wholesale prices. This pressure can be alleviated by unlocking demand-side flexibility through an incentive-based demand response program. When receiving the incentive information, end users are motivated to reduce their power consumption according to their own willingness and load characteristics. Aggregators can also reduce their losses by purchasing less electricity in extreme situations where wholesale electricity prices are exceptionally high. Different stakeholders can benefit if a suitable incentive mechanism is developed to optimize the demand response behavior of users.
Thirdly, the flexibility potential and associated costs with regard to the different responsive load characteristics in the demand-side building sector have not yet been fully investigated. As one of the largest end users of electricity, the building sector accounts for more than 70% of the total electricity consumption in the United States and 90% in Hong Kong, China [12]. Many cost-effective flexible resources such as smart load control and the use of passive thermal mass storage in buildings are not yet exploited for demand response. Recently, the development of grid-responsive and energy-flexible buildings has gained momentum [13], [14], which has led to extensive research in this domain. For example, owing to the inherent storage characteristics of the building’s thermal mass, the indoor thermal environment can be comfortable even during demand response periods if the power consumption of the heating, ventilation, and air conditioning (HVAC) systems is appropriately reduced and controlled. Similarly, lighting systems with dimming control can also be used for demand response as the indoor visual comfort of building occupants has a flexible range. The incentive mechanism needs to consider how to find a trade-off between load reduction and the compromise between indoor comfort and building occupant satisfaction.
1.2. Related existing work
In recent years, many studies have dealt with probabilistic forecasting in the fields of renewable energy [15] and electricity load [16], [17] as listed in Table 1[9], [15], [19], [20], [21], [23], [24], [25], [26], [27], [28], [29]. Probabilistic forecasting accounts for uncertainty information, which is typically represented by probability distributions. Depending on whether an explicit parametric form is used, these can be divided into parametric and non-parametric approaches [18]. The parametric approach usually assumes that the predicted random variable follows a specific distribution, whereas the non-parametric approach makes no distributional assumptions, which allows it to better capture the observed asymmetries. Various non-parametric techniques can be used such as kernel density estimation [15], quantile regression [19], bootstrapping [20], lower upper bound estimation (LUBE) [21], and gradient boosting [9], [22].
For example, Almeida et al. [19] used quantile regression forests to predict photovoltaic (PV) output power for one day in advance with an hourly resolution, providing statistical data on the quantiles of the hourly forecast. They found that this non-parametric approach provided better results than parametric modeling in terms of accuracy, especially in the high- and medium-clearness index ranges. Ni et al. [23] proposed a novel combined LUBE method to obtain the optimal prediction intervals for short-term PV power generation. Their results showed that this forecasting method significantly improved the quality of the prediction intervals in terms of both sharpness and coverage probability.
To produce probabilistic forecasts, Mitrentsis and Lens [9] used natural gradient boosting (NGBoost), which does not make strong assumptions about the functional form of the relationship between inputs and outputs, to probabilistically predict PV output. They also calculated Shapley additive explanation values to gain insight into why certain predictions were made. Both the point forecast accuracy and the overall probabilistic performance improved significantly.
Many studies have looked at probabilistic forecasting, but most have aimed to improve the prediction of renewable energy generation using probabilistic inputs. In this study, a data-driven probabilistic forecasting model was applied based on a natural gradient boosting algorithm to optimize the operation of resource aggregators, a topic that has not been investigated in previous research.
The application of a suitable optimization technique is also essential for dealing with uncertainties in the decision-making process of an energy management strategy [30]. In contrast to the scenario-based approach of stochastic optimization, which can lead to computational intractability [31], the main concept of chance constraints in risk-aware decision-making is to represent uncertainties by guaranteeing that the associated constraints are satisfied with certain probabilities. Many studies have adopted a chance-constrained programming technique for risk-aware optimization of power and energy dispatch. For example, Guo et al. [32] developed a chance-constrained peer-to-peer joint energy and reserve market to account for the uncertainties in renewable generation and to ensure a fair allocation of reserve costs. Wang et al. [33] proposed a chance-constrained programming approach for the day-ahead optimal bidding strategy of energy systems to minimize the operation cost of energy dispatch in electricity markets by considering the uncertainties of renewable generation and multiple loads. Chance-constrained programming can effectively manage the risk by imposing probabilistic constraints on the uncertain parameters of a decision problem.
Another critical issue is unlocking demand-side flexibility without compromising indoor comfort or load satisfaction for building occupants during aggregator operation. Incentive-based demand response programs are commonly implemented using smart-grid technologies and advanced metering systems. By financially compensating users with attractive incentives, the demand response program encourages the demand side to provide energy flexibility by reducing load during high demand, peak-price hours, or grid emergencies. For example, Kohansal and Mohsenian-Rad [34] developed a scenario-based stochastic optimization framework in day-ahead and real-time markets to optimize the hourly energy price for the demand side. In this study, historical data on demand-side consumption under previously price-quota curves were used to analyze user response behavior. Chai et al. [35] proposed an incentive-based demand response model that considered the effect of user behavior. With the proposed optimization model, retailers’ profits and users’ load reduction can be determined under a specific incentive. Based on the assumed user response behavior, bi-level optimization [36], [37] and game theory-based optimization [38] can be used in the interactive scheme to optimize the flexibility provision and ensure the benefits of different stakeholders. However, most existing studies use price–quota curves [34], [39] and demand elasticity models [40] to capture user response behaviors. However, these models are insufficient to describe building users’ willingness to participate in demand responses when responsive loads are related to indoor comfort. For example, load adjustment of HVAC and lighting systems can achieve demand response objectives by readjusting the indoor air temperature/supply air temperature/chilled water temperature or dimming lighting control [41], [42]. However, the effects of these methods on the thermal and visual indoor comfort of building occupants are ignored and cannot be directly accounted for using the aforementioned demand elasticity models. In our previous study [43], an optimal strategy was developed for unlocking the energy flexibility of building clusters while ignoring the effects of incentives on user behavior. An interactive scheme that considers indoor comfort and load satisfaction of building occupants is needed to represent users’ willingness and guide demand-side response actions to exploit flexibility.
1.3. Main contributions
Previous studies have proposed many dispatch strategies to deal with the uncertainties of renewable generation and demand-side flexibility in aggregator operation. However, most of these strategies assume that prior uncertainty information is difficult to obtain and ignore the willingness of demand-side building users to participate in demand response. The objective of this study was to solve these problems by developing a risk-based optimal dispatch strategy for resource aggregators. In the context of existing literature, this study fills the gaps related to the practical difficulties of renewable energy procurement uncertainty and neglecting demand response willingness by integrating a data-driven probabilistic forecasting model for renewable energy generation and an interactive flexibility engagement scheme. The main contributions of this study are as follows.
(1) A data-driven probabilistic forecasting model for renewable energy generation was developed that adopts the NGBoost without prior knowledge of uncertain variables. Based on the probabilistic prediction, the balance between supply and demand was reformulated with chance constraints to enable a risk-aware decision-making process for the aggregator’s energy management.
(2) A bi-level optimization problem was formulated to design the incentive mechanism for the interactive flexibility engagement scheme, which captures the willingness of building users based on indoor comfort and load satisfaction indices and maximizes the use of demand-side flexibility
(3) The energy management of the aggregator was optimized based on a chance-constrained risk-aware bidding strategy using mixed-integer linear programming, which enables the aggregator to maximize the operating profits from electricity trading between the wholesale and retail markets.
(4) The effectiveness of the proposed strategy is validated using a case study. The effects of different power supply confidence levels on economic performance and the risk of supply shortages were discussed.
The remainder of the paper is organized as follows. Section 2 introduces the outline of proposed risk-aware optimal dispatch strategy. Section 3 describes the methodology and mathematical formulation of optimization. 4 Arrangement of the validation tests, 5 Results and analysis present the arrangement of the validation tests and result analysis. The conclusions are summarized in Section 6.
2. Outline of proposed risk-aware optimal dispatch strategy
Fig. 1 presents the framework of the proposed dispatch strategy for the resource aggregator and highlights the interactions between the wholesale market, the aggregator, and the building users. The aggregator plays a crucial role in enabling market access to various distributed resources such as renewables, storage systems, and flexible loads. It can also act as an intermediary between the wholesale and retail markets to meet demand-side load requirements.
The proposed risk-aware dispatch strategy consists of two key components: an interactive flexibility engagement scheme and a chance-constrained day-ahead bidding process. Under the interactive flexibility engagement scheme, an incentive-based demand response program is implemented to leverage the demand-side building energy flexibility when wholesale electricity prices exceed transactive retail prices. In this scenario, the aggregator incentivizes and encourages building users to reduce their load. A bi-level optimization problem was formulated to determine the optimal incentives and load-reduction capacities that ensure mutual benefits for the aggregator and building users. In this study, HVAC systems, dimmable lighting systems, and curtailable plug-in loads were considered as flexible resources. Building users can set self-defined coefficients to quantify the cost of indoor thermal/visual discomfort and load dissatisfaction associated with load reduction. Therefore, the optimization process can capture the willingness of building users by introducing the associated costs.
The day-ahead bidding process optimizes the dispatch of the storage system and the electricity bidding strategy in the wholesale market, accounting for the uncertainties of the renewable generation forecast by the NGBoost algorithm. The variables to be optimized include the electricity purchased on the wholesale market, the electricity sold to the building users, and charging/discharging of the storage system. Based on the supply–demand balance requirements and the probabilistic forecast of renewable generation, the chance constraint method converts the optimization problem into a mixed-integer linear programming formulation. The settlements for all spot purchases made by the aggregator in the day-ahead market are determined by the corresponding prices and quantities of electricity dispatched per hour. In this study, it was assumed that the aggregator acts as a price taker in the day-ahead market due to its limited influence on the wholesale market and accordingly submits electricity bids covering the following 24 h period.
By leveraging the flexibility of multiple responsive loads and storage systems, the aggregator can derive a risk-aware optimal dispatch strategy based on renewable generation probabilities that minimizes costs (or maximizes profits) in the day-ahead market. Building users can also benefit from the flexibility offered by the demand response program.
3. Methodology and mathematical formulation of risk-aware optimization
3.1. Objective function
The optimization objective of the proposed dispatch strategy for the aggregator is given by Eq. (1). The overall objective is to minimize the cost of buying electricity from the wholesale market (CWM), maximize the profits from selling electricity to building users (CRM), and minimize the demand response (CDR) payments, while satisfying all operational constraints. Eqs. (2), (3), (4) represent the costs and profits, respectively.
where , , and are the wholesale electricity price, the retail electricity price, and the demand response incentive at time t, respectively. Pgrid,t, is the electricity bought from the wholesale market, whereas Pload,t is the electricity simultaneously sold to the building users in the retail market. Δt is the time interval which is set to one hour in this study. tDR is the demand response period. When is higher than , an incentive is offered to encourage users to activate demand response. ΔPDR,t is the demand response capacity of the building users. The incentive and demand response capacities are determined by a bi-level optimization process in the interactive flexibility engagement scheme, as described in Section 3.2. The constraints of storage and energy balance in the dispatch are presented in Section 3.3.
3.2. Interactive flexibility engagement of building users
3.2.1. Bi-level optimization of the demand response incentive
To determine the incentive and demand response capacity ΔPDR,t, an interactive flexibility engagement scheme is used, which precedes the day-ahead bidding process to ensure the benefits of different stakeholders. A bi-level optimization problem with upper-lower objectives and constraints was formulated and the lower-level optimization problem was replaced by the Karush–Kuhn–Tucker (KKT) optimality conditions in the optimization programming.
where ΔPDR,i,t is the total load reduction capacity of building i during the demand response period tDR. cth,i,t, cvis,i,t, and cld,i,t represent the costs of thermal discomfort, visual discomfort, and load dissatisfaction, respectively, due to the curtailment of the different system loads during the demand response period. The details of the quantification are described in Section 3.2.2.
3.2.2. Quantification of the associated demand response costs
Three types of loads within a building cluster (with multiple building users) were considered in this study: HVAC systems, dimmable lighting systems, and plug-in equipment, as shown in Eq. (7). For each building i, the costs of thermal and visual discomfort and load dissatisfaction can be represented by Eqs. (8), (9), (10).
where PHVAC,i,t, Plig,i,t, Pce,i,t are the load reduction of the HVAC system, lighting system, and other plug-in equipment during the demand response period. α, β, and γ are self-defined coefficients of the building users that represent their willingness to manage demand. ΔPMVi,t is the change in the predictive mean vote (PMV) value used to quantify the thermal discomfort cost. ΔLi,t is the change in horizontal illuminance used to quantify the visual discomfort cost. The visual discomfort cost is quantified based on the change in horizontal illuminance (ΔLi,t). Lb,i,t and Pceb,i,t are the baseline levels of the indoor illuminance and other loads, respectively. The load-dissatisfaction cost was quantified based on the load-reduction rate of the plug-in equipment.
For each building, by implementing appropriate control strategies, such as adjusting the indoor air temperature, the power consumption of the HVAC system can be partially reduced to ensure energy flexibility, although thermal comfort may be affected. Therefore, a simplified Resistor–Capacitor (RC) based model was used to represent the thermal dynamics of the building to quickly calculate the load alteration of the HVAC system and evaluate the effect on thermal comfort based on the PMV. This model simplifies the external and internal thermal masses of a building into a single homogeneous lumped mass and introduces an equivalent temperature to represent the overall building energy status. The heat transfer between the outdoor environment, building thermal mass, and indoor environment is simplified by the equivalent external and internal thermal mass resistances and the effective surface of the building envelope. Consequently, the passive storage characteristics of a building can be succinctly represented by the determined thermal capacitance and resistance values (derived by training historical load and temperature data) and used to calculate the change in cooling load as a function of the indoor temperature reset. The effectiveness of the model for evaluating the load alteration of an HVAC system was validated under several demand response scenarios, as described by Xue et al. [44]. Eqs. (11), (12), (13), (14), (15) present the relation between the indoor air temperature, power consumption of the HVAC system, and PMV [45]. The constraints of the load-reduction capability of the HVAC system and the indoor air temperature are shown in Eqs. (16), (17). The load-reduction capacity of the dimmable lighting system and other plug-in equipment can be calculated within specified limits using Eqs. (18), (19), (20), (21), (22):
where ΔQbui,t denotes the cooling load alteration potential. Rbui,o and Rbui,in denote the equivalent external and internal thermal mass resistances of the building, respectively. τ denotes the time constant. Cbui is the thermal capacitancer. Abui is an effective building surface. Tb is the indoor air temperature in the baseline control method. Tin,t is the indoor air temperature under the flexibility provision scheme, which must be optimized. QHVAC,t is the cooling load at the time t. Qbase,t is the baseline cooling load at the time t. tDR is the duration of the demand response. Ts is the average temperature of the human skin, and MR is the human energy metabolism rate. Icl is the thermal resistance of clothing. PMVt is the predicted mean vote value at the time t. PHVAC,t, PHVACb,t, and COPt are the load reduction, baseline consumption, and coefficient of performance of the HVAC system, respectively. PHVAC,LO is the lowest power consumption of the HVAC system when the load ratio was 0.2. Tmax is the maximum acceptable indoor air temperature. ΔLt and Lb,t are the change in and the baseline of the horizontal illuminance. Lmin is the minimum acceptable illuminance. Plig,t, Pligb,t, and Plig,t are the load reduction, baseline consumption, and optimized consumption of the lighting system. LE is the luminous efficacy of the individual lamps (80 lm·W−1). UF is the utilization factor and is normally between 0.4 and 0.6. The maintenance factor, denoted as MF, is set to 0.7 in good-condition scenarios. Pce,t, Pceb,t, and Pce,t are the load reduction, baseline consumption, and optimized consumption of the plug-in equipment. ε is the maximum reduction rate of plug-in equipment.
3.3. Constraints of day-ahead bidding optimization
3.3.1. Electrical energy storage (EES) constraints
The constraints on electrical storage in optimal bidding are shown in Eqs. (23), (24), (25), (26). The upper and lower limits were set to slow down the degradation of the battery.
where PEES,t is the discharge power of the battery. and are used to identify the different states. When the storage is discharged at , the charging power is equal to zero, and vice versa. SOCEES,t+1 and SOCEES,t are the electric energy storage states at the time t + 1 and t, respectively. EEES and PEES,max are the storage capacity and the rated power. SOCmax and SOCmin are the upper and lower limits of the electric energy storage state, respectively. ηch and ηdis are the charging and discharging efficiency respectively.
3.3.2. Chance constraints of supply and demand balance
The net demand (Pnet,t) and supply (Psupply,t) are expressed in Eqs. (27) and (28). The uncertainty of PV generation must be taken into account during the day-ahead bidding process. Therefore, chance-constrained programming was chosen to account for the uncertain factors by ensuring that the probability of meeting the constraints is equal to or greater than the specified confidence level. The constraints for the energy balance between the supply and demand are formulated as shown in Eq. (29). To solve the optimization problem involving chance constraints, the implicit chance constraints are transformed into deterministic constraints based on the cumulative distribution function principle. The optimal decision for the inclusion of risk can be made by defining different confidence levels.
where Pbase,t denotes the baseline load of the building cluster. PPV,t is the predicted PV generation power. Pr(⋅) denotes the probability of an event occurring. is the confidence level set by the aggregator for ensuring the energy balance.
3.4. Extraction of uncertainties through the application of NGBoost
The conventional method for quantifying the uncertainties in renewable generation is to infer a probability distribution of the output based on a given probability distribution function of an assumed known input; however, the distribution function is difficult to obtain and may not always be accurate or appropriate. Therefore, in this study, the NGBoost algorithm [46] was used to extract the uncertainty of renewable generation from historical data without prior knowledge of the uncertain variables. NGBoost is a highly effective gradient-boosting algorithm known for its simplicity and modularity.
As shown in Fig. 2, the algorithm consists of three key components: ① base learners such as a regression tree, ② a probability distribution that defines the form and parameters of the distribution to be estimated, and ③ a scoring rule. The NGBoost algorithm is a supervised learning technique that uses boosting to estimate the parameters of a conditional probability distribution denoted as Pθ(y|x), where y represents the target variable, x represents the input features, and θ represents the parameter vector of the probability distribution, which is not limited to scalar-valued distributions. The parameter vector varies depending on the selected distribution, such as the mean and standard deviation, for a normal distribution. It is noteworthy that the distribution mentioned does not represent the entire target variable. Instead, it refers to the specific training examples assigned to each leaf node in the tree. Consequently, each leaf node had a unique probabilistic distribution.
For the point forecast, the predicted values were evaluated against the observed data using a loss function. In NGBoost-based probabilistic regression, a similar evaluation is performed using a scoring rule that compares the estimated probability distribution with the observed data. This scoring rule, denoted S, uses the forecasted probability distribution (Pθ) and the observation outcome (y) as inputs. It assigns a score S(Pθ, y) to the forecast and aims to give the best score true distribution of outcomes the best score on average. Among the various rules available for appropriate scoring, the logarithmic score is commonly used and can be described mathematically as follows:
Starting from a training dataset denoted as , the parameters θ are obtained by aggregating M base learner outputs and an initial θ(0), shown in Eqs. (31), (32), (33). θ(0) is the initial parameter vector. xn and yn are observed feature and target in the training dataset. N denotes the size of the dataset n. The learning algorithm begins with θ(0), which minimizes the sum of the scoring rule S for all training examples and effectively fits the marginal distribution of the response variables. The predicted outputs were scaled using the scaling factors specific to each stage. Where M denotes the boosting iterations. η is the learning rate, f(m) is the set of base learners for each stage m, and ρ(m) is the scaling factor. Eq. (33) shows an example of a normal distribution. and are two base learners per stage with parameters µ and σ.
4. Arrangement of the validation tests
To validate the effectiveness of the proposed dispatch strategy, the operation of the resource aggregator was tested on the five weekdays in Hong Kong, China. The demand-side building cluster selected included three multi-floor office buildings with different thermal characteristics (i.e., one low-weighted, one middle-weighted, and one high-weighted). The baseline control strategy of the HVAC system during office hours assumes a constant indoor temperature of 24 °C and humidity of 60% relative humidity (RH) following the given schedule of the occupancy rate. Table 2[47] lists the specifications and parameters of the simplified building thermal models and Table 3[47] lists the electrical energy storage systems and the self-defined coefficients for the building’s load discomfort and dissatisfaction costs.
The historical data on PV output were obtained from the system advisor model (SAM) project [48]. Fig. 3 presents the data containing measurements with a resolution of 1 h resolution from January 2 to December 31, 2021. To improve the data quality, a data preprocessing procedure, such as the identification of outliers with domain expertise was implemented. The daily PV power generation profile of the training set is shown in Fig. 4. The NGBoost algorithm was used in this study to generate a probabilistic prediction of PV power output. In this study, decision trees were selected as the base learners because they are non-parametric, suitable for handling complex patterns in volatile data, and can capture nonlinear relationships. They are robust to outliers to certain degree, because they split the data based on feature thresholds. The features used to train the predictive model included the time of day, temperature, sun position above the horizon, and hourly minimum and maximum global horizontal irradiance. In forecasting, the model input uses predicted weather information available for the coming day (e.g., the predicted hourly minimum and maximum global horizontal irradiance) at time t to predict PV generation for a future period. The normal distribution θ with the mean and standard deviation is chosen as the probability distribution for each time interval as it gave an accurate prediction in the preliminary analysis. The logarithmic scoring rule is used to generate a rating based on a predicted distribution and an observation of the target variable.
5. Results and analysis
A probabilistic prediction of PV power generation based on the NGBoost algorithm was conducted in Python. The bi-level optimization and the chance-constrained bidding optimization problem were programmed with YALMIP toolbox [28] in an MATLAB environment and solved with the CPLEX solver on a computer with an eight-core Intel Core i7 CPU. In this section, the optimization results in July 2021 of the interactive flexibility engagement scheme and the economic performance of the proposed chance-constrained dispatch strategy under different confidence levels are presented.
5.1. Optimized load reduction and demand response incentives
The day-ahead electricity prices were taken from the California Independent System Operator (CAISO) market. Fig. 5 shows the optimization results of demand response incentives based on a bi-level optimization considering the willingness of building users. The aggregator provides electricity supply services to the demand-side building cluster at a fixed retail price (set as 45 USD·(MW·h)−1 in this case) which is higher than the wholesale electricity price in most time slots. If the wholesale electricity price exceeds the transaction price, an interactive flexibility engagement is implemented price during the demand response period, and an optimized incentive is sent to the building cluster to encourage load reduction. For example, if on July 20 between 19:00 and 20:00, when the wholesale price is 122.85 USD·(MW·h)−1, the optimized incentive reaches 22.22 USD·(MW·h)−1.
Fig. 6 shows the total power consumption of the building cluster and the optimized load-reduction capacities of the different buildings. It can be observed that load reduction usually takes place between 18:00 and 21:00 and can even reach 100 kW in some hours. This shows that the total load can be reduced by up to 13% when the wholesale price is excessively high (July 20 between 19:00 and 20:00). Each building has a different load-reduction capacity, owing to its unique thermal characteristics and self-defined cost coefficients.
Fig. 7 presents the load reduction results for different systems and the corresponding flexible settings of the buildings. These flexible settings include the optimized indoor illuminance, indoor temperature, and the reduction rate of curtailable plug-in loads. The results showed that the load reduction capacity of the HVAC system was only implemented between 19:00 and 20:00, one hour before it was shut down. This is because reducing the HVAC system load at other times cannot prevent the rebound effect. Figs. 7(b)–(d) depict the diverse settings optimized for the different building users during the demand response periods. Building User 1, for example, sets the lowest value for α (self-defined coefficient of thermal discomfort cost), indicating a higher willingness to sacrifice indoor thermal comfort for demand response. This user is more inclined to tolerate higher indoor temperatures, as shown in Fig. 7 (c). The variations in flexible settings of the building users show how important it is to consider individual preferences and comfort requirements.
The optimization process allows building users on the demand-side to adjust their settings based on their needs and comfort thresholds. Each building user can set their self-defined coefficients (α, β, γ) reflecting the degree to which the user is willing to participate in load reduction, which are fairly considered after aggregating multiple buildings in the optimization process. The incentive is measured as a reward per unit of kW load reduction, and the profits of buildings are ultimately performance-based, which means that those who contribute more to load reduction can receive higher profits. By accommodating user preferences in this interactive scheme, the participation and engagement of building users can be improved, leading to a more effective and satisfactory implementation of demand response within the resource aggregator framework.
5.2. Probabilistic prediction of renewable generation
Fig. 8 shows the NGBoost-based probabilistic prediction results for PV generation from July 19 to 24, 2021. The mean values of the PV forecast output and forecast intervals are shown with different colors in the figure to visually represent the probabilistic results. The mean value of each time step represents the expected PV forecast output (at the 50% quantile level) during a given period. The prediction intervals (25%, 50%, 75%, and 95% confidence intervals) reflect the possible ranges of the conditional metric values for future PV output power. The color assigned to each interval corresponds to the probability that the PV output power will fall within a specific range. Each time step corresponded to a specific normal distribution. Fig. 8 presents an illustrative example of a probability density function representing the PV forecast at 12:00 on July 21, 2021. The probability density function is characterized by the mean (μ = 351.1 kW) and the standard deviation (σ = 21.3 kW) values.
Three indices, mean absolute percentage error (MAPE), mean square error (MSE), and coefficient of variation of root mean square error (CV-RMSE) [29], were used to evaluate the performance of probabilistic PV prediction. The performance results based on the predicted mean value and actual PV power generation are 4.29%, 16.70 kW, and 8.16%, respectively. It can also be observed that the actual PV power outputs align with 50% of the prediction intervals in most time slots, indicating high accuracy. When the PV generation power fluctuates sharply, the width of the prediction intervals may increase owing to the volatility of PV generation. The prediction results demonstrate the effectiveness of the NGBoost algorithm in capturing the probabilistic nature of PV generation, which enables the aggregator to make risk-aware decisions to optimize the dispatch.
The probability integral transform (PIT) is a technique that converts data values from any continuous distribution into random variables that follow a standard uniform distribution [29]. This method is useful for evaluating probabilistic predictions by comparing observed values with predicted densities. If the probabilistic predictions are accurate and stable, the resulting PIT histogram, which displays the frequency of each transformed value, should be approximately uniform. Fig. 9 illustrates the PIT histogram for probabilistic PV predictions across the dataset, with the dashed red line indicating the average frequency. This indicates that the probabilistic PV predictions for the dataset are consistent and reliable as the distribution is almost uniform.
5.3. Chance-constrained optimal dispatch results
Based on the optimized load reduction and the probabilistic prediction of PV generation with different prediction intervals, the optimization of day-ahead bids for the resource aggregator can be performed in a risk-aware manner. An acceptable probability of 85% was set as the confidence level for the energy balance constraints to ensure a relatively conservative and reliable outcome. The probabilistic predicted result of PV generation is then transformed into a tractable deterministic value using a specified 85% quantile during optimization.
Fig. 10 presents the optimal power dispatch results from the day-ahead bid optimization. The power demand (reduced load from the baseline power consumption) was fulfilled by a combination of power supply sources, including the power grid, PV generation, and storage system discharge. Positive and negative power values indicate that the battery has been discharged and charged, respectively. When the wholesale price is exceptionally high, the load is reduced under the interactive flexibility engagement scheme and the battery is discharged at its maximum rate to minimize costs. During the hours of low peak prices in the early morning, the load can be fully satisfied by discharging the storage system and making use of the available PV generation, so that renewable energy sources are used to meet demand. Considering the probabilistic nature of PV generation and varying wholesale prices, the aggregator can make informed decisions by taking a chance-constrained approach and maximizing economic benefits while ensuring a reliable and sustainable energy supply. A key metric that is significantly affected is the risk to which aggregators are exposed in the market.
5.4. Economic and environmental performance and risks of supply shortages at different confidence levels
In the proposed dispatch strategy, both the resource aggregator and the building users can benefit from an interactive flexibility engagement scheme. Based on the bi-level optimization of demand response incentives and load reduction capacity, a win–win situation is achieved. Table 4 summarizes the daily load reduction capacities and cost savings of the building cluster and aggregator under the interactive flexibility-engagement scheme. The building cluster can reduce the total electricity costs from 2536.63 to 2489.12 USD, a cost savings of 1.87%. The aggregator can also reduce the cost of purchasing electricity at a high wholesale price. The overall cost savings of the aggregator from interactive flexibility engagement can reach 96.57 USD and increase profits by 8.90% (from 1084.27 to 1181.84 USD).
In addition to the advantages of flexible engagement, the aggregator can benefit from chance-constrained bidding optimization on the wholesale market. However, the costs associated with bidding are influenced by risk acceptance, which is set as a chance constraint. Different bidding strategies can result in deviations between the day-ahead dispatch schedule and real-time power consumption due to the difference between the predicted and actual PV generation. The hourly power deviations for different risk acceptance values are shown in Fig. 11. Blue represents electricity insufficiency, and red represents electricity surplus. These deviations can be mitigated by participating in a real-time market where clearing prices are determined based on actual system operation. In this section, to evaluate the performance of the bidding strategies under various confidence levels (ranging from 50% to 95% quantiles), the electricity supply insufficiency and economic outcomes are compared and presented in Table 5. The total aggregator profits during the five days tested ranged from 1160.12 to 1218.22 USD, depending on the confidence level selected. It was found that a conservative strategy, characterized by a higher acceptable probability or confidence level, can lead to lower total profits during the day-ahead bidding process while reducing the occurrence of supply deficiencies. The aggregator can create a profitable day-ahead schedule under different confidence levels, balancing economic performance and the risk of supply shortages. Fig. 12 shows the dispatch results on July 20 and 23, 2021 at different confidence levels. On July 20, significant fluctuations in renewable energy generation necessitated the use of conservative strategies. By setting a high confidence level of 95%, the model effectively prevents supply shortages and turns the power shortage observed in Fig. 12(a) into a surplus, as shown in Fig. 12(b). Conversely, on July 23, a strategy with a confidence level only a 50% was sufficient to ensure an adequate supply. In such cases, a higher level of risk can sometimes yield greater profits in day-ahead optimization.
The total carbon emissions per hour of the CAISO market are converted into a dynamic carbon emission rate based on the corresponding energy outputs [49], as shown in Fig. 13. To assess the environmental impact of the proposed strategy, the reduction in carbon emissions was calculated considering the self-consumption of PV generation and the demand-side flexibility engagement based on the carbon emission rates. From Table 5, it is evident that the total carbon emissions decrease as the supply insufficiency increases at different confidence levels. A conservative dispatch strategy with a high confidence level causes more carbon emissions as it may underestimate renewable PV generation and result in more electricity being purchased from the wholesale market. By introducing an interactive flexibility engagement scheme, carbon emissions can be reduced by 3% (e.g., from 9136.45 to 8877.69 kg). The proposed dispatch strategy offers qualitative benefits such as greater grid stability and better integration of renewable energy sources.
5.5. Discussion
In this study, the factor representing users’ willingness was not a fixed value and could be negotiated and adjusted for practical applications. Once sufficient historical data is available, it is possible to create the appropriate predictive models to deal with the uncertainty of users’ willingness. User willingness is considered as given information for the aggregator so that it can apply the KKT conditions to solve the bi-level optimization problem. However, if user privacy regarding their willingness to participate in demand response is an important concern, alternative algorithms such as distributed optimization with multiple iterations can be adopted to solve the bi-level optimization problem. These methods can ensure that sensitive user data remains secure and private while still achieving effective optimization.
To adapt the proposed risk-aware optimal dispatch strategy to different application scenarios, it is essential to customize the model based on several key factors. This includes adjusting the forecasting model based on specific historical renewable energy outputs and electricity prices in the wholesale and retail markets, as well as adjusting the aggregator’s risk preferences. By accounting for these factors, the strategy can be effectively tailored to diverse regional contexts to ensure scalability and effectiveness. The proposed methodology focuses on the use of advanced forecasting techniques, bi-level incentive optimization, and robust decision-making to optimize aggregators’ bidding strategies in the day-ahead market. To account for unpredictable changes, real-time monitoring and adaptive control mechanisms also need to be integrated to optimize intra-day dispatch. This may include dynamic adjustment of demand response incentives and storage charging/discharging rates based on real-time conditions. The development of a real-time framework for optimization control will be a key focus of future work.
6. Conclusions
Resource aggregators play a crucial role in the transition to more flexible and sustainable energy systems. In this study, a risk-aware optimal dispatch strategy was proposed to account for the uncertainties associated with renewable energy output and leverage building energy flexibility for the sustainable and economical functioning of resource aggregators. Based on the test results, the main conclusions can be summarized as follows:
(1) Both the resource aggregator and building cluster can benefit from the interactive flexibility engagement scheme, with cost savings of 8.90% and 1.87%, respectively. A win–win situation can be achieved based on the bi-level optimization of demand response incentives and load reduction capacity.
(2) The prediction results show the effectiveness of the NGBoost algorithm in capturing the uncertain nature of PV generation. Probabilistic predictions with confidence intervals comprehensively represent the uncertainty and enable the aggregator to make more robust and risk-aware decisions.
(3) The proposed dispatch strategy allows the aggregator to maximize profits from electricity transactions between wholesale and retail markets and strike an appropriate balance between economic performance and the risk of supply shortages. Carbon emissions can be reduced by 3% through the use of an interactive flexibility engagement scheme.
The proposed dispatch strategy remains applicable even in future scenarios where the carbon trading market or business models associated with carbon emission factors are expected to become sufficiently mature.
The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.
Acknowledgments
The research presented in this study was financially supported by the Collaborative Research Fund (C5018-20GF) of the Research Grant Council (RGC) of Hong Kong Special Administrative Region, and the Shenzhen Science and Technology Innovation Commission Grant (KCXST20221021111203007).
ChenZ, ChenY, HeR, LiuJ, GaoM, ZhangL.Multi-objective residential load scheduling approach for demand response in smart grid.Sustain Cities Soc2022; 76:103530.
[2]
HouP, YangG, HuJ, DouglassPJ, XueY.A distributed transactive energy mechanism for integrating PV and storage prosumers in market operation.Engineering2022; 12:171-182.
[3]
TangH, WangS.A model-based predictive dispatch strategy for unlocking and optimizing the building energy flexibilities of multiple resources in electricity markets of multiple services.Appl Energy2022; 305:117889.
[4]
NorouziM, AghaeiJ, PirouziS, NiknamT, Fotuhi-FiruzabadM.Flexibility pricing of integrated unit of electric spring and EVs parking in microgrids.Energy2022; 239:122080.
[5]
HuJ, ZhouH, ZhouY, ZhangH, NordströmdL, YangG.Flexibility prediction of aggregated electric vehicles and domestic hot water systems in smart grids.Engineering2021; 7(8):1101-1114.
[6]
ZhangX, YuX, YeX, PirouziS.Economic energy management of networked flexi-renewable energy hubs according to uncertainty modeling by the unscented transformation method.Energy2023; 278:128054.
[7]
NorouziM, AghaeiJ, NiknamT, PirouziS, LehtonenM.Bi-level fuzzy stochastic–robust model for flexibility valorizing of renewable networked microgrids.Sustain Energy Grids Netw2022; 31:100684.
[8]
TangH, LiB, ZhangY, PanJ, WangS.A coordinated predictive scheduling and real-time adaptive control for integrated building energy systems with hybrid storage and rooftop PV.Renew Energy2025; 239:122047.
[9]
MitrentsisG, LensH.An interpretable probabilistic model for short-term solar power forecasting using natural gradient boosting.Appl Energy2022; 309:118473.
[10]
HuangQ, WeiS.Improved quantile convolutional neural network with two-stage training for daily-ahead probabilistic forecasting of photovoltaic power.Energy Convers Manage2020; 220:113085.
[11]
RanaM, SethuvenkatramanS, GoldsworthyM.A data-driven approach based on quantile regression forest to forecast cooling load for commercial buildings.Sustain Cities Soc2022; 76:103511.
[12]
TheElectrical & MechanicalServicesDepartment.Hong Kong energy end-use data 2022.Report. HongKong: TheGovernment of theHongKongSpecialAdministrativeRegion; 2022.
[13]
LuoZ, PengJ, CaoJ, YinR, ZouB, TanY, et al.Demand flexibility of residential buildings: definitions, flexible loads, and quantification methods.Engineering2022; 16:123-140.
[14]
TangH, WangS, LiH.Flexibility categorization, sources, capabilities and technologies for energy-flexible and grid-responsive buildings: state-of-the-art and future perspective.Energy2021; 219:119598.
[15]
JiangY, HuangG, YangQ, YanZ, ZhangC.A novel probabilistic wind speed prediction approach using real time refined variational model decomposition and conditional kernel density estimation.Energy Convers Manage2019; 185:758-773.
[16]
HongT, WilsonJ, XieJ.Long term probabilistic load forecasting and normalization with hourly information.IEEE Trans Smart Grid2014; 5(1):456-462.
[17]
XieJ, HongT, LaingT, KangC.On normality assumption in residual simulation for probabilistic load forecasting.IEEE Trans Smart Grid2017; 8(3):1046-1053.
[18]
LiB, ZhangJ.A review on the integration of probabilistic solar forecasting in power systems.Sol Energy2020; 210:68-86.
[19]
AlmeidaMP, MuñozM, deI la Parra, PerpiñánO.Comparative study of PV power forecast using parametric and nonparametric PV models.Sol Energy2017; 155:854-866.
[20]
BozorgM, BracaleA, CarpitaM, DeP Falco, MottolaF, ProtoD.Bayesian bootstrapping in real-time probabilistic photovoltaic power forecasting.Sol Energy2021; 225:577-590.
[21]
WuYK, SuPE, WuTY, HongJS, HassanMY.Probabilistic wind-power forecasting using weather ensemble models.IEEE Trans Ind Appl2018; 54(6):5609-5620.
[22]
PengW, GaoJ, ChenY, WangS.Bridging data barriers among participants: assessing the potential of geoenergy through federated learning.Appl Energy2024; 367:123293.
[23]
NiQ, ZhuangS, ShengH, KangG, XiaoJ.An ensemble prediction intervals approach for short-term PV power forecasting.Sol Energy2017; 155:1072-1083.
[24]
ZhangC, WeiHK, ZhaoX, LiuTH, ZhangKJ.A Gaussian process regression based hybrid approach for short-term wind speed prediction.Energy Convers Manage2016; 126:1084-1092.
[25]
WangS, SunY, ZhangS, ZhouY, HouD, WangJ.Very short-term probabilistic prediction of PV based on multi-period error distribution.Electr Power Syst Res2023; 214:108817.
[26]
AlHakeemD, MandalP, HaqueAU, YonaA, SenjyuT, TsengTL.A new strategy to quantify uncertainties of wavelet–GRNN–PSO based solar PV power forecasts using bootstrap confidence intervals.In: Proceedings of the 2015 IEEEPower & EnergySocietyGeneralMeeting; 2015 Jul 26–30; Denver, CO, USA. NewYorkCity: IEEE; 2015. p. 1–5.
[27]
LiuL, ZhaoY, ChangD, XieJ, MaZ, SunQ, et al.Prediction of short-term PV power output and uncertainty analysis.Appl Energy2018; 228:700-711.
[28]
BessaRJ, TrindadeA, SilvaCSP, MirandaV.Probabilistic solar power forecasting in smart grids using distributed information.Int J Electr Power Energy Syst2015; 72:16-23.
[29]
ChenZ, ZhangJ, XiaoF, MadsenH, XuK.Probabilistic machine learning for enhanced chiller sequencing: a risk-based control strategy.EnergyBuiltEnviron. 2024. In press.
[30]
PirouziS.Network-constrained unit commitment-based virtual power plant model in the day-ahead market according to energy management strategy.IET Gener Transm Distrib2023; 17(22):4958-4974.
[31]
Rashidizadeh-KermaniH, Vahedipour-DahraieM, Shafie-KhahM, SianoP.A regret-based stochastic bi-level framework for scheduling of DR aggregator under uncertainties.IEEE Trans Smart Grid2020; 11(4):3171-3184.
[32]
GuoZ, PinsonP, ChenS, YangQ, YangZ.Chance-constrained peer-to-peer joint energy and reserve market considering renewable generation uncertainty.IEEE Trans Smart Grid2021; 12(1):798-809.
[33]
WangY, ZhengY, YangQ.Day-ahead bidding strategy of regional integrated energy systems considering multiple uncertainties in electricity markets.Appl Energy2023; 348:121511.
[34]
KohansalM, Mohsenian-RadH.Price-maker economic bidding in two-settlement pool-based markets: the case of time-shiftable loads.IEEE Trans Power Syst2016; 31(1):695-705.
[35]
ChaiY, XiangY, LiuJ, GuC, ZhangW, XuW.Incentive-based demand response model for maximizing benefits of electricity retailers.J Mod Power Syst Clean Energy2019; 7(6):1644-1650.
[36]
LiY, HanM, YangZ, LiG.Coordinating flexible demand response and renewable uncertainties for scheduling of community integrated energy systems with an electric vehicle charging station: a bi-level approach.IEEE Trans Sustain Energy2021; 12(4):2321-2331.
[37]
YuWANG, KeLI, ShuzhenLI, XinMA, ChenghuiZHANG.A bi-level scheduling strategy for integrated energy systems considering integrated demand response and energy storage co-optimization.J Energy Storage2023; 66:107508.
[38]
NwuluNI, XiaXH.Multi-objective dynamic economic emission dispatch of electric power generation integrated with game theory based demand response programs.Energy Convers Manage2015; 89:963-974.
[39]
DengT, YanW, NojavanS, JermsittiparsertK.Risk evaluation and retail electricity pricing using downside risk constraints method.Energy2020; 192:116672.
[40]
YuR, YangW, RahardjaS.A statistical demand-price model with its application in optimal real-time price.IEEE Trans Smart Grid2012; 3(4):1734-1742.
[41]
DaiM, LiH, WangS.Event-driven demand response control of air-conditioning to enable grid-responsive buildings.Autom Construct2023; 150:104815.
[42]
WangH, WangS.A disturbance compensation enhanced control strategy of HVAC systems for improved building indoor environment control when providing power grid frequency regulation.Renew Energy2021; 169:1330-1342.
[43]
TangH, WangS.Multi-level optimal dispatch strategy and profit-sharing mechanism for unlocking energy flexibilities of non-residential building clusters in electricity markets of multiple flexibility services.Renew Energy2022; 201:35-45.
[44]
XueX, WangS, SunY, XiaoF.An interactive building power demand management strategy for facilitating smart grid optimization.Appl Energy2014; 116:297-310.
[45]
TangR, LiH, WangS.A game theory-based decentralized control strategy for power demand management of building cluster using thermal mass and energy storage.Appl Energy2019; 242:809-820.
[46]
DuanT, AnandA, DingDY, ThaiKK, BasuS, NgA, et al.NGBoost: natural gradient boosting for probabilistic prediction.In: Proceedings of the 37thInternationalConference onMachineLearning, PMLR; 2020 Jul 13–18; online conference. Vienna: InternationalConference onMachineLearning (ICML); 2020. p. 2690–700.
[47]
TangH, WangSW.Game-theoretic optimization of demand-side flexibility engagement considering the perspectives of different stakeholders and multiple flexibility services.Appl Energy2023; 332:120550.
[48]
BlairN, DobosAP, FreemanJ, NeisesT, WagnerM, FergusonT, et al.System advisor model, SAM 2014.1.14: general description. Report. Springfield: NationalRenewableEnergyLab., Golden, CO, USA; 2014.
[49]
CaliforniaIndependentSystemOperator (ISO).CAISO CO2 emissions (serving ISO load) [Internet].Folsom: California Independent System Operator; [cited 2024 Nov 20]. Available from: https://www.caiso.com/TodaysOutlook/Pages/emissions.html.