A Self-Adaptive Routing Region in Wireless Sensor Network’s Heterogeneous Traffic

— The paper presents a new routing scheme using the information on the locations of nodes to create a routing region that controls the region of packet routing to achieve route optimization. The proposed scheme aimed to reduce the occurrence of packet detours or other routing overheads caused by the undirected packet transmission. The strength of this approach is that it can improve the lifetime of nodes in the network while decreasing the time taken for a packet to arrive at its destination or base station (BS). The proposed scheme used a self-adaptive algorithm that dynamically adjusted the routing region based on the BS’s calculation of the network layer parameters to achieve energy efficiency while satisfying data quality. The routing region limits the area of routing and restricts data flooding in the entire network, which potentially will waste resources and cause data redundancy. The simulation showed that the proposed scheme outperformed, the original fitness scheme and SPEED, according to energy consumption, transmission delay, throughput, and reliability (packet delivery ratio) under different congestion levels. The proposed scheme offered double the throughput and shortened packet delay by 20%. Furthermore, it had a longer lifetime, exceeding other schemes by approximately twofold when the traffic was not too congested. However, the gap decreases when the network becomes worse.


I. INTRODUCTION
Nowadays, sensors support multiple sensing capabilities [1]- [4] that enable research in a wide range of applications [5], [6] such as target tracking, security system, habitat monitoring, environmental control, traffic monitoring, and health-care applications.Limited battery power is a major challenge for wireless sensor network (WSN) applications [7]; most routing approaches are designed to deal with energy trade-off, however, not much have been done to optimize the quality of service (QoS) [8].
Certainly, traffic diversity relating to various data classifications require different QoS levels for data communication [9].Four types of packets are used for different categories of traffic in this paper, namely C1, C2, C3, and C4.C1 refers to critical traffic with highest importance which requires both reliability and low latency such as object tracking, safety alarms services.Meanwhile, C2 is the delay-sensitive traffic that delivers data within a given deadline but tolerate a certain amount of packet loss like video monitoring/streaming services.C3 is the reliability-sensitive traffic, which should be delivered without loss but tolerates reasonable delay like regular data monitoring services.Lastly, C4 refers to the best effort traffic that has no specific requirement.
The new scheme needs to provide a generic approach to encompass all the important attributes of QoS into a single routing framework.The scheme should factor in different application requirements.Thus, it can route packets with minimum overhead to save energy, reduce transmission delay, and lengthen the lifetime of routing while still maximizing throughput.
Much research in WSN has tried to use the information of nodes' locations for packet routing and routing discovery and maintenance to achieve route optimization.The locations of nodes are used to route packets to neighbors that have the closest distance to the destination or base station (BS) to reduce both communication costs and transmission delays.This paper uses a new routing scheme that exploits the information of nodes' locations to create a routing region that limits the routing area and restricts data flooding in the entire network, potentially wasting resources and causing data redundancy.
The area of routing is a zone of rectangle which is created using several stages.At first, BS creates a line to connect the BS and the source (S); this line is referred as S-BS.Second, BS defines a radius for each pair of adjacent sides of the region that are perpendicular to the line of S-BS.The sides are named by region side-1 (RS1) and region side-2 (RS2).The radius can be dynamically adjusted using a self-adaptive algorithm based on the BS's calculation of the network layer parameters as the reflection of the QoS values.The radius adjustment is classified into three different levels, i.e., low, medium, and high.Each level determines a certain range of numbers for a QoS value being classified.When the QoS calculation value is low, the radius will be increased.The parameters include end-to-end delay, data delivery ratio, and energy of all nodes in the region.
The scheme has several contributions.First, it can differentiate the required data related to each type of traffic and assign different priorities for different types of packets.Second, it can implement a fitness routing approach that considers the quality of each node that fits each data category having different QoS requirements.Third, it is able to setup a routing region which limits data routing in a specific zone to achieve energy efficiency as well as data quality.Lastly, it is adaptable to adjust the radius of the routing region by using a selfadaptive algorithm to maintain the QoS performances even with frequent topological changes.The rest of this paper is organized as follows: Section II discusses the related work.Section III describes the approach of the proposed routing algorithm.The implementation and the evaluation through a comparative simulation study is presented in Section IV.Finally, Section V draws the conclusions.

II. RELATED WORK
The most significant research efforts in WSN aim at energy management techniques that use the geographic information of the nodes to route data by reducing communication costs while achieving data quality [10].Several approaches have been described on how location information can be used [11].
The first approach is based on typical protocols that use the location information of source, neighbors, and destination nodes to forward packets in greedy mode.These protocols are Greedy Perimeter Stateless Routing (GPSR) [12], Geographic and Energy Aware Routing (GEAR) [13], and Greedy Other Adaptive Face Routing (GOAFR) [14].GOAFR combines a greedy and a face routing technique to restrict routing discovery and select a node with the closest distance to the sender node.GOAFR is suitable for high-density networks, however, it takes more looping, which causes a longer time during the routing process to route packets to the destination.Similar to GOAFR, GPSR constructs a perimeter forwarding approach by transmitting packets through nodes at the edges of the graph around the destination when no closer neighbors are available.The extended mechanism of GPSR is GEAR [13].GEAR divides the routing region into four zones, and it uses both the remaining energy and the geographic information of neighboring nodes to estimate the link cost for a path.GEAR selects a node closer to the destination, and it uses the previous path if no neighbor to the destination is available.
The second approach is based on the protocols that divide the routing region into smaller rectangle zones (grid), such as geographical adaptive fidelity (GAF) [15] and GRID [16].Based on the node's location and radius transmission, GAF forms a small virtual grid.The side of the grid is defined by  = R √5 .Nodes inside the grid communicate with each other and periodically select a cluster head that actively monitors and reports to the destination about any events while other nodes sleep.Hence, GAF may achieve energy conservation to lengthen the network lifetime.GRID uses a grid shape and performs a grid leader to route packets in a grid-by-grid manner.GRID is suitable for a large and dense network as this protocol divides the network into smaller regions (grid).GRID can also maintain a route alive when a destination node moves out of the region by performing a handoff operation similar to a cellular system.
The last approach is the algorithm that uses location-based information to limit the area of packet routing to achieve route optimization.This protocol includes Location-Aided Routing (LAR) protocol [17], Distance Routing Effect Algorithm for Mobility (DREAM) [18], and wireless sensor networks in home automation (WSNHA)-location-based self-adaptive routing (LBAR) [19].LAR and DREAM try to reduce routing overhead by limiting the route discovery area in smaller request zones.These zones can be improved by adapting the shape based on the speed of the mobile node.They represent three shapes: rectangle, bar, and fan.In [19], the protocol defines a cylindrical request zone for route discovery, maintenance, and packet forwarding.A node can adaptively adjust the radius of cylindrical zone using a self-learning Bayesian's theorem according to the prior probability of successful and unsuccessful data transmission.The transmission fails when a source node does not receive a route reply packet from a destination node or otherwise.Each node creates a table containing both the number of successful and failed packet transmissions under different radius zones and chooses a radius that has the higher probability for packet forwarding.
The proposed scheme is different from the previous algorithms that use a routing zone approach because the adaptation of the routing region is initiated by a BS (not a node) to avoid overhead costs for maintaining a route table to destination by using the calculation of QoS parameters such as delay, data delivery ratio and energy of all nodes in the region.BS periodically computes the QoS metrics to find an optimum radius to determine the size of the routing region.
This paper discusses the enhancement of our previous works [20], [21].This enhancement aims to improve route optimization and restrict unguided relaying/transmission due to improper routing areas, which wastes energy and increases transmission delay in WSNs.
The proposed scheme used a request zone approach based on LAR techniques to achieve effective route discovery for data routing.The scheme used a self-adaptive algorithm that dynamically adjusted the size of the routing region based on the BS's calculation of the network layer parameters to increase successful data routing while considering energy efficiency.The paper compares the proposed scheme, named TeGaReGioN, with the original scheme for WSN's applications having different types of data traffic based on differentiating QoS requirements named TeGaRand SPEED [22] as the existing algorithms use the location-based information approach and consider QoS notions.

III. PROPOSED ROUTING DESIGN
In the proposed algorithm, each sensor knows its geographic (location) information using some localization methods.By using the location, every node communicates with its direct neighbors that are located within the node's transmission range {NNj: distNNi ≤ Prange}.
BS propagates a message containing its hop value (0) and coordinates over the network in order for each node in the network to determine its hop count and distance to BS.A node periodically updates a table that contains energy, distance to BS, information on channel access failure, and packet queue length and exchanges the information of the table between neighbors.Currently, each node knows the neighbors' locations and attributes to setup route discovery as well as packet routing and route maintenance.
As the proposed scheme uses a routing region to confine the area of data routing to the destination, BS regularly updates the size of the routing region by calculating the QoS values to find an optimum radius for the closed region.BS broadcasts the updated radius, which suits a certain BS-source vector throughout the network, so the nodes can update their locations whether they are still inside or outside a routing region.After all nodes have decided the locations to a certain closed area, the proposed scheme selects a node to relay packets to the destination using a fitness routing approach.
The proposed algorithm offers two methods that provide energy efficiency and route optimization.They are a selfadaptive routing region algorithm and a fitness routing approach [20].The paper describes each of them in the following section.

A. ROUTING REGION ALGORITHM
In the proposed scheme, when a source node S wants to report events to the BS, node S needs to find a route to the BS.At first, node S, which has no existing path to the BS, transmits a route discovery message to the BS in a hop-by-hop manner until the message arrives at the destination.By receiving the message, BS checks the location of the source node in its route table and constructs an imaginary straight line to the source.If multiple sources create events, BS develops more than a single imaginary line.BS regularly determines the radius of the routing region using the QoS value calculation to create each pair of adjacent sides of the region that are perpendicular to the line (S-BS), namely RS1 and RS2, as shown in Figure 1.BS broadcasts the radius for a certain pair of S-BS over the network; thus, any node can calculate whether its location is in or out of the region, as explained in (6).out of the region, as explained in (6).
The routing region is shown as the dotted line in Figure 1. Figure 1 shows the coordinates of nodes S, BS, H, and L as (XS,YS), (XBS,YBS), (XH,YH) and (XL,YL), respectively.The distance between node H and the line (S-BS) is d while the distance between node L and the line is .The condition for determining whether a node is located in the routing region is: if its distance (d) is 0 ≤ d ≤ Radius (R), like node H, otherwise other distance () is > R like node L. As the line (S-BS) and the RS1 and RS2 are perpendicular, thus the distance between any nodes to line (S-BS) are supposed to be perpendicular.For instance, it assumes the line (S-BS) is a vector  ⃗ and the line that connects node S to node H is a vector  ⃗⃗ , whereas  ⃗ and  ⃗⃗ ∈ |R  as non-zero vectors.From the two vectors, the angle ∅ is determined as shown in Figure 2.
Figure 2 explains that d indicates the distance between node H and the line (S-BS).Thus, it finds whether d is lower or higher than (R) as the radius of the region.Figure 2 shows that the result of the cross-product of two vectors  ⃗ and  ⃗⃗ is the vector ( ⃗⃗⃗⃗⃗ .⃗⃗ ).Suppose that the equation of the cross-product of two vectors derived from the law of cosines is Then it calculates the angle ∅ as follows The length of vector  ⃗ and vector  ⃗⃗ are Hence, the angle ∅ is determined as (5) Once the angle ∅ is defined, then the distance (d) from any node (in this case: node H) to the line (S-BS) is calculated as From ( 6), if the distance (d) is 0 ≤ d ≤ R, then a node is in the routing region; otherwise, when 0 ≤ R ≤ d, a node is out of the routing region.The nodes inform neighbors about their relative positions to the routing region to facilitate route discovery and packet routing.

1) SELF-ADAPTATIVE ROUTING REGION
In a situation where the traffic becomes higher, many nodes may be congested or die faster, leading to packet losses due to packet route failure.Congestion causes difficulty in routing packets from source to destination.The proposed scheme needs to expand the radius (R) of the routing region to involve more nodes participating in data routing to address this situation.In contrast, when traffic becomes normal and the QoS improves, the proposed algorithm adaptively decreases the radius of the routing region into a smaller area.The smaller routing region saves energy consumption because fewer nodes are used to relay packets while more nodes outside the routing zone go to idle mode.Furthermore, a static radius for every routing region should not be established to address the network dynamics (i.e., topological changes, link instability, or channel access availability).The proposed scheme is designed to adapt to changes in the network by proposing a self-adaptive routing region based on the value of QoS parameters to achieve optimum QoS performance.
The decision for adjusting the radius is based on the selflearning process by the BS according to the following information.
1. End-to-end delay of packet arrival.2. Data delivery ratio which is determined from the number of data received at the BS divided by the number of data sent by the source.3. Total energy of all nodes in the routing.

2) FORMULA OF THE ROUTING REGION
In this section, the work describes how the scheme makes decision based on the evaluation of the network layer parameters (QoS metrics) to dynamically adjust the routing region.The self-learning of the BS can be realized by the following formula.
The α1QoS(de) function is the delay function of all data traffic in a certain period.The lower the delay, the better the QoS performance.α1 is the weighting constant to standardize the value of delay.
The α2QoS(En) function is the function that represents the energy of all nodes in the routing region.More energy means higher chances for a node to be maintained to deliver data.α2 is the standardization weighting factor for energy.
The α3QoS(Dr) function is the function of data delivery (Dr) ratio at BS.A higher ratio reflects the effectiveness of the routing algorithm in routing packets.α3 is the Dr standardization weighting factor.
Table I shows the adjustment of the routing region which can be classified into three different levels, e.g.(low, medium, high).The low is defined as the radius of the routing region being assigned to 0.5R by the algorithm, while medium has (R) and high refers to 2R.R is the initial power transmission range.The best values of a and b help find the optimum route performance.

B. FITNESS ROUTING APPROACH
After establishing a routing region and determining the position of the nodes toward the region, the proposed scheme considers the quality of each node in the region that fits each type of traffic to perform route differentiation.It uses the fitness function to select the candidate next-node y due to different type of data categories as follows [20].
where  0 (y) is the factor that reflects the remaining energy based on the battery lifetime.Higher energy on a node makes the node more likely to be chosen.  is the weighting constant. 1 (Y-BS) is the factor of the distance between a node and BS that represents delay estimation for data transmission.the closer a node is to the destination, the lower the delay prediction and the more attracted it is to forward real-time packets. 2 is the weighting factor. 2 (y) is a function that evaluates the link availability of a candidate's next node.A higher error rate is indicated by many channel access failures, and it degrades the possibility of a node being selected. 3 (y) is a factor that reflects the number of packets waiting in the queue.This factor makes heavily used nodes less attractive, even if they have much energy. 3 is a weighting factor.Each packet type requires different weights for different parameters, and the summation of the weighting constants is 1.For instance, the highest QoS packet assigns higher weight for energy and distance as it requires reliability and lower latency.Reliable traffic requires a higher weight for energy, while delay-sensitive traffic needs a higher weight for distance.Finally, the best-effort service needs equal weight for all parameter 3.

IV. SIMULATION AND EVALUATION
In the proposed algorithm, each sensor knows its location.To evaluate the above approaches, a Java-based wireless network simulator (JWSN) was developed to construct the network graph and to simulate the algorithms in terms of throughput, delay and network lifetime.The simulator used the carrier-sense multiple access with collis ion avoidance (CSMA/CA) mechanism [23], which commonly uses the 802.11protocols for wireless networks.Before initiating data transmission, the CSMA/CA required both the sender and the receiver to send a request to send (RTS) and clear to send (CTS) packets to reduce packet collision.When a node heard an RTS from a neighboring node, but the node was not the corresponding CTS, the node would forward the packets to other neighbors.In the network, 350 nodes were randomly deployed onto a 300 × 300 m 2 grid, whereas the BS, the destination, was located in the middle center of the network.Congestion was produced by creating data flows from six sources with different traffic rates (1-50 packet per second (pps)).The sources were placed at corners and edges of the grid.To test the robustness and the energy efficiency of the schemes, the simulation was run for 300 s with various parameters as follows: stationary node, data rate (250 kbps), packet size (1 kb), Hello cycle period (8 s), initial energy (15 J), and initial transmission range (30 m).
Figure 3 shows the packet reception of each scheme for all types of traffic.Overall, TeGaReGioN achieved the highest throughput compared to others.All schemes provide increasing throughput while more data flows in the network, but higher traffic certainly increases the number of lost packets, as shown in Figure 4.For instance, TeGaReGioN reached a peak packet reception (16.5 Mb) at 30 pps before the rate went steady (15.5 Mb) for the rest of the traffic.In contrast, with a similar trend, the original fitness approach SPEED only achieved almost half throughput (about 9-10 Mb) under mid to heavy congestion.
Although the packet reception increases under higher traffic (see Figure 4), the packet delivery ratio significantly decreases along with more packets injected into the network.Congestion caused many nodes to fail to relay packets to BS as the destination, so many packets were dropped during data transmission.Figure 4 demonstrates that the proposed scheme, which controls data routing in a closed area, succeeded in avoiding packet detouring and reducing communication costs.Hence, more packets could be delivered to the BS even if the network became congested.Under heavy congestion, TeGaReGioN could maintain a delivery ratio of 35%, while other schemes provided not more than 20%.When the   experiment simulated less traffic, TeGaReGioN achieved a nearly 100% ratio, but the other two schemes had only a 67% packet ratio.Figure 4 validates that the TeGaReGioN is sensitive to the network dynamic.Figure 5 explains the importance of the routing algorithms that perform route differentiation.Compared to SPEED, both the proposed scheme and the original one attempted to balance the network load by involving more nodes to participate in data delivery by nearly double.SPEED involved about 90 nodes in the simulation, while both schemes used around 150 to 200 nodes.By increasing the number of nodes joining in routing, the algorithm maximizes the network utilization to achieve efficiency.It is not happening in the case of SPEED because SPEED does not enable traffic differentiation and will not change the routing path unless SPEED cannot maintain the required packet speed.
Figure 6 shows the average lifetime, which is when the first node runs out of energy.The longer the time for an active node to fail, the less route breakage occurs, which degrades the network performance.The advantage of using a routing region conserves the nodes' battery for relaying packets compared to non-routing region algorithms.For instance, when the traffic was not too congested, TeGaReGioN doubled the route lifetime, and the gap decreased when the network became more congested.In addition, at 20 pps, the proposed scheme could prolong the first node's lifetime until 112 s, while other schemes could only maintain it for around 56 s.Under heavy congestion, all schemes significantly achieved low lifetime because many nodes failed quickly.
The efficiency of the proposed scheme was validated by fewer node failures during the simulation, as shown in Figure 7.When the energy of the nodes in the region fell, the value of the QoS calculation decreased.Then, TeGaReGioN performed a self-adjustable region approach that dynamically increased the radius of the routing area or otherwise.The expanded routing region might increase node participation in delivering packets, whereas the expansion balanced the network load and helped many nodes save energy.In contrast, the original fitness algorithm without the routing region approach might experience packet detouring (broadcast storm), communication cost increase, and overhead.Therefore, the proposed scheme achieved fewer drained nodes while providing a higher throughput and data delivery ratio.
The superiority of a routing region mechanism is justified in Figure 8, where TeGaReGioN shortens packet delay for all data categories.The proposed scheme could lower its delay by approximately 20% (approximately) compared to the original fitness scheme and by nearly 50% compared to SPEED.Hence, the rate became similar between TeGaReGioN and the other schemes, which used a fitness approach when the traffic was too congested.Figure 8 shows that by controlling the region of      packet routing, the proposed scheme avoids packet detour and shortens en-route data from a source to the BS.

V. CONCLUSION
This research investigated the analysis of the packet detouring caused by unguided data transmission.It introduced a routing approach to address the problem of unguided packet relay due to improper area of routing that would affect the overall performance of the network.The proposed scheme, termed TeGaReGioN, performed a routing region mechanism for controlling the area of routing to achieve route optimization.This mechanism was then combined with the fitness method to support heterogeneous traffic for different QoS requirements.The proposed scheme used a self-adaptive algorithm based on the BS's calculation of the network layer parameters to dynamically adjust the routing area to achieve energy efficiency while satisfying data quality.The results represent that the self-adaptation of the routing region has greater tolerances for changes in the network conditions and reduces the need for human intervention to maintain the QoS performances in these dynamic environments.The simulation shows that the proposed scheme outperformed the original fitness scheme and SPEED in terms of energy consumption, transmission delay, throughput, and reliability (packet delivery ratio) under different congestion levels.
According to the proposed scheme, there is a need for an efficient and intelligent approach that provides a smooth (nonsharp/sudden) adaptation to improve QoS performances by adjusting the routing region according to the current situation of network dynamics.The next adaptation approach should meet a trade-off between the efficiency and the accuracy for adjusting the routing region; thus, increased throughput and a decreased delay with lower energy consumption can be achieved.

Figure 1 .
Figure 1.Routing region in the proposed scheme.

Figure 2 .
Figure 2. How to define the distance between a node to the line (S-BS).

Figure 3 .
Figure 3. Packet reception of all types of traffic.

Figure 6 .
Figure 6.Time when the first node died (s).

Figure 7 .
Figure 7. Energy consumption for data communication.

Figure 8 .
Figure 8.Average delay for all data traffics.

Figure 4 .
Figure 4. Data delivery ratio of all types of traffic.

TABLE I MAPPING
BETWEEN QOS VALUES AND ADJUSTMENT OF ROUTING REGION Muhammad Nur Rizal: A Self-Adaptive Routing Region … p-ISSN 2301-4156 | e-ISSN 2460-5719