Electric Vehicles Charging Management for Real ‐ Time Pricing Considering the Preferences of Individual Vehicles

: The paper proposes a real ‐ time model for electric vehicles (EVs) controlled load charging. The proposed demand ‐ side management (DSM) of EVs is implemented based on queuing analysis with a nonhomogeneous arrival rate and charging service periods dataset. An electric vehicle model is used which is based on a statistical survey to represent the uncontrolled demand of the EVs. A probability distribution for the time at which EVs are plugged and the corresponding value of the state of charges (SOCs) are considered. The preferences of individual EVs have been fully exploited through a set of instructions to fulfill the needs of the vehicles’ owners. The designated preferences include the owner setting for both, charging price preferences (OPR), and the maximum estimated parking time duration (EPTD). The quasi ‐ static time ‐ series (QSTS) simulation is used to simulate real ‐ time scenarios of the 24 ‐ h simulation period. The IEEE 123 nodes radial test feeder is analyzed with different daily load curves, EV charging scenarios, and wind power penetrations. The results show the effectiveness of the proposed DSM in avoiding excessive levels of charging with/without penetration of non ‐ dispatchable wind power generation. The proposed DSM enables the EVs to charge with low tariff rates either at excessive renewable power generation or late evening hours with available committed bulk power plants and light loading conditions.


Introduction
Electric vehicles are the result of recent developments in modern transportation due to the growing concerns over carbon and greenhouse effects and reduce carbon emissions [1,2]. EVs became an essential approach to solve environmental problems because they have zero emissions and low noise [3]. The increase in the number of EVs is welcomed by green energy supporters [4]. However, uncoordinated EV charging results in undesirable impacts on the operation and performance of electrical systems [5][6][7]. In consequence, the EVs charging process is managed to reduce congestion or to balance the load and achieve peak load shaving [8]. Various studies have been reported to explore the effects of EVs charging on electrical power systems [9][10][11][12][13][14][15][16][17]. As an example, EV charging could lead to voltage variation, increase the load, and increase power losses of electrical grids [18]. Moreover, EV charging could affect the generation scheduling of the thermal generation units as well as the wind power plants [19].
The random nature of the EV state plays the main role in developing the EV model. The EV charging profile is determined in terms of several factors [11]: (1) the number of EVs, (2) the battery type, (3) the initial state of charge (SOC) at the beginning of the charging process, (3) the start time of EV charging process, and (4) type and location of chargers [20]. The initial SOC of EVs' batteries always subject to an element of randomness, but the general pattern is influenced by the battery usage. The charge rate of EV batteries during the charging process should also follow the general charging characteristics determined by the battery type and the charging mode [21]. The normal and quick EV charging on regular weekdays and off-peak days in both summer and winter have been studied in [22].
Several statistical models have been proposed based on the random SOC that depended on the vehicle traveled distance. A statistical model was presented based on the National Travel Survey data [23]. The EV's battery capacity, SOC, and energy consumption are used to model the EVs charging to assess their impact on the residential loads [24]. The probabilistic using Monte Carlo simulation of EVs has been developed with considering two EVs random variables: the time for vehicle arrival and energy demand [25]. The uncertainties characteristic of the EV is fully exploited whereas the transportation data have been used to extract the probability density function (pdf) [26].
The coordination of EV charging is very important to avoid many severe effects on power grids. Many control schemes have been proposed to overcome the negative impacts of EV charging. A control strategy using data-driven models has been implemented to relax power system components and prevent excessive loading due to EV charging demand [27][28][29]. Demand side management (DSM) works to guarantee EVs' demand satisfaction in all grid situations and certifies grid stability [30][31][32][33][34]. At a low voltage transformer, DSM is used to shave the daily load while satisfying the EV charging process [35]. Real-time energy management is developed to reduce the EVs charging cost, and eliminate the charging impact with the existence of a photovoltaic (PV) system [36]. A control strategy is also developed for dynamic peak shaving at various scenarios considering the EV owner preferences [17]. A smart charging strategy with a two-stage optimization technique is applied to minimize the total energy loss at different penetration levels of EVs whereas the reactive power compensation from vehicle to grid (V2G) mode is utilized to reduce the energy losses [37]. A bi-directional charging power control of aggregated EV is analyzed in time series to assess generation modes [38].
A mathematical model-based M/M/s queue is presented using the fluid dynamic model to forecast the charging demand [39]. The model of EVs is used in the probabilistic load flow and the queueing theory to obtain the charging load of multiple EVs [40]. A nonhomogeneous Poisson process for the arrival rate of the EV during 24 h is used to create a suitable load profile [7]. The arrival rate is modeled based on the vehicle owner's price preference whereas the probability of arriving vehicle in charging station is increased at lower prices and vice versa [7]. The electricity price is going to be affected by the integration of non-dispatchable renewable energy resources resulting in a dynamic electricity tariff [41]. The impacts of wind power generation on the electricity price in Germany is reported in a comprehensive study showing that wind power generation reduces the wholesale electricity price [42]. Recent research implementation using the queue model emphasizes the EV satisfaction level and preserves power networks [13]. In addition, incentive prices not only achieve reduced cost but improve the utilization of charging infrastructure [43]. In [44], the controlled charging demand is calculated by using a queuing model and integrated into the economic dispatch algorithm to find the optimal charging plan of each EV.
In this paper, a virtual queue is continuously developed to account for EVs owner satisfaction and to avoid excessive EVs charging load. The developed model is quite simple and any EVs plugged into the system can participate in the queue. The owner satisfaction is based on saving both the time and cost of the charging process during two scenarios for wind power generation. The main contributions of this work could be summarized as follows:  Developing queue model to account for owner preferences such as electricity tariff rate (ETR) and estimated parking time duration (EPTD) (the time that the owner could keep his vehicle plugged in the grid).


Using incentive electricity tariffs with wind power generation and investigating their impact on both owner and the grid in terms of charging cost and peak load shifting respectively.  Simulation of 24-h scenarios using accelerated quasi-static time series (QSTS) engine [45,46].
The organization of the paper is as follows: Section 2 describes the mathematical model of queuing theory. Section 3 proposes the DSM using queuing theory. Section 4 presents the numerical results based on the standard IEEE 123-node test system. Finally, the conclusions are presented in Section 5.

Mathematical Formulation of Queue
This section presents the queuing analysis used to control EV's charging load. Figure  1 shows the schematic diagram for a population of EVs connected to the network to start the charging process. From the network point of view, the process is a queueing system consisting of three main parts:  Arrivals of EVs characterized by a statistical distribution with an arrival rate which is represented by a number NEV of the EV connected to the grid at a specific time T (see Figure 1)  EVs queue includes several EVs waiting in a line to charge. It should be mentioned here that the line represents EVs connected to the network and all vehicles are connected to the network and are either charging or not.  The charging service includes several servers (charging points NCP) subject to a statistical distribution of service times (charging time).
Hence, the DSM for EVs charging can be defined as a multi-servers (M/M/s) queue with identical server number (charging points) NCP. Each charging point has an operating process with an exponential Poisson service rate . The most important parameters for any queue are: the average time spent in the queue, average queue length, and the overall average time spent in the system [47]. To obtain these parameters, a Markov chain is used in the queueing analysis [48].
A sequence of random variables , , , … . is defined as a Markov chain for n steps, where the transition probability to the following state only depends on the current state.
where is the probability. The transition probability between two state i and j in n steps can be expressed as: where the transition matrix can be expressed as: (3) Figure 1. The schematic diagram for EVs charging process with a dynamic queue model.
In this work, the arranged EVs in the queue is considered the state of the chain, where the state transition occurs when an EV arrived, or a connected EV reached its full charge state , hence it is virtually unplugged viz., idle state, or to depart physically. A birthdeath is applied as a stochastic model to represent the evolving process of the system, wherein the queuing model "birth" denotes the customer arrival while "death" denotes the customer departure. The transition rate diagram is exhibited in Figure 2. The figure shows the transition for NEV states when all states have an arrival rate λ but there are two different service rates. In case of the number of EV less than the charging point NCP number (NEV < NCP) the service rate is otherwise, in case of the number of EV greater than the charging point number (NEV > NCP) in which all charging points have occupied, the rate is . By applying the Markov chain using the transition rate diagram shown in Figure 2 the transition probability matrix can be written as in (4).
The stationary condition which describes the steady-state condition is expressed by the following equation: where is the stationary vector … … . The general formula for the stationary distribution at any state n can be written as: The value of can be calculated using the total probability condition as follows: Consequently, the value of can be calculated using the following equation.
Thus, the performance of the queuing model can be determined once the initial condition is given. The average number of EVs available in the system is computed as follows: The number of EVs waiting in the queue can be expressed [49]: (11) The overall time spent in the system can be calculated using: However, the average waiting time in the queue can be given by [49]:

Numeric Example for the Queuing Model
This section gives a simple example of the queuing model that is used for EV arriving in the charging station. Figure 3 presents the main inputs and outputs of the queuing model. Hence, the following numeric example demonstrates the application of this model in the EV-arriving process.
Assume that a charging station has charging points = 3 and the arrival rate of the EV at this station 5 /ℎ . The charging point can charge the EV to be fully charged in 30 hence, the service rate is 2 EV/hr. Arriving EV balks when 6 EVs are in the system. Hence, to calculate the average waiting time and the overall time that the EV number 6 takes in the queue, the queue model is applied as follows: To calculate the stationary vector for all state (EV = 6), should be evaluated first by applying (9), hence 0.068. Then the from 1 6 can be calculated using (6). The first part of the Equation (6) will be applied as 1 2, which is and the values will be as follows: The overall values of the stationary vector are calculated and arranged in Table 1. The probability that all charging points are idle is: The probability that an EV will not have to wait is: The probability that an EV will have to wait is: The probability that an EV balk is: The average number of EVs available in the system is computed using (10) is:

2.944
The number of EVs waiting in the queue based on (11) is

0.700
The overall time spent in the system can be calculated using (12) is: The average waiting time in the queue can be given by (13) is:

Owner Preferences
The developed queue charging model uses the owner's preferences to manage demand and guarantee user satisfaction. Two factors are required from the owner: the owner preferred price-setting OPR and the EPTD. A real-time electricity tariff rate (ETR) variation is illustrated in Figure 4 hence, each owner can adopt his OPR, at which the battery starts charging. Related to the preferred price (see Figure 2) the marked portions represent cheap electricity prices to decrease the total cost of the charging where the cost can be calculated as (14) where, is the total charging cost, is the electricity tariff rate at time T, is the charging power, and are the starting and ending times of charging. In consequence, the EV charging process will respond with the changing of the realtime price, in addition, the owner can determine EPTD.

EVs Charging Queue
The charging strategy of the EV can be implemented using the queue model based on the owner's preferences. As presented in the previous subsection, the owner feeds the control system with the EPTD and OPR when its EV is plugged in, then based on the owner's OPR and the ETR, the queue model arranges the EV as presented in Algorithm 1 and shown in Figure 5. Update EPTD and OPR 10: if1 11: State the EV to charging mode 12: else if1 13: Increment 1

Implementation of Real-Time Simulation with EV Charging
To study the impact of EV charging on the grid load demand, a real-time simulation is essentially required. Hence, in this work, QSTS simulation is used to compute a 24-hr simulation period. In contrary to classical snapshot power flow simulation, QSTS is a sequential time series power flow and can be performed based on a varying load demand during a period. The classical loads such as commercial, industrial, residential are varying based on the daily load curves. However, to simulate the random behavior of EV load demand during 24 hrs without control, a statistical model can be used based on the lognormal distribution of the traveling millage to calculate the SOC and normal distribution of the plugin time . Then, at each instant time T, the load of the EV can be estimated based on the number of the plug-in EVs and their SOC at this instant plus the classical load.
To manage and control the EVs load demand, a DSM is proposed in this work based on the queue as presented in Figure 6.  , and . When the is greater than the ETR, the queuing algorithm generates the waiting time Tq, and the time spent in the system Ts for each EV. The controller then decides when the battery should charge or be idle. After the demand is determined, the total EV load is added to the classical demand, then the QSTS simulation is applied to compute a 24-hr simulation period.  Figure 6. Queuing management strategy for demand response at instant T for EVs aggregation N, at bus k.

Test System Description
The IEEE 123 nodes test feeder is used to studying the feasibility of the proposed DSM for EVs charging load. The data of the feeder are extracted from [50]. Three different classical load profiles (residential, commercial, and industrial) are used as shown in Figure 7. Sample time of 1 min is chosen to run the QSTS. The QSTS is implemented using a sequential power-flow solver that is based on forward/backward sweep and programmed in C++ with a personal computer (Core I7, 2.66 GHz processor with 8 GB RAM). The nodes of the IEEE 123 test feeder are categorized into three types: residential, commercial, and industrial [46]. The residential demand is assumed to involve 40% of EV's power penetration level with respect to the total demand of IEEE 123 nodes test feeder, hence, 400 EVs are used. It is assumed that all EVs use GMEV1 battery type, and it is satisfactory for the battery to reach 90% SOC.
The following different case studies are examined:  Base case (without EV): this case represents the IEEE 123 with considering classical loads profile only.  Case 1: (Uncontrolled EVs Charging) in this case, a statistical model [11] is used to present the impact of EV charging with the classical loads of the distribution system.  Case 2: (Controlled EVs Charging) DSM based on queueing theory is used to manage the EVs charging demand with consideration of owner preferences.  Case 3: Wind power generation is integrated to show its influence on the ETR and the total demand.

Generation of Case Datasets
In this work, for real-time management of the EVs charging based on the queue model, a set of data is generated to represent the arrival of electric vehicles into the grid. a non-homogeneous Poisson process is used to represent the arrival rate which is dependent on the statistical model of EV as shown in Figure 8. Furthermore, the battery's characteristic is considered in the charging service rate and the number of servers' changes based on the ETR. The pdf for the traveled miles and plugged-in time is used to distribute the 400 EVs randomly. The generated EVs distribution is used as input data to test out the proposed method. The lognormal distribution for the traveled distance is carried out using the mean value of 22.3 miles and the standard deviation of 12.4 miles. The plugged-in time is distributed normally with a mean of 1:00 AM and a standard deviation of 5 h [51]. The results of this algorithm are shown in the 3-D plot in Figure 9.

Case 1 Results (Uncontrolled EVs Charging)
The uncontrolled EV charging impact is depicted in Figure 10, based on the statistical distribution [11] for the plugged time introduced in Figure 9, the majority of EVs connected to the grid in the time between 0:00 and 04:00, and their charging process increases the total demand from 1.5 p.u to 2.0 p.u as shown in Figure 8. With the number of connected EVs decreasing, and the charged EVs disconnecting, the total demand is reduced between 09:00 to 16:00. The load starts to increase again in the remaining time of the day.

Case 2 Results (Owner Preferences)
In the developed DSM, each EV owner feeds the system with two control signals, the , and the price reference . To model the owner preferences in this work, a normal distribution for both signals is generated. It is assumed that the mean EPDT is 6.00 hr with 1.00 hr stander deviation, on the other hand, the OPR has a mean equal to 0.45 per unit price and 0.05 stander devotion. The obtained distribution results for both signals are exhibited in Figure 11. Based on the owner signals and the real-time ETR (see Figure 4) [16] which is provided by the DSM, the developed DSM based on the queuing theory gives the priority for the EV to charge or to be in the idle state. Figure 12 shows the demand for this case and it can be noted that an amount of demand has been shifted to the time where the ETR is low to avoid the high charging cost.

Impact of Wind Power on ETR
Electrical systems use economic dispatch and unit commitment to ensure that power delivery to the load remains within the power system transmission and generation constraints, however, with the integration of renewable energy resources which have an intermittent nature as shown in Figure 13. Hence, wind power is non-dispatchable over time. Consequently, the best solution is to reduce the electricity price, which, gives controllable loads (COLs) such as EVs the availability to consume the extra generated power.
This case study gives a new vision of how the integration of renewable energy resources can be more useful for both generations and the load side. The wind power generation is integrated with the IEEE-123 node system, with the maximum penetration of the wind power chosen to be 20% of the total demand of the IEEE-123 node. It is assumed that when the wind power generation is more than 60% of the total penetration the DSM should reduce the ETR to the minimum value. As such, the connected idle EVs can charge the excess generation power instead of shutting down generation units or using wind power curtailment. Hence, the change in ETR in the existence of wind power is exhibited in Figure 14.

Case 3 Results
In this case, wind power generation (see Figure 13) is used with the EV's DSM. The impact of wind energy intermittency on the total demand is illustrated in Figure 15 and it can note that the wind power generation shaves the peak demand caused by the EVs charging and the impact of the wind power in the EVs charging behavior is described in the next subsection.

Voltage Profile Results
To present the impact of the EV charging on the power system voltage profile, the QSTS is carried out and the voltage of all phases at each bus is calculated for 24 hr. Figure  16 shows the impact of the EV charging on phase # a at the worst-case bus 114. The voltage profile in case1 and case 2 is lower than the limits of 0.95 p.u due to the EV charging. However, using the DSM with wind power generation increases the voltage to be within the limits as presented in case 3.

EVS Charging Behavior
The effect of the owner preferences based on EPTD and OPR as well as the wind power generation on arbitrary EVs charging process is presented in this section. Three EVs are chosen at different plugged-in times, the EVs numbered as EV#i, EV#j, and EV#k. Moreover, the SOC and operating charging power are presented for each EV. Table 2 gives the initial parameter for the three arbitrary EVs, SOC is 40% for all selected EVs however, they have different plugged-in times. Each EV has a different owner preference variable. Figure 17a,b displays the operating power and SOC of EV#i respectively. In the case of no control (Case 1), the battery starts charging at the plugged-in time 09:23 whereas the battery stops charging and gets disconnected from the grid when the SOC reaches 90%.
However, in Case 2, with the owner preferences considered, the proposed DSM shows a flexible charging process and capable to perform discrete charging. EV#i is delayed and set at an Idle state as shown in Figure 17a,b due to the real-time ETR not meeting the OPR in this duration of time considering the EPTD limit.
In Case 3, with the integration of wind power generation, the battery is charged in two sessions. The first session starts at the plugged-in time of 09:23 and stops at 11:17 whereas the second session starts at 13:53 and reaches the required SOC at 16:00.
Similarly, for EV#j and #k, the charging behavior is affected by the DSM as depicted in Figures 18 and 19 respectively. EV#j is in Idle state two times in case 2 and one time in case 3 when wind power has been integrated. Furthermore, EV#j is connected to the grid in case 3 after it has been sent to the waiting list two times in case 2.

Impact of DSM on Owner Satisfaction
Finally, it is important to study EV's owner satisfaction with the proposed DSM. Owner satisfaction can be measured using the savings in charging costs and the overall time that the owner spends in the charging process compared to his EPTD. The saving in charging cost can be calculated using the following equation: Table 3 summarizes the saving in the cost per unit price for the different case studies for the three arbitrary EVs. Significant savings in the cost occurred by using the proposed DSM to those EVs that start charging after 12:00 PM; the saving reached 42.1% and 55.4% for EV#j and #k respectively.
However, EV#i starts charging in the morning, and the ETR is not high as in the evening, the saving is 7.6% and 34.2% in case 2 and case 3 respectively. Finally, all the EVs reach the specified SOC while the overall connected time is less than each owner's EPTD.

Conclusions
This paper has presented a proposed DSM based on queuing theory for controlling the EVs charging load in the existence of wind power generation in power distribution networks. To represent the uncontrolled demand of the EV, a statistical model was used based on a statistical survey. QSTS was used to solve the 24 hr power flow and study the impact of the external load presented by the EV charging process. The proposed DSMbased queueing model uses the owner preferences signal which includes the EPTD and OPR to manage the charging process by operating the EV in one of two states (charge or idle). The proposed DSM takes advantage of integrating wind power generation in the distribution system to help the DSM in case of more generation power available in the system. The IEEE 123 nodes radial test feeder was used to check the performance of the proposed DSM through the owner's satisfaction based on the cost-saving and the overall time in the system. The results showed, using the proposed DSM, a significant cost saving was achieved for the EVs owner. In addition, shaving in the demand was obtained in the case of with and without wind power integration.

Conflicts of Interest:
The authors declare no conflict of interest.