Skip to main content

Optimal Charge Scheduling of Electric Vehicles in Solar Energy Integrated Power Systems Considering the Uncertainties

  • Chapter
  • First Online:
Electric Vehicles in Energy Systems

Abstract

Nowadays, vehicle to grid (V2G) capability of the electric vehicle (EV) is used in the smart distribution network (SDN). The main reasons for using the EVs, are improving air quality by reducing greenhouse gas emissions, peak demand shaving and applying ancillary service, and etc. So, in this chapter, a non-linear bi-level model for optimal operation of the SDN is proposed where one or more solar based-electric vehicle parking lots (PLs) with private owners exist. The SDN operator (SDNO) and the PL owners are the decision-makers of the upper-level and lower-level of this model, respectively. The objective functions at two levels are the SDNO’s profit maximization and the PL owners’ cost minimization. For transforming this model into the single-level model that is named mathematical program with equilibrium constraints (MPEC), firstly, Karush–Kuhn–Tucker (KKT) conditions are used. Furthermore, due to the complementary constraints and non-linear term in the upper-level objective function, this model is linearized by the dual theory and Fortuny-Amat and McCarl linearization method. In the following, it is assumed that the SDNO is the owner of the solar-based EV PLs. In this case, the proposed model is a single-level model. The uncertainty of the EVs and the solar system, as well as two programs, are considered for the EVs, i.e., controlled charging (CC) and charging/discharging schedule (CDS). Because of the uncertainties, a risk-based model is defined by introducing a Conditional Value-at-Risk (CVaR) index. Finally, the bi-level model and the single-level model are tested on an IEEE 33-bus distribution system in three modes; i.e., without the EVs and the solar system, with the EVs by controlled charging and with/ without the solar system, and with the EVs by charging/discharging schedule and with/without the solar system. The main results are reported and discussed.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 149.00
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 199.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info
Hardcover Book
USD 199.99
Price excludes VAT (USA)
  • Durable hardcover edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Similar content being viewed by others

References

  1. L.P. Fernandez, T.G. San Román, R. Cossent, C.M. Domingo, P. Frias, Assessment of the impact of plug-in electric vehicles on distribution networks. IEEE Trans. Power Syst. 26, 206–213 (2011)

    Article  Google Scholar 

  2. M.S. ElNozahy, M.M.A. Salama, A comprehensive study of the impacts of PHEVs on residential distribution networks. IEEE Trans. Sustain. Energy 5, 332–342 (2014)

    Article  Google Scholar 

  3. C. Weiller, Plug-in hybrid electric vehicle impacts on hourly electricity demand in the United States. Energy Policy 39, 3766–3778 (2011)

    Article  Google Scholar 

  4. J. Mullan, D. Harries, T. Bräunl, S. Whitely, Modelling the impacts of electric vehicle recharging on the Western Australian electricity supply system. Energy Policy 39, 4349–4359 (2011)

    Article  Google Scholar 

  5. J.Y. Yong, V.K. Ramachandaramurthy, K.M. Tan, N. Mithulananthan, A review on the state-of-the-art technologies of electric vehicle, its impacts and prospects. Renew. Sust. Energ. Rev. 49, 365–385 (2015)

    Article  Google Scholar 

  6. A. Jiménez, N. García, Voltage unbalance analysis of distribution systems using a three-phase power flow ans a genetic algorithm for PEV fleets scheduling, in Proceedings of the Power and Energy Society General Meeting, (San Diego, 2012, 22–26 July), pp. 1–8

    Google Scholar 

  7. H. Shareef, M.M. Islam, A. Mohamed, A review of the stage-of-the-art charging technologies, placement methodologies, and impacts of electric vehicles. Renew. Sust. Energ. Rev. 64, 403–420 (2016)

    Article  Google Scholar 

  8. H. Salman, K. Muhammad, R. Umar, Impact analysis of vehicle-to-grid technology and charging strategies of electric vehicles on distribution networks—A review. J. Power Sources 277, 205–214 (2015)

    Article  Google Scholar 

  9. P.S. Moses, S. Deilami, A.S. Masoum, M.A. Masoum, Power quality of smart grids with plug-in electric vehicles considering battery charging profile, in Proceedings of the 2010 IEEE PES Innovative Smart Grid Technologies Conference Europe (ISGT Europe), (Chalmers Lindholmen, Gothenburg, 2010, 11–13 Oct), pp. 1–7

    Google Scholar 

  10. G. Razeghi, L. Zhang, T. Brown, S. Samuelsen, Impacts of plug-in hybrid electric vehicles on a residential transformer using stochastic and empirical analysis. J. Power Sources 252, 277–285 (2014)

    Article  Google Scholar 

  11. E. Akhavan-Rezai, M.F. Shaaban, E.F. El-Saadany, A. Zidan, Uncoordinated charging impacts of electric vehicles on electric distribution grids: Normal and fast charging comparison, in Proceedings of the Power and Energy Society General Meeting, (San Diego, 2012, 22–26 July), pp. 1–7

    Google Scholar 

  12. E. Sortomme, M.A. El-Sharkawi, Optimal scheduling of vehicle-to-grid energy and ancillary services. IEEE Trans. Smart Grid 3(1), 351–359 (2012)

    Article  Google Scholar 

  13. Z. Wang, S. Wang, Grid power peak shaving and valley filling using vehicle-to-grid systems. IEEE Trans. Power Del 28(3), 1822–1829 (2013)

    Article  Google Scholar 

  14. M.A. López, S. De la Torre, S. Martín, J.A. Aguado, Demand-side management in smart grid operation considering electric vehicles load shifting and vehicle-to-grid support. Int. J. Electr. Power Energy Syst. 64, 689–698 (2015)

    Article  Google Scholar 

  15. A. Zakariazadeh, S. Jadid, P. Siano, Multi-objective scheduling of electric vehicles in smart distribution system. Energy Convers. Manag. 79, 43–53 (2014)

    Article  Google Scholar 

  16. F. Fazelpour, M. Vafaeipour, O. Rahbari, M.A. Rosen, Intelligent optimization to integrate a plug-in hybrid electric vehicle smart parking lot with renewable energy resources and enhance grid characteristics. Energy Convers. Manag. 77, 250–261 (2014)

    Article  Google Scholar 

  17. F. Marra, G.Y. Yang, C. Træholt, E. Larsen, J. Østergaard, B. Blažič, W. Deprez, EV charging facilities and their application in LV feeders with photovoltaics. IEEE Trans. Smart Grid 4(3), 1533–1540 (2013)

    Article  Google Scholar 

  18. M.H. Amini, M.P. Moghaddam, O. Karabasoglu, Simultaneous allocation of electric vehicles’ parking lots and distributed renewable resources in smart power distribution networks. Sustain. Cities Soc. 28, 332–342 (2017)

    Article  Google Scholar 

  19. S.M. Mohammadi-Hosseininejad, A. Fereidunian, H. Lesani, Reliability improvement considering plug-in hybrid electric vehicles parking lots ancillary services: A stochastic multi-criteria approach. IET Gener. Transm. Dis. 12(4), 824–833 (2017)

    Article  Google Scholar 

  20. S.M.B. Sadati, J. Moshtagh, M. Shafie-khah, J.P. Catalão, Smart distribution system operational scheduling considering electric vehicle parking lot and demand response programs. Electr. Power Syst. Res. 160, 404–418 (2018)

    Article  Google Scholar 

  21. S.M.B. Sadati, J. Moshtagh, M. Shafie-khah, A. Rastgou, J.P. Catalão, Operational scheduling of a smart distribution system considering electric vehicles parking lot: A bi-level approach. Int. J. Electr. Power Energy Syst. 105, 159–178 (2019)

    Article  Google Scholar 

  22. R. Sioshansi, J. Miller, Plug-in hybrid electric vehicles can be clean and economical in dirty power systems. Energy Policy 39(10), 6151–6161 (2011)

    Article  Google Scholar 

  23. M.S. ElNozahy, M.M.A. Salama, Studying the feasibility of charging plug-in hybrid electric vehicles using photovoltaic electricity in residential distribution systems. Electr. Power Syst. Res. 110, 133–143 (2014)

    Article  Google Scholar 

  24. M. Ghofrani, A. Arabali, M. Ghayekhloo, Optimal charging/discharging of grid-enabled electric vehicles for predictability enhancement of PV generation. Electr. Power Syst. Res. 117, 134–142 (2014)

    Article  Google Scholar 

  25. W. Hennings, S. Mischinger, J. Linssen, Utilization of excess wind power in electric vehicles. Energy Policy 62, 139–144 (2013)

    Article  Google Scholar 

  26. B.S.M. Borba, A. Szklo, R. Schaeffer, Plug-in hybrid electric vehicles as a way to maximize the integration of variable renewable energy in power systems: the case of wind generation in northeaster Brazil. Energy 37(1), 469–481 (2012)

    Article  Google Scholar 

  27. D. Dallinger, S. Gerda, M. Wietschel, Integration of intermittent renewable power supply using grid-connected vehicles–a 2030 case study for California and Germany. Appl. Energy 104, 666–682 (2013)

    Article  Google Scholar 

  28. C. Jin, X. Sheng, P. Ghosh, Optimized electric vehicle charging with intermittent renewable energy sources. IEEE J. Sel. Top. Signal Process. 8(6), 1063–1072 (2014)

    Article  Google Scholar 

  29. A.J. Conejo, M. Carrión, J.M. Morales, Decision making under uncertainty in electricity markets, vol 1 (Springer, New York, 2010)

    Book  Google Scholar 

  30. M. Shafie-khah, P. Siano, D.Z. Fitiwi, N. Mahmoudi, J.P. Catalão, An innovative two-level model for electric vehicle parking lots in distribution systems with renewable energy. IEEE Trans. Smart Grid 9, 1506–1520 (2017)

    Article  Google Scholar 

  31. S. Bahramara, M.P. Moghaddam, M.R. Haghifam, Modelling hierarchical decision making framework for operation of active distribution grids. IET Gener. Transm. Dis. 9(16), 2555–2564 (2015)

    Article  Google Scholar 

  32. M. Esmaeeli, A. Kazemi, H. Shayanfar, M.R. Haghifam, P. Siano, Risk-based planning of distribution substation considering technical and economic uncertainties. Electr. Power Syst. Res. 135, 18–26 (2016)

    Article  Google Scholar 

  33. M. Mazidi, H. Monsef, P. Siano, Incorporating price-responsive customers in day-ahead scheduling of smart distribution networks. Energy Convers. Manag. 115, 103–116 (2016)

    Article  Google Scholar 

  34. S. Talari, M. Yazdaninejad, M.R. Haghifam, Stochastic-based scheduling of the microgrid operation including wind turbines, photovoltaic cells, energy storages and responsive loads. IET Gener. Transm. Dis. 9(12), 1498–1509 (2015)

    Article  Google Scholar 

  35. A. Zakariazadeh, S. Jadid, P. Siano, Stochastic multi-objective operational planning of smart distribution systems considering demand response programs. Electr. Power Syst. Res. 111, 156–168 (2014)

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Appendices

Appendix A: Linear Power Flow

In this chapter, a linear power flow is used based on [20, 30]. This power flow is used only in radial distribution networks. For this purpose, a term is considered as a block to avoid nonlinearities. Note that the EVs in the PLs act as a source at the on-peak hours and as a load at the off-peak or mid-peak hours. The active and reactive power balance in this power flow is shown in Eqs. (4.A.1) and (4.A.2). Of course in the single-level model, instead of the expected value of the charging/discharging power and the output power of the solar system in Eq. (4.A.1), their scenario values are replaced.

$$ {\displaystyle \begin{array}{l}{P}_{sb,t}^{Wh2G}\times {\eta}^{Trans}+{\hat{P}}_{PL,t}^{Solar}+\sum \limits_{EV}{\hat{P}}_{PL, EV,t}^{dch}-\sum \limits_{EV}{\hat{P}}_{PL, EV,t}^{ch}-\sum \limits_{b^{\hbox{'}}}\left[\left({P}_{b,{b}^{\hbox{'}},t,s}^{+}-{P}_{b,{b}^{\hbox{'}},t,s}^{-}\right)+{R}_{b,{b}^{\hbox{'}}}I{2}_{b,{b}^{\hbox{'}},t,s}\right]\\ {}+\sum \limits_{b^{\hbox{'}}}\left({P}_{b^{\hbox{'}},b,t,s}^{+}-{P}_{b^{\hbox{'}},b,t,s}^{-}\right)-{P}_{b,t}^{\mathrm{L}}=0\kern4.25em \forall \mathrm{t},\mathrm{s}\end{array}} $$
(4.A.1)
$$ {Q}_{sb,t}^{Wh2G}-\sum \limits_{b^{\hbox{'}}}\left[\left({Q}_{b,{b}^{\hbox{'}},t,s}^{+}-{Q}_{b,{b}^{\hbox{'}},t,s}^{-}\right)+{X}_{b,{b}^{\hbox{'}}}I{2}_{b,{b}^{\hbox{'}},t,s}\right]+\sum \limits_{b^{\hbox{'}}}\left({Q}_{b^{\hbox{'}},b,t,s}^{+}-{Q}_{b^{\hbox{'}},b,t,s}^{-}\right)-{Q}_{b,t}^{\mathrm{L},}=0\kern4em \forall \mathrm{t},\mathrm{s} $$
(4.A.2)

Note that I2 refers to an auxiliary variable linearly representing the squared current flow I2 in a given branch. At most one of these two positive auxiliary variables, i.e., Pb,b,t,s and Qb,b,t,s, can be different from zero at a time. This condition is again implicitly enforced by optimality. Moreover, Eqs. (4.A.3) and (4.A.4) limit these variables by the maximum apparent power for the sake of completeness.

$$ 0\le \left({P}_{b,{b}^{\hbox{'}},t,s}^{+}+{P}_{b,{b}^{\hbox{'}},t,s}^{-}\right)\le {V}^{Rated}\times {I}^{\max, b,b} $$
(4.A.3)
$$ 0\le \left({Q}_{b,{b}^{\hbox{'}},t,s}^{+}+{Q}_{b,{b}^{\hbox{'}},t,s}^{-}\right)\le {V}^{Rated}\times {I}^{\max, b,{b}^{\hbox{'}}} $$
(4.A.4)

Equation (4.A.5) is presented for the balancing of voltage between two nodes. It should be noted that V2 in Eq. (4.A.5) is an auxiliary variable representing the squared voltage relation.

$$ V{2}_{b,t,s}-V{2}_{b^{\hbox{'}},t,s}-{Z}_{b,{b}^{\hbox{'}}}^2I{2}_{b,{b}^{\hbox{'}},t,s}-2{R}_{b,{b}^{\hbox{'}}}\left({P}_{b,{b}^{\hbox{'}},t,s}^{+}-{P}_{b,{b}^{\hbox{'}},t,s}^{-}\right)-2{X}_{b,{b}^{\hbox{'}}}\left({Q}_{b,{b}^{\hbox{'}},t,s}^{+}-{Q}_{b,{b}^{\hbox{'}},t,s}^{-}\right)=0 $$
(4.A.5)

Equation (4.A.6) is employed for linearizing the active and reactive power flows that appear in the apparent power expression.

$$ V{2}_b^{Rated}I{2}_{b,{b}^{\hbox{'}},t,s}=\sum \limits_f\left[\left(2f-1\right)\Delta {S}_{b,{b}^{\hbox{'}}}\Delta {P}_{b,{b}^{\hbox{'}},f,t,s}\right]+\sum \limits_f\left[\left(2f-1\right)\Delta {S}_{b,{b}^{\hbox{'}}}\Delta {Q}_{b,{b}^{\hbox{'}},f,t,s}\right] $$
(4.A.6)

For the piecewise linearization, Eqs. (4.A.7), (4.A.8), (4.A.9), (4.A.10), and (4.A.11) are represented. The number of blocks required to linearize the quadratic curve is set to 10 according to [20], which strikes the right balance between accuracy and computational requirements. Further descriptions, justifications, and derivations of the network model used in this chapter can be found in [30].

$$ {P}_{b,{b}^{\hbox{'}},t,s}^{+}+{P}_{b,{b}^{\hbox{'}},t,s}^{-}=\sum \limits_f\Delta {P}_{b,{b}^{\hbox{'}},f,t,s} $$
(4.A.7)
$$ {Q}_{b,{b}^{\hbox{'}},t,s}^{+}+{Q}_{b,{b}^{\hbox{'}},t,s}^{-}=\sum \limits_f\Delta {Q}_{b,{b}^{\hbox{'}},f,t,s} $$
(4.A.8)
$$ 0\le \Delta {P}_{b,{b}^{\hbox{'}},f,t,s}\le \Delta {S}_{b,{b}^{\hbox{'}}} $$
(4.A.9)
$$ 0\le \Delta {Q}_{b,{b}^{\hbox{'}},f,t,s}\le \Delta {S}_{b,{b}^{\hbox{'}}} $$
(4.A.10)
$$ \Delta {S}_{b,{b}^{\hbox{'}}}=\frac{V^{Rated}\times {I}^{\max, b,{b}^{\hbox{'}}}}{f} $$
(4.A.11)

Appendix B: Converting the Bi-Level Model to the Single-Level Model

The presented non-linear bi-level model by using the KKT conditions and the dual theory is converted into a linear single-level model. Firstly, by using of KKT optimization conditions (which a series of equal and unequal constraints that are inherently non-linear) a single-level model will be achieved. The presence of complementary constraints is caused by the model to be non-linear. These series of constraints by the Fortuny-Amat and McCarl method which include binary variables, and a very large positive integer will be linear. Then, by using dual theory, the non-linear objective function becomes linear. When the bi-level model is converted to a single-level model, the main objective function of the final model is the linearly objective function of the upper level. Also the constraints of this model are the upper and lower level constraints, KKT’s optimization constraints and linearly KKT’s complementary constraints.

4.1.1 Converting Controlled Charging the Bi-Level Model to the Single-Level Model

At first, the constraints of the lower-level are described as Eqs. (4.I.1), (4.I.2), (4.I.3), (4.I.4), (4.I.5), (4.I.6), (4.I.7), (4.I.8), and (4.I.9):

$$ {C}_1={SOE}_{EV}^{\mathrm{max}}-{SOE}_{PL, EV,t,s}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^1 $$
(4.I.1)
$$ {C}_2={P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^2 $$
(4.I.2)
$$ {C}_3={P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}_{mid/ off- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^3\kern0.5em $$
(4.I.3)
$$ {C}_4={P}_{PL, EV,{t}^{on- peak},s}^{ch- solar}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}}^4 $$
(4.I.4)
$$ {C}_5={P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{on- peak},s}^{ch- solar}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}}^5\kern0.5em $$
(4.I.5)
$$ {SOE}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}-{SOE}_{\mathrm{PL},\mathrm{EV},\mathrm{t}\hbox{-} 1,\mathrm{s}}-\left(\left({P}_{PL, EV,t,s}^{ch- grid}+{P}_{PL, EV,t,s}^{ch- Solar}\right)\times {\eta}^{ch}\right)=0\kern1em \forall \mathrm{PL},\mathrm{EV},\mathrm{t}\succ {\mathrm{t}}^{arv},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t}\succ {\mathrm{t}}^{arv},\mathrm{s}}^6 $$
(4.I.6)
$$ {SOE}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}-{\mathrm{SOE}}_{EV}^{\mathrm{arv}}-\left(\left({P}_{PL, EV,t,s}^{ch- grid}+{P}_{PL, EV,t,s}^{ch- Solar}\right)\times {\eta}_{ch}\right)=0\kern1em \forall \mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^7 $$
(4.I.7)
$$ {SOE}_{PL, EV,t,s}-{SOE}_{EV}^{dep}=0\kern1em \forall \mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^8 $$
(4.I.8)
$$ \sum \limits_{EV}{P}_{PL, EV,t,s}^{ch- Solar}-{P}_{PL,t,s}^{Solar}=0\kern1em \forall \mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^9 $$
(4.I.9)

So, the Lagrangian function can be achieved by Eq. (4.I.10):

$$ {\displaystyle \begin{array}{c}L=\sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}\times {\Pr}_{t^{mid/ off- peak}}^{G2 PL}\\ {}-\left({SOE}_{EV}^{\mathrm{max}}-{SOE}_{PL, EV,t,s}\right)\ {\lambda}_{PL, EV,t,s}^1\\ {}-\left({P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- solar}\right)\kern0.37em {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^2\\ {}-\left({P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- solar}\right)\;{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3\\ {}-\left({P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{ch- solar}\right)\kern0.37em {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^4-\left({P}^{\mathrm{max}}-{P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{ch- solar}\right)\;{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^5\\ {}-\left({SOE}_{PL, EV,t,s}-{SOE}_{PL, EV,t-1,s}-\left({P}_{PL, EV,t,s}^{ch- grid}\times {\eta}^{ch}\right)-\left({P}_{PL, EV,t,s}^{ch- solar}\times {\eta}^{ch}\right)\right){\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t}\succ {t}^{arv},\mathrm{s}}^6\ \\ {}-\left({SOE}_{PL, EV,t,s}-{\mathrm{SOE}}_{EV}^{\mathrm{arv}}-\left({P}_{PL, EV,t,s}^{ch- grid}\times {\eta}^{ch}\right)-\left({P}_{PL, EV,t,s}^{ch- solar}\times {\eta}^{ch}\right)\right){\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^7\ \\ {}-\left({SOE}_{PL, EV,t,s}-{\mathrm{SOE}}_{EV}^{\mathrm{dep}}\ \right){\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^8-\left(\sum \limits_{EV}{P}_{PL, EV,t,s}^{ch- solar}-{P}_{PL,t,s}^{solar}\right){\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^9\end{array}} $$
(4.I.10)

Due to the decision variable in this model, KKT conditions are explained in Eqs. (4.I.11), (4.I.12), and (4.I.13):

$$ {\displaystyle \begin{array}{c}\frac{\partial L}{\partial {P}_{PL, EV,\mathrm{t},s}^{ch- grid}}={\Pr}_{t^{mid/ off- peak}}^{G2 PL}-{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^2+{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3\\ {}+\left({\eta}_{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^6\ \left|{}_{\mathrm{t}\succ {\mathrm{t}}^{\mathrm{arv}}}\right.\right)+\left({\eta}_{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^7\left|{}_{t={t}^{arv}}\right.\right)=0\end{array}} $$
(4.I.11)
$$ {\displaystyle \begin{array}{c}\frac{\partial L}{\partial {P}_{PL, EV,t,s}^{ch- solar}}=-{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^2+{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3-{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^4+{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^5\\ {}+\left({\eta}^{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^6\ \left|{}_{\mathrm{t}\succ {\mathrm{t}}_{\mathrm{arv}}}\right.\right)+\left({\eta}^{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^7\left|{}_{t={t}^{arv}}\right.\right)-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^9=0\end{array}} $$
(4.I.12)
$$ {\displaystyle \begin{array}{c}\frac{\partial L}{SOC_{PL, EV,t,s}}={\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^1+{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t}+1,\mathrm{s}}^6\left|{}_{\mathrm{t}\succ {\mathrm{t}}_{\mathrm{arv}}}\right.-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^6\left|{}_{\mathrm{t}\succ {\mathrm{t}}_{\mathrm{arv}}}\right.\\ {}-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^7\left|{}_{\mathrm{t}={\mathrm{t}}_{\mathrm{arv}}}\right.-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^8\left|{}_{\mathrm{t}={\mathrm{t}}_{\mathrm{dep}}}\right.=0\end{array}} $$
(4.I.13)

The dual variables of unequal constraints are equal or greater than zero, and the dual variables whose constraints are equal to zero are unrestricted in sign. For Eqs. (4.I.1), (4.I.2), (4.I.3), (4.I.4) and (4.I.5), the complementary constraints are as follows, i.e. Eqs. (4.I.14), (4.I.15), (4.I.16), (4.I.17), and (4.I.18).

$$ 0\le {SOE}_{EV}^{\mathrm{max}}\hbox{-} {SOE}_{PL, EV,t,s}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^1\kern0.5em \ge 0 $$
(4.I.14)
$$ 0\le {P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- solar}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^2\ge 0 $$
(4.I.15)
$$ 0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3\ge 0 $$
(4.I.16)
$$ 0\le {P}_{PL, EV,{t}^{on- peak},s}^{ch- solar}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^4\ge 0 $$
(4.I.17)
$$ 0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{on- peak},s}^{ch- solar}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^5\ge 0 $$
(4.I.18)

The linearization of complementary constraints is performed by Fortuny-Amat and McCarl linearization method by Eq. (4.I.19) [21]. Then, Eqs. (4.I.20), (4.I.21), (4.I.22), (4.I.23), and (4.I.24) are obtained.

$$ {\displaystyle \begin{array}{l}0\le {F}_1\perp {F}_2\ge 0\\ {}0\le {F}_1\le U\times M\\ {}0\le {F}_2\le \left(1-U\right)\times M\\ {} U\varepsilon \left[0,1\right]\kern0.24em \end{array}} $$
(4.I.19)
$$ {\displaystyle \begin{array}{l}0\le {SOE}_{EV}^{\mathrm{max}}-{SOE}_{PL, EV,t,s}\le {U}_{PL, EV,t,s}^1\times {M}^1\\ {}0\le {\lambda}_{PL, EV,t,s}^1\le \left(1-{U}_{PL, EV,t,s}^1\right)\times {M}^2\;\end{array}} $$
(4.I.20)
$$ {\displaystyle \begin{array}{l}0\le {P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- solar}\le {U}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^2\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^2\le \left(1-{U}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^2\right)\times {M}^2\kern0.24em \end{array}} $$
(4.I.21)
$$ {\displaystyle \begin{array}{l}0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- grid}-{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- solar}\le {U}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^3\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3\le \left(1-{U}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^3\right)\times {M}^2\end{array}} $$
(4.I.22)
$$ {\displaystyle \begin{array}{l}0\le {P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{ch- solar}\le {U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^4\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^4\le \left(1-{U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^4\right)\times {M}^2\kern0.24em \end{array}} $$
(4.I.23)
$$ {\displaystyle \begin{array}{l}0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{ch- solar}\le {U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^5\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^5\le \left(1-{U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^5\right)\times {M}^2\end{array}} $$
(4.I.24)

The obtained model is a non-linear single-level model, which must be linearized using the dual theory. So, firstly, the dual objective function of the lower-level model is formed as Eq. (4.I.25):

$$ {\displaystyle \begin{array}{l}\operatorname{Maximize}\\ {}+\sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}\left(\begin{array}{l}-\left({SOE}_{EV}^{\mathrm{max}}\times {\lambda}_{PL, EV,t,s}^1\right)-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}_{mid/ off- peak},\mathrm{s}}^3\right)\\ {}-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}}^5\right)+\left({\mathrm{SOE}}_{EV}^{\mathrm{arv}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^7\right)\\ {}+\left({\mathrm{SOE}}_{EV}^{\mathrm{dep}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^8\right)+\left({P}_{PL,t,s}^{Solar}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^9\right)\end{array}\right)\end{array}} $$
(4.I.25)

According to the strong dual theory, the objective functions of the original and dual problems are equal at the optimal point of the decision variables of the two problems; therefore, the non-linear section of the objective function is linear according to Eq. (4.I.26).

$$ {\displaystyle \begin{array}{l}\;\sum \limits_{s=1}^{Ns}{\rho}_s\left(\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{n=1}^N\sum \limits_{t=1}^{24}{P}_{PL,n,{\mathrm{t}}^{mid/ off- peak},s}^{ch}\times {\Pr}_{{\mathrm{t}}^{mid/ off- peak}}^{G2 PL}\ \right)=\\ {}\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}\left({\hat{P}}_{PL, EV,{t}^{mid/ off- peak}}^{ch- grid}\times {\Pr}_{t^{mid/ off- peak}}^{G2 PL}\right)=\\ {}=\sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}\left(\begin{array}{l}-\left({SOE}_{EV}^{\mathrm{max}}\times {\lambda}_{PL, EV,t,s}^1\right)-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3\right)\\ {}-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}}^5\right)+\left({\mathrm{SOE}}_{EV}^{\mathrm{arv}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^7\right)\\ {}+\left({\mathrm{SOE}}_{EV}^{\mathrm{dep}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^8\right)+\left({P}_{PL,t,s}^{Solar}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^9\right)\end{array}\right)\end{array}} $$
(4.I.26)

4.1.2 Converting Charging/Discharging Schedule the Bi-Level Model to the Single-Level Model

At first, the constraints of the lower-level are described as Eqs. (4.II.1), (4.II.2), (4.II.3), (4.II.4), (4.II.5), (4.II.6), (4.II.7), (4.II.8), (4.II.9), and (4.II.10):

$$ {C}_1={SOE}_{PL, EV,t,s}-{SOE}_{EV}^{\mathrm{min}}\ge 0\kern1.25em \forall \mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^1 $$
(4.II.1)
$$ {C}_2={SOE}_{EV}^{\mathrm{max}}-{SOE}_{PL, EV,t,s}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^2\kern0.5em $$
(4.II.2)
$$ {C}_3={P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^3 $$
(4.II.3)
$$ {C}_4={P}^{\mathrm{max}}-{P}_{PL, EV,{t}_{mid/ off- peak},s}^{ch- grid}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^4\kern0.5em $$
(4.II.4)
$$ {C}_5={P}_{PL, EV,{t}^{on- peak},s}^{dch}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}}^5 $$
(4.II.5)
$$ {C}_6={P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{on- peak},s}^{dch}\ge 0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{on- peak},\mathrm{s}}^6 $$
(4.II.6)
$$ {SOE}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}-{SOE}_{\mathrm{PL},\mathrm{EV},\mathrm{t}\hbox{-} 1,\mathrm{s}}+\left(\frac{P_{PL, EV,t,s}^{dch}}{\eta^{dch}}\right)-\left(\left({P}_{PL, EV,t,s}^{ch- grid}+{P}_{PL, EV,t,s}^{ch- Solar}\right)\times {\eta}^{dch}\right)=0\kern1em \forall \mathrm{PL},\mathrm{EV},\mathrm{t}\succ {\mathrm{t}}^{arv},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t}\succ {\mathrm{t}}^{arv},\mathrm{s}}^7 $$
(4.II.7)
$$ {SOE}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}-{\mathrm{SOE}}_{EV}^{\mathrm{arv}}+\left(\frac{P_{PL, EV,t,s}^{dch}}{\eta^{dch}}\right)-\left(\left({P}_{PL, EV,t,s}^{ch- grid}+{P}_{PL, EV,t,s}^{ch- Solar}\right)\times {\eta}^{ch}\right)=0\kern1em \forall \mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^8 $$
(4.II.8)
$$ {SOE}_{PL, EV,t,s}-{SOE}_{EV}^{dep}=0\kern1em \forall \mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}\kern1em {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^9 $$
(4.II.9)
$$ \sum \limits_{EV}{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\kern1em -{P}_{PL,{t}^{mid/ off- peak},s}^{Solar}=0\kern1em \forall \mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}\kern1em {\uplambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^{10} $$
(4.II.10)

Based on the previous part, Eqs. (4.II.11), (4.II.12), (4.II.13), (4.II.14), (4.II.15), (4.II.16), (4.II.17), (4.II.18), (4.II.19), (4.II.20), (4.II.21), (4.II.22), (4.II.23), (4.II.24), (4.II.25), (4.II.26), and (4.II.27) is showing the single-level steps:

$$ {\displaystyle \begin{array}{l}L=\\ {}\sum \limits_{s=1}^{Ns}{\rho}_s\left(\begin{array}{l}\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- grid}\times {\Pr}_{{\mathrm{t}}^{mid/ off- peak}}^{G2 PL}\ \\ {}+\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}{P}_{PL, EV,{t}^{on- peak},s}^{dch}\times \left(0.5{\Pr}_t^{PL2G}+{C}^{cd}\right)\end{array}\right)\\ {}-\left({SOE}_{PL, EV,t,s}-{SOE}_{EV}^{\mathrm{min}}\right)\ {\lambda}_{PL, EV,t,s}^1\\ {}-\left({SOE}_{EV}^{\mathrm{max}}-{SOE}_{PL, EV,t,s}\right)\ {\lambda}_{PL, EV,t,s}^2\\ {}-\left({P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\right)\kern0.37em {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3\\ {}-\left({P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}-{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}\right)\;{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4\\ {}-\left({P}_{PL, EV,{t}^{on- peak},s}^{dch}\right){\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^5-\left({P}^{\mathrm{max}}-{P}_{PL, EV,{t}^{on- peak},s}^{dch}\right){\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^6\\ {}-\left(\begin{array}{l}{SOE}_{PL, EV,t,s}-{SOE}_{PL, EV,t-1,s}-\left({P}_{PL, EV,t,s}^{ch- grid}\times {\eta}^{ch}\right)\\ {}-\left({P}_{PL, EV,t,s}^{ch- Solar}\times {\eta}^{ch}\right)+\left(\frac{P_{PL, EV,t,s}^{dch}}{\eta_{dch}}\right)\ \end{array}\right){\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t}\succ {t}^{arv},\mathrm{s}}^7\ \\ {}-\left(\begin{array}{l}{SOE}_{PL, EV,t,s}-{\mathrm{SOE}}_{EV}^{\mathrm{arv}}-\left({P}_{PL, EV,t,s}^{ch- grid}\times {\eta}^{ch}\right)\\ {}-\left({P}_{PL, EV,t,s}^{ch- Solar}\times {\eta}^{ch}\right)+\left(\frac{P_{PL, EV,t,s}^{dch}}{\eta^{dch}}\right)\end{array}\right){\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^8\ \\ {}-\left({SOE}_{PL, EV,t,s}-{\mathrm{SOE}}_{EV}^{\mathrm{dep}}\ \right){\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^9\\ {}-\left(\sum \limits_{EV}{P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- Solar}-{P}_{PL,{t}^{mid/ off- peak},s}^{Solar}\right){\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^{10}\end{array}} $$
(4.II.11)
$$ {\displaystyle \begin{array}{l}\frac{\partial L}{\partial {P}_{PL, EV,t,s}^{ch- grid}}={\Pr}_{{\mathrm{t}}^{mid/ off- peak}}^{G2 PL}-{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3+{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4\\ {}+\left({\eta}^{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^7\ \left|{}_{\mathrm{t}\succ {\mathrm{t}}^{\mathrm{arv}}}\right.\right)+\left({\eta}^{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^8\left|{}_{t={t}^{arv}}\right.\right)=0\end{array}} $$
(4.II.12)
$$ {\displaystyle \begin{array}{l}\frac{\partial L}{\partial {P}_{PL, EV,t,s}^{ch- Solar}}=-{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3+{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4+\left({\eta}_{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^7\ \left|{}_{\mathrm{t}\succ {\mathrm{t}}_{\mathrm{arv}}}\right.\right)\\ {}+\left({\eta}^{ch}\times {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^8\left|{}_{t={t}^{arv}}\right.\right)-{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^{10}=0\end{array}} $$
(4.II.13)
$$ {\displaystyle \begin{array}{l}\frac{\partial L}{P_{PL, EV,t,s}^{dch}}=0.5{\Pr}_{{\mathrm{t}}_{on- peak}}^{PL2G}+{C}^{cd}-\left(\frac{\lambda_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^7}{\eta^{dch}}\ \left|{}_{\mathrm{t}\succ {\mathrm{t}}_{\mathrm{arv}}}\right.\right)-\left(\frac{\lambda_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^8}{\eta^{dch}}\ \left|{}_{\mathrm{t}={\mathrm{t}}_{\mathrm{arv}}}\right.\right)\\ {}-{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}_{on- peak},\mathrm{s}}^5+{\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^6=0\end{array}} $$
(4.II.14)
$$ {\displaystyle \begin{array}{l}\frac{\partial L}{SOC_{PL, EV,t,s}}={\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t}+1,\mathrm{s}}^7\left|{}_{\mathrm{t}\succ {\mathrm{t}}_{\mathrm{arv}}}\right.-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^7\left|{}_{\mathrm{t}\succ {\mathrm{t}}_{\mathrm{arv}}}\right.-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^8\left|{}_{\mathrm{t}={\mathrm{t}}_{\mathrm{arv}}}\right.\\ {}-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^9\left|{}_{\mathrm{t}={\mathrm{t}}_{\mathrm{dep}}}\right.-{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^1+{\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^2=0\end{array}} $$
(4.II.15)
$$ 0\le {SOE}_{PL, EV,t,s}-{\mathrm{SOE}}_{EV}^{\mathrm{min}}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^1\ge 0\kern0.72em $$
(4.II.16)
$$ 0\le {\mathrm{SOE}}_{EV}^{\mathrm{max}}-{SOC}_{PL, EV,t,s}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},\mathrm{t},\mathrm{s}}^2\kern0.5em \ge 0 $$
(4.II.17)
$$ 0\le {P}_{PL, EV,{\mathrm{t}}_{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- Solar}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}_{mid/ off- peak},\mathrm{s}}^3\ge 0 $$
(4.II.18)
$$ 0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- grid}-{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- Solar}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4\ge 0 $$
(4.II.19)
$$ 0\le {P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{dch}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^5\ge 0 $$
(4.II.20)
$$ 0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{dch}\perp {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^6\kern0.36em \ge 0 $$
(4.II.21)
$$ {\displaystyle \begin{array}{l}0\le {SOE}_{PL, EV,t,s}-{\mathrm{SOE}}_{EV}^{\mathrm{min}}\le {U}_{PL, EV,t,s}^1\times {M}^1\\ {}0\le {\lambda}_{PL, EV,t,s}^1\le \left(1-{U}_{PL,n,t,s}^1\right)\times {M}^2\;\end{array}} $$
(4.II.22)
$$ {\displaystyle \begin{array}{l}0\le {SOE}_{EV}^{\mathrm{max}}-{SOE}_{PL, EV,t,s}\le {U}_{PL,n,t,s}^2\times {M}^1\\ {}0\le {\lambda}_{PL, EV,t,s}^2\le \left(1-{U}_{PL,n,t,s}^2\right)\times {M}^2\;\end{array}} $$
(4.II.23)
$$ {\displaystyle \begin{array}{l}0\le {P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- grid}+{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- Solar}\le {U}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^3\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^3\le \left(1-{U}_{PL,n,{\mathrm{t}}^{mid/ off- peak},s}^3\right)\times {M}^2\kern0.24em \end{array}} $$
(4.II.24)
$$ {\displaystyle \begin{array}{l}0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{\mathrm{t}}_{mid/ off- peak},s}^{ch- grid}-{P}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^{ch- Solar}\le {U}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^4\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4\le \left(1-{U}_{PL, EV,{\mathrm{t}}^{mid/ off- peak},s}^4\right)\times {M}^2\end{array}} $$
(4.II.25)
$$ {\displaystyle \begin{array}{l}0\le {P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{dch}\le {U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^5\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^5\le \left(1-{U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^5\right)\times {M}^2\kern0.24em \end{array}} $$
(4.II.26)
$$ {\displaystyle \begin{array}{l}0\le {P}^{\mathrm{max}}-{P}_{PL, EV,{\mathrm{t}}^{on- peak},s}^{dch}\le {U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^6\times {M}^1\\ {}0\le {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^6\le \left(1-{U}_{PL, EV,{\mathrm{t}}^{on- peak},s}^6\right)\times {M}^2\end{array}} $$
(4.II.27)

The non-linear part of the objective function can be converted to a linear part with two equations i.e. (4.II.28) and (4.II.29).

$$ {\displaystyle \begin{array}{l}\mathit{\operatorname{Maximize}}\\ {}\sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}\left(\begin{array}{l}\left({SOE}_{EV}^{\mathrm{min}}\times {\lambda}_{PL, EV,t,s}^1\right)-\left({SOE}_{EV}^{\mathrm{max}}\times {\lambda}_{PL, EV,t,s}^2\right)\\ {}-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4\right)-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^6\right)\\ {}+\left({\mathrm{SOE}}_{EV}^{\mathrm{arv}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^8\right)+\left({\mathrm{SOE}}_{EV}^{\mathrm{dep}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^9\right)\\ {}+\left({P}_{PL,{t}^{mid/ off- peak},s}^{Solar}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^{10}\right)\end{array}\right)\end{array}} $$
(4.II.28)
$$ {\displaystyle \begin{array}{l}\sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{n=1}^N\sum \limits_{t=1}^{24}\left(\begin{array}{l}\left({P}_{PL,n,{t}^{mid/ off- peak},s}^{ch- grid}\times {\Pr}_{t^{mid/ off- peak}}^{G2 PL}\right)\\ {}+\left({P}_{PL,n,{t}^{on- peak},s}^{dch}\times \left(0.5{\Pr}_{t^{on- peak}}^{PL2G}+{C}^{cd}\right)\right)\end{array}\right)\\ {}=\sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}\left(\begin{array}{l}\left({SOE}_{EV}^{\mathrm{min}}\times {\lambda}_{PL, EV,t,s}^1\right)-\left({SOE}_{EV}^{\mathrm{max}}\times {\lambda}_{PL, EV,t,s}^2\right)\\ {}-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4\right)-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^6\right)\\ {}+\left({\mathrm{SOE}}_{EV}^{\mathrm{arv}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^8\right)+\left({\mathrm{SOE}}_{EV}^{\mathrm{dep}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^9\right)\\ {}+\left({P}_{PL,{t}^{mid/ off- peak},s}^{Solar}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^{10}\right)\end{array}\right)\\ {}\\ {} So:\\ {}\sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}{P}_{PL, EV,{t}^{on- peak},s}^{dch}\times {\Pr}_{t^{on- peak}}^{PL2G}=\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}\left({\hat{P}}_{PL, EV,{t}^{mid/ off- peak}}^{dch}\times {\Pr}_{t^{mid/ off- peak}}^{G2 PL}\right)=\\ {}=2\times \sum \limits_{s=1}^{Ns}{\rho}_s\sum \limits_{PL=1}^{N_{PL}}\sum \limits_{EV=1}^{N_{EV}}\sum \limits_{t=1}^{24}\left(\begin{array}{l}\left({SOE}_{EV}^{\mathrm{min}}\times {\lambda}_{PL, EV,t,s}^1\right)-\left({SOE}_{EV}^{\mathrm{max}}\times {\lambda}_{PL, EV,t,s}^2\right)\\ {}-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{mid/ off- peak},\mathrm{s}}^4\right)-\left({P}^{\mathrm{max}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{on- peak},\mathrm{s}}^6\right)\\ {}+\left({\mathrm{SOE}}_{EV}^{\mathrm{arv}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{arv},\mathrm{s}}^8\right)+\left({\mathrm{SOE}}_{EV}^{\mathrm{dep}}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{\mathrm{t}}^{dep},\mathrm{s}}^9\right)\\ {}+\left({P}_{PL,{t}^{mid/ off- peak},s}^{Solar}\times {\lambda}_{\mathrm{PL},\mathrm{EV},{t}^{mid/ off- peak},\mathrm{s}}^{10}\right)-\left({P}_{PL, EV,{t}^{on- peak},s}^{dch}\times {C}^{cd}\right)\\ {}-\left({P}_{PL, EV,{t}^{mid/ off- peak},s}^{ch- grid}\times {\Pr}_{t^{mid/ off- peak}}^{G2 PL}\right)\end{array}\right)\end{array}} $$
(4.II.29)

Appendix C

The nomenclature is shown below.

Indices

 

b, b

Index for branch or bus

EV

Index for EV number

F

Index for linear partitions in linearization

s

Index for scenarios

sb

Index for slack bus

t, t

Index for time (hour)

Parameters

Ccd

Cost of equipment depreciation ($/kWh)

Imax

Upper limit of branches’ current (A)

Imax, b, b′

Maximum current of branch b, b′ (A)

M

Sufficiently large constants

PL

The demand of customers (kW)

Pmax

Nominal rate of charging/discharging of EVs (kWh)

PSolar

Power generated of the solar system (kW)

PrL

Electricity price for the customer ($/kWh)

PrWh2G

The wholesale market electricity price ($/kWh)

R b, b′

Resistance between branch b, b (Ω)

QL

Customer’s reactive power (kVAR)

SOEarv

Initial SOE of the EVs (kWh)

SOEdep

Desired SOE of the EVs (kWh)

SOEmax

Upper limit of SOE (kWh)

SOEmin

Lower limit of SOE (kWh)

tarv

Arrival time of the EVs to the PL

tdep

Departure time of the EVs from the PL

V Rated

Nominal voltage (V)

Vmax

Maximum allowable voltage (V)

Vmin

Minimum allowable voltage (V)

X b, b′

Reactance between branch b, b (Ω)

Z

Impedance (Ω)

ηch

Charging efficiency (%)

ηdch

Discharging efficiency (%)

ηTrans

Transformer efficiency (%)

ρ

Probability of each scenario

α

Confidence level

β

Risk aversion parameter

ΔS

Upper limit in the discretization of quadratic flow terms (kVA)

Variables

 

B

Profit in each scenario

I,I2

Current flow (A), squared current flow (A2)

Pch-grid

Charging power of the EVs by the SDNO (kW)

Pch-solar

Charging power of the EVs by the power generated of the solar system (kW)

\( {\hat{P}}^{ch- grid} \)

The expected value of charging power of the EVs by the SDNO (kW)

\( {\hat{P}}^{solar} \)

The expected value of the power generated of the solar system (kW)

Pdch

Discharging power of the EVs (kW)

\( {\hat{P}}^{dch} \)

The expected value of discharging power of the EVs (kW)

PLoss

SDN’s losses (kW)

PWh2G

Purchasing power from the wholesale by the SDNO (kW)

P+

Active power flows in downstream directions (kW)

P

Active power flows in upstream directions (kW)

PrG2PL

Charging tariff of the EVs ($/kWh)

PrPL2G

Discharging tariff of the EVs ($/kWh)

QWh2G

SDN’s reactive power (kVAR)

Q+

Reactive power flows in downstream directions (kVAR)

Q

Reactive power flows in upstream directions (kVAR)

SOE

State of energy (kWh)

U

Binary variable

λ

Dual variable ($/kWh)

η

Auxiliary variable for calculating CVaR

ξ

Value-at-risk

Rights and permissions

Reprints and permissions

Copyright information

© 2020 Springer Nature Switzerland AG

About this chapter

Check for updates. Verify currency and authenticity via CrossMark

Cite this chapter

Sadati, S.M.B., Moshtagh, J., Shafie-Khah, M., Rastgou, A., Catalão, J.P.S. (2020). Optimal Charge Scheduling of Electric Vehicles in Solar Energy Integrated Power Systems Considering the Uncertainties. In: Ahmadian, A., Mohammadi-ivatloo, B., Elkamel, A. (eds) Electric Vehicles in Energy Systems. Springer, Cham. https://doi.org/10.1007/978-3-030-34448-1_4

Download citation

  • DOI: https://doi.org/10.1007/978-3-030-34448-1_4

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-030-34447-4

  • Online ISBN: 978-3-030-34448-1

  • eBook Packages: EnergyEnergy (R0)

Publish with us

Policies and ethics