## 5 Using MEC to Augment the Computing Capabilities of Vehicles
### Resource Allocation
The authors investigate the advantages of modifying processing configurations that can effectively regulate the data drop rate in order to handle the latency for mission-critical operations. Next, taking into account the processing capacity of the network, an online method allocates resources adaptively and enables the network to minimize the loss in processing quality while ensuring the completion of the task on time. To achieve this objective, the proposed approach can dynamically adjust and manage the offloading of the tasks, channel resources, processing method, and data loss. To reduce the system latency for SDN-enabled IoV, researchers optimize the offloading mechanism, transmission ratio, and resource allocation together [122]. Moreover, the impacts of varying task complexity on offloading and computation are also taken into account in their methodology. The authors devise an SDN model which divides tasks according to two-plane communication. Also, they use Particle Swarm Optimization (PSO) to enhance the total throughput. This method works by breaking the issue down into three smaller issues: the offloading decision of cars, the distribution of resources by RSUs, and the proportion of offloading for vehicles. It solves the multivehicle and multi-MEC offloading scenario effectively and minimizes the complexity of the problem. To increase system performance, the local offloading mechanism and its rate and the method of assigning resources are all collaboratively adjusted. The SDN controller broadcasts a global status report including task urgency, available resources, and Channel Status Information (CSI). When SDN obtains the vehicle's demand for resource offloading through the data layer, it seeks out the best solution (containing resource allocation and offloading strategy) at the control layer, and then transmits control commands. Simulation results show that the proposed mechanism achieves optimal performance. In order to enhance urban communication and computing capacities, it has recently been proposed that cars with an abundance of unused computing capabilities be organized as a fog server [123]. This creates a new computing paradigm called Vehicular Fog-Edge Computing (VFEC). Authors model the VFEC scenario as a multilevel Stackelberg game with an incentive system. RSU leases computing resources from cars in a long-period market. The implementation of the Pareto optimal configuration is hampered in this procedure by using collected data over the RSU. Also, an incentive system is created based on contract theory to address this issue. The contract helps represent different vehicle types and improves benefits for both parties. Meanwhile, the communication between the RSU, MEC server, and users forms a short-term market with interactions like pricing and resource decisions, simulated using the Stackelberg game. Unlike iterative techniques frequently employed in some auctions and non-cooperative games, the equilibrium of the Stackelberg game can be found in a single stage of processing. The architecture of the model is shown in Figure 9.  
The authors of [124] consider the diverse conditions encountered by vehicles while on the move in a real-world scenario. They propose a comprehensive architecture for dynamic resource management in mobile networks of vehicles. The architecture models the dynamic vehicular environment by a collection of connected Markov Decision Processes (MDPs), employs a learning method, and utilizes the advantages of an actor-critic algorithm to allocate resources for vehicles. Their algorithm has a distinct manner in comparison with [125]. Their suggested learning model can adjust to a new environment when the higher network layer is fine-tuned. This makes the learning approach more adaptable, efficient in using samples, and, overall, more effective. In ref. [126], authors investigate capacity planning and service transfer in MEC. Their work seeks to minimize delay by formulating the allocation problem as an MINLP, factoring in user mobility and limitations in MEC server resources.