Heuristic approach for transactive energy management in active distribution systems

The advent of distributed energy resources (DERs), which include small conventional and renewable generation units, energy storage, and flexible loads in distribution network needs distributed coordination for effective management. In this paper, a stochastic transactive management framework is proposed to minimize overall cost and avoid network constraints violation at the distribution network level. This framework includes day-ahead scheduling of electric vehicles and air conditioning loads under demand response aggregators (DRAs), and DERs under distributed generation owners (DGOs) into day-ahead wholesale market in a network managed by a distribution network operator (DNO). An agent called distribution independent system operator (DISO) is responsible for coordination among DRAs, DGOs, and DNO. A heuristic step-size update approach is proposed to calculate the Lagrange multiplier iteratively and improve the convergence speed. This framework is modeled as a quadratic constraint programming (QCP) problem and solved using the GAMS solver. Simulation results on a modified 33-bus system with considerable penetration of loads and DERs, shows that the suggested framework can efficiently reduce the iterations to converge and returns an optimal schedule. And demonstrate the effect of network congestion, demand, and generation uncertainties on the resulting objective values of the agents and magnitude of the Lagrange multiplier values.


Background
The integration of stochastic renewable generation sources has an increased need for balancing generation and demand in energy markets. Aggregators having a group of proactive consumers are expected to provide balancing power to the grid by managing their flexibility. Meanwhile, undesirable line congestions and voltage violations may arise in the distribution network, when flexible resources respond to external control or price signals on a large scale [1]. Hence, the development of a useful framework to coordinate flexibility at the distribution system level subject to network limits is of utmost importance [2]. A typical active distribution system consists of few or all of the following agents namely, customers served by retailers and demand response aggregators (DRAs), distributed energy resources (DERs) managed by distributed generation owners (DGOs) and distribution network operator (DNO) and distribution level independent system operator (DISO) [3].
The following are the main issues in the optimal operation of the distribution system due to the inclusion of DERs controlled by multiple agents. The first is how to coordinate these agents with multiple objectives at multiple levels into power system operation and market operation. Second, is how to address fairness in risk management among agents when considering the volatility in price and uncertainties in demand and generation [4]. Third, how to address computational complexity and privacy in centralised frameworks and convergence rate in iterative decentralised frameworks.
There have been some efforts in the literature for addressing these challenges in the collaborative operation of different agents in the active distribution network. They differ in following key aspects whether the agent is a price maker or a price taker, whether network constraints are taken into account or not, whether uncertainty is considered or not, whether the control is centralised [5,6], distributed [7], peer-to-peer [8], and transactive energy (TE) approach [9]. We divided the related works into multiple themes. The first theme is concerned with coordination among the agents. Retailer's price maker bidding of customers flexible demand into the day-ahead (DA) electricity market is addressed as centralised [10] and decentralised mechanisms in [11,12]. A single leader and multi-follower type bi-level model proposed in [13] to obtain trading strategies between proactive distribution company and DGOs and procure remaining demand requirement from the wholesale market and did not consider flexible demand bidding. Stratification of demand into service priorities based on traffic light concept applied to the flexibility services and customers [2]. TE management approaches based on distribution locational marginal prices (DLMPs) approaches or their underlying components are being explored recently as they enforce the interconnected constraints implicitly through price signal. Since LMPs (locational marginal prices) plays a vital role in the coordinated operation of power systems and electricity markets, and form a link between wholesale market/transmission grid and retail electricity market/distribution grid as discussed in [14] through hierarchical LMP concept. Similarly interaction of interconnected microgrids through zonal LMP is suggested in [15]. Li et al. [16] developed a Nash bargaining theory to model the TET framework which considers network loss allocation and develops a closed-form solution. Auction-based electricity market to balance DR and DERs in a microgrid in [9], however, this work overlooks the impact of trading on network congestion. Authors in [3] proposed a TE management system (TEMS) for managing constrained grids where DNO and retailers negotiate to meet network constraints through congestion price generated by the third party known as DISO. Here, Lagrange multiplier (LM) at each bus is equivalent of congestion price in DLMP, and DISO iteratively updates the price signal to coordinate among agents reasonably. However, the proposed approach does not consider distributed renewable generation and its uncertainties. It is to be noted here that, the distribution tariff increases without TE owing to the expenses in upgrading the network, which will eventually be passed on to end customers with an enhanced bill. For both DNO and end consumers, this scenario is neither beneficial nor efficient. Whereas in TEMS, the tariff is dynamic, and the congestion level can be prevented or reduced to minimise the overall cost further. The works in [17] presents a multi-agent TEMS based on oligopoly competition model to control demand and supply to minimise customers cost, and regulate voltage in the presence of high levels of renewable generation and EVs penetration.
The second theme is concerned with computational complexity and scalability. A neurodynamic algorithm is proposed in [18] instead of optimisation to derive the bidding curve in real-time (RT) based on historical data, but the algorithm yields less accurate solutions if there is a considerable variation in magnitude of parameters. Nature inspired meta heuristics are used in [19,20] to reduce communication overhead which reduces computational efforts. Multi-agent transactive control is an emerging technique for its ability to increase system scalability, autonomy, and resiliency. They reduce the levelled cost of energy for each node. We discussed related works based on the type of trading and proactive customers considered, i.e. whether peer-to-peer/intra microgrid [21,22] peer-to microgrid, microgird-microgrid [9,15] and microgrid-to-utility grid [19]. A multi-level TE approach for multi-micro gird is proposed in [23] where sharing priority is based on a heuristic approach. In this Liu et al. [15] proposed a novel sub-gradient based TEMS approach for coordinated operation of networked microgrids in a distribution network.
The third theme is concerned with the uncertainties of renewable generation and DR flexibility forecasts, which puts system balance at risk and needs more reserve requirements, particularly when DISO has no access to historical data. Authors in [4,24] proposed risk constrained decentralised algorithms for renewable energy integration and demand response integration, respectively. A new point estimate base stochastic method is proposed in [25] to estimate LMP. Liu et al. [26] implemented modified Harr's two-point estimation method to study the effect of correlation between renewable distributed generation and load uncertainties on probabilistic optimal power flow approach and it can estimate the mean and variance of the scheduling solutions compared to Monte Carlo simulation. The authors in [27] proposed a stochastic receding horizon control to handle the uncertainties in real time optimal operation of network. A chance constrained optimal power flow model is proposed in [28] which can handle the stochastic characteristics of electric vehicle (EV) load on voltage regulation. A stochastic decision making model for price setting by retailer under intermittent DER and DR is proposed in [29] but network constraints are not considered here.

Motivation
To best of our knowledge, a detailed TE optimisation mechanism for the overall social cost minimisation and integration of stochastic demand and DERs into the market under network congestion has not been studied extensively in the literature. When compared with other distributed algorithms, the TE mechanism does not require partial derivatives and can lower computational time by selecting suitable step-size heuristically in updating LMs. Further, multiple roles of DISO needs to be redefined on how to handle network congestion, competition, and risk aversion between DGOs, DRAs, and customers in a fair manner. In this paper, we aim to address the impact of high penetration of stochastic renewable generation and demand on obtained LMs/congestion price for enforcing network constraints. And suggest a heuristic approach to update the LMs to improve the convergence speed.

Contributions
Building forth on the previously developed network constrained TE (NCTE) framework in [3,30], this work develops a stochastic operational framework to enable the participation of DRAs and DGOs located in distribution network managed by DNO, in the DA and RT markets. The model aims to maximise social welfare through energy exchange in DA and RT markets, optimal generation of conventional distributed generators (DGs), bidding renewable DGs, optimal scheduling of flexible loads, using load and generation curtailment options coordination by NCTE framework. In this model, DISO is responsible for updating congestion price and coordinate decisions among agents in an iterative approach. Scenario-based stochastic programming is used for addressing the demand, renewable generation and price information uncertainties into consideration. Additionally, this paper, suggests an approach to select the step-size heuristically for LM calculation to reduce the number of iterations to converge when compared to fixed and incremental step size update techniques. In summary, the main contributions of this paper are as follows: • We follow up on a recently proposed network constrained TE management framework [3], and extend this to a scenario with: (i) high penetration of DERs such as solar photovoltaic and wind generation, energy storage devices (SDs), distributed generation managed by DGOs, and flexible load of residential customers managed by DRAs; (ii) customers appliance and discomfort model into consideration; and (iii) operational decision making in both DA and RT markets with uncertainties in renewable generation, load demand and market price. • Formation of a stochastic optimal decision-making framework for DISO considering distribution network power flow constraints, and power and price uncertainties to study the impact on economic and system operating issues due to TEbased framework in an approximated but holistic manner. • A heuristic step size calculation is suggested to update LM iteratively to achieve relatively faster convergence with reasonable accuracy. • Finally, validate the proposed approach with a stochastic environment on a modified 33-bus system. Then demonstrate the impact of heuristic step-size on the convergence, and impact of uncertainties on optimal solutions, discussion on cost and benefits for each agent, i.e. DRA, DGO and DNO.
The rest of the paper is organised as follows. Section 2 introduces the framework of the DISO, and the detailed mathematical models for DRA, DGO, and DNO. Section 3 presents the LM-based reformulation of the problem and sub-gradient based solution strategy with heuristic step-size update. Section 4 provides case studies to illustrate the performance of the proposed method. Section 5 concludes the paper.

Problem formulation
This work considers the problem of congestion price update by the coordinator to improve convergence in a TEMS-based control of demand and supply of agents in a distribution system. Fig. 1 represents a network-constrained TE management method to schedule flexible demand and DERs. In this system, we assume that in addition to supplying electricity to loads, DRAs manage the curtailable, air-conditioning, and EV loads on behalf of certain group customers to minimise the overall cost. Hence, each DRA represents the interests of a group of customers and aims at minimising their operating costs by optimally participating in the DA spot market and RT balancing markets. Similarly DGOs try to bid their stochastic generation, SDs power into the electricity market to maximise the profit. These operations should comply with DNO's network security constraints. The DISO is therefore introduced as an independent system operator who coordinates the DRAs, DGOs, and the DNO's operational interests by the transactive-energy approach. If there is a network constraint violation by the actions of the DRAs and DGOs, congestion prices ware generated by the DISO proportional to the amount of power deviation and shared to DNO, DRAs, and DGOs to minimise the congestion in an iterative manner. The final load schedules will be sent to customers by DRAs.
It is to be noted here that, for simplicity, we consider DRA knows the customer preferences and can directly control their appliances usage. We omit the discussion on how to divide the payoff or profit among the customers in coalition, i.e. among members under the DRA which is usually done using popular solutions like shapely value in case of cooperative game theory. Alternatively, there can be another level of TE trading/scheduling between DRA and its non-cooperative customers [31]. Similarly for DGO agent, we assume DERs under it form a coalition to bid into the market to maximise their profit.

DRA's optimisation model
Each DRA has to decide the amount of energy to be procured to meet its customers demand and minimise the cost. Residential customers is assumed to have following intelligent loads (ILs) such as EV and air conditioning (AC) loads, and conventional loads with portion of it as curtailable. The DRA's objective is to minimise the cost of discomfort, energy consumption cost by strategic procurement of energy from DA and RT markets, and load curtailment options. In this study we use the model presented in [3] to characterise the AC and EV loads as follows: CL is the variable set. The relation between indoor temperature and power demand is modelled by (2a). Assume that the customer desires a most comfortable temperature T nac, b in, com and there is a range of temperature that the customer can bear as denoted by (2b) and AC power demand limits are denoted by (2c). For EV load, the cumulative power should be equal to the requested energy at the end of the charging period (2d). Here, SOC nev, b represents the state of charge of individual EV. The constraints (2e) and (2f) represent limits on charging power and curtailable load (CL), respectively. The aggregated power for DRA to be procured from DA and the RT market is calculated according to (2g).
The value of expected demand at each bus b and interval t is given below, which is obtained by summing the DA value and weighted sum of RT values

DGO's optimisation model
A DGO can have three types of resources namely conventional generation, renewable generation and SDs. The uncertainties in renewable generations and RT electricity prices are represented by scenario-based method. For profit maximisation, each DGO should commit a fixed power in DA and RT markets rationally while minimising the expected cost. The DGO objective (4) indicates minimisation of minus profit, which consists minus revenue of selling committed generation quantities with market prices and the cost of generation and storage usage, and cost of renewable generation curtailment P ω g , t, g ren, c = P ω g , t, g ren, f − P ω g , t, g ren , ∀t, g ∈ G b , ω g (5i) With the optimisation variables as DGO, rt , P ω g , t, s sd , P ω g , t, s sc , P ω g , t, g conv , P ω g , t, g ren, c . At each time interval t, constraints (5a), (5b), identify total active power available for DGO to bid. The energy balance constraints for each SD is enforced by (5c), and bounded by (5d) while capabilities of the charge/discharge active power are constrained by (5e) and (5f), respectively. DG's power is constrained by (5g). Renewable generation schedule and curtailment are represented by (5h) and (5i), respectively. It is to be noted that, in case if a DGO has only SDs and then the market price will be the purchasing price in case of charging power and selling price in case of discharging power in this formulation.
The value of expected generation at each bus b and interval t is given as To enforce the network power flow constraints on the values of power schedules by DRA and DGO assume their values are deterministic instead of stochastic for simplicity. The impact of their deviation due to uncertainties on network utilisation is of future research interest. Let P t, b D is expected net power at each bus given as where index m and n denote the number of DGOs and DRAs in the system, respectively.

DNO's optimisation model
For DNO, the objective is to control the optimal power schedules at each bus from DRAs and DGOs, subject to network voltage constraints and power limits as well as to minimise power losses. The first term in (8) is squared difference between allowable power schedules by DNO and net value of actual power schedules by DRAs and DGOs, and the second term is approximated power loss. The linearised power flow equations described in [32] is used here for radial distribution network model. These power flow equations that must hold in a network are imposed as set of constraints (9a)-(9e). Here, bus 1 is the substation connected to the external transmission network, and remaining buses represent local load and DERs. Each bus b ∈ B/ 1 has a unique ancestor denoted by k ∈ A b and set of child nodes denoted by j ∈ C b except for terminal buses. Similarly, the line connecting ancestor bus k to bus b is labelled as line kb having to have resistance r kb and reactance , P loss is the optimisation variable set. The approximated power loss is calculated by (10a). Assuming reactive power consumption Q t, b DNO is minimal and power factor at each bus is fixed in (10b), it changes in proportion to the real power P t, b DNO .

Centralised social cost minimisation problem
From a social cost minimisation point of view, it is required to minimise the following objectives together: DRAs cost, DGOs minus of profit, and the DNO's capacity allocation mismatch plus losses, subject to all their constraints as well as (11c). The overall problem formulation is as follows: where Ξ DISO = Ξ DRA , Ξ DGO , Ξ DNO and (11c) is a global constraint for the DNO and all agents, implying sum of optimal power of DRAs minus sum of optimal power of DGOs should be less than or equal (or exactly equal) to optimal allowable power by the DNO. This coupling constraint mitigates congestion and avoids the undesirable impact of the DRAs and DGOs actions on the distribution network. Let λ t, b denote the set of LMs corresponding to coupling inequality constraint (11b). By keeping the rest of the constraints implicit, the Lagrangian function for the centralised problem is: To solve Lagrangian in a centralised way, DISO requires not only the distribution network information but also the private information of the customers (i.e. utility functions and appliance schedules) and DERs. To protect customer privacy and make the DR scalable, we propose a dual decomposition algorithm-based TE management scheme to solve the problem.

TE modelling and implementation
In practice, DISO does not have direct control over all agents nor access to their private information. Alternatively, to solve the optimisation problem (12), a dual decomposition method is applied that can decompose this problem into sub-problems. Each DRA's minimisation problem can be written as s.t. the same aggregator constraints presented in Section 2.1.
Each DGO's minimisation problem can be written as s.t. the same DGO constraints presented in Section 2.2. The DNO's minimisation problem is now s.t. the same DNO constraints given in Section 2.3. This approach not only reduces the problem complexity but also provides decision-making right to each agent in the network. The problems include the DGO's, DRA's and DNO's optimisation problems, coordinated by the DISO by updating the LMs/dual variables λ t, b . The idea is to determine the vectors such that obtained equilibrium corresponds optimal solution of the centralised social welfare optimisation problem (11a). To solve the dual optimisation problem of (12), we apply the sub-gradient method [33] based distributed TE algorithm concept, which requires multiple iterations of information exchange among agents to determine equilibrium as described in Algorithm 1. This strategy is applicable because the problem is convex and constraints are also linear. The KKT and slaters conditions are satisfied and a feasible solution exists and is unique [4,34].
In each iteration, all agents receive the updated LMs at corresponding buses and send their optimal power schedules in return to the DISO.

DISO update
The DISO updates the LMs using the power difference according to following equations, if P t, b DGO ≠ 0, then (17) where i is the index for the iterations. δ t, b i is a step size, which has to be positive to guarantee convergence. The superscript i for any variable represents its value in iteration i. Note that the difference in (16) and (17) is that the constraint (11b) is enforced as strict equality constraint if the bus has both demand and generation and as inequality if the bus has only demand. Because as concluded in [3], enforcing (11b) as inequality constraint at demand bus is beneficial for overall social cost minimisation. Moreover, enforcing as equality at a bus with both generation and demand or only generation improves overall social cost minimisation based on our studies. so, δ t, b i can be positive or negative for b ∈ DGO and is non-negative for b ∉ DGO.

Step size update
Instead of using a scalar step-size while performing the LMs update in each iteration using either (16) or (17), we suggest a heuristic step-size update to improve the convergence speed. A value which depends on the amount of deviation of power schedule from the allowable power by DNO. We compared the convergence with other step-size update techniques mentioned below and observed the improvement in convergence speed.

Fixed step size (FS) update:
In this approach, a simple step-size δ t, b i = k fs , is chosen to update the LMs by DISO.

Incremental step size (IS) update:
This approach it is proportional to iteration number, i.e. δ t, b i = k fs + k is × i, where k fs and k is are positive constants.

Heuristic step size (HS) update:
In this, the initial value is chosen as a different value for each bus and time interval based on historical data learning. Then step size is also updated by a value proportional to power deviation at each iteration where k hs 1 and k hs 2 are positive constants whose value is generally chosen as 1000 times smaller than the maximum value of the power difference. In practice, the information exchanges can be facilitated by a system shown in Fig. 1, which shows the implementation of the proposed transactive control for networkconstrained management. In such a framework, the DISO manages congestion prices (i.e. the LMs) and sends updated values to the DNO and aggregator agents to achieve convergence.

Case study setup
The suggested approach is implemented over a modified IEEE 33bus radial distribution network shown in Fig. 2. The modified network has following local resources: two sets of DGs, one solar PV, one wind turbine and two SDs connected at buses 8, 25, 14, 31, and 19, 26, respectively, and their parameters are as mentioned in Table 1. Their optimal locations preferences are considered from [35]. The solar PV and wind power generation, and load demand profiles are shown in Fig. 3. The solar PV, wind and outdoor temperature data is collected from rooftop solar PV plant installed at IIT Gandhinagar campus which is used to derive renewable generation outputs. The DA and RT electricity prices are taken from ComEd's website on 30 November 2018, are shown in Fig. 3. Assume load shed λ t shed and generation curtailment λ t curt penalty prices as 1.5 × λ t DA .
For elastic load, we assume that there are 50 households connected to each load bus. Each house is having three types of appliances namely air conditioner as flexible loads, EV as shiftable loads and remaining appliances like lighting and entertainment appliances as a fixed load (FL) demand with a portion of it as CL. The details of EV and AC appliance parameters and customer preferences are given in Table 2. The FL at each bus is in range of 0 to 0.2 pu, with values below 0.05 p.u. at off-peak hours and 0.02 at peak hours and aggregated FL demand of all the buses is as shown in Fig. 3. The probability of each scenario is assumed to be equal. Keep in mind that the total number of scenarios resulting from all possible combinations is Ω S = Ω WT × Ω PV × Ω FL × Ω RT , i.e. 10 × 10 × 5 × 10. However, we need to consider the combination of PV, wind generation and RT prices scenarios only in DGO's optimisation problem, i.e. Ω WT × Ω PV × Ω RT , and combination of load demand and RT prices scenarios in DRA's   (3), (6). Their deviation from DA scheduled values is addressed by risk coordination in RT scheduling stage, which will be addressed in future work. The sub-station bus voltage is maintained at 1 p.u., while voltage limits at other buses are taken as 0.95 and 1.05 p.u. The power factor of the load/generation at each bus is taken as 0.9. The base voltage and base MVA of the system are 12.66 kV and 4 MVA, respectively. The time resolution of the scheduling interval is taken as 1 h.
For the sake of simplicity, we consider n = 1, i.e. number of DRAs as one responsible for controlling loads at all buses, and m = 1, i.e. one DGO responsible for controlling DERs including energy storage, renewable and non-renewable generation located at nodes earlier mentioned as indicated by green colour for connections in Fig. 2. There can be multiple DRAs and DGOs controlling a particular section of nodes in the network.
The values of DNO objectives weight coefficients w 1 , w 2 are taken as 10, 1, respectively. It is to be observed that the choice of their values will impact the control decisions and objective values of all the agents, namely DGO, DNO, and DRA. Therefore, these values should be selected based on analysis for different power and price scenarios and mutual agreement between the agents. Also apart from weights, objectives are multiplied by a scaling factor S base × 1000, i.e. 4000 to convert values from p.u. to actual power in kW/h. The values of the DRA's objectives weight coefficients k 1 , k 2 are chosen as 1, 0.5 for all case studies.
The problem is formulated as a quadratic constrained programming problem and solved by using CPLEX/GAMS. For evaluating the impact of congestion, the necessity of the stochastic model, and the effectiveness of the proposed approach in convergence speed. The TE management is analysed for the following case studies: •  best-case scenario for easy comparison. This case study is done to show how network conditions are affected. • Case-1: Uncongested best case scenario -In this case, DNO considers both voltage limits, power limits in constraints and losses in the objective function. DRA and DGO consider only best-case scenario values for FL demand, renewable generation, and RT prices. Comparison of this deterministic TEMS results to case-0 is to show how network conditions are improved and total costs are affected with consideration of network limits. Also studied how heuristic step-size update in calculating LMs affects the convergence speed when compared to fixed (FS) and incremental step (IS) methods.
• Case-2: Uncongested worst-case scenario -This is same as case-1 except that here instead of best-case scenario values, we consider only worst case-scenario values for stochastic variables like renewable generations, FL demand, and RT market prices. This is done to show how various costs and schedules may get affected without considering the stochasticity. • Case-3: Uncongested stochastic scenario -In this case, DNO considers both voltage limits, power limits in constraints and losses in the objective function. DRA and DGO consider uncertainties in demand, renewable generation and RT prices through scenario-based approach. Comparison of stochastic TEMS results to case-1 and case-2 to show how the value of stochasticity, i.e. how uncertainties improve the total costs and net power profile.

Stochastic optimisation-scenarios generation and reduction
Stochastic programming is used to formulate and solve the problems with uncertain parameters. The uncertain parameters can be represented as a number of scenarios with a probability of occurrence for each scenario [37]. The stochastic programming generates a single solution which is best in some sense by weighing the optimal solutions associated with each input scenario. Since point forecast information is not sufficient to devise the optimal decision making because of uncertainty and error in the forecast model. There is one way to address this is predict several possible scenarios using probability density function (PDF) of the forecasted data which is obtained by kernel density estimator (KDE) as explained in [38]. Using the estimated PDFs for wind power, PV power, FL and electricity price we generate multiple scenarios using Monte-Carlo simulation [39].
Generally, the number of scenarios required to depict the uncertainty accurately is quite high, which makes the stochastic programming intractable. Hence, to reduce the number of scenarios while most of the stochastic information embedded. This is achieved by minimising the Kantorovich distance between the reduced and original set [40], which is the most commonly used approach. Fig. 3 shows values of generated and reduced scenarios for random variables. The exact number of scenarios to generate and reduce to are decided based on the forecast data error and variance parameters. For wind power, we considered a Weibull distribution with forecasting error 15% and variance 10%. For PV, Load and price we assumed normal distribution with the error 10% and variance 5%. For all random variables Wind power, PV power and electricity price we generate 100 scenarios and reduced to 10 scenarios since they have high error variance in relative to FL demand. For an FL we generated 100 scenarios and reduced to 5 scenarios. Table 3 summarises the obtained probabilities For simplicity, we consider a number of FL scenarios at each bus is same and their values are obtained by scaling down total FL demand of all buses, i.e. P t, ω FL by multiplying it with real power at each bus, i.e. p b rated as given in data sheet for IEEE 33 bus system in Table 4.

Simulation results-impact of network limits and step-size
In this section, first network congested and uncongested cases, i.e. case-0 and case-1 results are compared for studying the impact of congestion. Second, the value of considering stochasticity is demonstrated by comparing deterministic optimisation with best and worst scenarios, i.e. case-1 and case-2 with stochastic optimisation, i.e. case-3. Finally, analysis on how heuristic stepsize improves the convergence speed and accuracy of results is studied for case-1.

DRA's and DGO's strategy:
DRA can benefit from reduced congestion cost by rescheduling their load demand to the hours of lower price values. Similarly, DGO can benefit from the renewable generation units dispatch, SDs scheduling, and DRAs load scheduling to smooth out their conventional generation profiles; thereby reducing generation cost during the peak hours. Fig. 4a shows the profile of DRA with schedules of the total demand of AC, EV, and FLs as a stacked bar for all four case studies. By comparing case-0 and case-1, it can be seen that part of total demand levels is shifted from time slots t = 5, 6, 7 to slots t = 1, 2, 3 to reduce congestion cost by avoiding under voltage. In addition to load shifting, there is an AC load reduction and a portion of FL curtailment during time slots from t = 1 to t = 8 and at t = 20 and t = 24. This exact reduction in numbers is AC load is reduced by 0.72 p.u. (i.e. 2.88 MW), and FL is curtailed by 0.46 p.u. (i.e. 1.84 MW), and this reduction is reflected in DA and RT energy procurement in case-0 and case-1 as shown in Table 5. Moreover, there is an increment in discomfort cost from case-0 to case-1 as listed in Table 6. As indicated in Fig. 5 which shows the outdoor temperature and actual indoor temperature of ACs at two selected buses, i.e. at buses 18 and 19. Since there is a high congestion price/LM value in addition to energy price at bus 18 compared to bus 19, the indoor temperature is allowed to rise more than the desired temperature but within allowable limits to reduce the energy cost.
Comparing case studies with the deterministic approach, i.e. case-1 and case-2, with the stochastic approach, i.e. case-3, it is evident that in stochastic approach total cost lies in between best and worst-case scenarios and hence reduces the risk of an increase in cost by 785 dollars compared to worst-case scenario. Fig. 4b shows the profile of DGO with schedules of the DG, SD, and renewable sources stacked for all four case studies. By comparing case-0 and case-1, it can be seen that total generation levels are reduced at time slots t = 14, 15, 16 and increased at time slots t = 19, 20, 21 to maximise the profit. This is done mostly by changing generation schedules of DG at bus 8 and charge and discharge of SD at buses 19 and 20.
By comparing the procurement strategies for all four cases in Fig. 6a, it can be seen that reliance on DA market is high than the RT market. This is justifiable because the prices in DA is less than RT except at time intervals t = 9, 13,14,15,16,18. Hence, only during those periods, DRA procures the power from the RT market.
Whereas in the case of DGO, opposite phenomena happen to maximise the profit. From Fig. 6b, it is evident that the share of energy sells in the RT market compared to the amount in the DA market.    Table 6 presents the total cost/profit and benefits of energy procurement/sell by DRA, DGO and DNO. It is evident from Table 6 that stochastic optimisation, i.e. case-3 is the best choice because it provides an average expected cost/profit and reduces the risk of an increase in cost in case of DRA and decrease in profit case of DGO.

DNO's strategy:
For DNO, the objective is to maximise the network utilisation and minimise the congestion by limiting the power at each bus to allowable values. We study how the demand flexibility and renewable generation effect on voltage profile with and without limits on voltage and power at each bus in DNO's optimisation problem, i.e. for case-0 and case-1. Fig. 7 shows the voltage profile throughout the network for two selected time slots, one with high renewable generation, i.e. at t = 12 and other with high load demand, i.e. at t = 20. One can observe the profile is now with in the limits, the drop in voltage at t = 12 is due to the reduction in P t DGO as showning Fig. 4 and rise in voltage at t = 20 is due to the reduction in P t DRA . The approximated power losses in case-0 is 4.95 MWh and in case-1 is 2.93 MWh. The objective values of DNO for all case studies is listed in Table 6, where 'Allocation cost' refers to the value of the weighted square difference between allowable and actual power schedules, and power losses in the objective function. The 'congestion cost' is negative as DNO receives the congestion price paid by DRA and DGO. This results also highlight the locational value of energy consumption or injection because of their impact of network losses and congestion varies at different buses in the network.
DISO calculates the LM values also interpreted as congestion price and passes the updated value to DRA and DGO at each iteration as described in Section 3.1. Fig. 8 shows the final converged value of LMs at each node in each time interval for case-1. It is to be noted that the value of LM is positive in case of buses with only demand as (11c) is enforced as inequality constraint, and it can be positive or negative at bus locations with both demand and generation as (11c) is enforced as equality constraint. Also, the magnitude of value is high at buses away from substation bus in the network.

Impact of step-size on algorithm convergence
Since, λ t, b is an important variable in the transactive control approach. We study the number of iterations for convergence of Algorithm 1 with three different step size update methods mentioned in Section 3.2 for a selected case study, i.e. case-1. In Fig. 9, which shows DNO, DRA1's, and DGO1's objective functions convergence, and change in their values due to network congestion. Fig. 9a shows that Algorithm 1 with fixed step-size (FS) and incremental step-size (IS) converges in about 36 and 40 iterations, respectively, where as for heuristic step-size (HS) converges in 28 iterations.
Similarly, DRA and DGO objectives with HS update converge relatively faster in comparison to FS and IS update methods.
In Fig. 10, which shows the change in net consented power of agents at bus 8 and bus 16 at time slot 3 with a change in corresponding LM values at that particular bus and time. We can see that load is reduced to zero at bus 16 (since the FL is curtailed as DA price plus LM value reached a value higher than curtailment penalty, i.e. 1.5 times DA price, AC load is zero and EV load is shifted) to minimise congestion cost. When compared to FS and IS updates, the suggested HS update reduces the number of iterations by 7 with 2-3% error in obtained final value due to using a relatively higher step size value but in acceptable accuracy limits. In bus 8 at time 3, the power converges to −0.168 p.u., which is the value of demand minus minimum power generation by DG at bus 8, i.e. (0.082-0.25) p.u. as in Fig. 10b. The LMs are equivalent to congestion prices, and its value depends on market energy price,  DERs cost, load and renewable generation curtailment costs, and network configuration. When compared with other distributed algorithms, this approach does not require partial derivatives and can lower computational time by selecting suitable step-size heuristically in updating LMs.

Conclusions
In this paper, we suggested a modified step-size update for DA scheduling using stochastic TE management model that enables the participation of DRAs and DGOs in the wholesale market while avoiding voltage and power limit violations in the distribution network. The framework is implemented over a modified 33-bus radial distribution network, including a total of 1650 customers with 50 customers at each bus having AC, EV loads, and FLs. And two DGs, one solar PV system, one wind generation, and two SDs strategically placed at selected buses. Numerical results revealed that DISO's LM update strategies are effective in enforcing network limits, appliance energy requirements and competition among DRAs and DGOs. The heuristic step size reduces the number of iterations by at least 10%, and thereby reducing the data sharing load on the communication infrastructure. Furthermore, it is worth observing that incorporation of multiple objectives and their value trade-off with other agents can be easily done using TE in privacy-preserving and distributed manner. Regarding future research this work can be improved in the following ways: (i) instead of fixed power factor assumption, the variable reactive powers for DRAs and DGOs can also be considered for optimal capacitor bank switching by DNO to improve voltage regulation; (ii) development of online machine learning approach to dynamically update step size by training with historical data; (iii) consideration of risk in stochastic optimisation models and calculation of penalty/revenue price signal by DISO proportional to their deviation from actual schedule by the agents in RT adjustment stage; and (iv) consideration of non-linear convex power flow equations instead of linearised power flow equations in RT scheduling stage to revise DA decisions, and comparison with other types of distributed approaches.