1 Introduction

In recent years, sustainability is a key point in many research fields and domains. Railways systems are no different, and in the last few years, new technologies have established a new paradigm to create and develop a future sustainable railways. The demand for energy throughout the world has been growing rapidly. Therefore, there is a requirement for going towards renewable power. Denmark has set a target of 50% of its power demand from renewable energy resources (RERs) by 2030, whereas the European Union (EU) commission fixed a binding renewable energy target of at least 32% in the EU for 2030. Renewable energy sources (RESs) such as wind power and solar PV energy are often spatially distributed and inherently intermittent and unpredictable. The power output of RESs depends on the wind speed, solar irradiation, and other climatic factors, which are uncertain and intermittent in nature. The present paper aims at optimal operation of railway systems with regenerative braking considering the smart grid paradigm where RERs such as wind and solar PV powers, energy storage systems battery storage and supercapacitors [1].

Nowadays, the world is going towards the development of high speed railways with the integration of RERs and storage systems. The objective of this work is to improve the energy efficiency by optimizing the design of the railway electric infrastructure, including devices such as energy storage systems and/or reversible substations to make use of the energy from regenerative braking. If the distance between territorially dispersed substations is long, then they are more suitable for the integration of RERs and storage systems [2]. This integration will reduces the dependency on primary electrical grid. The electrical supply of railway system is very easy for installing RERs, battery and supercapacitors storages along with regenerative braking capabilities. Regenerative braking plays an important role for improving the energy efficiency of electrified railway system [3]. Energy obtained by applying the regenerative braking is fed back to utility grid or stored in the available storage systems. The main challenge of integrating RERs into electrified railways is their intermittency that negatively effects the power balance. Therefore, by increasing the flexibility in the system operation and planning by including the regenerative braking, battery storage and supercapacitors.

Reference [4] proposes an optimal approach for energy and economic savings of railway system and energy storage systems, and it is analyzed for a Spanish high-speed railway system. An economic model to simulate optimal operation of a grid-connected microgrid (MG) considering wind farms and an innovative technology of advanced rail energy storage system is proposed in [5]. An optimal energy saving in DC-electrified railway with on-board storage system by using peak demand cutting strategy has been proposed in [6]. Reference [7] presents a scaled simulation and its prototype hardware of dc-dc bi-directional converter for a real rail traction drive system which is responsible for recuperation of braking energy in energy storage system. A stochastic dynamic programming method for optimal energy management of a smart home with plug-in electric vehicle energy storage is proposed in [8]. A comprehensive review of various energy storage and transportation of energy is presented in [9]. An approach to control the generated power from energy sources existing in autonomous and isolated MGs has been proposed in [10].

Application of storage devices in electrified railways, such as batteries, flywheels, electric double layer capacitors and hybrid energy storage devices is presented in [11]. An approach to minimize the impact of uncertainty and variability by offering an alternative approach for energy storage is proposed in [12]. A supercapacitor based storage system integrated railway static power conditioner sed in high-speed railways is proposed in [13]. An optimal sizing methodology for energy storage system in a railway line is proposed in [14]. Reference [3] proposes a co-phase traction power supply system with super capacitor for realizing the function of energy and power quality management in electrified railroad systems. The use of wind energy for power supply of traction railway network is presented in [15]. Reference [16] uses wind energy as a RER and the grid network sends power to locomotives of traction line connected by their substation.

From the above literature, it can be concluded that the usual energy analysis approach of train considers a static analysis based on the power flow formulations. However, in the presence of RERs, i.e., wind and solar PV powers; and the charging/discharging decisions of storage systems, the static analysis is not sufficient as wind speed and solar irradiance are intermittent in nature. In this work, it is assumed that the amount of power output from wind and solar PV units are also considered as dispatchable/schedulable, apart from the other dispatchable elements (batteries and supercapacitors). This paper deals with the ways to minimize the operating costs of electric railway systems by using renewable power sources and storage. The regenerative braking and storage systems provide flexibility to the system operation. The major contributions of this work are as follows:

  • An optimal operation of electrified railway system is proposed by considering the regenerative braking capabilities of trains along with RERs (wind and solar PV) and storage (battery storage and supercapacitors).

  • Detailed simulation models of train motion and railway power systems including load flow is used and developed in this work.

  • Minimization of total operating cost objective of electrified railway system consisting of cost of power generation from the external power system, cost of power obtained from RERs such as wind and solar PV sources, cost of power from storage systems such as battery storage and supercapacitors, and the income obtained by selling excess power back to the main electrical grid.

  • The proposed optimization problem is formulated as an AC optimal power flow (AC-OPF) problem subjected to various equality and inequality constraints.

  • Probability distribution functions (PDFs) are used to the uncertainties related to wind and solar PV powers.

  • The proposed AC-OPF problem is solved by using CONOPT solver of generalized algebraic modeling system (GAMS) software, which is a powerful and efficient optimization tool.

  • Simulation results obtained with GAMS/CONOPT solver are also compared with meta-heuristic based differential evolution algorithm (DEA).

The remainder of this paper is organized as follows: Sect. 2 presents the proposed problem formulation that is optimal operation of electrified railways. Detailed modeling of power output and uncertainty handling of RERs (wind and solar PV) and storage is presented in Sect. 3. Section 4 presents the description of non-linear optimization techniques (i.e., CONOPT solver of generalized algebraic modeling system (GAMS) software and differential evolution algorithm) that are considered in this paper. Section 5 presents the simulation results on sample test system. Conclusions and scope for future research are presented in Sect. 6.

2 Problem Formulation: Optimal Operation of Electrified Railways

The considered railway system is consists of regenerative braking of trains, wind, solar PV energy systems, battery storage and supercapacitors. The regenerative braking and storage systems provide flexibility to the system operation. Supercapacitors store the energy obtained from regenerative braking, and battery storage is used to compensate difference in electricity prices throughout the day. Supercapacitors capture high power density and high frequency operation of regenerative braking. Battery storage system absorbs short peaks of energy. The electrified railway system considered in this work consists of power to/from main electrical grid, power output from wind and solar PV powers, power to/from electric trains, battery storage and supercapacitor, and it is depicted in Fig. 1.

Fig. 1
figure 1

Electrified railway system with RERs, battery storage and supercapacitors

In general, there are two ways of integration of renewable power into the system based on the schedulable/dispatchable or non-schedulable/non-dispatchable nature of RERs. In this work, it is assumed that that renewable power generation (i.e., wind and solar PV powers) can be scheduled, and can bid in the market. But, it should consider appropriate amount of reserve and storage in operational plan. The RERs are augmented with storage devices such as batteries or fly wheels or supercapacitors, and the total power output from these sources is scheduled subjected to maximum utilization of renewable energy/power utilization.

In this paper, minimization of total operating cost (TOC) of railway system is considered as the objective function, and it is solved subjected to various equality and inequality constraints. The TOC of electrified railway system consisting of cost of power generation from the external power system (i.e., from/to main utility grid), cost of power obtained from RERs such as wind and solar PV sources, cost of power from storage systems such as battery storage and supercapacitors, and the income obtained by selling excess power back to the main electrical grid [17]. This TOC minimization objective function can be formulated as,

minimize, total operating cost (TOC), i.e.,

$$TOC = \mathop \sum \limits_{i = 1}^{{\text{N}}} {\text{C}}_{{\text{G}}} \left( {{\text{P}}_{{{\text{Gi}}}} } \right) + \mathop \sum \limits_{j = 1}^{{{\text{N}}_{{\text{W}}} }} {\text{C}}_{{\text{W}}} \left( {{\text{P}}_{{{\text{Wj}}}} } \right) + \mathop \sum \limits_{k = 1}^{{{\text{N}}_{{\text{S}}} }} {\text{C}}_{{\text{S}}} \left( {{\text{P}}_{{{\text{Sk}}}} } \right) + \mathop \sum \limits_{b = 1}^{{{\text{N}}_{{\text{B}}} }} {\text{C}}_{{\text{B}}}^{{\text{b}}} + \mathop \sum \limits_{u = 1}^{{{\text{N}}_{{\text{U}}} }} {\text{C}}_{{\text{U}}}^{{\text{u}}} - \mathop \sum \limits_{l = 1}^{{{\text{N}}_{{{\text{sp}}}} }} {\text{C}}_{{{\text{sp}}}} \left( {{\text{P}}_{{{\text{ex}},{\text{l}}}} } \right).$$
(1)

In the above equation, first term in the power generation cost from the external power system (i.e., power bought from electric network), and it is expressed as,

$${\text{C}}_{{\text{G}}} \left( {{\text{P}}_{{{\text{Gi}}}} } \right) = {\text{C}}_{{\text{G}}} \cdot {\text{P}}_{{{\text{Gi}}}} ,$$
(2)

where \(P_{Gi}\) is the active power generation from the network at ith node, and \(C_{G}\) is the cost of corresponding power generation (in $/MWh).

Second term in Eq. (1) is cost associated with WEGs, and it is calculated by using,

$${\text{C}}_{{\text{W}}} \left( {{\text{P}}_{{{\text{Wj}}}} } \right) = {\text{a}}_{{\text{j}}} + {\text{C}}_{{\text{W}}} \cdot {\text{P}}_{{{\text{Wj}}}} ,$$
(3)

where \(P_{Wj}\) is the wind power output at jth node, \(C_{W}\) is the cost of wind power generation (in $/MWh). Third term in Eq. (1) is the cost associated with solar PV units, and it is calculated by using,

$${\text{C}}_{{\text{S}}} \left( {{\text{P}}_{{{\text{Sk}}}} } \right) = {\text{b}}_{{\text{k}}} + {\text{C}}_{{\text{S}}} \cdot {\text{P}}_{{{\text{Sk}}}} ,$$
(4)

where \(P_{Sk}\) is the solar PV power output at kth node, and \(C_{S}\) is the cost of solar PV power generation (in $/MWh). Fourth term is daily minimum battery storage unit cost (\({\text{C}}_{{\text{B}}}^{{\text{b}}}\) in $), and it is determined based on the condition that battery may reach end of its useful life in two ways. One is based on maximum number of years that the storage batteries can function (\(T_{B}\)), and another one is based on the maximum number of cycles (\(T_{NC}\)), before reaching \(T_{B}\). This cost can be calculated by using [18],

$$C_{B}^{b} = max\left[ {\frac{{C_{B}^{m} }}{{365.T_{B} }}, \frac{{C_{B}^{m} }}{{\left( {{\raise0.7ex\hbox{${T_{NC} }$} \!\mathord{\left/ {\vphantom {{T_{NC} } {\delta^{b} }}}\right.\kern-\nulldelimiterspace} \!\lower0.7ex\hbox{${\delta^{b} }$}}} \right)}}} \right].$$
(5)

In the above equation, \(\delta^{b}\) is maximum daily number of cycles per battery, and \(C_{B}^{m}\) is minimum storage battery cost (in $). Fifth term in Eq. (1) is daily minimum cost of supercapacitors (\(C_{U}^{u}\) in $). This cost depends on maximum number of years the supercapacitors can function (\(T_{U}\)), and it is calculated by using [19],

$$C_{U}^{u} = \frac{{C_{U}^{m} }}{{365 \cdot T_{U} }}.$$
(6)

\(C_{U}^{m}\) is minimum supercapacitor unit cost (in $). Last term in equation is the income obtained by selling excess power back to power network. This is calculated by using [17],

$${\text{C}}_{{{\text{sp}}}} \left( {{\text{P}}_{{{\text{ex}},{\text{l}}}} } \right) = {\text{C}}_{{{\text{sp}}}} \cdot {\text{P}}_{{{\text{ex}},{\text{l}}}} ,$$
(7)

where \(C_{sp}\) is the selling price of excess power (in $/MWh), and \(P_{ex,l}\) is the available excess power at lth node.

2.1 Equality/Power Balance Constraints

The equality constraints include the active and reactive power balance constraints, and they are the key system operation constraints. The active power balance constraint states that the total generated power from the network (\(P_{Gi}\)), wind generator (\(P_{Wj}\)), solar PV generator (\(P_{Sk}\)) and power discharged from battery (\(P_{B}^{disch}\)) and supercapacitor (\(P_{SC}^{disch}\)) should be the same as total power demand of train (\(P_{T}\)) which takes positive and negatives values, excess power (\(P_{ex,l}\)), power demand from the network (\(P_{Di}\)), battery charging power (\(P_{B}^{ch}\)), supercapacitor charging power (\(P_{SC}^{ch}\)) plus the system power losses (\(P_{L}\)). This active power balance constraint at a particular node can be expressed as [20],

$${P}_{Gi}+{P}_{Wj}+{P}_{Sk}+{P}_{B}^{disch}+{P}_{SC}^{disch}={P}_{T}+{P}_{ex,l}+{P}_{Di} +{P}_{B}^{ch}+{P}_{SC}^{ch}{+P}_{L}$$
(8)

where \(P_{T}\) and \(Q_{T}\) are the active and reactive power demands of Tth train. \(P_{Di}\) and \(Q_{Di}\) are the active and reactive power demands at ith node. \(P_{L}\) and \(Q_{L}\) are the active and reactive power demands at ith node.

Similarly, the reactive power balance constraint states that the total reactive power generated power from the network (\(Q_{Gi}\)), wind generator (\(Q_{Wj}\)), solar PV generator (\(Q_{Sk}\)) should be the same as total reactive power demand of train (\(Q_{T}\)), reactive power demand from the network (\(Q_{Di}\)), plus the system reactive power losses (\(Q_{L}\)). This reactive power balance constraint at a particular node can be expressed as [20],

$$Q_{Gi} + Q_{Wj} + Q_{Sk} = Q_{T} + Q_{Di} + Q_{L} .$$
(9)

2.2 Inequality Constraints

The thermal limit of each device or conductor is limited by the amount of current, which is closely related to apparent power. Therefore, the inequality constraint related to apparent power (\(S_{Gi} )\) is expressed as,

$$S_{Gi}^{min} \le S_{Gi} \le S_{Gi}^{max} ,$$
(10)

where \(S_{Gi}^{min}\) and \(S_{Gi}^{max}\) are the lower and upper limits of apparent power of the network.

Voltages at each node are limited by their lower and upper limits.

$$V_{Gi}^{min} \le V_{Gi} \le V_{Gi}^{max} .$$
(11)

Power flow in a line is restricted by [20],

$$S_{Li} \le S_{Li}^{max} ,$$
(12)

where \(S_{Li}\) is the power flow in ith line, and \(S_{Li}^{max}\) is the thermal limit of ith line.

From the above objective function and constraints, it can be observed that the proposed problem is a non-linear programming problem, i.e., an AC-optimal power flow (AC-OPF) problem. The above optimization problem is solved by using the CONOPT solver of generalized algebraic modeling system (GAMS) software package. The obtained results are also compared with meta-heuristic based differential evolution algorithm (DEA).

3 Modeling of Wind, Solar PV and Storage Systems

In this section, modeling of power output from wind and solar PV systems, and the uncertainty handling of these RERs is presented. And also, modeling of battery storage and supercapacitors is described.

3.1 Modeling of Wind Energy System

The amount of power output from a wind energy generator (WEG) at a given location depends on the wind speed, and it closely follows the Weibull probability distribution function (PDF). Amount of power output from a WEG (\(P_{W}\)) can be calculated by using [21],

$$P_{W} = \left\{ {\begin{array}{*{20}l} { 0\quad if\, v < v_{ci} or v \ge v_{co} } \\ {P_{r} \left( {\frac{{v^{3} - v_{ci}^{3} }}{{v_{r}^{3} - v_{ci}^{3} }}} \right)\quad if \,v_{ci} \le v \le v_{r} } \\ {P_{r}\quad if \,v_{r} \le v \le v_{co} } \\ \end{array} } \right.,$$
(13)

where \(v\) is wind speed; \(v_{r}\), \(v_{ci}\) and \(v_{co}\) are rated, cut-in and cut-out wind speeds. \(P_{r}\) is rated wind power output. The power output from WEG (\(P_{W}\)) is restricted by its maximum power (\(P_{W}^{max}\)) and it is represented by,

$$P_{W} \le P_{W}^{max} .$$
(14)

Here, Weibull PDF of wind speed is used, and it is expressed as [21],

$$f_{v} = \left( \frac{k}{c} \right)\left( \frac{v}{c} \right)^{k - 1} e^{{ - \left( \frac{v}{c} \right)^{k} }} 0 < v < \infty ,$$
(15)

where c and k are scale and shape factors, respectively.

3.2 Modeling of Solar Energy System

Power output from solar PV unit depends on solar irradiance at a specific location, and it is expressed as [22],

$$P_{S} = \left\{ {\begin{array}{*{20}l} {P_{r}^{S} \left( {\frac{{G^{2} }}{{G_{std} R_{c} }}} \right)\quad if\, 0 < G < R_{c} } \\ {P_{r}^{S} \left( {\frac{G}{{G_{std} }}} \right) \quad if\, G > R_{c} } \\ \end{array} } \right.,$$
(16)

where \(G_{std}\) is standard solar irradiation (set at 1000 W/m2), \(G\) is forecasted solar irradiation. \(R_{c}\) is a certain solar irradiation (set at 150 W/m2). \(P_{r}^{S}\) is rated power generation from solar PV unit. The power output from solar PV unit (\(P_{S}\)) is restricted by maximum limit (\(P_{S}^{max}\)), and it is represented by,

$$P_{S} \le P_{S}^{max} .$$
(17)

The hourly solar irradiation mostly follows a bimodal distribution function. This bimodal distribution can be represented by a linear combination of two unimodal distributions. These unimodal functions are modeled by using log-normal, Weibull and Beta PDFs. Here, Weibull PDF is used, and it can be represented by [22],

$$f_{G} = W\left( {\frac{{k_{1} }}{{c_{1} }}} \right)\left( {\frac{G}{{c_{1} }}} \right)^{{k_{1} - 1}} e^{{ - \left( {\frac{G}{{c_{1} }}} \right)^{{k_{1} }} }} + \left( {1 - W} \right)\left( {\frac{{k_{2} }}{{c_{2} }}} \right)\left( {\frac{G}{{c_{2} }}} \right)^{{k_{2} - 1}} e^{{ - \left( {\frac{G}{{c_{1} }}} \right)^{{k_{2} }} }} 0 < G < \infty ,$$
(18)

where \(W\) is weight factor. \(c_{1}\), \(c_{2}\), \(k_{1}\) and \(k_{2}\) are scale and shape factors, respectively.

3.3 Modeling of Battery Storage

Batteries have relatively low power density, high energy density, small number of charging/discharging cycles and their characteristics will degrade quickly over time. Hence, batteries alone cannot be used to store the energy of regenerative braking [23]. Therefore, in this work, supercapacitors are also used along with storage batteries. Charge/discharge equation of storage battery is represented by [24],

$${\text{C}}_{{\text{B}}}^{{{\text{t}} + 1}} = {\text{C}}_{{\text{B}}}^{{\text{t}}} - \frac{{\Delta {\text{t}}}}{{{\text{C}}_{{\text{B}}}^{{\text{m}}} }}\left( {\frac{{{\text{P}}_{{{\text{B}},{\text{t}}}}^{{{\text{disch}}}} }}{{\eta_{{\text{B}}}^{{{\text{disch}}}} }} + \eta_{{\text{B}}}^{{{\text{ch}}}} {\text{P}}_{{{\text{B}},{\text{t}}}}^{{{\text{ch}}}} } \right) ,$$
(19)

where \(\Delta {\text{t}}\) is sampling time. \({\text{C}}_{{\text{B}}}^{{\text{m}}}\) is maximum capacity of storage battery. \({\text{C}}_{{\text{B}}}^{{\text{t}}}\) and \({\text{C}}_{{\text{B}}}^{{{\text{t}} + 1}}\) are normalized state-of-charge (SOC) of battery storage at t, t + 1 time instants. \({\text{P}}_{{{\text{B}},{\text{t}}}}^{{{\text{ch}}}}\) and \({\text{P}}_{{{\text{B}},{\text{t}}}}^{{{\text{disch}}}}\) are the charging and discharging powers of battery storage system. \(\eta_{{\text{B}}}^{{{\text{ch}}}}\) and \(\eta_{{\text{B}}}^{{{\text{disch}}}}\) are charging and discharging efficiencies of storage batteries. The battery SOC is restricted by,

$$C_{B,b}^{min} \le C_{B,b} \le C_{B,b}^{max} ,$$
(20)

where \(C_{B,b}^{min}\) and \(C_{B,b}^{max}\) are minimum and maximum limits of battery SOCs at bth node. The maximum charging and discharging power limits of battery storages are expressed as,

$$P_{B,b}^{ch,min} \le P_{B,b}^{ch} \le P_{B,b}^{ch,max} ,$$
(21)
$$P_{B,b}^{disch,min} \le P_{B,b}^{disch} \le P_{B,b}^{disch,max} ,$$
(22)

where \(P_{B,b}^{ch}\) is the charging power of storage battery at bth node, and \(P_{B,b}^{disch}\) is the discharging power of storage battery at bth node.

3.4 Modeling of Supercapacitors

Supercapacitors store energy electrostatically, which gives high power density and last for millions of charge/discharge cycles without losing energy storage capacity. But, they are extremely expensive. Charge/discharge equation of supercapacitors is represented by [19],

$${\text{C}}_{{{\text{SC}}}}^{{{\text{t}} + 1}} = {\text{C}}_{{{\text{SC}}}}^{{\text{t}}} - \frac{{\Delta {\text{t}}}}{{{\text{C}}_{{{\text{SC}}}}^{{\text{m}}} }}\left( {\frac{{{\text{P}}_{{{\text{SC}},{\text{t}}}}^{{{\text{disch}}}} }}{{\eta_{{{\text{SC}}}}^{{{\text{disch}}}} }} + \eta_{{{\text{SC}}}}^{{{\text{ch}}}} {\text{P}}_{{{\text{SC}},{\text{t}}}}^{{{\text{ch}}}} } \right),$$
(23)

where \({\text{C}}_{{{\text{SC}}}}^{{\text{m}}}\) is maximum capacity of supercapacitor. \({\text{C}}_{{{\text{SC}}}}^{{\text{t}}}\) and \({\text{C}}_{{{\text{SC}}}}^{{{\text{t}} + 1}}\) are normalized SOC of supercapacitors at t, t + 1 time instants. \({\text{P}}_{{{\text{SC}},{\text{t}}}}^{{{\text{ch}}}}\) and \({\text{P}}_{{{\text{SC}},{\text{t}}}}^{{{\text{disch}}}}\) are charging and discharging powers of supercapacitors. \(\eta_{{{\text{SC}}}}^{{{\text{ch}}}}\) and \(\eta_{{{\text{SC}}}}^{{{\text{disch}}}}\) are charging and discharging powers of supercapacitors. The supercapacitors SOC is restricted by [17],

$$C_{SC}^{min} \le C_{SC} \le C_{SC}^{max} ,$$
(24)

where \(C_{SC}^{min}\) and \(C_{SC}^{max}\) are minimum and maximum limits of supercapacitor SOCs. Maximum charging and discharging power limits of supercapacitors are expressed as,

$$P_{SC,u}^{ch,min} \le P_{SC,u}^{ch} \le P_{SC,u}^{ch,max} ,$$
(25)
$$P_{SC,u}^{disch,min} \le P_{SC,u}^{disch} \le P_{SC,u}^{disch,max} ,$$
(26)

where \(P_{SC,u}^{ch}\) is the charging power of supercapacitor at uth node, and \(P_{SC,u}^{disch}\) is the discharging power of supercapacitor at uth node.

4 GAMS and Differential Evolution Algorithm

The nonlinear models created with generalized algebraic modeling system (GAMS) must be solved with a nonlinear programming (NLP) algorithm. In this paper, the CONOPT solver for NLP imbedded in the GAMS software package is used for solving the optimal operation problem of railway systems. CONOPT implements a generalized reduced gradient (GRG) method. The reader may refer references [25, 26] for detailed description of CONOPT solver.

Differential evolution algorithm (DEA) is a stochastic, reliable, versatile function optimizer. It is a population based meta-heuristic optimization algorithm, and it is developed to optimize real parameter and real valued functions. It can be used for solving various practical problems considering non-continuous, non-differential, non-linear, and multi-dimensional features. The DEA consists of initialization, mutation, crossover and selection operators. The detailed description of these operators and its implementation is presented in references [27, 28].

5 Simulation Results

The proposed optimization problem is solved by using the CONOPT solver of GAMS, and it is tested on a sampled test system described in references [29, 30]. Here, it is considered that the minimum amount of active power generation from the network at ith node (i.e.,\(P_{Gi}^{min}\)) is − 6 MW. This indicates that 6 MW of regenerative power can be fed back to the main utility grid [12]. On the other hand, the amount of power consumed from the main utility grid (\(P_{Gi}^{max}\)) is considered to be 12 MW. In this work, it is considered that the electrified trains are running in both directions. All the optimization programs are implemented on a personal computer with a 3.6 GHz Intel Core i7 and 16 GB RAM.

Figure 2 depicts the power demands data of trains 1 and 2 considered in the simulations of this paper. All the simulation studies executed in this paper considers a time period of (17:00–18:00) h with a time step (i.e., Δt) of 30 s. This 1 h time period leads to 120, 30 s sub-intervals. However, the energy price data is available on hourly basis. But, in this work, it is considered that the data of energy price is available for every 5 min for 1 h operating period. Figure 3 depicts the energy price data for the considered operating period.

Fig. 2
figure 2

Power demands data of trains 1 and 2 used in simulation studies

Fig. 3
figure 3

Energy price data for 1 h operating period

In this work, simulations are performed for four different cases to validate the performance of proposed optimal operation of electrified railways. These four cases are solved by using the CONOPT solver of GAMS software package. The obtained results are also compared with meta-heuristic based differential evolution algorithm (DEA). Simulation results for four cases are presented in the following subsections.

5.1 Case 1: Optimal Operation of Electrified Railways Without Considering RERs and Storage

In this work, it is assumed that the amount of power output from wind and solar PV units are also considered as dispatchable/schedulable. In Case 1, Eq. (1), i.e., the total operating cost (TOC) minimization objective consists only first and last terms. This case study does not includes wind, solar PV power, battery storage and supercapacitors. In this case, the grid power and available excess power due to regenerative braking are optimized to obtain the minimum total operating cost. As mentioned earlier, in this paper, CONOPT solver of GAMS software is used to solve the proposed optimization problem. The obtained results are also compared with meta-heuristic based differential evolution algorithm (DEA). Figures 4 and 5 depict the amount of power absorbed/delivered to main utility grid by using CONOPT solver of GAMS and DEA, respectively.

Fig. 4
figure 4

Power delivered/absorbed by the utility grid by using CONOPT solver of GAMS software

Fig. 5
figure 5

Power delivered/absorbed by the utility grid by using differential evolution algorithm (DEA)

Scheduled power generations and objective function values for cases 1, 2, 3 and 4 using CONOPT solver of GAMS and DEA are presented in Table 1.

Table 1 Scheduled generations and objective values for different cases using CONOPT solver of GAMS and DEA

In case 1, the total power generation, amount of excess power available and TOC obtained by using CONOPT solver are 4.861 MWh, 1.150 MWh and 326.11 $/h, respectively; whereas by using meta-heuristic based DEA are 4.904 MWh, 1.147 MWh, and 326.85 $/h, respectively. These simulation results confirms the effectiveness of solving the proposed optimization problem by using CONOPT solver of GAMS software package.

5.2 Case 2: Optimal Operation of Electrified Railways with RERs

Here, the TOC minimization objective function consists all the terms in Eq. (1) except fourth and fifth terms, as they are related to storage systems. In case 2, the TOC minimization objective function consists all the terms in Eq. (1) except fourth and fifth terms, as they are related to storage systems. Case 2 is optimized by considering the schedulable/dispatchable nature of wind and solar PV units and to account the power from regenerative braking. Here, the optimal operation of electrified railways is performed by considering the wind and solar PV units into the system.

In this work, the rated capacity of WEG (\(P_{r}\)) is considered as 3 MW, \(v_{r}\) is 12 m/s, \(v_{ci}\) is 3 m/s, and \(v_{co}\) is 20 m/s. Figure 6 depicts the wind speed forecast for the selected operating period (17:00–18:00 h). The amount of wind power generated based on available wind speed is calculated based on Eq. (13). But, the actual wind power output is calculated by using the probability analysis. As explained earlier, the Weibull PDF is used to handle the wind power uncertainty.

Fig. 6
figure 6

Wind speed and solar irradiation during operating period (17:00–18:00 h)

The maximum capacity of solar PV system (\(P_{r}^{S}\)) selected in this work is 2 MW. Figure 6 shows the forecasted solar irradiation during the operating period (17:00–18:00 h). For this selected solar irradiation, the amount of solar PV power output obtained is calculated by using Eq. (16). Weibull PDF based bi-modal distribution function is selected to handle the uncertainty of solar PV power.

From Table 1, it can be observed that for case 2, the amount of total power absorbed from utility grid, wind and solar PV power outputs obtained by using CONOPT solver of GAMS software are 4.012 MWh, 1.265 MWh and 0.842, respectively. Whereas, these values by using DEA are 4.054 MWh, 1.233 MWh and 0.831 MWh, respectively. The available excess energy obtained by using GAMS is 1.508 MWh whereas by DEA is 1.5 MWh.

The optimum TOC obtained in this case by using CONOPT solver of GAMS software is 306.59 $/h, and it is 5.98% less than TOC obtained from Case 1. The optimum TOC obtained in this case by using DEA is 307.62 $/h, and it is 5.88% less than TOC obtained from case 1. These simulation results confirms the effectiveness of solving the proposed optimization problem by using CONOPT solver of GAMS software package.

5.3 Case 3: Optimal Operation of Electrified Railways with Storage

TOC of the system can be reduced by increasing the storage capacity of supercapacitors and batteries. But, it increases total investment cost of storage system. The rated capacities of storage battery and supercapacitor considered in this work are 0.5 MW and 1.5 MW, respectively. The charge/discharge efficiencies of battery storage and supercapacitors are 0.9 and 0.95, respectively. Maximum and minimum SOC of both battery storage and supercapacitor are assumed to be 100% and 25%, respectively.

In this case 3, TOC minimization objective function consists all the terms of Eq. (1) except second and third terms. Figures 7 and 8 show the SOC of storage battery and supercapacitor by using CONOPT solver of GAMS software and DEA, respectively.

Fig. 7
figure 7

State of charge (SOC) of battery and supercapacitor by using CONOPT solver of GAMS software

Fig. 8
figure 8

State of charge (SOC) of battery and supercapacitor by using DEA

After solving the proposed optimization problem by using CONOPT solver of GAMS software, the obtained total power absorbed from main utility grid, energy obtained from storage battery and supercapacitor are 4.172 MWh, 0.458 MWh and 0.340 MWh, respectively. The available excess energy in this case is 1.311 MWh. The TOC obtained in this case is 289.82 $/h, which is 11.13% less than TOC obtained from case 1, and 5.47% less than case 2.

The proposed optimization problem is also solved by using DEA, and the obtained total power absorbed from main utility grid, energy obtained from storage battery and supercapacitor are 4.205 MWh, 0.451 MWh and 0.328 MWh, respectively. The available excess energy in this case is 1.273 MWh. The TOC obtained in this case is 291.07 $/h, which is 10.95% less than the cost obtained from case 1, and 5.38% less than case 2.

5.4 Case 4: Optimal Operation of Electrified Railways Considering Both RERs and Storage

In this case, the TOC minimization objective function, i.e., the objective function consists all the terms of Eq. (1). Here TOC is minimized by considering the schedulable/dispatchable nature of wind, solar PV units, batteries and supercapacitors by accounting the power from regenerative braking. The simulation results obtained by using CONOPT solver of GAMS software are the total power absorbed from main utility grid, wind, solar PV power outputs, energy output storage battery and supercapacitor are 3.711 MWh, 1.209 MWh, 0.825 MWh, 0.380 MWh and 0.242 MWh, respectively. The optimum TOC obtained in this case is 283.44 $/h, which is 13.08% less than the TOC obtained from case 1, 7.55% less than case 2 and 2.20% less than case 3.

The obtained results are also compared with DEA. Total power absorbed from main utility grid, wind, solar PV power outputs, energy output storage battery and supercapacitor are 3.803 MWh, 1.167 MWh, 0.819 MWh, 0.386 MWh and 0.245 MWh, respectively. The optimum TOC obtained in this case is 284.18 $/h, which is 13.05% less than TOC obtained from case 1, 7.62% less than case 2 and 2.37% less than case 3.

These simulation results confirms the effectiveness of solving the proposed optimization problem by using CONOPT solver of GAMS software package.

6 Conclusions

A methodology for optimal operation of electrified railway systems including renewable energy resources (RERs) such as wind and solar PV units, regenerative braking, battery storage and supercapacitors is proposed in this paper. In this work, minimization of total operating cost of electrified railway system is considered as an objective function which consisting of cost of power generation from the external power system, cost of power obtained from RERs such as wind and solar PV sources, cost of power from storage systems such as battery storage and supercapacitors, and the income obtained by selling excess power back to the main electrical grid. The proposed AC-OPF problem is solved by using CONOPT solver of generalized algebraic modeling system (GAMS) software, which is a powerful and efficient optimization tool. The obtained results are also compared with meta-heuristic based differential evolution algorithm (DEA). The obtained simulation results confirms the effectiveness of solving the proposed optimization problem by using CONOPT solver of GAMS software package. Performing the optimal operation of power system considering the investment cost of railway system and its application for the microgrids in railway stations is a scope for future research work.