Optimal Aggregation Design for Massive V2G Participation in Energy Market

As a new type of transportation, electric vehicles (EV) can effectively adjust the supply and demand balance of power systems using their vehicle-to-grid (V2G) characteristics. To better promote the participation of EV resources in the energy market and interact with power systems, we propose a novel framework of an electric vehicle aggregator (EVA) that can aggregate schedulable EVs within its jurisdiction to provide auxiliary services for the power grid. Due to EV charging behavior’s uncertain nature, we employ a probability mass function (PMF) based model to provide more accurate forecasts of future EV behaviors. To reduce EVA operation costs and maximize the travel utility for EV users participating in this service, we develop an EVA optimization schedule model that combines a day-ahead optimization schedule and real-time optimization schedule. Finally, we create three case studies to verify the results of the proposed method. Matlab is used to simulate and analyze each case study concerning uncoordinated charging, coordinated charging while considering day-ahead optimization schedules, and an ensemble of coordinated charging activities that consider the day-ahead optimization schedule and real-time optimization schedule. Through comparative analysis, it is verified that the proposed strategy can effectively reduce EVAs’ operating costs and meet the travel requirements of EV users. The impact of different degrees of error of EV plug-out information on the proposed method is also analyzed.


I. INTRODUCTION
Promoting EVs can accelerate fuel substitution and reduce vehicle exhaust emissions, which are of great significance for promoting energy conservation and emissions reduction and preventing air pollution [1]- [4]. However, broad EV access to the power grid will seriously affect the distribution network's stability and reliability [5]- [8]. Simultaneously, due to the extremely high communication network and computational complexity required by the dispatching agency for direct dispatching of EVs, it is necessary to introduce the role of an EVA to coordinate scheduling of EVs within the EVA jurisdiction. In essence, an EVA is an electricity retailer that provides charging operation services. According to the daily charging demand of the EV fleet, the EVA bids for energy in the day-ahead market. It implements a real-time scheduling The associate editor coordinating the review of this manuscript and approving it for publication was Md Asaduzzaman . optimization strategy based on day-ahead market transactions to maximize its profit without affecting EVs' charging targets [9]- [11]. Through aggregation, coordination, and control of EVAs, EVs can effectively conduct positive interactions with the power grid, play the role of peak shaving and valley filling, and provide auxiliary services (AS) such as frequency regulation (FR) and operating reserves [12]- [14].
In [15], based on the travel habits of EV users, a cloud model is used to build a charging load curve and a range of charging loads. Compared with Monte-Carlo methods, the cloud model has higher prediction accuracy, but the model is only applicable within a specific boundary or facility. Also, its applicability is focused on infrastructure planning for EVs. The work presented in [16] uses different EV driving conditions in conjunction with a deep learning algorithm based on a modular recurrent neural network to predict EVs' power requirements. This method can optimize the power requirements of EVs and extend their driving distances. However, this model ignores the driving behaviors of EV users. The work by [17] developed an EV load forecasting model that considered the types of EVs, charging times, charging modes, and other factors in a specific area and the model was also used to analyze the different impacts of EV charging on the distribution network for different seasons. The studies mentioned above have all considered a combination of factors such as state of charge (SoC), charging time, charging station location, electricity price, and driver experience to model EVs contributions to the grid. However, these models do not consider factors related to the social characteristics of EV users and economic factors. To implement an optimal charging infrastructure [18], the effects of the factors mentioned above on EV charging demand using agent-based modelling to predict EV charging's electrical power demand are examined. The authors of [19] suggested an energy management (EM) scheme using random forest methodology to predict EV travel patterns to minimize the cost of energy consumption. Although the above literature produced significant results, all ignored the possibility of errors related to EVs' charging behaviors. To address this, the work proposed by [20] discusses a two-stage approximate dynamic programming framework to determine the optimal charging strategy by utilizing predicted short-term future information and longterm estimations from historical data. In [21], the authors also establish an intelligent traffic scene with optimal traffic-light control to predict future driving-state information and driving models of hybrid EVs (HEV). Combining each available taxi's historical charging events and real-time GPS trajectories, the work in Reference [22] predicts a taxi's current operational state and recommends a suitable charging station for each cab to minimize its charging time. To solve the problem of EV range anxiety, the authors in [23] use locationdependent environmental conditions and time-varying drive system losses to estimate EV battery SoC and range.
Another critical aspect of EVA is participation in the spot market, an essential part of the modern energy market. The spot market generally consists of the day-ahead market and real-time market to achieve a reliable connection between dispatching operations and market transactions. EVAs can use the properties of V2G to flexibly adjust the chargedischarge process of electric vehicles to provide AS for the power grid in real-time and improve both the reliability and stability of the power grid. Therefore, it is of theoretical and practical significance to study the decision-making problem that enables EVAs to provide a suitable real-time scheduling mode based on operation optimization constraints and link EVAs with the current energy market to maximize revenue. Considering the relationship between market price and bidding price, [11] proposes an optimal bidding model for EVAs to minimize electricity costs' conditional expectations. The authors in [24] perform cluster analysis for different types of EVs and their travel times while combining market clearance limits and EV charging load limits to build a two-level optimal bidding strategy model for EVs aggregators to minimize EVA costs. A mixed-integer linear programming model is proposed by [25] and considers EV users' driving behaviors to reduce bid amounts and provide confidence to EV owners. In [26], a stochastic optimization model for optimal bidding strategies of EVAs in the day-ahead energy and ancillary services markets is proposed with variable wind energy to maximize conditional value at risk (CVaR) and minimize EVA operation costs. The work by [27] offers an optimal bidding strategy that uses a dynamic programming method that considers Markov random prices and random AGC signals. The authors in [28] proposed an EVA bidding strategy and an internal resource optimization model to maximize EV benefits by utilizing competitors' predicted bids. The authors in [29] studied the problem in which an aggregator bidding into the day-ahead energy market to minimize charging costs while satisfying the flexible demand of EVs. In [30], a twolevel optimization architecture is established to develop an optimal bidding strategy and charging management in a realtime energy market to minimize EVA costs. A two-stage stochastic optimization problem was developed by [31] to maximize profits of a risk-averse EV aggregator for bids on the day-ahead market in both the energy and frequency containment reserve market. [32] proposed a DR technique to manage V2G-enabled PEV electricity assignments to reduce overall electricity procurement costs for retailer bidding in the day-ahead market and real-time market.
The works above propose the use of EV characteristics for V2G energy market participation. However, most of the methods ignore the uncertainty in EV charging behavior i.e., plug-in and departure time. It is prudent to consider the uncertainties in EV behavior when predicting EV data for optimal EVA operation.
The main contribution of this paper is to build an EVA optimization framework for the power grid considering EV uncertain characteristics and EVA technical constraints. The objectives are as follows: 1) To develop an efficient EVA framework that captures the technical constraints that arise as a result of EV integration into the grid. We account for three types of input information, namely, EV charging behavior information, electricity market (EM) information, EVA operating performance information, and also EVA performance analysis. Among these, EV charging behavior information considers the initial SoC, plug-in time, and parking duration time. EM information refers to the time of use (TOU) of the day-ahead market and of the real-time market.
2) Use Monte-Carlo simulation to build EV charging behavior PMF based on data acquired from the Federal Highway Administration (FHWA) in the US.
3) Design of an optimal scheduling algorithm for a group of EVAs using a convex model in conjunction with data such as day-ahead energy market prices, real-time energy market prices, and EV characteristics. This algorithm is designed to minimize EVA operation costs without affecting the charging requirements of EV users. 4) Given the available EV information, we evaluate the EV final SoC PMF and EVA costs by using different EV VOLUME 8, 2020 plug-out error rates to analyze the performance of the EVA optimization model.
The remainder of the paper is arranged as follows: Section II presents the EVA framework. Section III describes a joint optimization model for EV day-ahead markets and real-time markets. Case study and simulation results are discussed in Section IV. Finally, Section V presents a summary of the findings and conclusions.

II. THE EVA FRAMEWORK
A. DESIGNS CONSIDERATION FOR THE EVA 1) THE EVA PROPOSAL In the power system, we mainly divide the demand load into two types: rigid loads and flexible loads. Some demand loads that do not have the potential to regulate electricity usage are called rigid loads, such as refrigerators. Some demand loads that can actively participate in grid operation control and interact with the energy grid are called flexible loads, and EVs are the most typical example. EVs can be regarded simultaneously as both loads and distributed energy storage devices. When grid demand is low, they are charged, and when demand is high, they will feed power back to the energy grid. Therefore, we can use their characteristics to provide AS to the power system, such as FR and DR, which can reduce the burden on the power grid and reduce costs for EV users and operators. Therefore, various countries are vigorously promoting the development of broad EV access. Although massive EV resources can exert economic value in the energy market, it is not realistic for EVs to participate in the energy market alone as individual entities. The main aspects being considered to design an EVA are as follows [33]: • The cost of technology development The energy market has relatively high technical requirements for V2G services, such as power flow and economics and infrastructure costs, such as communication, measurement, control systems, and related supporting technologies. Although this provides ancillary services to the power grid, it can seriously affect EV users' enthusiasm for participating in grid interactions.
• Market rules Single EVs' capacity and power are too small and are far below the minimum size requirement (e.g., MW level) for participating in the power system market. Thus, large numbers of EVs need to be aggregated to meet the requirements of current market rules.
• Uncoordinated charging The charging behavior of EVs is always managed according to the travel requirements of EV users. Because the users do not know EV charging characteristics, electricity price information, or incentive policies for EVs, they cannot carry out scientific and practical charging plans, which would cause certain economic losses to themselves. Simultaneously, large numbers of EVs carrying out uncoordinated charging into the grid would also seriously affect power system stability. In summary, to promote the participation of EV resources in the energy market and its interaction with the grid, a novel type of commercial operational entity, EVA is needed to provide AS to the grid. EVAs can act as an intermediary mechanism to coordinate the relationship between large numbers of EVs and dispatching centers. EVAs can not only avoid the impact of uncoordinated charging of massive numbers of EVs on the power system but can also control EVs through reasonable and effective regulation methods without affecting the travel demands of EV users. EVAs can also provide DR, FR, and other grid ASs to the power system to satisfy the respective interests of both EVAs and EV users.

2) EVA STRUCTURE
EVAs provide the bridge between EV users and the grid. On the one hand, they are the providers and managers of EV charging businesses while, on the other hand, they represent EV interactions with the energy market. Fig. 1 demonstrates an EVA structure that shows the information and energy interactions among EV, EVA, and the grid operator.
• First and foremost, EVAs integrate EV user behaviors such as the total number of EVs charging per hour and the registration number of each EV, initial SoC, plug-in time, parking duration time, and target SoC to build an EV fleet. Since each EVA has a database of EVs, as long as we know each EV's registration number, the corresponding EV information can be obtained, i.e., vehicle model, on-board charger capacity, and battery size. Simultaneously, EVAs also receive signals from the power grid in real-time, such as hourly capacity limits, TOUs, and FRs.
• Second, the EV fleet and grid information are used to build an optimization algorithm to schedule each EV to meet the requirements of EV owners and the grid.
• Finally, the data used by the optimization algorithm is updated based on the current scheduling results for future use in the next scheduling operation.

3) TECHNICAL CHALLENGES FOR EVA DESIGN
EVAs can effectively solve the problems brought by large numbers of EVs participating in the energy market. They possess the technical conditions and economic advantages of participating in the energy market in terms of scale and structure, but many aspects must be considered [33].
• Data aggregation technology After EVAs collect EV data, it is necessary to filter and classify the data according to specific rules to obtain valuable information to aggregate the EVs for the grid operator. Since the scheduling process is based on this data, data processing, clustering analysis, and other technologies are significant for transforming the data into meaningful information for later use.
• Prediction EV data technology As a means of transportation, EVs present a significant obstacle in providing auxiliary services to the power system due to the uncertainty of their charging behaviors. Therefore, EVAs need to consider using the information on user travel patterns to model their availability.

• Control technology
The control technology is based on combining the dispatching response command information received from the grid operator and aggregated EV information to dispatch EVs. Simultaneously, this technology also needs real-time corrections of prediction deviations and power deviations in actual operations. This technology plays an essential role in improving customer satisfaction and achieving the task of power grid optimization.

B. FRAMEWORK OF THE EVA OPTIMIZATION MODEL 1) FRAMEWORK OF THE EVA OPTIMIZATION MODEL
Uncoordinated charging of large numbers of EVs increases the burden of system operation and negatively impacts user interests. EVAs provide a platform for the power grid and EV users to share real-time EV parameters, electricity price information, electricity demand, and other information. At the same time, EVAs directly dispatch EV electricity consumption behaviors which can cause schedules to be more reasonable and practical, give full play to the potential of schedulable resources under the premise of facilitating the travel requirements of users, and actively participate in the energy market to improve the system operational reliability and minimize the charging costs of operators. Fig. 2 reflects the framework of the EVA optimization model. The specific process is as follows: • Structure of an EVA virtual fleet Based on the PMF of EV information such as initial SoC, plug-in time, and parking duration time, the EVA predicts the charging situation for the next day and builds a primitive model, as shown in Fig. 3. The figure shows eight EVs with charging times from t = 0 to t = 5, EV n in,dur represents the charging behavior of each car where n is an index of EV number, in indicates plug-in time, and dur is the parking duration time. Each EV n in,dur has P n in,dur,idx which represents hourly charge/discharge decision variable based on the parking duration, where idx is charging/discharging time instance within the parking duration. As an example, EV3's plug-in  time is t = 1, the connection period is four continuoustime slots, and the decision variable is {P 1 1,4,1 , P 1 1,4,2 , P 1 1,4,3 , P 1 1,4,4 }, which is the total charging requirement of each EV, as shown in (1): where S n in,dur is the total charging requirement for the n-th EV. X t represents the sum of charge/discharge power for each period, as is shown in (2): Subject to • Bidding process The EVA formulates a day-ahead optimization scheduling plan based on the EV information in the primitive model and information from the day-ahead market to ensure that it can meet all EVs' travel requirements while minimizing the operating costs of the EVA. Fig. 4 details the bidding VOLUME 8, 2020  process, which shows that bidding begins at t = 0:00 am and lasts 24 hours. During the bidding period, hourly energy is purchased based on the day-ahead power optimization schedule obtained by the distribution system operator (DSO). It is scheduled to be dispatched to each EV. Bidding is suspended for subsequent hours until the next bidding time.
• Model predictive control (MPC) Dynamic systems can employ the concept of MPC to predict EV loads. However, in practice, most EVs will not optimally charge/discharge as scheduled due to uncertainties. If the amount of energy purchased is less than the required energy, there is the need to purchase extra energy from the DSO at a higher price to compensate for discrepancies. Conversely, if the bidding energy is greater, it is required to sell the surplus to DSO or other users at a lower price. Therefore, given the above scenario, there is the need to make corresponding adjustments to EV power dispatch on time through the real-time market to reduce EVA costs. Considering the shortcomings of the model described above, we propose a real-time optimization scheduling method to enable scheduling adjustments shown in Figure 5. The blue shaded region indicates bidding time, and the bold black line spans the bidding period, which is usually 24 hours. After bidding, the optimal EV hourly power is scheduled to span the period for which bidding has been made; the red depicts this period dashed lines, however, real-time power scheduling spans 48 hours. Other literature proposed a 24 hours base period [34], [35] for real-time power scheduling, but in this paper, we propose 48 hours to account for EVs that charge beyond the 24 hours into the next day to provide a more accurate EV schedule. There is also the option of extending the period to 96 hours or more, but this will increase the computational time required by the algorithm and also affect the accuracy of results. Once the EV power schedule  is available, the schedule assigned to a particular instance in time is dispatched to EVs in real-time as is shown in yellow [ Fig. 5]. The optimal hourly EV power schedule is executed periodically in real-time for a duration of 48-hour to account for EV's with plug-in durations that span past the current day. Prior periods for which dispatching has been executed are marked in green and the white periods are the areas to be optimized. The process iterates until the next day. Finally, the performance of the EVA optimization model is analyzed by using EV charging information.

2) MODELING EV CHARGING BEHAVIOR PMF
The modeling for the EV charging behavior is essential for the day-ahead market in particular. In other literature, battery charging and discharging behaviors are mainly modelled, and the travel statistics of EV are ignored. This does not accurately reflect the charging/discharging characteristics of the vehicle-to-grid interaction. In this paper, a probabilistic model is used to simulate charging behaviors. Based on the current travel statistics and actual application of the vehicle, the Monte-Carlo method is used to build the PMF of the initial SoC, plug-in time, and parking duration time so that the objects are described by the model are as realistic as possible. The relevant flowchart and pseudocode are shown in Figure 6 and Figure 7. The model depicted in Figure 6 starts by obtaining 1,000,000 vehicles data from the FHWA. Information such as vehicle ID, the number of trips begun by each ID, and each trip, the start time and the end time, and mileage are extracted from the data, which is shown in Table 1. Each set of vehicle information obtained from the FHWA data is conditioned as an EV experience by using the following steps.
Step 1: In this step, the traditional data are conditioned by assigning EV brand and initial SoC. Each vehicle in the FHWA data is randomly assigned an EV brand status following the sale distribution in Table 2. An initial SoC status is assigned to each vehicle based on a uniform distribution in the range of 0.2 and 1.
Step 2: After the SoC for each vehicle has been obtained, equation (4) is used to evaluate the remaining SoC after the first trip. If the remaining SoC is less than minSoC, the vehicle is reassigned to an initial SoC according to Step 1. If the remaining SoC is greater than minSoC, the initial SoC, remaining SoC after the first trip, and first trip information are logged against the vehicle ID, and the next trip is evaluated.
where when Tr is the trip number, [1,2,3,. . . ]; SoC n Tr−1 is initial SoC of the n-th vehicle on the Tr-1-th trip; d n Tr is travel distance for the n-th vehicle on the Tr-th trip; d n m is the maximum driving distance of the n-th EV; SoC n Tr is the remaining SoC of the n-th EV after the Tr-th trip; and minSoC is the minimum level of the battery for normal operation (this is sometimes considered as a low battery state).
Step 3: From (4), the initial SoC for the current trip is SoC n Tr−1 and the remaining SoC of each vehicle after the current trip is SoC n Tr ; if applicable this is evaluated by use of (4) considering the conditions below: • If the remaining SoC is greater than minSoC, the remaining SoC after the current trip and the current trip information are logged against the vehicle ID, and the next trip is then evaluated.
• If the remaining SoC is less than minSoC, (5) is utilized to determine if the vehicle can meet the minimum requirement for the current trip provided the vehicle is charged after the first trip. If the remaining SoC after (5) is still less than minSoC, this trip information is discarded and the next trip is evaluated. If the remaining SoC from (5) is greater than minSoC, the SoC after the current trip and the trip's information are logged against the vehicle ID and the next trip is then evaluated.
where end Tr−1 is the end time of the previous trip, Start Tr is the start time of the current trip, P n max is the maximum charge power, η is charging efficiency, and Cap n is the battery capacity of the n-th vehicle.
Step 4: Step 3 is repeated until all trips in the FHWA data for each vehicle are exhausted. The data obtained on each vehicle after the process include vehicle brand, battery capacity, initial SoC of each trip, and start time and end time of each trip. A frequency histogram is used to build a PMF for initial SoC, plug-in time, and plug-out time based on the acquired information. VOLUME 8, 2020

III. FORMULATION
To reduce EVA operational costs, it is necessary to optimize the day-ahead operation decision-making, that is, to flexibly configure the day-ahead charge/discharge plan of the EVs connected to the charging station in the jurisdiction. However, due to the uncertainties in EV charging behaviors, discrepancies exist between the predicted load and actual load. Thus, there is also a corresponding discrepancy between the EVA's energy quantity and actual energy consumption. To address this issue, we employ a joint optimization model for the EV day-ahead market and real-time market to reduce EVA operational costs caused by EVs' uncertainties.

A. OBJECTIVE FUNCTIONS 1) OBJECTIVE FUNCTION 1: MINIMIZE THE TARGET RESIDUAL ENERGY
Most of the existing charging and discharging strategies of EVs assume that many EV users will not travel until the next day after they arrive home. Still, in real life, there is a high probability of travel after users have returned home [36]. In this case, if the remaining EV power is low, it is challenging to meet the travel requirements of users, which will seriously affect user travel convenience and enthusiasm for participating in optimal dispatching by the power grid. So, to address this problem, the objective function is proposed as:

Subject to
F_SoC n = SoC n in + dur idx=1 P n in,dur,idx × η Cap n , ∀n ∈ N (7) SoC n t+1 = SoC n t + P n in,dur,idx × η Cap n ∀n ∈ N , ∀t ∈ T (8) SoC n min ≤ SoC n t ≤ SoC n max ∀n ∈ N , ∀t ∈ T (10) P n min ≤ P n in,dur,idx ≤ P n max ∀n ∈ N , ∀t ∈ T (11) where n is the index of EV number; N is the total number of EVs; F_SoC n is the final charge level of the n-th EV; SoC n in is SoC of the n-th EV at the plug-in time; SoC n t is the SoC of the n-th EV at time t; P n in,dur,idx is the hourly charge/discharge power based on parking duration time of the n-th EV; η is charging efficiency which is 0.9; Cap n is the n-th EV battery capacity; SoC n max and SoC n min are the maximum and the minimum SoCs of the n-th EV, respectively; P n min and P n max are the maximum and the minimum chargedischarge powers of the n-th EV, respectively.

B. OBJECTIVE FUNCTION 2: MINIMIZE EVA DAY-AHEAD ENERGY MARKET COSTS
The day-ahead market plays an essential role in the energy market framework. Each EVA can participate in day-ahead market energy trading as a single decision-maker of energy storage, sell power when the price is high, and purchase power when the price is low. Based on the above characteristics, we establish an objective function shown in (12), to optimize the day-ahead optimization schedule to minimize EVA day-ahead power purchase costs. (12) where B is the bidding duration, which is 24 hours; X t is the total required power at time t; Pd t is the day-ahead market price at time t.

C. OBJECTIVE FUNCTION 3: MINIMIZE EVA REAL-TIME ENERGY MARKET COSTS
Due to the uncertainty of EVs, there will often be an overlap between bidding power and power demand. When the power supply exceeds power demand, the surplus power is sold to the grid at a lower price, and when power demand exceeds the supply, more energy is purchased from the gird at a higher price. This process increases the operational cost of the EVA, and to mitigate excess EVA operational costs, an objective function is expressed as: where R is a time duration of 48 hours, B t is the bidding power at time t, A t is actual power consumption at time t, E t is the difference between bidding power and actual power consumption, P R,t is real-time market penalty cost at time t, P R1,t is the real-time market penalty cost at time t when B t > A t , and P R2,t is the real-time market penalty cost at time t when B t < A t .
Finding the optimal solution for (13) with linear programming is not straightforward since this is a nonlinear system and is not a continuously differentiable function. In nonlinear programming, there are two optimal solutions, namely a local and global optimum, and it can be challenging to find the global optimum given the limited time available. On the flip side, there is only one global optimum in convex programming, and it can be found quickly. So, to remedy this problem, a piecewise equation for (13) is considered to relax the difficulties associated with non-linearities and help find the optimal value of the solution more quickly and accurately. (15) is decomposed into two piecewise functions, as shown in (16): S t ≥ 0 ∀t ∈ T (18) 211800 VOLUME 8, 2020 where S t is the difference between bidding power and actual power consumption when B t ≥ A t B t > A t and V t is the difference between bidding power and actual power consumption when B t ≤.

D. FINAL OBJECTIVE FUNCTION
In conclusion, to reduce EVA costs, it is necessary to simultaneously consider the bidding cost, real-time energy market cost, and travel requirements of EV users. An ensemble of the objective functions is expressed as: where O is EVA total cost, O 1 is an objective function for EV user travel requirements, O 2 is an objective function for the day-ahead market, O 3 is an objective function for the realtime market, α is the weight of O 1 , and β is the weight of O 2 and O 3 . Choosing α and β is critical as such, we used the cross-validation method to obtain the parameters for α and β.

IV. CASE STUDY A. PMF OF THE EV CHARGING BEHAVIOR
Suppose the assumption is made that driving behaviors are the same for both EV and non-EV (conventional vehicle) users. In that case, this paper uses conventional vehicle data provided by the FHWA available online. The data include travel (trip) start times, travel end times, travel distances, and other travel information. As EVs' use case will not deviate from conventional vehicles, their travel behaviors will also be the same. As such, we adopt conventional vehicle data as the EV plug-in time and plug-out time while the initial EV SoC is evaluated by using the available data. Simulations in the MATLAB (R2019a version) environment are conducted with a PC having 16 GB RAM and an Intel i-7 processor (3.0 GHz). Based on historical data from the FHWA, we selected 1,000,000 different types of EVs to predict charging behaviors, and the relevant information for different EV types is shown in Table 1 and Table 2. According to the flow chart in Fig. 4, a PMF model is constructed for plug-in times, parking duration times, and initial SoCs of EVs and is shown in figures 8 -10. Fig. 8 shows the PMF for EV plug-in time for each hour. Fig. 9 shows the hourly distribution of EV initial (Plug-in) SoC. From the figure, it is evident that the EVA accepts new EV connections hourly with varying SoC. For example, in the first graph, most EVs connected to the EVA at time 0:00 am joined with initial SoC of 0.5 with a probability of 14% and the figure shows that the general initial SoC distribution is not normal as depicted in the most article [15]- [17]. Fig. 10 details the hourly distribution of EV parking duration. The figure shows that the parking duration time for EVs plug into EVA at each moment is different. For example, for EVs plugged-in at 0:00 am, there is an 11% chance that the vehicles will remain plugged-in for 9 hours before plugging out as most EV user will drive to work at 9:00 am and at 9:00 am, there VOLUME 8, 2020 is a 23% chance that vehicles will remain plugged-in for 1-2 hours.

B. CASE STUDY FOR EVA PERFORMANCE ANALYSIS
Based on the EV charging behavior PMF shown in Figures 8-10, we perform simulations with 500 EVs while considering three cases as follows: Case 1: Uncoordinated charging. All EV users charge their EVs as soon as possible without considering TOU prices, and the EVA also does not participate in the EM.
Case 2: Coordinated charging. The EVA participates in the day-ahead market due to the uncertainty in EV charging behavior. EVA performance under different plug-out error conditions is also considered.
Case 3: Coordinated charging with the day-ahead market and real-time market while considering various plug-out time errors.
According to the cases discussed above, we analyze the performance of the EVA based on operational costs and EV final SoC distributions. Due to the constraint with the dataset and the energy market in consideration being operated at the hourly interval, and the dataset used has a high granularity (hourly resolution), the departure time for EVs in our case study is hourly intervals. Fig. 11 shows the day-ahead market price for the energy market. We see that electricity prices are low between 0 am-6 am and are higher between 4 pm-9 pm. In case 1, we assume that EVs' uncoordinated charging price is 1.5 times the day-ahead market price. In case 2, the dayahead market price is the same as depicted in Fig.11. In case 3, we assume that the cost of EVA electricity sales is $5 lower than the day-ahead market price and that the price for electricity purchases is $8 higher than that of the day-ahead market price. For all EVs, we assume that the user's expected final SoCs are 100%. Fig. 12 shows the uncoordinated charging schedules of 30 EVs. In this figure, the x-axis is to time; the y-axis is the ID of EV and EV charging power, which ranges from 0 to 20 kW; and the gray boundary line indicates the parking duration of each EV. For the uncoordinated charging schedule, we assume that EV batteries are charged at the maximum current at the onset of charging. As charging progress, the current is gradually reduced until the battery is fully charged.

1) CASE STUDY 1: UNCOORDINATED CHARGING
Due to uncoordinated charging, EV users ignore the charging price and charge EVs based on their requirements. Figure 12 shows that the majority of EV users will charge EVs from 3 pm to 8 pm even though the charging price during this period is very high. This contributes to a daily cost of $566.5, which significantly increases EVA operational costs. Fig. 13 shows the EV final SoC distribution for uncoordinated charging. From this figure, we can see that 93.8% of EV users leave with 100% SoC and the remaining 6.2% of EV users leave with final SoCs between 50% and 90%. From the maximum driving distance information for EVs shown in Table 1, it is evident that as long as an EV user does not travel for long distances, there will be a sufficient SoC to cover the EV user's next trip. So, when EV user charging behaviors are uncoordinated, their travel requirements are mostly meet.    demand and day-ahead market price. These data are obtained via the day-ahead optimization schedule to minimize the cost of EVA energy purchases without affecting EV users' travel requirements. Due to uncertain EV user behavior, we simulate the EV final SoC PMF and EVA costs with different plugout time error rates to analyze the EVA optimization model's performance.
When comparing Fig. 12 and Fig. 14, we observe that under uncoordinated charging, users only consider their travel requirements and ignore charging costs; also, most EV users charge EVs during periods of high electricity prices. When users consider TOU, EVs will discharge at high electricity prices and charge at low electricity prices, reducing the cost of the EVA. From Figure 14, it can be observed that  although the plug-out time of most EVs is around t = 40, most EVs stop charging at around t = 30. This is because EVs' charging cost gradually increases after t = 30; thus, the optimal schedule avoids charging between t = 30 and t = 40 to prevent a potential increase in operational costs for the EVA. Fig. 15 shows the EVA costs for case 2 with different deviations (σ ) where σ represents the deviation of plug-out time. A plug-out time deviation of 1 means EV users will leave early or charge for an additional hour. When σ = 0, the EVA cost is $336.7 and thus provides a 40.5% cost reduction compared to case 1, and with an increase in σ , the EVA cost also increases. Nevertheless, the EVA cost is always lower than that for case 1. It can be seen that the day-ahead optimization schedule can effectively reduce the EVA cost. Fig. 16 shows the EV final SoC distributions for case 2 with different σ values. Fig.16-a) shows that approximately 89% of EV users charge to 100% SoC, which is a 4.8% decrease from case 1, and the final SoCs of the remaining 11% of EV users SoC are between 40% and 90%. Fig. 16-b) to Fig. 16-d) shows that with the rise in σ , the probability of EV final SoCs reaching 100% decreases and that the lowest final SoC ranges will decrease to approximately 20%; this situation poses a challenge for EV users with a final SoCs of 20% for meeting their travel requirements.

3) CASE STUDY 3: COORDINATED CHARGING AND THE REAL-TIME ENERGY MARKET
For this case study, we use the day-ahead optimization schedule and real-time optimization schedule to dispatch EVs at the same time to compensate for the additional costs caused by the uncertainties in EV charging behavior. Also, we simulate the EV final SoC PMF and EVA costs with different plug-out  time error rates to analyze the performance of the EVA optimization model.
When σ = 0, the actual EV charging information is the same as that obtained via PMF and the dispatch results for EVs are consistent with Figure 14. Figure 17 shows the EVA cost comparison between case 2 and case 3 with different σ values, and EVA costs increase with increased σ values. For figure 17, we know that when σ = 0, the costs for the case 3 and 2 are the same because when the actual EV charging information is consistent with the predicted EV charging information, the real-time optimization schedule's objective function is equal 0. When σ = 0, thus σ = 1, σ = 2, or σ = 3, the rate of cost increase gradually, but the cost of case 3 is lower than the cost of case 2. Figure 18 shows the cost reduction rate obtained by comparing the costs of case2 and case3 with the cost of case1. It can be seen from the figure that the cost reduction rate of case3 is always greater than that of case2. In effect, EVAs achieve operational cost savings when considering EV dispatched via both the dayahead optimization and real-time optimization schedules. Figure 19 shows EV final SoC distributions for case 3 with different σ values. The figure depicts the probability of an EV final SoC reaching 100%, which decreases with increased σ values. When σ = 0, cases 2 and 3 show the same results for dispatching EVs and the EVs final SoC distributions are also the same. When σ = 0, the probability of EVs final SoCs reaching 100% in case 3 is lower than for case 2, but the minimum value of the final SoC for the remaining EV users is higher than for case 2, which can better meet the travel needs of EV users.  [8] and [36].
Finally, we provide comparison details on cost reduction of uncoordinated charging and coordinated charging of the optimization methods proposed in this paper and that of methods proposed in [8], [36]. Our proposed method uses an optimal scheduling algorithm for a group of EVAs using a convex model in conjunction with data such as day-ahead energy market prices, real-time energy market prices, and EV characteristics which can minimize EVA operation cost without affecting the charging requirements of EV users, the method proposed in [8] uses the fuzzy rule to dispatch the EVs parked at charging station, which can guarantee full charging at departure time for each vehicle. Whereas the method in [36] considers the day-ahead market and real-time pricing by using sigmoid function to reduces the operation cost by shift the peak load and valley load. Considering the same number of vehicles, table 3 shows our proposed method yields the highest EVA cost reduction of 28.5% in comparison to 21.15% and 16.6% for the methods proposed in [8] and [36], respectively.

V. CONCLUSION
This study presents a novel EVA framework that can reasonably dispatch EVs and provide auxiliary services to the power grid. Also, we built a probability mass function (PMF) model based on plug-in time, parking duration time, and initial SoC information of EVs using the Monte-Carlo method to model EV charging behavior. Finally, an EVA optimization scheduling model that combines the day-ahead market and real-time market was established to minimize EVA costs without affecting EV user travel requirements.
Three case studies are conducted to verify the proposed method using Matlab. Case 1 shows that uncoordinated charging can generally meet users' travel needs, but since most EV users charge their EVs during times of high electricity prices, EVA costs are very high. Case 2 shows that using the day-ahead optimization schedule can reasonably dispatch EVs to discharge at high electricity prices and charge at low electricity prices. When σ = 0 and when compared with case 1, EVA cost is reduced by 40% without affecting user travel needs. However, when the actual EV charging information contains deviations from our predicted information, this will increase EVA costs and affect EV users' travel needs. In case 3 and when σ = 0, EVA costs, and EV final SoC distribution results are the same, but when σ = 0, when compared with case 1 and case 2, the cost of case 3 is lowest and can better meet the travel needs of EV users at the same time.
The proposed method achieves more significant cost reductions from the verification results and is better at satisfying EV user travel requirements than the other two cases. Simultaneously, the uncertainty of EVs is fully considered, which can effectively ensure the reliability and effectiveness of the EVA optimization model. Future works that consider permitting EVAs to participate in ancillary services such as FR could help decrease EVA costs.