<?xml-model href='http://www.tei-c.org/release/xml/tei/custom/schema/relaxng/tei_all.rng' schematypens='http://relaxng.org/ns/structure/1.0'?><TEI xmlns="http://www.tei-c.org/ns/1.0">
	<teiHeader>
		<fileDesc>
			<titleStmt><title level='a'>Learning Reactive Power Control Polices in Distribution Networks Using Conditional Value-at-Risk and Artificial Neural Networks</title></titleStmt>
			<publicationStmt>
				<publisher></publisher>
				<date>01/01/2023</date>
			</publicationStmt>
			<sourceDesc>
				<bibl> 
					<idno type="par_id">10437397</idno>
					<idno type="doi">10.35833/MPCE.2022.000477</idno>
					<title level='j'>Journal of Modern Power Systems and Clean Energy</title>
<idno>2196-5625</idno>
<biblScope unit="volume">11</biblScope>
<biblScope unit="issue">1</biblScope>					

					<author>Krishna Sandeep Ayyagari</author><author>Reynaldo Gonzalez</author><author>Yufang Jin</author><author>Miltiadis Alamaniotis</author><author>Sara Ahmed</author><author>Nikolaos Gatsis</author>
				</bibl>
			</sourceDesc>
		</fileDesc>
		<profileDesc>
			<abstract><ab><![CDATA[Scalable coordination of photovoltaic (PV) inverters, considering the uncertainty in PV and load in distribution networks (DNs), is challenging due to the lack of real-time communications. Decentralized PV inverter setpoints can be achieved to address this issue by capitalizing on the abundance of data from smart utility meters and the scalable architecture of artificial neural networks (ANNs). To this end, we first use an offline, centralized data-driven conservative convex approximation of chance-constrained optimal power flow (CVaR-OPF) in which conditional value-at-risk (CVaR) is used to compute reactive power setpoints of PV inverter, taking into account PV and load uncertainties in DNs. Following that, an artificial neural network (ANN) controller is trained for each PV inverter to emulate the optimal behavior of the centralized control setpoints of PV inverter in a decentralized fashion. Additionally, the voltage regulation performance of the developed ANN controllers is compared with other decentralized designs (local controllers) developed using model-based learning (regressionbased controller), optimization (affine feedback controller), and case-based learning (mapping) approaches. Numerical tests using real-world feeders corroborate the effectiveness of ANN controllers in voltage regulation and loss minimization.]]></ab></abstract>
		</profileDesc>
	</teiHeader>
	<text><body xmlns="http://www.tei-c.org/ns/1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink">
<div xmlns="http://www.tei-c.org/ns/1.0"><p>models to find a local control policy that maps the local historical data of each PV inverter to the optimal reactive power setpoints computed by using an OPF. However, the previous reference uses a deterministic OPF to compute the reactive power setpoints, while neglecting the uncertainty in user load and PV generation. Reference <ref type="bibr">[17]</ref> introduces support vector machines to design volt-var curves utilizing an offline centralized algorithm based on chance-constrained OPF while considering only PV uncertainty. As it is using chanceconstrained optimization, an approach is needed to estimate the tightening, which represents the uncertainty margins. In the previous reference, the authors propose using Monte-Carlo simulations to implement the tightening. Another approach in <ref type="bibr">[18]</ref> uses kernels to learn nonlinear PV inverter control policies and calculate real-time reactive power injections based on a linearized OPF problem. However, determining the best kernels can be a challenging task.</p><p>Notwithstanding the increasing availability of data and machine learning approaches that could be leveraged to map local historical data to optimal PV inverter setpoints, it remains a difficult task to take PV and load uncertainty into account in OPF for any data-driven learning design. For instance, an effective approach to mitigate DER and load uncertainty is to enforce probabilistic specifications for violations of voltage and PV reactive power constraints, leading to chance-constrained (CC) OPF formulations. The CC-OPF is nonconvex and challenging to solve. In order to bypass the nonconvexity, the Gaussianity assumption has been traditionally invoked to model the uncertainty distribution (e. g., <ref type="bibr">[8]</ref>), which is not usually valid. Convex surrogates can also replace the chance constraints, such as the conditional-valueat-risk (CVaR) or distributionally robust formulations (e. g., <ref type="bibr">[19]</ref>, <ref type="bibr">[21]</ref>- <ref type="bibr">[23]</ref>). The advantage of CVaR-OPF is that it is data-driven and distribution agnostic. Nevertheless, data-driven machine learning approaches for PV reactive power control are not explored in <ref type="bibr">[21]</ref>- <ref type="bibr">[23]</ref>. Therefore, leveraging the CVaR-OPF approach to compute the optimal PV reactive power setpoints and then using machine learning techniques to learn the mapping is an interesting research direction to capture uncertainty in historical data and learn the probabilistic guarantees associated with the voltage regulation constraint. Furthermore, using artificial neural networks (ANNs) to learn the mapping is advantageous as ANNs can accommodate any degree of nonlinearity and generally constitute a modelfree approach. Next, we list the literature pertaining to the application of ANNs in DNs.</p><p>In the past, research has been published concerning the application of ANNs to solve various DN problems <ref type="bibr">[24]</ref>- <ref type="bibr">[26]</ref>. One such application is the coordination of distribution system assets such as tap changers, shunt capacitors, and stepvoltage regulators <ref type="bibr">[24]</ref>. A single neural network is trained from deterministic offline optimization approaches to infer active and reactive power setpoints of the DERs in a centralized manner, replacing the role of distribution system operator (DSO) in real time <ref type="bibr">[25]</ref>. A large-scale communication infrastructure required to communicate the optimal setpoints predicted from the centralized ANN to other DERs in real time is assumed <ref type="bibr">[25]</ref>. In <ref type="bibr">[26]</ref>, ANNs are used to estimate nodal voltages in DNs using real-time smart meter data.</p><p>Most recently, <ref type="bibr">[27]</ref> integrates deep neural networks (DNNs) for PV inverter control policy directly into the CVaR-OPF by considering load and PV uncertainty. Specifically, the DNN training is directly incorporated into the CVaR-OPF problem where the DNN weights are trained using back-propagation and upon computing gradients of losses and voltages with respect to inverter reactive power injections. Gradient-free variants are also explored in order to optimize the DNN weights. Albeit DNN specific parameters can be learned directly by solving the CVaR-OPF, incorporating additional network objectives or constraints remains difficult. Reference <ref type="bibr">[28]</ref> uses deterministic optimization for datadriven learning. Also, the CVaR objective along with meansquare error (MSE) is used during ANN training to infer the reactive power setpoints. Furthermore, the mini-batch gradient descent algorithm is developed by carefully selecting the mini-batches to speed up the training process of the ANNs. Therefore, evaluating the performance of ANNs for datadriven decentralized voltage regulation using the optimal reactive power setpoints computed from CC-OPF is thus required, which was carried out in the conference precursor of our work <ref type="bibr">[19]</ref>. Specifically, in <ref type="bibr">[19]</ref>, the ANNs are trained using optimal reactive power setpoints obtained by solving the CC-OPF problem without incorporating the training process directly into the optimization, and the capability of voltage regulation and loss minimization of the developed ANN model is compared with that of a tree-based regression model for a smaller network (IEEE 13-node) and for a longer timescale (1-hour).</p><p>The contributions of this paper are listed as follows. 1) A methodology for using ANNs to learn the mapping from load and PV generation uncertainties to inverter reactive power setpoints from data optimized by the CVaR-OPF is developed. The CVaR-OPF formulation and the ANN structure with different activation functions and training process are presented in detail.</p><p>2) We extend the previous work in <ref type="bibr">[19]</ref> to accommodate larger networks with reasonable number of PVs and showcase the benefits of a scalable implementation of the datadriven decentralized learning approach. Results are showcased in the Arizona SB 129-node feeder <ref type="bibr">[29]</ref>.</p><p>3) The decentralized controllers are implemented using a faster timescale of 15 min and are tested for under-and overvoltage test cases.</p><p>4) It is investigated whether the trained ANNs generalize the uncertainty in data sufficiently over a longer period by respecting the probabilistic specification of voltage constraints.</p><p>5) The developed ANN controllers are compared in terms of voltage regulation and thermal loss minimization with the following data-driven approaches: regression-based controllers <ref type="bibr">[16]</ref>, case-based learning <ref type="bibr">[30]</ref>, and optimized affine feedback schemes <ref type="bibr">[23]</ref>. Specifically, we develop regressionbased controllers by adopting the CVaR-OPF problem, which is not performed in <ref type="bibr">[16]</ref>. The end result is to present the trade-offs of various decentralized designs concerning voltage regulation and thermal loss minimization while com-plying with the probabilistic specification on the voltages and PV inverter constraints. The ANNs perform remarkably well in terms of probabilistic voltage regulation and thermal loss minimization compared with regression-based, casebased, and optimization-based affine control schemes.</p><p>The remainder of this paper is organized as follows. Section II presents the system model and the data-driven centralized offiline stochastic OPF. The voltage regulation problem with generic chance constraints and their data-driven approximations used to obtain optimal DER setpoints are also formulated. Data-driven local designs for reactive power control using linear and nonlinear policies are the theme of Section III. Section IV details the numerical tests, including the network setup and data collection process. Thorough comparisons are presented between the performance of the developed ANN controller and other designs in terms of voltage regulation and thermal loss minimization. Finally, conclusions are drawn in Section V.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>II. SYSTEM MODEL AND DATA-DRIVEN CENTRALIZED OFFLINE STOCHASTIC OPF</head><p>The network and resource model adopted in this paper are detailed first, followed by the methodology to account for the uncertainty in user load and PV generation using CVaR optimization <ref type="bibr">[19]</ref>, <ref type="bibr">[23]</ref>.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>A. Power Distribution System Model</head><p>Consider a single-feeder radial distribution network modeled by a tree graph with N + 1 buses (nodes) and lines (edges) connecting these buses. Let N 0 : ={0, 1, ..., N} denote the set of all buses and L: ={1, 2, ..., L} denote the set of lines. The substation is indexed by n = 0. All nodes except the substation are included in the set N: ={1, 2, ..., N} and represent user nodes. Let v n denote the squared voltage magnitude at bus n &#206; N 0 , where v 0 is fixed, and let v collect all nodal voltages for n &#206; N. Let s n = p n + jq n denote the complex power injected to bus n. For each line n &#206; L, z n = r n + jx n denotes its impedance, and S n = P n + jQ n is the complex power flow to the bus n. Also, let b sh n be the reactive power injected at bus n (e.g., due to shunt capacitors) at nominal voltage of 1.0 p. u.. We collect all nodal quantities into vectors p, q, b sh , and v, and correspondingly, r, x, P, and Q for lines. Let z = r + jx, and S = P + jQ denote the respective complex vectors. The relationship between voltage magnitudes, power injections, and line power flows is captured by the LinDistFlow model <ref type="bibr">[31]</ref> in p.u.. P = -F T p (1)</p><p>) where A &#206; R L &#180;N results from removing the first column of the network edge-to-node incidence matrix A &#834; =[a 0 &#57512;A]&#206; R L &#180;(N + 1) ; we also have F = -A -1 with the property that Fa 0 = 1 N and Z = diag(z) <ref type="bibr">[31]</ref>; v 0 is the squared voltage magnitude at the slack bus; and a 0 is the first column in A &#834; <ref type="bibr">[31]</ref>. For a given N &#180;1 vector z, diag(z) returns an N &#180;N matrix with the elements of z on its diagonal. Further, I N denotes an N &#180;N identity ma-trix; and 0 N and 1 N are the N-dimensional vectors with all zeroes and ones, respectively.</p><p>Substituting (1) and (2) into (3) and premultiplying (3) with -F yields:</p><p>It is assumed that the network parameters in X and b sh render (I N -X &#834; ) invertible. The model in (4) approximates squared voltage magnitude as affine functions of power injections p and q, and generalizes <ref type="bibr">[31]</ref> to include shunt capacitors.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>B. Generation and Load Model</head><p>The network has N pv distributed PV generator units whose connection to the buses is described by the PV-to-node incidence matrix &#915; &#206; R N &#180;Npv</p><p>. Due to solar intermittency, the real power p pv k of PV unit k = 1&#57512;2&#57512;&#57385;&#57512;N pv can be modeled as a random variable, while its reactive power injection q pv k can be actively controlled. Further, we collect the solar generation and reactive power injections from all PV buses in vectors p pv &#206; R N pv and q pv &#206; R N pv , respectively. If S pv k&#57512;max is the apparent power capacity for inverter k, the reactive power injections respect the capacity constraints:</p><p>The DN also includes N c constant-power loads, whose connection to network buses is given by the load-to-node incidence matrix &#936; &#206; R N &#180;Nc . The load active and reactive power consumptions p c k and q c k (k = 1&#57512;2&#57512;&#57385;&#57512;N c ) are modeled as random variables. The nodal active and reactive power consumptions are collected in vectors</p><p>N &#180;(2N c + N pv ) collects all system disturbances, which are uncontrollable. Finally, we express the net active and reactive power injections p and q in terms of controlled input u and disturbance w as follows: <ref type="bibr">(6)</ref> where</p><p>. Upon substituting (6) into (4), it can be observed that the nodal voltages are reformulated as linear functions of u and w: v(u&#57512;w) = Du + Ew + v&#834; 0 <ref type="bibr">(7)</ref> where</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>C. Objective Function</head><p>This paper considers the objective of minimizing the thermal losses on the lines, which are approximated by</p><p>Utilizing the fact that P n and Q n can be written as linear functions of p n and q n (cf. (1) and ( <ref type="formula">2</ref>)), it follows that the losses are quadratic in p and q. Furthermore, it can be observed from ( <ref type="formula">6</ref>) that p and q are linear functions of u and w. Therefore, the thermal losses can be expressed as quadratic functions of u and w as follows:</p><p>where R u , R w , R uw , and R wu are the appropriate matrices; s u and s w are the appropriate vectors; and h is a scalar.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>D. Chance-constrained Voltage Regulation</head><p>Equation ( <ref type="formula">7</ref>) directly demonstrates that the uncertainty in w will cause random fluctuations in the nodal voltages. Therefore, it is hard to ensure that voltages remain within bounds v i&#57512;min and v i&#57512;max as specified by ANSI Standard C84.1 <ref type="bibr">[32]</ref>, i. e., it may not be possible to ensure that v min &#163;(Du + Ew + v&#834; 0 )&#163; v max holds at all times. Instead, we enforce the latter constraint in a probabilistic fashion. In order to cope with the variability in w, we describe the voltage regulation problem first with generic chance constraints followed by their data-driven convex approximation. Consider the following optimization problem (P1) subject to ( <ref type="formula">5</ref>), ( <ref type="formula">7</ref>), ( <ref type="formula">11</ref>) and ( <ref type="formula">12</ref>).</p><p>(P1) min</p><p>It follows from ( <ref type="formula">9</ref>) that the dependence of thermal losses on w renders the objective function random; therefore, the expected value of the losses is minimized. In addition, constraint (5) may be enforced for all w (i. e., with probability 1) or as a chance constraint with probability &#946; k . The motivation for the latter is to allow for more flexible reactive power policies in the design phase; and the bounds of (5) will be respected in real time.</p><p>Unless the uncertainty has a favorable distribution, it is well-known that chance-constrained optimization is generally nonconvex and thus hard. The CVaR presents itself as a suitable risk measure that can be used as a convex surrogate of the chance constraint <ref type="bibr">[33]</ref>. Specifically, CVaR can be utilized to shape the tail of a distribution. Consider a function f (u&#57512;w) of the decision vector and the uncertainty, which enters in a probability constraint as Pr{ f (u&#57512;w)&#163; 0}. The CVaR at level &#945; is defined as</p><p>, where (&#215;) + : = max{&#215;&#57512;0}. It can be observerd that a CVaR constraint serves as a conservative surrogate of the chance constraint, in the sense that if CVaR &#945; ( f (u&#57512;w))&#163; 0, then Pr{ f (u&#57512;w)&#163; 0}&#179; &#945; follows <ref type="bibr">[33]</ref>. Therefore, CVaR is a conservative surrogate of the chance constraint. In other words, satisfying the CVaR constraint guarantees that the original chance constraint is respected as well. If f (u&#57512;w) is convex in u, CVaR offers a convex restriction to the original chance constraint as: inf</p><p>Thus, the chance constraints in the voltage regulation problem (P1) are replaced by the CVaR constraints. Then, the following operations are performed. The auxiliary variable over which the infimum is taken in ( <ref type="formula">13</ref>) is included as optimization variable; the max operator in (&#215;) + is removed by the epigraph trick; and the expectation in ( <ref type="formula">13</ref>) is replaced by its average sample approximation. To this end, a set of training scenarios {w n s } N tr n s = 1 (realization of the random variable w) is assumed to be available, where N tr is the number of training scenarios. For notational simplicity, define u max k&#57512;n s = q &#713;pv k&#57512;n s = (S pv max &#57512;k ) 2 -( p pv k&#57512;n s ) 2 as the scenario-dependent maximum reactive power capacity; and u min k&#57512;n s = -q &#713;pv k&#57512;n s = -u max k&#57512;n s . The resulting CVaR-based data-driven voltage regulation problem (P2) is stated as <ref type="bibr">(14)</ref>, subject to ( <ref type="formula">7</ref>), ( <ref type="formula">15</ref>)-( <ref type="formula">23</ref>).</p><p>(P2) min</p><p>Upon solving optimization problem (P2), the optimal control setpoints of the k th PV inverter for scenario n s , i.e., q * k&#57512;n s , are projected within the interval [-q &#713;pv k&#57512;n s , q &#713;pv k&#57512;n s ] to respect <ref type="bibr">(5)</ref> and are given as q proj k&#57512;n s . Notice that the reactive power setpoints of the k th PV inverter computed from problem (P2) are adaptive, i.e., the reactive power setpoints q proj k&#57512;n s correspond to each scenario w n s without any restriction on the reactive power control policy. In addition, to dispatch the PV reactive power setpoints in real time, the DSO repeatedly solves the optimization problem (P2), which can be taxing computationally and communication-wise if w n s changes more frequently, and therefore, deploying the control rules in real time becomes obsolete.</p><p>To overcome the above-mentioned issues and to expedite the process of adjusting the DER setpoints adaptively based on time-varying w n s , we focus on developing local control policies, where the reactive power of the k th PV inverter is captured by previously optimized inputs/outputs, i.e., (d k&#57512;n s &#57512;q proj k&#57512;n s ), where d k&#57512;n s contains only the local historical information of w n s to be defined shortly. To accomplish this task, we leverage: &#9312; machine learning approaches, precisely ANN and regression-based approaches that learn the nonlinear mapping between d k&#57512;n s and q proj k&#57512;n s ; and &#9313; optimization-based approaches, wherein the linear control policy is included during optimization to compute inverter specific coefficients. This is the theme of the ensuing section.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>III. DATA-DRIVEN LOCAL DESIGNS FOR REACTIVE POWER CONTROL USING LINEAR AND NONLINEAR POLICIES</head><p>This section details the various designs for individual local open-loop linear and nonlinear control policies for each inverter. Specifically, we develop an ANN-based controller for each PV inverter, trained using the optimal PV setpoints with their local historical information (d k&#57512;n s &#57512;q proj k&#57512;n s ). Similarly, we design linear and nonlinear control policies, variations of which have been pursued in the literature to compute PV inverter set points (e.g., <ref type="bibr">[8]</ref>- <ref type="bibr">[10]</ref>, <ref type="bibr">[16]</ref>), but not brought together under a unifying umbrella for comparison.</p><p>Let us consider the training data set corresponding to the k th PV inverter obtained from training optimization (P2) as {d k&#57512;n s &#57512;q proj k&#57512;n s } N tr n s = 1 . Vector d k&#57512;n s is the local input to the k th PV inverter whose entries are given by the following base variables: net real power demand (p net k&#57512;n s = p c k&#57512;n sp pv k&#57512;n s ), reactive power demand q proj k&#57512;n s , and the maximum reactive power capacity q &#713;pv k&#57512;n s given by ( <ref type="formula">5</ref>). It should be noted that the voltage v k&#57512;n s which is dynamically coupled to the local control action q proj k&#57512;n s may also be appended to d k&#57512;n s ; however, the stability of the resulting controller is difficult to analyze (e.g., <ref type="bibr">[34]</ref>). Therefore, the nodal voltage v k&#57512;n s is not an input to the local policies developed in the present work. The goal of machine learning techniques (ANN and regression) used in Designs I-IV is to find a (generally nonlinear) control policy &#937;: f k (d k&#57512;n s )&#174; q proj k&#57512;n s that maps the local information of the k th PV inverter to its projected optimal setpoint using the previously optimized available input-outputs f k ({d k&#57512;n s } N tr n s = 1 )&#174;{q proj k&#57512;n s } N tr n s = 1 . Once the control policy has been designed, it can be locally applied in real time given the present net real power demand, reactive power demand, and available reactive power capacity, to determine the reactive power setpoint for each inverter. Specifically, the real and reactive power demands p c k and q c k are typically available by a smart meter, while the real power generation p pv k is determined by the maximum power point tracking of PV generator or similar algorithm. In the present paper, the performance of the local policies is assessed using a set of N tst test (not previously seen) scenarios. The set of local inputs corresponding to the test data is denoted by {d&#8242; k&#57512;n s } N tst n s = 1 . In this paper, we devise ANN controllers to approximate the mapping &#937;. The ANN structure amounts to a two-layer feed-forward network that consists of one hidden layer (HL) and one output layer (OL) for all PV inverters considered in this paper, as shown in Fig. <ref type="figure">1</ref>. The first layer includes four hidden neurons and with parameters (&#920; HL k &#57512;&#955; HL k ) which repre-sent weights and biases corresponding to the inputs of the k th PV inverter, respectively. Similarly, (&#952; OL k &#57512;&#955; OL k ) represent the output layer parameters. We use a nonlinear activation function &#981; HL for computation at the HL; and for the OL we use a linear activation function &#981; OL . Given training input vector d k&#57512;n s , the layer-wise computations are given as follows.</p><p>where the vector-valued function &#981; HL k is applying the nonlinear activation function &#981;(&#215;) k elementwise.</p><p>For notational simplicity, let &#928; k collect the trainable parameters (&#920;&#57512;&#955;) of all layers for the ANN corresponding to the k th PV inverter. In the task of supervised learning, the ANN is trained using back-propagation algorithms based on gradient descent which minimize the training loss defined as:</p><p>where g k (d k&#57512;n s ; &#928; k ) represents the composite mapping given by (3). The choice of training loss is task specific and in this study we use the MSE. Upon training, the optimal parameters &#928; * k are available, and the trained ANN is used to estimate the reactive power setpoints for the actual test data {d&#8242; k&#57512;n s } N tst n s = 1 , which is expressed as:</p><p>1) Design I: ANN-based controller with tangent-sigmoid activation function. In this design, for nonlinear activation function &#981; HL k (&#215;) of each neuron in the HL, we use the tangentsigmoid function tanh. One advantage of tangent-sigmoid neurons is that the negative inputs are strongly negative and the zero inputs are close to zero, allowing them to have outputs over a wide range of input space. A linear activation function is used for the neuron in the output layer.</p><p>2) Design II: ANN-based controller with rectified linear unit (ReLU) activation function. In this design, the transfer function in the HL of the neural network developed in Design I is replaced by the ReLU activation function, which is used by the majority of ANN applications in recent years. This is because of the fact that ReLU is computationally less expensive as it involves less mathematical operations and is easier to implement <ref type="bibr">[35]</ref>.</p><p>The training algorithm for Designs I and II is presented herein. In this paper, the Bayesian regularization algorithm is used as a training algorithm implemented using the command TrainBr in MATLAB <ref type="bibr">[36]</ref> for Designs I and II to up- date the weight and bias values of the ANN models. The Bayesian regularization algorithm minimizes the combination of squared errors and weights, and then determines the correct combination so as to produce a network that generalizes well <ref type="bibr">[37]</ref>. Since the ANN training starts with random initial weights, different results are obtained by different training algorithm runs. Therefore, every training is rerun until the best solution is obtained in terms of performance <ref type="bibr">[26]</ref>. It is noteworthy to mention that, since we consider only three base variables to estimate the optimal setpoints, the sensitivity of the estimation to the number of neurons in the hidden layer stabilizes for four neurons for all the test cases.</p><p>The training parameters and corresponding values for Designs I and II are listed in Table <ref type="table">I</ref> for all test cases.</p><p>3) Design III: regression-based controller with quadratic interactions and Bayesian information criterion (BIC). This design specifically uses regression <ref type="bibr">[16]</ref> for deriving local control of individual DERs in a decentralized fashion. Also, this design assumes the quadratic transformations of the base variables which contain additional nonlinear terms including the pairwise products and quadratic terms of base variables. The base variables are selected based on the BIC criterion <ref type="bibr">[16]</ref>. In this design, the mapping &#937; is approximated by the function</p><p>are the coefficients that are to be evaluated upon minimizing the MSE loss function, i.e., 1</p><p>4) Design IV: regression-based controller with linear interactions and sum of squared estimate of errors (SSE). This design also uses regression and replaces the quadratic transformations with linear transformations of the base variables and further uses SSE criterion for model selection. Vector d k&#57512;n s contains an intercept (constant term), linear term of each base variable, and all pairwise products of distinct base variables (no quadratic terms).</p><p>The regression-based Designs III and IV are trained using the stepwiselm command from the statistics and machine learning toolbox in MATLAB <ref type="bibr">[36]</ref>. It is worth emphasizing that the regression-based controllers in <ref type="bibr">[16]</ref> have been developed using deterministic OPF. However, the regressionbased controllers in this study are developed by adopting the CVaR-based data-driven voltage regulation problem (P2), lending them scenario-based adaptivity in a probabilistic fashion.</p><p>5) Design V: Case-based learning approach. In this design, the training information along with target data {d k &#57512;q proj k&#57512;n s } N tr n s = 1 is stored in a database of past cases. The actual test realization {d&#8242; k&#57512;n s } N tst n s = 1 , for which the reactive power setpoints are to be computed, are called the present cases. The present case vector d&#8242; k&#57512;n s is compared to all past cases in the database to find the best match in the least Euclidean distance sense. Specifically, the distance is defined as &#57390; &#57390; d&#8242; k&#57512;n sd k&#57512;n s 2 . Then the corresponding setpoint q proj k&#57512;n s from the past case with the smallest distance is used as the estimation for the present case. This technique has been implemented to predict building energy consumption in <ref type="bibr">[30]</ref>, and more generally, the Euclidean distance has been used in various case-based learning applications <ref type="bibr">[38]</ref>, <ref type="bibr">[39]</ref>. This technique would be difficult to implement in a real-time setup due to the time needed to compute distances to all cases in the database and find the best estimate. It may also exhibit a large generalization error.</p><p>6) Design VI: affine feedback control policy. In this design, the control policy for the k th PV inverter is restricted to have a linear form q pv k (w) = m T k w + &#964; k , where m k and &#964; k are the optimization variables for the k th PV inverter <ref type="bibr">[8]</ref> - <ref type="bibr">[10]</ref>. The coefficients m k select the entries of w corresponding to the k th PV inverter (and are set to zero otherwise), yielding a decentralized linear policy. The decentralized linear policy can be optimized by including in the optimization problem (P2) additional constraints u n s = Mw n s + &#964; <ref type="bibr">[23]</ref> with appropriate sparse matrix M &#206; R N pv &#180;(2N c + N pv ) and vector &#964; &#206; R N pv . The flow diagram depicting the open-loop local control designs and validation process is shown in Fig. <ref type="figure">2</ref>. The load consumption and PV generation data are first collected to solve the centralized CVaR-OPF (P2) and compute the optimal PV setpoints for Designs I through V, as well as the optimal coefficients m k &#57512; &#964; k per inverter for Design VI. The optimal PV setpoints produced by the CVaR-OPF solution are projected back to their feasible regions to respect the device limits and the projected data are used to train Designs I through IV. The reactive power controllers produced by all designs are then used to compute the setpoints for the actual test data. It is worth emphasizing that the test data used for validation are different from the ones used for training. The computed setpoints for the actual test data are projected back to their feasible regions and the resulting reactive power injections are then given as inputs to a nonlinear power flow solver, namely the Z-bus method <ref type="bibr">[40]</ref>, to obtain the nodal voltages across the network. The latter are used to validate the performance of the different designs in terms of voltage regulation and loss improvement. Specifically, the empirical probability of voltage violation is assessed in the ensuing section.</p><p>Figure <ref type="figure">3</ref> illustrates that the reactive power setpoint computed by the decentralized policy such as the ANN of Design I or Design II is fed into the traditional power controller, current controller, and switching logic module of the inverter.  Remark 1: extension to multi-phase DNs. The proposed data-driven local control designs can be extended to multiphase DNs. The counterpart of LinDistFlow in (2) is LinDist3Flow approximation upon ignoring losses and other high-order terms <ref type="bibr">[41]</ref>, which we have recently extended to handle step-voltage regulator tap selection in the OPF <ref type="bibr">[42]</ref>. Upon solving the resultant optimization problem, the optimal reactive power setpoints can be used to train the ANNs.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>IV. NUMERICAL TESTS</head></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>A. Network and Test Case Setup</head><p>The network used in this paper is the Arizona SB 129node test feeder, whose line parameters, nominal load values, and PV locations are adopted from <ref type="bibr">[29]</ref>. Further, we assume V base = 4.16 kV and S base = 2 MVA for all the test cases considered in this paper. The voltage limits v min and v max are set to be 0.95 p.u. and 1.05 p.u., respectively, for all test cases.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>B. Data Collection</head><p>The data for solving the optimization problem (P2) are collected from the homes installed with smart meters located on Pecan Street in Austin, Texas, USA <ref type="bibr">[43]</ref>. Historical load consumption and PV generation data are obtained for the month of July 2015. The data are collected in both hourly and minute-based resolution. Since the Pecan Street data include only active power, the reactive power consumptions are generated by q c = p c tan &#981; assuming lagging power factor. The data from each home are then aggregated to match the nominal load of the node. Details on data aggregation can be found in <ref type="bibr">[19]</ref>. A variety of under-and over-voltage scenarios, control resolutions, and chance constraint specifications are investigated, as described next.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>C. Test Cases 1) Test Cases A and B (Under-voltage, Slow Time-scale)</head><p>Test cases A and B are to investigate the performance of various designs for the under-voltage scenario in DNs. In test cases A and B, we consider a one-hour resolution of historical data. The optimization is performed based on the data for the first 30 days of the month (N tr = 720 scenarios) to generate the training scenarios, and the performances of the developed control designs (Designs I-VI) are evaluated for the last day (N tst = 24 scenarios). Further, the maximum PV generation is assumed to be 80% of the nominal consumption p c . The apparent power capacity S pv max is set to be 185% of P pv max . Moreover, a lagging power factor of 0.95 is assumed for all loads. For test case A, the voltage violation probability &#945; is set to be 0.9 and the PV inverter reactive power capacity violation probability &#946; is assumed to be 0.95 in the optimization problem (P2). The difference in test case B is that the probability specifications are tightened in the optimization, which poses a challenge for the decentralized designs not to exceed the desired violation probabilities. Precisely, the voltage violation probability is tightened to 0.95 and the PV inverter capacity violation probability is further tightened to 0.99.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>2) Test Cases C and D (Over-voltage, Fast Time-scale)</head><p>Test cases C and D are the investigations into over-voltage scenarios in the DNs (SB 129-node modified) while using the 15-min data-point resolution. For the 15-min datapoint resolution, the 1-min data-point resolution load consumption and PV generation profiles are first considered. The values are then averaged every 15 min to construct 15min based profiles. Furthermore, we assume the power factor of 0.99 (lagging) for all loads to compute the reactive power profiles. To create over-voltage scenarios, the original SB 129-node feeder for test cases C and D is modified by adding eight additional PV inverters and 6 shunt capacitors with ratings [1.5&#57512;100&#57512;5&#57512;5&#57512;5&#57512;3]kvar. Voltage violation and PV inverter probability specifications are both set to be 0.95. Furthermore, the maximum PV generation is assumed to be 130% of the actual nominal consumption p c . The apparent power capacity S pv max is set to be 120% of P pv max . Also, nominal loads are scaled down to 10% of their actual values. The optimization for test case C is performed in a similar way as test cases A and B, i.e., the optimization is performed for 30 days of July 2015 (N tr = 2880 scenarios) and the performance of the developed control designs is evaluated for the last day  (N tst = 96 scenarios). For test case D, the optimization is performed for the first 24 days (N tr = 2304 scenarios). Then, the control designs are tested on the last seven days of July 2015 (N tst = 672 scenarios). In other words, the difference in test case D is that we test for the last seven days instead of the last day. The objective is to investigate the generalization over a longer period of time.</p><p>The optimization problem for test cases A, B, C, and D is programmed in MATLAB invoking CVX <ref type="bibr">[44]</ref> with MOSEK Solver. Specifically, test cases A and B are solved using a PC with 32 GB RAM, and test cases C and D are solved using a high-performance computing cluster.</p><p>Table <ref type="table">II</ref> lists the maximum voltage probability violations in percentage for the terminal node (node 129) in all designs and test cases. Voltage violations are shown in bold. Figure <ref type="figure">4</ref> depicts a bar graph comparing the results in Table <ref type="table">II</ref>. More detailed analysis of the results per test case are provided next. 1) Test case A: it can be observed from Table <ref type="table">II</ref> that both regression controllers (Designs III and IV) violate the voltage specification, i. e., the voltage probability violations are above 10%. From Fig. <ref type="figure">4</ref>, it can also be observed that Designs III and IV perform significantly worse for test case A. Both ANN controllers (Designs I and II) and the case-based learning (Design V) pass the voltage specification, and have the same performance outcome of 8.33%. The affine controller (Design IV) performs the best for test case A, with a probability of 4.17%.</p><p>2) Test case B: by observing Table <ref type="table">II</ref>, it can be observed that only two designs passed the voltage specification, i. e., the ANN with tangent-sigmoid (Design I) and the affine controller (Design VI). From Fig. <ref type="figure">4</ref>, it can be observed again that both regression controllers perform significantly more poorly in comparison to the other designs for test case B. The ANN with tangent-sigmoid (Design I) performs better in test case B compared with test case A, with voltage probability violation of 4.17%. The affine controller (Design VI) performs the best compared with the other designs, for test case B with zero probability of voltage violations.</p><p>3) Test case C: for this test, the ANN controllers (Designs I and II) and the regression with quadratic interactions (Design III) all show good performance with 1.04% probability violation, and the affine controller (Design VI) again performs the best with zero probability of voltage violations.</p><p>From Table <ref type="table">II</ref> and Fig. <ref type="figure">4</ref>, it can be observed that the regression without quadratic interactions (Design IV) and the casebased learning (Design V) both exceed the allowed voltage violation specification of 5%, with violation probabilities of 6.25% and 9.38%, respectively. 4) Test case D: for this test case, all designs pass the voltage violation specification of 5%. Design IV performs slightly worse to the other designs at probability violation of 3.13%. ANN with tangent-sigmoid (Design I) and affine controller (Design IV) perform the best with 2.38%.</p><p>The empirical cumulative distribution functions (CDFs) for the voltage at node 129, which is the node with the highest probability violation using different designs in various test cases, are depicted in Figs. <ref type="figure">5</ref> and<ref type="figure">6</ref>. The y-axis in Fig. <ref type="figure">5</ref> depicts the probability of voltage violation for node 129 being below the minimum voltage limit (p.u.), i.e., Pr{v 129 &#163; 0.95}. Similarly, the y-axis in Fig. <ref type="figure">6</ref> depicts the probability of voltage violation for node 129 being above the maximum voltage limit, i. e., Pr{v 129 &#179; 1.05}. The x-axis, &#954;, is the voltage violation specification in Figs. <ref type="figure">5</ref> and<ref type="figure">6</ref>.</p><p>The network-wide voltage profiles using Designs I, III, V, and VI with respect to no-control for test cases B and C are  also shown in Figs. <ref type="figure">7</ref> and<ref type="figure">8</ref>, respectively. The y-axis in Fig. <ref type="figure">7</ref> depicts the smallest voltage across the network for each time period in the x-axis. The duration over which each curve stays below the horizontal line of 0.95 p. u. corresponds to the voltage probability violation; likewise for Fig. <ref type="figure">8</ref> and the over-voltage case.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>D. Percentage Improvement in Thermal Losses</head><p>Table III lists the percent improvement (or reduction) of average thermal losses under the considered control designs versus the case where no reactive power control is applied. The regression-based controllers (Designs III and IV) achieve the best percent improvement compared with the other designs. The ANN controllers (Designs I and II) and case-based learning (Design V) show similar improvement, only slightly less than the regression designs. Interestingly, the affine controller (Design VI) performs the worst in terms of thermal loss improvement, whereby losses have actually increased for test case D.</p><p>Overall, while the regression-based controllers (Designs III and IV) show good thermal loss improvement, they perform poorly for under-voltage scenarios, i. e., test cases A and B. The affine controller (Design VI), on the other hand, outperforms all the other designs concerning voltage regulation. However, this superior performance comes at the cost of the poor improvement in average thermal losses. ANN with ReLU (Design II) results in slightly better improvement to thermal losses compared with ANN with tangent-sigmoid (Design I), but exhibits voltage violation for test case B. The ANN with tangent-sigmoid controller (Design I) provides a good middle ground, with low probability of voltage violations in both under-and over-voltage scenarios, and simultaneously achieves large improvement in terms of thermal losses.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>V. CONCLUSION</head><p>This paper develops a data-driven control based on ANNs to compute the reactive power setpoints utilizing conservative convex approximations of chance constraints. The controllers can be implemented in a decentralized fashion, without the need for monitoring and communication infrastructure. The developed ANN controllers are compared with regression-based ones, as well as optimization approaches featuring affine feedback rules and a case-based learning approach. ANN controllers turn out to be robust to uncertainties for voltage regulation when compared with other control polices. In future research, we will focus on extending this approach considering more types of possible DERs such as battery energy storage systems and electric vehicles. It is also worth investigating the effect of coordinating different distribution system assets (e.g., step-voltage regulators and shunt capacitors) utilizing a stochastic optimization framework combined with data-driven control. Future research will also look into real-time implementation of the proposed ANN controllers using hardware-in-loop.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head>REFERENCES</head><p>[1] M. <ref type="bibr">Farivar</ref>  She had five years of prior R&amp;D industry experience as a Senior Scientist at ABB's U. S Corporate Research Center, Raleigh, USA. Her primary research interests include modeling, simulation and analysis of power electronics systems with a focus on control, stability, fault analysis, model prediction, integration of renewables and hardware-in-the-loop modeling and testing.</p><p>Nikolaos Gatsis received the Diploma (with Hons.) degree in electrical and computer engineering from the University of Patras, Patras, Greece, in 2005, the M. Sc. degree in electrical engineering, and the Ph. D. degree in electrical engineering with minor in mathematics from the University of Minnesota, Minneapolis, USA, in 2010 and 2012, respectively. He is currently an Associate Professor with the Department of Electrical and Computer Engineering, University of Texas at San Antonio, San Antonio, USA. He was the recipient of the CAREER Award by the U.S. National science Foundation. He has also received the UTSA President's Award for Research Achievement. His research interests include optimal and secure operation of smart grids and other critical infrastructures including water distribution networks and global positioning system.</p></div></body>
		</text>
</TEI>
