Upload
others
View
5
Download
0
Embed Size (px)
Citation preview
Submitted to Manufacturing & Service Operations Managementmanuscript (Please, provide the manuscript number!)
Authors are encouraged to submit new papers to INFORMS journals by means ofa style file template, which includes the journal title. However, use of a templatedoes not certify that the paper has been accepted for publication in the named jour-nal. INFORMS journal templates are for the exclusive purpose of submitting to anINFORMS journal and should not be used to distribute the papers in print or onlineor to submit the papers to another publication.
Dynamic Matching for Real-Time Ridesharing
Erhun Ozkan, Amy R. WardMarshall School of Business, University of Southern California, Los Angeles, California 90089,
[email protected], [email protected],
In a ridesharing system such as Uber or Lyft, arriving customers must be matched with available drivers.
These decisions affect the overall number of customers matched, because they impact whether or not future
available drivers will be close to the locations of arriving customers. A common policy used in practice is
the closest driver (CD) policy that offers an arriving customer the closest driver. This is an attractive policy
because it is simple and easy to implement. However, we expect that a forward-looking parameter-based
policy can achieve better performance.
We propose to base the matching decisions on the solution to a continuous linear program (CLP) that
accounts for (i) the differing arrival rates of customers and drivers in different areas of the city, (ii) how long
customers are willing to wait for driver pick-up, and (iii) the time-varying nature of all the aforementioned
parameters. We prove asymptotic optimality of a CLP-based policy in a large market regime. However,
solving the CLP is difficult, thus we also propose matching policies based on a linear program (LP). We prove
asymptotic optimality of an LP-based policy in a large market regime in which drivers are fully utilized.
We conduct simulation experiments to test the performances of the CD, the LP-based, and the CLP-based
matching policies.
Key words : ridesharing platforms, dynamic matching, asymptotic optimality.
History :
1. Introduction
Ridesharing platforms are online mobile platforms which match paying customers who
need a ride with drivers who provide transportation. Some examples of these platforms are
Uber and Lyft in America, Grab in Southeast Asia, and Didi Chuxing in China. Rideshar-
ing companies emerged in the last ten years, as the market penetration of smartphones
exploded, and have grown exponentially fast. The ridesharing companies all make use of
the relatively recent ability to track the locations of the customers and drivers continuously
1
Author: Dynamic Matching for Real-Time Ridesharing2 Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
(unlike the taxicab companies) which enables responsive and efficient market control (cf.
Azevedo and Weyl (2016)).
Ridesharing platforms are two-sided matching markets (cf. Rochet and Tirole (2006))
that pair customers and drivers. Typically, when a customer needs a ride, she requests the
ride via an application on a smartphone. The system controller, who is the correspond-
ing ridesharing company, matches the customer with a driver, if both sides approve the
matching. Then, the driver picks up the customer and takes her to her destination.
The ridesharing company would like to ensure there is always a nearby driver to offer an
arriving customer. This is because if a customer must wait too long for pick-up, then the
customer may refuse the ride and use another transportation option. However, maintaining
adequate driver supply is difficult. Not only do customers choose when to request a ride,
but also drivers choose when to begin work, how long to work, and where to go to search
for customers. The result can be dramatic changes in customer demand and driver supply
across different locations and over the course of a day, which sometimes results in significant
driver shortages (cf. Figures 1-3 in Hall et al. (2016)).
One common operational strategy is to match customers with the closest driver (CD),
and to use pricing to incentivize drivers to move to undersupplied locations. However,
surges in price can lead to negative publicity (cf. White (2016), The Economist (2016), and
Michallon (2016)). This leads to the question of whether better matching decisions could
reduce the need for price surges. An ideal is to solve a joint pricing and matching problem
that accounts for the impact of differing customer and driver location. However, that is
a very difficult problem. As a first step, we assume customer and driver arrival rates are
given, and focus on optimizing the matching decisions. The aforementioned rates can be
time-varying, and could potentially be thought of as the result of a pricing policy (as well
as other underlying incentives that may be given to drivers or customers, such as demand
information sharing or discount coupons). Our underlying assumption is that a decoupling
between the pricing and matching strategies is helpful. That is, the pricing strategy can be
used to balance the overall number of customers and drivers in the system, and the match-
ing strategy can be used to improve the geospatial driver supply and customer demand
balance.
The following example motivates why the matching decisions made by the CD policy
can be improved. Figure 1 represents part of a city, partitioned into ten disjoint hexagonal
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!) 3
areas, as is done by Uber (cf. Figure 3 in Chen and Sheldon (2016)). Suppose a customer
arrives at area 1 and requests a ride. There are three drivers idle in area 4 and there is
a single idle driver in area 3. Moreover, a concert recently ended in area 8, which implies
a high potential customer arrival rate in that area. If the destination of the current area
1 customer is far away, the driver assigned to that customer will not return to area 1 for
a long time. Then, the system controller has two options: He can either offer one of the
drivers in area 4 or the driver in area 3 to the customer in area 1. Under the CD policy,
the system controller offers an area 4 driver. However, offering the driver in area 3 saves
all drivers in area 4 to match with the potential customers departing the concert in area
8. This prevents the potential future need to offer an area 8 customer a far-away area 3
driver, whom the customer will likely refuse, ending in no match being made. We conclude
there is a nontrivial tradeoff between offering the closest driver in accordance with the CD
policy and offering a farther driver in order to maximize the future number of customers
matched.
!
"
#
$
%
&
'
(
)
!*
Figure 1 An intuitive explanation of why the CD policy may not assign the right driver to a customer.
1.1. Contributions of the Paper
We propose a matching policy for ridesharing and prove its optimality in a large mar-
ket asymptotic regime. The relevant objective is to maximize the number of customers
matched with drivers. The reason we focus on this objective rather than other common
objectives such as maximizing profit or revenue is that early-stage companies (such as most
ridesharing companies) often are mainly interested in growing their market share. This
leads to the following main contributions.
Author: Dynamic Matching for Real-Time Ridesharing4 Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
Formulating an analytically tractable ridesharing system model that captures location:
The essential first step to find an optimal, or near-optimal, matching policy for ridesharing
is the development of an analytically tractable model. That model must be rich enough to
capture the salient features of driver behavior. The issue is that tracking each individual
driver’s movement makes the analysis very difficult, if not impossible. Our novel insight is
that the area partitioning shown in Figure 1 leads naturally to the use of Poisson processes
to capture driver location. In particular, our assumption is that in the aggregate, the
individual driver decisions regarding when to begin and end work, if and where to move
when not transporting a customer, and what to do after customer drop-off result in non-
homogeneous Poisson arrival and departure processes to and from each of the different
areas.
Deriving an upper bound on the performance of any (admissible) matching policies: We
consider a large matching market, in which the arrival rates of the customers and drivers
grow without bound, so as to approximate the case of a large city. For any matching
policy that does not know the future with certainty, we establish that the solution to a
continuous linear program (CLP) is an asymptotic upper bound on the cumulative number
of matchings done in a finite time horizon, under fluid scaling (cf. Theorem 1). That upper
bound is very strong in the sense that it is valid on almost every sample path.
Proposing a matching policy based on the CLP: We provide matching policies that
asymptotically mimic the performance of any feasible CLP matching process (cf. Theorem
2). When the CLP is solvable, this leads to an asymptotically optimal matching policy (cf.
Corollary 1 and Theorem 3). Otherwise, there may exist a feasible CLP matching process
that can be used to develop a forward-looking policy that ameliorates the problematic
myopic behavior of the CD policy as in the example in Figure 1.
Proposing an asymptotically optimal matching policy based on a linear program (LP):
The upper bound CLP leads to an easily solvable upper bound LP when drivers are fully
utilized. We provide intuitive sufficient conditions on an underlying network game such
that drivers are fully utilized whenever prices “surge”. This motivates an asymptotically
optimal LP-based matching policy (cf. Theorem 4).
Providing simulation experiments to illustrate the performance of our CLP-based and
LP-based policies: Our simulation experiments in Section 5 show that both the CLP-
based and the LP-based proposed matching policies can significantly outperform the CD
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!) 5
policy. Consistent with intuition, we see that demand spikes coupled with low nearby driver
availability, such as in Figure 1, lead to the poor performance of the CD policy. This is
exactly when we recommend spending the extra effort of estimating parameters, such as
customer and driver arrival rates, in order to be able to implement a CLP- or an LP-
based matching policy. (In comparison, the CD policy requires no network information to
implement.)
The remainder of this paper is organized as follows. We conclude this section with a
literature review (cf. Section 1.2) and a summary of our mathematical notation (cf. Section
1.3). Section 2 presents our model. We formalize our large matching market regime, an
asymptotic upper bound on the cumulative number of matchings, and prove that a CLP-
based matching policy achieves that upper bound in Section 3. We motivate a condition
under which an LP-based matching policy achieves the asymptotic upper bound in Section
4. Section 5 presents some simulation experiments. Finally, we make concluding remarks
in Section 6. The proofs of all results can be found in the E-Companion.
1.2. Literature Review
In recent years, academic research related to ridesharing platforms has grown rapidly,
alongside the use of these platforms. An overview of research problems on ridesharing
platforms can be seen in Azevedo and Weyl (2016). While the effects of pricing have been
well-studied (cf. Chen et al. (2015), Cachon et al. (2016), Chen and Sheldon (2016), Hall
et al. (2016), Riquelme et al. (2016), Bimpikis et al. (2017), Guda and Subramanian (2017),
and Taylor (2017)), we are aware of no research on other ways to maximize matchings.
Dynamic matching control has been studied in the literature in the context of kid-
ney exchanges (cf. Unver (2010)), housing markets (cf. Leshno (2016)), online matching
platforms such as Upwork or Airbnb (cf. Arnosti et al. (2016)), and assemble-to-order
manufacturing systems (cf. Plambeck and Ward (2006) and Reiman and Wang (2015)).
However, the ridesharing model is different enough that it is not clear any of the results of
these studies carry over.
A method to control dynamic matching systems is the market thickening approach,
where the system controller first waits for jobs (that is, customers and drivers in the
context of this paper) to build-up, or thicken, in the market and then makes the matching
decisions. In the queueing literature, Gurvich and Ward (2014) consider a matching system
where jobs with multiple classes arrive in the system dynamically and randomly and prove
Author: Dynamic Matching for Real-Time Ridesharing6 Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
asymptotic optimality of a discrete review matching policy as the arrival rates of the jobs
increase (i.e., a large market assumption). The discrete review policy first lets the jobs
thicken in the system between the review epochs and then makes the matching decisions by
solving an LP at the review epochs. Akbarpour et al. (2016) consider a dynamic matching
network where jobs made to wait too long to be matched may abandon, or leave the system
without being matched. They prove that if the system controller can identify which jobs
are about to abandon, and match only those jobs, then waiting for other jobs to arrive
and thicken the market is very valuable. A straightforward implementation of the market
thickening approach does not work in our case because customers expect drivers to be
assigned to them immediately, and the system controller does not know when drivers will
decide to finish working for the day. However, a large market assumption that is similar
in spirit to the ones in Plambeck and Ward (2006), Gurvich and Ward (2014), Akbarpour
et al. (2016), Arnosti et al. (2016), Leshno (2016), and Riquelme et al. (2016) is the key
methodological insight we use to derive our matching policies.
A recent study applicable to ridesharing platforms is Hu and Zhou (2016), which con-
sider dynamic matching control of a two-sided, discrete-time matching system where both
supply and demand can abandon the system and the objective is to maximize the expected
total discounted profit. By using dynamic programming, Hu and Zhou (2016) derive some
structural properties of the optimal matching policies, that are different from ours (see
Remark 8).
The spirit of our methodology is drawn from the queueing control literature, where (i)
an asymptotic regime is defined, (ii) a control policy is derived from the solution of an
optimization problem, and (iii) asymptotic optimality of the control policy is proven (cf.
Harrison (2000) and Ata and Kumar (2005)). Similar methodology is used in Braverman
et al. (2017) to propose an empty car routing policy in a ridesharing model with limited
driver supply. However, that methodology does not in general allow for the derivation of
asymptotically optimal controls when the queueing network has time-varying arrival rates.
In contrast, in the context of matching, Gurvich and Ward (2014), Hu and Zhou (2016),
and our study all allow for time-varying arrival rates. Moreover, Hu and Zhou (2016) and
our study both consider the situation of a time-varying distribution that represents the
allowed waiting time for a match.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!) 7
There are some recent studies related to the stability of dynamic matching networks,
cf. Caldentey et al. (2009), Adan and Weiss (2012), Busic et al. (2013), Buke and Chen
(2015), and Moyal and Perry (2016). However, stability is not an issue in our case because
customers do not wait for pick-up from far away drivers and drivers leave their area if not
matched with a customer quickly enough.
1.3. Notation and Terminology
The set of nonnegative integers and strictly positive integers are denoted by N and N+,
respectively. The k dimensional (k ∈N+) Euclidean space is denoted by Rk and R+ denotes
[0,+∞). For x, y ∈ R, x ∨ y := maxx, y, x ∧ y := minx, y, and (x)+ := x ∨ 0. We let
B(Rk) denote the Borel σ-algebra on Rk for all k ∈N+ and L(R) denote the collection of
Lebesgue measurable subsets of R, which is a σ-algebra on R. For all T ∈ R+, B([0, T ])
and L([0, T ]) denote the Borel and Lebesgue σ-algebra on the interval [0, T ], respectively.
A function f :X→R defined in measure space (X,X ) is called X -measurable (denoted by
f ∈X ), if it is (X ,B(R))-measurable. If the measure space (X,X ) is (R,B(R)) ((R,L(R))),
we say that f is Borel (Lebesgue) measurable.
For each k ∈N+, Dk denotes the the space of all ω : R+→Rk which are right continuous
with left limits. Let 0, e∈D be such that 0(t) = 0 and e(t) = t for all t∈R+. We abbreviate
the phrase “independent and identically distributed” by “i.i.d.” and “almost surely” by
“a.s.”. The notationa.s.−−→ denotes almost sure convergence. We assume that all of the
random variables and stochastic processes are defined in the same complete probability
space (Ω,F ,P), E denotes the expectation under P, and P(A,B) := P(A ∩ B). We let
σX denote the σ-field generated by the random variable X, I denote the indicator
function, and ⊥ denotes independence.
2. A Ridesharing Model
We partition the city into N ∈ N+ disjoint areas, as illustrated in Figure 1, and assume
that in the aggregate the individual driver decisions (regarding their work schedule and
location) result in Poisson process arrivals and departures to and from each area. Specifi-
cally, type i drivers arrive at area i ∈N := 1,2, . . . ,N according to a non-homogeneous
Poisson process having instantaneous rate λi(t) at time t∈R+, and cumulative rate func-
tion Λi(t) :=∫ t
0λi(s)ds. The instantaneous rate at which type i drivers neither transporting
customers nor on their way to pick-up a customer leave area i∈N is θi(t).
Author: Dynamic Matching for Real-Time Ridesharing8 Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
Customers arrive in the system and request to be matched. The J ∈ N+ different cus-
tomer types are categorized by factors such as their origin and destination area, and
their priority status. Type j ∈ J := 1,2, . . . , J customers arrive in accordance with a
non-homogeneous Poisson process having instantaneous rate µj(t) at time t ∈ R+, and
cumulative rate function Γj(t) :=∫ t
0µj(s)ds. A matching policy π= (π1, . . . , πJ) determines
which driver type to offer an arriving customer. Each component πj tracks the sequence
of driver types offered to type j customers; i.e., when πj(k) = i, then the system controller
attempts to match the kth arriving type j customer with a type i driver, for j ∈ J , k ∈
N+, i ∈ N ∪ 0. The notation πj(k) = 0 implies no driver is offered to the customer, in
which case the customer is lost. The customer accepts the offered driver if the waiting time
required for pick-up is not too large (in a sense specified precisely below), and otherwise
the customer is lost and the offered driver stays in his current area. The implication is that
customers are classified as matched or unmatched (i.e., lost) at the time of their arrival,
even though a matched customer must still wait to be picked-up by a driver. The process
Dπij(t) tracks the cumulative number of type i drivers matched to type j customers under
policy π in [0, t].
The number of drivers in area i at time t∈R+ depends on the matching policy π. Then,
for Ai and Ri unit rate Poisson processes, the number of unmatched type i drivers at time
t is:
Qπi (t) =Qi(0) +Ai (Λi(t))−Ri
(∫ t
0
θi(s)Qπi (s)ds
)−∑j∈J
Dπij(t)≥ 0, (1)
where Qi(0), i ∈N are random variables independent of all other stochastic primitives.
The second term in the right-hand side of (1) represents the cumulative number of driver
arrivals to area i in [0, t], while the third and fourth terms represent the cumulative number
of driver departures from area i in [0, t] by unmatched and matched drivers, respectively.
We would like to match as many customers with drivers as possible. This is straightfor-
ward if there are many matching policies under which Qπi (t)> 0 for all i ∈N and t ∈R+,
because then there is always a driver near to an arriving customer. The difficulty is that in
general not every area will have an available driver – and which areas have available drivers
depends on earlier matching decisions. In this case, the arriving customer is matched only
if the time required for the driver to pick-up the customer is less than the amount of time
that customer is willing to wait for a driver.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!) 9
The time a customer is willing to wait for a driver can depend on the time of day. For
example, during working hours, a customer may be more time-constrained than during
non-working hours. We represent this using a step function that depends on the customer
arrival time. First, we partition the time horizon into countably many disjoint intervals by
defining the deterministic sequence τm,m ∈ N such that τm ∈ R+ and τm ≤ τm+1 for all
m∈N, and τm→∞ as m→∞. Second, to allow for potentially changing traffic conditions,
we define the pick up time of a type i driver for a type j customer who arrived in the system
at time t ∈ [τm, τm+1) by tij(m) ∈ R+ for all i ∈ N , j ∈ J , and m ∈ N. Third, we denote
the time the kth type j customer arrival is willing to wait for pick-up given the arrival
occurred at time t∈ [τm, τm+1) by the random variable akj (m) for all k ∈N+, j ∈J , m∈N.
The sequence akj (m), k ∈N+ is i.i.d., and independent of all other stochastic primitives
for all m∈N and j ∈J . Then, the probability that the kth type j customer accepts a type
i driver, given the arrival time is t, is
Fij(t) =∞∑m=0
P(akj (m)≥ tij(m)
)I (t∈ [τm, τm+1)) (2)
for all i∈N , j ∈J , k ∈N+, and t∈R+.
We connect our model to the queueing literature by showing its visual relationship to
a stochastic processing network (cf. Harrison (2000)) in Figure 2. The main difference is
that customers that do not accept their offered “server” (i.e., driver) are lost, with the
probabilities specified by Fij(t), for i∈N , j ∈J , and t∈R+.
The closest driver (CD) policy, denoted by πCD, offers a type j customer that arrives at
time t∈R+ a driver type from the set
arg mini∈N :Q
πCDi (t−)>0
∑m∈N
tij(m)I(t∈ [τm, τm+1)). (3)
If the set in (3) is not a singleton, the offered driver is chosen randomly from the closest
drivers. The question is: Does the CD policy match as many customers as possible?
The total cumulative number of matchings under any policy π depends on the number
of customers willing to wait for their offered driver. Specifically, if Ej is a unit rate Poisson
process and νj(k) := inft ∈ R+ : Ej(Γj(t)) = k is the arrival time of the kth type j ∈ Jcustomer, k ∈N+, then
Dπij(t) :=
Ej(Γj(t))∑k=1
∑m∈N
I(νj(k)∈ [τm, τm+1), a
kj (m)≥ tij(m), πj(k) = i
), (4)
Author: Dynamic Matching for Real-Time Ridesharing10Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
! " !
!" # !$ # !% #
&" #
'" #
&$ #
'$ #
&( #
'( #
)*"" #)*$" # )*(" #
Figure 2 A queueing-inspired visualization of our model formulation.
for all i ∈ N , j ∈ J , t ∈ R+, and under any policy π. Our objective is to find a policy π
that maximizes the total cumulative number of matchings made in a finite time horizon
over a specified class of admissible matching policies Π; that is, to solve
maxπ∈Π
∑i∈N ,j∈J
Dπij(T,ω), (5)
for all ω ∈Ω. In studying this problem, we obtain some results on the more general objective
maxπ∈Π
∑i∈N ,j∈J
wijDπij(T,ω) (6)
that also allows the system manager to provide weights wij, i ∈N , j ∈ J , on the possible
matchings. The objectives (5) and (6) are very strong objectives because solving either
requires specifying a policy that maximizes the number of matchings on every sample path.
Remark 1. In our model formulation, the driver types are formed only based on the
arrival locations of the drivers. However, we can extend our results to an arbitrary (but
finite) number of driver types I ∈ N+ by updating akj (m) to akij(m) for all k ∈ N+, j ∈ J ,
m ∈ N, and i ∈ I := 1,2, . . . , I. Then, akij(m) denotes the patience time of the kth type
j customer for a type i driver given that she arrived in the system on the time interval
[τm, τm+1), for all k ∈ N+, j ∈ J , m ∈ N, and i ∈ I. All of our results hold under this
extension.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)11
2.1. Admissible Policies
Roughly speaking, an admissible matching policy cannot anticipate the future. This is
formalized mathematically by defining the filtration F := F(t), t ∈ R+ that represents
the information known by the system controller as time moves forward as follows.
F(t) := σ
Ai(Λi(s)),Ej(Γj(s)),Ri
(∫ s−
0
θi(u)Qi(u)du
),Dij(s−),Qi(s−), akj (m)
∀s∈ [0, t], i∈N , j ∈J , m∈N, k ∈ 1,2, . . . ,Ej(Γj(t−))
. (7)
In (7), we see that when a customer arrives in the system at time t, the system con-
troller does not know how long she is willing to wait for driver pick-up. This is important
because otherwise the system controller could cherry-pick certain customers to offer far-
away drivers without consequence. The technical implication is that the filtration F is not
right continuous.
The information the system controller has at the arrival epoch of the kth type j customer
is
Fj(k) := σ
Ai(Λi(s∧ νj(k))),Ej′(Γj′(s∧ νj(k))),Ri
(∫ (s∧νj(k))−
0
θi(u)Qi(u)du
),
Dij′((s∧ νj(k))−),Qi((s∧ νj(k))−), ∀i∈N , j′ ∈J , s∈R+,
arj′(m), r ∈ 1, . . . ,Ej′(Γj′(νj(k)−)),∀j′ ∈J \j, arj(m), r ∈ 1, . . . , k− 1,∀m∈N
, (8)
for all k ∈ N+ and j ∈ J . Since each of the stochastic processes that generate the σ-field
in (7) is either right or left continuous and νj(k) is a stopping time with respect to the
filtration F for all j ∈J and k ∈N+, the σ-field in (8) is well defined. Since νj(k)≤ νj(k+1)
for all k ∈N+, Fj :=Fj(k), k ∈N+
is a filtration for all j ∈J .
Definition 1. (Admissible Policies) For all j ∈J , let Πj denote the set of discrete-time
stochastic processes with domain N+×Ω and range N ∪0, such that for all πj ∈Πj, πj
is Fj-adapted (i.e., πj(k)∈Fj(k) for all k ∈N+) and if Qi(νj(k)−) = 0 for some i∈N , then
πj(k) 6= i. Let Π be the set of J-dimensional discrete-time stochastic processes such that
for all π ∈Π, we have π= (π1, π2, . . . , πJ) where πj ∈Πj for all j ∈J . Then, Π is the set of
admissible policies.
Lemma 1. The CD policy is admissible; that is, πCD ∈Π.
Author: Dynamic Matching for Real-Time Ridesharing12Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
Remark 2. Although the system controller cannot anticipate either the arrival times of
the customers, or how long they will wait for pick-up, or how long the drivers will remain
in their current area, he can accurately forecast the arrival rates of the customer and driver
types and the driver acceptance probabilities associated with the customer types. In other
words, he knows the functions Λi, Γj, and Fij for all i∈N and j ∈J .
Remark 3. The filtration F can be augmented to include additional stochastic processes
Υm : R+×Ω→R with right or left continuous sample paths for all m ∈N, provided that
the sequence Υm,m∈N does not contain any future information related to the processes
that generate F(t) for all t∈R+. For example, if the system controller randomly chooses a
driver to offer an arriving customer, then Υm,m∈N includes a sequence of i.i.d. random
variables that reflect the outcome of an N -sided die roll.
Remark 4. Since the arrival process of each customer type is a non-homogeneous Pois-
son process, the probability that more than one customer arrives in the system simultane-
ously at some time epoch is zero. Therefore, the range of all πj ∈Πj is chosen as N ∪0
instead of the m-fold Cartesian product of N ∪0 for some m≥ 2 for all j ∈J .
Remark 5. Let F(νj(k)) denote the sigma algebra defined by the stopping time νj(k)
as in Definition 1.2.12 of Karatzas and Shreve (1988). Another way to define Πj is such
that for all πj ∈Πj, πj(k)∈F(νj(k)) for all k ∈N+. We do not choose this option because
proving akj (m)⊥F(νj(k)) for all j ∈J , m∈N, and k ∈N+ is difficult1, but akj (m)⊥Fj(k)
is by construction (cf. (8)). This result is exactly what prevents the system controller
knowing how long an arriving customer is willing to wait for driver pick-up, and so is
crucial to our model and analysis.
We end this section with the following technical assumption.
Assumption 1. (Technicalities) The functions λi : R+ → R+ and µj : R+ → R+ are
Borel measurable and the function θi is defined such that θi ∈D and θi ≥ 0 for all i∈N and
j ∈J . We assume that supt∈R+λi(t)<∞, supt∈R+
θi(t)<∞, and supt∈R+µj(t)<∞ for all
i∈N and j ∈J . The unit rate Poisson processes Ai,Ri, and Ej are mutually independent
for all i∈N and j ∈J .
1 Intuitively, one can expect that Fj(k) =F(νj(k)) for all j ∈J and k ∈N+. Although such a result is proved underspecific measure spaces (cf. Lemma 5.4.18 of Karatzas and Shreve (1988) and Lemma 1.3.3 of Stroock and Varadhan(2006)) or under some assumptions (cf. Theorem 1.6 of Shiryaev (2008)), none of them is applicable to our case.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)13
3. An Asymptotically Optimal CLP-Based Matching Policy
It is very difficult to solve the optimization problem (6) exactly. Even if we can accomplish
this very challenging task, the optimal matching policy will most likely be sample path
dependent and will be very complicated. Hence, we consider a large market where the
arrival rates of the customers and drivers grow without bound, and solve (6) under fluid
scaling in that limiting regime. Section 3.1 specifies the large market limiting regime and
the fluid scaling. Section 3.2 establishes that the solution to a CLP serves as an asymptotic
upper bound on the objective (6) under fluid scaling. Section 3.3 provides a simple policy
that can achieve asymptotically any matching process feasible for the CLP, and, therefore,
can be used to specify an asymptotically optimal policy when the CLP is solvable.
3.1. A Large Matching Market
We consider a sequence of matching systems indexed by n, n∈N+. Each matching system
has the same primitives with the one introduced in Section 2 except that the arrival rates
of the drivers and customers, and departure rates of unmatched drivers from their current
areas depend on n. In the nth matching system, for all i∈N , j ∈J , and t∈R+, let
Λni (t) :=
∫ t
0
λni (s)ds, Γnj (t) :=
∫ t
0
µnj (s)ds, (9)
where λni : R+→ R+ and µnj : R+→ R+ are Borel measurable rate functions for all i ∈N ,
j ∈ J , and n ∈ N+. Moreover, θni ∈ D and θni ≥ 0 for all i ∈ N and n ∈ N+. A policy
π = πn, n∈N+ is a sequence that specifies a policy for each n, and π is admissible if πn
is admissible for all n ∈ N+. For a policy such as CD that does not change with n, in a
slight abuse of notation, we specify π (i.e., π = πCD) and assume πn = π for all n ∈ N+.
Our notational convention is to denote a process (or random variable) X in the nth system
under the admissible policy π by Xπ,n.
Increasing the arrival rates without a bound and keeping the departure rates of
unmatched drivers from their areas bounded results in a crowded matching system where
we can use law of large numbers type of results to obtain tractable approximations for the
processes of interest.
Assumption 2. (Large Market) We assume that Λni /n → Λi uniformly on compact
intervals (u.o.c.)2 and∫∞
0|µnj (s)/n−µj(s)|ds→ 0 as n→∞ for all i∈N and j ∈J . The
2 For f ∈ D and T1 ∈ R+, we let ‖f‖T1 := sup0≤t≤T1|f(t)|. Let Xn, n ∈ N be a sequence in D and X ∈ D. Then
Xn→X u.o.c. as n→∞, if ‖Xn−X‖T1 → 0 as n→∞ for all T1 ∈R+.
Author: Dynamic Matching for Real-Time Ridesharing14Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
latter convergence implies that Γnj /n→ Γj u.o.c. as n→∞ for all j ∈J . We assume that
θni → θi u.o.c. for all i∈N .
Assumption 2 does not necessarily imply that the arrival rates of all customer and driver
types grow to infinity for all t ∈ R+ as n→∞. In particular, arrival rates can be zero in
some areas during some time periods (e.g., λni = µnj = λi = µj = 0 for some i∈N and j ∈Jand all n∈N+), as may be true in parts of the city during very early morning hours.
We focus on the first-order imbalances between the driver supply and customer demand
by considering fluid scaling. For all i∈N , j ∈J , t∈R+, n∈N+, and admissible policy π,
define
Ani (t) :=Ai(nt)/n, Rn
i (t) :=Ri(nt)/n, Enj (t) :=Ej(nt)/n, (10a)
Λni := Λn
i /n, Γnj := Γnj /n, Qπ,ni :=Qπ,n
i /n, Dπ,nij :=Dπ,n
ij /n. (10b)
By (1), (10a), and (10b), for all i∈N , t∈R+, n∈N+, and admissible policy π,
Qπ,ni (t) = Qn
i (0) + Ani (Λn
i (t))− Rni
(∫ t
0
θni (s)Qπ,ni (s)ds
)−∑j∈J
Dπ,nij (t)≥ 0. (11)
Our analysis requires the initial number of drivers waiting to be very small. When the
horizon length represents a working day, this corresponds to assuming the number of drivers
during the late night hours is very small. In general, the horizon length is arbitrary, and
can be smaller (i.e., correspond to so-called “rush” hour) or longer (i.e., represent multiple
days).
Assumption 3. (Initial Conditions) We assume that Qni (0)
a.s.−−→ 0 as n→∞ for all
i∈N .
Assumptions 1, 2, and 3 are in force throughout the paper.
3.2. An Asymptotic CLP Upper Bound
In this section, we derive an asymptotic upper bound on the fluid scaled objective (6) by
solving a CLP. The decision variables xij : [0, T ]→ R+ for all i ∈ N and j ∈ J are such
that xij(t) denotes the fraction of type j customers who are offered type i drivers at time
t, so that µj(t)Fij(t)xij(t) approximates the instantaneous matching rate between type i
drivers and type j customers. The relevant CLP is:
max∑
i∈N ,j∈J
wij
∫ T
0
µj(s)Fij(s)xij(s)ds, (12a)
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)15
subject to:∑j∈J
∫ t
0
µj(s)Fij(s)xij(s)ds≤Λi(t), for all i∈N and t∈ [0, T ], (12b)
∑i∈N
xij(t)≤ 1, for all j ∈J and t∈ [0, T ], (12c)
xij(t)≥ 0, for all i∈N , j ∈J , and t∈ [0, T ], (12d)
xij is Lebesgue measurable for all i∈N and j ∈J . (12e)
Constraint (12b) implies that the cumulative number of customers who are assigned to
type i drivers up to time t cannot be greater than the cumulative number of type i drivers
arrived in the system up to time t for all t ∈ [0, T ] and i ∈ N . Constraint (12c) implies
that a customer cannot be offered more than one driver. A more complicated CLP also
incorporates the fluid-scaled version of (11) (so that parameter θi, i∈N appears); however,
as discussed in the E-Companion, that more complicated CLP does not lead to more
general results.
Lemma 2. There exists an optimal solution of the CLP (12).
We denote an optimal solution of the CLP (12) by the process x := xij(t), i ∈ N , j ∈
J , t∈ [0, T ]. The following theorem establishes that the optimal objective function value
of the CLP (12) is an asymptotic upper bound on the fluid scaled objective (6) under any
admissible policy for almost all sample paths.
Theorem 1. Under any admissible policy π,
lim supn→∞
∑i∈N ,j∈J
wijDπ,nij (T )≤
∑i∈N ,j∈J
wij
∫ T
0
µj(s)Fij(s)xij(s)ds, a.s.
The key challenge is to show that there exists a feasible matching process xij(t), i∈N , j ∈
J , t∈ [0, T ] (not necessarily optimal) such that the derivative of the limit of the fluid scaled
cumulative matching process Dπ,nij (t), i ∈ N , j ∈ J , t ∈ [0, T ] corresponds to the process
µj(t)Fij(t)xij(t), i ∈N , j ∈ J , t ∈ [0, T ]. If the aforementioned feasible matching process
is x, then the upper bound in Theorem 1 is attained, meaning the policy is asymptotically
optimal.
The CLP (12) assumes that drivers will wait in their current location as long as necessary
to be matched with customers, because the CLP does not incorporate θi, i∈N . Although
that provides a clear upper bound on the matching rates, that upper bound is not always
Author: Dynamic Matching for Real-Time Ridesharing16Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
achievable. In particular, in the case of a forward-looking CLP solution, the drivers must
be patient enough to wait to be matched with closer customers arriving later in time (as
in the example depicted in Figure 1).
3.3. A CLP-Based Randomized Policy
We would like to find an admissible matching policy that can reproduce any feasible match-
ing process x := xij(t), i∈N , j ∈J , t∈ [0, T ] for the CLP (12) (including an optimal one,
x). This is important because finding a feasible matching process that improves on any
myopic matching policy (such as CD) may be possible even when finding an optimal CLP
solution is not. The question is: How do we translate between a feasible matching process
and the decision of which driver to offer an arriving customer?
Definition 2. (Randomized Policy) If a type j customer arrives in the system at time
t, the system controller makes a random selection from the set N ∪ 0 such that the
probability that the outcome is i is xij(t) for all i∈N and the probability that the outcome
is 0 is 1−∑
i∈N xij(t). If the outcome is i for some i∈N and there is a type i driver in the
system, then the system controller offers a type i driver to the customer. If the outcome
is i for some i∈N but there is no type i driver in the system or if the outcome is 0, then
no driver is offered to the customer (and so the customer is lost).
We denote the randomized policy by πR and write πR(x) when we want to emphasize
its dependence on the particular feasible matching process x. Under a technical condition
on the associated feasible matching process for the CLP (12), πR is admissible.
Lemma 3. Suppose that the feasible matching process for the CLP (12), x, is such that
xij is a Borel measurable simple function with possibly countably infinite range for all i∈N
and j ∈J . Then, πR(x) is admissible.
The randomized policy is a simple policy, because no state information is needed for
its implementation. Still, its performance replicates any feasible matching process for the
CLP (12), when drivers are willing to wait in their current locations to be matched.
Theorem 2. Suppose x is a feasible matching process that satisfies the condition in
Lemma 3. Fix an arbitrary i∈N . If θi = 0, then
sup0≤t≤T
∣∣∣∣∣∑j∈J
(DπR(x),nij (t)−
∫ t
0
µj(s)Fij(s)xij(s)ds
)∣∣∣∣∣ a.s.−−→ 0, as n→∞.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)17
Theorem 2 shows that when an optimal solution x to the CLP (12) is a Borel mea-
surable simple function, then πR(x) attains the upper bound in Theorem 1. However, x
may not satisfy the aforementioned condition. Then, we do not know the associated ran-
domized policy is admissible, and so we cannot use Theorem 2 to ensure the upper bound
in Theorem 1 is achieved. However, we can approximate an optimal CLP (12) solution
with a sequence of Borel measurable simple functions to ensure the upper bound is nearly
achieved. Specifically, by Theorem 2.10 and Proposition 2.12 of Folland (1999), there exists
a sequence of feasible matching processes for the CLP (12) denoted by xr, r ∈N+ such
that xr := xrij(t), i ∈ N , j ∈ J , t ∈ [0, T ], for all i ∈ N , j ∈ J , and r ∈ N+, xrij is a Borel
measurable simple function, 0≤ xrij(t)≤ xr+1ij (t)≤ xij(t) for all t∈ [0, T ], and xrij(t)→ xij(t)
as r→∞ for all t ∈ [0, T ] except on a set of zero measure. Then, by Theorem 2 and the
bounded convergence theorem used on the sequence µj(t)Fij(t)xrij(t), t ∈ [0, T ], r ∈ N+,
we have the following corollary.
Corollary 1. If θi = 0 for all i ∈ N , then for any ε > 0, there exists an r0(ε) ∈ N+
such that if r≥ r0(ε),
limn→∞
∑i∈N ,j∈J
DπR(xr),nij (T )≥
∑i∈N ,j∈J
∫ T
0
µj(s)Fij(s)xij(s)ds− ε, a.s.
Solving the CLP (12) or accurately approximating an optimal solution of it is a very
challenging task (cf. Perold (1981)). If µj(t)Fij(t) was a constant function of t for all i∈N
and j ∈ J , then the CLP (12) would become a Separated Continuous Linear Program
(SCLP). Although an SCLP is solvable (cf. Anderson et al. (1983) and Weiss (2008)), it
is an NP-hard problem (cf. Bertsimas et al. (2015)). The even more restricted assumption
that eliminates time dependent parameters implies that the CLP (12) can be solved by an
LP.
Theorem 3. If λi, µj, and Fij are constant functions of t for all i∈N and j ∈J , then
there exists an optimal solution of the CLP (12) denoted by x such that x(t) = x∗ for all
t∈ [0, T ], where x∗ := x∗ij, i∈N , j ∈J is an optimal solution of the following LP, having
the decision variables xij, i∈N , j ∈J :
max∑
i∈N ,j∈J
wijµjFijxij, (13a)
Author: Dynamic Matching for Real-Time Ridesharing18Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
subject to:∑j∈J
µjFijxij ≤ λi, ∀i∈N ,∑i∈N
xij ≤ 1, ∀j ∈J , xij ≥ 0, ∀i∈N , j ∈J .
(13b)
Furthermore, if wij = 1 for all i∈N and j ∈J , then πR(x) achieves the asymptotic upper
bound given in Theorem 1; i.e.,
limn→∞
∑i∈N ,j∈J
DπR(x),nij (T ) =
∑i∈N ,j∈J
∫ T
0
µj(s)Fij(s)xij(s)ds, a.s.
In contrast to Theorem 2 and Corollary 1, Theorem 3 does not require θi = 0 for all
i ∈N . This is because an LP-based policy is myopic. In particular, such a policy will not
prolong driver waiting in some areas in anticipation of future demand changes.
The assumption of time homogeneous parameters in Theorem 3 is severe. We would like
to find another sufficient condition under which the CLP (12) can be easily solved.
4. An Asymptotically Optimal LP-Based Randomized Policy
An LP-based matching policy arises naturally when we consider an underlying network
game in which raising prices decreases customer demand and increases driver supply. Then,
a“smart” system controller will not raise prices beyond what is needed to match driver
supply with customer demand. The implication is that the CLP constraint (12b) should be
binding, as discussed in Section 4.1. Then, an LP-based randomized policy is asymptotically
optimal, as shown in Section 4.2.
4.1. Connection of the CLP (12) with Pricing
Suppose we view λi(t), µj(t), and θi(t) for all i∈N and j ∈J as outcomes of an underlying
network game played by the customers, the drivers, and the system controller at time t
for all t ∈R+. Then, the arrival rates of customers and drivers (λi(t) and µj(t)), and the
departure rates of unmatched drivers (θi(t)), can depend on prices, and potentially other
incentives, such as travel times and shared demand information. Provided λi, µj, and θi
for all i∈N and j ∈J do not depend on the matching policy, all of the analyses hold; in
particular, Theorem 1 provides an upper bound on the cumulative number of matchings
and Theorem 2 implies that any feasible matching process for the CLP (12) is achievable
by the randomized policy.
We would like to provide intuition for why an underlying network game can result in the
ability to specify a CLP optimal solution through LP solutions. To do that, suppose that
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)19
the CLP constraint (12b) is not binding at some times in an area. The implication is that
there are excess drivers. Then, assuming that decreasing prices encourages more customers
but less drivers to arrive, the system controller would like to decrease prices. However, the
system controller would only do that until there are no more excess drivers, that is until all
drivers are matched. Furthermore, the system controller would not decrease prices more
because that would result in more customers than drivers.
Requirement on Underlying Network Game If there are unmatched drivers in
the system, then there exists a pricing adjustment under which all drivers being matched
increases the total matchings.
This suggests that “good” pricing decisions lead to an outcome in which driver supply and
customer demand over all the areas are equal under “good” matching decisions.
Assumption 4. (Fully Utilized Drivers) There exists a feasible matching process for the
CLP (12), denoted by x, such that∑i∈N ,j∈J
∫ t
0
µj(s)Fij(s)xij(s)ds=∑i∈N
Λi(t), for all t∈ [0, T ].
In other words, a “smart” system controller lowers prices when there are excess drivers in
the system when he can.
One potential issue with using the underlying network game requirement to motivate
Assumption 4 is that there is generally some minimal price. Many ridesharing companies
use an area and time specific “surge” multiplier to attract more drivers when the customer
demand exceeds the driver supply. However, if that multiplier cannot go below 1, then the
result is that there can be times when there are too many drivers (i.e., the right-hand side
of the display in Assumption 4 strictly exceeds the left-hand side). This adds another layer
of complexity, because this is exactly the situation in which the system controller desires
a forward-looking policy that “saves” some of the excess drivers for future anticipated
increases in customer demand (meaning we require understanding the solution to the CLP
(12)). Still, even in this situation, focusing only on a time period during which prices are
above their minimal level provides a time period during which Assumption 4 should be
in force (although, admittedly, how to connect between that time period and another in
which prices are at their minimal level is not obvious, because a CLP cannot in general be
“broken up”).
Assumption 4 is valid in the rest of Section 4 (but not necessarily in Section 5).
Author: Dynamic Matching for Real-Time Ridesharing20Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
Remark 6. Assumption 4 is parallel to Assumption 1 in Harrison (2000), which intro-
duces an optimization problem to define fully utilized resources in the queueing literature
when parameters do not vary with time.
4.2. An LP-Based Randomized Matching Policy
We begin by observing that Assumption 4 implies the CLP constraint (12b) binds for all
i ∈ N under at least one optimal CLP solution. This is because any feasible matching
process that satisfies Assumption 4 must be optimal because all of the drivers are matched
under this solution. Second, under any feasible matching process that satisfy Assumption 4,
if any one area i is such that the constraint (12b) has slack, then there must be another area
k such that the number of matched customers exceeds the cumulative driver arrivals (i.e.,
the left-hand side of the constraint strictly exceeds the right-hand side) which produces an
infeasible matching process. Now, the following LP is relevant at each fixed t∈ [0, T ]:
max∑
i∈N ,j∈J
wijµj(t)Fij(t)xij(t), (14a)
subject to:∑j∈J
µj(t)Fij(t)xij(t)≤ λi(t), ∀i∈N , (14b)
∑i∈N
xij(t)≤ 1, ∀j ∈J , (14c)
xij(t)≥ 0, ∀i∈N , j ∈J , (14d)
where the decision variables are xij(t) for all i∈N and j ∈J . The main difference between
the LP (14) and the CLP (12) is that (14a) and (14b) in the LP (14) are the derivatives of
(12a) and (12b) in the CLP (12), respectively. By Assumption 1 and the fact that xij(t) = 0
for all i∈N and j ∈J is feasible for the LP (14) for all t∈ [0, T ], there exists an optimal
solution of the LP (14) for all t∈ [0, T ].
Assumption 5. (Measurability) There exists a deterministic process x∗ := x∗ij(t), i ∈N , j ∈ J , t ∈ [0, T ] such that x∗ij(t), t ∈ [0, T ] is Lebesgue measurable for all i ∈ N and
j ∈ J , and x∗ij(t), i ∈ N , j ∈ J is an optimal solution of the LP (14) at time t for all
t∈ [0, T ].
If each of λi and µj is a step function (with possibly countably infinite range) for all i∈Nand j ∈ J , then there exists a deterministic function which satisfies Assumption 5, and
that function can be chosen as a step function. Assumption 5 is valid in the rest of Section
4.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)21
The following result connects the CLP (12) with the LP (14).
Lemma 4. The process x∗ is an optimal solution of the CLP (12).
Lemma 4 combined with Theorem 1 imply the following asymptotic LP-based upper
bound on the fluid scaled objective (6).
Corollary 2. Under any admissible policy π,
lim supn→∞
∑i∈N ,j∈J
wijDπ,nij (T )≤
∑i∈N ,j∈J
wij
∫ T
0
µj(s)Fij(s)x∗ij(s)ds, a.s.
In order to obtain the upper bound in Corollary 2, the LP (14) must be solved infinitely
many times (for all t ∈ [0, T ]). However, in practice, the LP (14) can be solved at finitely
many time epochs, and the remaining x∗ij(t) values can be approximated by, for example,
linear interpolation or assuming that x∗ij is a step function with finite range.
The randomized policy πR(x∗) is LP-based. To be admissible (a necessary condition for
asymptotic optimality), the condition in Lemma 3 must be satisfied.
Theorem 4. Suppose x∗ satisfies the condition in Lemma 3. If wij = 1 for all i ∈ N
and j ∈J , then πR(x∗) achieves the asymptotic upper bound given in Corollary 2, i.e.,
limn→∞
∑i∈N ,j∈J
DπR(x∗),nij (T ) =
∑i∈N ,j∈J
∫ T
0
µj(s)Fij(s)x∗ij(s)ds, a.s.
The LP-based randomized policy is myopic. As a consequence, for the same reason
explained after Theorem 3, Theorem 4 does not require the condition θi = 0 for all i ∈
N . Another consequence is that the time-varying parameters can be estimated in real-
time, because the matching decisions do not depend on future estimated arrival rates of
customers and drivers.
5. Performance Evaluation
We begin by observing that the performance of the randomized policy can likely be
improved by incorporating state information. This is because the randomized policy can
match a customer with an area in which there are no drivers, leading to that customer
being lost. To correct this, in Section 5.1, we introduce state-dependent LP- and CLP-based
policies, that require knowledge of driver locations. Then, in Section 5.2, we compare the
performance of those policies and the LP- and CLP-based randomized policy against the
benchmark CD policy. We do this first when parameters do not vary with time and second
Author: Dynamic Matching for Real-Time Ridesharing22Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
when they do. In the first case, the LP- and CLP-based policies coincide (cf. Theorem
3), whereas in the second, when the importance of considering future customer and driver
arrival rates becomes important, they do not.
5.1. Additional Proposed Matching Policies
The randomized policy is not match conserving in the sense that a customer arriving at a
time when at least one driver is available is always offered a driver. The benchmark CD
policy (in (3)) is match conserving. We propose two new policies, one deterministic and one
not, that are match conserving and can be based on either a CLP (12) or LP (14) solution,
depending on whether or not Assumption 4 holds. Assume x is a feasible matching process
for the CLP, which includes x∗ when Assumption 4 holds.
Deterministic Policy: If a type j ∈J customer arrives in the system at time t, the system
controller offers a driver type from the set
arg mini∈N :Qi(t−)>0
Dij(t−)−
∫ t
0
µj(s)Fij(s)xij(s)ds
. (15)
If the set in (15) is not a singleton, then the system controller can use any tie breaking
rule which does not use any future information. If there is no driver in the system, then no
driver is offered. (Note that we have suppressed the dependence of Dij, µj, and Fij on n in
the notation to emphasize that the policy can be applied directly to the model in Section 2,
even though any results obtained on its asymptotic performance would require reference
to the sequence of matching systems introduced in Section 3 and used in Sections 3 and 4.)
Hybrid Policy: Suppose that a type j customer arrives in the system, and there is a
driver in the system. Then the system controller makes a random selection in the same
way explained under the randomized policy. If the outcome is i for some i∈N and there is
a type i driver in the system, the system controller offers a type i driver to the customer.
If the outcome is i for some i ∈ N but there is no type i driver in the system or if the
outcome is 0, the customer is offered the driver type specified in (3) by the CD policy. If
there is no driver in the system, then the customer is lost.
Remark 7. Let α : J → N be a function which specifies the arrival location of each
customer type. If xij = 0 for all i∈N and j ∈J such that i 6= α(j), then the Hybrid policy
is the CD policy defined in (3).
Lemma 5. The deterministic and hybrid policies are admissible under the condition on
x in Lemma 3.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)23
The deterministic and hybrid policies can be implemented regardless of whether or not
they are admissible. However, in order to prove asymptotic optimality results parallel
to those for the randomized policy (specifically, Corollary 1 and Theorems 2, 3, and 4),
admissibility is required (and can be achieved using the approximation explained prior to
Corollary 1). The proofs of the aforementioned asymptotic optimality results are much
more difficult due to the state dependence.
5.2. Simulation Experiments
In this section, we present simulation experiments where we test the performances of the
CD policy and the LP- and CLP-based matching policies. We associate the LP- and CLP-
based policies based on an optimal solution of the LP (14) and an optimal solution of the
CLP (12), respectively. We present an experiment with time homogeneous parameters in
Section 5.2.1 and an experiment with time dependent parameters in Section 5.2.2.
The term “offered driver” refers to the driver offered to an arriving customer, that is
determined by the matching policy. The customer may or may not accept being matched
with the driver offered at the arrival time t ∈ [0, T ], depending on the driver type i ∈N ,
the customer type j ∈J , and the acceptance probability Fij(t). Any variation of the word
“match” means that the relevant customer has both been offered a driver, and has accepted
that driver, meaning that driver picks up that customer.
We assume that the larger the Fij(t) at time t∈ [0, T ], the smaller the pick up time of a
type i driver for a type j customer. Then, under the CD policy, the offered driver set for a
type j customer arriving at time t in (3) is exactly arg maxi∈N :Qi(t−)>0 Fij(t) for all j ∈Jand t∈R+ (and the match occurs if also the resulting pick-up time is lower than the time
that customer is willing to wait for pick-up).
We choose N = J = 3 in both simulation experiments (so the customer type represents
the customer’s arrival location). This is the smallest network size possible that allows for us
to illustrate the more general insight behind when and why LP-based policies outperform
CD. The reason a two area network will not work is that as long as Fii(t) ≥ Fij(t) for
all i, j ∈ 1,2,3 and t ∈ [0, T ], the LP-based policies give more priority to within-area
matchings than they give to between-area matchings, which exactly coincides with the CD
policy. In contrast, the reason CLP-based policies outperform CD (as well as any other
myopic policy such as an LP-based one) has to do with their potential to be forward-
looking, which can be seen in a two-area network.
Author: Dynamic Matching for Real-Time Ridesharing24Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
Implementation Details. We used Omnet++ discrete-event simulation freeware. In each
experiment, we started with an empty system; i.e., Qi(0) = 0 for all i∈N . At each simula-
tion instance associated with each matching policy, we have done Rep number of replica-
tions. The maximum of the margin of errors associated with the 95% confidence interval
for the percentage of all customers matched (= t0.025,Rep−1× Sample Stdv./√Rep) among
all policies in all instances is less than 0.42.
!" # $
%" # &
!' # &
%' # &
!( # &
%( # $
)*"' # )*'" # $+,, )*'( # )*(' # $+,-!" #" $"
)*"( # )*(" # $
Figure 3 The parameters of the first simulation experiment are: Qi(0) = 0, θi = 0.1, Fii = 1, wij = 1 for all i, j ∈
1,2,3, and n∈ 1,10,100.
5.2.1. Time Homogeneous Parameters We present a simulation experiment which
shows that our LP-based policies can potentially match more customers and drivers in
a finite time horizon than the CD policy does. Figure 3 provides all input parameters.
Since all parameters are time homogeneous, the LP- and CLP-based policies coincide (cf.
Theorem 3). We omit “(t)” from the notation. Moreover, n ∈ 1,10,100 measures the
market size, as in Assumption 2.
The intuition for why we do not expect the CD policy to perform well in this example
is as follows. Under the CD policy, when a type 1 or 2 customer arrives in the system,
the offered driver is type 2 (if there is one in the system) because λ1 = 0, F21 > F31, and
F22 > F32. Since µ1 + µ2 = 2n > λ2 = n, some of the type 1 or 2 customers cannot be
offered type 2 drivers and must be offered type 3 drivers. The type 2 customers who are
not offered type 2 drivers are offered type 3 drivers and so 98% of those customers are
matched. However, the type 1 customers offered type 3 drivers are lost because F31 = 0.
In comparison, the optimal solution of the LP (13) has x∗21 = 1, x∗22 = 0.01, and x∗32 = 0.99.
In words, the LP-based policies match type 1 customers with type 2 drivers and type 2
customers with type 3 drivers, to prevent losing a non-trivial percentage of the type 1
customers.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)25
CD Rand. Det. Hyb.50
60
70
80
90
100%
Cu
sto
me
rs M
atc
he
d LP Ub.
(a) n= 1
CD Rand. Det. Hyb.50
60
70
80
90
100
% C
usto
me
rs M
atc
he
d LP Ub.
(b) n= 10
CD Rand. Det. Hyb.50
60
70
80
90
100
% C
usto
me
rs M
atc
he
d LP Ub.
(c) n= 100
Figure 4 The percentage of all customers matched in the simulation experiment corresponding to Figure 3.
Figure 4 shows the percentage of all customers matched with drivers in the simulation
experiment (i.e., the objective (5), since wij = 1 for all i, j ∈ 1,2,3) under the CD pol-
icy and the LP-based policies. “LP Ub.” shows one hundred times the optimal objective
function value of the LP (13) divided by the total customer arrival rate to the system,
which is an approximate upper bound on the percentage of all customers matched under
any admissible policy by Theorems 1 and 3. The key observations are that
(i) the LP-based policies outperform the CD policy in all traffic intensities;
(ii) the LP-based policies are very close to the approximate upper bound based on The-
orem 1 as the arrival rates become large, which verifies Theorem 3 numerically.
Remark 8. The LP-based matching decisions contradict Corollary 1 of Hu and Zhou
(2016), which roughly states that a ridesharing company should always match a demand
with a supply if they are originated from the same geographic region. This is due to
differences in the model formulations. In particular, in Hu and Zhou (2016), matchings
between different types occur with either probability one or zero. In contrast, in our setting
whether or not a matching takes place (i.e., whether or not a customer accepts the offered
driver) is random.
!" # $
%"&'(
!) # *
%) # $
!+ # $
%+ # *
,-") # ,-)" # *.// ,-)+ # ,-+) # *./0!" #" $"
,-"+ # ,-+" # *
Figure 5 The parameters of the second simulation experiment are: Qi(0) = 0, Fii = 1, wij = 1 for all i, j ∈
1,2,3, n∈ 0.1,1,10,100, θi = θ is constant in i and θ ∈ 10−2,10−3,10−4,10−5, T = 1800, µ1(t) =
0 for all t∈ [0, T/2], and µ1(t) = 2n for all t∈ [T/2, T ].
Author: Dynamic Matching for Real-Time Ridesharing26Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
5.2.2. Time Dependent Parameters Motivated by the example in Figure 1 in the
Introduction, our next simulation experiment is designed to show that CLP-based policies
can significantly outperform LP-based policies and the CD-policy by taking into account
the future customer and driver arrival rates. Our assumption is that the customer arrival
rate in one area will spike; in particular, we assume µ1(t) = 0 for all t ∈ [0, T/2] and
µ1(t) = 2n for all t ∈ [T/2, T ], where the length of the time horizon is T = 1800, and
n∈ 0.1,1,10,100 denotes the traffic intensity of the system. Figure 5 provides the other
input parameters, which are time homogeneous, and so “(t)” is omitted.
Table 1 shows the percentage of all customers that are matched with drivers in the
simulation experiment (i.e., the objective (5), since wij = 1 for all i, j ∈ 1,2,3) under the
CD policy, the LP-based policies, and the CLP-based policies.
Table 1 The percentage of all customers matched in the simulation experiment corresponding to Figure 5.
LP-Based Policies CLP-Based Policiesθ n CD Rand. Determ. Hybrid Rand. Determ. Hybrid
10−2 0.1 63.8 57.9 67.1 67.5 62.5 68.1 67.91 66.1 69.1 72.6 72.9 72.3 73.9 74.110 66.1 72.9 73.9 74.1 75.2 75.5 75.5100 66.1 74.0 74.2 74.3 75.9 75.9 75.9
10−3 0.1 67.0 69.4 73.5 75.4 82.0 83.4 83.71 66.4 72.7 74.1 74.8 85.8 86.1 86.310 66.3 73.9 74.2 74.5 86.8 86.8 86.9100 66.2 74.2 74.2 74.4 86.9 86.9 86.9
10−4 0.1 68.0 70.3 73.7 77.0 92.1 92.8 93.51 66.7 73.0 74.2 75.2 96.0 96.0 96.110 66.3 74.0 74.2 74.7 96.8 96.8 96.8100 66.2 74.2 74.2 74.5 96.9 96.9 96.9
10−5 0.1 67.8 70.4 73.9 77.0 93.6 93.7 94.31 66.8 73.2 74.1 75.4 97.4 97.4 97.610 66.4 74.0 74.2 74.7 98.5 98.5 98.6100 66.2 74.2 74.3 74.5 98.8 98.7 98.8
Table 1 confirms that the CLP-based policies outperform the LP-based policies, and
the LP-based policies outperform the CD policy. Furthermore, both the CLP-based and
LP-based policies achieve the expected performance derived from the optimal solution of
the CLP (12) and the LP (14) as the market size n becomes large. Most intriguing, the
performance of the CLP-based policies improves as θ becomes small, whereas the perfor-
mance of the CD and LP-based policies is independent of θ. This is because the CLP-based
policies are forward-looking but the CD and LP-based policies are not. As a result, the
CLP-based policies are the only ones that require the drivers arriving in the first half of
the simulation to be willing to wait until sometime during the second half of the simu-
lation to be offered to a customer – and that “willingness-to-wait” is determined by the
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)27
parameter θ. This observation is exactly the reason Theorem 2 and Corollary 1 (related to
the asymptotic optimality of the potentially forward-looking CLP-based policies) require
θ = 0 but Theorems 3 and 4 (related to the asymptotic optimality of myopic LP-based
policies) do not.
The next three paragraphs explain the intuition for the percentages shown in Table 1.
The CD policy: In the first half of the simulation, i.e., in the time interval [0, T/2],
the CD policy offers type 1 drivers to type 2 customers and in total 0.99n(T/2) type 2
customers are matched. In the second half of the simulation, the CD policy offers type
1 drivers to both type 1 and type 2 customers. All of the type 1 customers who are
offered type 1 drivers will accept those drivers and 99% of the type 2 customers who are
offered type 1 drivers will accept those drivers. Then, the arrival rate of the customers
who will accept a match with type 1 drivers if offered is 2n+ 0.99n= 2.99n but the arrival
rate of type 1 drivers is only n. Thus, only 1/2.99 of the type 1 customers are offered
and matched with type 1 drivers and 1.99/2.99 of them are lost. Hence, nT/2.99 type 1
customers are matched in the second half of the simulation. Similarly, among the 99% of
the type 2 customers who accept type 1 drivers if offered, 1/2.99 of them will be offered
type 1 drivers. Hence, 0.99n(T/2)/2.99 type 2 customer are matched with type 1 drivers
and 0.98× 1.99n(T/2)/2.99 type 2 customers are matched with type 3 drivers, and the
remaining type 2 customers are lost in the second half of the simulation. Dividing the total
number of matchings by the total number of arriving customers (2nT ) leads to 66.1% of
all customers being matched, which agrees with Table 1 for larger n.
The LP-based policies: The optimal solution of the LP (14) is such that x∗12(t) = 1 for
all t ∈ [0, T/2] and x∗11(t) = 0.5 and x∗32(t) = 1 for all t ∈ [T/2, T ], and all other decision
variables at all other times are 0. In the first half of the simulation (t∈ [0, T/2]), x∗12(t) = 1
implies type 2 customers are offered type 1 drivers, resulting in 0.99n(T/2) matchings.
In the second half of the simulation (t ∈ [T/2, T ]), x∗11(t) = 0.5 dictates type 1 customers
and drivers being matched; however, the disparity between the arrival rates results in only
half the customers being matched, or n(T/2) matchings. Also, x∗32(t) = 1 results in type
2 customers matching with type 3 drivers, leading to 0.98n(T/2) matchings. Dividing the
total number of matchings by the total number of arriving customers (2nT ) leads to 74.3%
of all customers being matched, which agrees with Table 1 for larger n
Author: Dynamic Matching for Real-Time Ridesharing28Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
The CLP-based policies: An optimal matching process for the CLP (12) has: x32(t) = 1
for all t∈ [0, T ], x11(t) = 0 for all t∈ [0, T/2], x11(t) = 1 for all t∈ [T/2, T ], all other decision
variables are 0. (To see that process is optimal, note that as many drivers as possible
are matched.) This solution is forward-looking because the type 1 drivers arriving before
time T/2 are “saved” to be offered to the type 1 customers arriving after time T/2. Then,
2n(T/2) type 1 customers are matched in the second half of the simulation. Since x32(t) = 1
for the entire simulation, there are 0.98nT matchings for type 2 customers. Dividing the
total number of matchings by the total number of arriving customers (2nT ) leads to 99%
of all customers being matched, which, in contrast to the CD and LP-based policies does
not agree with Table 1 for all larger values of n.
The issue is that not all drivers arriving in the first half of the simulation will wait for
customers to arrive in the second half of the simulation. The number that wait depends on
the parameter θ. This is why we see 99% of all customers matched in Table 1 only when
both n is larger and θ is smaller.
6. Concluding Remarks
The decisions on which driver to offer to each arriving customer in a ridesharing system
impact the overall number of customers matched. This is because those decisions determine
whether or not future available drivers will be close to the locations of arriving customers.
We have formulated an optimization problem whose solution serves as an asymptotic upper
bound on the matching rates as the market becomes large. That optimization problem
accounts for (i) the differing arrival rates of drivers and customers in different areas of the
city, (ii) how long customers are willing to wait for driver pick-up, and (iii) the time-varying
nature of all the aforementioned parameters.
The aforementioned optimization problem is in general a CLP, which can be difficult to
solve. We establish that a simple randomized matching policy can asymptotically achieve
any matching process feasible for the CLP, so that there is potential to develop “good”
CLP-based matching policies, even when an optimal CLP solution is unknown. When
an optimal CLP solution is known, then a CLP-based randomized policy asymptotically
achieves the aforementioned optimization problem upper bound (assuming drivers are
“patient enough”).
Under the assumption that drivers are fully utilized, the CLP solution can be specified
through LP solutions. Then, an LP-based randomized policy asymptotically achieves the
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)29
aforementioned optimization problem upper bound. The fully utilized driver assumption
arises when the customer and driver arrival rates arise as the outcome of an underlying
network game in which a decrease in price in a given area causes less driver arrivals but
more customer arrivals. However, the resulting customer and driver arrival rates must
be independent of the matching policy. An excellent question for future research is to
understand how to jointly optimize over the incentive decisions (such as pricing) and the
matching decisions.
Many ridesharing companies have a car pooling option in which more than one customer
can share a single driver. In this case, a “matched” driver is still regarded as potentially
available. The issue, as studied in Gopalakrishnan et al. (2016), is that “adding” a customer
to an already matched driver causes inconvenience to the customer(s) that are already
passenger(s) (i.e., already riding with that driver). More research is required to fully under-
stand how to make matching decisions that both account for this inconvenience and ensure
the highest possible overall matching rates.
Acknowledgments
We would like to thank Siddhartha Banerjee for his valuable comments that helped us to write Section 4.1.
References
Adan, I., G. Weiss. 2012. Exact FCFS matching rates for two infinite multitype sequences. Operations
Research 60 475–489.
Akbarpour, M., S. Li, S. O. Gharan. 2016. Thickness and information in dynamic matching markets. Working
paper, http://ssrn.com/abstract=2394319.
Anderson, E. J., P. Nash, A. F. Perold. 1983. Some properties of a class of continuous linear programs.
SIAM Journal on Control and Optimization 21 758–765.
Arnosti, N., R. Johari, Y. Kanoria. 2016. Managing congestion in matching markets. Working paper,
http://ssrn.com/abstract=2427960.
Ata, B., S. Kumar. 2005. Heavy traffic analysis of open processing networks with complete resource pooling:
Asymptotic optimality of discrete review policies. The Annals of Applied Probability 15 331–391.
Azevedo, E. M., E. G. Weyl. 2016. Matching markets in the digital age. Science 352 1056–1057.
Bertsimas, D., E. Nasrabadi, I. C. Paschalidis. 2015. Robust fluid processing networks. IEEE Transactions
on Automatic Control 60 715–728.
Bimpikis, K., O. Candogan, D. Saban. 2017. Spatial pricing in ride-sharing networks. Working paper,
https://ssrn.com/abstract=2868080.
Author: Dynamic Matching for Real-Time Ridesharing30Article submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)
Braverman, A., J. G. Dai, X. Liu, L. Ying. 2017. Empty-car routing in ridesharing systems. Working paper,
arXiv:1609.07219v2.
Buke, B., H. Chen. 2015. Stabilizing policies for probabilistic matching systems. Queueing Systems 80
35–69.
Busic, A., V. Gupta, J. Mairesse. 2013. Stability of the bipartite matching model. Advances in Applied
Probability 45 351–378.
Cachon, G. P., K. M. Daniels, R. Lobel. 2016. The role of surge pricing on a service platform with self-
scheduling capacity. Working paper, http://ssrn.com/abstract=2698192.
Caldentey, R., E. H. Kaplan, G. Weiss. 2009. FCFS infinite bipartite matching of servers and customers.
Advances in Applied Probability 41 695–730.
Chen, K., M. Sheldon. 2016. Dynamic pricing in a labor market: Surge pricing and flexible work on
the Uber platform. Working paper, http://www.anderson.ucla.edu/faculty_pages/keith.chen/
papers.htm.
Chen, L., A. Mislove, C. Wilson. 2015. Peeking beneath the hood of Uber. Proceedings of the 2015 ACM
Conference on Internet Measurement Conference. New York, 495–508.
Folland, G. B. 1999. Real Analysis Modern Techniques and Their Applications. 2nd ed. Wiley.
Gopalakrishnan, R., K. Mukherjee, T. Tulabandhula. 2016. The costs and benefits of ridesharing: Sequential
individual rationality and sequential fairness. Working paper, arXiv:1607.07306v1.
Guda, H., U. Subramanian. 2017. Strategic surge pricing and forecast communication on on-demand service
platforms. Working paper, https://ssrn.com/abstract=2895227.
Gurvich, I., A. Ward. 2014. On the dynamic control of matching queues. Stochastic Systems 4 479–523.
Hall, J., C. Kendrick, C. Nosko. 2016. The effects of Uber’s surge pricing: A case study. Working paper,
http://faculty.chicagobooth.edu/chris.nosko/.
Harrison, J. M. 2000. Brownian models of open processing networks: Canonical representation of workload.
The Annals of Applied Probability 10 75–103.
Hu, M., Y. Zhou. 2016. Dynamic type matching. Working paper, http://ssrn.com/abstract=2592622.
Karatzas, I., S. E. Shreve. 1988. Brownian Motion and Stochastic Calculus. 1st ed. Springer-Verlag.
Leshno, J. D. 2016. Dynamic matching in overloaded waiting lists. Working paper, http://jleshno.
weebly.com/.
Michallon, C. 2016. ‘Shame on you’: Uber comes under fire as users complain of price
surge in the aftermath of Manhattan explosion - with rides costing up to three times
their usual prices. Dailymail.com http://www.dailymail.co.uk/news/article-3795474/
Uber-comes-fire-users-complain-price-surge-aftermath-Manhattan-explosion.html.
Author: Dynamic Matching for Real-Time RidesharingArticle submitted to Manufacturing & Service Operations Management; manuscript no. (Please, provide the manuscript number!)31
Moyal, P., O. Perry. 2016. On the instability of matching queues. Working paper, arXiv:1511.04282.
Perold, A. F. 1981. Extreme points and basic feasible solutions in continuous time linear programming.
SIAM Journal on Control and Optimization 19 52–63.
Plambeck, E. L., A. R. Ward. 2006. Optimal control of a high-volume assemble-to-order system. Mathematics
of Operations Research 31 453–477.
Reiman, M. I., Q. Wang. 2015. Asymptotically optimal inventory control for assemble-to-order systems with
identical lead times. Operations Research 63 716–732.
Riquelme, C., S. Banerjee, R. Johari. 2016. Pricing in ride-share platforms: A queueing-theoretic approach.
Working paper, http://ssrn.com/abstract=2568258.
Rochet, J. C., J. Tirole. 2006. Two-sided markets: a progress report. RAND Journal of Economics 37
645–667.
Shiryaev, A. N. 2008. Optimal Stopping Rules. Springer. Reprint of the 1978 edition.
Stroock, D. W., S. R. S. Varadhan. 2006. Multidimensional Diffusion Processes. Springer. Reprint of the
1997 edition.
Taylor, T. A. 2017. On-demand service platforms. Working paper, https://ssrn.com/abstract=2722308.
The Economist. 2016. A fare shake. http://www.economist.com/news/finance-and-economics/
21698656-jacking-up-prices-may-not-be-only-way-balance-supply-and-demand-taxis.
Unver, M. U. 2010. Dynamic kidney exchange. Review of Economic Studies 77 372–414.
Weiss, G. 2008. A simplex based algorithm to solve separated continuous linear programs. Mathematical
Programming 115 151–198.
White, D. 2016. Uber users are complaining about pricey New Year’s Eve rides. Time http://time.com/
4165410/uber-new-years-eve-price-surge-rides/.
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec1
ELECTRONIC COMPANION
In this electronic companion, we provide the proofs for results stated in the main body of the
manuscript titled “Dynamic Matching for Real-time Ridesharing”. Section EC.1 provides the proof
of Theorem 1, which provides an asymptotic upper bound on the fluid-scaled objective (6). That
proof relies on the fluid equations, and the details of their derivation are given in Section EC.2.
Section EC.3 provides a new regulator mapping result which is used in the proofs for asymptotic
optimality results in Section EC.4. The proofs of Lemmas 1, 2, 3, 4, and 5 are found in Section
EC.5. Finally, we present a relative compactness result in space D, which is used in the derivation
of fluid equations, in Section EC.6.
EC.1. Proof of Theorem 1
The proof of Theorem 1 relies on understanding the behavior of fluid limits. In particular, the proof
uses the fact that all fluid limits satisfy a set of equations that can be connected to the constraints
in the CLP (12). The implication is that any fluid limit gives a feasible matching process for the
CLP (12), which implies the optimal objective function value of the CLP (12) is an asymptotic
upper bound for the objective (6) under fluid scale.
For all i2N , j 2J , t2R+
, n2N+
, and admissible policy = n, n2N+
, let us define
G,nij (t) :=
Ej(nj (t))X
k=1
I
nj (k) = i
, (EC.1)
which is the cumulative number of times the system controller o↵ers a type i driver to a type j
customer up to time t and let G,nij :=G,n
ij /n be the fluid scaled process. Clearly, D,nij G,n
ij for
all i 2N , j 2 J , n 2N+
, and admissible policy by (4). For all n 2N+
and admissible policy ,
let X,n 2D2NJ+3N+J be defined such that
X,n :=
Ai ni , Ej n
j , Rni
Z ·
0
ni (s)Q,ni (s)ds
, Q,ni , D,n
ij , G,nij , 8i2N , j 2J
, (EC.2)
where “” denotes the composition map. Let X,n := X,n/n be the fluid scaled version of X,n.
Then, we define fluid limit(s) of X,n, n 2 N+
similar to the definition on page 299 of Dai and
Tezcan (2011) in the following way.
ec2 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Definition EC.1. (Fluid Limit) Let us fix an arbitrary admissible policy = n, n2N+
. Then,X is a fluid limit of X,n, n 2N
+
if there exists an ! 2 and a subsequence nk, k 2N+
such
that X,nk(·,!)! X u.o.c. as k!1.
Proposition EC.1. (Fluid Equations) For any admissible policy = n, n 2 N+
, there exists
a full set A (i.e., P(A) = 1) such that for any ! 2 A, X,n(·,!), n 2 N+
is relatively
compact (i.e., every subsequence has a convergent subsequence) in the Skorokhod space D2NJ+3N+J
endowed with the u.o.c. topology. Thus, fluid limits exist in almost all sample paths and any fluid
limit
X =
i, j,
Z ·
0
i(s)Qi (s)ds, Q
i , D
ij, G
ij, 8i2N , j 2J
and satisfies the following equations for all t2R+
:
Qi (t) =i(t)
Z t
0
i(s)Qi (s)ds
X
j2JD
ij(t) 0, 8i2N , (EC.3a)
Dij(0) = G
ij(0) = 0, 8i2N , j 2J , (EC.3b)
Dij and G
ij are nondecreasing and absolutely continuous for all i2N and j 2J , (EC.3c)
X
j2JD
ij(t)i(t), 8i2N , (EC.3d)
X
i2N
Gij(t2) G
ij(t1) j(t2)j(t1), 8j 2J and t
1
, t2
2R+
such that t2
t1
, (EC.3e)
Dij(t) D
ij(m) Fij(m)
Gij(t) G
ij(m)
I (t2 [m, m+1
)) = 0,
for all m2N, i2N , and j 2J . (EC.3f)
The proof of Proposition EC.1 is presented in Section EC.2. Let us fix an arbitrary admissible
policy and an arbitrary ! 2A. Then there exists a subsequence nk, k 2N+
such that
limsupn!1
X
i2N ,j2JwijD
,nij (T,!) = lim
k!1
X
i2N ,j2JwijD
,nkij (T,!).
Since D,nij (·,!) is relatively compact (cf. Proposition EC.1) for all i 2N and j 2 J , there exists
a subsequence of nk, k 2 N+
denoted by nl, l 2 N+
such that D,nlij (·,!) converges to a limit
Dij(·) u.o.c. as l!1 for all i2N and j 2J . Hence,
limsupn!1
X
i2N ,j2JwijD
,nij (T,!) = lim
k!1
X
i2N ,j2JwijD
,nkij (T,!),
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec3
= liml!1
X
i2N ,j2JwijD
,nlij (T,!) =
X
i2N ,j2JwijD
ij(T ).
Then, Theorem 1 follows by the following result.
Proposition EC.2. Let = n, n2N+
denote an arbitrary admissible policy. Under any fluid
limit of X,n, n2N+
, we have
X
i2N ,j2JwijD
ij(T )
X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds.
Next, we will prove Proposition EC.2. Let us consider the following CLP which has the decision
variables zij : [0, T ]!R+
for all i2N and j 2J that replace µj(t)Fij(t)xij(t) in the CLP (12):
maxX
i2N ,j2Jwij
Z T
0
zij(s)ds, (EC.4a)
subject to:X
j2J
Z t
0
zij(s)dsi(t), for all i2N and t2 [0, T ], (EC.4b)
X
i2N :
¯Fij(t)>0
zij(t)
Fij(t) µj(t), for all j 2J and t2 [0, T ], (EC.4c)
zij(t)I
Fij(t) = 0
= 0, for all i2N , j 2J , and t2 [0, T ], (EC.4d)
zij(t)I (µj(t) = 0) = 0, for all i2N , j 2J , and t2 [0, T ], (EC.4e)
zij(t) 0, for all i2N , j 2J , and t2 [0, T ], (EC.4f)
zij is Lebesgue measurable for all i2N and j 2J . (EC.4g)
By an argument very similar to Lemma 2, there exists an optimal solution of the CLP (EC.4)
which is denoted by zij(t), i 2 N , j 2 J , t 2 [0, T ]. We consider the CLP (EC.4) instead of the
CLP (12) because of three main reasons. First, the feasible region of the CLP (EC.4) is smaller
than the one of the CLP (12) in the sense that there exist a surjective but not bijective mapping
from the feasible region of the CLP (12) to the one of the CLP (EC.4). Second, it is easier to create
connection between a fluid limit of D,nij , i 2N , j 2 J , n 2 N
+
and the decision variables of the
CLP (EC.4) than between the same fluid limit and the decision variables of the CLP (12). Third,
we have the following result.
ec4 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Lemma EC.1. The optimal objective function values of the CLP (12) and the CLP (EC.4) are
equal.
Proof: First, consider the deterministic process µj(t)Fij(t)xij(t), i 2 N , j 2 J , t 2 [0, T ]
(remember that xij(t), i 2N , j 2 J , t 2 [0, T ] is an optimal solution of the CLP (12)). It is easy
to see that this process is feasible for the CLP (EC.4). Thus,
X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)dsX
i2N ,j2Jwij
Z T
0
zij(s)ds. (EC.5)
Second, for all i2N , j 2J , and t2 [0, T ], let
yij(t) :=
8
>
>
>
<
>
>
>
:
zij(t)
µj(t) ¯Fij(t), if Fij(t)> 0 and µj(t)> 0,
0, otherwise.
(EC.6)
Then, it is easy to see that the process yij(t), i2N , j 2J , t2 [0, T ] is feasible for the CLP (12),
thus
X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)yij(s)ds=X
i2N ,j2Jwij
Z T
0
zij(s)I
Fij(s)> 0, µj(s)> 0
ds (EC.7a)
=X
i2N ,j2Jwij
Z T
0
zij(s)dsX
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds, (EC.7b)
where the equality in (EC.7b) is by (EC.4d) and (EC.4e). Hence, the optimal objective function
values of the CLP (12) and the CLP (EC.4) are equal to each other by (EC.5) and (EC.7b).
Let us consider an arbitrary fluid limit of an arbitrary admissible policy . By (EC.3c) and
Theorem 3.35 of Folland (1999), both Dij and G
ij are di↵erentiable almost everywhere on [0, T ] for
all i 2N and j 2 J . Let dij and gij be the (nonnegative) derivatives of Dij and G
ij, respectively,
on the points where they are di↵erentiable and without loss of generality be equal to 0 on the
points where they are not di↵erentiable for all i2N and j 2J on the interval [0, T ]. By (EC.3b),
(EC.3c), and the fundamental theorem of calculus for Lebesgue integrals (cf. Theorem 3.35 of
Folland (1999)), for all i2N , j 2J , and t2 [0, T ],
Dij(t) =
Z t
0
dij(s)ds, Gij(t) =
Z t
0
gij(s)ds. (EC.8)
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec5
Then, dij(t), i2N , j 2J , t2 [0, T ] satisfies (EC.4b) by (EC.3d) and (EC.8); (EC.4f) and (EC.4g)
by (EC.3c), Theorem 3.35 of Folland (1999), and construction.
Next, fix an arbitrary customer type j 2J and t2 [0, T ], and let t2 [m, m+1
) for some m2N.
By choosing t2
= t, t1
= 0, and taking the derivatives of the both sides in (EC.3e), we have
X
i2Ngij(t) µj(t). (EC.9)
By (EC.3f) and (EC.8), for all i2N ,
dij(t) =
8
>
>
>
<
>
>
>
:
Fij(m)gij(t), if Fij(t)> 0,
0, otherwise,
(EC.10)
where the equality in (EC.10) holds for all t 2 [0, T ] except on a set of zero measure and we
modify dij such that dij(t) = 0 in that set of zero measure. Then by (EC.9) and (EC.10) and the
nonnegativity of gij for all i2N ,
X
i2N :
¯Fij(t)>0
dij(t)
Fij(t) µj(t),
so that dij(t), i2N , j 2J , t2 [0, T ] satisfies (EC.4c). Moreover, it satisfies (EC.4d) by (EC.10).
Lastly, by (EC.9), we have
gij(t)I (µj(t) = 0) = 0, 8i2N . (EC.11)
Thus, if Fij(t)> 0 for some i2N , then dij(t)I (µj(t) = 0) = 0 by (EC.10) and (EC.11). Otherwise,
dij(t) = 0 by (EC.10). Hence, dij(t), i2N , j 2J , t2 [0, T ] satisfies (EC.4e) as well, so it is feasible
for the CLP (EC.4). Then,
X
i2N ,j2Jwij
Z T
0
zij(s)dsX
i2N ,j2Jwij
Z T
0
dij(s)ds=X
i2N ,j2JwijD
ij(T ), (EC.12)
where the equality in (EC.12) is by (EC.8). Therefore, (EC.12) together with Lemma EC.1 proves
Proposition EC.2.
ec6 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
EC.2. Proof of Proposition EC.1 (Properties of Fluid Limits)
Let us fix an arbitrary T1
2 R+
. For all k 2 N+
, let Dk[0, T1
] denote the the space of functions
with domain [0, T1
] and range Rk which are right continuous with left limits. We will first prove
Proposition EC.1 except the property (EC.3f) with respect to processes defined in D2NJ+3N+J [0, T1
],
then we will extend these results to the processes in D2NJ+3N+J . Lastly, we will prove (EC.3f). By
the functional strong law of large numbers, random time-change theorem (cf. Theorems 5.10 and
5.3 of Chen and Yao (2001), respectively), and Assumption 2,
Ani n
ia.s.!i, u.o.c., Rn
ia.s.! e, u.o.c., En
j nj
a.s.! j, u.o.c. as n!1, (EC.13)
for all i2N and j 2J . Let
A1
:=n
! 2 : Qni (0,!)! 0, An
i ni (·,!)!i u.o.c., Rn
i (·,!)! e u.o.c.,
Enj n
j (·,!)! j u.o.c. as n!1 for all i2N and j 2Jo
. (EC.14)
Then, A1
is a full set (i.e., P (A1
) = 1) by (EC.13) and Assumption 3. Let us fix an arbitrary
! 2A1
and an arbitrary admissible policy = n, n 2N+
. We omit and ! from the notation
up to Lemma EC.2 below for notational convenience.
Clearly, for all i2N and j 2J , Ani n
i , n2N+
and Enj n
j , n2N+
are relatively compact
in the u.o.c. topology by (EC.14). Moreover, i and j are Lipschitz continuous by Assumption 1;
and for all i2N , j 2J , and t1
, t2
2R+
such that t2
t1
, we have
X
i2N
Gnij(t2) Gn
ij(t1) En
j nj (t2) En
j nj (t1), (EC.15)
Dnij(t2) Dn
ij(t1) Gnij(t2) Gn
ij(t1), (EC.16)
where (EC.15) is by the fact that the system controller can o↵er a driver to a customer only at the
customer arrival epochs, and (EC.16) is by (4) and (EC.1). Then by Lemma EC.14 (cf. Section
EC.6), Gnij, n 2N
+
and Dnij, n 2N
+
are relatively compact in D[0, T1
] endowed with the u.o.c.
topology for all i 2N and j 2 J such that all of their subsequential limits are Lipschitz and so
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec7
absolutely continuous. Since Gnij and Dn
ij are nondecreasing and Gnij(0) = Dn
ij(0) = 0 for all i 2N ,
j 2J , n 2N+
, any fluid limits of these processes satisfy (EC.3b) and (EC.3c). Moreover, (EC.3e)
follows by (EC.14) and (EC.15).
By Assumption 1, we define i := supt2R+i(t) <1 and µj := supt2R+
µj(t) <1 for all i 2N
and j 2 J . Moreover, there exists a constant 2 R+
and n0
2 N+
such that if n n0
, ni (t)
for all t 2 R+
and i 2N by Assumptions 1 and 2. Let us fix an arbitrary i 2N and consider the
processR ·0
ni (s)Qni (s)ds. By (EC.14), An
i ni (T1
)!i(T1
) iT1
<1 and Qni (0)! 0 as n!1.
Hence, there exists an n1
2N+
and a constant C <1 such that if n n1
, Qni (0)+ An
i ni (T1
)C.
Then
Z t2
0
ni (s)Qni (s)ds
Z t1
0
ni (s)Qni (s)ds=
Z t2
t1
ni (s)Qni (s)ds
Z t2
t1
Qni (s)ds (EC.17a)
Z t2
t1
Qni (0)+ An
i ni (s)
ds
Qni (0)+ An
i ni (T1
)
(t2
t1
) C(t2
t1
) (EC.17b)
for all n n0
_ n1
and t1
, t2
2 [0, T1
] such that t2
t1
, and the first inequality in (EC.17b) is by
(11). Then,R ·
0
ni (s)Qni (s)ds,n 2N
+
is relatively compact in the u.o.c. topology with Lipschitz
continuous subsequential limits by Lemma EC.14 (cf. Section EC.6). By the fact that Rni ! e u.o.c.
(cf. (EC.14)) and Lemma 11 of Ata and Kumar (2005),
Rni
R ·0
ni (s)Qni (s)ds
, n2N+
is relatively
compact in the u.o.c. topology and all of its limits are Lipschitz continuous. Hence, Qni , n 2N
+
is also relatively compact in the u.o.c. topology with Lipschitz continuous and nonnegative limits
by (11) and (EC.14).
Let us fix an arbitrary subsequence nl, l 2N+
such thatR ·
0
ni (s)Qnli (s)ds, l 2N
+
converges
to a (continuous) limit under the uniform norm. Then, there exists a subsequence of nl, l 2N+
,
denoted by nk, k 2N+
, such that
Qnki Qi
T1! 0 as k!1 for all i 2N , where Qi 2D[0, T
1
]
is nonnegative and continuous for all i2N . Then,
supt2[0,T1]
Z t
0
nki (s)Qnk
i (s)dsZ t
0
i(s)Qi(s)ds
supt2[0,T1]
Z t
0
nki (s)Qnk
i (s)dsZ t
0
i(s)Qnki (s)ds
+ supt2[0,T1]
Z t
0
i(s)Qnki (s)ds
Z t
0
i(s)Qi(s)ds
T1
Qnki
T1knk
i ikT1+T
1
Qnki Qi
T1! 0, as k!1,
ec8 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
by Assumption 2. Therefore, each convergent subsequence ofR ·
0
ni (s)Qni (s)ds,n2N
+
converges
toR ·0
i(s)Qi(s)ds u.o.c. where Qi is a fluid limit of Qni , n2N
+
for all i2N . Then, by Lemma 11 of
Ata and Kumar (2005), each convergent subsequence of
Rni
R ·0
ni (s)Qni (s)ds
, n2N+
converges
toR ·0
i(s)Qi(s)ds u.o.c. where Qi is a fluid limit of Qni , n2N
+
for all i2N . This proves (EC.3a).
Next, (EC.3d) follows by (EC.3a) and the fact that Qi is nonnegative for all i2N .
By Theorems 16.2 and 16.4 of Billingsley (1999) and the fact that T1
2R+
is arbitrarily chosen,
we can extend the results above to the processes in D2NJ+3N+J , which proves Proposition EC.1
except (EC.3f). Lastly, in order to prove (EC.3f), it is enough to prove the following result. From
this point forward, we keep and ! in the notation.
Lemma EC.2. For all i2N , j 2J , m2N, and admissible policy = n, n2N+
,
supt2[m,m+1)
D,nij (t) D,n
ij (m) Fij(m)
G,nij (t) G,n
ij (m)
a.s.! 0, as n!1. (EC.18)
Proof: Let us fix arbitrary i 2 N , j 2 J , m 2 N, and an admissible policy = n, n 2 N+
.
Then the converging number in (EC.18) is equal to
supt2[m,m+1)
1
n
Ejnj (t)
X
k=Ejnj (m)+1
I
akj (m) tij(m)
Fij(m)
I
nj (k) = i
, (EC.19)
by (4), (EC.1), and (10b). For notational completeness, for any n,m 2 N and sequence of real
numbers xk, k 2N, if n>m, thenPm
k=n xk := 0. Let
Yk := I
akj (m) tij(m)
Fij(m), Znk := I
nj (k) = i
, Xnk := Yk Zn
k .
Then, (EC.19) is equal to
supt2[m,m+1)
1
n
Ejnj (t)
X
k=Ejnj (m)+1
Xnk
. (EC.20)
By the definition of the admissible policies (cf. Definition 1), nj (k) is Fn
j (k)-measurable for all
k,n2N+
, so does Znk . Moreover, ak
j (m) is independent of Fnj (k) by construction (cf. (8)), so does
Yk. Then, E
Xnk |Fn
j (k)
= 0 for all k,n 2 N+
because E [Yk] = 0. Therefore, we expect to have a
Martingale strong law of large numbers result for triangular arrays:
1
n
Ejnj (m)+nX
k=Ejnj (m)+1
Xnk
a.s.! 0, as n!1. (EC.21)
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec9
We present the formal proof of (EC.21) done by the technique introduced by de Jong (1996) in
Section EC.2.1.
Let us first choose an arbitrary > 0 and then choose arbitrary 1
> 0 and 2
> 0 such that
1
(2
+ µjm+1
)< . Let the set of ! 2 which satisfy (EC.21) be denoted by A2
. Then P(A2
) = 1.
Let us choose an arbitrary ! 2 A1
\A2
, where A1
is defined in (EC.14). Then, there exists an
n2
(2
,!) 2N such that |Enj n
j (m+1
,!)j(m+1
)|< 2
for all n n2
(2
,!) by (EC.14). By the
definition of j, (10a), (10b), and Assumption 1,
Enj n
j (m+1
,!)/n< 2
+ µjm+1
, 8n n2
(2
,!). (EC.22)
By (EC.21), there exists an n1
(1
,!)2N such that
1
n
Ejnj (m,!)+nX
k=Ejnj (m,!)+1
Xnk (!)
< 1
, 8n n1
(1
,!). (EC.23)
Let us fix an arbitrary t2 [m, m+1
). On the one hand, if Ej nj (t,!)Ej n
j (m,!) n1
(1
,!),
then
1
n
Ejnj (t,!)
X
k=Ejnj (m,!)+1
Xnk (!)
< 1
Ej nj (t,!)Ej n
j (m,!)
n
1
Ej nj (m+1
,!)
n, (EC.24)
by (EC.23). On the other hand, if Ej nj (t,!)Ej n
j (m,!)<n1
(1
,!), then
1
n
Ejnj (t,!)
X
k=Ejnj (m,!)+1
Xnk (!)
1
n
Ej nj (t,!)Ej n
j (m,!)
<n1
(1
,!)
n. (EC.25)
Hence, for all t2 [m, m+1
), if n n2
(2
,!),
1
n
Ejnj (t,!)
X
k=Ejnj (m,!)+1
Xnk (!)
< (1
(2
+ µjm+1
))_ n1
(1
,!)
n< _ n
1
(1
,!)
n, (EC.26)
by (EC.22), (EC.24), (EC.25), and the fact that 1
(2
+ µjm+1
)< . Let
n0
(,!) :=maxn2
(2
,!), n1
(1
,!)/. (EC.27)
Then, for all > 0, there exists an n0
(,!) such that if n n0
(,!),
supt2[m,m+1)
1
n
Ejnj (t,!)
X
k=Ejnj (m,!)+1
Xnk (!)
< , (EC.28)
by (EC.26) and (EC.27). Since (EC.28) is true for all ! 2A1
\A2
, the proof is complete.
We complete the proof of Proposition EC.1 by defining the full set A :=A1
\A2
.
ec10 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
EC.2.1. Proof of (EC.21)
Since the indices in the sum in (EC.21) are random, we first prove that YEjnj (m)+k ?Zn
Ejnj (m)+k
and E[XnEjn
j (m)+k] =E[YEjnj (m)+k] = 0 for all n2N
+
and k 2N+
, so that we can use a Martin-
gale strong law of large numbers result for triangular arrays in order to prove (EC.21).
For notational convenience, we omit the superscript from the notation. Remember that we
fix arbitrary i 2N , j 2J , m2N in Lemma EC.2. Let Knk :=Kn
Ejnj (m)+k for all K 2 X,Z and
k 2N+
, and Yk := YEjnj (m)+k for all k 2N
+
. Then proving (EC.21) is equivalent to proving
1
n
nX
k=1
Xnk
a.s.! 0, as n!1. (EC.29)
Let Fnj (k) := Fn
j (Ej nj (m) + k) for all k 2 N
+
(cf. (8)) and Fnj (k) := ;, for all k 2 Z\N
+
,
where Z denotes the set of integers. Since nj (Ej nj (m) + k) is a stopping time with respect to
the filtration Fn for all k 2N+
and is increasing in k, Fnj (k) is well defined and
Fnj (k), k 2 Z
is
a filtration.
Let Snk :R+
!RN be defined such that
Snk(t,!) :=
Ai ni (t^ nj (k,!),!),Ej0 n
j0(t^ nj (k,!),!),Qni ((t^ nj (k,!)),!),
Ri
Z
(t^nj (k,!))
0
ni (u)Qni (u,!)du, !
!
, Dnij0((t^ nj (k,!)),!), 8i2N , j0 2J ,
ar^Ej0n
j0 (nj (k,!),!)
j0 (m,!), ar^(k1)
j (m,!), 8r,m2N!
, (EC.30)
for all k,n2N+
and ! 2. By (8),
Fnj (k) = Sn
k(t), t2R+
. (EC.31)
Then we have the following result.
Lemma EC.3. Fix arbitrary k,n2N+
and j 2J . Let g be an arbitrary Fnj (k)-measurable function.
Then, there exist a B(RN)-measurable function f and a sequence of nonnegative real numbers tl, l 2
N such that g(!) = f(Snk(tl,!), l 2N) for all ! 2.
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec11
Proof: The proof follows by the fact that RN is a Polish space (cf. Corollary 3.39 of Aliprantis
and Border (2006)) and Exercise 1.5.6 of Stroock and Varadhan (2006).
Lemma EC.4. We have nj
Ej nj (m)+k
2 Fnj (k) and a
Ejnj (m)+k
j (m)2 Fnj (k+ l) for all j 2J ,
k, l, n2N+
, and m2N.
Proof: We have aEjn
j (m)+k
j (m) 2 Fnj (k + l) by definition of Fn
j (k + l) (cf. (8)). Let us fix
arbitrary j 2J , k,n2N+
, and m2N. For notational convenience, let E :=Ej nj (m). Then
nj
Ej nj (m)+ k
=1X
r=0
nj
r+ k
I
E = r
=1X
r=0
fr
Snr+k(t
rl ), l 2N
I
E = r
(EC.32)
=1X
r=0
fr
Sn˜E+k(t
rl ), l 2N
I
E = r
(EC.33)
where the second equality in (EC.32) is by Lemma EC.3. First, I
E = r 2 Fn
j (k) for all r 2 N
by definition of Fnj (k). Second, let y : ! RN be such that y(!) :=
Sn˜E(!)+k
(trl ,!), l 2 N
. Since
B(RN) = B(R)B(R) . . . (cf. Lemma 1.2 of Kallenberg (1997)), B(RN) is generated by the sets
of type B :=
Q
l2NBl : Bl 2 B(R) (cf. Proposition 1.3 of Folland (1999)). Then, since Fnj (k) =
n
Sn˜E+k
(t), t2R+
o
(cf. (EC.31)), we have
! 2 : y(!)2B=n
! 2 : Sn˜E(!)+k(t
rl ,!)2Bl, l 2N
o
=\
l2N
n
! 2 : Sn˜E(!)+k(t
rl ,!)2Bl
o
2 Fnj (k).
Since fr 2B(RN) by definition, the mapping in (EC.33) is Fnj (k)-mesurable.
Then, we have the following result.
Lemma EC.5. We have aEjn
j (m)+k
j (m)? Fnj (k) for all j 2J , k,n2N
+
, and m2N.
Proof: For notational convenience, again let E :=Ej nj (m). Let us fix arbitrary j 2J , k,n2
N+
, m2N, and c2R and an arbitrary set B 2 Fnj (k). Then
P
a˜E+kj (m)< c, B
=1X
r=0
P
ar+kj (m)< c, B, E = r
=1X
r=0
Eh
I
ar+kj (m)< c
I(B)I
E = ri
ec12 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
=1X
r=0
Eh
I
ar+kj (m)< c
f
Sn˜E+k(tl), l 2N
I
E = ri
(EC.34)
=1X
r=0
Eh
I
ar+kj (m)< c
f
Snr+k(tl), l 2N
I
E = ri
=1X
r=0
P
ar+kj (m)< c
Eh
f
Snr+k(tl), l 2N
I
E = ri
(EC.35)
=P
a1
j(m)< c
1X
r=0
Eh
f
Snr+k(tl), l 2N
I
E = ri
(EC.36)
=P
a1
j(m)< c
1X
r=0
P
B, E = r
=P
a1
j(m)< c
P (B)
=1X
r=0
P
a1
j(m)< c
P
E = r
P (B) =1X
r=0
P
ar+kj (m)< c
P
E = r
P (B)
=1X
r=0
P
ar+kj (m)< c, E = r
P (B) =1X
r=0
P
a˜E+kj (m)< c, E = r
P (B) (EC.37)
=P
a˜E+kj (m)< c
P (B) , (EC.38)
where (EC.34) is by Lemma EC.3. (EC.35) is by (EC.31) and the fact that ar+kj (m)? Fn
j (r+ k)
(cf. (8)), I
E = r2Fn
j (r+k) for all r 2N, and f
Snr+k(tl), l 2N
2Fnj (r+k) (see proof of Lemma
EC.4 for a similar argument explained in detail). (EC.36) is by the i.i.d. property of the sequence
arj(m), r 2 N, and the first equality in (EC.37) is by the fact that ar+k
j (m) ? Fnj (r + k) and
I
E = r 2 Fn
j (r+ k) for all r 2N. By definition of independence (cf. page 41 of Durrett (2010)),
the equality in (EC.38) proves the desired result.
Remark EC.1. If the filtration defined in (7) is generated by the sequence of processes m,m2
N defined in Remark 3, we can still prove Lemmas EC.4 and EC.5 by updating the definition in
(EC.30) such that the infinite dimensional process Snk includes the sequence m,m2N.
Now we are ready to prove (EC.21) by the technique introduced by de Jong (1996). For any
x2R, let bxc denote the greatest integer which is smaller than or equal to x. Then,
1
n
nX
k=1
Xnk =
1
n
nX
k=1
Xnk E
h
Xnk
Fnj (k+ bn0.25c 1)
i
+1
n
nX
k=1
Eh
Xnk
Fnj (kbn0.25c)
i
+1
n
nX
k=1
Eh
Xnk
Fnj (k+ bn0.25c 1)
i
Eh
Xnk
Fnj (kbn0.25c)
i
=:An1
+An2
+An3
. (EC.39)
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec13
We will consider each of An1
, An2
, and An3
separately. Let us choose an arbitrary > 0. First, let
us consider
1X
n=1
P (|An1
|> ) =1X
n=1
P
nX
k=1
Xnk E
h
Xnk
Fnj (k+ bn0.25c 1)
i
>n
!
. (EC.40)
Note that Znk is Fn
j (k)-measurable by Lemma EC.4 and Yk ? Fnj (k) by Lemma EC.5. Moreover,
Eh
Yk
i
=Eh
I
aEjn
j (m)+k
j (m) tij(m)
Fij(m)i
=E
" 1X
r=0
I
ar+kj (m) tij(m)
I
Ej nj (m) = r
#
Fij(m)
=1X
r=0
E
I
ar+kj (m) tij(m)
I
Ej nj (m) = r
Fij(m)
=1X
r=0
E
I
ar+kj (m) tij(m)
E
I
Ej nj (m) = r
Fij(m) (EC.41)
=1X
r=0
Fij(m)E
I
Ej nj (m) = r
Fij(m) (EC.42)
= Fij(m)
1X
r=0
E
I
Ej nj (m) = r
1
!
= 0, (EC.43)
where (EC.41) is by the fact that ar+kj (m)?Fn
j (r+k) (cf. (8)) and I
Ej nj (m) = r
2Fnj (r+k)
for all k 2N+
and r 2N, and (EC.42) is by definition of Fij(m) (cf. (2)). Hence, on the one hand,
Eh
Xnk
Fnj (k)
i
=Eh
YkZnk
Fnj (k)
i
= ZnkEh
Yk
i
= 0, for all k,n2N+
, (EC.44a)
Eh
Xnk
Fnj (k l)
i
=Eh
Eh
Xnk
Fnj (k)
i
Fnj (k l)
i
= 0, for all k, l, n2N+
, (EC.44b)
by (EC.43). On the other hand, Xnk is Fn
j (k+ l)-measurable for all k 2N+
and l 2N+
by Lemma
EC.4. Hence, for all k,n2N+
,
Eh
Xnk
Fnj (k+ bn0.25c 1)
i
=
8
>
>
>
<
>
>
>
:
0, if n< 16,
Xnk , n 16.
(EC.45)
Since
Xnk
1 for all k 2 N+
and n 2 N+
, the sum in the the right-hand side in (EC.40) is less
than or equal to 15<1 by (EC.45).
ec14 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Second, by (EC.44), we have
1X
n=1
P (|An2
|> ) =1X
n=1
P
nX
k=1
Eh
Xnk
Fnj (kbn0.25c)
i
>n
!
= 0. (EC.46)
Third,
1X
n=1
P (|An3
|> ) =1X
n=1
P
nX
k=1
Eh
Xnk
Fnj (k+ bn0.25c 1)
i
Eh
Xnk
Fnj (kbn0.25c)
i
>n
!
=1X
n=1
P
0
@
nX
k=1
bn0.25c1
X
l=bn0.25c+1
Eh
Xnk
Fnj (k+ l)
i
Eh
Xnk
Fnj (k+ l 1)
i
>n
1
A
1X
n=1
P
0
@
bn0.25c1
X
l=bn0.25c+1
nX
k=1
Eh
Xnk
Fnj (k+ l)
i
Eh
Xnk
Fnj (k+ l 1)
i
>n
1
A
1X
n=1
bn0.25c1
X
l=bn0.25c+1
P
nX
k=1
Eh
Xnk
Fnj (k+ l)
i
Eh
Xnk
Fnj (k+ l 1)
i
>n
2bn0.25c
!
. (EC.47)
For all r 2N+
, let
Mnl (r) :=
rX
k=1
Eh
Xnk
Fnj (k+ l)
i
Eh
Xnk
Fnj (k+ l 1)
i
.
First, E
Mnl (r)
2r <1 and Mnl (r) 2 Fn
j (l+ r) (even when l+ r 0 in which Mnl (r) = 0 by
definition) for all r 2N+
. Second,
Eh
Mnl (r+1)
Fnj (l+ r)
i
=Eh
Eh
Xnr+1
Fnj (l+ r+1)
i
Eh
Xnr+1
Fnj (l+ r)
i
+Mnl (r)
Fnj (l+ r)
i
= 0+Mnl (r).
Therefore, for all fixed n2N+
and l 2Z, Mnl (r), Fn
j (l+ r), r 2N+
is a martingale sequence such
that E[Mnl (r)] = 0. Moreover,
Mnl (r)Mn
l (r1)
2 for all r 2N+
, i.e., the martingale di↵erences
are bounded by 2. Then, the sum in (EC.47) is equal to
1X
n=1
bn0.25c1
X
l=bn0.25c+1
P
|Mnl (n)|>
n
2bn0.25c
1X
n=1
bn0.25c1
X
l=bn0.25c+1
2exp
0
@2
n
2bn0.25c
2
nX
k=1
42!1
1
A
=1X
n=1
2
2bn0.25c 1
exp
n2
32bnc0.5
<1, (EC.48)
where the inequality is by Azuma’s inequality (cf. Theorem 6.3.3 of Ross (1996)).
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec15
Finally, (EC.29) follows by the fact that
P
limsup
1
n
nX
k=1
Xnk
>
!
=P (limsup |An1
+An2
+An3
|> ) = 0,
where the second equality is by the fact that the sum in (EC.40) is finite, (EC.46), (EC.48), and
Borel-Cantelli Lemma (cf. Theorem 2.3.1 of Durrett (2010)).
EC.3. A Regulator Mapping Result
We need regulator mapping results in order to prove Theorems 2, 3, and 4 in Section EC.4. Since
the generalized one-sided regulator mappings defined in the literature (cf. Reed and Ward (2004,
2008) and Ward and Kumar (2008)) are not applicable to our case, we introduce a new one-sided
and nonlinear regulator mapping in this section. Let , : D! D be such that for all x 2 D and
t2R+
,
(x)(t) := sup0st
(x(s))+, (x)(t) := x(t)+ (x)(t). (EC.49)
Then, is the conventional one-sided and one-dimensional regulator mapping (cf. Chapter 13.5 of
Whitt (2002)). We define the following regulator mapping.
Definition EC.2. (A time-dependent, one-sided, and nonlinear regulator mapping): Let x, y 2
D be such that x(0) 0 and supt2R+|y(t)| < 1. The time-dependent, one-sided, and nonlinear
regulator mapping (M, M) :D2 !D2 is defined by (M, M) (x, y) = (z, `) where
CONDITION 1 (C1). z(t) = x(t) R t
0
y(s)z(s)ds+ `(t) 0 for all t2R+
.
CONDITION 2 (C2). `(0) = 0, ` is nondecreasing, andR10
z(t)d`(t) = 0.
If y= 0 in Definition EC.2, then the time-dependent, one-sided, and nonlinear regulator mapping
becomes the conventional one-sided and one-dimensional regulator mapping defined in (EC.49) (cf.
Theorem 6.1 of Chen and Yao (2001)); if y 2D is a constant function, then it becomes the linearly
generalized one-sided mapping described in Ward and Kumar (2008).
In order to write the time-dependent, one-sided, and nonlinear regulator mapping in terms of
the conventional one-sided and one-dimensional regulator mapping defined in (EC.49), we make
the following definition.
ec16 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Definition EC.3. (Integral equation): Let x, y 2D be such that supt2R+|y(t)|<1. Let M :D2 !
D is a mapping such that u :=M(x, y) solves the integral equation
u(t) = x(t)Z t
0
y(s)(u)(s)ds, 8t2R+
. (EC.50)
A mapping g :D!D is Lipschitz continuous with respect to the uniform norm, if for all T1
2R+
,
there exists a constant 2R+
which may depend on T1
such that kg(x) g(y)kT1 kx ykT1 for
all x, y 2D. Then, the first main result of this section is the following.
Proposition EC.3. For any given x, y 2D such that x(0) 0 and supt2R+|y(t)|<1, there exists
a unique pair of functions (M, M) (x, y) which satisfies conditions C1 and C2 in Definition EC.2.
Moreover,
1. M(x, y) = (M(x, y)) and M(x, y) = (M(x, y)),
2. both M(·, y) :D!D and M(·, y) :D!D are Lipschitz continuous with respect to the uniform
norm.
In order to prove Proposition EC.3, we need the following result.
Lemma EC.6. For any given x, y 2 D such that supt2R+|y(t)| < 1, there exists a unique u 2 D
which solves the integral equation (EC.50). Moreover, the mapping M(·, y) : D ! D is Lipschitz
continuous with respect to the uniform norm.
Proof: Fix an arbitrary pair x, y 2D such that y := supt2R+|y(t)|<1. Let y :D!D be such
that for all u2D and t2R+
, y(u)(t) := y(t)(u)(t). Then for all u1
, u2
2D and t2R+
,
ky(u1
) y(u2
)kt y k(u1
)(u2
)kt 2y ku1
u2
kt ,
where the last inequality is by the fact that the mapping is Lipschitz continuous with respect
to the uniform norm with Lipschitz constant 2 (cf. Lemma 13.5.1 of Whitt (2002)). Thus, y is
Lipschitz continuous with respect to the uniform norm. Since (EC.50) is equivalent to
u(t) = x(t)Z t
0
y(u)(s)ds, 8t2R+
,
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec17
there exists a unique u2D which solves (EC.50) by Lemma 1 of Reed and Ward (2004). Moreover,
the mapping M(·, y) :D!D is Lipschitz continuous with respect to the uniform norm by the same
Lemma.
Proof of Proposition EC.3: Let us fix an arbitrary pair x, y 2 D such that x(0) 0 and
supt2R+|y(t)| < 1. Let u := M(x, y) (note that such a u 2 D uniquely exists by Lemma EC.6).
Moreover, let (z, `) := (, )(u). Then, by (EC.49), (EC.50), and the fact that x(0) = u(0) 0,
z(t) = u(t)+ `(t) = x(t)Z t
0
y(s)(u)(s)ds+ `(t) = x(t)Z t
0
y(s)z(s)ds+ `(t) 0, 8t2R+
,
thus condition C1 in Definition EC.2 is satisfied by (z, `). Since u(0) = x(0) 0, then `(0) =
(u)(0) = 0 and `(·) is nondecreasing by the definition of the mapping (cf. (EC.49)). Lastly,
Z 1
0
z(t)d`(t) =
Z 1
0
(u)(t)d (u)(t) = 0
by definition of the conventional one-sided, one-dimensional regulator mapping (cf. Theorem 6.1
of Chen and Yao (2001)). Therefore, the pair (z, `) = (, )(u) satisfies the conditions C1 and C2
in Definition EC.2.
Next, we will prove uniqueness. Let (z1
, `1
) be another pair which satisfies the conditions C1 and
C2 and g 2D be such that
g(t) := x(t)Z t
0
y(s)z1
(s)ds, 8t2R+
.
Then, z1
(t) = g(t) + `1
(t) for all t 2 R+
. By condition C2 and the uniqueness of the Skorokhod
mapping (cf. Theorem 6.1 of Chen and Yao (2001)), (z1
, `1
) = (, )(g), so
g(t) = x(t)Z t
0
y(s)(g)(s)ds, 8t2R+
. (EC.51)
By Lemma EC.6, there exists a unique solution of (EC.51) which is M(x, y) = u = g. There-
fore, (z1
, `1
) = (, )(g) = (, )(u) = (z, `), which proves uniqueness. Moreover, (M, M)(x, y) =
(z, `) = (, )(u) = (, )(M(x, y)).
Next, let us consider arbitrary x1
, x2
2D such that x1
(0) 0 and x2
(0) 0. Let u1
:=M(x1
, y)
and u2
:=M(x2
, y). By Lemma EC.6, the mapping M(·, y) : D! D is Lipschitz continuous with
ec18 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
respect to the uniform norm. Let y(t) be the corresponding Lipschitz constant for t 2R+
. Then,
for all t2R+
,
M(x1
, y)M(x2
, y)
t= k(u
1
)(u2
)kt 2ku1
u2
kt 2y(t)kx1
x2
kt ,
where the first inequality is by the fact that the mapping is Lipschitz continuous with respect to
the uniform norm with Lipschitz constant 2 (cf. Lemma 13.5.1 of Whitt (2002)). Hence, M(·, y)
is Lipschitz continuous with respect to the uniform norm. Lastly, for all t2R+
,
M(x1
, y) M(x2
, y)
t= k (u
1
) (u2
)kt ku1
u2
kt y(t)kx1
x2
kt ,
where the first inequality is by the fact that the mapping is Lipschitz continuous with respect to
the uniform norm with Lipschitz constant 1 (cf. Lemma 13.4.1 of Whitt (2002)). Hence, M(·, y)
is also Lipschitz continuous with respect to the uniform norm.
Next, we present the following preliminary result.
Lemma EC.7. Let T1
2R+
be an arbitrary constant, x, y 2D be such that y 0 and there exists a
constant K 2R+
such that y(t)K for all t2R+
. Then, there exists a constant C =C(K,T1
)2R+
such that kM(x, y)kT1 CkxkT1.
Proof of Lemma EC.7: Let u := M(x, y) be the unique solution of the integral equation
(EC.50). Note that (u) 0 by (EC.49). Then by (EC.50) and the fact that y 0 and (u) 0,
u(t) kxkT1 , 8t2 [0, T1
]. (EC.52)
Let dae denote the smallest integer which is greater than or equal to a for all a 2 R. Let us
partition the interval [0, T1
] into subintervals with length 1/(4K) except the last interval which is
[(d4KT1
e 1)/(4K), T1
]. Then there are d4KT1
e subintervals. Let,
fn := sup
|u(t)| : t2
n 1
4K,n
4K
, 8n2 1, . . . , d4KT1
e 1 , (EC.53)
fd4KT1e := sup
|u(t)| : t2d4KT
1
e 1
4K,T
1
.
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec19
Then,
kM(x, y)kT1 = kukT1 = maxn21,...,d4KT1e
fn.
By (EC.50),
u(t) =x(t)+
Z t
0
y(s)(u)(s)ds, 8t2R+
. (EC.54)
By (EC.54) and the fact that the mapping is Lipschitz continuous with respect to the uniform
norm with Lipschitz constant 2 (cf. Lemma 13.5.1 of Whitt (2002)),
u(t) kxkT1 +1
4K2Kkuk
1/(4K)
, 8t2
0,1
4K
) f1
2kxkT1 (EC.55)
where the second inequality above is by (EC.52) and (EC.53). By (EC.54),
u(t) =x(t)+x
1
4K
u
1
4K
+
Z t
1/(4K)
y(s)(u)(s)ds, 8t2
1
4K,1
2K
)u(t) 2kxkT1 + f1
+1
4K2Kkuk
1/(2K)
, 8t2
1
4K,1
2K
)u(t) 2kxkT1 + f1
+1
2(f
1
+ f2
) , 8t2
1
4K,1
2K
) f2
4kxkT1 +3f1
,
where the last inequality follows by (EC.52) and (EC.53). By induction, we can show that
fn 4kxkT1 +2fn1
+n1
X
k=1
fk, 8n2 2, . . . , d4KT1
e . (EC.56)
By (EC.55) and (EC.56), one can show that
kukT1 = maxn21,...,d4KT1e
fn (d4KT1
e+4)! kxkT1 .
We complete the proof by defining C(K,T1
) := (d4KT1
e+4)!.
The second main result of this section is the following.
Lemma EC.8. Let xn, n 2N and yn, n 2N be sequences in D such that xn(0) 0 and yn 0
for all n 2 N, there exists a constant K 2 R+
such that yn(t) K for all n 2 N and t 2 R+
,
and there exist x 2 D and y 2 D such that xn ! x u.o.c. and yn ! y u.o.c. as n ! 1. Then,
(M, M) (xn, yn)! (M, M) (x, y) u.o.c. as n!1.
ec20 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Proof of Lemma EC.8: For each n2N, let un 2D be the unique solution of the equation
un(t) = xn(t)Z t
0
yn(s)(un)(s)ds, 8t2R+
, (EC.57)
which exists by Lemma EC.6. For each n2N, let us define
fn(t) :=
Z t
0
yn(s)(un)(s)ds, 8t2R+
. (EC.58)
Note that fn is continuous for all n 2 N and un = xn fn for all n 2 N by (EC.57) and (EC.58).
Let T1
be an arbitrary constant in R+
. We will show that the sequence fn, n 2 N restricted to
the compact domain [0, T1
] is relatively compact by the Arzela-Ascoli Theorem (cf. Theorem 7.2
of Billingsley (1999)). First, supn2N |fn(0)|= 0<1. Second,
lim!0
supn2N
sup|t1t2|
|fn(t2) fn(t1)|= lim!0
supn2N
sup|t1t2|
Z t2
t1
yn(s)(un)(s)ds
lim!0
2 supn2N
kynkT1supn2N
kunkT1
lim!0
2K supn2N
kunkT1
, (EC.59)
lim!0
2KC(K,T1
) supn2N
kxnkT1
= 0, (EC.60)
where the first inequality in (EC.59) is by the fact that the mapping is Lipschitz continuous with
respect to the uniform norm with Lipschitz constant 2 (cf. Lemma 13.5.1 of Whitt (2002)). The
inequality in (EC.60) is by Lemma EC.7. Note that xn ! x u.o.c where x is a bounded function in
[0, T1
], thus there exists a suciently large n0
2N such that supnn0kxnkT1
<1, and without loss
of generality we assume supn2N kxnkT1<1. Hence, we obtain the convergence result in (EC.60).
Therefore, fn, n2N restricted to the compact domain [0, T1
] is relatively compact.
Since both xn, n2N and fn, n2N are relatively compact in D[0, T1
] endowed with the u.o.c.
topology, so does un, n2N by (EC.57) and (EC.58). Let us consider an arbitrary subsequence of
un, n2N, denoted by unk, k 2N, such that unk
! u u.o.c. as k!1 where u2D[0, T1
]. Then,
supt2[0,T1]
u(t)x(t)+
Z t
0
y(s)(u)(s)ds
(EC.61)
= supt2[0,T1]
u(t)unk(t)+unk
(t)x(t)+
Z t
0
y(s)(u)(s)ds
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec21
uunk
T1+
xnkx
T1+ sup
t2[0,T1]
Z t
0
y(s)(u)(s) ynk(s)(unk
)(s)
ds
uunk
T1+
xnkx
T1+ sup
t2[0,T1]
Z t
0
y(s)(u)(s) ynk(s)(u)(s)
ds
+ supt2[0,T1]
Z t
0
ynk(s)(u)(s) ynk
(s)(unk)(s)
ds
uunk
T1+
xnkx
T1+2T
1
kukT1
ynk y
T1+2T
1
K
unku
T1. (EC.62)
As k!1, all of the terms in (EC.62) converges to 0, so (EC.61) is equal to 0. Thus, u=M(x, y)
and u is the unique solution of (EC.50) by Lemma EC.6. Therefore, each subsequence of un, n2N
has convergent subsequence which converges to the same limit, which implies that un ! u u.o.c.
as n!1 where u=M(x, y). Note that the process (M, M) (xn, yn) 2D2 is well defined for all
n 2N by Proposition EC.3. Since the mappings and are Lipschitz continuous with respect to
the uniform norm,
M, M (xn, yn) = (, ) (M(xn, yn)) = (, ) (un)
! (, ) (u) = (, ) (M(x, y)) =
M, M (x, y), u.o.c. as n!1,
which completes the proof. EC.4. Proofs of Theorems 2, 3, and 4
We prove Theorems 2, 3, and 4 by representing the queue length process of each driver type with
the time-dependent, one-sided, and nonlinear regulator mapping defined in Definition EC.2. We
first present some preliminary results that will be used in the proofs of all of the three theorems in
Section EC.4.1. Then, we will prove Theorems 2, 4, and 3 in Sections EC.4.2, EC.4.3, and EC.4.4,
respectively. Lastly, we make a discussion about whether introducing a di↵erent CLP can extend
the results of this section and the main results of the paper in Section EC.4.5.
EC.4.1. Preliminary Results
In this section, we present some preliminary results that will be used in the proofs of Theorems
2, 3, and 4. We consider R(x) where x = xij(t), i 2 N , j 2 J , t 2 [0, T ] is a feasible matching
ec22 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
process for the CLP (12) solution such that xij is a Borel measurable simple function with possibly
countably infinite range for all i2N and j 2J in this section. We start with the formal definition
of this randomized policy based on Definition 1.
Let xij(m), i 2N , j 2 J ,m 2 N be a sequence of real numbers in R+
and Bm,m 2 N be a
disjoint partition of the interval [0, T ] such that Bm is a Borel measurable set for all m 2 N. We
assume that
xij(t) =1X
m=0
xij(m)I (t2Bm) , 8t2 [0, T ], i2N , j 2J . (EC.63)
Without loss of generality, we choose the partition Bm,m 2 N such that Bm [m, m+1
) for
all m 2 N. By (12c),P
i2N xij(m) 1 for all j 2 J and m 2 N. Let us define the sequence of
independent random variables pkj (m), k 2 N+
, j 2 J ,m 2 N, which is independent of all other
stochastic primitives and F(0)-measurable such that, P(pkj (m) = i) = xij(m) and P(pkj (m) = 0) =
1Pi2N xij(m) for all i2N , j 2J , k 2N+
, and m2N. Note that the sequence pkj (m), k 2N+
, j 2
J ,m2N corresponds to m,m2N defined in Remark 3 associated with the randomized policy.
With a slight abuse of notation, let R(x) = (n1
,n2
, . . . ,nJ ) in the nth system. Then,
nj (k) =
X
i2N
X
m2N
i I
nj (k)2Bm, pkj (m) = i, Q
R(x),ni (nj (k))> 0
, (EC.64)
for all j 2 J and k,n 2N+
. Then, clearly, nj (k) is Fn
j (k)-measurable for all j 2 J and k,n 2N+
,
thus R(x) is admissible by Definition 1.
Let : N ! N be a function such that (m) := l 2 N : Bm [l, l+1
). Under R(x), for all
i2N , j 2J , t2 [0, T ], and n2N+
, we have
DR(x),nij (t) =
Ejnj (t)
X
k=1
X
m2N
I
nj (k)2Bm, akj ((m)) tij((m)), pkj (m) = i, Q
R(x),ni (nj (k))> 0
.
Let us define the following stochastic process such that for all i2N , j 2J , n2N+
, and t2 [0, T ],
HR(x),nij (t) :=
Ejnj (t)
X
k=1
X
m2N
Fij((m)
)xij(m)I
nj (k)2Bm, QR(x),ni (nj (k))> 0
,
=
Z t
0
X
m2N
Fij((m)
)xij(m)I
s2Bm, QR(x),ni (s)> 0
dEj nj (s),
=
Z t
0
Fij(s)xij(s)I
QR(x),ni (s)> 0
dEj nj (s),
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec23
where the second equality is the Lebesgue-Stieltjes integral (cf. page 107 in Folland (1999)), and
the third equality is by (2) and (EC.63). Let HR(x),nij := (1/n)HR(x),n
ij . Then we have the following
result whose proof is presented in Section EC.4.1.1.
Lemma EC.9. For all i2N and j 2J , we have
DR(x),nij H
R(x),nij
T
a.s.! 0, as n!1.
We omit the superscript R(x) from the notation for convenience in presentation in the rest
of Section EC.4.1. Let us define the following stochastic processes such that for all i 2N , j 2 J ,
n2N+
, and t2 [0, T ],
Mnij(t) :=
Z t
0
Fij(s)xij(s)I (Qni (s)> 0)
dEj nj (s) dn
j (s)
,
Lnij(t) :=
Z t
0
Fij(s)xij(s) (I (Qni (s)> 0) I (Qn
i (s)> 0))dnj (s),
Inij(t) :=
Z t
0
Fij(s)xij(s)I (Qni (s) = 0)µn
j (s)ds. (EC.65)
Let Mnij := (1/n)Mn
ij, Lnij := (1/n)Ln
ij, and Inij := (1/n)Inij for all i2N , j 2J , and n2N+
. Then, by
(9), (11), and after some algebra,
Qni (t) = Xn
i (t)Z t
0
ni (s)Qni (s)ds+
X
j2JInij(t), (EC.66)
for all i2N , n2N+
, and t2 [0, T ], where
Xni (t) := Qn
i (0)+ Ani n
i (t)
Rni
Z t
0
ni (s)Qni (s)ds
Z t
0
ni (s)Qni (s)ds
X
j2J
Dnij(t) Hn
ij(t)X
j2JMn
ij(t)+X
j2JLn
ij(t)1
n
X
j2J
Z t
0
Fij(s)xij(s)µnj (s)ds
for all i2N , n2N+
, and t2 [0, T ]. Without loss of generality, we define
Qni (t) := Qn
i (T ), Xni (t) := Xn
i (T ),X
j2JInij(t) :=
X
j2JInij(T ), ni (t) := 0 (EC.67)
for all i 2N , n 2N+
, and t T for mathematical completeness, so (EC.66) is well defined for all
t2R+
.
The following result allows us to approximate Xni by a deterministic process.
ec24 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Lemma EC.10. For all i2N and j 2J , we have
Lnij
T= 0 a.s. 8n2N
+
, and
Mnij
T
a.s.! 0, sup0t<1
Xni (t) Xi(t)
a.s.! 0, as n!1,
where
Xi(t) :=i(t)X
j2J
Z t
0
Fij(s)xij(s)µj(s)ds,
for all t 2 [0, T ] and Xi(t) := Xi(T ) for all t T . Moreover, Xi is absolutely continuous and non-
negative for all i2N .
The proof of Lemma EC.10 is presented in Section EC.4.1.2. Note that for all i2N and n2N+
,
X
j2JInij(0) = 0,
X
j2JInij is nondecreasing,
Z 1
0
Qni (t)d
X
j2JInij(t)
= 0, (EC.68)
by (EC.65) and (EC.67). By Assumption 1, the fact that Xni (0) 0, (EC.66), (EC.67), (EC.68),
Definition EC.2, and Proposition EC.3, we have
Qni ,X
j2JInij
=
M, M Xni ,
ni
for all i2N and n2N+
.
There exists a constant 2R+
and n0
2N+
such that ni (t) for all t2R+
, i2N , and n n0
by Assumptions 1 and 2. Then, by Assumption 2, Lemma EC.8, and Lemma EC.10, we have
Qni M Xi,i
T
a.s.! 0,
X
j2JInij M Xi,i
T
a.s.! 0, (EC.69)
as n!1 for all i2N . Lastly, we have the following result.
Lemma EC.11. Fix an arbitrary i2N . If M Xi,i
= 0, then
sup0tT
X
j2J
Dnij(t)
Z t
0
µj(s)Fij(s)xij(s)ds
a.s.! 0, as n!1.
Proof: By (EC.69) and the fact that M Xi,i
= 0,
X
j2JInij
T
a.s.! 0, as n!1. (EC.70)
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec25
Then,
sup0tT
X
j2J
Dnij(t)
Z t
0
µj(s)Fij(s)xij(s)ds
= sup0tT
X
j2J
Dnij(t) Hn
ij(t)+ Hnij(t) Mn
ij(t)+ Lnij(t)+ Mn
ij(t) Lnij(t)
+ Inij(t) Inij(t)Z t
0
µj(s)Fij(s)xij(s)ds
X
j2J
Dnij Hn
ij
T+X
j2J
Mnij
T+X
j2J
Lnij
T+
X
j2JInij
T
+ sup0tT
X
j2J
Hnij(t) Mn
ij(t)+ Lnij(t)+ Inij(t)
Z t
0
µj(s)Fij(s)xij(s)ds
=X
j2J
Dnij Hn
ij
T+X
j2J
Mnij
T+X
j2J
Lnij
T+
X
j2JInij
T
+ sup0tT
X
j2J
Z t
0
µnj (s)
nµj(s)
Fij(s)xij(s)ds
(EC.71)
a.s.! 0, as n!1, (EC.72)
where the first inequality above is by triangular inequality and (EC.71) is by algebra. In (EC.71),
as n!1, the first term converges to 0 a.s. by Lemma EC.9, the second and third terms converge
to 0 a.s. by Lemma EC.10. The fourth term in (EC.71) converges to 0 a.s. by (EC.70). Finally, the
fifth term in (EC.71) converges to 0 by Assumption 2 and the fact that 0 Fij(t)xij(t) 1 for all
i2N , j 2J , and t2 [0, T ]. Hence, we obtain the convergence in (EC.72).
EC.4.1.1. Proof of Lemma EC.9 The proof of Lemma EC.9 is very similar to the one of
Lemma EC.2. For notational convenience, we omit the superscript R(x) from the notation in this
section. Let us fix arbitrary i2N and j 2J . Then, by definition, we have
Dnij Hn
ij
T= sup
0tT
1
n
Ejnj (t)
X
k=1
X
m2N
I
akj ((m)) tij((m)), pkj (m) = i
Fij((m)
)xij(m)
I
nj (k)2Bm, Qni (
nj (k))> 0
. (EC.73)
For all n2N+
and m2N, let
Yk(m) := I
akj ((m)) tij((m)), pkj (m) = i
Fij((m)
)xij(m),
ec26 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Znk (m) := I
nj (k)2Bm, Qni (
nj (k))> 0
,
W nk (m) := Yk(m)Zn
k (m),
W nk :=
X
m2N
W nk (m)
Then, the right-hand side of (EC.73) is equal to
sup0tT
1
n
Ejnj (t)
X
k=1
W nk
. (EC.74)
Note that, if we can prove that
1
n
nX
k=1
W nk
a.s.! 0, as n!1, (EC.75)
then we can prove that the term in (EC.74) converges to 0 as n!1 by the same way we prove
Lemma EC.2. Hence, in the remaining part of this section, we will prove (EC.75), whose proof is
very similar to the one of (EC.21).
For all n2N+
, if k 2Z\N+
, we let Gnk := ;,; and if k 2N
+
, we let
Gnk :=
(
Ai ni (s^ nj (k)),Ej0 n
j0(s^ nj (k)),Ri
Z
(s^nj (k))
0
ni (u)Qni (u)du
!
,
Dnij0((s^ nj (k))),Qn
i ((s^ nj (k))), 8i2N , j0 2J , s2R+
,
arj0((m)), prj0(m), r 2 1, . . . ,Ej0 n
j0(nj (k)), 8j0 2J \j,m2N
arj((m)), prj(m), r 2 1, . . . , k 1, 8m2N
)
. (EC.76)
Then, Gnk , k 2 Z is a filtration for all n 2 N
+
. Moreover, Yk(m) ? Gnk and Zn
k (m) 2 Gnk for all
k,n2N+
and m2N; and W nk (m)2 Gn
k+l for all k,n, l 2N+
by construction. First, for all k,n2N+
,
Eh
W nk
Gnk
i
=E
"
X
m2N
W nk (m)
Gnk
#
=X
m2N
E
W nk (m)
Gnk
=X
m2N
E
Yk(m)Znk (m)
Gnk
, (EC.77a)
=X
m2N
Znk (m)E
Yk(m)
Gnk
=X
m2N
(Znk (m)E [Yk(m)]) = 0, (EC.77b)
where the second equality in (EC.77a) is by the fact that |W nk | 1 for all k,n 2N
+
and bounded
convergence theorem for conditional expectations. Second, for all k,n, l 2N+
,
Eh
W nk
Gnkl
i
=Eh
Eh
W nk
Gnk
i
Gnkl
i
= 0, (EC.78)
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec27
by (EC.77b). Third, for all k,n2N+
,
Eh
W nk
Gnk+bn0.25c1
i
=
8
>
>
>
<
>
>
>
:
0, if n< 16,
W nk , n 16.
(EC.79)
Therefore, by (EC.77b), (EC.78), and (EC.79), we can prove (EC.75) by the same method that we
use in Section EC.2.1 (starting from (EC.39)) in order to prove (EC.21).
EC.4.1.2. Proof of Lemma EC.10 By triangular inequality, for all i2N ,
Xni Xi
T Qn
i (0)+
Ani n
i i
T+X
j2J
Dnij Hn
ij
T+X
j2J
Mnij
T(EC.80a)
+X
j2J
Lnij
T+ sup
0tT
Rni
Z t
0
ni (s)Qni (s)ds
Z t
0
ni (s)Qni (s)ds
(EC.80b)
+X
j2Jsup
0tT
1
n
Z t
0
Fij(s)xij(s)µnj (s)ds
Z t
0
Fij(s)xij(s)µj(s)ds
. (EC.80c)
We will consider each term in the right-hand side (RHS) of (EC.80) separately. The first term
in the RHS of (EC.80a) converges to 0 a.s. by Assumption 3. The second term in the RHS of
(EC.80a) converges to 0 a.s. by (EC.13). The third term in the RHS of (EC.80a) converges to 0
a.s. by Lemma EC.9. Next let us consider the fourth term in the RHS of (EC.80a). For all i 2N
and j 2J ,
Mnij
T= sup
0tT
1
n
Z t
0
Fij(s)xij(s)I (Qni (s)> 0)d
Ej nj (s)n
j (s)
sup0tT
1
n
Z t
0
Fij(s)xij(s)I (Qni (s)> 0)d
Ej nj (s)_n
j (s)Ej nj (s)^n
j (s)
sup0tT
1
n
Z t
0
d
Ej nj (s)_n
j (s)Ej nj (s)^n
j (s)
= sup0tT
1
n
Ej nj (t)_n
j (t)Ej nj (t)^n
j (t)
sup0tT
1
n
Ej nj (t)_n
j (t)j(t)
+ sup0tT
1
n
Ej nj (t)^n
j (t)j(t)
a.s.! 0, as n!1, (EC.81)
where (EC.81) is by Assumption 2, (EC.13), and continuous mapping theorem (cf. Theorem 5.2 of
Chen and Yao (2001)). Therefore, the fourth term in the RHS of (EC.80a) also converges to 0 a.s.
ec28 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Next, let us consider the first term in (EC.80b). For all i2N , j 2J , and n2N+
,
Lnij
T sup
0tT
1
n
Z t
0
Fij(s)xij(s) |I (Qni (s)> 0) I (Qn
i (s)> 0)|µnj (s)d(s)
1
n
Z T
0
I (Qni (s) 6=Qn
i (s))µnj (s)d(s)
= 0 a.s., (EC.82)
where (EC.82) is by the fact that Qni has finitely many jumps on a compact time interval (cf.
Lemma 12.1 of Billingsley (1999)), because Qni 2D and its jump magnitudes are exactly 1, so the
Lebesgue measure of the set t2 [0, T ] :Qni (t,!) 6=Qn
i (t,!) is 0 for almost all ! 2. Therefore,
the first term in (EC.80b) is 0 a.s. for all i2N and j 2J .
Next, let us consider the second term in (EC.80b). Let us fix an arbitrary ! 2A1
(cf. (EC.14)).
From the proof of Proposition EC.1 (cf. page ec8 in Section EC.2), we know that each subsequence
of the second term in (EC.80b) has a subsequence which converges to 0 on the sample path !,
which implies that the second term in (EC.80b) itself converges to 0 as n!1 on the sample path
!. Since P(A1
) = 1, the second term in (EC.80b) converges to 0 a.s as n!1.
Next, the term in (EC.80c) converges to 0 as n!1 by Assumption 2 and the fact that 0
Fij(t)xij(t) 1 for all i2N , j 2J , and t2 [0, T ]. Since Xni (t) = Xn
i (T ) for all t T (cf. (EC.67)),
sup0t<1
Xni (t) Xi(t)
a.s.! 0, as n!1 for all i2N .
Lastly, Xi is absolutely continuous because it is a di↵erence of two absolutely continuous func-
tions. It is nonnegative by (12b) and the fact that x is a feasible matching process for the CLP
(12).
EC.4.2. Proof of Theorem 2
Since i = 0 by assumption, M
Xi,i
= Xi by Definition EC.3. By (EC.49) and the fact that
M Xi,i
= M
Xi,i
(cf. Proposition EC.3) and Xi is nonnegative (cf. Lemma EC.10), we
have M Xi,i
=
Xi
= 0 for all i2N . Then, the proof follows by Lemma EC.11.
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec29
EC.4.3. Proof of Theorem 4
The process x
is a feasible matching process for the CLP (12) by Lemma 4 and it is a Borel
measurable simple function with possibly countably infinite range for all i 2 N and j 2 J by
assumption. Then, the results of Section EC.4.1 apply to this process. Moreover, we can extend
the results of Lemma EC.10 such that Xi is also nondecreasing for all i 2N by (14b), (12b), and
the fact that x is a feasible matching process for both the CLP (12) and the LP (14). Then, we
have the following result.
Lemma EC.12. M
Xi,i 0 for all i2N .
Proof: Recall that Xi is an absolutely continuous, nonnegative, and nondecreasing function for
all i2N by Lemma EC.10 and the argument mentioned above. Let us fix an arbitrary i2N . Let
ui :=M(Xi,i). Then, by Definition EC.3,
ui(t) = Xi(t)Z t
0
i(s)(ui)(s)ds, 8t2R+
. (EC.83)
Since ui is a di↵erence of two absolutely continuos functions, it is also absolutely continuous.
We will use proof by contradiction technique. Assume that ui(t)< 0 for some t2R+
. Then, there
exists an interval [t1
, t2
]R+
such that t1
:= inft2R+
: ui(t)< 0, ui(·) is nonincreasing on [t1
, t2
],
and ui(t2)< 0. Since ui(0) = 0 and ui is continuous, such an interval exists. Then, ui(t1) = 0 and
(ui)(t) = 0 for all t2 [t1
, t2
] by (EC.49) and construction, and
ui(t2) = Xi(t2)Z t2
0
i(s)(ui)(s)ds= Xi(t2)
ui(t1)+
Z t1
0
i(s)(ui)(s)ds
Z t2
t1
i(s)(ui)(s)ds
= Xi(t2) Xi(t1)Z t2
t1
i(s)(ui)(s)ds= Xi(t2) Xi(t1) 0,
which is a contradiction because ui(t2) < 0 by construction. Therefore, ui(t) 0 for all t 2 R+
,
which completes the proof.
By (EC.49), the fact that M Xi,i
= M
Xi,i
(cf. Proposition EC.3), and Lemma
EC.12, we have M Xi,i
= 0 for all i2N . Then, by Lemma EC.11, for all i2N ,
sup0tT
X
j2J
DR(x
),n
ij (t)Z t
0
µj(s)Fij(s)xij(s)ds
a.s.! 0, as n!1,
which gives us the desired result.
ec30 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
EC.4.4. Proof of Theorem 3
By Assumption 1 and the fact that xij = 0 for all i 2N and j 2J are feasible matching fractions
for the LP (13), there exists an optimal solution of the LP (13), denoted by x = xij, i2N , j 2J .
Let x := xij(t), i2N , j 2J , t2 [0, T ] be such that xij(t) := xij for all i2N , j 2J , and t2 [0, T ].
It is easy to see that the process x is a feasible matching process for the CLP (12). Thus,
X
i2N ,j2JwijµjFij
Z T
0
xij(s)ds=X
i2N ,j2JwijµjFijx
ijT
X
i2N ,j2JwijµjFij
Z T
0
xij(s)ds, (EC.84)
where x := xij(t), i 2 N , j 2 J , t 2 [0, T ] is an optimal solution of the CLP (12), which exists
by Lemma 2. Let xij := (1/T )R T
0
xij(s)ds for all i 2 N and j 2 J . Then it is easy to see that
xij, i2N , j 2J is feasible for the LP (13), thus
X
i2N ,j2JwijµjFijxij =
X
i2N ,j2JwijµjFij
1
T
Z T
0
xij(s)ds
X
i2N ,j2JwijµjFijx
ij. (EC.85)
By (EC.84) and (EC.85), we see that x is an optimal solution of the CLP (12).
The rest of the proof of Theorem 3 is very similar to the one of Theorem 4. Since the process x is
an optimal solution of the CLP (12) and xij is a Borel measurable simple function for all i2N and
j 2 J , the results of Section EC.4.1 apply to this process. Moreover, we can extend the results of
Lemma EC.10 such that Xi is also nondecreasing for all i2N by (13b). Therefore, Lemma EC.12
holds and M Xi,i
= 0 for all i2N . Then, by Lemma EC.11, for all i2N ,
sup0tT
X
j2J
DR(˜x),nij (t)
Z t
0
µj(s)Fij(s)xij(s)ds
a.s.! 0, as n!1,
which gives us the desired result.
EC.4.5. A CLP with departure rates of unmatched drivers
By the properties of the fluid limits of admissible policies (cf. Proposition EC.1), it is possible to
derive a CLP which considers with i, i2N in the following way:
maxX
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds, (EC.86a)
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec31
X
j2J
Z t
0
µj(s)Fij(s)xij(s)ds+ qi(t)+
Z t
0
i(s)qi(s)ds=i(t), 8i2N and t2 [0, T ], (EC.86b)
X
i2Nxij(t) 1, for all j 2J and t2 [0, T ], (EC.86c)
xij(t) 0, qi(t) 0, for all i2N , j 2J , and t2 [0, T ], (EC.86d)
xij and qi are Lebesgue measurable for all i2N and j 2J , (EC.86e)
where the decision variables are xij : [0, T ]!R+
and qi : [0, T ]!R+
for all i 2N and j 2 J . The
only di↵erence between the CLP (EC.86) and the CLP (12) is that the former one contains the
additional parameters i, i2N and the additional decision variables qi, i2N.
Although we can associate the matching policies defined in Definition 2 and Section 5.1 with
feasible matching processes for the CLP (EC.86), these matching policies do not provide more
general asymptotic optimality results than the ones that we have in Corollary 1 and Theorems
2, 3, and 4. Recall that we need the condition i = 0 in Theorem 2 and i = 0 for all i 2 N in
Corollary 1 because we use Theorem 2 to prove Corollary 1. In order to prove Theorem 2, we need
Lemma EC.11. However, Lemma EC.11 holds, if M Xi,i
= 0; and a sucient condition for that
result is i = 0. In order to prove Theorem 2 for the randomized policy associated with a feasible
matching process for the CLP (EC.86), we still need to prove Lemma EC.11, and we still need the
condition M Xi,i
= 0. However, the CLP (EC.86) does not facilitate a di↵erent condition than
the one i = 0 to prove M Xi,i
= 0.
Recall that we derive the LP (14) from the CLP (12) by taking the derivative of (12a) and (12b)
with respect to t. Then we prove Theorem 4 by Assumption 4. However, it is not clear how to
derive an LP from CLP (EC.86) because taking the derivative of (EC.86b) with respect to t results
in an ordinary di↵erential equation. Hence, it is not clear how to relax Assumption 4 by using the
CLP (EC.86).
In summary, considering the CLP (EC.86), which is more complicated than the CLP (12), does
not facilitate more general results. Hence, we consider the CLP (12) in this study.
ec32 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
EC.5. Lemma Proofs
We first prove Lemma 1, second prove Lemmas 3 and 5 (because they are related to Lemma 1),
third prove Lemma 2, and lastly prove Lemma 4.
EC.5.1. Proof of Lemma 1
Let CD = (1
,2
, . . . ,J). For notational convenience, we omit the superscript CD from the nota-
tion in this proof. Let us define the sequence of independent random variables qkj (l), k 2 N+
, j 2
J , l 2NN, which is independent of all other stochastic primitives and F(0)-measurable, such that
qkj (0,0, . . . ,0) = 0, and ifPN
i=1
li > 0, then P(qkj (l1, l2, . . . , lN) = i) = li/PN
i=1
li for all k 2N+
, j 2J ,
and l 2NN such that l= (l1
, l2
, . . . , lN). For notational convenience, let us define the set
Sj(k) := argmini2N :Qi(j(k))>0
X
m2N
tij(m)I(j(k)2 [m, m+1
) (EC.87)
for all j 2 J and k 2N+
. Let |Sj(k)| denote the cardinality of the set Sj(k). Then, under the CD
policy, for all j 2J and k 2N+
, let
j(k) := I (|Sj(k)|= 1)X
i2N
i I (i2 Sj(k))
+ I (|Sj(k)|> 1) qkj
Q1
(j(k))I(12 Sj(k)), . . . ,QN(j(k))I(N 2 Sj(k))
.
Note that Qi(j(k)) = limt!1Qi((t^ j(k))) 2Fj(k) by Proposition 2.7 of Folland (1999) and
definition of Fj(k) (cf. (8)) for all i 2N , j 2 J , and k 2 N+
. By (8), (EC.87), and the fact that
j(k) 2 Fj(k), the random variables I (|Sj(k)|= 1), I (|Sj(k)|> 1), I (i2 Sj(k)), and I (Sj(k) =N1
)
are Fj(k)-measurable for all i2N , j 2J , k 2N+
, and N1
N . Lastly,
qkj
Q1
(j(k))I(12 Sj(k)), . . . ,QN(j(k))I(N 2 Sj(k))
=X
N1NI (Sj(k) =N
1
)
X
l2NN:li=0,8i/2N1
qkj (l1, l2, . . . , lN)I
Qi(j(k)) = li,8i2N1
!
2Fj(k).
Therefore, j 2 Fj for all j 2 J under the CD policy, so it is an admissible policy. Note that, the
sequence qkj (l), k 2N+
, j 2J , l 2NN corresponds to m,m2N defined in Remark 3 associated
with the CD policy.
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec33
EC.5.2. Proofs of Lemmas 3 and 5
First, the randomized policy given in Definition 2 is admissible by the fact that (EC.64) is Fnj (k)-
measurable for all j 2J and k,n2N+
. Second, the admissibility proof of the hybrid policy follows
by the fact that it is a hybrid of the randomized policy given in Definition 2 and the CD policy
defined in (3), and both of the latter two policies are admissible. Third, the deterministic policy is
admissible because both Qni (
nj (k)) and Dn
ij(nj (k)) are Fn
j (k)-measurable for all i 2N , j 2J ,
and k,n2N+
(cf. (8)) and the tie breaking rule does not use any future information.
EC.5.3. Proof of Lemma 2
We use the proof technique introduced by Levinson (1966). We first present a preliminary result
from Levinson (1966), then prove Lemma 2. Let L2([0, T ]) denote the space of Lebesgue measurable
functions with domain [0, T ] and range R such that if f 2 L2([0, T ]), thenR T
0
f(t)2dt <1. We let
w! denote weak convergence in L2([0, T ]) as defined in Proposition 6 in Section 8.2 of Royden and
Fitzpatrick (2010).
Lemma EC.13. (Lemma 2.1 of Levinson (1966)) Let fr, r 2N be a uniformly bounded sequence
of functions in L2([0, T ]) such that frw! f for some f 2L2([0, T ]). Let fu, fl : [0, T ]!R be defined
as fu(t) := limsupr!1 fr(t) and fl(t) := lim infr!1 fr(t) for all t 2 [0, T ]. Then, f(t) fu(t) and
f(t) fl(t) for all t2 [0, T ] except on a set of zero measure.
First, note that xij = 0 for all i 2N and j 2J is a feasible matching process for the CLP (12).
Second, xij is nonnegative and bounded for all i2N and j 2J by (12c) and (12d). Third, both µj
and i are bounded processes on [0, T ] by Assumption 1, and wij and Fij are bounded by definition
for all i 2N and j 2 J . Moreover, µj, i, and Fij are all Borel measurable (so does the process
µj(·)Fij(·)) by construction for all i2N and j 2J .
Let x := xij, i 2N , j 2 J denote the decision variables of the CLP (12), H denote the set of
feasible decision variables of the CLP (12), i.e., H= x :x satisfies (12b)-(12e), and
M := supx2H
X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds <1.
ec34 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Then, there exists a sequence of feasible decision variables denoted by xr, r 2N such that xr =
xrij, i2N , j 2J for all r 2N and
limr!1
X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xrij(s)ds=M.
By Theorem 14 in Section 8.3 of Royden and Fitzpatrick (2010), there exists a subsequence of
xr, r 2N which is again denoted by xr, r 2N for notational convenience such that xrij weakly
converges to some xij 2L2([0, T ]) for all i2N and j 2J . Let x := xij, i2N , j 2J . SinceX
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds=X
i2N ,j2Jwij lim
r!1
Z T
0
µj(s)Fij(s)xrij(s)ds=M, (EC.88)
it is enough to prove that a modification of x is in H in order to prove Lemma 2.
First, let us consider (12b). Let us fix an arbitrary i2N and t2 [0, T ]. Then,
X
j2J
Z t
0
µj(s)Fij(s)xij(s)ds=X
j2J
Z T
0
µj(s)Fij(s)I(s2 [0, t])xij(s)ds
=X
j2Jlimr!1
Z T
0
µj(s)Fij(s)I(s2 [0, t])xrij(s)dsi(t), (EC.89)
where the equality in (EC.89) is by the definition of weak convergence and the inequality in (EC.89)
is by (12b). Hence, x satisfies (12b).
Next, let us consider (12c) and (12d). Note that, since xrij
w! xij for all i 2N and j 2 J , it is
easy to see thatP
i2N xrij
w!P
i2N xij for all j 2J . Then, by Lemma EC.13, for all t2 [0, T ] except
on a set of zero measure,
X
i2Nxij(t) limsup
r!1
X
i2Nxrij(t) 1, xij(t) lim inf
r!1xrij(t) 0, 8i2N , j 2J . (EC.90)
Hence, x satisfies (12c) and (12d) for all t2 [0, T ] except on a set of zero measure, and we denote this
set of zero measure by H and its complement by Hc, i.e., Hc := [0, T ]\H. Let x= xij, i2N , j 2J
be such that xij(t) := xij(t) for all t2Hc, i2N , and j 2J , and xij(t) := 0 for all t2H, i2N , and
j 2J . Then, x satisfies (12c) and (12d) by construction, and satisfies (12e) by Proposition 2.11.a
of Folland (1999). Moreover, for all i2N and t2 [0, T ],
X
j2J
Z t
0
µj(s)Fij(s)xij(s)ds
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec35
=X
j2J
Z T
0
µj(s)Fij(s)I(s2 [0, t]\H)xij(s)ds+X
j2J
Z T
0
µj(s)Fij(s)I(s2 [0, t]\Hc)xij(s)ds
=X
j2J
Z T
0
µj(s)Fij(s)I(s2 [0, t]\Hc)xij(s)ds (EC.91)
i(t)X
j2J
Z T
0
µj(s)Fij(s)I(s2 [0, t]\H)xij(s)ds=i(t), (EC.92)
where (EC.91) is by the fact that H is a set of zero measure and xij(t) = xij(t) for all t 2Hc, the
inequality in (EC.92) is by (EC.89), and the equality in (EC.92) is by the fact that H is a set of
zero measure. Therefore, x satisfies (12b), so it is a feasible matching process for the CLP (12),
and it is an optimal solution by (EC.88) and the fact that it is equal to x almost everywhere.
EC.5.4. Proof of Lemma 4
By Assumption 4 and the argument in the first paragraph of Section 4.2, there exists an optimal
solution of the CLP (12), denoted by x, under which constraint (12b) is binding for all driver types
at all times. Note that x satisfies (14c) and (14d) because these constraints are exactly the same
of (12c) and (12d), respectively. Since constraint (12b) is binding for all driver types at all times
under x, then by taking the derivative of both right- and left-hand sides of (12b) with respect to
t, we can see that xij(t), i 2N , j 2 J (or a modification of it) satisfies (14b) for all t 2 [0, T ], so
it is feasible for the LP (14) for all t2 [0, T ]. Then,
X
i2N ,j2Jwijµj(t)Fij(t)xij(t)
X
i2N ,j2Jwijµj(t)Fij(t)x
ij(t), 8t2 [0, T ],
)X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)dsX
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds. (EC.93)
Second, x satisfies (12e) by Assumption 5 and satisfies (12c) and (12d) by satisfying (14c) and
(14d), respectively. By taking the integral of both the right- and left-hand sides in (14b) with
respect to t, we can see that x satisfies (12b) for all t2 [0, T ], so it is a feasible matching process
for the CLP (12). Then,
X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds
X
i2N ,j2Jwij
Z T
0
µj(s)Fij(s)xij(s)ds. (EC.94)
Therefore, x is an optimal solution of the CLP (12) by (EC.93) and (EC.94).
ec36 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
EC.6. Relative Compactness in space D
In this section, we present a relative compactness result in space D that we use in the proof of
Proposition EC.1 (cf. Section EC.2). Although this result is known in folklore, we could not find a
specific theorem to refer to, thus we provide one.
Let T1
2R+
be an arbitrary constant. We consider D[0, T1
] endowed with the usual Skorokhod
J1
topology (cf. Chapter 3 of Billingsley (1999)). For some x, y 2 D[0, T1
], let d(x, y) denote the
Skorokhod J1
distance between these processes (cf. (12.13) in Billingsley (1999)).
Lemma EC.14. Let Y n, n 2 N+
be a relatively compact sequence in D[0, T1
] endowed with the
u.o.c. topology such that all of its subsequential limits are uniformly continuous. Let Xn, n2N+
be a sequence in D[0, T1
] such that
supn2N+
|Xn(0)|<1, (EC.95a)
|Xn(t2
)Xn(t1
)|K |Y n(t2
)Y n(t1
)| , for all t1
, t2
2 [0, T1
] and n2N+
, (EC.95b)
where K 2R+
is a constant. Then, Xn, n2N+
is relatively compact in D[0, T1
] endowed with the
u.o.c. topology and all of its subsequential limits are uniformly continuous.
Moreover, if all of the subsequential limits of Y n, n2N+
are absolutely (Lipschitz) continuous,
then all of the subsequential limits of Xn, n2N+
are also absolutely (Lipschitz) continuous.
Proof: Since Y n, n 2 N+
is relatively compact with respect to the u.o.c. topology, it is also
relatively compact with respect to the Skorokhod J1
topology. Then, by Theorem 12.3 of Billingsley
(1999),
supn2N+
kY nkT1<1, lim
!0
supn2N+
w0(Y n, ) = 0, (EC.96)
where w0 is defined in equation (12.6) of Billingsley (1999). Then,
supn2N+
kXnkT1= sup
n2N+
sup0tT1
|Xn(t)| supn2N+
|Xn(0)|+ supn2N+
sup0tT1
|Xn(t)Xn(0)|
supn2N+
|Xn(0)|+K supn2N+
sup0tT1
|Y n(t)Y n(0)| supn2N+
|Xn(0)|+2K supn2N+
kY nkT1<1, (EC.97)
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec37
where the first inequality in (EC.97) is by (EC.95b) and the strict inequality in (EC.97) is by
(EC.95a) and (EC.96). Next,
0 lim!0
supn2N+
w0(Xn, )K lim!0
supn2N+
w0(Y n, ) = 0, (EC.98)
where the second inequality is by the definition of w0 (cf. equation (12.6) of Billingsley (1999))
and (EC.95b) and the last equality is by (EC.96). Therefore, Xn, n2N+
is a relatively compact
sequence in D[0, T1
] endowed with the Skorokhod J1
topology by (EC.97), (EC.98), and Theorem
12.3 of Billingsley (1999).
Let Xnl , l 2N+
be an arbitrary convergent subsequence of Xn, n2N+
such that d(Xnl ,X)!
0 for some X 2 D[0, T1
] as l ! 1. Then, there exists a subsequence of nl, l 2 N+
, denoted by
nk, k 2N+
, such that d(Y nk , Y )! 0 as k!1 where Y 2D[0, T1
] and Y is uniformly continuous.
Let us fix an arbitrary > 0. There exits a := (,K)> 0 such that if |t2
t1
|< , |Y (t2
)Y (t1
)|<
/(6K). Since convergence in Skorokhod J1
metric implies u.o.c. convergence when the limit is
continuous (cf. page 124 in Billingsley (1999)), we also have kY nk Y kT1 ! 0 as k !1. Let
denote the set of continuous, strictly increasing, and bijective mappings from the domain [0, T1
]
onto itself. Then, there exists a k0
2 N+
and a sequence ↵k, k 2 N+
in the set such that if
k k0
,
↵k e
T1_Xnk ↵k X
T1<
8^ , kY nk Y kT1 <
8K, (EC.99)
where the first inequality is by the definition of Skorokhod J1
metric (cf. (12.13) in Billingsley
(1999)) and the fact that d(Xnk ,X)! 0 as k !1. Let us fix an arbitrary k k0
. Then, for all
t1
, t2
2 [0, T1
] such that |t2
t1
| ,
|X(t2
)X(t1
)| X(t2
)Xnk(↵k(t2
))
+
Xnk(↵k(t2
))Xnk(↵k(t1
))
+
Xnk(↵k(t1
))X(t1
)
2
X
l=1
X(tl)Xnk(↵k(tl))
+K
Y nk(↵k(t2
))Y nk(↵k(t1
))
2
X
l=1
X(tl)Xnk(↵k(tl))
+K
Y nk(↵k(tl))Y (↵k(tl))
+K
Y (↵k(tl))Y (tl)
+K |Y (t2
)Y (t1
)|
ec38 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
< 2
Xnk ↵k X
T1+2KkY nk Y kT1 +
3+
6
<
4+
4+
2= ,
where the second inequality is by (EC.95b), the fourth inequality is by the definition of and
(EC.99), the last inequality is by (EC.99). Therefore, X is uniformly continuous, thus Xnl !X
u.o.c. as l!1 (cf. page 124 of Billingsley (1999)). This implies that Xn, n2N+
is also relatively
compact in the u.o.c. topology and all of its subsequential limits are uniformly continuous.
Next, suppose that Y is absolutely continuous. We will prove thatX is also absolutely continuous.
Let us fix an arbitrary 1
> 0. Let (al, bl)ml=1
be an arbitrary finite set of disjoint intervals such
that (al, bl) [0, T1
] for all l 2 1,2, . . . ,m. Since Y is absolutely continuous, for any 1
> 0, there
exists a 1
= 1
(1
)> 0 such that ifPm
l=1
(bl al)< 1
, thenPm
l=1
|Y (bl)Y (al)|< 1
/K. Then
mX
l=1
|X(bl)X(al)|mX
l=1
(|X(bl)Xnk(bl)|+ |Xnk(bl)Xnk(al)|+ |Xnk(al)X(al)|)
mX
l=1
|X(bl)Xnk(bl)|+ |Xnk(al)X(al)|+K |Y nk(bl)Y (bl)|
+K |Y nk(al)Y (al)|+K |Y (bl)Y (al)|
mX
l=1
2kX XnkkT1+2K kY nk Y kT1
+K |Y (bl)Y (al)|
= 2m
kX XnkkT1+K kY nk Y kT1
+KmX
l=1
|Y (bl)Y (al)|, (EC.100)
where the second inequality is by (EC.95b). By letting k!1, the first term in (EC.100) converges
to 0, thus the sum of the terms in (EC.100) becomes less than 1
. Hence,X is absolutely continuous.
Lastly, suppose that Y is Lipschitz continuous with Lipschitz constant 2 R+
. We will prove
that X is also Lipschitz continuous. For all t1
, t2
2R+
,
|X(t2
)X(t1
)| limsupk!1
(|X(t2
)Xnk(t2
)|+ |Xnk(t2
)Xnk(t1
)|+ |Xnk(t1
)X(t1
)|)
limsupk!1
|X(t2
)Xnk(t2
)|+ |Xnk(t1
)X(t1
)|+K |Y nk(t2
)Y (t2
)|
+K |Y nk(t1
)Y (t1
)| +K |Y (t2
)Y (t1
)|
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec39
limsupk!1
2kX XnkkT1+2K kY nk Y kT1
+K |Y (t2
)Y (t1
)| (EC.101)
K|t2
t1
|,
where the second inequality is by (EC.95b). Since the first term in (EC.101) converges to 0 and Y
is Lipschitz continuous, we obtain the last inequality, so X is Lipschitz continuous. References
Adan I, Weiss G (2012) Exact FCFS matching rates for two infinite multitype sequences. Operations Research
60:475–489.
Akbarpour M, Li S, Gharan SO (2016) Thickness and information in dynamic matching markets, Working
paper, http://ssrn.com/abstract=2394319.
Aliprantis CD, Border KC (2006) Infinite Dimensional Analysis: A Hitchhiker’s Guide (Springer), third
edition.
Anderson EJ, Nash P, Perold AF (1983) Some properties of a class of continuous linear programs. SIAM
Journal on Control and Optimization 21:758–765.
Arnosti N, Johari R, Kanoria Y (2016) Managing congestion in matching markets, Working paper, http:
//ssrn.com/abstract=2427960.
Ata B, Kumar S (2005) Heavy trac analysis of open processing networks with complete resource pooling:
Asymptotic optimality of discrete review policies. The Annals of Applied Probability 15:331–391.
Azevedo EM, Weyl EG (2016) Matching markets in the digital age. Science 352:1056–1057.
Bertsimas D, Nasrabadi E, Paschalidis IC (2015) Robust fluid processing networks. IEEE Transactions on
Automatic Control 60:715–728.
Billingsley P (1999) Convergence of Probability Measures (Wiley), second edition.
Bimpikis K, Candogan O, Saban D (2017) Spatial pricing in ride-sharing networks, Working paper, https:
//ssrn.com/abstract=2868080.
Braverman A, Dai JG, Liu X, Ying L (2017) Empty-car routing in ridesharing systems, Working paper,
arXiv:1609.07219v2.
ec40 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Buke B, Chen H (2015) Stabilizing policies for probabilistic matching systems. Queueing Systems 80:35–69.
Busic A, Gupta V, Mairesse J (2013) Stability of the bipartite matching model. Advances in Applied Prob-
ability 45:351–378.
Cachon GP, Daniels KM, Lobel R (2016) The role of surge pricing on a service platform with self-scheduling
capacity, Working paper, http://ssrn.com/abstract=2698192.
Caldentey R, Kaplan EH, Weiss G (2009) FCFS infinite bipartite matching of servers and customers.
Advances in Applied Probability 41:695–730.
Chen H, Yao DD (2001) Fundamentals of Queueing Networks: Performance, Asymptotics, and Optimization
(Springer).
Chen K, Sheldon M (2016) Dynamic pricing in a labor market: Surge pricing and flexible work on
the Uber platform, working paper, http://www.anderson.ucla.edu/faculty_pages/keith.chen/
papers.htm.
Chen L, Mislove A, Wilson C (2015) Peeking beneath the hood of Uber. Proceedings of the 2015 ACM
Conference on Internet Measurement Conference, 495–508 (New York).
Dai JG, Tezcan T (2011) State space collapse in many-server di↵usion limits of parallel server systems.
Mathematics of Operations Research 36:271–320.
de Jong RM (1996) A strong law of large numbers for triangular mixingale arrays. Statistics & Probability
Letters 27:1–9.
Durrett R (2010) Probability: Theory and Examples (Cambridge), fourth edition.
Folland GB (1999) Real Analysis Modern Techniques and Their Applications (Wiley), second edition.
Gopalakrishnan R, Mukherjee K, Tulabandhula T (2016) The costs and benefits of ridesharing: Sequential
individual rationality and sequential fairness, Working paper, arXiv:1607.07306v1.
Guda H, Subramanian U (2017) Strategic surge pricing and forecast communication on on-demand service
platforms, Working paper, https://ssrn.com/abstract=2895227.
Gurvich I, Ward A (2014) On the dynamic control of matching queues. Stochastic Systems 4:479–523.
e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing ec41
Hall J, Kendrick C, Nosko C (2016) The e↵ects of Uber’s surge pricing: A case study, Working paper,
http://faculty.chicagobooth.edu/chris.nosko/.
Harrison JM (2000) Brownian models of open processing networks: Canonical representation of workload.
The Annals of Applied Probability 10:75–103.
Hu M, Zhou Y (2016) Dynamic type matching, Working paper, http://ssrn.com/abstract=2592622.
Kallenberg O (1997) Foundations of Modern Probability (Springer).
Karatzas I, Shreve SE (1988) Brownian Motion and Stochastic Calculus (Springer-Verlag), first edition.
Leshno JD (2016) Dynamic matching in overloaded waiting lists, Working paper, http://jleshno.weebly.
com/.
Levinson N (1966) A class of continuous linear programming problems. Journal of Mathematical Analysis
and Applications 16:7–83.
Michallon C (2016) ‘Shame on you’: Uber comes under fire as users complain of price
surge in the aftermath of Manhattan explosion - with rides costing up to three times
their usual prices. Dailymail.com http://www.dailymail.co.uk/news/article-3795474/
Uber-comes-fire-users-complain-price-surge-aftermath-Manhattan-explosion.html.
Moyal P, Perry O (2016) On the instability of matching queues, Working paper, arXiv:1511.04282.
Perold AF (1981) Extreme points and basic feasible solutions in continuous time linear programming. SIAM
Journal on Control and Optimization 19:52–63.
Plambeck EL, Ward AR (2006) Optimal control of a high-volume assemble-to-order system. Mathematics of
Operations Research 31:453–477.
Reed JE, Ward AR (2004) A di↵usion approximation for a generalized Jackson network with reneging.
Proceedings of the 42nd Annual Allerton Conference on Communication, Control, and Computing
(Monticello, IL.).
Reed JE, Ward AR (2008) Approximating the GI/GI/1+GI queue with a nonlinear drift di↵usion: Hazard
rate scaling in heavy trac. Mathematics of Operations Research 33:606–644.
Reiman MI, Wang Q (2015) Asymptotically optimal inventory control for assemble-to-order systems with
identical lead times. Operations Research 63:716–732.
ec42 e-companion to Ozkan and Ward: Dynamic Matching for Real-time Ridesharing
Riquelme C, Banerjee S, Johari R (2016) Pricing in ride-share platforms: A queueing-theoretic approach,
Working paper, http://ssrn.com/abstract=2568258.
Rochet JC, Tirole J (2006) Two-sided markets: a progress report. RAND Journal of Economics 37:645–667.
Ross SM (1996) Stochastic Processes (Wiley), second edition.
Royden HL, Fitzpatrick PM (2010) Real Analysis (Pearson), fourth edition.
Shiryaev AN (2008) Optimal Stopping Rules (Springer), reprint of the 1978 edition.
Stroock DW, Varadhan SRS (2006) Multidimensional Di↵usion Processes (Springer), reprint of the 1997
edition.
Taylor TA (2017) On-demand service platforms, Working paper, https://ssrn.com/abstract=2722308.
The Economist (2016) A fare shake. http://www.economist.com/news/finance-and-economics/
21698656-jacking-up-prices-may-not-be-only-way-balance-supply-and-demand-taxis.
Unver MU (2010) Dynamic kidney exchange. Review of Economic Studies 77:372–414.
Ward AR, Kumar S (2008) Asymptotically optimal admission control of a queue with impatient customers.
Mathematics of Operations Research 33:167–202.
Weiss G (2008) A simplex based algorithm to solve separated continuous linear programs. Mathematical
Programming 115:151–198.
White D (2016) Uber users are complaining about pricey New Year’s Eve rides. Time http://time.com/
4165410/uber-new-years-eve-price-surge-rides/.
Whitt W (2002) Stochastic-Process Limits: An Introduction to Stochastic-Process Limits and Their Appli-
cation to Queues (Springer).