## 3 Economic Dispatch Process
\[p_{t}^{gi}+FCR_{up,t}^{gi}+aFRR_{up,t}^{gi}\leq st_{t}^{gi}p^{gi,\max}+r_{up,t }^{gi,sl},\forall gi\in G \tag{6}\]  
\[p_{t}^{gi}-FCR_{dn,t}^{gi}-aFRR_{dn,t}^{gi}\geq st_{t}^{gi}p^{gi,\min}-r_{dn,t }^{gi,sl},\forall gi\in G \tag{7}\]  
\[p_{t}^{gi}\leq st_{t}^{gi}p^{gi,\max},\forall gi\in G \tag{8}\]  
\[p_{up/dn,t}^{gi}=\frac{aFRR_{up/dn,t}^{i}}{\sum\limits_{i\in\{G,ESS\}}{aFRR_{ up/dn,t}^{i}}},\forall i\in\{G,ESS\} \tag{9}\]  
aFRR participation factors \((pf_{up/dn,t}^{i})\) sent to the AGC are calculated using Equation (9), according to the scheduling process results. Calculation practices for participation factors, taking account of unit ramp rates, variable costs and capacity, are described in [11; 12; 41; 55; 61; 62]. RES generation curtailment (\(x_{t}^{res}\)) is calculated using Equation (10), where \(P_{t}^{res,max}\) is the available RES generation. \[p_{t}^{res}+x_{t}^{res}=P_{t}^{res,\max} \tag{10}\]  
Constraints (11)-(17) are associated with the operation of the energy storage systems. Using the integer state variables (\(st_{t}^{bi,c},\ st_{t}^{bi,d}\)) in (11), the case of simultaneously charging and discharging storage units is avoided. Storage constraints (12) and (13) are equivalent to (6) and (7) of thermal units, where \(p^{bi,d,max}\) and \(p^{bi,c,max}\) refer to the maximum discharge and charge capacity, respectively. The charge/discharge states (\(st_{t}^{bi,c},\ st_{t}^{bi,d}\)) are defined using constraints (14) and (15). Equation (16) calculates the SOC at the end of the ED time interval (\(soc_{t}^{bi}\)), using the expected SOC at the end of the previous time interval (\(SOC_{t-1}^{bi}\)), the dispatch orders (\(p_{t}^{bi,c},\ p_{t}^{bi,d}\)), the charging/discharging efficiency (\(n^{bi,c},\ n^{bi,d}\)), the maximum energy capacity (\(E^{bi,max}\)), and the ED time interval duration, in hours (\(\Delta t\)). Due to its short optimization horizon, the ED process cannot be relied upon to determine the optimal operation of limited energy resources. For this purpose, a reference SOC (\(SOC_{t}^{bis}\)) is used as an input to the ED problem, which may be fixed or derived from a scheduling process executed at a previous step, with a longer optimization horizon (e.g., daily). Dealing with short-duration storages (e.g., 1 h), as in the study case of this paper, energy arbitrage is not part of their intended functionality, which is the provision of operating reserves. In such a case, the objective is to maintain energy reserves at a level that ensures sustained provision of FCR and aFRR for a minimum duration. Hence, in this paper, a constant \(SOC_{t}^{bis}\) reference is assumed, set at 55% (see Table A1 of Appendix A) to ensure both an upwards and downwards regulation capability. Equation (17) is introduced in the ED process, in order to penalize SOC deviations (using Equation (4)), expressed through slack variables (\(soc_{up,t}^{bi,sl},\ soc_{dn,t}^{bi,sl}\)), from its reference. Thus, SOC is restored back to its reference in each ED interval, replenishing energy reserves utilized to support reserve deployment in real time. This process will not put system security at risk, as constraints (6) and (7) ensure that SOC regulation observes the level of reserves available by the thermal units.