Scalable Optimal Design of Incremental Volt/VAR Control using Deep
  Neural Networks
Volt/VAR control rules facilitate the autonomous operation of distributed
energy resources (DER) to regulate voltage in power distribution grids.
According to non-incremental control rules, such as the one mandated by the
IEEE Standard 1547, the reactive power setpoint of each DER is computed as a
piecewise-linear curve of the local voltage. However, the slopes of such curves
are upper-bounded to ensure stability. On the other hand, incremental rules add
a memory term into the setpoint update, rendering them universally stable. They
can thus attain enhanced steady-state voltage profiles. Optimal rule design
(ORD) for incremental rules can be formulated as a bilevel program. We put
forth a scalable solution by reformulating ORD as training a deep neural
network (DNN). This DNN emulates the Volt/VAR dynamics for incremental rules
derived as iterations of proximal gradient descent (PGD). Analytical findings
and numerical tests corroborate that the proposed ORD solution can be neatly
adapted to single/multi-phase feeders.
Sarthak Gupta, Ali Mehrizi-Sani, Spyros Chatzivasileiadis, Vassilis Kekatos
# Scalable Optimal Design of Incremental Volt/VAR Control using Deep Neural Networks

###### Abstract

Volt/VAR control rules facilitate the autonomous operation of distributed energy resources (DER) to regulate voltage in power distribution grids. According to non-incremental control rules, such as the one mandated by the IEEE Standard 1547, the reactive power setpoint of each DER is computed as a piecewise-linear curve of the local voltage. However, the slopes of such curves are upper-bounded to ensure stability. On the other hand, incremental rules add a memory term into the setpoint update, rendering them universally stable. They can thus attain enhanced steady-state voltage profiles. Optimal rule design (ORD) for incremental rules can be formulated as a bilevel program. We put forth a scalable solution by reformulating ORD as training a deep neural network (DNN). This DNN emulates the Volt/VAR dynamics for incremental rules derived as iterations of proximal gradient descent (PGD). The rule parameters appear as DNN weights. To reduce the DNN depth, we leverage Nesterov's accelerated PGD iterations. Analytical findings and numerical tests corroborate that the proposed ORD solution can be neatly adapted to single/multi-phase feeders.

 IEEE Standard 1547.8, incremental control rules, multiphase feeders, proximal gradients, gradient backpropagation, deep neural networks.

## I Introduction

Local Volt/VAR (Volt-Ampere Reactive) control facilitates voltage regulation on distribution grids by providing reactive power compensation from DERs equipped with smart inverters. Different from centralized control schemes which incur large computational and communication burden, local rules decide DER setpoints based on local measurements. Volt/VAR control rules can be categorized into _non-incremental_ and _incremental_ ones. The former compute DER reactive power setpoints based on local voltage readings. The IEEE Standard 1547.8 prescribes such non-incremental control rules as piecewise-linear functions of voltage [1]. On the other hand, incremental Volt/VAR rules compute the _change_ in VAR setpoints as a function of voltage [2, 3, 4, 5, 6].

The existing literature on designing Volt/VAR control rules can be classified into _stability_- and _optimality_-centric works. Stability-centric works study the effect of Volt/VAR rules as a closed-loop dynamical system, which may be rendered under stable under steep slopes of non-incremental rules [7, 8]. In fact, to ensure stability, non-incremental rules may have to compromise on the quality of their steady-state voltage profile [5, 8]. Incremental rules however do not experience stability limitations and can thus achieve improved voltage profiles compared to their non-incremental counterparts. Nonetheless, such improvements may come at the expense of longer settling times of the associated Volt/VAR dynamics [8].

Optimality-centric works focus on designing stable control rules to minimize a voltage regulation objective. To this end, optimization-based strategies have been employed to design affine non-incremental rules using heuristics [9, 10, 11]. Two of our recent works in [12] and [13] have addressed the problem of optimally designing the slope, deadband, saturation, and reference voltage. Reference [12] performs ORD via a bilevel optimization applicable to single-phase feeders. Reference [13] proposes DNN-based digital twins that emulate Volt/VAR dynamics, and reformulates ORD as a DNN training task for single-/multi-phase feeders.

This letter deals with optimally selecting the shape of incremental Volt/VAR control rules, with contributions on three fronts: _c1)_ Although this _optimal rule design_ (ORD) task can be posed as a mixed-integer nonlinear optimization program, it does not scale well with the numbers of DERs, nodes, and grid loading scenarios. To address this challenge, the genuine idea here is to reformulate ORD as a deep-learning task and judiciously adapt the fast software modules widely available for training deep neural networks (DNNs). We have put forth a similar approach for designing non-incremental control rules in [13]. However, migrating from non-incremental to incremental rules is non-trivial due to the different curve shapes, stability, and settling time properties. _c2)_ To further expedite ORD for incremental rules, we suggest implementing accelerated Nesterov-type variants of the rules to yield a shallower DNN emulator. _c3)_ We also establish the convergence of incremental rules on multiphase feeders.

Recently, reference [14] deals with the optimal design of incremental rules. It uses DNNs with a single hidden layer to model piecewise-linear functions and formulates ORD as a reinforcement learning task. While [14] also utilizes DNNs to design incremental rules, we delineate from it in several ways. Reference [14] focuses on voltage control during transient dynamics, whereas this work aims at ORD to drive steady-state voltages closer to unity and over different grid loading scenarios. Reference [14] utilizes a DNN to model the piecewise-linear mapping of the rule. In contrast, this work develops a DNN-based digital twin that emulates end-to-end Volt/VAR dynamics. Lastly, we provide stability and convergence analysis for single- and multiphase feeders alike, whereas [14] applies only to single-phase feeders.

The rest of this letter is organized as follows. Section II models the feeder and discusses non-incremental and incremental Volt/VAR control rules. Section III formulates DNN-based digital twins for Volt/VAR dynamics of incremental rules, and their accelerated version. It also presents ORD
for single-phase feeders as a deep learning task. Section IV extends the ORD process to multiphase feeders. The incremental rules are then benchmarked against non-incremental rules from [13] using tests on real-world data, in Section V. The letter is concluded in Section VI.

## II Volt/VAR Control Rules

Consider a radial feeder serving \(N\) buses equipped with DERs, indexed by \(n\). Let \((\mathbf{q}^{\ell},\mathbf{q})\) collect reactive loads and generations at all nodes. Vectors \((\mathbf{p},\mathbf{v})\) collect the net active power injections and voltage magnitudes at all nodes. The impact of \(\mathbf{q}\) on \(\mathbf{v}\) can be approximately captured using the linearized grid model [13]

\[\mathbf{v}\simeq\mathbf{X}\mathbf{q}+\tilde{\mathbf{v}} \tag{1}\]

where \(\tilde{\mathbf{v}}:=\mathbf{R}\mathbf{p}-\mathbf{X}\mathbf{q}^{\ell}+v_{0} \mathbf{1}\) models the underlying _grid conditions_, and \(v_{0}\) is the substation voltage. Vector \(\tilde{\mathbf{v}}\) represents the impact of non-controlled quantities \((\mathbf{p},\mathbf{q}^{\ell})\) on voltages. Matrices \((\mathbf{R},\mathbf{X})\) depend on the feeder topology. For single-phase feeders, they are symmetric positive definite with positive entries [15]. For multiphase feeders, they are non-symmetric and have positive and negative entries [5, 13].

Vector \(\mathbf{q}\) in (1) carries the reactive injections by DERs we would like to control. Per the non-incremental rules of the IEEE Std. 1547 [1], DER setpoints are decided based on the Volt/VAR curve of Fig. 1, which is parameterized by \((\bar{v},\delta,\sigma,\bar{q})\). The standard further constrains these parameters within a polytopic feasible set [1, 12]. The negative slope of the linear segment of the curve in Fig. 1 can be expressed as

\[\alpha:=\frac{\bar{q}}{\sigma-\delta}.\]

The interaction of Volt/VAR rules with the feeder gives rise to nonlinear dynamics. These dynamics are stable if \(\|\operatorname{dg}(\boldsymbol{\alpha})\mathbf{X}\|_{2}<1\), where \(\operatorname{dg}(\boldsymbol{\alpha})\) is a diagonal matrix carrying the rule slopes over all buses on its diagonal [7]. The equilibrium setpoints for DERs cannot be expressed in closed form. However, they coincide with the minimizer of the convex optimization problem [7]

\[\min_{-\mathbf{q}\preceq\mathbf{q}\preceq\bar{\mathbf{q}}}\frac{1}{2}\mathbf{ q}^{\top}\mathbf{X}\mathbf{q}+\mathbf{q}^{\top}(\tilde{\mathbf{v}}-\bar{ \mathbf{v}})+\frac{1}{2}\mathbf{q}^{\top}\operatorname{dg}^{-1}(\boldsymbol{ \alpha})\mathbf{q}+\boldsymbol{\delta}^{\top}|\mathbf{q}| \tag{2}\]

where \(|\mathbf{q}|\) applies the absolute value on \(\mathbf{q}\) entrywise. Problem (2) depends on rule parameters \((\bar{v},\delta,\alpha,\bar{q})\) across all buses, collected in the \(4N\)-long vector \(\mathbf{z}:=(\bar{\mathbf{v}},\boldsymbol{\delta},\boldsymbol{\alpha},\bar{ \mathbf{q}})\). We denote by \(\mathbf{q}_{\mathbf{z}}(\tilde{\mathbf{v}})\) the equilibrium setpoints, and by

\[\mathbf{v}_{\mathbf{z}}(\tilde{\mathbf{v}})=\mathbf{X}\mathbf{q}_{\mathbf{z} }(\tilde{\mathbf{v}})+\tilde{\mathbf{v}} \tag{3}\]

the related equilibrium voltages reached by Volt/VAR rules parameterized by \(\mathbf{z}\) under grid conditions \(\tilde{\mathbf{v}}\).

_Optimal rule design (ORD)_ can be stated as the task of selecting \(\mathbf{z}\) to bring equilibrium voltages \(\mathbf{v}_{\mathbf{z}}(\tilde{\mathbf{v}})\) close to unity. To cater to diverse conditions, the utility may sample loading scenarios \(\{\tilde{\mathbf{v}}_{s}\}_{s=1}^{S}\) for the next hour, and find \(\mathbf{z}\) as

\[\mathbf{z}^{*}\in\arg\min_{\mathbf{z}} F(\mathbf{z}):=\frac{1}{S}\sum_{s=1}^{S}\|\mathbf{v}_{\mathbf{z}}( \tilde{\mathbf{v}}_{s})-\mathbf{1}\|_{2}^{2}\] (ORD) subject to (3) and \[\mathbf{z}\in\mathcal{Z}.\]

Once found, the customized rules \(\mathbf{z}^{*}\) are sent to DERs to operate autonomously over the next hour. Note that \(\mathbf{v}_{\mathbf{z}}(\tilde{\mathbf{v}}_{s})\) depends on \(\mathbf{z}\) because the equilibrium setpoints \(\mathbf{q}_{\mathbf{z}}(\mathbf{v}_{s})\) in (3) are the minimizers of problem (2), which is parameterized by \(\mathbf{z}\). When solving (ORD) for non-incremental rules, the feasible set \(\mathcal{Z}\) consists of the polytopic constraints imposed on \(\mathbf{z}\) by the IEEE Std. 1547 as well as additional constraints on \(\boldsymbol{\alpha}\) to ensure \(\|\operatorname{dg}(\boldsymbol{\alpha})\mathbf{X}\|_{2}<1\); see [12]. Therefore, the feasible set \(\mathcal{Z}\) can be quite confined. This can lead to less desirable voltage profiles; that is, higher objective values \(F(\mathbf{z}^{*})\).

The aforesaid issue can be addressed by replacing the non-incremental Volt/VAR rules of IEEE Std. 1547 by incremental ones as suggested in [2, 3, 4, 5, 6]. Incremental rules express the _change_ rather than the actual value in setpoints as a function of voltage. One option for incremental rules is to implement a proximal gradient descent (PGD) algorithm solving (2) as proposed in [5]. In this case, the control rule coincides with the PGD iterations, which are implemented by DERs in a decentralized fashion. Using incremental rules, set \(\mathcal{Z}\) is enlarged as now we only need to ensure

\[\mathbf{z}\geq\mathbf{0}\] \[0.95\cdot\mathbf{1}\leq\bar{\mathbf{v}}\leq 1.05\cdot\mathbf{1}\]

and that \(\bar{\mathbf{q}}\) are within the reactive power ratings of the DERs.

The PGD algorithm is an extension of gradient descent to handle constraints and non-differentiable costs [5]. At iteration \(t\), PGD proceeds with two steps: _s1)_ It first computes the gradient of the first two terms of \(F(\mathbf{z})\), that is \(\mathbf{X}\mathbf{q}^{t}+\tilde{\mathbf{v}}-\bar{\mathbf{v}}=\mathbf{v}^{t}- \bar{\mathbf{v}}\). Here \(\mathbf{q}^{t}\) is the latest estimate of the minimizer of (2); _s2)_ PGD then updates \(\mathbf{q}^{t+1}\) as the minimizer of

\[\min_{-\bar{\mathbf{q}}\preceq\mathbf{q}\leq\bar{\mathbf{q}}}\ \frac{1}{2}\mathbf{q}^{\top} \operatorname{dg}^{-1}(\boldsymbol{\alpha})\mathbf{q}+\boldsymbol{\delta}^{ \top}|\mathbf{q}|+\frac{1}{2\mu}\|\mathbf{q}-(\mathbf{v}^{t}-\bar{\mathbf{v}}) \|_{2}^{2} \tag{4}\]

for a step size \(\mu>0\). The last problem involves the last two terms in the cost of (2) regularized by the Euclidean distance of \(\mathbf{q}\) to the gradient \((\mathbf{v}^{t}-\bar{\mathbf{v}})\) computed in step _s1)_.

Converting PGD to control rules, step _s1)_ is performed by the physics of the feeder when injecting \(\mathbf{q}^{t}\) and measuring the local voltage deviations. Step _s2)_ is run by each DER independently as (4) is separable across buses. Using the subdifferential, solving (4) provides the update [5]

\[y_{n}^{t}=\tilde{\alpha}_{n}\cdot\left(q_{n}^{t}-\mu(v_{n}^{t}-\bar{v}_{n})\right) \tag{5a}\]

Fig. 1: Non-incremental Volt/VAR control rule provisioned by the IEEE Std. 1547 for the interconnection of DERs [1].
\[q_{n}^{t+1}=g_{n}\left(y_{n}^{t}\right) \tag{5b}\]

where \(g_{n}(y_{n})\) is the _proximal operator_

\[g_{n}(y_{n}):=\begin{cases}+\bar{q}_{n}&,\ y_{n}>\overline{q}_{n}+\mu\tilde{ \delta}_{n}\\ y_{n}-\mu\tilde{\delta}_{n}&,\ \mu\tilde{\delta}_{n}<y_{n}\leq\overline{q}_{n}+\mu \tilde{\delta}_{n}\\ 0&,\ -\mu\tilde{\delta}_{n}\leq y_{n}\leq\mu\tilde{\delta}_{n}\\ y_{n}+\mu\tilde{\delta}_{n}&,\ -\overline{q}_{n}-\mu\tilde{\delta}_{n}\leq y_{n}<-\mu \tilde{\delta}_{n}\\ -\overline{q}_{n}&,\ y_{n}<-\overline{q}_{n}-\mu\tilde{\delta}_{n}.\end{cases} \tag{6}\]

and the new parameters \((\tilde{\alpha}_{n},\tilde{\delta}_{n})\) are defined as

\[\tilde{\alpha}_{n}:=\frac{1}{1+\mu/\alpha_{n}}\quad\text{and}\quad\tilde{ \delta}_{n}:=\frac{\delta_{n}}{1+\mu/\alpha_{n}}.\]

The proximal operator is plotted in the top panel of Figure 2. Note that in (5), rule parameters are transformed from representation \(\mathbf{z}=(\bar{\mathbf{v}},\tilde{\boldsymbol{\delta}},\tilde{\boldsymbol {\alpha}},\tilde{\mathbf{q}})\) to representation \(\tilde{\mathbf{z}}:=(\bar{\mathbf{v}},\tilde{\boldsymbol{\delta}},\tilde{ \boldsymbol{\alpha}},\tilde{\mathbf{q}})\). This is without loss of generality as the transformation is a bijection, and so one can work exclusively with \(\tilde{\mathbf{z}}\). The feasible set \(\tilde{\mathcal{Z}}\) for \(\tilde{\mathbf{z}}\) is similar to \(\mathcal{Z}\) with the addition that \(\tilde{\boldsymbol{\alpha}}\leq\mathbf{1}\). As with non-incremental rules, the rules in (6) are driven by local data, but now \(q_{n}^{t+1}\) depends on \((v_{n}^{t},q_{n}^{t})\), and not \(v_{n}^{t}\) alone. Both types of rules solve (2). Hence, they both converge to the same equilibrium. The advantage of incremental rules is that they are stable for all \(\boldsymbol{\alpha}\) as long as \(\mu<2/\lambda_{\text{max}}(\mathbf{X})\); see [5]. It is worth stressing that \(\mathbf{z}\) does not have the same physical interpretation as in non-incremental rules (slopes, deadband, or saturation), though \(\mathbf{z}\) parameterizes (2) for both rules.

_Accelerated incremental rules_. Although PGD rules enlarge \(\mathcal{Z}\), their settling times can be long. They reach an \(\varepsilon\)-optimal cost of (2) within \(-\frac{2\log\varepsilon}{\log\varepsilon}\kappa\left(\mathbf{X}\right)\) iterations. Here \(\kappa(\mathbf{X}):=\lambda_{\text{max}}(\mathbf{X})/\lambda_{\text{min}}( \mathbf{X})\) is the condition number of \(\mathbf{X}\). References [5, 16] put forth _accelerated_ incremental rules based on accelerated PGD (APGD). These rules need \(-\frac{2\log\varepsilon}{\log\varepsilon}\sqrt{\kappa\left(\mathbf{X}\right)}\) iterations to attain an \(\varepsilon\)-optimal cost, and take the form

\[\tilde{y}_{n}^{t} :=\left(1+\beta_{t}\right)y_{n}^{t}-\beta_{t}y_{n}^{t-1} \tag{7a}\] \[q_{n}^{t+1} :=g_{n}\left(\tilde{y}_{n}^{t}\right) \tag{7b}\]

where \(\beta_{t}:=\frac{t-1}{t+2}\), while \(y_{n}^{t}\) and \(g_{n}(y_{n})\) are as defined in (5a) and (6). Updates (7) remain local, but introduce additional memory as \(q_{n}^{t+1}\) depends on \((v_{n}^{t},q_{n}^{t})\) and \((v_{n}^{t-1},q_{n}^{t-1})\).

## III Deep Learning for Optimal Rule Design (ORD) in Single-Phase Feeders

Solving (ORD) is challenging as it is a nonconvex bilevel program. Although it can be modeled as a mixed-integer nonlinear program, such an approach does not scale well with the number of DERs and/or scenarios for non-incremental rules [13]. Seeking a more scalable solution, we reformulate (ORD) as a deep learning task. The key idea is to design a DNN that emulates Volt/VAR dynamics under the control rule of (5). To this end, note that \(g_{n}(y_{n})\) is a piecewise-linear function with four breakpoints [5]. Interestingly, this operator can be expressed as the superposition of four rectified linear units (ReLUs) as illustrated in Fig. 2, where ReLUs are denoted by \(\rho(\cdot)\). The intercepts of the ReLUs depend linearly on \((\tilde{\delta}_{n},\bar{q}_{n})\).

Building on this, one APGD iteration for DER \(n\) can be implemented by the 4-layer DNN in Fig. 3, whose weights depend affinely on \((\bar{v}_{n},\tilde{\delta}_{n},\tilde{\alpha}_{n},\bar{q}_{n})\). This DNN takes \((q_{n}^{t},v_{n}^{t})\) as its input, and computes \((q_{n}^{t+1},y_{n}^{t})\) at its output. It is termed \(\text{IC}_{n}\) and will be used as a building block to emulate Volt/VAR dynamics. This is accomplished by the recursive neural network (RNN) shown in Fig. 4. Here blocks \(\text{IC}_{n}\) are arranged vertically to model the parallel operation of DERs. Their outputs \(\mathbf{q}^{t+1}\) are multiplied by \(\mathbf{X}\), and the new voltage is computed as \(\mathbf{v}^{t+1}=\mathbf{X}\mathbf{q}^{t+1}+\tilde{\mathbf{v}}\). This is repeated \(T\) times. Thanks to the RNN structure, there is _weight sharing_, so the number of DNN weights is \(4N\) rather than \(4NT\).

The RNN takes a grid loading vector \(\tilde{\mathbf{v}}_{s}\) as its input, the rule parameters \(\tilde{\mathbf{z}}\) as weights, and computes the voltages \(\mathbf{v}_{\tilde{\mathbf{z}}}^{T}(\tilde{\mathbf{v}}_{s})\) at time \(T\) at its output. For the output \(\mathbf{v}_{\tilde{\mathbf{z}}}^{T}(\tilde{\mathbf{v}}_{s})\) to approximate well equilibrium voltages, the depth \(T\) can be chosen by the convergence rate of PGD as follows.

**Proposition 1**.: _For the DNN of Fig. 4 to ensure \(\|\Phi\left(\tilde{\mathbf{v}};\mathbf{z}\right)-\mathbf{v}^{*}(\mathbf{z})\|_ {2}\leq\epsilon_{1}\ \forall\ \tilde{\mathbf{v}}\), its depth \(T\) should satisfy_

\[T\geq\left(\frac{\kappa-1}{2}\right)\log\left(\frac{2\|\mathbf{X}\|_{2}\|\hat{ \mathbf{q}}\|_{2}}{\epsilon_{1}}\right). \tag{8}\]

Fig. 3: A DNN emulating the accelerated incremental rules of (7). Plain incremental rules can be modeled by dropping the second layer (setting \(\beta^{t}=0\)) and ignoring output \(y_{n}^{t}\).

Fig. 2: Proximal operator \(g(y)\) expressed as a sum of four shifted rectified linear units (ReLUs).
_Proof:_ From the control rule of (5b), it follows that

\[\|\mathbf{q}^{t}-\mathbf{q}^{*}\|_{2} =\|\mathbf{g}\left(\mathbf{y}^{t}\right)-\mathbf{g}\left(\mathbf{y} ^{*}\right)\|_{2}\] \[\leq\|\mathbf{y}^{t}-\mathbf{y}^{*}\|_{2}\] \[=\|\operatorname{dg}(\tilde{\boldsymbol{\alpha}})(\mathbf{I}-\mu \mathbf{X})\left(\mathbf{q}^{t-1}-\mathbf{q}^{*}\right)\|_{2}\] \[\leq\|\operatorname{dg}(\tilde{\boldsymbol{\alpha}})\|_{2}\cdot \|\mathbf{I}-\mu\mathbf{X}\|_{2}\cdot\|\mathbf{q}^{t-1}-\mathbf{q}^{*}\|_{2}\] \[\leq\|\mathbf{I}-\mu\mathbf{X}\|_{2}\cdot\|\mathbf{q}^{t-1}- \mathbf{q}^{*}\|_{2}. \tag{9}\]

The first inequality stems from the non-expansive property of the proximal operator \(\mathbf{g}\). The next equality follows from (5a). The second inequality from the sub-multiplicative property of the spectral norm. The last inequality follows by the definition of spectral norm and because \(\tilde{\alpha}_{n}\leq 1\) for all \(n\).

If \(\|\mathbf{I}-\mu\mathbf{X}\|_{2}<1\), inequality (9) implies that the dynamics in (5) are a non-expansive mapping, and thus, are stable and converge to \(\mathbf{q}^{*}\). Condition \(\|\mathbf{I}-\mu\mathbf{X}\|_{2}<1\) holds when \(\mu<2/\lambda_{\max}(\mathbf{X})\). The norm \(\|\mathbf{I}-\mu\mathbf{X}\|_{2}\) achieves its minimum of \(\left(1-\frac{2}{\kappa+1}\right)\) when

\[\mu_{0}:=\frac{2}{\lambda_{\max}(\mathbf{X})+\lambda_{\min}(\mathbf{X})}.\]

Plugging \(\mu_{0}\) into (9) and unfolding the dynamics over \(t\) provides

\[\|\mathbf{q}^{t}-\mathbf{q}^{*}\|_{2} \leq\left(1-\tfrac{2}{\kappa+1}\right)^{t}\|\mathbf{q}^{0}- \mathbf{q}^{*}\|_{2}\] \[\leq 2\left(1-\tfrac{2}{\kappa+1}\right)^{t}\|\hat{\mathbf{q}}\| _{2}.\]

For the voltage approximation error \(\|\mathbf{v}^{T}-\mathbf{v}^{*}\|_{2}=\|\mathbf{X}\left(\mathbf{q}^{T}- \mathbf{q}^{*}\right)\|_{2}\) at time \(T\) to be smaller than \(\epsilon_{1}\), we need

\[\|\mathbf{v}^{T}-\mathbf{v}^{*}\|_{2} \leq 2\|\mathbf{X}\|_{2}\cdot\|\hat{\mathbf{q}}\|_{2}\cdot \left(1-\frac{2}{\kappa+1}\right)^{T}\leq\epsilon_{1}.\]

This can be achieved by selecting \(T\) such that

\[T \geq\frac{\log\left(\frac{2\|\mathbf{X}\|_{2}\hat{\mathbf{q}}\|_ {2}}{\epsilon_{1}}\right)}{\log\left(1+\frac{2}{\kappa-1}\right)}\] \[\geq\left(\frac{\kappa-1}{2}\right)\log\frac{2\|\mathbf{X}\|_{2} \|\hat{\mathbf{q}}\|_{2}}{\epsilon_{1}}.\]

where the last inequality follows from \(\log(1+x)\leq x\). 

Plugging the values \(\|\mathbf{X}\|_{2}=0.463\) and \(\kappa=848\) for the IEEE 37-bus feeder, \(\|\hat{\mathbf{q}}\|_{2}=0.1\), and \(\epsilon_{1}=10^{-5}\) in (8), yields \(T\geq 2,892\) layers, which is relatively large. A key contributor to this large \(T\) is the \(\kappa\) term in (8). This promulgates the adoption of accelerated rules (7), which are known to have \(\mathcal{O}(\sqrt{\kappa})\) dependence. Interestingly, during implementation, one does not need to fix \(T\) to the above worst-case bounds. Leveraging dynamic computation graphs offered by Python libraries such as Pytorch, one may determine \(T\)_'on the fly'_ depending on the convergence of \(\mathbf{v}^{t}\) between pairs of successive layers.

Since the RNN emulates Volt/VAR dynamics, it can surrogate \(\mathbf{v}_{\mathbf{z}}(\tilde{\mathbf{v}}_{s})\) in (ORD). Then (ORD) can be posed as training a DNN over its weights \(\tilde{\mathbf{z}}\in\tilde{\mathcal{Z}}\) or \(\mathbf{z}\in\mathcal{Z}\). Grid loading scenarios \(\{\tilde{\mathbf{v}}_{s}\}_{s=1}^{S}\) are treated as features and equilibrium voltages \(\mathbf{v}_{\mathbf{z}}(\tilde{\mathbf{v}}_{s})\) as predictions that should be brought close to the target value of \(\mathbf{1}\) for scenarios \(s\). The DNN can be trained using stochastic projected gradient descent (SPGD) as [13]

\[\tilde{\mathbf{z}}^{i+1}=\left[\tilde{\mathbf{z}}^{i}-\frac{\lambda}{2B}\nabla_ {\tilde{\mathbf{z}}^{i}}\left(\sum_{s\in\mathcal{B}_{i}}\|\Phi(\tilde{\mathbf{ v}}_{s};\tilde{\mathbf{z}})-\mathbf{1}\|_{2}^{2}\right)\right]_{\tilde{\mathcal{Z}}} \tag{10}\]

where \(\lambda>0\) is the learning rate; set \(\mathcal{B}_{i}\) is a batch of \(B\) scenarios; and \([\cdot]_{\tilde{\mathcal{Z}}}\) is the projection onto \(\tilde{\mathcal{Z}}\). Since \(\tilde{\mathcal{Z}}\) consists of simple box constraints, projection essentially means clipping the values to the box. Lastly \(\nabla_{\tilde{\mathbf{z}}^{i}}(\cdot)\) represents the gradient with respect to \(\tilde{\mathbf{z}}\) evaluated at \(\tilde{\mathbf{z}}=\tilde{\mathbf{z}}^{i}\), and is calculated efficiently thanks to _gradient back-propagation_. Although our DNN-based ORD assumed PGD-based rule, it may be applicable to other incremental rules too.

A discussion about control rules and their DNN-based emulators is due. Recall that all three types of Volt/VAR control rules (non-incremental, incremental, and accelerated incremental) reach the same equilibrium voltages, if stable. The emulators aim at computing these equilibrium voltages. A natural question is whether the DNN emulator could implement a rule of a type different from the rule actually implemented on the feeder. This may be desirable to leverage the advantages of two types. Some caution is needed here. If the feeder implements non-incremental rules, but incremental rules converge faster to equilibrium voltages, it makes sense for the emulator to implement incremental rules. Of course, in this case, stability constraints on the non-incremental rules have to be enforced during DNN training. The reverse is not recommended: If the emulator implements non-incremental rules, its parameters \(\mathbf{z}\) should be constrained to be stable and that would be a restriction of the actual ORD problem. Finally, given the convergence advantage of accelerated incremental rules, they are always preferable over plain incremental rules for the DNN implementation. This showcases the utility of accelerated control rules even if they are not actually implemented on the feeder.

## IV Deep Learning for Optimal Rule Design (ORD) in Multiphase Feeders

In multiphase feeders, matrix \(\mathbf{X}\) is non-symmetric and has both positive and negative entries. Therefore, the rule analysis and design of Section III has to be revisited. For example, equilibrium setpoints cannot be found as the minimizers of

Fig. 4: Recurrent neural network (RNN) implementation for accelerated Incremental Volt/VAR control rules.
an optimization problem as with (2). Moreover, increasing \(\mathbf{q}\) does not mean that all voltages increase.

In multiphase feeders, the non-incremental rules of IEEE Std. 1547 remain stable as long as \(\|\operatorname{dg}(\boldsymbol{\alpha})\mathbf{X}\|_{2}<1\). This is the same condition as in the single-phase setup. How about the stability and equilibrium of incremental rules in multiphase feeders? Recall that for single-phase rules, incremental rules were obtained as the PGD iterations solving (2). Lacking an equivalent inner optimization for multiphase feeders precludes a similar approach here. Despite the incremental rules of (5) do not correspond to PGD iterates anymore, they can still be shown to be stable for multiphase feeders.

**Proposition 2**.: _Let \(\mathbf{U}\mathbf{\Lambda}\mathbf{U}^{\top}\) be the eigen-decomposition of matrix \(\mathbf{X}\mathbf{X}^{\top}\). The incremental rules of (5) are stable for multiphase feeders if their step size is selected as \(\mu<\lambda_{\min}\left(\mathbf{\Lambda}^{-1/2}\mathbf{U}^{\top}\left(\mathbf{ X}+\mathbf{X}^{\top}\right)\mathbf{U}\mathbf{\Lambda}^{-1/2}\right)\)._

The claim follows readily by adopting the proof of Proposition 1: If \(\mu\) is selected as above, then \(\|\mathbf{I}-\mu\mathbf{X}\|_{2}<1\) follows from [5, Prop. 6]. Similar to the single-phase case, incremental rules in multiphase feeders allow us to enlarge the feasible set \(\mathcal{Z}\) of rule parameters \(\mathbf{z}\). It is worth stressing that different from the single-phase setting, incremental and non-incremental rules do not converge to the same equilibrium on multiphase feeders.

The ORD task for multiphase feeders can also be formulated as a deep-learning task, with some modifications. Firstly, matrices \(\mathbf{R}\) and \(\mathbf{X}\) need to be altered. Secondly, the DNNs for multiphase feeders have \(12N\) trainable parameters, since each layer consists of \(3N\) building modules corresponding to bus/phase (node) combinations. Lastly, the step size has to be selected per Proposition 2. Adopting the proof of Proposition 1, we next find the minimum DNN depth in multiphase feeders.

**Proposition 3**.: _Let the DNN of Fig. 4 implement the incremental rules of (5) on multiphase feeders with \(\mu\) selected per Proposition 2. The DNN depth \(T\) ensuring voltage approximation error \(\|\Phi\left(\bar{\mathbf{v}};\mathbf{z}\right)-\mathbf{v}^{*}(\mathbf{z})\|_{2 }\leq\epsilon_{1}\) is_

\[T\geq\frac{\log\frac{\epsilon_{1}}{2\|\mathbf{X}\|_{2}\|\mathbf{q}\|_{2}}}{ \log\|\mathbf{I}-\mu\mathbf{X}\|_{2}}.\]

We next numerically evaluate the proposed DNN-based ORD approach in single- and multiphase feeders, and contrast the performance of incremental control rules with that of non-incremental rules.

## V Numerical Tests

We benchmark the performance of DNN-based incremental rules against non-incremental rules from [13] on single- and multiphase feeders. Real-world data were sourced from the Smart* project on April 2, 2011 [17], as explained in [13]. The DNNs were implemented and trained using Pytorch.

We first compare (non)-incremental rules, both designed via DNN training for the single-phase IEEE 37-bus feeder of Figure 5. Homes with IDs 20-369 were averaged 10 at a time and successively added as active loads to buses 2-26 as shown in Fig. 6. Active generation from solar panels was also added, as per the mapping in Fig. 6. Buses \(\{6,9,11,12,15,16,20,22,24,25\}\) were assumed to host DERs with Volt/VAR control customized per bus.

Incremental rules were simulated in their accelerated rendition. Both sets of rules were trained over \(S=80\) scenarios and \(200\) epochs with a learning rate of \(0.001\), using the Adam optimizer, and setting \(\mu=1\) for incremental rules. To ensure repeatability, the results were repeated across several time periods between 1-6 PM, and are compiled in Table V. Incremental rules obtained marginally lower objectives than non-incremental rules across all periods, with a somewhat significant difference for the 5 PM period. This behavior is explained because incremental rules allow for a larger set \(\mathcal{Z}\).

DNN-based incremental control rules were also contrasted with their non-incremental ones on the multiphase IEEE 13-bus feeder, using the testing setup from [13]. Active loads were sampled \(10\) at a time from homes with IDs \(20\)-\(379\) and added to all three phases for the buses 1-12. Figure 6 also shows the solar panel assignments shown in Fig 6 for solar generation. Lastly, nine DERs with inverters were added across phases and bus indices as shown in Fig 6.

The learning rates for non-incremental and incremental DNNs were set as \(0.1\) and \(0.001\), respectively, with the design

Fig. 5: The IEEE 37-bus feeder converted to single-phase. Node numbering follows the format node number {panel ID}. DERs at buses \(\{6,9,11,12,15,16,20,22,24,25\}\) provide reactive power control; the rest operate at unit power factor.
parameters \(\mathbf{z}:=(\bar{\mathbf{v}},\boldsymbol{\delta},\boldsymbol{\sigma},\boldsymbol{ \alpha})\) initialized to feasible values \((0.95,0.01,0.3,1.5)\). Table V compares the performance of the two rule categories over multiple periods for \(S=80\). While incremental rules took longer times to train, they were successful in lowering the cost \(F(\mathbf{z})\) by more than \(50\%\), thus yielding improved voltage profiles across all periods.

## VI Conclusions

We have devised a DNN approach to optimally design incremental Volt/VAR control rules for single- and multi-phase feeders. The key idea is to construct a DNN that emulates end-to-end the associated Volt/VAR dynamics. The DNN takes grid conditions as the input, the rule parameters as weights, and outputs the associated equilibrium voltages. Leveraging the convergence rates of the related optimization algorithms, we have provided bounds on the minimum depth of the DNN emulator to approximate equilibrium voltages within the desired accuracy. We have also established the stability of incremental control rules for multiphase feeders. Numerical tests have demonstrated that the designed control rules attain improved voltage profiles compared to their non-incremental alternatives. The improvement was found to be starker for multiphase feeders, wherein (non)-incremental rules do not reach the same equilibrium. Our findings motivate further research to possibly characterize the equilibria of control rules for multiphase feeders; the convergence of accelerated incremental rules for multiphase feeders; and to deal with chance-constrained formulations or ORD problems targeting phase imbalances.
