1
Task Replication for Deadline-Constrained Vehicular Cloud Computing: Optimal Policy, Performance Analysis and Implications on Road Traffic
arXiv:1711.11114v1 [cs.IT] 29 Nov 2017
Zhiyuan Jiang, Member, IEEE, Sheng Zhou, Member, IEEE, Xueying Guo, Member, IEEE, Zhisheng Niu, Fellow, IEEE
Abstract—In vehicular cloud computing (VCC) systems, the computational resources of moving vehicles are exploited and managed by infrastructures, e.g., roadside units, to provide computational services. The offloading of computational tasks and collection of results rely on successful transmissions between vehicles and infrastructures during encounters. In this paper, we investigate how to provide timely computational services in VCC systems. In particular, we seek to minimize the deadline violation probability given a set of tasks to be executed in vehicular clouds. Due to the uncertainty of vehicle movements, the task replication methodology is leveraged which allows one task to be executed by several vehicles, and thus trading computational resources for delay reduction. The optimal task replication policy is of key interest. We first formulate the problem as a finite-horizon sampled-time Markov decision problem and obtain the optimal policy by value iterations. To conquer the complexity issue, we propose the balanced-task-assignment (BETA) policy which is proved optimal and has a clear structure: it always assigns the task with the minimum number of replicas. Moreover, a tight closed-form performance upper bound for the BETA policy is derived, which indicates that the deadline violation probability follows the Rayleigh distribution approximately. Applying the vehicle speed-density relationship in the traffic flow theory, we find that vehicle mobility benefits VCC systems more compared with road traffic systems, by showing that the optimum vehicle speed to minimize the deadline violation probability is larger than the critical vehicle speed in traffic theory which maximizes traffic flow efficiency. Index Terms—Vehicular networks, cloud computing, Markov decision process, task replication, hard deadline.
I. I NTRODUCTION With the rapid development of autonomous driving technologies and a wide variety of on-board infotainment services, the future vehicles are equipped with advanced and sufficient computational resources to facilitate sophisticated artificialintelligence (AI) based algorithms. Wireless communication modules are also indispensable, which enable various types of communications including vehicle-to-vehicle (V2V), vehicleto-infrastructure (V2I) and vehicle-to-everything (V2X) over Z. Jiang, S. Zhou and Z. Niu are with Tsinghua National Laboratory for Information Science and Technology, Tsinghua University, Beijing 100084, China. Emails: {zhiyuan, sheng.zhou, niuzhs}@tsinghua.edu.cn. X. Guo is with the Department of Computer Science, University of California at Davis, Davis, CA 95616, USA. Email:
[email protected]. The corresponding author is S. Zhou. This work is sponsored in part by the Nature Science Foundation of China (No. 61701275, No. 91638204, No. 61571265, No. 61621091), the China Postdoctoral Science Foundation, and Intel Collaborative Research Institute for Mobile Networking and Computing.
different protocols, e.g., dedicated short range communication (DSRC) [1], long-term-evolution-vehicle (LTE-V) [2] and future 5G technologies [3]. Armed with these components, the vehicular network is evolving into a connected group of intelligent individuals which has great potentials. Consequently, the vehicle-as-a-resource (VaaR) concept has been proposed recently which exploits the enormous resources of vehicles and the vehicular network to facilitate new types of services such as sensing, vehicle-bearing data transfer, cloud computing and localization [4]–[14]. Among the resources that the vehicular network can offer, the computational resources are considered to be the most desirable one due to the growing computing demand of AI systems and the hardware limitation of user equipments [7] [8]. The vehicular cloud computing (VCC) [4] [9] is therefore proposed to allow the computing tasks to be collected at the task assignment station, e.g., a roadside unit (RSU), and offloaded to vehicles. A pictorial description of the VCC architecture is given in Fig. 1, in which the RSU controls the vehicular cloud through communications with vehicles inside its coverage area [15]. The computational resources of vehicles are abstracted based on the network function virtualization (NFV) technology [16], such that it is transparent to users. The users can be pedestrians, sensors, and vehicles with insufficient computation capability. The task execution procedure is as follows. An RSU, denoted by task-RSU, collects tasks from users and offloads them to its associated vehicles based on a given task assignment policy during meetings between vehicles and the RSU. After the task computation, the output of the task is fed back to the task-RSU through the backhaul when the vehicle meets with any RSU in the network. Since the tasks can only be offloaded (or collected) to (or from) the vehicles inside the limited coverage area by successful transmissions during encounters [15], such a VCC system is referred to as an encounter-based VCC (eVCC) system [17]–[20]. One can immediately identify that the most intriguing challenge in the eVCC system is that the service process exhibits large uncertainty due to vehicle mobility. The meetings between the taskRSU and service-vehicles (SVs) and the meetings afterwards when the outputs of the tasks are collected are both subject to the random behaviour of moving vehicles. Consequently, the timeliness of the task computation is difficult to guarantee. Therefore, how to provide timely cloud computing services in eVCC systems becomes a challenging problem. We propose to exploit the task replication technique to
2
RSU
TASK OFFLOAD
Backhaul
TASK OFFLOAD
RSU TASK1
TASK ASSIGNMENT TASK COMPLETION
TASK2
…
…
TASK ASSIGNMENT TASK COMPLETION
RSU
TASKN TASK QUEUE
Service vehicles Task vehicles
Computing Resources
CPU SV7 SV8
SV6
SV1
SV3 SV2
DISK BANDWITH
SV5 SV4
Fig. 1. Vehicular cloud computing system overview.
overcome this problem, which allows one task to be offloaded to multiple vehicles and the task is executed as long as one of the vehicles executes the task and feeds back the output. In this way, the mobility and high volume of vehicles are, to some extent, exploited to provide low-latency services. Towards this end, the key questions include how to assign (replicate) tasks to minimize the deadline violation probability of tasks given stochastic vehicle movements, and how to analyze and optimize the performance. In the literature, there are some recent efforts dedicated to VCC systems. In [21] [22], the authors propose to exploit parked cars for task offloading and cooperative sensing. On the contrary, since parked cars can be regarded as part of the static cloud servers and the corresponding task offloading policy has been well investigated (see [23] [24] and references therein), we focus on utilizing vehicles on the move. The eVCC task scheduling and resource allocation problem are formulated based on a semi-Markov-decision-process (SMDP) approach in [6] [25]. However, the SMDP based approach suffers from the curse of dimensionality and hence cannot be applied in high vehicle density scenarios. A large body of work has focused on the task replication policy and performance analysis in, e.g., data retrieval, multi-server data processing systems [26]–[31]. The task replication technique is usually leveraged to deal with the straggler problem [29] [31], where the service process has a heavy-tail distribution. In [26], the authors focus on analyzing the performance of task replication policies based on the queuing theory. In [27] [30], the optimal replication degree, i.e., the number of replicas, is investigated. However, it is not applicable to the eVCC system where the servers (vehicles) are not always present. In [28], the optimal data retrieval replication policy is proved to be an shortest expected remaining processing time policy, which essentially schedules the task with the shortest time to go. Interestingly, although in different contexts, we will show that the optimal policy to minimize the deadline violation probability in VCC systems actually schedules the task with the longest time to go
(the task with least number of replicas has the longest expected time to go). In this paper, the optimal multi-task replication policy to minimize the deadline violation probability and its performance in the eVCC system are investigated. The main contributions include: • We first formulate the task assignment problem as a sampled-time MDP, by which the optimal policy and deadline violation probability can be computed by finitehorizon value iteration. This result is used as the benchmark to validate optimality. To conquer the computational complexity issue, we design the balanced-taskassignment (BETA) policy by which the resultant task assignment is as balanced as possible, and prove its optimality. • A tight upper bound for the deadline violation probability following the optimal BETA policy is derived in closedform, which implies that the optimum deadline violation probability follows the Rayleigh distribution approximately. We further apply the results from the vehicular traffic flow theory and demonstrate that there exists an interesting relationship between computation delay and vehicle density (or speed). A larger vehicle density leads to more vehicles executing the tasks, but meanwhile slows down the average vehicle speed due to limited human reaction time [32] which results in larger computation delay considering the task output has to be collected after offloaded. We show that the optimum vehicle density to minimize the deadline violation probability is in general lower, and the corresponding vehicle speed is higher, than the critical vehicle density and speed in traffic theory to maximize traffic efficiency, respectively. The remainder of the paper is organized as follow. In Section II, the system model is presented and the problem is formulated. In Section III, a sampled-time MDP based solution is presented and the results are utilized as a benchmark to validate policy optimality. In Section IV, the optimal BETA
3
policy is described and proved for optimality. In Section V, a closed-form performance bound is derived for the deadline violation probability given the optimal BETA policy and the optimum vehicle density is analyzed by applying the results from the vehicular traffic theory in Section VI. The simulation results are conveyed in Section VII. Finally, we conclude our work in Section VIII. Throughout the paper, we use boldface uppercase letters, boldface lowercase letters and lowercase letters to designate matrices, column vectors and scalars, respectively. Denote by E(·) as the expectation operation. Denote by 1(·) as the indicator function. The exponential distribution with mean of λ is denoted as Exp(λ), and exp(·) denotes the exponential function. The cardinality of a set is denoted by | · |. The probability of an event is denoted by Pr{·}. Denote by k mod N as the remainder of the Euclidean division of k by N. II. S YSTEM M ODEL AND P ROBLEM F ORMULATIONS We consider a Poisson vehicular network model with exponential vehicle-meeting time (PV-E). The following two model assumptions are made. 1) Poisson vehicle spatial distribution: The number of vehicles in the system at time t, denoted by Mt , follows the Poisson distribution1 . Denoting the length of roads in the system as S, the average vehicle density is λ, then λk S k e−λS . (1) k! The vehicle number is assumed to be the same during the task offloading since the deadline is usually much smaller than the vehicle number variation time in vehicular networks. 2) Homogeneous memory-less vehicle meeting: At any time and any RSU in the system, the time remaining before vehicle-m meets2 with the RSU follows an independent exponential distribution with mean µm = µ, ∀m,3 i.e., Pr {Mt = k} =
Pr{t < x} = 1 − e−µx .
(2)
Consider a task-RSU with N tasks that need to be offloaded and executed before deadline Dn , n ∈ {1, ..., N } where n is the task index. The task size is normalized such that each task can be offloaded to one vehicle at a time. In this paper, we consider the tasks are the with same type, i.e., the delay deadline is the same for all tasks and hence hereinafter Dn = D.4 The tasks are executed in the eVCC system as follows. For each task, it has to be first offloaded to a vehicle when the 1 The Poisson point process is widely-used to model the stochastic spatial geometry of, e.g., base stations and vehicles [33]. 2 In this paper, we define a meeting between a vehicle and an RSU as an event that a transmission (task offloading or output collection) is successful between them during the passage of the vehicle through the coverage area of the RSU. This definition excludes the encounters during which the transmissions are unsuccessful due to, e.g., bad wireless channel conditions, insufficient passage time and etc. 3 The exponential meeting time of vehicles is validated and widely-used to model the vehicle behavior [17], [18], [34], [35]. 4 The following MDP formulation can be immediately generalized to the multi-type task scenario, but the analysis for the optimal policy would be considerably more complicated and is left for future work.
vehicle meets with the task-RSU. After the meeting, the task is assumed to be successfully offloaded and the vehicle uses on-board computational resources to compute the task. After that, when the vehicle meets with any RSU in the system, the computing result is fed back to the task-RSU through backhaul and the task is considered as successfully executed. Moreover, we denote ( 1, if the task-n is executed before deadline (3) ωn = 0, otherwise In this paper, we focus on the scenario where the task computation time is negligible compared with vehicle meeting time as shown in [6]. We consider the task assignment problem that upon the meeting between a vehicle and the task-RSU, which task should be offloaded to the vehicle so as to minimize the deadline violation ratio, which is defined as pv = 1 −
N X ωn . N n=1
(4)
Moreover, in the eVCC system, the task service time fluctuates dramatically due to the unpredictable and diversified vehicle movements. Therefore, in order to counteract this so-called straggler effect [31], the tasks are replicated and executed independently. One task can be offloaded multiple times to different vehicles. Once one of the vehicles finishes the task (the output is fed back), the task is considered to be successfully executed. Since the SVs are out of coverage area when not meeting with RSUs in the eVCC system, they cannot be assigned new tasks even if the task at hand has been finished by other vehicles, until they meet with an RSU again. This is referred to as the non-purging model in [36]. In a purging model for e.g., multi-processor computing, the processor begins a new task as soon as the current task is finished (maybe by other processors). A. Task Execution Procedure in EVCC Systems The detailed task execution procedure in eVCC systems is described in the following. Task collection: Define the task execution interval as T . Within the interval, the task collection and assignment are executed simultaneously. The task requests from users are collected at each RSU. Denote the number of collected task requests at the t-th interval as Nt . Task Assignment: In the (t + 1)-th interval, the Nt tasks collected in the previous interval at each RSU are assigned based on the proposed algorithm described in Section IV. Specifically, upon the arrival of a vehicle, the n-th task is assigned based on the algorithm. If the assignment is successful subject to wireless transmission failure, the number of replications for the n-th task increases by one.5 Task Output Feedback: At the end of each interval, each RSU collects the task output feedback from assigned vehicles through backhaul links. The assigned vehicles may 5 Note that each RSU carries out the task assignment independently, which means that the recourse constraints of vehicle are ignored in this paper.
4
finish computing the tasks and feed back the task outputs when meeting with another RSU. In this case the output is transmitted to the original RSU through backhaul links. Afterwards, each RSU transmits the outputs to corresponding users and the task execution is finished. The above procedure then repeats itself. III. S AMPLED -T IME M ARKOV C HAIN BASED A PPROACH First, the continuous time model is converted to a discretetime approximation. Consider some given small increment of time δ, a sampled time approximation to the continuous time Poisson vehicle meeting for vehicle-m is a discrete Bernoulli process whose meeting probability is µm δ [37]. It is straightforward PKto derive that the meeting rate for a total of K vehicles is m=1 µm , and thus the meeting probability is Kµδ due to the second assumption in Section II. On account of the task replication, the system state space is characterized by S = {(r1 , ..., rN , d) |1 ≤ d ≤ D, ri ∈ Γ, ∀i = 1, ..., N } , (5) where d is the number of elapsed time slots, i.e., the computation delay. Note that the problem is with finite time horizon of 1 ≤ d ≤ D, d ∈ Z, for deadline violation consideration. The number of current replicas of task-n which are being processed in the eVCC system is denoted by rn , which is sufficient to describe the system state due to the memoryless vehicle meeting assumption. The time slot each replica is made is irrelevant based on the assumption. The state space is finite since the number of replicas cannot exceed the number of vehicles in the system. For ease of exposition, with slight abuse of notations we denote rn = F as that task-n is finished. The set Γ = {1, ..., M, F} (6) denotes the set of values of rn , ∀n. For each state with d = D, it denotes a terminal state. Since 1 ≤ d ≤ D and the terminal states are mutually exclusive, there exists a unique terminal state where the system terminates in. The reward is defined as the number of finished tasks at time D. Based on this definition and (4), maximizing the reward is equivalent to minimizing the deadline violation ratio. Also note that the initial state is always (7) s0 = (0, ..., 0, 0). | {z } N
It is without loss of generality to assume there is a vehicle meeting at the time slot zero, since it is equivalent to consider the delay deadline as D − D0 if the first time when a vehicle meets with the task-RSU is D0 . The system state is reviewed and the decisions are made at the meeting time6 between vehicles and the task-RSU, expect the time slot zero. Note that based on the discrete time conversion, a sufficiently small time increment δ is chosen such that at any given time slot the probability of multiple 6 Although the meeting is defined as an event that a successful transmission occurs during the passage of the vehicle through the coverage area of an RSU, the meeting time is defined as a time point instead of a period of time at which the transmission is completed.
vehicle meetings is negligible. It is easy to validate the fact that based on the system model and system state description in (5), the following Markovian properties are satisfied: If an action a is chosen in state x at a decision time slot, then the time till the next decision time slot, i.e., τ , is determined by the memory-less vehicle meetings with the RSU. Moreover, the system state at the next decision time slot st+τ depends on the task execution during time interval (t, t + τ ) which is also memory-less. Hence, the time till next decision time slot and the next system state depend only on the present state x and the chosen action a, i.e., Pr{st+τ = y|(st = x, at = a), ..., (s0 , a0 )} = Pr{st+τ = y|(st = x, at = a)}, Pr{τ = z|(st = x, at = a), ..., (s0 , a0 )} = Pr{τ = z|(st = x, at = a)}.
(8)
Also the reward incurred only depends on the terminal state, and thus independent of the past. A. Transition Probability At the decision time slot, given an action that the n-th task (unfinished) is offloaded to the meeting vehicle, the state transition probability is Pr{((ri |i ∈ M, i 6= n), rn , (rj |j ∈ / M, j 6= n), d) → ((F|i ∈ M, i 6= n), rn + 1, (rj |j ∈ / M, j 6= n)), d + τ } = ( Q Q τ −1 τ (1 − s) s n∈M pn (1 − pτm ), d + τ < D; Q / τ Q m∈M τ −1 (1 − s) pn m∈M (1 − pτm ), d + τ = D, n∈M / (9) where pi denotes the probability that the i-th task is not finished until the next decision time slot. The set M contains the tasks that have not been finished before time d and are finished during time slot d to the next decision time slot. It follows that pi = max{1 − qi , 1(ri = F)}, i ∈ {1, · · · , N }
(10)
qi = (ri + 1(i = n))Bµδ, i ∈ {1, · · · , N },
(11)
and where qi denotes the probability that at least one of the vehicles which are executing task-i meets with one of the B RSUs. Note that there are (ri + 1(i = n)) B different vehicleRSU combinations that can lead to the execution of the i-th task. Based on the homogeneous memory-less vehicle meeting assumption, the event that task-i is finished happens with a rate of (ri + 1(i = n)) Bµ, due to the fact that the distribution of the minimum of several exponentially distributed random variables is also exponential with a rate that is the summation of the rates of the variables. Denote the probability that a vehicle meets with the task-RSU as s. Based on the same arguments, s = M µδ, (12) where M denotes the number of vehicles in the system during this task computation. Based on the first assumption in Section
5
II, M is Poisson distributed but fixed during one task computation. Therefore, the time index is omitted for simplicity and its stochastic nature will be considered in the performance analysis in Section V. Note that δ is sufficiently small such that s is also small due to the discrete time approximation formulation. Assuming the current decision time slot is d, the probability that the next vehicle meets with the task-RSU at time d + τ is Pr{next meeting at time d + τ } = (1 − s)τ −1 s,
(13)
when d + τ < D. Since a finite horizon of 1 ≤ d ≤ D is sufficient, the transition probability to a terminal state, which is denoted by the time index of D, is Pr{no more meeting before deadline} = (1−s)D−d−1 . (14) We assume that the vehicle meetings are independent. Therefore, the task completion and the new vehicle meetings are independent. B. Finite-Horizon MDP-Based Solution The system reward is expressed by a terminal reward vector h, where the entry of h is a function of a terminal state st ∈ S, i.e., N X h(st ) = 1(st (i) = F), (15) i=1
which denotes the number of finished tasks before deadline. Consequently, the solution to the formulated MDP minimizes the deadline violation ratio in (4). Since this is a finite horizon MDP problem with finite state space, the backwards recursive iteration algorithm can be applied to find the optimal dynamic policy. Note that the optimal policy of a finite horizon problem is, in general, a dynamic policy, i.e., not a stationary policy as often observed in the infinite-horizon MDP, meaning that given the current system state, the policy also depends on the current time. Applying the backwards recursive iteration, we start from the terminal stage, denoted by stage K Jk (sk ) =
max
ak ∈{1,...,N }
E{Jk+1 (sk+1 ) + gk (sk )},
(16)
where JK (sK ) = gK (sK ) is the terminal reward. Based on [38], the optimal reward J ∗ (s0 ) = J0 (s0 ),
(17)
and the optimal dynamic policy is given by a∗ {a∗0 , · · · , a∗K−1 }, where a∗k ’s are derived from (16).
=
IV. O PTIMAL BALANCED -TASK -A SSIGNMENT P OLICY The finite-horizon MDP-based solution described above is guaranteed to find the optimum. However, as in many application scenarios, it suffers from the curse of dimensionality. One can easily find that the state space grows exponentially with the number of tasks. In what follows, we prove that the BETA policy, which is also stationary, is the optimal policy. First, the definition of the BETA policy is given.
Definition 1: The BETA policy is defined as at every decision time slot when a vehicle meets with the task-RSU, given the current task status (r1 , · · · , rN ), offload the n-th task to the vehicle, where n = arg min {ri |ri 6= F},
(18)
i∈{1,...,N }
and ties are broken arbitrarily. Remark 1: It is not difficult to figure out that the task status following the BETA policy is as balanced as possible, in the sense P that given the total number of computing vehicles as γ = ri 6=F ri , and the number of unfinished tasks as u = |{ri |ri 6= F}|, ri∗ ∈ {bγ/uc, dγ/ue}, i ∈ {1, · · · , N },
(19)
where ri∗ denotes the resultant task assignment by the BETA policy, and bxc and dxe denote the nearest integers below and above x, respectively. Theorem 1: Given the homogeneous memory-less vehicle meeting assumption (2), the BETA policy is optimal in minimizing the deadline violation ratio in (4). Proof: The proof is based on backwards induction on time. See Appendix A for details. Remark 2: A high-level intuition to explain the optimality of BETA policy is as follows. A stochastic coupling argument (the details are omitted for brevity) can be used to show that a necessary and sufficient condition for optimality is to avoid unnecessary service, which is defined as the event that a vehicle executes a task that has already been finished by vehicles before it. Based on this observation, the tasks should be assigned as balanced as possible, assuming the service occurs uniformly among tasks, to reduce the potential number of unnecessary services. The fundamental reason for the optimality of the BETA policy is that the tasks are treated equally, both from the deadline and the violation ratio perspectives. V. P ERFORMANCE A NALYSIS FOR BETA P OLICY The BETA policy is proved to be optimal, as long as the homogeneous memory-less vehicle meeting assumption described in Section II is upheld. The vehicle meeting process at the task-RSU is irrelevant, which can be observed by the proof of Theorem 1. Despite that the optimality of the BETA policy is shown, it is difficult to obtain a closedform formula for the performance, i.e., concretely the deadline violation probability (average violation ratio) of the system. The difficulty stems from deriving the static distribution of a high-dimensional Markov chain described by the formulated MDP given the BETA policy. To address this issue and gain more insights into the performance, we derive a closed-form upper bound for the deadline violation probability of the eVCC system, which is shown to be quite tight, by noticing the fact that the BETA policy evenly replicates the tasks and therefore the performance of the BETA policy should be similar with an equivalent system where there is only one task with one N -th of the vehicles. The following theorem formalizes this finding.
6
Theorem 2: The deadline violation probability of the system is upper bounded by λS λ1 Pr{tD > D} ≤ exp − 1+ e−λ2 D N λ2 − λ1 λ2 − e−λ1 D ,(20) λ2 − λ1 where λ2 = µB and λ1 = µ. Proof: See Appendix B. Corollary 1: (Short deadline regime) When D → 0, the task computation time lower bound derived in Theorem 2, i.e., tD , follows the Rayleigh distribution, i.e., λS
2
Pr{tD < D} = 1 − e− 2N Bµ
D2
,
(21)
and the deadline violation probability upper bound is 1 − Pr{tD < D} given deadline D. The mean computation delay is s Nπ . (22) E[tD ] = 2λBSµ2 Proof: See Appendix C. Remark 3: Since Corollary 1 is the Taylor expansion approximation of Theorem 2, the short deadline regime is there when λ1 D → 0, and λ2 D → 0, (23) which denote the average numbers of meetings between a vehicle and one and B RSUs before deadline, respectively. The numbers are usually small in typical scenarios, making the approximation accurate in most cases. Therefore, Corollary 1 is used in the following section for ease of exposition. VI. I MPLICATIONS ON ROAD T RAFFIC : O PTIMUM V EHICLE D ENSITY FOR E VCC In this section, some insights are given by combining the performance analysis of the optimal BETA policy and the traffic engineering theory [32]. It is observed that the average vehicle speed decreases with the vehicle density in the real world due to limited human reaction time [32]. Therefore, to minimize the deadline violation probability, the impacts of vehicle density and vehicle speed, which reflect on the number of SVs and the output collection rate respectively, need to be jointly considered to find the optimum tradeoff. Based on the traffic theory, there are three macroscopic parameters that describe the traffic flow state on the road: the average (space mean) speed of traffic stream V , the rate of flow F , and the vehicle density L. With the unified units, the fundamental equation of the speed-flow-density relationships is F = V L. (24) The general relationship of the basic parameters can be well illustrated by the approximate linear relationship between the speed of vehicles and the vehicle density [17], i.e., L V (L) = Vmax 1 − , (25) Lmax where Vmax is the speed limit, and Lmax is the traffic jam vehicle density. Later in the section, the linear relationship will
be generalized. In the traffic theory, there is a concept named critical vehicle density, which is defined as the optimum vehicle density given a stationary traffic flow that maximizes the traffic efficiency, i.e., the traffic flow rate. It is straightforward to see that the critical vehicle density to maximize the vehicle flow rate given (25) is Lmax . (26) 2 Essentially, it states the simple fact that when there is too much traffic wherein the vehicles cannot move or when there is too little traffic wherein the vehicles are too few, the traffic flow throughput is not satisfactory. The question is whether the critical vehicle density is also optimal for the eVCC system. Towards this end, we have the following theorem. Theorem 3: When the speed-density relationship, i.e., V (L), satisfies the following conditions, the optimum vehicle density for eVCC system L† is smaller than the critical vehicle density L∗ . 1) V (L) is monotonically non-increasing, and V (L) ≥ 0 for 0 ≤ L ≤ Lmax . 2) V (L) is a concave function of L, or it satisfies L∗ =
V (L) = G −
K X
ck Lαk ,
(27)
k=1
where αk ∈ (0, +∞)∪(−1, − 12 ), ck ≥ 0, ∀k and G ≥ 0. Proof: See Appendix D. Remark 4: Note that the first condition in Theorem 3 is almost always met in practice, due to the fact that people would drive more slowly with more vehicles on the road [41]. The second condition allows several well-recognized speeddensity models to be applicable, e.g., in [42, Chapter 12] and [40]. Remark 5: Theorem 3 establishes that under most circumstances, the optimum vehicle density for the eVCC system is smaller than the critical vehicle density. Therefore, the corresponding optimum speed comparison is the opposite, which indicates that vehicle mobility actually benefits the eVCC system more than the traditional traffic system. Corollary 2: In the short deadline regime, if the linear speed-density relationship is satisfied, the optimum vehicle density to minimize the average deadline violation probability is Lmax L† = . (28) 3 Proof: See Appendix E. Remark 6: This result corresponds to the critical vehicle density with linear speed-density model in (26). It demonstrates, in closed-form, the comparisons between the optimal vehicle densities in VCC systems and traffic systems. A. Asymptotic Analysis 1) Large City Regime: In the large city regime, the length of the road is approaching infinity, i.e., S → ∞. Since the number of available vehicles is increased whereas the distance of travelling is also increased, it is interesting to investigate the
7
Number of vehicles executing Task-2
Time slot 1
Time slot 15
20
20 Assign Task-1
15
15 Assign Task-2
10
5
10
5
5
10
15
20
5
Number of vehicles executing Task-1
10
15
20
Number of vehicles executing Task-1
Fig. 2. The optimal task assignment policy given by solving MDP-1. The total number of vehicles is M = 20, the number of RSUs is B = 5, the delay deadline is D = 20, and only two tasks are considered.
7= 7= 7= 7=
Average violation ratio
1
1 120 veh/s, value iteration for MDP-1 1 120 veh/s, BETA policy 1 60 veh/s, value iteration for MDP-1 1 60 veh/s, BETA policy
0.8
0.6
0.4
0.2
0 1
6
11
16
20
Deadline (s) Fig. 3. The optimal average violation ratio given by value iteration to solve MDP-1, in comparison with the achieved average violation ratio by the BETA policy. The total number of vehicles is M = 20, the number of RSUs is B = 5 and only two tasks are considered.
performance in the regime. Based on Theorem 2, it follows that when S → ∞, µ → 0, then the deadline violation probability approaches the following based on the linear speed-density relationship (25), LS S→∞ Bµ2 D2 P r(tD > D) −−−−→ exp − 2N ! 2 2 LVmax B L S→∞ 2 −−−−→ exp − 1− D . 2SN Lmax (29) It can be observed that as long as the RSU density, i.e., B/S, and the vehicle density remains unchanged, the performance is irrelevant with the road length. 2) High RSU Density Regime: When the RSU density goes to infinity, i.e., B/S → ∞, combining with Theorem 2, we
obtain LS −µD P r(tD > D) −−−−→ exp − 1−e . N B S →∞
(30)
If we continue to assume the short deadline regime as in Corollary 1, then (30) becomes B LVmax L S →∞, D→0 P r(tD > D) −−−−−−−−→ exp − 1− D . N Lmax (31) It turns out that the optimum vehicle density in this regime is identical with the critical vehicle density which maximizes the traffic flow rate. This is explained by the fact that when RSUs are everywhere, the tasks would be immediately finished after they are offloaded, and hence the task computation time is determined by the vehicle meeting rate at the task-RSU, which is equivalent with the traffic flow rate assuming homogeneous vehicle meetings. VII. N UMERICAL R ESULTS In this section, numerical results based on computer simulation are given to demonstrate the optimality of the BETA policy, to validate the tightness of the performance upper bound given in Theorem 2 and Corollary 1, and to show the impacts of several key system parameters. The vehicle meeting rate µ is given by (25), where the speed limit is Vmax = 100 km/h and the traffic jam vehicle density is Lmax = 140 veh/km assuming two lanes [32]. Fig. 2 and 3 are shown to demonstrate the optimality of the BETA policy. The optimal policy is obtained by value iteration to solve MDP-1. It is observed in Fig. 2 that the optimal policy has the same structure with the BETA policy, which always assigns the task with fewer replicas. It is worth mentioning that in general the optimal policy for a finite-horizon MDP is not stationary, in the sense that it may change as the time goes on. However, it is shown that the BETA policy is optimal at any time slot (time slot 1 and 15 are shown). Also note that the ties are broken arbitrarily, and therefore the policy on the diagonal can go either way. Fig. 3 shows that optimum value of the initial state equals the average violation ratio obtained
8
0.4
0.2
0 20
40
60
80
100
120
0.8
0.6
0.4
0.2
0.8
0.6
0.4 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.2
20
40
60
Deadline (s)
80
100
120
20
140
40
60
0.6
0.4 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.2
80
100
120
20
140
40
60
(b) L = 60 veh/km.
80
100
120
140
Deadline (s)
Deadline (s)
Deadline (s)
(a) L = 30 veh/km.
0.8
0
0
0
140
Deadline violation probability
0.6
Monte Carlo (BETA policy) Corollary 1 Theorem 2
Deadline violation probability
0.8
1
1
1 Monte Carlo (BETA policy) Corollary 1 Theorem 2
Deadline violation probability
Deadline violation probability
1
(c) L = 90 veh/km.
(d) L = 120 veh/km.
Fig. 4. The optimal average violation ratio versus the deadline given by Monte Carlo simulations based on the BETA policy, in comparison with the violation probability upper bound given in Theorem 2 and Corollary 1. The number of RSUs is B = 10, the road length is 10 km, the number of tasks is 50. 1
0.6
0.4 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.2
0
0.8
0.6
0.4
0.2
0 0
5
10
15
20
0
5
Number of RSUs
10
15
1
0.8
0.6
0.4 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.2
0
20
0.8
0.6 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.4
0.2
0 0
5
Number of RSUs
(a) L = 30 veh/km.
Deadline violation probability
0.8
1 Monte Carlo (BETA policy) Corollary 1 Theorem 2
Deadline violation probability
Deadline violation probability
Deadline violation probability
1
10
15
20
0
5
Number of RSUs
(b) L = 60 veh/km.
10
15
20
Number of RSUs
(c) L = 90 veh/km.
(d) L = 120 veh/km.
Fig. 5. The optimal average violation ratio versus the number of RSUs on the road given by Monte Carlo simulations based on the BETA policy, in comparison with the violation probability upper bound given in Theorem 2 and Corollary 1. The road length is 10 km, the number of tasks is 50, the deadline is 80 s. 1
0.6
0.4
0.2
0 20
40
60
80
Number of tasks
(a) L = 30 veh/km.
100
0.8
0.6
0.4
0.2
0 20
40
60
80
100
Number of tasks
(b) L = 60 veh/km.
Deadline violation probability
0.8
1
1 Monte Carlo (BETA policy) Corollary 1 Theorem 2
Deadline violation probability
Monte Carlo (BETA policy) Corollary 1 Theorem 2
Deadline violation probability
Deadline violation probability
1
0.8
0.6
0.4 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.2
0.8
0.6
0.4 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.2
0
0 20
40
60
80
Number of tasks
(c) L = 90 veh/km.
100
20
40
60
80
100
Number of tasks
(d) L = 120 veh/km.
Fig. 6. The optimal average violation ratio versus the number of tasks given by Monte Carlo simulations based on the BETA policy, in comparison with the violation probability upper bound given in Theorem 2 and Corollary 1. The road length is 10 km, the number of RSUs is 10, the deadline is 80 s.
by simulating the BETA policy, with two distinct departure rates. Fig. 4-8 are shown to reflect the impact of several key parameters, and to compare the simulation results with the closed-form expressions in Theorem 2 and Corollary 1. The simulation results are obtained by running the BETA policy for 1000 iterations and calculating the average, where in each iteration the number of vehicles is generated based on the Poisson distribution as assumed in Section II. In general, it is shown that the deadline violation probability performance can be well characterized by the closed-form upper bounds given in Theorem 2 and Corollary 1. In particular, the result in Corollary 1 is very close to the simulation results. The optimum vehicle density given in Proposition 2, which minimizes the deadline violation probability is validated in Fig. 7. It is shown that the promptness of the eVCC system with the optimum vehicle density by Proposition 2 is significantly better than the traditional critical vehicle density in the traffic engineering theory, demonstrating that vehicle mobility benefits the eVCC
system more compared with the traffic system. It also indicates that we need to rethink the desired traffic conditions in the future when vehicular network based applications such as eVCC, are widely implemented. In Fig. 8, the performance under a widely used speed-density model, which is validated based on real traffic measurements collected by using 3-h a.m. peak sensor data from a section of the M27 freeway in Southampton England [39]. Based on the model, the speeddensity relationship is characterized by " 1.964 # L , (32) V = 116.4 1 − 149.797 which satisfies the second condition in Theorem 3. A. Tradeoff between eVCC Efficiency and Traffic Efficiency Define the eVCC efficiency as the average number of executed tasks in unit time, i.e., N Pr{t < D} ηCE = , (33) T
9
33 Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.9 0.8 0.7
32.5
EVCC e/ciency (tasks/s)
Deadline violation probability
1
Critical Vehicle Density = 70
0.6 0.5 0.4 0.3
Achievable Region
31.5 31 30.5 30 29.5
20
40
60
80
100
120
Vehicle density (veh/km)
140
0.7
Tradeo, Region
Win-Win Region
29
0.2
0.75
0.8
0.85
0.9
0.95
Tra/c .ow rate (veh/s)
Fig. 7. The optimal average violation ratio versus the vehicle density on the road given by Monte Carlo simulations based on the BETA policy, in comparison with the violation probability upper bound given in Theorem 2 and Corollary 1. The road length is 10 km, the number of RSUs is 10, the number of tasks is 50, the deadline is 80 s.
Fig. 9. The tradeoff between eVCC efficiency and traffic efficiency. The road length is 10 km, the number of RSUs is 10, the number of tasks is 50, the deadline is 80 s.
VIII. C ONCLUSIONS
1
Deadline violation probability
32
Monte Carlo (BETA policy) Corollary 1 Theorem 2
0.8
Critical Vehicle Density = 86.3
Ly = 66:6 by Theorem 3
0.6
0.4
0.2
0 20
40
60
80
100
120
140
Vehicle density (veh/km) Fig. 8. Based on measurement validated model in [39] [40], the optimal average violation ratio versus the vehicle density on the road given by Monte Carlo simulations based on the BETA policy, in comparison with the violation probability upper bound given in Theorem 2 and Corollary 1. The road length is 10 km, the number of RSUs is 10, the number of tasks is 50, the deadline is 80 s.
where N/T denotes the number of generated tasks in unit time. The traffic efficiency is the traffic flow rate, i.e., the average number of vehicles passing through in unit time, which is ηTE = V L. (34) To study the tradeoff between ηCE and ηTE , the Fig. 9 is depicted. In the win-win region, the eVCC and traffic efficiency both go up with the increased vehicle density. It is observed that after some point, which actually corresponds to L† in Corollary 2, the eVCC efficiency drops with the traffic efficiency, which is denoted by the tradeoff region in Fig. 9. The finding indicates that the future intelligent transportation system should strike a good balance between traffic efficiency and eVCC efficiency.
In this paper, in order to minimize the deadline violation probability in the eVCC system, we design optimal multitask replication policy by finite horizon MDP. Further, it is proved that the optimal policy given homogeneous memoryless vehicle meeting and identical deadline of tasks is the BETA policy. The BETA policy always assigns the task with the least number of replicas, hence the longest expected time to go, which happens to be the opposite of several existing deadline-driven algorithms [28] [43] [44] for applications with different contexts. A tight, closed-form upper bound for the deadline violation probability by the BETA policy is derived which shows that the execution time is Rayleigh distributed with variance scaling with λV 2 . It is intriguing to find out that, combining with the traffic engineering theory, the optimum vehicle density to minimize the deadline violation probability is lower than the traditional critical vehicle density which maximizes the traffic flow rate. Given that the average vehicle speed decreases as the vehicle density grows, the result implies that the increased vehicle mobility benefits the eVCC system more compared to the traditional traffic system attributing to higher vehicle meeting rate, until the point that there are too few vehicles on the road due to decreased vehicle density. Such a tradeoff is thoroughly described by the presented analysis. A general and sufficient condition under which the optimum vehicle speed for the eVCC system is larger than that for the traffic system is given. Combining with the linear speed-density relationship and the asymptotic analysis, it is shown that the optimum vehicle density for eVCC is one-third of the traffic jam vehicle density. Simulation results show that the derived closed-form expressions can fully characterize the impacts of several key parameters. The future directions include extensions to non-exponential service time distributions and non-identical task deadlines. With task service time no longer being memory-less, the task with a longer waiting time currently should expect the
10
TASK ASSIGNMENT
‐ Set
CAR ARRIVAL
…
TASK COMPLETION
1
‐ Delete queue‐3; F; ‐ Set ‐
,
F
TASK QUEUEs
Fig. 10. Pictorial description of MDP-2.The discrete meeting probability is denoted by p, and the departure probability is denoted by q which are both i.i.d. over time and follows Bernoulli distribution.
waiting time to be shorter and even longer, with light-tail and heavy-tail service time distributions, respectively. The task replication policy is hence affected. When the tasks have different deadlines, it is natural that they should be treated differently, which deviates from the BETA policy. In either case, it is conjectured that the BETA policy can be extended by leveraging a utility function [45] to characterize those factors.
Proof: The sketch of the proof is as follows. First, we will derive an equivalent MDP which has the same optimal policy as the above-mentioned MDP. Then we will show that the BETA policy is optimal based on the equivalent MDP. Towards developing the equivalent MDP, we first prove the following lemma. Lemma 1: Define the total service rate under policy π as D−1 X
N X
ri,π (t)µB.
The system is still time-slotted as previously explained in Section II. After the task assignment, the vehicle is placed in one of the N queues (see Fig. 10 for an illustration), where each queue denotes a task with ri task replicas. The NP queues are served by a common server with a service rate N of i=1,ri (t)6=F ri (t)Bµ. Whenever a task completion occurs at time tm , the corresponding queue is deleted, and we set ri (t) = F, ∀t > tm . The total reward is defined as
(35)
t=0 i=1,ri,π (t)6=F
If R(π1 ) ≥ R(π2 ), the distribution of pv (π1 ) dominates that of pv (π2 ), i.e., Pr{pv (π1 ) < x} ≥ Pr{pv (π2 ) < x}.
Next, we develop an equivalent MDP (denoted by MDP-2), based on the above-mentioned MDP (denoted by MDP-1). Lemma 2: The optimal policy of MDP-1 is the same with the following MDP-2.
A PPENDIX A P ROOF OF T HEOREM 1
R(π) =
completion under π1 is higher than that under π2 , since the servers under π2 is a subset of π1 . This coupling argument results in the distribution dominance. The average results follow immediately. With this, we complete the proof.
D−1 X
E
N X
ri (t) .
(37)
t=0 i=1,ri (t)6=F
(36)
Consequently, the average violation ratio under π1 is no more than that under π2 . Proof: Lemma 1 simply implies that if a policy has a stronger serving ability (higher service rate), it has better violation ratio. To make it rigorous, a coupling argument is adopted. Consider a given total service rate of R(π). The service process is with a time varying service rate of ri (t)B, i ∈ {1, · · · , N }. ri (t) 6= F, and the serving time is from 0 to D. Given that the service process is memory-less and independent with the policy once the service rate is given. The considered service process is equivalent with a system with R(π) servers, and service rates are all 1, serving for one time slot. The equivalence stem from the fact that the distribution of the number of service tasks are the same. Due to the i.i.d. assumption, we can consider that the servers under π2 are a subset of the servers under π1 , given that R(π1 ) ≥ R(π2 ). Based on a coupling argument, assuming the occurrence of an arbitrary, and identical subset of servers with task completion in the time slot, the number of task
Proof: By construction of MDP-2 and Lemma 2, it is straightforward to see that the optimal policies of MDP-1 and MDP-2 are the same. Based on Lemma 2, in order to show that the BETA policy is optimal for MDP-1, it is sufficient to show that it is optimal for MDP-2. Towards this end, we will first show that the BETA policy is the myopic policy for MDP-2, meaning that the BETA policy maximizes the immediate reward for MDP2. Then, we will show that the myopic policy is indeed the optimal policy, and hence the BETA policy is optimal for MDP-1. Similar techniques have been used in [46], but in a different scenario. Define gt (r(t), a) as the immediate reward, given the queue status r(t), and the action of assigning to the a-th queue. Denote by c(t) = 1 as that there is a vehicle meeting with the task-RSU, and c(t) = 0 otherwise. Then, based on the law of total probability,
11
Based on the induction hypothesis in II), it follows that ˆ t+1,a (r, a)) am = arg max(W
E [g (r(t), a)] t N X = 1 −
pi
i=1,ri (t)6=F
+
pi
i=1,ri (t)6=F
a
= arg min[ra (t)].
ri (t) + c(t)
N X
With this, we establish the fact that the BETA policy is optimal at time t, given the induction hypothesis in I) and II). To show II) is also valid at time t, it follows that given ri ≤ rj and m = arg min1≤n≤N rn (t), ∀i, j ∈ {1, · · · , N }.
rn (t) + c(t)
n=1,rn (t)6=F
−ri (t) − 1(a = i)c(t)) =
N X i=1,ri (t)6=F
N X
pi (ri (t) + 1(a = i)c(t)),
i=1,ri (t)6=F
(38) where pi denotes the probability that a task which belongs to queue-n is executed in this time slot. pi = (ri (t) + 1(i = a)c(t))µBδ, ∀1 ≤ i ≤ N, ri (t) 6= F. (39) After a task completion from queue-n, the queue-n is deleted. Based on (38) and (39), it is easy to see that the myopic policy which maximizes E[gt (r(t), a)] is to assign the task-nm to the vehicle, where nm =
arg min
ri (t).
(40)
i∈{1,··· ,N },ri (t)6=F
This coincides with the BETA policy. In what follows, we will show the myopic, i.e., BETA policy, is optimal. The proof is based on backwards induction on time t. Define the total reward from time t on based on the BETA policy given the current r(t) as Wt (r(t)). The following statements will be shown to be valid based on backwards induction. I) Wt (r(t)) is the optimal total reward from t on, i.e., the BETA policy is optimal. II) For each t ≥ 0, if ri (t) ≤ rj (t) Wt (r(t) with ri (t) = F) ≥ Wt (r(t) with rj (t) = F). (41) For notation simplicity, denote Wt (r(t) with ri (t) = F) ˆ t,i (r(t)). Given that I) and II) are both valid from time as W t + 1 to D. We want to show that they are also valid at time t. Define the total reward from time t on, given the action a, and followed by actions based on the BETA policy from t + 1 on, as qt (r(t), a). Then I) is equivalent to Wt (r(t)) = max qt (r(t), a), a
(42)
where qt (r(t), a) is given in (43) at the top of next page. It follows that am = arg max qt (r, a) a
ˆ t+1,a (r(t))). = arg max(−2ra (t) + W a
ˆ t,i (r(t)) − W ˆ t,j (r(t)) W = rj − ri + (rj + 1(j = m)c(t))2 − (ri + 1(i = m)c(t))2
ri (t) + c(t)
−
(45)
a
i=1,ri (t)6=F
N X
N X
(46) ˆ ˆ +pj Wt+1,i (r(t)) − pi Wt+1,j (r(t)) N X ˆ t+1,i (r(t)) − W ˆ t+1,j (r(t)) (47) + W i=1,ri (t)6=F
+
X
ˆ t+1,n,i (r(t)) − pn W
n6=i
X
ˆ t+1,n,j (r(t)). pn W
(48)
n6=j
It is easy to see that (46) ≥ 0, since rj ≥ ri . To show (47)≥ 0, two cases are considered. If ri = rj , then (47) is trivially true. Otherwise given rj ≥ ri , ri + 1 ≤ rj , then pj = (rj + 1(mj = j)c(t))µBδ ≥ (ri + 1)µBδ ≥ (ri + 1(mi = i)c(t))µBδ = pi ,
(49)
where mj = arg min rn (t), n6=j
mi = arg min rn (t).
(50)
n6=i
Combining with the induction hypothesis II), we obtain (47)≥ 0. To show that (48)≥ 0, let us consider the following four cases. Case A: mi 6= j, mj 6= i. Then, mi = mj . ˆ t+1,i,j (r(t)) (48) = rj (t)µBδ W ˆ −ri (t)µBδ W (r(t)) t+1,i,j X ˆ t+1,n,i (r(t)) − W ˆ t+1,n,j (r(t)) + pn W n6=i,j
≥ 0,
(51)
based on rj (t) ≥ ri (t) and induction hypothesis II). Case B: mi = j, mj 6= i. Then, ri (t) ≤ rj (t) = rmi (t) ≤ rn , ∀n 6= i, j. It follows that mj = i, and this case is infeasible. Case C: mi 6= j, mj = i. ˆ t+1,m ,j (r(t)) (48) = (rmi (t) + c(t))µBδ W i ˆ t+1,i,j (r(t)) +rj (t)µBδ W ˆ t+1,i,j (r(t)) −(ri (t) + c(t))µBδ W ˆ −rm (t)µBδ Wt+1,m ,j (r(t)) ≥ 0, i
(44)
i
based on the same technique to prove (47)≥ 0.
(52)
12
N X
qt (r(t), a) = E [gt (r(t), a)] +
pi Wt+1 (r(t)) +
i=1,ri (t)6=F N X
=
ri (t) + c(t) −
i=1,ri (t)6=F N X
+
N X
ˆ t+1,i (r(t)) pi W
i=1,ri (t)6=F N X
(ri (t) + 1(a = i)c(t))2 µBδ +
i=1,ri (t)6=F
N X
pi Wt+1 (r(t))
i=1,ri (t)6=F
ˆ t+1,i (r(t)). (ri (t) + 1(a = i)c(t))µBδ W
(43)
i=1,ri (t)6=F
Case D: mi = j, mj = i. ˆ t+1,i,j (r(t)) (48) = (rj (t) + c(t))µBδ W ˆ t+1,i,j (r(t)) ≥ 0. −(ri (t) + c(t))µBδ W
(53)
With this, we complete the induction proof, and hence the theorem is proved.
denotes the meeting delay distribution, ta and ts are independent. The natural way to establish the distribution of the sum of two independent random variables is to leverage the characteristic function (CF). Given the CF of a random variable x ∼ Exp(λ) as ϕx (z) = λ(λ − jz)−1 ,
A PPENDIX B P ROOF OF T HEOREM 2 Proof: We prove the theorem by first showing that the deadline violation probability is upper bounded by a system with one task and λS/N vehicle meeting rate. Then the performance of the task system is derived in a closed-form. Lemma 3: The deadline violation probability is upper bound by a system with one task and a vehicle meeting rate of λSµ/N . Proof: Consider a round-robin task assignment policy which assigns the (k mod N )-th task to the k-th meeting vehicle, even if the task has been finished. Since the division of a Poisson process is also a Poisson process, the resultant meeting rate in MDP-2 for the k-th queue is λS/N . It is straightforward to see the performance of the BETA policy is upper bounded by this round-robin policy by noticing that the BETA policy is the same with the round-robin policy, except that it does not assign finished tasks. Lemma 4: For a system with one task and a vehicle meeting rate of λSµ/N , the deadline violation probability is identical to a system with λS/N servers each of which has an i.i.d. service time distribution of λ1 λ2 F (x) = 1 + e−λ2 x − e−λ1 x . (54) λ2 − λ1 λ2 − λ1 The task is completed once one of the servers finishes. Proof: Since there is only one task, all the meeting vehicles are carrying the same task. The total number of vehicles is λS/N (ignoring the remainder of division), and each vehicle needs an extra service time of ts after meeting at the task-RSU, where ts ∼ Exp(Bµ).
−1 here, and the CF of t is hence
ϕt (z) = ϕta (z) · ϕts (z) −1 = λ1 λ1 − jz)−1 λ2 (λ2 − jz 1 λ1 λ2 1 − = λ1 − jz λ2 − jz λ2 − λ1 λ2 −1 = λ1 (λ1 − jz) · λ2 − λ1 λ1 +λ2 (λ2 − jz)−1 · . λ1 − λ2
(59)
It follows that the density function of t is f (t) =
λ2 λ1 λ1 e−λ1 t + λ2 e−λ2 t , λ2 − λ1 λ1 − λ2
(60)
and hence the distribution function follows immediately. Based on Lemma 3 and Lemma 4, the violation happens when all servers fail to execute the task on time, i.e., tm ,
min
i∈{1,··· ,M }
[ti ] > D,
(61)
where M is a Poisson distributed random variable with mean of λS/N to follow the assumption 1) in Section II. The deadline violation probability follows, which reads Pr{tm > D} =
∞ X
Pr{tm > D|M = m} Pr{M = m}.
(55)
(56)
where ta ∼ Exp(µ)
√
m=0
Therefore, the service process is equivalent to one with λS/N servers, and each with a service time. t = ta + ts ,
where j =
(58)
(57)
(62) To proceed, we have the following lemma. Lemma 5: Given a distribution function F (x), v(x) ,
∞ X 1 k −α α e (1 − F (x))k = e−αF (x) . k!
k=0
(63)
13
Proof: v(x) = e−α +
∞ X 1 −α k e α (1 − F (x))k , k!
(64)
k=1 ∞
X 1 dv(x) dF (x) =− e−α αk (1 − F (x))k−1 dx k! dx k=1 ∞ X
= −α
k=0
V (L) = g − cLα ,
dF (x) 1 −α k e α (1 − F (x))k k! dx
dF (x) = −α v(x). dx
(65)
Therefore, dv(x) = −αdF (x), v(x) v(x) = Ce−αF (x) .
(66) (67)
Since when x = 0, F (0) = 0, then v(0) = 1, C = 1, and v(x) = e−αF (x) . Based on Lemma 5, Pr{tm > D} = e
− λS N F (x)
,
It is easy to find out that if V (L) is concave, then V 0 (L) is nonincreasing, and therefore L∗ ≥ L† . Otherwise if V (L) satisfies the condition in (27), wherein V (L) has a polynomial form, it is sufficient to show for each monomial term, L∗ ≥ L† . Specifically, we consider (75)
where α ∈ (0, +∞) ∪ (−1, − 21 ), c ≥ 0, ∀k and g ≥ 0. It follows based on the KKT condition that α1 g ∗ , (76) L = c(1 + α) α1 g † L = . (77) c(1 + 2α) Hence L∗ ≥ L† is equivalent to gα ≥ 0. c(1 + 2α)(1 + α)
(78)
The condition in (27) follows immediately, which concludes the proof.
(68) A PPENDIX E P ROOF OF C OROLLARY 2
where F (x) is given in (54), which concludes the proof. A PPENDIX C P ROOF OF C OROLLARY 1 Proof: Consider the Taylor series 1 e−λx = 1 − λx + λ2 x2 + o(x2 ), (69) 2 where o(xn ) denotes higher order infinitesimals of xn . When λ1 D and λ2 D approach zeros, the upper bound in Theorem 2 is asymptotically λS λ1 λ2 exp − 1+ e−λ2 D − e−λ1 D N λ2 − λ1 λ2 − λ1 λ1 1 λS D→0 1+ 1 − λ2 x + λ22 D2 −−−→ exp − N λ2 − λ1 2 λ2 1 2 2 2 − 1 − λ1 D + λ1 D + o(D ) λ2 − λ1 2 λS 2 2 = exp − λ1 λ2 D + o(D ) . (70) 2N
In our model, the vehicle density is λ. The rate of traffic flow is the reciprocal of the inter-vehicle-meeting time at the task-RSU, i.e., 1 F =E = λSµ, (79) min [t1 , ..., tM ]
The conclusion follows immediately by noticing λ1 = µ and λ2 = Bµ, which completes the proof.
L† = arg max [λµ2 ].
(71) (72)
0≤L≤Lmax
It is obvious that both L∗ and L† are positive. If L∗ = Lmax , then L† ≤ L∗ is trivially true. Otherwise, we have, based on the first-order Karush-Kuhn-Tucker (KKT) condition, V (L∗ ) + L∗ V 0 (L∗ ) = 0, †
†
0
†
V (L ) + 2L V (L ) = 0.
(80)
(81)
Given that in the short deadline regime, the deadline violation probability follows the Rayleigh distribution given in Corollary 1, the optimum vehicle density is therefore (82)
0≤λ≤Lmax
R EFERENCES
0≤L≤Lmax
L† = arg max [V 2 (L)L].
F = Sµ. λ Combining with (25), we obtain Vmax λ µ= 1− . S Lmax V =
Combining with (81), the conclusion of the proposition follows immediately based on the Cauchy-Schwarz inequality.
A PPENDIX D P ROOF OF T HEOREM 3 Proof: First, it is easy to see that L∗ = arg max [V (L)L],
where ti denotes the inter-meeting time of the i-th vehicle. Therefore, the average speed is
(73) (74)
[1] J. B. Kenney, “Dedicated short-range communications (DSRC) standards in the united states,” Proceedings of the IEEE, vol. 99, pp. 1162–1182, Jul 2011. [2] S. Chen, J. Hu, Y. Shi, and L. Zhao, “LTE-V: A TD-LTE-based V2X solution for future vehicular network,” IEEE Internet Things J., vol. 3, pp. 997–1005, Dec 2016. [3] C. X. Wang, F. Haider, X. Gao, X. H. You, Y. Yang, D. Yuan, H. M. Aggoune, H. Haas, S. Fletcher, and E. Hepsaydir, “Cellular architecture and key technologies for 5G wireless communication networks,” IEEE Commun. Mag., vol. 52, pp. 122–130, February 2014. [4] X. Hou, Y. Li, M. Chen, D. Wu, D. Jin, and S. Chen, “Vehicular fog computing: A viewpoint of vehicles as the infrastructures,” IEEE Trans. Veh. Tech., vol. 65, pp. 3860–3873, Jun 2016.
14
[5] C. C. Lin, D. J. Deng, and C. C. Yao, “Resource allocation in vehicular cloud computing systems with heterogeneous vehicles and roadside units,” IEEE Internet Things J., vol. PP, no. 99, pp. 1–1, 2017. [6] K. Zheng, H. Meng, P. Chatzimisios, L. Lei, and X. Shen, “An SMDPbased resource allocation in vehicular cloud computing systems,” IEEE Trans. Ind. Electron., vol. 62, pp. 7920–7928, Dec 2015. [7] I. Jang, S. Choo, M. Kim, S. Pack, and G. Dan, “The software-defined vehicular cloud: A new level of sharing the road,” IEEE Veh. Tech. Mag., vol. 12, pp. 78–88, June 2017. [8] S. Bitam, A. Mellouk, and S. Zeadally, “VANET-cloud: a generic cloud computing model for vehicular Ad Hoc networks,” IEEE Wireless Commun., vol. 22, pp. 96–102, Feb. 2015. [9] S. Abdelhamid, H. S. Hassanein, and G. Takahara, “Vehicle as a resource (VaaR),” IEEE Network, vol. 29, pp. 12–17, Jan 2015. [10] M. Gerla, “Vehicular cloud computing,” in The 11th Annual Mediterranean Ad Hoc Networking Workshop (Med-Hoc-Net), pp. 152–155, Jun 2012. [11] E. Lee, E. K. Lee, M. Gerla, and S. Y. Oh, “Vehicular cloud networking: architecture and design principles,” IEEE Commun. Mag., vol. 52, pp. 148–155, February 2014. [12] M. Whaiduzzaman, M. Sookhak, A. Gani, and R. Buyya, “A survey on vehicular cloud computing,” J. Netw. Comput. Applicat., vol. 40, pp. 325 – 344, 2014. [13] R. Hussain, J. Son, H. Eun, S. Kim, and H. Oh, “Rethinking vehicular communications: Merging VANET with cloud computing,” in 4th IEEE Int. Conf. Cloud Comput. Technol. Sci., pp. 606–609, Dec 2012. [14] S. Olariu, I. Khalil, and M. Abuelela, “Taking VANET to the clouds,” Int. J. Pervasive Comput. Commun., vol. 7, no. 1, pp. 7–21, 2011. [15] K. Mershad and H. Artail, “Finding a STAR in a vehicular cloud,” IEEE Intell. Transp. Syst. Mag., vol. 5, pp. 55–68, Summer 2013. [16] S. Han, C. l. I, Z. Xu, and C. Rowell, “Large-scale antenna systems with hybrid analog and digital beamforming for millimeter wave 5G,” IEEE Commun. Mag., vol. 53, pp. 186–194, Jan. 2015. [17] S. Yousefi, E. Altman, R. El-Azouzi, and M. Fathy, “Analytical model for connectivity in vehicular Ad Hoc networks,” IEEE Trans. Veh. Tech., vol. 57, pp. 3341–3356, Nov 2008. [18] L. Zhou, Y. Zhang, K. Song, W. Jing, and A. V. Vasilakos, “Distributed media services in P2P-based vehicular networks,” IEEE Trans. Veh. Tech., vol. 60, pp. 692–703, Feb 2011. [19] L. Zhou, R. Q. Hu, Y. Qian, and H. H. Chen, “Energy-spectrum efficiency tradeoff for video streaming over mobile Ad Hoc networks,” IEEE J. Select. Areas Commun., vol. 31, pp. 981–991, May 2013. [20] L. Zhou, “Mobile device-to-device video distribution: Theory and application,” ACM Trans. Multimedia Comput. Commun. Appl., vol. 12, pp. 38:1–38:23, Mar. 2016. [21] D. Eckhoff, C. Sommer, R. German, and F. Dressler, “Cooperative awareness at low vehicle densities: How parked cars can help see through buildings,” in Proceedings IEEE GLOBECOM, pp. 1–6, Dec 2011. [22] N. Liu, M. Liu, W. Lou, G. Chen, and J. Cao, “PVA in VANETs: Stopped cars are not silent,” in Proceedings IEEE INFOCOM, pp. 431–435, Apr 2011. [23] K. Kumar and Y. H. Lu, “Cloud computing for mobile users: Can offloading computation save energy?,” Computer, vol. 43, pp. 51–56, Apr 2010. [24] C. You, K. Huang, H. Chae, and B. H. Kim, “Energy-efficient resource allocation for mobile-edge computation offloading,” IEEE Trans. Wireless Commun., vol. 16, pp. 1397–1411, Mar 2017. [25] H. Liang, L. X. Cai, D. Huang, X. Shen, and D. Peng, “An SMDPbased service model for inter-domain resource allocation in mobile cloud networks,” IEEE Trans. Veh. Tech., vol. 61, pp. 2222–2232, Jun 2012. [26] K. Gardner, S. Zbarsky, S. Doroudi, M. Harchol-Balter, and E. Hyytia, “Reducing latency via redundant requests: Exact analysis,” SIGMETRICS Perform. Eval. Rev., vol. 43, pp. 347–360, Jun 2015. [27] N. B. Shah, K. Lee, and K. Ramchandran, “When do redundant requests reduce latency?,” IEEE Trans. Commun., vol. 64, pp. 715–722, Feb 2016. [28] Y. Sun, Z. Zheng, C. E. Koksal, K. H. Kim, and N. B. Shroff, “Provably delay efficient data retrieving in storage clouds,” in Proceedings IEEE INFOCOM, pp. 585–593, Apr 2015. [29] D. Wang, G. Joshi, and G. Wornell, “Using straggler replication to reduce latency in large-scale parallel computing,” SIGMETRICS Perform. Eval. Rev., vol. 43, pp. 7–11, Nov 2015. [30] Y. Kim, R. Righter, and R. Wolff, “Job replication on multi-server systems,” Adv. in Appl. Probab., vol. 41, no. 2, pp. 546–575, 2009. [31] J. Dean and L. A. Barroso, “The tail at scale,” ACM Commun., vol. 56, pp. 74–80, Feb 2013. [32] R. P. Roess, E. S. Prassas, and W. R. McShane, Traffic engineering. Prentice Hall, 2011.
[33] S. N. Chiu, D. Stoyan, W. S. Kendall, and J. Mecke, Stochastic geometry and its applications. John Wiley & Sons, 2013. [34] V. Chandrasekhar, J. Andrews, and A. Gatherer, “Femtocell networks: a survey,” IEEE Commun. Mag., vol. 46, pp. 59–67, Sep. 2008. [35] A. O. Allen, Probability, statistics, and queueing theory. Academic Press, 2014. [36] F. Poloczek and F. Ciucu, “Contrasting effects of replication in parallel systems: From overload to underload and back,” arXiv preprint arXiv:1602.07978, 2016. [37] R. G. Gallager, Discrete stochastic processes, vol. 321. Springer Science & Business Media, 2012. [38] D. P. Bertsekas, Dynamic programming and optimal control, vol. 1. Athena scientific Belmont, MA, 1995. [39] T. Toledo, M. Ben-Akiva, D. Darda, M. Jha, and H. Koutsopoulos, “Calibration of microscopic traffic simulation models with aggregate data,” Transportation Research Record: Journal of the Transportation Research Board, vol. 1876, pp. 10–19, 2004. [40] L. A. Pipes, “Car following models and the fundamental diagram of road traffic,” Transportation Research, vol. 1, no. 1, pp. 21 – 29, 1967. [41] M. Van Aerde, “Single regime speed-flow-density relationship for congested and uncongested highways,” in 74th TRB Annual Conference, 1995. [42] D. R. Drew, Traffic flow theory and control. McGraw-Hill Book Company, 1968. [43] X. Guo, R. Singh, P. Kumar, and Z. Niu, “A high reliability asymptotic approach for packet inter-delivery time optimization in cyber-physical systems,” in MobiHoc ’15, (New York, NY, USA), pp. 197–206, ACM, 2015. [44] L. Schrage, “A proof of the optimality of the shortest remaining processing time discipline,” Operations Research, vol. 16, no. 3, pp. 687–690, 1968. [45] I.-H. Hou and P. R. Kumar, “Queueing systems with hard delay constraints: a framework for real-time communication over unreliable wireless channels,” Queueing Systems, vol. 71, pp. 151–177, Jun 2012. [46] Q. Zhao, B. Krishnamachari, and K. Liu, “On myopic sensing for multichannel opportunistic access: structure, optimality, and performance,” IEEE Trans. Wireless Commun., vol. 7, pp. 5431–5440, Dec 2008.