# Multi-Tier Cellular Handover with Multi-Access Edge Computing and Deep Learning
## 2 Preliminaries
### Multi-Tier Intra-RAT Handover
#### 2.1.1 3 GPP Defined Logic and Procedure  
This section overviews the handover logic and procedure defined in 3 GPP TSs 38.331 [8] and 38.300 [3], respectively. Before detailing these steps, an understanding of how a UE switches between idle and connected states are described below:  
* _Idle_: A UE is in the idle state when its context is known to the 5 GC but does not have an established connection to a gNB. In this state, the UE listens and responds to broadcasted messages from gNBs. It performs measurements and cell reselection methods when it is ready to connect to a gNB;
* _Connected_: A UE is in the connected state when its context is known to both 5 GC and gNB. In this state, the UE provides periodic measurement reports with channel quality information (CQI). Data are regularly transferred in this phase.  
At set timestamps during the connected state, the UE sends measurement reports for the AMF to assess whether a handover is necessary. Usually, it is based on the UE's received signal strength (RSS) for its associated BS, although sometimes other factors such as loading are considered. The way the AMF decides whether a handover is to occur is decided based on an event-triggered system. Events are triggered by the logic described in [8]. There are various event triggers, and their parameters are specified in Tables 1 and 2. Events A1 through A6 are only considered as they relate to intra-RAT handover; other events such as B1 are not relevant to this work as they relate to inter-RAT handover.  
Each event has an entry and leaving condition. If the entry condition is satisfied for longer than a certain period, called the time to trigger (TTT), the BS will initiate the handover procedure to the desired cell. However, if the UE's reference signal received power (RSRP) drops below the leaving condition or does not meet the entry condition after the TTT, the UE remains connected to the current BS, as the desired BS no longer meets the criteria.  
This paper focuses on implementing two of the handover events, A1 and A3. Other events are not considered as there will be unnecessary complexities introduced that will diverge from the scope of this work. For example, an A6 handover would require a form of dual connectivity for the user to perform and assess this event correctly. After the UE has met the entry condition for the duration of the TTT interval, a handover procedure is initiated. There are three phases [3]:  
* _Preparation_: Upon deciding to handover, the source gNB sends a handover request to target gNB, which in turn processes the request and completes the admission control by returning a handover request acknowledgment to the source gNB;
* _Execution_: Upon being notified by source gNB, UE begins to detach from source gNB and synchronizes to target gNB. Simultaneously, source gNB executes a sequence number (SN) status transfer and delivers buffered and new data from UPF to target gNB;
* _Completion_: This phase begins with a path switch requested by the target gNB, which triggers the 5 GC to switch the path of the UE's data to the target gNB via the UPF. Then UPF sends the end marker for source gNB via the AMF, which in turn sends a path switch acknowledgment. Finally, the target gNB sends a message to source gNB to release the context of the UE, completing the handover procedure.