# Research on Optimal Voltage Control of Distribution Network with the Participation of EVs and PVs
## 2 Materials and Methods
### A Two-Stage Voltage Regulation Scheme for Distribution Networks with PVs and EVs
#### 2.4.2 Modelling of the Intraday Control Stage  
As the mismatches between the day-ahead and the intraday power forecasting results are inevitable, the optimal daily operation settings of OLTC transformers and CBs obtained from the day-ahead control stage may not address all the potential voltage issues (e.g., voltage fluctuation and violations of bus voltage limits). Thanks to the real-time control capability of PV inverters and EV chargers, the PV systems and EVs are applied as supplementary voltage regulation resources in the intraday control. The control variables for the intraday control stage are the PV Var support settings (i.e., the knee pints of the voltage droop control in Figure 5) and the EV charging/discharging schemes. The control objective is to minimize the voltage deviation from its reference value and the voltage fluctuation between consecutive time slots, as in (28), with the operational constraints of EVs and PVs considered (as discussed in Sections 2.2 and 2.3). \[minf_{ic}=\sum_{i=1}^{N_{b}}(|V_{i,t}-V_{0}|+|V_{i,t}-V_{i,t-1}|) \tag{28}\]  
The optimal daily operation settings of OLTC transformers and CBs obtained from the day-ahead control stage are the predefined variables during the intraday control stage. The PV systems and EVs act as supplementary voltage regulation resources. The PV systems are always grid-connected, and their voltage regulation capability is achieved using the device-level reactive power control, with the control range mainly determined by the operating power level (and hence the solar irradiation level). For the EV fleet, its voltage regulation capability is achieved with the real-time charging/discharging scheduling under the constraints of EV battery SoC. Due to the diversified travel patterns of EV users, the operating condition of any individual EV charger will vary with time, which will directly affect its charging/discharging schemes and hence its voltage regulation capability. Accordingly, a rolling-optimization-based control scheme (ROCS) is proposed for the EV charging/discharging scheduling and is characterized by self-adaptive optimization window length, as illustrated in Figure 3. Specifically, assuming 5 EVs will be connected to an EV charging station at different time instances with diversified charging durations, the selected optimization window length for each time slot also has to be dynamically adjusted depending on the time-varying EV availability for the grid voltage support. For any time instance, the EV is either already connected to the charging station for a certain time or is just connected to the charging station. As illustrated in Figure 10, only EVs 1-2 are grid-connected at time instance \(t_{2}\), while EVs 1-4 are grid-connected at time instance \(t_{3}\). Based on the information on EV availability at a given time instance and the expected departure time of EV users, the optimization window length at the specified time instance can be defined by (29). \[LW_{m}=\ \cup(t_{exp,i}-t_{m}),i\in N_{m}^{ev} \tag{29}\]  
where \(LW_{m}\) is the optimization window at time instance \(t_{m}\), \(t_{exp,i}\) is the expected EV departure time of \(i\)th EV while \(N_{m}^{ev}\) is the total number of grid-connected EVs at time instance \(t_{m}\). For the example in Figure 9, the EV availability and the EV control variables under each optimization window (i.e., \(W_{2}\), \(W_{3}\), and \(W_{4}\)) are tabulated in Table 5 where \(P_{m,k}^{i}\) refers to the charging/discharging power of \(i\)th EV at time instance \(t_{m}\) of \(k\)th optimization window. It is noticed that the EV charging/discharging power for a given time slot may have different optimum values (e.g., \(P_{3,2}^{1}\), under \(W_{2}\) and \(P_{3,3}^{1}\) under \(W_{3}\) may have different optimum solutions). To address this issue, only the optimal charging power for the first time slot of each window is selected to make up the final scheduling schemes of EV charging.