## 3 Medium Access Control Layer
### Time-Based Schemes
#### 3.3.2 Random-Based Schemes  
This set of protocols avoids the pre-allocation of resources by allowing nodes to compete with each other and obtain medium access on demand. These protocols usually rely on random access to distribute transmissions. They also normally include some recovery mechanisms in case a collision occurs. Protocols under this category can be subdivided into direct access, handshake access and contention access. Direct AccessProtocols under this category do not perform any kind of handshake for channel reservation. However, they can perform carrier sensing prior to transmission in order to avoid disrupting ongoing transmissions, deferring it until the channel is free. Aloha [72] is the simplest method to access the medium. It simply sends a packet whenever there is data to send, without performing any type of channel assessment or retransmission. In its variant, called aloha with carrier sensing (aloha-CS), prior to transmission, each node performs a clear channel assessment (CCA) in order to avoid disrupting any ongoing transmission. If the channel is sensed to be free, the sending node transmits its packet. However, if an ongoing transmission is sensed, the node waits until the channel is free and then sends the packet. Different studies have been conducted in order to understand the performance of aloha in an underwater medium. In [92], the authors develop an analytic model to study the performance of contention-based protocols by modeling different versions of aloha in an array network. Although the authors make several simplifications, different conclusions are drawn. Arrays longer than five hops are probably not going to perform well when using the simple aloha protocol. However, using p-persistent aloha without dropping packets increases the network throughput at the cost of increasing the delay. Another study based on the aloha protocol is presented in [93], in which two different variants of aloha are proposed. Aloha with collision avoidance (aloha-CA) tries to avoid collisions by overhearing the transmitted packets and knowing the propagation delays between all node pairs. The other proposed modification is aloha with advanced notification (aloha-AN), which consists of sending a short data packet prior to the actual data transmission with information on the sender and the intended receiver. CSMA [72] is another well-known protocol under this category. Similar to aloha-CS, this protocol uses carrier sensing. However, unlike aloha-CS, after waiting for the channel to be free, a node does not immediately send its packet. Instead, it performs random back-offs to mitigate the probability of collisions. This variant is called non-persistent CSMA. In another variant, called p-persistent CSMA, a node transmits with a probability of p when the channel is sensed to be free. Note that 1-persistent CSMA is equivalent to aloha-CS. Reservation AccessThis technique consists of reserving the channel prior to the transmission of the actual data packet. In order to do so, usually, short control packets are sent before transmission. By reserving the channel, the frequency of the collisions of data packets is minimized, and the additional traffic introduced by the control packets is compensated for. In the handshake-based alternative, whenever a transmitter wants to send a data packet, it first sends a control packet informing the other nodes that it has data to send. Upon reception of this control packet by the intended receiver, it replies if the channel is not being used. After receiving this reply packet, the transmitter can start the transmission of the data packet. However, this reservation mechanism cannot guarantee collision freeness, because of the well-known hidden and exposed node problems. Many authors have proposed different solutions to cope with this problem. Multiple access collision avoidance (MACA) [94] is the first approach of a handshake algorithm proposed to reserve the channel. The sender first sends an RTS control packet in order to start the channel reservation.