BUILDING A DYNAMIC MODEL OF PROFIT MAXIMIZATION FOR A CARSHARING SYSTEM ACCOUNTING FOR THE REGION’S GEOGRAPHICAL AND ECONOMIC FEATURES

This paper describes a dynamic model of profit maximization for a car-sharing system, taking into consideration the geographical and economic characteristics of a region. To solve the model construction task, a technique to cover the region with geometric shapes has been described. It was established that when modeling a car-sharing system, it is rational to cover a region with a grid of equal regular hexagons located side to side. For each subregion, quantitative parameters were calculated: the number of free cars in the subregions, the probability of a car traveling from one sub-region to another, the cost of maintenance and operation of the car, and the income from the trip. This takes into consideration the dynamic nature of the specified parameters. Based on these parameters, an objective function is constructed including constraints for the dynamic model. These constraints take into consideration the economic and geographical features of each subregion.A dynamic profit maximization model was built for the car-sharing system in the city of New York (USA) based on the TCL dataset. To calculate the parameters of the model, data on 776,285,070 trips over the period from January 2016 to July 2021 were used. Maps of the beginning and completion of trips in the region and a map of trips tied to hexagonal grid cells using the Kepler visualization service have been built. The frameworks H3 and S2 were analyzed in terms of determining the length of the route between the subregions. Modeling was carried out according to the built unidirectional dynamic model of profit maximization. It has been established that taking into consideration the average economic and geographical characteristics of a region makes it possible to increase the profit of the car-shar-ing system by 12.36 %. Accounting for the dynamics of economic and geographical features of the region of customers in the model makes it possible to increase profits by an additional 4.18 %


Introduction
The global sharing market is one of the largest worldwide. The global market value of the sharing economy is set to reach USD 1.5 trillion by 2024. In 2019, the global market value of the economy for this industry amounted to USD 373.7 billion. The growth forecast is calculated according to the assumption that the total annual growth rate (CAGR) for the period from 2019 to 2024 would be 31.9 % [1]. The benefits and trends in the growth of the sharing market over the past 20 years are described in [2].
A special place in the sharing market belongs to car sharing. Car sharing involves the short-term rental of a car for a certain period by the driver. This type of movement is an alternative to public transport and makes it possible to expand the possibilities of movement within or outside the city at your own discretion. The user of a car-sharing system pays only for the time (mileage, etc.) of using the car and does not pay for its maintenance, which significantly saves money in the case of permanent (non-permanent) use of the car, since the owner of the car must pay significant sums for insurance, parking, gasoline, maintenance, in addition to the cost of the car itself. Car sharing is a key aspect of the evolution of transport systems, potentially leading to reduced congestion, reduced greenhouse gas emissions, and increased mobility flexibility for users.
An important factor in the growth of profits of the car-sharing system is to provide users with appropriate convenience, accessibility, availability of cars, rental costs, etc. At the same time, it is necessary to take into consideration the totality of costs that are associated with ensuring the functioning of the system as a whole. To this end, one needs to establish a rational system of restrictions, cost, and placement of cars in a region, etc. It is necessary to take into consideration the economic and geographical factors of the development of the car-sharing system. Taking into consideration these factors and ensuring the intensive development of the car-sharing system in the region leads to social and economic benefits. In particular, reducing congestion, air pollution, and freeing up space for urban space while taking parking spaces to specific areas [3].
The complexity of the problem of managing the car-sharing system is associated with the emergence of a possible disbalance of cars in the time and territorial dimensions, which leads to the inconvenience of the system for users as a whole and, accordingly, a possible decrease in system revenue [4]. One of the ways to partially solve this disbalance is to «reboot» the system every day, by moving cars to certain subregions that are in high demand in a certain period. Such movement is expensive and affects the cost of renting a car. However, in real systems, it is almost impossible to do without this movement of cars. In addition, the regulation of the disbalance is possible by imposing restrictions on the terms of car rental [4].
The complexity of managing a car-sharing system is also due to the fact that all management is carried out in dynamics, taking into consideration the change in demand in different subregions at different points in time, and providing operational and business solutions. At the same time, there are several related tasks: splitting regions into subregions, determining the necessary characteristics for them, calculating them in dynamics, maximizing the system's profits under specified restrictions, etc. [5].
The construction of a dynamic model for maximizing the profits of a car-sharing system, taking into consideration the economic and geographical characteristics of the region, is a relevant task [6]. This will stimulate the development of the region in the ecological, economic, and urban dimensions [7]. In particular, to intensify the process of reducing congestion in the region, reduce air pollution, increase revenues to the regional budget, and effectively equip parking spaces [3]. Taking into consideration the intensity of the development of the sharing market in general and, in particular, car sharing, the tasks discussed in the current article are of national importance. Therefore, research on the development of dynamic models of profit maximization for the car-sharing system is relevant.

Literature review and problem statement
It is advisable to consider the description of the characteristics of car-sharing systems and the problems of modeling operational solutions in these systems. The main operational solutions are the distribution of cars and moving them to the appropriate sub-regions, changing the cost of car rental in different subregions, and the conditions for the provision of car-sharing services in general. To support operational solutions, the relevant optimization problems are stated and solved. Paper [3] describes a simulation model for evaluating alternatives to car movements. In particular, study [4] describes the model of maximizing the profitability of the car-sharing system and the method of mathematical programming for its solution with the optimization of movement for a one-way car-sharing system. However, the model is not considered in dynamics and does not take into consideration the change in demand for cars at different periods of time, which is important for determining the rational movement of cars in the region. In work [5], the problem of moving cars for a one-way carsharing system without artificial relocation of cars is considered. To solve the problem, a model of mixed integer programming is proposed to establish the sequence of actions by personnel regarding the movement of cars. The model takes into consideration only requests that can be performed by system employees but does not take into consideration external factors necessary to maximize the profitability of the car-sharing system. In [8], it is shown that one-way and two-way car-sharing systems can operate simultaneously in the same region. Each system has its own customer base.
Paper [6] describes a method for determining the optimal number of cars that need to be placed in the region to meet demand. Also described are the components of moving vehicles, as well as parking and inventory after travel. In work [6], it is established that the demand and the size of the fleet depend on the scheme of user requests. That is, the size of the fleet decreases with the distribution of requests of users of the car-sharing system over time. Based on the conclusions in the cited paper, we can say that considering a dynamic model for maximizing the profits of the car-sharing system is a relevant task that requires research.
The task of maximizing the daily income of the car-sharing system, taking into consideration the minimization of maintenance and operation costs of cars, is described in [9]. For modeling, integer programming was used with the calculation of cars that are parked at each station. It was established that a large car-sharing network with a large number of small stations is more profitable. Work [9] did not take into consideration the economic or geographical characteristics of the region, which directly affect the profitability of the car-sharing system. Paper [10] describes an integrated system to optimize the movement of vehicles and personnel. However, the static variables considered in the cited paper do not take into consideration changes in the needs of car-sharing system customers over time.
Significant popularity of car-sharing systems with electric cars has been identified, which has a significant environmental appeal. However, electric cars still need a long time to charge, which, as shown in [11], leads to an increase in total costs and a decrease in the profitability of the car-sharing system. One solution to this problem is the use of micro-mobility systems (e-bikes, electric scooters, and skateboards, etc.). This is especially true for commercial organizations for the supply of goods, food, etc. and the rapid movement of customers within the city for short distances. Paper [12] describes models of the use of electric car-sharing and micromobility, as well as assesses demand taking into consideration sociodemographic and geographical characteristics. However, the study reported in [12] does not take into consideration changes in customer behavior regarding the electrical car-sharing system and micro-mobility over time.
Paper [13] considers the use of stochastic programming to solve the problem of vehicle relocation for the car-sharing relocation problem. Bender's proposed decomposition method makes it possible to solve the problem of selecting the optimal value from a predetermined set of scenarios. The main limitation of the cited paper is the need to prepare rational scenarios for the relocation of vehicles. In that article, the authors considered no more than 500 scenarios due to time constraints.
Thus, the task of building a dynamic profit maximization model for the car-sharing system using the economic and geographical characteristics of a region is incompletely resolved and requires separate research.

The aim and objectives of the study
The aim of this study is to devise a profit maximization model for the car-sharing system, taking into consideration the geographical and economic characteristics of a region. The dynamic model will make it possible to increase the efficiency of the car-sharing system by taking into consideration changes in the distribution of potential customers over time in a certain region. The consequence of this is the growth of profits of the car-sharing system and the development of the region as a whole.
To accomplish the aim, the following tasks have been set: -to describe a technique for covering a certain region with geometric shapes, which makes it possible to divide the region into subregions; -to establish quantitative parameters for each subregion, which are essential for building a dynamic profit maximization model for the car-sharing system; -to identify components of the dynamic profit maximization model for the car-sharing system, in particular, build an objective function and set limits taking into consideration the geographical and economic characteristics of the region.

The study materials and methods
Ensuring the effective functioning of the car-sharing system depends on taking into consideration the geographical and economic characteristics of the region in which this system is implemented. In addition, an important component of efficiency is the consideration of these characteristics in dynamics. To formalize the parameters of the model, the set theory was used. To cover the region, the hexagonal tessellation method was used. To build a model of profit maximization, the theory of discrete optimization was applied.
Car-sharing systems are developed in Europe, the USA, Canada, and Japan, and there are sufficient data on the functioning of these systems that are available for analysis. In Ukraine and Kazakhstan, sufficient data are not collected that could reflect economic and geographical features, which does not make it possible to adequately build a model. In the presence of relevant data, the described model could be used to maximize the profits of the car-sharing system in any region. Therefore, the data for our study (the coordinates of the beginning and end of the trip, the time of the trip to New York (USA)) was taken from one of the largest open datasets [14]. The data include information about taxi rides of the four largest services. Since carsharing is an alternative to the taxi service, it can be assumed that the behavior of customers of the car-sharing system will be similar, that is, trips will be carried out on similar routes.

Dynamic profit maximization model
for the car-sharing system

1. Procedure for covering a region with geometric shapes
To build a model for maximizing the profits of the car-sharing system, in addition to economic parameters, it is necessary to take into consideration geographical ones. To this end, the region that is selected for the implementation of the system must be divided into subregions. For each subregion, it is possible to calculate the parameters that are necessary for making operational decisions on the implementation of the system.
The traditional way to present geoinformation data is to keep a list of objects, each of which stores its coordinates as one of the attributes. This technique of data storage has a number of disadvantages. In particular, it is difficult to find neighboring objects and build routes between them. In addition, the technique of presenting data while preserving the coordinates of objects greatly complicates the analysis of data in some subregions. This is due to the complexity of determining all objects that are located in a particular subregion. To analyze data in subregions, a technique of presenting data can be used where the region under investigation is covered with a grid, and the properties of objects are stored in the cell of the grid that covers them.
A relevant task is to select the method of covering the region with a grid. The conventional method is administrative when the boundaries of grid cells are determined by streets, city boundaries, geographical objects, urban areas, etc. The administrative method most accurately reflects the division of the region into subregions. However, a significant disadvantage of the administrative method is the complex shape of cell borders. After all, to store the boundary of cells using broken, spline, or other lines, it is necessary to reserve significant amounts of memory. In addition, different shapes of cell boundaries significantly complicate the algorithms for their processing. It is possible to reduce the complexity of algorithms by using me thods of tessellation of the region with a homogeneous grid. The basis of the methods of tessellation is the coverage of the region with a grid, each cell of which has the shape of a regular n-gon, in particular a triangle, square, or hexagon [15].
To cover a certain region with geometric shapes of different areas, which makes it possible to divide the region into subregions, the frameworks H3 from Uber [16] and S2 from Google were analyzed [17]. As a result of the comparison (Table 1), it was established that both frameworks cover the entire surface of the Earth, so they can be used to cover any region. In addition, both frameworks provide an opportunity to choose the scale of the grid in a very wide range. Both frameworks are open source projects from international companies Uber and Google [16,17]. The only significant difference between the H3 and S2 frameworks is the shape of the grid cells. The main advantage of covering with a grid with hexagonal cells is that the distance between the centers of adjacent cells is a regular one. This property greatly simplifies the algorithms for finding the shortest paths between cells. When simulating a car-sharing system, distances and tra vel routes are important. Therefore, the real authors believe that when modeling a car-sharing system, it is advisable to cover the region with a grid of equal regular hexagons located side to side.
To cover the map with hexagons using the H3 framework, first of all, it is necessary to specify the boundaries of the region. Data on the boundaries of the regions provided by the GADM service were used [18]. The data are provided in .gpkg format. For each country, a list of sectors that contain data on which city, district, and region this sector belongs to is compiled, and contains a description of the boundaries of the sector. The sector boundary is described as a polygon with given vertices. The coordinates of the vertices are stored in the format of geographic coordinates (pairs of length and width).
For the selected area, covering with hexagons of appropriate scale is carried out using the polyfill function, which is included in the H3 framework. The result is a list of hexagon IDs that cover the specified area. Kepler service was used to visualize the hexagonal tessellation of the region [19].

2. Determiningthe quantitative parameters for each subregion that are essential for building a dynamic model
The integrated system was analyzed to optimize the relocation of vehicles and personnel [10,13]; we identified key parameters that are significant for maximizing the profits of the car-sharing system. Systems [10,13] do not take into consideration changes in parameters over time. However, it should be noted that according to the data obtained according to the results of the dataset analysis [14], the frequency of car rental by customers varies periodically on different days of the week, time of day, etc. In addition, the car-sharing system operates cyclically. This should be taken into consideration when building a model. Consider the parameter Tthe number of periods by which one iteration of the cycle of functioning of the car-sharing system is divided. After the iteration of the cycle is completed, we believe that the system returns to its original state, in particular, the localization of cars may change. One iteration of the cycle is divided by points that are placed on the time axis evenly <t 0 , t 1 , …, t T >.
Let the region O be specified, which was covered with a grid with cells o 1  -P ij (t) is the cost of a car trip from the subregion o i to the subregion o j for a period [t-1, t); it can be determined from the following formula: where τ(t) is the fare to the neighboring subregion for the period [t-1, t); r ij is the length of the route when traveling from the subregion o i to the subregion o j ; L ij (t) is the cost of a car trip from the subregion o i to the subregion o j for a period [t-1, t); it can be determined from the following formula: where β is a coefficient that takes into consideration the cost of fuel for travel to the neighboring subregion.
Open source data are used to evaluate system settings. One of the largest datasets in terms of volume is the dataset of taxi trips to New York, USA received in the TLC service [14]. This dataset contains data on passenger journeys in four taxi services for the period from January 2009 to July 2021. Since 2016, data on the time and coordinates of the start of the trip, the time, and coordinates of the end of the trip, the cost of the trip, and the number of passengers are available. TLC dataset is used in other car-sharing systems management studies. In particular, study [13] used data from the TLC dataset for the period from 01.06.2016 to 01.06.2019 for modeling the relocation of vehicles for the car-sharing system.
To calculate the probability of a car traveling from the subregion o i to the subregion o j over a period [t-1, t), travel data from January 2016 to July 2021 were used. A total of 787,666,242 trips were processed. Data on 11,381,172 trips containing erroneous data, including level 0 coordinates, were discarded. To calculate the parameters of the model, data on 776,285,070 trips were used. The boarding and disembarking coordinates were visualized using the python mathplotlib library; they are shown in Fig. 1, 2.
Coordinates of the beginning of trips  The start and end coordinates of each trip are assigned to the corresponding cells of the hexagonal grid. The probability of travel is calculated as the ratio of the number of trips from the subregion o i to the subregion o j to the total number of trips in the region in one day.
With the help of the Kepler visualization service [19], a hexagonal tessellation of the selected region (New York) was built on the basis of the TLS dataset [14] for the period from 01.01.2016 to 01.07.2021 (Fig. 3). The travel map is constructed with reference to the cells of the hexagonal grid. The number of trips is displayed in colors.
According to [20], the cost of traveling one mile in three car-sharing services in New York City ranges from USD 0.35 to USD 0.59. In hexagonal tessellation of the region of New York using the H3 framework, the scale of the grid cell 8 was selected. At this scale, the size of the hexagon side is 461 meters. As a result, we obtain that the value of the tariff τ(t) should be determined within 0.15≤τ(t)≤ 0.3.
According to [14], the cost of travel per mile varied from USD 0.12 in 2016 to USD 0.174 in 2021. Therefore, the β coefficient can be estimated in the range from 0.05 to 0.07. When constructing a dynamic model of profit maximization, it was assumed that β = 0.06.

3. Construction of the objective function and limitations of the dynamic profit maximization model for the car-sharing system
When determining the objective function in the task of maximizing profits for the car-sharing system, one needs to specify all sources of income and costs for the implementation of the system. That is, taking into consideration the defined parameters for each subregion, one can write the objective function: where P t ij t The task is to find the optimal distribution of cars in the subregions at the initial time point. At subsequent points in time, the distribution of cars by subregions is determined on the basis of conditions (2) to (6).
As T grows, the effect of the initial parameter values on the optimization result is lost.
Therefore, at T >50, the effect of optimizing the initial placement of cars will be at the level of error. It is advisable to consider a dynamic model for small values T, T~10.
One should note the restrictions, in particular, that all cars at the initial moment of time should be divided into subregions: where k is the total number of cars in the car-sharing system; k i (0) is the number of free cars at the initial time in the sub-region o i ; k i (t) is the number of free cars over a period [t-1, t) in the sub-region o i , i n = 1, . We set a limit that the number of cars that customers can use to travel from the subregion o i to other subregions may not exceed the number of free cars in the subregion: where С ih (t) is the number of cars that left the subregion o i for the subregion o h over the time [t-1, t), h n = 1, ; С ih (t-1) is the number of cars that left the subregion o i for the subregion o h over the time [t-2, t-1), h n = 1, ; С hj (t-1) is the number of cars that came to the subregion o j from the subregion o h over the time[t-2, t-1), h n = 1, ; k i (t-1) is the number of free cars over the time [t-2, t-1) in the subregion o i , i n = 1, ; C ij (0) = 0 -this condition determines that at the initial moment of time the cars do not make trips.
We impose a restriction that determines the relationship between the apriori probability of a car traveling from the subregion o i to the subregion o j and the number of free cars in the subregion o i : where C ij (t) is the number of cars that have left the subregion o i for the subregion o j over the time [t-1, t), f is some step-function. The function f(p ij (t), k i (t-1)) is described analytically difficult, so, to find C ij (t), we use simulation modeling.
For each subregion o i and each free car over the time [t-2, t-1), we simulate a trip. To this end, we k i (t-1) times generate a pseudo-random number from the interval [0, 1). If the number falls into the interval [0, p i1 (t)), then we simulate the trip of the car to the region o 1 ; if the number falls into the interval [p i1 (t), p i1 (t)+p i2 (t)), we then simulate the car's trip to the region o 2  After carrying out the simulation procedure, we obtain an integer problem of linear programming (1) to (5). To find a solution to this problem, one can use the CPLEX application [21]. To establish spatial-logical and topological connections in the general planning of the region, in particular in terms of ensuring rational transportation routes, one can use a matrix multidimensional model, which is described in [22].

Discussion of results of studying the construction of a dynamic profit maximization model for the car-sharing system
A dynamic model of profit maximization for the car-sharing system was built, taking into consideration the economic and geographical characteristics of the region. The geographical component is provided by covering the region with a hexagonal grid, which makes it possible to break the region into subregions. To this end, we used the H3 framework [16], which makes it possible to choose different scales for the required number of subregions. The economic component is provided by calculation for each sub-region of a number of parameters reflecting changes in customer behavior in dynamics. The parameters of the dynamic model and their visualization are shown in Fig. 1-3. The dynamic model of maximizing the profits of the car-sharing system (1) to (6) is constructed by taking into consideration the described dynamic parameters. The advantage of the model is its dynamic character. Unlike the model described in [10], our model takes into consideration the change in demand for trips of customers of the car-sharing system during the day.
Study [13] considers the problem of the relocation of vehicles for car-sharing. It also makes it possible to maximize the profits of the car-sharing system due to the optimal distribution of cars between subregions. In this study, real authors use averaged TLC data over three years without taking into consideration changes in customer behavior. They covered New York city with a grid of 259 cells using a geographical method.
To verify the results of the development of a dynamic model for maximizing the profits of the car-sharing system, 4 cases were considered. The first two correspond to those reported in study [13], the third was chosen for the selection of parameters for the correct comparison of models, and the fourth was for building a dynamic model of profit maximization.
In the first case, data on the coverage of New York City with a grid were used, according to study [13], and p ij (t) does not depend on time, and does not take into consideration travel data. The probability of a trip between subregions is given by the Gauss distribution and depends on the distance between the subregions.
In the second case, data on the coverage of New York City with a grid were used, according to study [13], and p ij (t) does not depend on time but takes into consideration the average data on travel over 3 years. In terms of the study, this is achieved when T = 1.
To verify the dynamic model of profit maximization, two more cases were identified. In the third case, the grid coverage involved using the H3 framework [16] for 216 hexagons. As in the second case, p ij (t)) does not depend on time but takes into consideration the average data on customer travel for 3 years. The parameters for the third case were selected so that the maximum value of the objective function was close to the maximum value of the objective function in the second case.
In the fourth case, as in the third, the grid coverage involved using the H3 frame, and p ij (t) depends on time. The day is divided into 4 periods with a duration of 6 hours each. In terms of this study, T = 4.
For each case, modeling was carried out 25 times and average results were found. Table 2 Average results of modeling the profit maximization of the car-sharing system using New York City as an example Based on the results of our simulation, taking into consideration the average economic and geographical characteristics of the region (comparing cases 1 and 2) makes it possible to increase the profit of the car-sharing system by 12.36 %. Taking into consideration the dynamics of economic and geographical features of the customer region in the model (comparing cases 4 and 3) makes it possible to increase profits by additional 4.18 %.
Our dynamic model is unidirectional, that is, the cost of distributing cars by subregions after the end of the travel cycle in the model is not taken into consideration. These costs, as shown in [5], will be nonzero. The limitations of the built dynamic model are that the number of time periods and subregions should be small. This is due to the complexity of computing, which, for discrete optimization, will grow exponentially. We did not pay attention to the selection of the optimal method for solving the problem (1) to (6), which is the subject of further research. In addition, an important element of further research is the use of calculated parameters of the dynamic model as part of combined models for predicting air pollution [23].

1.
We have described a technique for covering a region with geometric shapes, which makes it possible to break the region into subregions. It is established that for a given task, the rational choice is to cover the region with proper hexagons, which are placed side to side. To cover and visualize this coverage, the TLS dataset was used for the selected region; data on 776,285,070 trips were processed. Maps of the beginning and completion of trips in the region and a map of trips tied to hexagonal grid cells using the Kepler visualization service have been built. The frameworks H3 and S2 have been analyzed in terms of determining the length of the route between the subregions. It is established that H3 has advantages for calculating the length of the route, which is necessary to build a dynamic model for maximizing the profits of the car-sharing system.
2. We have defined the quantitative parameters for each subregion, which are essential for building a dynamic profit maximization model for the car-sharing system. These parameters are the number of free cars in the subregions, the probability of a car traveling from one subregion to another, the cost of maintenance and operation of the car, and the income from the trip. The specified indicators were calculated in dynamics using the TLS dataset for the period from 2016 to 2021.
3. The objective function of profit maximization in the dynamic model has been determined; restrictions were set taking into consideration the geographical and economic characteristics of the region. Modeling was carried out according to the built unidirectional dynamic model of profit maximization for the car-sharing system on the example of New York. Four cases were considered to this end. The first two correspond to those reported in study [13], the third was chosen for the selection of parameters for the correct comparison of models, and the fourth -for building a dynamic model of profit maximization. It is established that taking into consideration the average economic and geographical characteristics of the region makes it possible to increase the profit of the car-sharing system by 12.36 %. Taking into consideration the dynamics of economic and geographical features of the region of customers in the model makes it possible to increase profits by an additional 4.18 %.