Optimal Cluster Scheduling of Active–Reactive Power for Distribution Network Considering Aggregated Flexibility of Heterogeneous Building-Integrated DERs

.


Relevant Background
The construction sector is the third-largest energy consumer, accounting for 33% of global energy demand and 16% of global CO2 emissions in 2022 [1].Considering the growing tendency of urbanization progress and the continuous development of the power industry, the proportion of construction energy consumption is expected to increase by 40% in 2030 and even 50% in 2050 [2].The aggregation of flexible DERs in buildings is recognized as a promising alternative method to reduce CO2 emissions and energy consumption, promoting the profound integration of distributed energy resources (DERs) and building energy supply [3].Smart-building systems equipped with power-access points could achieve flexible resource aggregation and exploit the regulation capacity of these resources sufficiently, intensifying the interdependency between buildings and electricity networks [3,4].Nevertheless, the location of building-integrated photovoltaics (BIPVs), building-integrated electric vehicles (BIEVs), building-integrated energy storage (BIES), building-integrated temperature-controlled load (BITC), and other types of comprehensive energy production and storage equipment in smart-building systems are generally scattered, resulting in the high complexity of centralized optimization scheduling due to the lack of information exchange and energy interaction [4][5][6].Consequently, the optimization scheduling of a distribution network with cluster division for flexible resources integrated into smart-building systems would be ideal for the high-penetrated deployment of DERs to meet carbon-neutral targets.
One typical method studied in [7] for cluster optimization scheduling is to use the second-order neighborhood similarity matrix and modular matrix to extract relatively more comprehensive complex network feature information for network division.Another example is a chromosome-encoding method considering the modular index based on the electrical design to satisfy the demand of distribution network programmers [8].In further research, a K-means clustering algorithm based on the variation sensitivity of voltage to power between nodes to solve the voltage overlimit and voltage fluctuations is used [9].Moreover, to tackle difficulties in uncertainty and centralized control, a multi-time rolling dynamic cluster division method with the equilibrium degree of reactive power for active distribution networks was developed [10].However, the cluster division in these studies only involves a single index without considering comprehensive indexes, including flexibility regulation capacity and electrical connection.In addition, the active-reactive power collaborative optimization scheduling of distribution networks is acknowledged as an effective strategy for handling the uncertainties from dispersive DERs.A method for the coordinated optimal operation scheduling of active distribution networks was developed to meet the electricity demand of the building itself with interconnected electric vehicles and integrated RESs [11].To implement optimal power dispatch and significantly reduce the overall operation cost of the microgrid, a method for optimal energy and power management of microgrids consisting of mega buildings, plug-in electric vehicles (PEVs), and renewable energy sources (RESs) was designed [12].Furthermore, an energy management system (EMS) for microgrids of building prosumers based on a hierarchical multi-agent system (MAS) was studied in [13] to minimize the operation cost of a microgrid, considering many operation and technical constraints.
Integration and quantification for the regulation capacity of flexible resources are regarded as effective means to take advantage of the flexibility of smart-building systems [4,[14][15][16][17][18].Several important investigations have been reported on the virtual battery model [14], virtual synchronous machine model [15], flexible supply-and-demand balance model [16], and node power model [17] for the aggregation of flexible resources.A generic and scalable approach considering zonotopic sets for flexible energy systems was studied in [18] to describe their flexibility quantitatively.The authors use a constraint space-superposition method based on Minkowski Sum to seek the maximal inner cube constraints for the virtual synchronous machine of a heat pump cluster [19].Moreover, the authors in [20] developed a day-ahead optimal scheduling model based on the generalized virtual battery model to determine the energy schedule and reserve capacity of electric vehicles and air conditioning.Additionally, a flexibility assessment can represent the abundance of flexible resources in a distribution network and has been comprehensively investigated with the insufficient ramping resource expectation index [21], the network flexibility index [22], the technical uncertain scenario flexibility index [23], and the technical-economic uncertainty scenario flexibility index [24].A quantitative assessment method for power system flexibility based on probabilistic optimal power flow was developed to improve system flexibility and operating economy [21,22].The authors in [23] studied a new distribution system flexibility evaluation method based on cloud models to address the difficulty in fully characterizing the flexibility status of a system.Furthermore, to quantify the transmission capacity of power grids and effectively improve the flexibility of power systems, an evaluation method of supply-and-demand balance considering flexible carrying capacity was studied in [24].However, the comprehensive effect of the indexes on the flexibility state of the system is usually neglected in these studies.
Aggregation techniques, such as the k-order approximate model [25], the multi-timescale approximate model [26], the real-time aggregation flexibility feedback method [27], and the Minkowski Sum [19] have been exploited to simplify the constraints of the aggregation feasible domains and realize the flexibility of the system.The authors studied a virtual power plant aggregation and operation mechanism to effectively guarantee the stability of the aggregation results [14].An adaptive and robust optimization algorithm was adopted to accurately quantify the maximum power support range of the heat grid to the power grid [17].After the aggregation of the flexible resources, the coordination and optimization of the distribution network with cluster division based on the flexible resources in the smart-building system can be achieved.Nevertheless, the potential active and reactive power support capacitates from the clusters of building-integrated flexible DERs for distribution networks are not involved.

Contribution
In this paper, an active-reactive power collaborative scheduling model with cluster division is proposed for the flexible DERs of smart-building systems to resolve the high complexity of centralized optimal scheduling for massively dispersed DERs in the distribution network.The detailed contributions of this paper are summarized as follows: 1.The customized virtual battery models are developed for building-integrated flexible DERs to aggregate the power characteristics while quantifying the operation and regulation capacity with the time-shifting energy state, the energy boundary, and the power boundary.A constrained space-superposition method with Minkowski Sum is exploited to derive the summation of the regulation capacity of building-integrated flexible DERs. 2. A cluster division algorithm considering the structural and functional cluster division indexes for the building-integrated flexible DERs is proposed to automatically divide the distribution network with a high proportion of renewable energy and flexible DERs into the optimal clusters.The structural cluster division index refers to the module degree index based on the electrical distance, which can ensure the close electrical connection of the nodes within the clusters, and the functional cluster division index represents the flexible balance contribution index, measuring the matching degree between the distributed power consumption demands and the supply of building-integrated flexible DERs.3.An optimal active-reactive power collaborative scheduling model for the clusters of building-integrated flexible DERs is formulated to minimize the operational cost, the power-loss cost, and the penalty cost for flexibility deficiency, in which the secondorder cone-based branch flow method is exploited to decompose the nonlinearity and nonconvexity of the power-flow equation and the nodal voltage magnitude constraint into the linearized cone model by introducing the intermediate variable.

Smart-Building System
Figure 1 depicts the typical modality of a smart-building system among a highly renewable-penetrated distribution network.The smart-building system is generally equipped with cogeneration systems, distributed photovoltaics, electric vehicles, heat pumps, and energy storage to satisfy the demand for electricity and the cold and heat load in the building [5].To fully utilize the space and time flexibility of building-integrated flexible DERs, the establishment of a virtual battery model for flexible DERs is necessary, which can quantify and integrate the flexibility and regulation capacity of these resources.

Battery Model of ES in a Smart-Building System
BIES can transfer the electricity generated by BIPVs to balance the energy of the power system, improving the reliability of system operation and power supply quality.A battery model of ES in a smart-building system (1), consisting of charge power constraints, discharge power constraints, and energy state constraints, is developed to describe the operating characteristic mathematically:  is the effect of other factors on the electric energy of the VB model.

VB Model of EV in a Smart-Building System
In general, the power battery of BIEV can achieve power interaction with the grid through flexibly switching between charging, placing, and discharging states.The gridconnected operation status of BIEV is illustrated in Figure 2, where BIEV with an initial operating capacity of  , 0 EV are connected to the grid with the maximum charge and discharge power of  ch,,,max EV and  dis,,,max EV at time  0 , reaching the expected operating capacity of  , EV when off the grid at time  1 .Thus, the virtual battery model of BIEV can be formulated as follows:

VB Model of TCL in a Smart-Building System
The equivalent thermal parameter model is adopted to describe the thermal dynamics characteristics of TCL, which equates the internal environment, external environment, and heating (cooling) capacity to circuit devices to analyze the dynamic change relationship of the indoor temperature and power [28,29].As illustrated in Figure 3, the heating capacity  , 1 of the temperature control load can be defined as the sum of the heat absorbed by the room  , 2 and the air convection heat  , 3 .(1d) shows that the energy of the BIES is equal to the superposition of the energy in the past state, the storage energy, and the release energy in the current state.Similarly, the indoor temperature  in,, TCL of the TCL is equal to the summation of the indoor temperature in the past state, warming, and cooling in the current state.When ambient temperature  out,, TCL is higher than indoor temperature, the temperature of the heating equipment  heat,, TCL and the ambient temperature together transfers the heat quantity from high temperature to low temperature, increasing indoor temperature and the energy of the VB model.On the contrary, when the indoor temperature is higher in the summer, the cooling capacity of TCL works to reduce the indoor temperature, which is equivalent to the decrease in the energy of the VB model, as follows:

Cluster Division Index of Building-Integrated Flexible DERs
Structural and functional cluster division indexes of building-integrated flexible DERs are designed for a distribution network with a high penetration of renewable energy to achieve independent autonomy within clusters and coordinated interaction among clusters.To ensure the close electrical connection of nodes within the clusters, the module degree index based on electrical distance is adopted to describe the connection strength of nodes in the structure [8].The functional index refers to the flexible balance contribution index, which can evaluate the regulation capacity of building-integrated flexible DERs to ensure the power balance under a high penetration rate of distributed energy access.

Module Degree Index
Generally, electrical distance   is exploited to measure the tightness of electrical coupling between nodes in the distribution network based on the sensitivity relationship of node power variation and node voltage [8], and thus the module degree index  for the cluster division structure strength of complex networks is formulated as follows: where   , , and   denote the edge weight connecting node  and , the sum of the edge weight in the network, and the edge weight connecting node ; (, ), a 0-1 variable, equals 1 if Node 1 and Node 2 are in the same cluster.Since there is a coupling relationship between the two nodes and the surrounding nodes,   can be formulated with the combined effect   of the power change in node  and  as shown in (8c) and (8d);  ,max is the maximum threshold of electrical distance; (8e) indicates the sensitivity relationship between node voltage and node-injected power; ∆, ∆, and ∆ are the variation of voltage amplitude, active power, and reactive power;   and   are the sensitivity matrix of voltage-active power and voltage-reactive power.

Flexible Balance Contribution Index
The regulation capacity of building-integrated flexible DERs refers to the flexible energy supply capacity required to satisfy the flexible demands of net load in smart-building systems, which can be divided into upgraded flexible energy supply capacity and downgraded flexible energy supply capacity.The flexible balance contribution index  can measure the matching degree between distributed power consumption demands and the supply of the building-integrated flexible DERs by calculating the equilibrium proportion of flexible DERs bearing node flexibility demands at a certain moment as follows: ,up ,dn ,, where  , ,up and  , ,dn denote the upgraded and downgraded flexible balance contribution degree.(9c) represents the flexible demands of net load in smart-building systems, deriving from the difference between load demands  , Load and BIPV generation.
Then, the cluster division index  of building-integrated flexible DERs considering the module degree index and the flexible balance contribution index with different weights  1 and  2 can be calculated from Formulas (8a) and (9a), The critical procedures of the cluster division process of building-integrated flexible DERs are summarized as follows: 1.Each node in the distribution network is regarded as a separate cluster initially to calculate the cluster division index  of building-integrated flexible DERs based on Formula (10); 2. Node  is randomly selected from the remaining nodes to merge with node , forming a new cluster (, ) , and then the variation of the cluster division index ∆ =  ′ −  can be derived from the division index of cluster (, ) .When ∆ reaches the maximum positive value, the two nodes can be divided into the same cluster; 3. The new cluster (, ) will be regarded as a new node to repeat the second procedure.The division procedures will continue until the nodes in the network cannot merge and the cluster division index  of building-integrated flexible DERs reaches the maximum.

Optimization Objective
The active-reactive power collaborative optimization scheduling within clusters can be formulated as a multi-object optimization model based on the flexibility of buildingintegrated flexible DERs, while the uncertainties in PV outputs, ES performance, EV parking behaviors, TCL heating/cooling behaviors, and SVC regulation capacity are considered and represented by various stochastic scenarios based on historical data in [3,30,31].Specifically, each cluster  aims to minimize operational cost   1 , power-loss cost   2 , and penalty cost for flexibility deficiency   3 , as shown in (11a), (12), and (13a).  1 is composed of the maintenance cost  ,,, PV of BIPVs due to the renewable generation curtailment, the lifetime degradation cost  ,,, ES of BIESs, the compensation cost  ,,, CL of BIEVs and BITCs stemmed from power regulation and the operation cost  ,,, SVC of static var compensator (SVC) under scenario .  2 can be derived from the power-flow calculation during the scheduling circulation, where  ,,, ,  ,,, ,  ,,, , and  ,, represent the nodal voltage magnitudes, the conductance, the susceptance, and the phase angle of line  at time  within cluster  under scenario  ;  , Loss is the compensation price of the network loss.The penalty cost   3 for the flexibility deficiency is introduced when the flexibility supply cannot satisfy the load demands within the clusters, including upgraded flexibility deficiency  ,, defi,up and downgraded flexibility deficiency  ,, defi,dn under scenario , as follows: , , ) , , ( where Ω PV , Ω ES , Ω CL , and Ω SVG are the node sets of BIPV, BIES, BIEV, BITC, and SVC;   and  indicate the -th distributed resource cluster and the total number of divided clusters;   is the number of scenarios for stochastic optimization;   is the probability of scenario , and the sum of probabilities for all scenarios is equal to 1. Due to the uncertainties in the balancing market prices, the unit operation prices Considering operational cost, power-loss cost, and penalty cost for flexibility deficiency comprehensively, the multi-objective function with different weights  1 ,  2 , and  3 can be represented as

Operation Constraints
The Newton-Raphson method is adopted to describe power flows within the clusters, as shown in (15a).Constraint (15b) represents the active and reactive power balance at each bus, and constraint (15c) imposes the upper and lower limits on the nodal voltage magnitudes,  ,,,max and  ,,,min . (

i t s k i t s k i t s k i t s k i t s k i t s k i t s k i t s k i t s k i t s
The power output curtailment of BIPV is supposed to be lower than the specified maximum thresholds of active and reactive power, Δ ,,,max PV and Δ ,,,max PV .Moreover, the sufficient power factor cos  under scenario  for the operation of a photovoltaic inverter is needed to limit the reactive power circulation, where the amount of reactive power injected or absorbed is constrained by the bounds in (16a) and (16b), PV PV , , , , , ,max 0 Also, the states of reactive power of SVC should be constrained within their lower and upper bounds  ,,,min SVC and  ,,,max SVC , as follows: In addition, the sum of the regulation capacity of building-integrated flexible DERs based on the constrained space-superposition method with Minkowski Sum ⨁ can be expressed as Formula (18a), and the state of the total sum of the regulation capacity

Solution Methodology
Due to the nonlinearity and nonconvexity of the power-flow equations increasing the heavy computation burden of the optimization model, the second-order cone-based branch flow method is exploited to decompose this challenging problem into the linearized cone model by introducing intermediate variable  ,,, ,  ,,, , and  ,,, under scenario  and rotary cone constraint, as shown in (19).
Then, the power-loss cost function (12a), the power-flow Equation (15a), and the nodal voltage magnitudes constraint (15c) can be reformulated as follows: , ) ) When solving the mixed-integer second-order cone programming, a polyhedral approximate description of the second-order cone relaxation is exploited to describe formula (19d), and the original problem with a non-convex feasible domain is relaxed into a convex second-order cone-feasible domain using second-order cone relaxation, which can be solved quickly and effectively using a common solver, as follows: As depicted in Figure 4, assuming that all feasible solutions of the non-convex feasible domain are on the second-order cone plane, the feasible domain is enlarged to convex cones after relaxation.Therefore, the solution within both the convex second-order cone and the original feasible domain is the optimal solution to the original problem.In conclusion, the flowchart of the active-reactive power collaborative scheduling model with cluster division is shown in Figure 5.

System Data
The proposed active-reactive power collaborative optimization scheduling model with cluster division is tested on a modified IEEE 33-bus distribution system, as depicted in Figure 6.The installed capacities of BIPVs in nodes 1, 6, 13, 17, 18, 24, and 29 are set as 0.5 MW, 1.0 MW, 0.2 MW, 1.5 MW, 0.8 MW, 1.2 MW, and 0.4 MW to simulate the diverse PV endowments.The predicted energy outputs of BIPVs derived from the actual values in [6,30,31], as well as the estimated 24 h loads from [32,33], are utilized to generate possible scenarios.The random operation scenario is exploited to represent the uncertainty of PV output, ES performance, EV behavior, and TCL heating/cooling behaviors [34].The initial random scenario tree has 5000 scenarios, and a scenario-reduction method is applied to decrease the number of scenarios to 50 to maintain the uncertainty approximation of the system while accelerating the calculation speed of the stochastic model.The prediction errors of BIPV generation and node load follow Gaussian distributions with zero means and a 10% standard deviation of the prediction values [31,32,35].The detailed technical specifications of the building-integrated equipment and the network are summarized in Table 1 [3,4,35].
The appropriate weights for the cluster division index of building-integrated DERs and the multi-object function are set as 0.41, 0.29, 0.63, 0.48, and 0.25 after many simulation tests.The optimization scheduling of the distribution network with cluster division for flexible DERs integrated into a smart-building system is implemented on an hourly basis over a 24 h horizon and solved by the CPLEX Optimizer on the MATLAB platform. of forecasting results.Based on the sampling of forecasting errors on PV output, ES performance, EV behaviors, TCL heating/cooling behaviors, and electric load, a set of scenarios can be formed through Monte Carlo simulations.Taking the PV output at node 24 as an example, it can be found from Figure 7a that the initial random scenario is densely distributed around the predicted values.After the removal of similar scenarios by the scenario-reduction method, the scenarios retaining essential properties of the initial scenarios can be depicted in Figure 7b.

Comparative Results and Analysis
Three comparative schemes are performed for in-depth analysis of the effectiveness of the proposed methodology.
1. Scheme 1 performs the proposed optimization scheduling of the distribution network with cluster division for flexible DERs integrated into smart-building systems in Section 3. 2. Scheme 2 adopts the centralized optimization scheduling of the distribution network without considering the cluster division.
3. Scheme 3 is the initial distribution network before the optimization scheduling.

Cluster Division of Building-Integrated Flexible DERs
Considering the differences in node-voltage amplitude, power injection, and load demands at different times, the detailed data of each node at noon is exploited for cluster division.Figure 8 depicts the function curves for the cluster division index of buildingintegrated DERs corresponding to the number of different clusters.It can be found that the index function achieves the maximum value  = 0.92 when the number of clusters is divided into 6.Therefore, the result of the optimal cluster division at  = 6 is shown in Figure 9.

Flexible Regulation Capacity Results of Building-Integrated Flexible DERs
Figure 10 illustrates the flexible regulation capacity of building-integrated flexible DERs based on the flexibility constraint space superimposed by Minkowski Sum.It can be observed from Figure 10 that the self-consistent rate is allowed to reflect the contribution of different flexibility resources to the flexibility balance of the power grid.For instance, the flexibility power region of building-integrated flexible DERs in Cluster 2 is larger than that of Cluster 1.In addition, the sum of the total amount of BIPV generation and the regulation capacity of building-integrated flexible DERs can satisfy the total load demands within Cluster 2, indicating that Cluster 2 achieves complete self-consistency of active power.On the contrary, the total load demands within Cluster 1 are greater than the sum of the total amount of BIPV generation and the regulation capacity of buildingintegrated flexible DERs at time  = 4 and  = 20, thus giving rise to flexibility power deficiency.The power-loss and the node-voltage amplitude with Schemes 1-3 are illustrated in Figure 11, where the node-voltage at noon is selected for analysis since the generation of BIPVs reaches the peak at that time.It can be found that the optimized system power loss with Scheme 1 is lower than that with Scheme 2 due to the comprehensive scheduling of the BIPV generation and the regulation capacity of building-integrated flexible DERs within clusters.In addition, the voltage-regulation effect of the centralized active power-reactive power cooperative optimization of the distribution network is unsatisfactory, maintaining the node voltage over the limit.However, since building-integrated flexible DERs are involved in the cluster power regulation, the node-voltage amplitude with Scheme 1 is within the specified range.Table 2 summarizes the statistical data of comparative economic performance results with Schemes 1 and 2, including the total cost, the operational cost, the power-loss cost, and the flexibility deficiency cost.Compared to Scheme 2, Scheme 1, considering the flexibility of building-integrated flexible DERs, can better estimate the flexibility regulation capacity, and thus, the operational cost and flexibility deficiency cost can be reduced by 11.69% and 9.21%, respectively.Consequently, Scheme 1 outperforms Schemes 2 and 3 on the economic merits and voltage regulation.

Conclusions
In this paper, an optimal active-reactive power collaborative scheduling model for building flexible DER clusters is proposed to resolve the uncertainties from the renewable energy in the distribution network.The key findings of this study are as follows: (1) The developed cluster division algorithm considering structural and functional indexes can achieve independent autonomy within clusters and coordinated interaction among clusters, contributing to decreasing the whole network loss; (2) Since the customized virtual battery models integrate and quantify the regulation capacity of flexible resources, the flexibility deficiency cost can be reduced by 9.21%; (3) The developed optimal active-reactive power collaborative scheduling model can achieve a better performance in economic merits and voltage regulation than the centralized optimization scheduling of a distribution network without considering the cluster division, whose operational cost can be decreased by 11.69%.In this article, the building-integrated flexible DERs, including BIES, BIEV, and BITC, were acknowledged as the resources on the demand side.

Figure 1 .
Figure 1.Typical modalities of a smart-building system.

Figure 2 .
Figure 2. VB model and the grid-connected operation status of BIEV.

Figure 3 .
Figure 3. VB model principle of TCL in a smart-building system.

Figure 7 .
Figure 7. Scenario generation and reduction results of PV outputs at node 24: (a) initial scenarios; (b) reduced scenarios.

Figure 8 .
Figure 8. Building-integrated resource cluster division index function curves.

Figure 9 .
Figure 9. Optimal cluster division result for the distribution network with building-integrated flexible DERs.

Figure 11 .
Figure 11.Comparative results with Schemes 1-3.(a) The 24 h network loss; (b) The node voltage at noon.
ch EV and  dis EV are the charge and discharge efficiency coefficients of BIEV.(4c) and (4d) represent the boundary of operation capacity and the operation state.Then, considering that the power boundary  ,,max EV and  ,,min EVof BIEV are affected by the operation capacity, the upgraded flexible energy supply  , EV,sup,up and the downgraded flexible energy supply  , EV,sup,dn of EV in a smart-building system can be ex- where  ch,,,min EV and  dis,,,min EV are the minimum thresholds of the charging and discharging power of BIEV connected at node  and time ;  ch,, EV ,  dis,, EV ,  , EV , and  , EV denote 0 t 1 t the charging power, discharging power, actual power, and operation capacity; and  2 are the heat-dissipation area of BITC connected at node  and time  and the wall;  TCL ,  Wall , and  COP denote the heating efficiency, wall surface thermal radiation rate, and energy conversion efficiency; , , and  are the indoor air density, air heat capacity, and room volume.(6b)and (6c) represent the boundary of actual power and indoor temperature, where  base and  are the indoor temperature baseline and the dead zone value, respectively.The upgraded flexible energy supply  , TCL,sup,up and the downgraded flexible energy supply  , TCL,sup,dn of TCL in smart-building systems can be expressed as VB model of ES, EV, TCL in the smart building system End Figure 5. Flowchart of the proposed method.

Table 1 .
Technical specifications of building-integrated equipment and distribution network.For the uncertainty problem in the active-reactive power collaborative optimization scheduling within clusters, multiple possible scenarios are derived from the basis values

Table 2 .
Comparative economic performance results.
Further Authors Yu Fu, Shuqing Hao, Junhao Zhang and Liwen Yu were employed by Guizhou Power Grid Co., Ltd.The remaining authors declare that the research was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.The nodal voltage magnitudes connected at node  and time  within cluster  under scenario  (, )A 0-1 variable equals 1 if Node 1 and Node 2 are in the same cluster  1 ,  2 The module degree index and the flexible balance contribution index, respectively  ,, ,  ,, ,  ,, Actual power of BIES, BIEV, BITC, load demands connected at node  and time  within cluster  under scenario   1 ,  2 ,  3 Weighting factor  ,,, SVC ,  ,,, ES ,  ,,, EV Reactive power output of SVC, BIES, and BIEV connected at node  and time  within cluster  under scenario   ,,,max ,  ,,,min dnFlexibility margin of the negative value connected at node  and time  within cluster  under scenario