# SCHC over LoRaWAN Efficiency: Evaluation and Experimental Performance of Packet Fragmentation
## 4 Modeling Channel Occupation Using SCHC
### Theoretical Model
#### 4.3.2 Block 2  
Block 2 is composed of all of the retransmission windows. There may be more than one retransmission window as fragments can be lost again.  
The number of Regular SCHC Fragments retransmitted in a window depends exclusively on the fragments lost in the immediately preceding window and can be modeled as a binomial random variable \(X\). The random variable \(X\) can take values in \(S=0,1,2,3,\ldots,n\). The probability function of \(X\) is given by Equation (6).  
\[P(x_{j})=\binom{k}{j}\cdot p^{j}\cdot(1-p)^{k-j} \tag{6}\]  
where \(k\) is the amount of Regular SCHC Fragments of the previous retransmission window. There are \((k-j)\) SCHC Fragments received successfully and \(j\) Regular SCHC Fragments that need to be retransmitted. \(p\) is the probability of losing a Regular SCHC Fragment in the previous window. The calculation of this error probability is based on the bit error rate  
Figure 5: Message flow in ACK-on-Error mode [own elaboration].  
of each bit that makes up a Regular SCHC Fragment according to the equation defined by [PERSON] in [6], which is  
\[p=BER^{F} \tag{7}\]  
\(F\) is the fragment size in bytes of the L2 MTU of the underlying LPWAN technology, and \(BER\) is the bit error rate.  
The mean or expected value of a binomial random value is given by Equation (8).  
\[\begin{split} E[X]&=\sum_{j=0}^{k}j\cdot\binom{k}{j }\cdot p^{j}\cdot(1-p)^{k-j}\\ E[X]&=k\cdot p\\ \end{split} \tag{8}\]  
Thus, the mean or expected value of Regular SCHC Fragments retransmitted in a window is given by Equation (9).  
\[\begin{split} E[X_{w_{i}}]&=m_{i}=\sum_{j=0}^{m_{(i -1)}}x_{j}\cdot\binom{m_{(i-1)}}{j}\cdot p^{j}\cdot(1-p)^{m_{(i-1)}-j}\\ E[X_{w_{i}}]&=m_{i}=m_{i-1}\cdot p\\ \end{split} \tag{9}\]  
where \(m_{i}\) is the expected value of Regular SCHC Fragments retransmitted in the \(i\)-th window and \(m_{i-1}\) is the expected value of Regular SCHC Fragments retransmitted in the \((i-1)\)-th window. Table 2 shows the expected value of Regular SCHC Fragments for each retransmission window.  
In Table 2, \(n\) is the number of Regular SCHC Fragments in the transmission windows. This variable is the same as \(n_{fragments}\) in Equation 3. Then, taking into account the SCHC fragmentation model and the duration of each Regular SCHC Fragment indicated in Figure 5, the time \(T_{i}\) of each retransmission window is given by Equation (10):  
\[T_{i}=m_{i}\cdot(T_{F}+RD_{2})+(T_{AR}+RD_{1})+TP_{ACK} \tag{10}\]  
The time of Block 2 is given by the sum of all of the times of each retransmission window. Equation (11) shows the above idea.  
\[\begin{split} T_{B2}&=\sum_{i=0}^{r}T_{i}\\ T_{B2}&=\sum_{i=0}^{r}\{m_{i}\cdot(T_{F}+RD_{2})+( T_{AR}+RD_{1})+TP_{ACK}\}\\ \end{split} \tag{11}\]  
Thus, the \(t_{0}\) time in Equation (1) is defined by the sum between Equation (5) and Equation (11), as shown by Equation (12).  
\[t_{0}=T_{B1}+T_{B2} \tag{12}\]  
\begin{table}
\begin{tabular}{l l} \hline \hline
**Retransmission Window** & \(m_{i}\) \\ \hline
1 st window & \(n\cdot p\) \\
2 nd window & \(n\cdot p^{2}\) \\
3 rd window & \(n\cdot p^{3}\) \\
4 th window & \(n\cdot p^{4}\) \\ \(\vdots\) & \(\vdots\) \\ \(\text{rth window}\) & \(n\cdot p^{r}\) \\ \hline \hline \end{tabular}
\end{table}
Table 2: Expected value of Regular SCHC Fragments for each retransmission window.