**1. Introduction**

A key function of an electricity grid operator is to balance supply and demand to ensure that the power produced always matches the power required. In the UK, for example, this is achieved by the Balancing Mechanism of the National Grid, which calculates deviations in supply and demand every half-hour. To address any imbalances, the operator will accept offers to increase or curtail demand and/or generation in near real-time. Electricity can also be traded ahead of time; in the day-ahead market, for example, generators and suppliers agree contracts for the delivery of energy typically during hour periods on the following day [1]. Vehicle-to-grid (V2G) is a technology that allows electric vehicles to contribute to such flexibility services by discharging or curtailing demand when required [2,3]. This capability has the potential to help manage the additional load on the grid resulting from the influx of electric vehicles, to help manage supply fluctuations inherent to renewable energy sources and to contribute to ambitious sustainability targets introduced by many cities around the world, including Nottingham in the UK [4].

While the integration of static energy storage within virtual power plants is relatively well developed [5], significant additional challenges result where the storage is mobile in the form of electric vehicles (EVs). For example, charging and discharging must be scheduled and aligned with vehicle availability, and use of the battery must respect the primary use of the vehicle as a form of transport. Commercial organisations have been established to offer such capability [6] attracted by the significant

opportunities offering flexibility services to the electricity grid [7]. Energy companies, such as Octopus Energy [8] and Ovo Energy [9] in the UK, are now also rolling-out services based on V2G.

Participation in market opportunities is, however, reliant on the availability of enough vehicles at the time of the market event. As the total population of participating vehicles grows, it becomes more likely that enough vehicles would be available, given that many are typically parked over 95% of the time [10]. However, as trading decisions are typically made in advance, finer-grained predictions of available capacity become necessary, and support participation in larger and more numerous market events as a smaller buffer of vehicles is required to account for uncertainty. Such predictions also enable the use of the technology for scenarios with an inherently smaller vehicle population, such as individual communities or local vehicle-to-building applications [11].

A prediction of available capacity is critically dependent on many factors, including battery capacity and state-of-charge; however, fundamental to this prediction is the actual availability of the vehicle, i.e., it must be parked close enough to an available charging station to be plugged in. This, therefore, requires predicting the stationary location of vehicles—a problem that has been explored previously in the literature. Markov models, for example, have been used to model driving patterns using a single vehicle's data [12] and to model a vehicle's state using survey data [13]. The related problems of travel time prediction [14] and parking space prediction [15] have also received considerable attention. However, to enable V2G services, there remains a need for techniques to predict when vehicles are parked close enough to charging stations and hence potentially available to a V2G aggregation service. These techniques must also be validated using real data from a substantial number of vehicles.

In this paper, we addressed this need by using a historical dataset from a fleet of vehicles to train and analysed several different predictive models. We made the following specific contributions; firstly, we demonstrated the ability of the models to predict when vehicles are parked close to V2G charging stations with high accuracy, which is necessary to underpin the assessment of the capacity available to a V2G aggregation service during future trading windows; secondly, we demonstrated a method of analysing a dataset retrieved from a vehicle tracking service to support the identification of vehicles that are strong candidates for use in a V2G service; thirdly, we demonstrated that simple prediction strategies, such as moving averages, could yield comparable performance to more complex machine learning techniques, which is of value to help bootstrap V2G services when large training datasets are not initially available.

The remainder of the paper is structured as follows; in Section 2, we described the dataset used to train the models and detailed the three approaches investigated; in Section 3, we compared, analysed and discussed the performance of the approaches in predicting the availability of individual vehicles and total available vehicles; Section 4 presents our conclusions.
