Research Article

A Safety Resource Allocation Mechanism against Connection Fault for Vehicular Cloud Computing

Algorithm 1

The PRMA.
Input the computation cost of tasks, communication cost of edges with average value and the Deadline of this service.
Calculate LFT of each task, starting from the exit task.
Compute for each task by DAG, starting from the exit task.
Sort the tasks in a sequence by non-increasing order of value.
  For each task in the sequence order sorted at step   do
     For in the condition of each vehicle (the optimized vehicle and two other random vehicles and ) chosen at the last loop do
      Calculate the AFT of this task allocated to every available vehicle in the VC.
       If AFT of task on one vehicle smaller than the LFT.
         Calculate for the vehicle in the condition that the last loop chosen vehicle is , or .
         End If
     End For
    Choose the vehicle which has the minimum probability to occur connection fault at that moment from all the vehicles as the branches of three vehicles chosen from last loop and other two random vehicles and as the allocation destination of this task.
  End For