AMCCR: Adaptive Multi-QoS Cross-Layer Cooperative Routing in Ad Hoc Networks

The cooperative communication technique in an ad hoc network exploits the spatial diversity gains inherent in multiuser systems and mitigates the multipath fading. This technique is necessary but perhaps not sufficient to meet the QoS demands in ad hoc network. This is due to the fact that routing protocol at the network layer is more responsible for the successful packet delivery and QoSsupport.Inthispaper,weproposeanadaptivemulti-QoScross-layercooperativerouting(AMCCR)protocolthatenhancesthe performancethroughthecooperationofphysical,MAC,andnetworklayers.Wefirstformulateanapproachtoanalyzethechannel statevariationsforeffectivecommunicationschemesatthephysicallayer.Secondly,wedynamicallyselectthetransmissionmode toemploycooperativeMACschemebyexploitingspatialdiversity.Thereafter,thenetworklayerchoosesanoptimizedroutefrom sourcetodestinationthroughtheselectedbestrelaycandidatesbasedonmultipleQoSmetrics.Thepaperisfurtherextended tosupportdual-hophalf-duplexcommunicationviaselectedrelaybycodingtechnique.Theproposedprotocolisvalidatedby extensivesimulationsandcomparedwithCD-MACandCODEprotocols.Theresultsclearlyshowthattheproposedcooperative cross-layerdesignapproachsignificantlyimprovestheaveragedelay,throughput,andnetworklifetimeofthesystem.


Introduction
The wireless ad hoc network has gained immense popularity due to the ubiquity of portable mobile devices and the convenience of infrastructure-less communication.Today the significant advances in wireless communication have brought a revolution in the area of mobile communication.With the increasing time-sensitive multimedia traffic on the Internet, there is a demand to set QoS features to meet the rigorous performance demands [1,2].The QoS is defined as a set of constraints such as end-to-end delay, throughput, packet loss, and energy which need to be satisfied by the network.
In wireless communications, errors in data transmissions occur due to the unreliability of wireless channel caused by the node's mobility, energy exhaustion, and channel fading.This consequently leads to retransmission when erroneous data frames are detected, which further results in an increase in delay and decrease in the packet delivery ratio of the network.Thus, achieving multiobjective QoS in ad hoc network is challenging.These circumstances motivate the innovation of a new technology, known as cooperative communication (CC) [3,4].
Recently, cooperative communication has received considerable interest of research fraternity in wireless networks.The idea of cooperative communications has been mainly concentrated on the physical layer with the advances in the techniques such as modulation and coding to allow nodes to cooperate in their transmissions to improve the overall performance of the wireless networks [5].The cooperative communication at the physical layer comprises decisionmaking in selecting cooperative relaying schemes like store and forward, amplify-and-forward [6], and decode-andforward [7], choosing power for signal transmission, and selecting scheme for relay selection.
The innovation of cooperative communication is not restricted to the physical layer only.To subjugate the constant node mobility, it would be ideal to expose the physical layer information for the cooperation to different higher protocol layers.In the recent time, the cooperative MAC scheme in ad hoc wireless networks has also attracted much attention [8].These schemes use handshaking techniques to reserve the channel and avoid the collision problems.These schemes use cross-layer design between the physical and MAC layers for relay selection with the criteria related to rate adaptation and power control.Due to random nature of the wireless channel, MAC layer should know when to initiate the cooperative transmission.Thus, the cooperative MAC should utilize the assistance from a relay node to forward the data using better link adaptation techniques and higher data rates to enhance the network throughput.
Usage of cooperative communication together with rate adaptation techniques can enable the nodes to adapt their data rates to match the channel conditions and node mobility.Combining both these techniques can provide a substantial throughput improvement in direct and conventional multihop network.
In this paper, we establish cooperation between physical, MAC, and network layers.We propose an effective distributed cross-layer cooperative routing algorithm for mobile nodes by using multi-QoS cooperative metrics that use the potential cooperation gain to find the optimal route.The cross-layer coordination between the MAC and network layers is used to select an optimal next hop, while the crosslayer coordination between the MAC and physical layers is used to select the best relay.
The main objectives of the proposed algorithm are as follows: (1) An energy-aware, end-to-end delay efficient route discovery scheme is proposed among the network nodes in order to increase the network lifetime.(2) Using the channel state information at the physical layer, the proposed algorithm determines whether cooperation on the link is necessary or not.(3) In case the cooperation on the link is necessary, multi-QoS metric is used to determine the potential relay nodes for a cooperative transmission over each link.The cooperative mode activation is implemented in the MAC layer.(4) We exploit the cross-layer approach to the routing layer for relay selections and resource allocations that reflect the potential cooperation gain to find the optimal paths.The best relay node selection strategy is executed in distributed manner.(5) The proposed algorithm is analyzed with single relay participation for cooperative scheme and further extended for supporting network coding scheme.(6) The best relay selection is enabled with collision avoidance mechanism.
The rest of the paper is organized as follows.Section 2 discusses the related work.In Section 3, we describe the physical model and assumptions.Section 4 describes our adaptive cooperative cross-layer architecture.In Section 5, we propose our cooperative network coding technique.The NAV is analyzed in Section 6. Performance evaluation and conclusions are presented in Sections 7 and 8, respectively.

Related Work
In the recent time, the cooperative MAC schemes in ad hoc wireless networks have attracted much attention.These schemes use handshaking techniques to reserve the channel and avoid the collision problems.These schemes uses crosslayer design between the physical and MAC layers for relay selection with the criteria related to rate adaptation and power control.
Sai Shankar et al. proposed a protocol called CMAC [9] with minor modifications to the standard IEEE 802.11Distributed Coordination Function (DCF).When the source node sends the data packets and if destination node receives them with errors or fails to receive them, the source node selects a cooperative relay node to forward the lost data packet.Although CMAC provides the reliability of data transmission and throughput enhancement, it assumes that the link between any nodes is ideal and error-free.The relayenabled DCF (rDCF) [10] and cooperative MAC (Coop-MAC) [11] were proposed to exploit the multirate capability and counter the throughput bottleneck caused by the low data rate links.The CoopMAC and rDCF protocols choose to send packets at a high data rate using relay node in a two-hop manner instead of a low data rate with direct transmission and improve the network performance.In rDCF, the best relay node is selected by the receiver, based on the piggybacked information in the control frame.Meanwhile, in CoopMAC, the relay node itself decides whether to cooperate or not, based on its local information maintained in the cooperative table.Both protocols are not suitable for multihop ad hoc networks and do not have any provision to deal with hidden node and exposed node.In UtdMAC [12], data packets are transmitted through the relay whenever a direct transmission fails due to fading.But, in UtdMAC, it is assumed that the relay is selected a priori and will be ready to transmit in a cooperative method whenever necessary.Thus, this protocol does not have to deal with much of the relay selection overhead and management.The cooperative diversity MAC (CD-MAC), proposed by [13], is based on the DCF mode.In CD-MAC, nodes use Distributed Space-Time Coding (DSTC).In CD-MAC, the transmission of multiple copies of a data stream is distributed among the cooperating nodes, which act as a virtual antenna array.The cooperating nodes encode the data by using orthogonal codes and simultaneously transmit it to the destination.The packet scheduling technique CD-MAC is similar to that of ARQ scheme, where cooperation is triggered when a direct transmission of a control packet fails.A source node sends an RTS packet to the destination node.If the destination replies with a CTS before the timeout period expires, then CD-MAC does not initiate cooperation; else, it activates the cooperation in the next phase.The source node intimates the need for cooperation to relay nodes through repeated RTS (C-RTS) packet.The destination node replies to a C-RTS with C-CTS simultaneously to relay and source node.During cooperation using DSTC, source node first sends a packet to the relay in the first phase and then both the source and relay simultaneously transmit the coded packet to the destination node.In CD-MAC, each node maintains an estimate of neighbor nodes link quality through periodic broadcast of Hello packets.However, due to repeated transmission of control packets, the nodes suffer in terms of end-to-end latency.CD-MAC does not handle the issue effectively in case the relay node is unavailable.Also, the energy consumption is not addressed properly; hence, due to repeated control packet transmissions, the latency gets increased; this further results in higher energy consumption for CD-MAC.
In the traditional layering network protocol architecture, the strict boundary between the layers ensures the easy deploying of network, but the encapsulation of the layers prevents sharing of certain vital information between layers.Traditional routing protocol optimizes each of the three layers, namely, physical, MAC, and network layers, independently, which may contribute to suboptimal network designs [14].The traditional ad hoc routing protocols are designed for point-to-point communication, which do not take advantage of the cooperative diversity technique [6,15].
Recently, there has been an increased interest in protocols for mobile ad hoc networks to exploit the significant interactions between various layers of the protocol stack for performance enhancements [16].The research at the physical layer and MAC layer can be combined with higher layers, in particular the routing layer, to realize a fully cooperative network [17].However, the problem of combining routing with cooperative diversity has received very little attention.
In some of the proposed researches towards cooperative routing, the primary objective of the routing is focused on energy efficiency [18], reduced collisions [19], enhanced throughput [20], outage probability [21], and so forth.Most of these cooperative routing algorithms are designed with the specific demand of requirements on single QoS parameter for a particular application.Hence, it is difficult to make comprehensive cooperative routing satisfying the needs of all applications.Further, significant effort has not been done in QoS provisioning for cooperative routing in wireless networks, especially in the context of achieving multiobjective QoS services, namely, end-to-end delay, reliability, throughput, and network lifetime.The existing cooperation techniques mentioned above do not consider cross-layer coordination between physical layer, MAC layer, and network layer.

System Model
Consider the mobile wireless ad hoc network comprising nodes   ,  +1 , . . .,   .These nodes transmit a signal to neighbor nodes directly or may employ one relay node among the neighborhood.We consider the IEEE 802.11gPHY layer, which uses different modulation techniques to support multiple data rates of 6, 9, 12, 18, 24, 36, 48, and 54 Mbps [10].All the control packets and headers, namely, RTS, CTS, PHY, and MAC headers, are transmitted at a fixed rate of 1 Mb/s.
In our experiments, we consider only one relay node selection in each hop in order to control complexity and the interference from simultaneous transmissions.Let   represent the relay node in the th hop; thus the set of  relays is denoted by   ,  +1 , . . .,   .The system considers slow Rayleigh fading channel model.Each node is equipped with single antenna, imposed with half-duplex constraint with the impracticality of concurrent radio transmission and reception.
Let ℎ   , +1 , ℎ   ,  , and ℎ   , +1 represent the channel gain from the node   to the next hop  +1 , from node   to relay   , and from relay   to node  +1 , respectively.Statistically, they are modeled as independent and identically distributed (i.i.d) circularly symmetric complex Gaussian random variable with zero mean and equal variance:  2   , +1 ,  2   ,  , and  2   , +1 , respectively.The noises    , +1 and    , +1 are modeled as zero mean complex Gaussian random variables with variance  0 .
We model the cooperation approach in two phases.In phase 1, the source node   broadcasts its information to the next hop  +1 , which is overheard by neighbor   nodes.The signal received at the next hop and the neighbor relay are represented as    , +1 and    ,  , respectively.
where 1 is the power transmitted at the node   and  represents the transmitted information symbol.In phase 2, the neighbor node   processes the received signal by amplifyand-forward (AF) or decode-and-forward (DF) techniques depending on the following specified criteria: (1) For adaptive cooperation with amplify-and-forward (AF) technique, in phase 2, under the AF technique implementation, the selected relay terminal simply amplifies the received signal and forwards it to the next hop with transmission power 2.As stated in [6], under AF technique, the achievable rate between   and  +1 with   is given as where  represents the bandwidth of channels at node   and relay   and the average mutual information  AF (  ,  +1 ,   ) between the input and the outputs achieved by i. ( The signal received at the next hop is represented as where  1 and  2 are given as where ℎ * is the conjugated channel gain corresponding to the received symbol.Assuming that the average energy of transmitted symbol  in ( 1) is 1, the SNR of MRC output is represented as where  1 and  2 are given as (2) For adaptive cooperation with decode-and-forward (DF) technique, in phase 2, to implement the technique, if the selected relay terminal is able to decode the symbols of the received information from the forwarding node   correctly, then it retransmits the information with power 2 to the next hop.We assume that if the SNR received at the relay is greater than the threshold, then the symbol will be correctly decoded.As stated in [6], under DF technique, the achievable rate  DF between   and  +1 via   is given as where average mutual information  AF (  ,   ,  +1 ) between the input and the outputs, achieved by i.i.d complex Gaussian inputs, is given by The signal received at the next hop node is given as The channel gains ℎ   , +1 , ℎ   , +1 , and ℎ   ,  are assumed to be known at the receiver but not at the transmitter and are assumed to be independent of each other.The next hop  +1 , on receiving the signal from the relay and previous forwarding node, detects the symbols transmitted with the knowledge of the channel gains ℎ   , +1 and ℎ   , +1 , respectively.The next hop implements a MRC.The MRC maximizes the SNR at the receiver so that the bit error rate is minimized.The combined signal at the next hop is represented as where  1 and  2 are computed to maximize the SNR of MRC output at the next hop node and are represented as Assuming that the average energy of transmitted symbol  in ( 1) is 1, the SNR of MRC output is represented as

AMCCR Cross-Layer Architecture
In this section, we propose AMCCR cross-layer scheme, which uses an energy-efficient QoS routing to meet the requirements of the application.We also propose using the adaptive MAC to identify the relay nodes satisfying certain QoS metrics to cooperate the data transmission with the intermediate hops in the path discovered in routing phase.
4.1.Energy-Aware QoS Routing.The QoS routing is an essential component of a AMCCR architecture.The QoS factor aims at improving the quality of service in the wireless communication.The wireless ad hoc networks are powerconstrained as the nodes have limited battery energy.Therefore, the energy of the node is a crucial QoS factor in the design of the routing algorithm [23].We propose an energyefficient routing scheme for the wireless ad hoc networks in order to increase the network lifetime while forwarding the packets through energy-constrained nodes.The energy efficiency can be measured by the time for which the network can maintain a desired performance level, called network lifetime.The minimum energy routing is different from the routing to maximize the network lifetime, as sometimes minimum energy routing invites more flows in an area, and the nodes in the route are exhausted very early.Thus, the entire network cannot perform due to failure of these nodes.Hence, it is vital to route the packets in a network by balancing the lifetime of all the nodes, so that desired network performance can be achieved for a long time.Hence, energy efficiency is not only measured by the power consumption but more generally it can be measured by the duration of time over which the network can maintain a certain performance level.
In the proposed QoS routing scheme, we use AODV [15] as a routing algorithm with minimal modifications.When a source node has data to send to the destination node, it floods with the route request packet, RREQ, to its neighbors.The ⟨source-address, broadcast-id⟩ pair is used to identify the RREQ uniquely to control the overhead created by flooding and reducing the transmission of repeated information.In the proposed routing scheme, the source incorporates a minimum required node energy threshold value  thresh and minimum residual energy of the node  residual .The hop count and reserved field in RREQ frame are replaced with  thresh , and  residual , respectively.Thus, no additional overhead for modifications is needed in the RREQ frame structure.The  residual field is initialized to zero by the source.
On receiving the RREQ, node checks if its residual energy is higher than the  thresh value specified in the frame.If true, then it updates  residual field of RREQ with its own  residual value and rebroadcasts the RREQ to its neighbors.An intermediate node can collect multiple RREQ copies for the predetermined time duration RREQ wait , which is assumed as 20 ms.The intermediate node retains the RREQ with highest  residual value and processes further.The destination node replies to source using the path with the highest  residual value.Thus, the scheme ensures that the path discovered does not consist of energy acute nodes.

Cooperative MAC.
To optimize the performance, we exploit the MAC cooperation, while selecting the route from source to destination.Once the route from the source   to the destination   is discovered, any two adjacent nodes can select a relay node for cooperation to meet certain QoS requirements.Consider the example shown in Figure 1, where path is discovered between   and the destination   .Any two adjacent nodes like   and  +1 in the path can select and utilize the relay node   , which is in the interference range of both these nodes for cooperative transmission as shown in Figure 1.
For each hop on the routing path, determining the need of relay node   between two adjacent nodes and selecting the optimal one from them are challenging.To address this problem, we propose an adaptive cooperative MAC.The primary focus of cooperative setup in the MAC layer is to meticulously allocate the resources and to engage cooperative nodes in setting up the cooperative environment.
The nodes willing to communicate over the 802.11network use four-way handshake procedure to eliminate the hidden terminal issue.The communication between nodes is initiated by exchanging RTS/CTS packets.We assume that the link is symmetric.The node   transmits the RTS along with the payload of length .The receiving node  +1 , based on SNR of received RTS signal, computes the bit error rate (BER) and selects the appropriate data rate DR   - +1 for transmission from the node   .The broadcast nature of the wireless channel allows neighboring nodes of the sender   to overhear the RTS and determine the appropriate data rate DR   -  between the transmitter and themselves based on the estimated SNR and BER.The receiving node  +1 transmits CTS incorporating DR   - +1 to node   .The neighboring node, to qualify as relay node, checks channel allocation for any ongoing communication in the interference region through network allocation vectors (NAV) to alleviate hidden terminal problems.If NAV is not set, it decodes the CTS transmitted from the node  +1 and selects the appropriate data rate DR   - +1 , based on receiving signal SNR value.

Best Relay Selection Criteria.
To participate in cooperative communication between transmitter   and receiver node  +1 as relay node, neighbor node goes through certain QoS metric.The selection of good-quality relay nodes is essential to achieve the objectives such as energy efficiency and high throughput, which enhances the system's performance.In the existing schemes, the relay selection mechanism mostly incurs extra overhead for complicated interactions among the neighbor links.Thus, it is essential to analyze the impact of complicated interactions among the neighbor links on cooperative diversity performance and minimize it to the lowest possible.In MANETs, there might be several neighbor nodes willing to join the transmitting node in cooperation communication and selecting the optimal one from them is challenging.If every neighbor node starts transmitting the request to the source, it will lead to wastage of bandwidth and energy of the nodes, which may further incur additional delay.So, to deal with such cases, we primarily focus on certain effective criteria for relay selection described as follows: (1) Distributed relay selection: in some of the schemes such as centralized relay selection technique [24], the relay selection is done in a passive listening mode with centralized control.In this technique, all the neighbor relay's channel state information (CSI) is accumulated and compared, which induces complexity and delay.The scheme proposed in [11] requires periodic broadcast of readiness message by each neighbor node to its one-hop neighbors, irrespective of whether the cooperative mode is needed or not (2) Adaptive relay selection: in fixed relaying scheme, data transmission always happens via relay node even when the destination node can directly receive and decode the data packets transmitted from the source.Hence, time slot used by the relay to forward the data packets is a waste of resources and takes double the time to transmit packets compared to the direct transmission.To counter these problems, adaptive relay selection would be more recommendable (3) Optimal number of relays: to improve the network performance, many researchers [24] proposed using multiple relay nodes with the intent of increasing the diversity gain.However, the multiple relay nodes participating in cooperative communication create a larger interference area and cause additional coordination overhead, thus affecting the overall throughput.The authors in [25] proved that single relay node achieves the same diversity gain as that of multiple relay nodes In this paper, distributed adaptive relay selection method is proposed.In the proposed scheme, selection of best relay node is carried out when the direct transmission from the transmitting node   to receiving node  +1 in a multihop network fails due to fading or the relay path transmission time is better than the direct path.In such a scenario, the neighboring node with a potential to be a relay node participates in relay node selection process and uses local information collected by it.The neighbor nodes will have to satisfy certain QoS metric checks to qualify as the best relay node among the other competing neighboring nodes.
If the direct transmission path between transmitting node and receiving node satisfies the QoS requirements, the relay nodes will not participate in the communication and the protocol will be reduced to simple DCF.The neighbor nodes undergo the following QoS metric test to qualify as relay node.The various QoS metric tests a neighbor node has to pass to qualify as a relay node to support cooperative MAC mechanism are as follows: (1) For transmission time, the first QoS metric is the transmission time.
where  is the packet length,  RE is the transmission time for RE frame which is sent by the candidate relay node to   and  +1 to notify its willingness to participate in the cooperative communication, and  SIFS is the short interframe space (SIFS) interval.
If the neighbor node prefers to be a relay node, the total transmission time via relay node, that is,  coop , should be less than the direct transmission time  direct .
(2) For channel contention metric, it focuses on the channel contention.In MANETs, due to constant topological change, nodes may cluster at certain area and there could be high inflow and outflow of data within that region, leading to high interference.Therefore, the average channel contention time of the node may increase, thereby degrading the throughput of the network.In the proposed protocol, a node having a packet to forward will run a contention counter  cc () from the start of channel contention till it wins the channel access.The average contention time for a node  cc-avg () is computed using exponential weighted moving average over time Δ and is given by where  is a constant smoothing factor between 0 and 1.
If the neighbor node prefers to be a relay node,  cc-avg () should be less than  cc-thresh , specified acceptable time duration.
(3) For energy utilization factor, the third metric, energy efficiency is undoubtedly one of the apt metrics for quality evaluation.The network lifetime is defined as the time from the deployment of the nodes to the instant the first node dies.So, to maximize the network lifetime, data has to be routed such that energy expenditure is fairly among the nodes in proportion to their energy reserved.The energy levels of all the nodes in the network have to be balanced and the nodes death due to frequent communication should be minimized to extend the network lifetime.
In the proposed algorithm, the energy required by the neighbor node during cooperative communication is computed as Figure 2: RE frame format.
where  receiver is the power required to receive the data packet from the source and  transmitter is the power required to transmit the data packet to the destination.
Each neighbor node also stores its residual energy,  residual .The proposed AMCCR protocol uses a novel way of interpreting energy using a metric called the energy utilization factor to select a relay node that not only is energy-efficient but also assists in improving the network lifetime.The energy utilization metric  value is given as Energy utilization metric  is a better parameter compared to  cooperative or  residual metric.For example, consider the two neighbor nodes  1 and  2 satisfying the above two QoS metric tests.Let us assume that  1 and  2 have the residual energy of 30 J and 50 J, respectively.Many of the routing protocols select the next hop based on residual energy or the minimum power needed to transmit.Let us assume that if  1 or  2 is selected as the relay node for cooperation, the energy required for transmission would be 10 J and 25 J, respectively.So, according to maximum residual energy selection criteria,  2 is selected and after cooperative transmission the residual energy of  1 and  2 would be 30 J and 25 J, respectively.
According to the proposed energy utilization selection metric, the value of  for  1 and  2 will be ( 1 ) = 10/30 and ( 2 ) = 25/50, respectively.The node with minimum  will be selected, that is, node  1 .Thus, after cooperative transmission, the residual energy of  1 and  2 would be 20 and 50, respectively.Even though the  factor does not guarantee total energy consumption minimization, it maximizes the minimum value of  residual and maintains energy levels of the nodes in the network in a balanced state.Therefore, this factor extends the node survival time and improves the network lifetime.
In the network, there may be several nodes that have qualified all the three QoS metric tests and are candidate nodes for best relay node selection.So, to optimally select the best relay node, each node computes the network utilization weight based on the individual QoS metric weight.Each node computes its weight  relay at regular interval of time and is given by where ∑ 3 =1   = 1,  coop-max is the maximum acceptable cooperative transmission time, and  cc-max is the maximum acceptable channel contention time.
It can be seen from the above equation that the metrics are normalized by their maximum values with some multiplicative factor .

Relay Eligible
Frame.In the proposed scheme, the control format is extended to include source address, next hop address, relay address, data rates between source relay, relay next hop, packet length from source to next hop, and packet length from next hop to source, and priority.This new control format is known as relay eligible frame (RE) which is as shown in Figure 2.
On completion of RTS and CTS exchange, the node satisfying the condition to be a relay node sends the RE frame.On receiving the RE frame from a neighbor node, node   selects the appropriate MAC scheme.If RE frame is not received within timeout, the node   adopts direct transmission.The retransmission attempt is denied if RE frames collide or the relay backoff counter is reduced to zero.The sender node   will transmit the data at rate DR − after a SIFS.
Each node maintains a priority table that consists of a pair of data rate between transmitter-relay and relay-receiver paths as shown in Table 1.The relay node on self-accessing sets the priority field in RE frame that matches with the corresponding data rate pair as per Table 1 and forwards the RE frame to the transmitting node and the next hop.
where  delay is a channel propagation delay and  switch is transceiver switching time.
We further divide the time slots  into  to map  relay value, which is given as Each source node starts its  counter from zero, and when it reaches its  relay value, it sends RE frame in that time slot.(1) Relay selection is time-efficient.
(2) Collision probability of relay selection is minimized.
(3) Relay selection dynamically adapts to time-varying channel condition and nodes mobility.
(4) Relay selection is done in a distributed manner.
(5) There is no hidden node problem.

Adaptive Cooperative MAC Schemes in AMCCR.
In AMCCR protocol, the data transmission can be in one of the four categories: (1) Direct transmission (2) Sender-relay-receiver (3) Cooperative transmission scheme using DF technique (4) Cooperative transmission scheme using AF technique These MAC schemes are adaptively selected based on priority field of RE frame.The cross-layer adaptive data transmission is briefly explained in Algorithm 1.To facilitate the proper selection of transmission scheme, CTS packet is modified to accommodate a flag known as FLAG P.

Direct Transmission.
Based on the received signal quality transmitted from node   , the receiving node  +1 sets its FLAG P field while replying with CTS.If the direct transmission is sufficient, that is, SNR of received signal is greater than SNR thresh , then FLAG P is set to 0. The neighbor node, while decoding the CTS, will notice the FLAG P field and refrain from interfering in the ongoing communication if it is set to 0. Figure 3(a) demonstrates the scheme.Transmission mode = DF cooperative transmission (10) else if Priority > 6 then (11) Transmission mode = AF cooperative transmission (12) end if (13)  the transmission rate from sender node to relay node is too high, receiver node does not overhear it due to reduced range and hence minimizes the interference.

DF Cooperative Transmission.
When priority field of RE frame contains the value between 4 and 6, the data rate estimate from source to relay node is higher compared to that from relay node to destination node.When the relay is located closer to the source terminal, channel quality between node   and relay   is better than that between relay   and node  +1 .When relay   moves away from the source, the BER increases and the relay node may send erroneous bits to the destination.Under this situation, DF technique is always better than AF technique and guarantees a performance diversity of the second order [26].Therefore, when FLAG P is set to 1 and the priority field of RE frame contains the value between 4 and 6, AMCCR protocol prefers DF cooperative transmission.DF technique is always better than AF technique and guarantees a performance diversity of the second order.Figure 3(b) demonstrates the scheme.

AF Cooperative Transmission.
If FLAG P is set to 1 and the priority field of RE frame contains the value greater than 6, the AMCCR protocol prefers the AF cooperative transmission.Priority greater than 6 indicates low data rate estimate between   and   and high data rate estimate between   and  +1 .Performance in terms of BER is good when the relay node is closer to the destination node.As the relay node moves away from the destination, signal strength drops due to high data rate.Hence, cooperative scheme with AF is preferred to guarantee a performance diversity of order two as compared to DF scheme.
On receiving the RE frame with priority bit, the node  +1 prepares for receiving data packets from relay node.The node   waits for SIFS time and sends data at the data rate DR   -  to relay node.On receiving the data packet, relay node waits for another SIFS time and forwards the packet to destination node  at the data rate DR   - +1 .On receiving the data correctly, node  +1 replies with an ACK packet to node   after SIFS.
If node   does not receive the RE frame within Timeout RE , it prefers direct communication.Figure 3(c) explains the scheme.

Cooperative Routing.
In MANETs, cooperation at the MAC layer can be exploited at the network layer to enhance the system's performance.Unlike the traditional routing protocol, we exploit the MAC cooperation, while selecting the route from source to destination.Thus, cooperative routing is activated whenever the opportunity of cooperation gain exists.Consider a simple network topology given in Figure 1.Let us assume that the proposed routing scheme discovers the route from node   to node   via nodes  +1 and  +2 during initial route discovery phase.During the control packet exchange between   and  +1 , if   qualifies to be the best relay node to support cooperative transmission, then nodes   and  +1 will update their route table with the additional entry for the relay node.Thus, the route layer will have access to cooperative link metrics of relay between two adjacent nodes.The route layer fully exploits this information while choosing the best next hop from the route table.The possible route from node   to   can be   -  - +1 - +2 -  .Hence, the cross-layer mechanism utilizes cooperative diversity that helps in improving the network performance.

Network Coding through Cooperative Communication
In a dual-hop half-duplex relay network, the throughput performance is reduced to half as it cannot transmit or receive simultaneously.To counter this fallback, we implement the network coding scheme in cooperative mode to support efficient communication.Network coding [27] is the technique that forwards the data received from multiple nodes by combining the input data packets into one or more output data packets.This results in a reduced number of packet transmissions, reducing the delay and enhancing the network performance.This technique is widely being accepted and can be exploited in the cooperative communication.Consider an example as shown in Figure 4, where nodes   and destination to the source   +1 -  is computed through the duration values in RTS and CTS, respectively.The condition for relay node to participate in cooperative network coding technique is revised as Figure 5 demonstrates the flow chart of detailed functionality of proposed AMCCR protocol.

NAV Adaptation
The IEEE 802.11 wireless network uses a virtual carrier sensing mechanism that uses network allocation vector (NAV).NAV helps to limit the nodes access to wireless medium which in turn avoids multiple interferences and conserves energy.The transmitting node specifies the transmission time required for the frames like RTS, CTS, and DATA, during which the channel will be busy.All nodes listening to channel on the network set their NAV for which they defer their transmission.The NAV is calculated based on the transmission data rate.In cooperative communication, since the data rate varies based on relay node location and channel condition, setting NAV for RTS and CTS accurately is not feasible until the relay node information is available to the source and the destination node.Thus, setting the effective NAV is vital.Updating the NAV of control packets in proposed AMCCR protocol is described as follows: (1) Whenever a node   has data to forward, it senses the channel to check if it is idle for a DCF interframe space (DIFS) time.Upon completing the required backoff timer, it sends RTS and reserves the channel for RTS NAV time.At this instance, since   has no idea about the cooperation or network coding, it uses basic data rate to compute channel reservation based on direct communication.
where  is the length of the data packet and DR   (33) (6) The nodes that receive only RTS from S but not the CTS set their NAV until the end of ACK.

Experimental Setup
In this section, we analyze the performance of the proposed AMCCR by using the NS2 simulator [28].We evaluate the performance of AMCCR by comparing the results with CD-MAC for cooperative mode and CODE for network coding.The AMCCR is evaluated for MANETs based on IEEE 802.11g.In our simulation, we consider a network over an area of 1000 * 100 meters.The experiment is simulated for 900 sec time duration, and the results are averaged after 20 executions.Each execution uses a seed value ranging from 1 to 9 for randomness in node placement and steady results.The random movement of mobile nodes is modeled using the random way-point modeling with a speed set to 5 m/s.The source and destination nodes are randomly selected for a TCP connection pair.Figure 6(a) shows the throughput performance proposed AMCCR, CD-MAC, and noncooperative 802.11DCF protocols.All the protocols perform similarly in the initial stage.But as the traffic load increases with deteriorating environment, CD-MAC and noncooperative 802.11DCF protocols' performance degrades.Also, as the network overhead increases, it leads to increase in packet collisions.Interestingly, the AMCCR offers excellent performance and better throughput improvement due to optimal relay node selection from the lesser congested area with minimal overhead, providing the highest data rate for packet transmission and influencing the network throughput.
In Figure 6(b), we observe the end-to-end delay performance of the AMCCR in comparison with CD-MAC and noncooperative 802.11DCF protocols.As the traffic flow increases, overall average delay increases for all the three protocols.But AMCCR significantly performs better.This is because of the adaptive cooperative approach in AMCCR that uses higher dynamic data rate adaptation that decreases the average transmission time and allows more packets to be transmitted faster via the relay node, reducing the overall transmission time duration.Also, in AMCCR, if a packet is lost due to the collision, relay node forwards the backup copy of data packets, reducing the retransmissions.
Figure 6(c) compares the network lifetime as a function of increasing traffic load.The lifetime of the network gradually decreases with the increasing traffic load.The reason for the decline in the lifetime is the extra energy consumption by the node and therefore it is exhausted early.As AMCCR efficiently chooses nodes with optimal residual energy, lifetime slowly declines and hence network is sustained for a longer time as compared to other two protocols.

Cooperative Mode with Varying Node Density.
In this simulation, we vary the network density by varying the network size from 20 nodes to 100 nodes at two different noise levels with 10 TCP traffic flows between randomly selected connection pairs.Figure 7(a) shows the throughput performance of the proposed AMCCR, CD-MAC, and noncooperative 802.11DCF protocols.The throughput performance curve of AMCCR is better compared to other protocols and performs consistently better.This is because the proposed protocol dynamically adapts to channel conditions.Also, as the network density increases, more relay nodes are available to support adaptive cooperative routing benefits for utilizing higher data rates.
Figure 7(b) shows the performance of average end-toend delay of three protocols.As the environment deteriorates with the increase in node density, the packet delay curve of CD-MAC and noncooperative 802.11DCF protocols has an upsurge.In AMCCR, because of its judicious selection of transmission mode and relay node, it optimizes the reliability and delay on hop-by-hop basis.The AMCCR exploits higher data rates offered by relay nodes to transmit packets, reducing the end-to-end delay.Figure 7(c) shows the network lifetime performance.We can observe that as the node density increases, the network lifetime curve in the graph increases.The network lifetime of the proposed AMCCR performs comparatively better than the other protocols at noise level of −92 dBm.The AMCCR has the longest lifetime as it optimally selects the nodes with sufficient energy level.The other protocols underperform as network lifetime is shorter.

Network Coding with Varying Number of Traffic Flows.
In this simulation, we vary the network load, that is, by varying the number of UDP-based concurrent VOIP traffics at two different noise levels.The voice traffic is encoded into a VoIP flow with ITU-T G.711 [29], with average source bit rate of 64 kbps and the packet size of 160 bytes.The number of nodes is assumed to be 50.We assume the number of flows from 4 to 20, with the source and destination nodes randomly selected for a UDP connection pair.We compare the AMCCR protocol with a cooperative communication scheme called CODE and 802.11DCF under the network coding scheme.In CODE, network coding is partially utilized.The relay node is randomly selected and not optimally by broadcasting the messages repeatedly.
From Figure 8(a), we can analyze the throughput performance of AMCCR in comparison with two other protocols.The proposed AMCCR even under the worst environment conditions shows 12-15% improved throughput compared to CODE.The performance of 802.11DCF is the worst as it works in a noncooperative method.Figure 8(b) shows the delay performance curve for all three protocols against the UDP VOIP traffic.The delay increases with the increase in traffic and deteriorating environment.The AMCCR outperforms CODE with 10-12% reduction in delay, as it optimally selects the best relay for cooperative coding.The adaptive decisions on transmission mode and relay selections at each hop in AMCCR provide the reliability and make it more robust to link failures, thus enhancing the delay performance.

Conclusions
The paper proposes a novel adaptive cooperative protocol, AMCCR for MANETs.In AMCCR, we developed a crosslayer algorithm for energy-efficient routing in MANETs using cooperative diversity.In AMCCR, routing scheme exploits the adaptive cooperative MAC scheme for reliable data transfer.AMCCR provides a distributed relay selection scheme using multi-QoS metric to choose the best relay that can help to receive data packets and transmit to the next hop using a cross-layer scheme.It is observed that, in order to design an energy-efficient network for reliable data transfer and to maximize the network lifetime, joint cooperation between several layers is needed, that is, link quality in the physical layer, relay selection in the MAC layer, and routing in the network layer.The extensive simulation conducted shows that, in cooperative mode, AMCCR significantly shows better performance in terms of throughput, delay, and network lifetime compared to CD-MAC and 802.11DCF even under the harsh environment.The proposed AMCCR also outperforms the CODE protocol as it exploits both cooperation and coding together to enhance system's performance.

Figure 5 :
Figure 5: Flow chart of the proposed AMCCR protocol.

Table 2 :
Comparison of various relay selection schemes.
4.3.2.Relay Selection Overhead.Due to the mobility of nodes, multiple relay nodes may be available satisfying the QoS metric.This may lead to collisions of RE frames.Such frequent collisions may reduce the cooperation opportunity and degrade system's performance.Thus, it is a challenging task to select the best relay efficiently with lower collision rate.So we need to make a trade-off between relay selection period and collision probability.In order to avoid the collision of RE frame from multiple nodes qualified to be a relay, each qualifying neighbor node waits for an additional  time after SIFS time.We divide the  time slot into multiple  slots of length . and  are computed as  = 2 *  delay +  switch - +1 is the data rate from node   to node  +1 .(2) The node  +1 on receiving RTS replies with CTS after a SIFS time and reserves the channel for NAV duration CTS NAV .CTS NAV = 3 *  SIFS +    - +1 DR   - +1 +  ACK .  - +1 ,   +1 -  ) min (DR   - , DR - +1 ) .If node   and node  +1 receive RE frame within timeout, they send the data through either cooperative technique or network coding.Else, node   sends the data packet through a direct transmission to node  +1 .RE timeout =  SIFS +  RE .

Table 3 :
Simulation parameters in the MAC layer.
The source-destination pairs are randomly selected.The initial energy of all nodes is set to 60 J and  thresh is assumed to be 5 J.The channels between each pair of nodes are set as independent Rayleigh fading channels.The transmission rate of the data packet is computed as the average SNR value of the received signal at the receiver.The channel in the physical layer utilizes the multirate transmission defined in IEEE 802.11g.The simulation parameters assumed at the MAC layer are mentioned in Table3.Throughput: it is the ratio of the total amount of data that reaches a receiver from a sender to the time it takes the receiver to get the last packet.It is expressed in bits per second(3) Network lifetime: the network lifetime of a node depends on the energy consumption in its own transmissions as well as data transmission from neighbor nodes.Thus, we compute the network lifetime with respect to energy consumed per unit time.Thus the network lifetime depends on the energy consumption during both phases.Thus we compute the network lifetime with respect to energy consumed per unit time.Thus the lifetime of any node   is computed as   =  initial / consumed , where  consumed is energy consumed per unit time.The total network lifetime is computed as NL = min  (  ), where  is total nodes in the network.7.1.2.Cooperative Mode with Varying Number of Traffic Flows.In this simulation, we vary the network load, that is, by varying the number of concurrent TCP traffic flows from 4 to 20, with two different noise levels at a rate of 4 packets/s.The number of nodes is assumed to be 50, randomly distributed.
7.1.1.Evaluation Metrics.Evaluation metrics are listed as follows:(1) Average end-to-end delay: it is computed as the average delay experienced by packet from source to destination which is successfully delivered.The delay time comprises transmission delay, propagation delay,