Multiagent Model of Price Dispersion in the Retail Market of Petroleum Products

In this study a multiagent model of behaviour of the dispersion of retail prices for petroleum products has been developed, depending on changes of external factors, in particular, sharp changes in wholesale prices. Therefore, there is a need for a model that would not only have the potential to test the existence of a price dispersion as a consequence of the specifics of competition in the market of petroleum products and consumer search strategies, but would have the ability to quantify the price variance as a consequence of the behaviour of individual market agents. The basis of the behaviour of market agents of this model is algorithms of price oligopolistic competition from traders and user price search strategies. Calibration models and verification of historical data of the Kyiv region, where they were previously established empirical data on the dispersion of prices showed a fairly good correspondence between the model and the actual data. In particular, the existence of a price pattern has been established at jump-like changes of wholesale prices. The presence of price strategy of buyers, which are based on the strategy of the base price, is shown. The coincidence of model and real data still needs to be improved.


Introduction
Despite world trends in reducing the share of hydrocarbons in energy consumption, the petroleum product market remains an extremely important institution for every single economy on any continent. Relatively long history of the functioning of the market shows that the central issue of this market is price behaviour. Governments of all countries must closely monitor changes in prices, especially for their significant increase, which can lead to negative social consequences. The long-established fact, both empirical and theoretical, lies in the fact that prices in this market behave as non-stationary time series. Some features of competition in the market of petroleum products, as well as significant sensitivity of fluctuations in the level of domestic prices from external factors, are the cause of such behaviour. The presence of the so-called price asymmetry is also a characteristic phenomenon, when jumps in prices on the wholesale market are accompanied by a rapid increase in retail prices and a slow decline in retail prices after the reduction of wholesale prices. However, this is not the only problem in this market. Another characteristic phenomenon is the presence of price dispersion. This means that for the same product, at the same time, prices even at neighbouring gas stations are usually different. Establishing the conditions in which firms choose a range of prices was and remains the main issue in the theory of prices. Starting from the pioneering work of Stigler [1], the scientific environment recognizes the role of imperfect information in shaping the equilibrium price dispersion. In numerous publications on this topic, the idea is that markets consist of consumers who receive information actively seeking lower prices, as well as consumers who remain uninformed, as they prefer to avoid the cost of searching. This behavior allows some firms to set higher prices than others in equilibrium, even when all firms sell homogeneous goods with identical production costs. Therefore, the simplest explanation for these price differences, which is that gas stations are not homogeneous in terms of costs or quality of petroleum products, is not sufficient. The main reason for the spread of prices in the market of petroleum products, as well as in the markets of other goods, is the behaviour of consumers who are trying to find a bargain price. However, establishing evidence that price dispersion is the result of an inadequate search for consumer spending is not a trivial task. Empirical studies mostly relied on comparative statistics to determine the role of search in this market. In a number of studies, regressive dependencies of the price dispersion from the intermediate part of the search expense are set, while others create a quantity dependence and price dispersion from the number of firms on the market, which allows for a formal test for the existence of the price dispersion. In particular, the theoretical dependence between the search intensity and the price dispersion, which is nonmonotonic, as well as the reverse, confirms the role of the search, is established. In particular, the theoretical dependence between the intensity of the search and the price variance is established, which is nonmonotonic and also inverse, which confirms the role of the search. However, there is a need to construct a model that could describe the mechanism of generating a dispersion of prices in the petroleum product market and allow an assessment of this change in dispersion over the short term.

Related Works
G. Stigler has a fundamental paper [1] in which the phenomenon of price dispersion for a homogeneous product is established due to incomplete consumer awareness. In addition, it introduces the concepts of search and price dispersion -"A buyer (or seller) who wants to identify the most favourable price must be able to identify the various sellers (or buyers) -a phenomenon I will term search". However, this paper did not establish a direct link between price dispersions and user searches. Moreover, Diamond [2] discovered the famous paradox, establishing a "law of one price", on which the price can hold, despite the imperfect information. The Diamond's paper really shows that even with the cost of searching for standard terms of the oligopoly of Bertrand, there is a unique equilibrium with a monopoly price. A little later, in the paper [3], it was shown that the market equilibrium is achieved not at one price, but at a certain price distribution. The fundamentals of customer search theory and its role in price dispersion were laid down by Varian [4]. The most common assumptions about the optimal rules for finding this theory are: ─ Firms sell absolutely homogeneous goods; ─ Consumers carry the search costs to find prices beyond the first price; ─ The price distribution is fully assumed by consumers; ─ Consumers can do different ways of searching: for example, a consistent search by which consumers disclose one price by another at random; ─ The optimal search rule is then reduced to a backup price (constant if the search cost is linear). ─ Search ceases as soon as the price is below the reserve price.
Varian has shown that there is no equilibrium in pure strategies, but equilibrium is achieved in mixed strategies. Diamond's paradox and Bertrand's competition are extreme cases when all consumers are informed or not informed. This paper looks at the interesting conclusion about increasing the number of companies operating in the market. When the number of competitors increases, the likelihood that any particular seller will successfully sell the product to some informed clients is reduced. As a consequence, in the equilibrium distribution of prices, higher prices increase their share. But this effect turns out to be positive for informed customers, because the expected lower price is decreasing. The reason is that more firms compete and well-informed buyers pay the lowest price. For unskilled clients, the expected price is clearly increasing. The gasoline market is a good example of a homogeneous, albeit not perfect, market where price dispersions are observed. Many consumers are only aware of some prices, and this gives some monopoly power to gas stations. In many cases, consumers find themselves in a situation where fuel runs out and have no choice other than filling their petrol tanks at the first-best filling station they are facing, which gives additional market power for gas stations. Prices change quite often, and to determine which gasoline station has the cheapest fuel in this market is a non-trivial task. The price variation in the fuel markets was widely documented in the scientific literature. In particular, publications on this topic [5][6][7][8][9][10] examined the dependence of the price dispersion on the density of vendors on the number of gas stations in the radius of 1.5 -2.5 miles around each station.
The price variation is measured by unexplained price fluctuations, namely, the square of the residues of the logarithmic regression of market characteristics, including the density of sellers. It was established that the increase in the number of neighbouring gas stations is associated with a decrease in the price dispersion. Lewis [8] agrees on two previous approaches, using station-level data to control differentiation, and examines the link between price variability and local market characteristics. The data includes prices for 327 gas stations in the San Diego area each Monday 2000 and 2001 (91 weeks). The paper finds a negative connection between the density of sellers and the price dispersion, as in [6], and confirms and complements this result by introducing the difference between the groups of consumers who use elite fuel and groups that use simpler fuel grades. According to [9], data on petrol prices from the Netherlands showed that with increasing competition, the price dispersion is increasing: low prices are decreasing and high prices rise on average. As a result, competition has an asymmetric impact on prices, and all consumers, regardless of the amount of prices they are watching, benefit from an increase in the number of gas stations. However, the gain from this is greater for informed consumers. The model proposed by [10], and develops the Varian's sales model, yielded the following results.
Identification of the role of imperfect information cannot be made by simply checking the usual comparative static of the dispersion of prices for costs or benefits of the search, or the number of enterprises on the market. Price dispersion becomes a nonmonotonic function of these variables if we allow consumers to adjust their strategies for finding equilibrium. Using a new test of rank spreads and price spreads between pairs of stations, it has been found that the time dispersion of the prices at the market level is consistently higher than for stations at one crossroads. This is consistent with the theory of consumer search, since the dispersion in the latter group is carried out only through the differentiation of petroleum products. At the same time, the assumption that the development of modern communication technologies will automatically eliminate the problem of the variance of prices themselves did not justify. So, on the data of Italian motorways [11], found that increasing transparency of prices had little effect on the level of price dispersion. Analysis of customer transaction data shows that less than 10% of consumers effectively use price data.
The above results of outstanding researchers have proved not only the existence of a dispersion of prices in the market of petroleum products as a consequence of the search behavior of buyers, but also allowed to find quantitative dependence of price characteristics on the infrastructure parameters of the market and the behavior of market actors. However, many questions remain unclear. One of the difficult problems is the estimation of the change in the variance of retail prices in the case of spin-off changes in wholesale prices. As already noted, in such cases there is a phenomenon of price asymmetry caused by the behavior of participants in the oligopolistic market of petroleum products. This phenomenon was not studied by the classical theory, but in recent decades, by the efforts of many researchers, this gap has largely been overcome, but only with the assumption of a hypothesis of a single price. The question of how the variation in retail prices in wholesale jumps has attracted the attention of researchers recently, in particular Noel [12], based on retail gas prices (known as Edgeworth price cycles), has established a two-way link between price dispersion and consumer search. The search activity not only affects the variance, as it was well documented, but the price variance also affects the search. This is an extremely interesting result, which, however, did not eliminate the need to develop a model for assessing the dynamics of the dispersion of retail prices at the usual wholesale price jumps, and not for the case of exogenous shocks, as was investigated by Noel. For this non-trivial problem, it is necessary to have an appropriate methodology for the solution.

Data analysis
In this paper we study of the level of dispersion and its dynamics at the data on gasoline prices in the retail market of petroleum products of Ukraine for separate filling stations were provided by the Scientific-Technical Centre "Psychea". The choice of gasoline, as a fuel, is explained by the higher homogeneity of consumers, compared with consumers of diesel fuel. However, despite the homogeneity of the market of petroleum products, in particular the gasoline market, the product market boundaries were clearly limited to cover the most homogeneous product: ─ Only non-branded gasoline, which falls under the state standard of quality, is involved in the consideration. ─ Gasoline of the brand А-95 is considered, because this type of fuel has the most homogeneity of consumers.
A comparative analysis of regional petroleum products markets in Ukraine showed existent of a daily dispersion of prices for gas stations belonging to different owners, as well as a significant difference in the level of price dispersion between individual regions of the country (Fig. 1, 2). Although there is a certain correlation between the level of retail prices and the level of dispersion, the market concentration may also affect the level of dispersion. Therefore, the study of the phenomenon of price dispersion is advisable to do for individual regions, and not for the whole country as a whole, because it will distort the results. Therefore, a sample of historical data of retail prices for A-95 gasoline of the Kyiv region for the period 2012-2017 was selected for the study.  The analysis behaviour gasoline prices for years 2012-2017 showed that most developments in the petroleum product market characterized by unique dispersion, but for intermittent changes in retail prices, to some extent, can assert the presence of the characteristic pattern of behaviour dispersion. In Fig. 3 shows a typical pattern of dispersion behaviour at a jump in retail prices caused by fluctuations in world oil prices. A characteristic feature of the dispersion is a significantly higher level of dispersion in the course of price growth and its return to the initial level during a decline.

Model
There are many models of behavior of retail prices in the market of petroleum products. The overwhelming majority, including those that quantify the price dispersion phenomenon in the fuel market, are based on econometric approaches. However, for the study of the influence of the behavior of individual market agents on the behavior of market prices, the multi-agent approach seems more relevant. The bottom line is that multi-agent model of petroleum product markets can more flexibly take into account the different structure and rules for the functioning of national markets and the behavior of market agents. The model of [13] focuses on the interaction between gas stations and the diffusion of prices from one gas station to another in the territorial dimension. Many aspects of using the multi-agent approach to competition in oligopolistic markets were studied by [14][15]. The agent who makes the decision to change the price is a gas station and the influence of the gas station owner is absent. However, this approach is not universal. In some markets for petroleum products, in particular in the Ukrainian petroleum product market, prices for each of the gas stations are set by the owners of the networks. Prices can be the same at all gas stations or different, but at the same time during the change in prices observed their equal increase in absolute terms. This approach was implemented for the model of the phenomenon of asymmetry of retail prices and their prediction in the retail market of petroleum products in Ukraine [16]. For these models, the main indicator, on the basis of which the conformity of the model with real data was checked, was determined by the average retail price. Such a model enables to reproduce the behaviour of retail networks, based on a comparison of the average price in the model and the average market price. However, the analysis of the behaviour of dynamics of price dispersion in this model was not foreseen. To show this phenomenon, the model has been refined. So let's determine the main assumptions and simplifications that are put into the model: ─ At the gas station only one type of fuel is used (gasoline A-95). ─ Consumers have only cars. ─ The market is limited to a certain area. ─ The list of retail networks is deterministic and unchanged. ─ Retail networks change prices at the same time at all gas stations and at the same absolute value. ─ The location of the gas station corresponds to their actual location in the specified area. ─ Consumers are evenly distributed throughout the territory.
It should also be noted that an improved multi-agent model takes into account the basic means of state regulation of the pricing of retail networks. In particular, unlike petroleum products markets in some countries, where the change in retail prices is not forbidden for one day, the model takes into account the rule that operates in the Ukrainian petroleum product market, where retail networks can only change prices once a day. In the multi-agent petroleum market model there are the following agents: retail chain, gas station, consumer and trader. According to the model, the daily activities of petroleum products trading consist of the following actions: consumers purchase fuel, retail networks collect statistics from gas stations, gas stations if necessary, order a new consignment of fuel from the trader, interaction between the gas station and the trader, retail networks analysing all available information, set prices for the next day. The software model is represented by the following class diagram (Fig. 4). The base class of each agent is MAgent, which is followed by agents of the gas station (MAzs class), retail network (MAzsNet class) and trader (class MTrader). For abstraction of a separate modeling, there is the MSimulation class, which manages the whole model and provides a set of tools for working with the model. The MInformSystem class is an interface for agent communication and information support. It should be noted that in the absence of a dedicated state agent, his functions in this model are assigned to this class, namely: to provide information on the list of taxes paid by retail networks and their current rates. The dynamics of the interaction between the flows of agents is shown in Fig. 5.

Algorithm of Retail Networks Behaviour
In the proposed multi-agent model, the algorithm for retail network behaviour is based on states. The model outlines the following agent states retail network: market followup (S1), strategy changes (S2), trade stop (S3), return to market (S4). State S1 implements the behaviour of the agent in the presence of profits during periods of decline in prices and for their minor fluctuations during periods of high margins. State S2 realizes the agent's response to a sharp change in the market situation: a leap of prices, a sharp decline in demand, and so on. The states S3 and S4 implement market exit strategies if it is impossible to get the profit and return to the market in the event of such an opportunity. Fig. 6 shows a diagram of states of the mechanism of decisionmaking by the agent "Network". Agent's behavioral algorithm Network in state S1 has the following appearance: To analyse the current situation, each agent has a statistical module that, with the help of the Ordinary Least Squares method, linearly defines the trajectory of the main indicators. Variables with suffixes "_c" denote the coefficient of the linear equation with the corresponding variable. Analysis of real data showed that retail networks mostly do not adjust the prices daily for a small value, and make a change in prices at least a certain value (usually it is 0.1 -0.3 UAH / litre). Therefore, for the formation of the correct dispersion dynamics, the rules for the formation of threshold price changes by each network are additionally prescribed. In addition, in the price change algorithm, 3 main drivers are allocated, which form the necessary level of prices in the usual situation: ─ The behaviour of wholesale (current_trader_price) prices with respect to the prices of last fuel purchases (last_by_price). ─ Price behaviour of competing networks (competitors_prrice). ─ Optimal price that maximizes profit (optimal_price).
We determine the optimum price as maximizing the profit of the retail network, taking into account current demand: where   0 1 , avg avg avg P P D P P a a P    -function of estimating the volume of sales of fuel at the gas station; P avg -average fuel price within a radius of K km from the location of the gas station; P -the fuel price of the agent, the variable for which the optimization takes place; Tax -Tax Component; Costs -Costs; P c -the price of fuel purchases. The demand function coefficients (α 0 and α 1 ) are automatically evaluated for each agent individually and specified at each step of the model during simulation. It should be noted that the establishment of both the upper and lower bounds of this indicator is dictated by both insufficiently studied demand function and consumer behaviour. The formation of the initial level of dispersion is achieved by setting variables and constant costs for each network based on real estimates of these indicators with some correction on the assumption of model and the stability of the initial state of the model.

Algorithms of Consumer Behaviour
As the results of previous studies have shown, consumer strategy with the search for a base price can generate asymmetric behaviour of retail prices. Therefore, based on the basic algorithm of consumer behaviour, the search for the base price is chosen: the consumer searches until he finds a price not higher than the price of the previous purchase. At the same time, as you know, consumers are not homogeneous, and among them there are groups with other patterns of behaviour: consumer orientation at the price and random selection of gas stations. The algorithm of consumer behaviour with the search for the base price is presented in Fig. 7. The consumer makes several attempts to find a price lower than the price of the last purchase of fuel. In the basic version of the model, the number of attempts to search is 5. The behaviour of consumers without a search is equivalent to a uniform distribution of demand for all filling stations. The scheme of the algorithm is shown in Fig. 8.
The behavior of price-oriented consumers is carried out by the construction by each consumer of distribution at the gas station in accordance with the price level at the gas station. The basis of such a distribution is an exponential distribution with modifications based on the following empirical assumptions: the consumer is guided by the relative price level when selecting a gas station, the lower the price, the greater the probability of choosing this gas station. Given the complexity of estimating the additional distribution parameters it is assumed that the mathematical expectation is equal to 1, and the density function has the following form as follows: where price -price at the gas station, min(price) -the minimum price among all the gas stations in the field of consumer's vision, k -the coefficient of normalization of distribution density: where M -amount of fuel station that in field of consumer's vision. This list of observed gas stations prepared for each consumer using empirical assumption that maximum distance from consumer location to station must not exceed 7 km. This value was determined on the basis of a survey of drivers in the region of Kyiv and has a preliminary assessment character, which requires a separate study. However, in order of magnitude it coincides with the values of the authors in the literature cited above. Due to the lack of reliable data on consumer preferences in the choice of gas stations, the basic algorithm of consumer behaviour will be considered the algorithm for finding the base price. However, for comparison, all types of consumer behaviour algorithms were used.

Experimental Results
Nelder-Mead method was used to calibrate the model. The criterion of optimality was the sum of absolute deviations of average retail prices in the model from their real values. In total, 130 steps were taken to select the optimal model parameters. These parameters are the following parameters (the notation corresponds to the variables in algorithm above): ─ PrM (with value 7.1195) -optimal price correction coefficient, which determines the effect of the deviation of the calculated optimal price from the current price at the gas station; ─ Pd (with value 0.05) -a coefficient that determines the magnitude of the impact of competitors prices absolute value on the price of gas stations; ─ Ck (with value -2.8899) -coefficient, which determines the influence of the price trend of competitors to the price of gas stations; ─ Trk (with value 1.0292) -coefficient, which determines the effect of wholesale prices change on the price at the gas station; ─ Pd2 (with value -16.861) -the threshold of competitors average price delta, which is used to switch the pricing approach in the algorithm.
As a result of the selection of parameters, it was possible to achieve qualitative detection of the dynamics of retail prices (Fig. 9), while the dynamics of dispersion repeats the actual trends (Fig. 10). That is, the multi-agent model identifies a pattern of price dynamics and dynamics of price dispersion. It should be noted that in general, some discrepancy between the finite level of the real and the model dispersion can be dictated by the local peculiarity of the jump. A slightly lower dispersion level of 75-90 model days is caused by the early reaction of retail networks of the lower price segment. Such an early reaction to the rise in prices in these networks is due to the existence of a single algorithm of behaviour as retail networks operating on both purchased fuel and selfproduced fuel. Therefore, in some cases, the decision to change prices in such networks may occur somewhat later than other networks in connection with the monthly schedule of processing capacity.  Along with the calibration of the model of the dynamics of the dispersion of retail prices with the use of the algorithm for searching the base price for consumers, the possibility of forming adequate dispersion estimation for other types of consumer behaviour was also checked. In Fig. 11 shows a comparison of the dynamics of retail price dispersion by various consumer behaviour algorithms. Other patterns of consumer behaviour have a fundamentally different dynamics of dispersion. In cases of search and price targeting, almost the same growth of dispersion is observed during the growth of retail prices. However, in the case of price-targeting, the dispersion, and somewhat lowered while finding retail prices for the "plateau", began to increase again after falling prices. On the one hand, this testifies to the discrepancy of such behaviour with real situations. However, on the other hand, there may be a simple non-compliance of the rules of retail networks with a similar behaviour of consumers. It should be noted that the re-training of the model with the use of the algorithm of targeting the price was not carried out, because the replacement of the algorithm has a small effect on the dynamics of average prices. The dynamics of dispersion in the use of consumers without a search showed that such a type of consumers cannot be dominant in the market given the significant difference in dispersion from the real.

Conclusions
This paper proposes a multiagent model of the phenomenon of dispersion of prices in the market of petroleum products. The conducted research showed that the multiagent model of oil products market as an oligopolistic competitive environment, in which fuel consumers are guided by the strategy of price search, generates the phenomenon of the price variance regardless of the initial conditions of the variance values. The agents' interaction was based on oligopolistic competition rules and consumer price search strategies. This model was tested on the price data for gasoline in the Kyiv region of the Ukrainian oil market. The choice of data for this region and the choice of gasoline as a commodity were dictated by the desire to identify the effect of dispersion due to the existence of a search strategy for consumers on a market with a homogeneous product. At the same time, the existence of a dispersion of retail prices in the market of petroleum products has been shown as a result of oligopolistic competition of traders and price search behavior of buyers, as well as the growth of price dispersion at price jumps of wholesale prices. It is shown well enough to predict the appearance of this pattern at price jumps. It has been established that the best approach to real data, both in terms of price and dispersion, has been shown by the consumer strategy with the search for the base price. The availability of other search strategies has not been confirmed. Comparison of model calculations and real data showed a fairly satisfactory coincidence, which, however, needs to be improved. However, to do this, there is need to conduct additional research in mixed search strategies for different categories of users.