## 3 The Proposed HSTMAC Framework and System Model
### Frame Structure of the Proposed HSTMAC Protocol  
As shown in Figure 2, in HSTMAC the BS schedules resources on a cycle-by-cycle basis in time domain and each access cycle spans \(\tau\) ms.  
In order to utilize the resources more efficiently, the HSTMAC protocol mainly divides the reserved resources into three sections: broadcast period (BP) for essential downlink control information, S-ALOHA period (SP) for M2M traffic with small size packets and TDMA period (TP) for H2H traffic with large size packets. The TDMA period is further split into random access period (RAP) for contention based random access and data transmission period (DTP) for contention free packet transmission. The optimal tradeoff between RAP and DTP is made according to Equation (4).  
In the broadcast period of each cycle, BS estimates the number of active devices based on the obtained statistics and calculates the optimal resource allocation and ACB parameters for M2M and H2H traffics respectively. Then the BS broadcasts a notification message which contains these parameters to all the devices for synchronization. In this paper, we mainly focus on the uplink transmission in a single cellular cell. Let \(L\) denote the reserved uplink resource blocks in each cycle and let \(L_{SPi}\), \(L_{TPi}\), \(L_{RAPi}\), \(L_{DTPi}\) denote the allocated RBs for the corresponding part in the \(i\)-th cycle, we can have:  
\[\begin{array}{ll}L&=L_{SP,i}+L_{TP,i}\\ &=L_{SP,i}+L_{RAP,i}+L_{DTP,i}\end{array} \tag{10}\]  
In order to make the analysis more tractable, we assume that all the active devices, new and backlog, arrive at the beginning of a cycle and complete the transmission procedure in current cycle (no matter success or fail). Packet loss on the wireless channel is not considered in this paper yet. Hence, a packet transmission request may fail due to ACB check failure, contention collision, or insufficient data channels. The failed device would select a random backoff interval between 0 and \(W_{BO}\) and start a retransmission attempt after the backoff counter expires. A packet will be dropped if it has not been sent successfully within the maximum \(Q\) transmission attempts.  
In order to evaluate the performance of HSTMAC protocol in an extreme scenario, we assume that the arrival rate of H2H packets follows a Poisson distribution with mean \(\lambda\) in each access cycle and the arrival rate of M2M devices follows a Beta distribution \(g(t)\) defined in [11]:  
\[g(t)=\frac{t^{\alpha-1}(T-t)^{\beta-1}}{T^{\alpha+\beta-1}B(\alpha,\beta)}, \hskip 56.905512 ptt\in[0,T] \tag{11}\]  
where \(B(\alpha,\beta)\) is the Beta function and \(T\) is the activation time interval of M2M devices. The packet sizes of H2H traffic and M2M traffic are \(\delta_{1}\), \(\delta_{2}\) respectively. Let \(N^{M2M}\) denote the total number of M2M devices, then the number of new arrivals in cycle \(i\) is:  
\[N_{i}^{M2M}=\int_{t_{i}}^{t_{i+1}}N^{M2M}\frac{t^{\alpha-1}(T-t)^{\beta-1}}{T^ {\alpha+\beta-1}B(\alpha,\beta)}dt,\hskip 28.452756 ptt\in[0,T],i\in[1, \left\lceil\frac{T}{\tau}\right\rceil] \tag{12}\]  
where \(t_{i}\) is the time of the \(i\)-th access cycle.  
Figure 2: Frame structure of the proposed hybrid S-ALOHA/TDMA MAC protocol.