As the penetration of distributed photovoltaic (PV) generation in distribution networks continues to rise, the inherent uncertainty and randomness of PV output introduce significant challenges to power quality and system reliability. To mitigate these adverse effects, battery energy storage systems (BESS) can be deployed in coordination with distributed PV. However, the high investment and operational costs of battery energy storage systems necessitate careful optimization of both their capacity and placement. In this study, I propose a comprehensive method for optimizing the capacity and placement of battery energy storage systems in distribution networks hosting distributed PV, with the objectives of improving voltage profiles and reducing network losses. The work leverages network calculus for capacity determination and voltage–load sensitivity analysis for site selection. I validate the approach on a modified IEEE-8 test system, demonstrating substantial improvements in voltage regulation and loss reduction.

System Modeling and Problem Formulation
Distributed PV Power Modeling
The output current of a PV array can be described by the equivalent single-diode model. The current Ipv is given by:
$$
I_{\text{pv}} = N_p \left[ I_{\text{sc}} – I_s \left( \exp\left(\frac{q V_D}{k N_s A T}\right) – 1 \right) – \frac{V_D}{R_b} \right]
$$
where Isc is the photocurrent, Is the saturation current, Ns and Np the number of series and parallel modules, q the electron charge, VD the diode voltage, k the Boltzmann constant, A the ideality factor, and T the temperature. This model captures the nonlinear behavior of PV generation used in the subsequent analysis.
Battery Energy Storage System Modeling
I model the operation of a battery energy storage system (BESS) with the following energy balance and constraints:
$$
E_{\text{BESS}}(t+\Delta t) = E_{\text{BESS}}(t) + b_c(t)\,\Delta t\,\eta_c\,P_c(t) – b_d(t)\,\Delta t\,\frac{P_d(t)}{\eta_d}
$$
$$
b_c(t) + b_d(t) = 1,\quad b_c(t), b_d(t) \in \{0,1\}
$$
$$
0 \le P_c(t) \le P_{c,\text{max}},\quad 0 \le P_d(t) \le P_{d,\text{max}}
$$
$$
E_{\text{BESS},\text{min}} \le E_{\text{BESS}}(t) \le E_{\text{BESS},\text{max}}
$$
Here EBESS(t) is the stored energy, bc, bd indicate charging/discharging states, ηc, ηd are efficiencies, and Pc, Pd are power rates. These constraints ensure realistic BESS operation in the optimization framework.
Capacity Optimization Using Network Calculus
To determine the optimal total capacity of the battery energy storage systems, I adopt a network calculus approach based on arrival curves of cumulative load. The load is discretized into intervals indexed by i. The cumulative load AL over interval [i, n] is:
$$
A_L(i,n) = \sum_{t=i}^{n} l_t
$$
The upper and lower arrival curves are defined such that:
$$
\alpha_{\text{up}}(n-i) \le A_L(i,n) \le \alpha_{\text{up}}(n-i-1)
$$
$$
\alpha_{\text{low}}(n-i) \le A_L(i,n) \le \alpha_{\text{low}}(n-i-1)
$$
For continuous load function AL(t), the BESS capacity bounds are derived by integrating within these bounding curves:
$$
\alpha_{\text{up}}(n-i) \le \int_{t=i}^{n} A_L(t)\,dt \le \alpha_{\text{up}}(n-i-1)
$$
$$
\alpha_{\text{low}}(n-i) \le \int_{t=i}^{n} A_L(t)\,dt \le \alpha_{\text{low}}(n-i-1)
$$
By identifying the maximum deviation between upper and lower cumulative loads over all intervals, I determine the minimum BESS capacity required to shave peaks and fill valleys. In my test system, the optimal total BESS capacity is found to be 70 MW, split equally between two selected nodes.
Placement Optimization via Voltage–Load Sensitivity Analysis
I perform Newton–Raphson power flow analysis to compute the sensitivity of nodal voltages to changes in active and reactive power injections. The power flow equations for a PQ node i are:
$$
P_i = \sum_{j=1, j\neq i}^{N} V_i V_j Y_{ij} \cos(\theta_{ij} + \delta_j – \delta_i)
$$
$$
Q_i = -\sum_{j=1, j\neq i}^{N} V_i V_j Y_{ij} \sin(\theta_{ij} + \delta_j – \delta_i)
$$
Linearizing around an operating point yields the Jacobian matrix relationship:
$$
\begin{bmatrix} \Delta P \\ \Delta Q \end{bmatrix} = \begin{bmatrix} J_1 & J_2 \\ J_3 & J_4 \end{bmatrix} \begin{bmatrix} \Delta \delta \\ \Delta V \end{bmatrix}
$$
Inverting the Jacobian gives the sensitivity matrices:
$$
\begin{bmatrix} \Delta \delta \\ \Delta V \end{bmatrix} = \begin{bmatrix} K_1 & K_2 \\ K_3 & K_4 \end{bmatrix} \begin{bmatrix} \Delta P \\ \Delta Q \end{bmatrix}
$$
where:
$$
K_1 = \begin{bmatrix}
\frac{\partial \delta_2}{\partial P_2} & \frac{\partial \delta_2}{\partial P_3} & \cdots & \frac{\partial \delta_2}{\partial P_N} \\
\vdots & \vdots & \ddots & \vdots \\
\frac{\partial \delta_N}{\partial P_2} & \frac{\partial \delta_N}{\partial P_3} & \cdots & \frac{\partial \delta_N}{\partial P_N}
\end{bmatrix},\quad
K_2 = \begin{bmatrix}
\frac{\partial \delta_2}{\partial Q_2} & \frac{\partial \delta_2}{\partial Q_3} & \cdots & \frac{\partial \delta_2}{\partial Q_N} \\
\vdots & \vdots & \ddots & \vdots \\
\frac{\partial \delta_N}{\partial Q_2} & \frac{\partial \delta_N}{\partial Q_3} & \cdots & \frac{\partial \delta_N}{\partial Q_N}
\end{bmatrix}
$$
$$
K_3 = \begin{bmatrix}
\frac{\partial V_2}{\partial P_2} & \frac{\partial V_2}{\partial P_3} & \cdots & \frac{\partial V_2}{\partial P_N} \\
\vdots & \vdots & \ddots & \vdots \\
\frac{\partial V_N}{\partial P_2} & \frac{\partial V_N}{\partial P_3} & \cdots & \frac{\partial V_N}{\partial P_N}
\end{bmatrix},\quad
K_4 = \begin{bmatrix}
\frac{\partial V_2}{\partial Q_2} & \frac{\partial V_2}{\partial Q_3} & \cdots & \frac{\partial V_2}{\partial Q_N} \\
\vdots & \vdots & \ddots & \vdots \\
\frac{\partial V_N}{\partial Q_2} & \frac{\partial V_N}{\partial Q_3} & \cdots & \frac{\partial V_N}{\partial Q_N}
\end{bmatrix}
$$
Using these sensitivities, I compute the voltage variation at each node due to load changes. The voltage drop on a line of length L is:
$$
V_{dr} = I \left( R\cos\theta + X\sin\theta \right) L
$$
By evaluating the voltage–load sensitivity across all PQ nodes under different loading scenarios, I identify the nodes with the highest sensitivity — those that experience the largest voltage deviations. In the IEEE-8 system, nodes 4 and 5 consistently exhibit the highest sensitivity and are therefore selected as optimal locations for installing the battery energy storage systems.
Case Study and Simulation Results
I implement the proposed method using MATLAB R2022a and test it on a modified IEEE-8 distribution system. The system comprises two conventional generators (160 MW each, 10 kV), two 60 MW PV units at nodes 2 and 3, and five PQ nodes (2–5). The allowable voltage range is [0.95 p.u., 1.05 p.u.], and the BESS state-of-charge limits are [0.10, 0.90]. I consider ten loading scenarios as shown in Table 1, where scenario 10 represents the worst-case heaviest load.
| Scenario | Node 2 | Node 3 | Node 4 | Node 5 |
|---|---|---|---|---|
| 1 | 43.02 | 66.98 | 78.69 | 86.65 |
| 2 | 40.67 | 49.01 | 77.69 | 67.50 |
| 3 | 39.27 | 54.51 | 76.42 | 62.98 |
| 4 | 34.98 | 58.62 | 64.03 | 77.06 |
| 5 | 27.61 | 51.79 | 77.94 | 68.36 |
| 6 | 29.32 | 66.21 | 60.32 | 54.01 |
| 7 | 40.28 | 59.63 | 67.94 | 86.12 |
| 8 | 45.01 | 64.65 | 67.93 | 77.62 |
| 9 | 37.22 | 49.74 | 52.04 | 79.68 |
| 10 | 44.67 | 71.98 | 80.36 | 87.07 |
Table 2 shows the voltage magnitude (in %) and active/reactive power flows at each PQ node for all scenarios without any BESS installation. The worst voltage occurs at nodes 4 and 5 in scenario 10 (95.81% and 96.97%, respectively).
| Scenario | Node 2 | Node 3 | Node 4 | Node 5 | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| V (%) | P (MW) | Q (Mvar) | V (%) | P (MW) | Q (Mvar) | V (%) | P (MW) | Q (Mvar) | V (%) | P (MW) | Q (Mvar) | |
| 1 | 100.20 | 29.01 | 17.98 | 98.19 | 83.66 | 52.79 | 95.78 | 75.23 | 43.10 | 97.05 | 122.13 | 73.45 |
| 2 | 100.53 | 34.79 | 22.56 | 98.19 | 64.70 | 40.76 | 97.06 | 66.92 | 38.96 | 98.14 | 99.68 | 59.73 |
| 3 | 100.56 | 33.46 | 20.73 | 99.06 | 68.33 | 42.92 | 97.10 | 66.12 | 37.83 | 98.23 | 97.96 | 58.81 |
| 4 | 100.61 | 30.16 | 18.73 | 99.04 | 69.16 | 43.43 | 97.31 | 55.10 | 31.53 | 98.15 | 99.79 | 59.89 |
| 5 | 100.75 | 23.49 | 14.62 | 99.14 | 67.59 | 42.63 | 97.05 | 67.06 | 38.31 | 98.17 | 101.23 | 60.64 |
| 6 | 100.93 | 24.78 | 15.39 | 99.26 | 69.14 | 43.15 | 97.97 | 51.86 | 29.74 | 98.96 | 82.96 | 49.59 |
| 7 | 100.36 | 34.65 | 21.36 | 99.73 | 73.13 | 45.78 | 96.69 | 59.23 | 33.79 | 97.68 | 109.71 | 65.78 |
| 8 | 100.32 | 37.98 | 23.54 | 98.64 | 75.06 | 47.09 | 96.85 | 58.31 | 33.27 | 97.86 | 103.92 | 62.39 |
| 9 | 100.76 | 31.31 | 19.45 | 99.48 | 60.50 | 38.03 | 97.83 | 44.23 | 25.19 | 98.48 | 93.41 | 56.08 |
| 10 | 100.04 | 40.12 | 20.11 | 97.98 | 83.12 | 55.47 | 95.81 | 68.97 | 39.53 | 96.97 | 115.38 | 75.27 |
After applying the sensitivity analysis, I identify nodes 4 and 5 as the optimal locations for the battery energy storage systems. Using the network calculus capacity optimization, I determine that each BESS should have a capacity of 35 MW (total 70 MW). The BESS units are then integrated into the system and the power flow is recalculated. Table 3 presents the voltage and power distribution after BESS integration.
| Scenario | Node 2 | Node 3 | Node 4 | Node 5 | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| V (%) | P (MW) | Q (Mvar) | V (%) | P (MW) | Q (Mvar) | V (%) | P (MW) | Q (Mvar) | V (%) | P (MW) | Q (Mvar) | |
| 1 | 100.92 | 38.69 | 19.32 | 99.39 | 68.12 | 40.06 | 98.81 | 68.18 | 38.89 | 99.49 | 104.61 | 60.73 |
| 2 | 101.32 | 36.69 | 18.41 | 100.33 | 51.39 | 29.68 | 99.81 | 67.53 | 38.69 | 100.39 | 87.12 | 49.89 |
| 3 | 101.32 | 35.68 | 17.59 | 100.18 | 55.81 | 32.33 | 99.69 | 66.79 | 38.19 | 100.43 | 85.62 | 49.06 |
| 4 | 101.36 | 31.87 | 16.03 | 100.19 | 55.86 | 32.53 | 99.91 | 55.61 | 31.76 | 100.35 | 87.31 | 50.24 |
| 5 | 101.53 | 24.92 | 12.46 | 100.28 | 54.35 | 31.47 | 99.73 | 67.26 | 38.73 | 100.40 | 88.63 | 50.79 |
| 6 | 101.45 | 26.17 | 13.10 | 100.04 | 54.42 | 35.36 | 99.99 | 52.27 | 29.81 | 100.42 | 70.15 | 37.42 |
| 7 | 101.16 | 36.41 | 18.13 | 99.93 | 59.43 | 34.83 | 99.39 | 59.98 | 56.30 | 99.91 | 97.05 | 56.18 |
| 8 | 101.13 | 39.12 | 20.06 | 99.87 | 62.03 | 36.19 | 99.53 | 58.81 | 33.69 | 100.07 | 91.38 | 52.81 |
| 9 | 101.44 | 32.90 | 16.53 | 100.51 | 47.25 | 29.16 | 100.26 | 44.61 | 26.01 | 100.45 | 80.59 | 45.63 |
| 10 | 100.78 | 40.19 | 20.13 | 99.13 | 69.81 | 44.43 | 98.61 | 68.97 | 39.78 | 99.21 | 103.01 | 65.63 |
The improvement in voltage is evident: in the worst-case scenario (scenario 10), node 4 voltage rises from 95.81% to 98.61%, and node 5 from 96.97% to 99.21%. Table 4 summarizes the voltage drop and line losses on each branch, comparing the cases without and with the battery energy storage systems.
| Line | Without BESS | With BESS | ||||
|---|---|---|---|---|---|---|
| Voltage Drop (%) | Active Loss (kW) | Reactive Loss (kvar) | Voltage Drop (%) | Active Loss (kW) | Reactive Loss (kvar) | |
| 1–2 | 0.59 | 22.37 | 279.47 | 0.47 | 15.99 | 199.77 |
| 1–3 | 2.64 | 338.78 | 4,244.94 | 2.10 | 227.12 | 2,845.31 |
| 1–6 | 0.25 | 3.15 | 36.03 | 0.02 | 0.13 | 1.45 |
| 2–6 | 0.36 | 11.33 | 129.12 | 0.45 | 16.45 | 187.92 |
| 3–4 | 2.16 | 88.27 | 994.17 | 0.65 | 12.58 | 141.85 |
| 4–5 | 1.15 | 121.07 | 1,087.98 | 0.71 | 55.43 | 498.68 |
| 5–6 | 3.42 | 817.69 | 7,436.63 | 2.03 | 321.26 | 2,919.61 |
As shown in Table 4, the integration of the battery energy storage systems reduces the overall voltage drop and network losses significantly. For the critical line 5–6, the voltage drop decreases by 40.64%, active power loss by 60.71%, and reactive loss by 60.74%. Across the entire system, the average reduction in voltage drop is 39.17%, in active power loss is 53.73%, and in reactive loss is 52.18%. These results confirm that the proposed BESS capacity and placement optimization effectively stabilizes the voltage profile and improves the economic operation of the distribution network.
Conclusion
In this work, I developed a systematic methodology for optimizing the capacity and placement of battery energy storage systems in distribution networks with high penetration of distributed photovoltaic generation. The capacity is determined using network calculus to bound the cumulative load demand, and the placement is identified through a voltage–load sensitivity analysis derived from the Newton–Raphson power flow Jacobian. Simulation on a modified IEEE-8 test system under multiple loading scenarios demonstrates that the proposed method selects the most sensitive nodes (nodes 4 and 5) and allocates a total BESS capacity of 70 MW. After integration, the voltage profiles improve markedly, with worst-case voltage rising from 95.81% to 98.61% at node 4 and from 96.97% to 99.21% at node 5. System-wide voltage drop, active power losses, and reactive power losses are reduced by 39.17%, 53.73%, and 52.18%, respectively. The framework is flexible and can be extended to incorporate other renewable energy sources and storage technologies, providing a valuable tool for distribution network planners aiming to enhance power quality and operational efficiency.
