# Performance Analysis of the IEEE 802.11p Multichannel MAC Protocol in Vehicular Ad Hoc Networks
## 4 Analytical Model and Performance Analysis
### Performance Analysis
#### 4.4.1 Packet Transmission Delay
 \tag{41}\]  
where \(S_{s}(z)\) and \(C_{s}(z)\) represent the PGF of \(T_{s,suc}\) and \(T_{s,col}\), respectively, and the expressions are given in Equation (43). According to Figure 8a, we can use Mason formula to solve the transfer function from the \"Start\" point to the \"End\" point, i.e., the PGF of service time of \(TS_{e}\). We have  
\[P_{TS_{e}}(z)=\sum_{k=0}^{\infty}q_{e,k}z^{ts_{e,k}}=\frac{S_{e}(z)}{W_{e}}\sum _{k=0}^{W_{e}-1}\left[H_{e}(z)\right]^{k} \tag{42}\]  
In VANETs, nodes use two-way handshake to make SCH reservations. Service provider sends a WSA packet and piggybacks with service information and the selected SCH. Service user responds to the WSA packet with an ACK. The PGF of \(T_{s,suc}\) and \(T_{s,col}\), \(S_{s}(z)\) and \(C_{s}(z)\) can be given by  
\[\left\{ \begin{array}{l}S_{s}(z)=z^{\left\lfloor\frac{T_{s,suc}}{\varphi} \right\rfloor}\\ C_{s}(z)=z^{\left\lfloor\frac{T_{s,col}}{\varphi}\right\rfloor}\end{array} \right. \tag{43}\]  
The backoff timer will be decremented by one time slot (\(\sigma\)) with probability (\(1-P_{s,b}\)). The backoff timer will be frozen if the channel is busy due to the following cases: safety packet error with probability \(P^{2}\), successful transmission a safety packet with probability \(P^{3}\), WSA packet error with probability \(P^{4}\), successful transmission a WSA packet with probability \(P^{5}\), collision slots from only emergency packets, only WSA packets or both with probability \(P_{s,b}-P^{2}-P^{3}-P^{4}-P^{5}\). Therefore, the PGF of the time that the backoff timer of WSA packet decrements by one can be expressed by  
\[ \begin{split} H_{s}(z)&=(1-P_{s,b})z+P^{2}C_{e}(z)+P^ {3}S_{e}(z)+P^{4}C_{s}(z)\\ &\quad+P^{5}S_{s}(z)+(P_{s,b}-\sum_{i=2}^{5}P^{i})\cdot\max[C_{e} (z),C_{s}(z)]\end{split}  \tag{44}\]  
The backoff process \(B_{s,i}(z)\) at stage \(i\) of WSA packets can be expressed by  
\[B_{s,i}(z)=\left\{ \begin{array}{l}\frac{1}{W_{s,i}}\sum\limits_{k=0}^{W_{s,i}-1}\left[H_{s}(z)\right]^{k},\quad\;i\leq m^{\prime}\\ \frac{1}{W_{s,m^{\prime}}}\sum\limits_{k=0}^{W_{s,m^{\prime}}}\left[H_{s}(z) \right]^{k},\quad m^{\prime}\leq i\leq m\end{array} \right. \tag{45}\]  
As we defined before, the random variable \(TS_{s}\) is the duration of time taken for a state transition from the start state (when a WSA packet is reaching the head of its queue and beginning to be served) to the end state (being transmitted successfully or discarded after maximum m times retransmission failures). When nodes use WSA packets to make SCH reservations, transmission failure will incur the increasement of backoff stage with doubled CW. The transmission failure includes two cases: transmission collision and transmission bit error. Due to our Assumption 4, these two cases thus have equal time. As shown in Figure 8b, the PGF of \(TS_{s}\), \(P_{TS_{e}}(z)\) can be expressed by  
\[ \begin{split} P_{TS_{s}}(z)&=(1-P_{s,f})S_{s}(z)\sum_{i=0}^{m} \left\{\left[P_{s,f}C_{s}(z)\right]^{i}\prod_{j=0}^{i}B_{s,j}(z)\right\}\\ &\quad+(P_{s,f}C_{s}(z))^{m+1}\prod_{j=0}^{m}B_{s,j}(z)\end{split}  \tag{46}\]  
Finally, based on Equations (42) and (46), we can derive the arbitrary \(n\)th moment of service time by differentiation. the average service time can be calculated by  
\[TS_{i}=\frac{1}{\mu_{i}}=\sum_{k=0}^{\infty}q_{i,k}\cdot(ts_{i,k}\cdot\sigma)=P _{TS_{i}}^{\prime}(z)\Big{|}_{z=1} \tag{47}\]  
Now, we can derive the service time distribution and to solve the values of variables \(P_{e,emp}\) and \(P_{s,emp}\). However, \(P_{e,emp}\) and \(P_{s,emp}\) depend on the duration of service time. We employ an iterative algorithm to solve \(P_{e,emp}\) and \(P_{s,emp}\). The detailed iterative steps are as follows:  
1. Initialize \(P_{e,emp}\) and \(P_{s,emp}\) according to the network condition, and assign initial values for them (ranging from 1 to 0), for example, if the network is under the unsaturated condition, it is better to set the value close to 1. 2.