Research Article

A Migration Method for Vehicle Mobility Services Based on Road Segmentation Markov Model

Algorithm 1

Service migration algorithm based on -learning (MS-Q).
Input: System state set S, System action set A
Output: Q-table
1. Initialize Q-table
2. for episode:
3. Initialization state s
4. for episode <thre episode++.
5.  Read the value from the Q-table and select action a with the ε-greedy policy
6.  Get a new state from action a, get instant reward through reward function r
7.  Update Q-table
8.  Update status
9. end for
10.end for