IMPROVING QUALITY OF SERVICE IN MOBILE ADHOC NETWORKS FOR PROACTIVE AND REACTIVE PROTOCOLS USING GENETIC ALGORITHM

Now-a-days finding a path from source to destination for practical multimedia applications by satisfying the QoS requirement is a big challenge. Achieving quality of service in a mobile adhoc network is an NP complete problem due to its dynamic nature of the network and limited resource availability. In this study, we propose a new QoS module which uses genetic algorithm based approach to find an optimal path from the source to the destination. An optimal path is selected by a suitable encoding scheme where the possible paths are in the form of strings. Analysis is done in a proactive protocol (OLSR) and for a reactive protocol (AODV) and the comparison between them was given as OLSRGA and AODVGA. To achieve Quality of Service (QoS) in the network, we have taken link state information such as delay and bandwidth in the network.


INTRODUCTION
Emerging of Mobile Adhoc Networks (MANETs) with infrastructureless network, which has dynamically varying topology has brought a vast progress and growth in the field of wireless and multimedia applications. Due to dynamic nature of the network, MANET must be able to provide the required quality of service for the delivery of real time communications such as audio and video that poses a number of different technical challenges and new definitions (Crawley et al., 1998) However, ad hoc networks present unique advanced challenges, including the design of protocols for mobility management, effective routing, data transport, security, power management and Quality-of-Service (QoS) provisioning. Once these problems are solved, the practical use of MANETs will be realizable. The overall design of a solution for all of these problems is currently too complex and the problem is considered as an NP complete problem.
Thus to achieve proper QoS routing, an optimal path is to be found between the source and destination. However, finding an optimal path in a network to support QoS is not easy because it has been proven to be an NP-complete problem (Yussof and Ong, 2007).
In this study, we have taken link state information such as delay and bandwidth constraints of the network as metric measurements to achieve QoS. In our proposed work a genetic algorithm approach is used to find out a broken link in the path by finding out the unfeasible path and repairing them to find out a feasible path. An optimal path is selected in terms of a strong structure, where each element represents a path between each pair of nodes and a new technique is formed by using the past solutions as the initial data for new searches. Thus an encoding scheme is used to increase the quality of the solutions and the rate of convergence by performing crossover and mutation function on the initial population. Analysis is done in a proactive and reactive protocol and it is compared with respect to QoS.

EVOLUTION FLOW OF GENETIC ALGORITHM
Genetic Algorithm is a search technique used in computing to find a true (or) approximate solution to optimization and search problems. It uses the idea of "survival of the fittest" to search the optimum path solutions. Genetic Algorithms are a particular class of evolutionary algorithms where the idea is first applied to a problem by first guessing the possible solutions and then uses the fittest solution to create a new generation which should be better than the previous generation by applying GA operators like crossover and mutations on previous generation (Munetomo et al., 1997). Genetic Algorithms are a particular class of evolutionary algorithms that use techniques inspired by evolutionary biology such as inheritance, mutation, selection and recombination . The idea of natural evolution is used in proposed algorithm.
First guessing the all possible solutions and then combine the fittest solutions to create a new generation of solution which will be better than the previous generation and will give the better fitness value.

PROPOSED WORK
The proposed method consists in looking for the optimal path from source to destination of the network by taking into account an evaluation criterion to find broken links in the path and replacing it by taking alternate route. A genetic algorithm approach is used to find out optimal path. Metric measurements like bandwidth of the network and delay of the network is also calculated for optimal path selection.

Operators of Genetic Algorithm
The algorithm starts with a set of solutions called a population. A new population is formed by taking solutions from one population. The new one is the children and the one which gives the children will be called as a parent. Thus, at each and every step, an individual is selected from the current population randomly to produce the children for the next generation. Solutions are the string of bits with fixed length called as chromosomes. We hope that the new population will be better than the old one.
Solutions which are selected to form the next generation (children) which can also be called as offspring are selected according to their fitness value (Uma et al., 2006). Strings with higher fitness values have a higher probability of contributing an offspring.
Genetic operators such as crossover and mutation apply to parents to produce offsprings. Over successive generations, the population "evolves" towards an optimal solution. Figure 1 shows the evolutionary flow of genetic algorithm. From this evolution process the best individuals are found out and used. Figure 2 shows a 10 node network model which is used for Communication. Each and every node consists of the paths from source node to the destination node.

Proposed GA to Find Optimal Path Selection in MANETs (GAOPS)
Topology of any multihop networks can be defined as a directed graph representation, assuming that the network is directed and it does not contain parallel links (Wook and Ahn, 2002): }connecting m pairs of node in the network W = Weight on the edges A source node and destination node are denoted by S and D, respectively. I i,j is denoted as a link connection indicator, which provides the link information from node i to node j . This indicator indicates whether the link is included in routing process or not (chromosome mapping).

Route number
Possible route 1 1-10-7 2 1-3-2-7 3 1-8-6-5-7 For example a path between node 1 and node 7 can have the combinations as 1-10-7, 1-3-2-7, 1-8-6-5-7, 1-8-3-2-7 which are called as possible routes. A routing algorithm selects one of the possible routes for the routing process (Singh and Chandel, 2012). A routing table is created to do the routing, there about 14 possible routes for each and every path. All possible routing pairs can be searched in advance and it can be arranged in the routing table in order of length. In our proposed GA each route is identified by a route number, which is the row number of the routing table. A string is a route number of all the paths and its length is N (N-1)/2. The combination of route number's in a string is varied to generate various combinations of chromosomes.  This is done by an encoding scheme (Montana and Jason, 2005). A routing path is encoded by a string of positive integers that represents the IDs of the node.
Locus of the string = order of the node First locus = source node Last locus = destination node Three steps are followed in selecting initial population: • Repeat the process until destination is reached • Select node N from the list of n nodes • Don't select already selected nodes (avoiding looping)

Fitness Function
Our aim is to find out the optimal path to satisfying QoS routing in MANET using GA. The QoS metrics are taken as delay, bandwidth, throughput and link quality (node pair connectivity index). Thus, it can be classified as a multiple objective optimization problem. In our work each and every objective function is assigned a weight and all of them are combined to form a single objective function to do this weight sum approach is used: where, F1, F2 and F3 are the objective functions that describe delay, bandwidth, node connectivity. The values of x1, x2 and x3 are set as 10 −2 , 10 −3 and 10 −3 respectively. Based on their equal importance towards the overall QoS routing performance these coefficients are taken.
If bandwidth<BQoS F2 is setting a high value 1000 which leads to a high weighted sum function F. Hence it is assumed that the node does not have proper bandwidth to transmit a date. A link breaking can be occurred in the connectivity pair, hence such type of nodes are eliminated. If Bandwidth>BQoS, then F2 = 0. Then the function F will be depending on F1 and F3. If all the node pairs that make up the route produce a node connectivity pair to zero means it shows that particular route has a strong connection. Thus the chromosome which has a low weight will have a strong fitness value.

Crossover
The crossover operates by exchanging sub routes between the route. Both the routes that are elected for crossover should have a same source node and destination node. The crossover operation for a QoS routing problem is done by exchanging each partial route of two chosen chromosomes in such a manner that the offsprings produced by the crossover represent a single route. The proposed work uses the potential crossing site. A set of pair of nodes which are commonly included in the two chosen chromosomes but without positional consistency. Such pairs are called potential crossing site. In above Fig. 3 we have two crossing sites (3, 2) and (5, 6).
The below code is used to choose the potential crossing sites of chromosomes.

Mutation
Mutation takes place by flipping of one of the genes of the chromosomes. That is randomly interchange (flips) the bit of offspring if they improve the solution either decreasing total cost or increasing fitness value. It leads to a generation of the alternate node from the mutation node to the destination node. In our proposed method a topological intelligent database is introduced for this purpose.

Procedure
First, a node is randomly selected from the chosen chromosome, which is called as mutation point. One of the nodes, which is randomly connected directly to the mutation point is chosen as the first node.
We delete the nodes that are placed in an upper partial route. This is to form a database which doesn't include the same node twice in the new routing path. The upper partial route indicates the surviving portion of the previous route after mutation. It is the partial chromosome stretching from the first gene to the intermediate gene at the mutation point.

PERFORMANCE EVALUATION OF GA
The performance of GA depends on choosing of the probabilities of crossover and mutation. The crossover probability Pc is taken as 0.70 and the mutation probability Pm is taken as 0.50. This is done for a population size of 50. 1000 Maximum generation is made and as a termination condition 100 generations with same fitness is taken.
As an example 6 nodes are taken and their paths are shown below in Fig. 5. Three tables are formed respectively, for the example shown in Fig. 5, Table 2 shows all the existing paths and their weights. Table 3 shows the process of selection and final routes. Table 4 shows encoding and crossover function.

Initial Populations
All possible solutions The chromosomes which have the lowest weight have the high fitness value. By performing the process of selection and sorting parent chromosomes are found out. After performing binary encoding the weights, crossover function is generated and is performed on the parent node. 0 represents no link and it is used only for the comparison purpose (Wook and Ahn, 2002).

SIMULATION RESULTS
To run our simulation, we have taken four protocols, two reactive protocols and two proactive protocols, namely: Proactive protocols-Optimized Link State Routing Protocol (OLSR) and Destination-Sequenced Distance-Vector Routing (DSDV), Reactive protocols-Ad hoc On-Demand Distance Vector Routing (AODV) and Temporally-Ordered Routing Algorithm (TORA).
The OLSR protocol uses Multi Point Relays (MPR). MPR is a node that is selected which can cover all nodes that are two hops away. DSDV protocol routes every node to avoid loopings in the routing table (Perkins and Bhagwat, 1994). Each node acts as a router where a routing table is maintained and periodic routing updates are exchanged, even if the routes are not needed. A sequence number is associated with each route or path to the destination to prevent routing loops.
AODV uses route discovery phase and route maintenance phase. When a source node wants to pass a data to the destination with QoS requirements it starts with the route discovery phase. Once the route is discovered the data transmission takes place. During the data transmission it is also important to maintain the path to the destination. This is done by route maintenance. TORA builds and maintains a Directed Acyclic Graph (DAG) rooted at a destination. No two nodes may have the same height (Park and Corson,1997).
The overview modules of OLSR using a GA module (OLSRGA), DSDV using a GA (DSDVGA), AODV using GA a module (AODVGA), TORA using a GA (TORAGA) is given below.
Whenever there is a need to find a new set of route to the destination, GA module is always the initiator to find the set and it provides a new set of routes to the QoS module (Fig. 6) and it is stored in the buffer of QoS Module and if there is no any other node that is present within the neighbor, then the path from the buffer is followed. For the sake of efficiency, at some periodic time, the route from the buffer is again evaluated by GA module. To manage modularity concepts, the QoS routing module only has a minimum knowledge of the internals of the GA module and the MPR sets (in OLSR), formation of routing with the help of the sequence number (in DSDV), formation of the routing table (in AODV), recomputing a DAG in order to find a route (in TORA) are found in the form of simplified individuals (paths). As new sets of routes are exchanged with the QoS routing module is done through the buffer. isi.edu/nsnam/ns/ ) is used to do the simulation for all the four protocols (AODVGA,OLSRGA,DSDVGA,TORAGA). We have updated the source codes of the following files in each and every protocol to incorporate GA. Table 1 Gives the modification in all the protocols.50 nodes are placed randomly in the rectangular area of 1500×1500 M. Nodes can move randomly according to random waypoint mobility model with a speed of 10, 20 and 30 m sec −1 . The pause time is taken as 5, 10 and 15 s. The QoS parameters like delay, throughput and packet delivery ratio are analyzed here.

Scenario setup for MANET
The below Fig. 7 shows the effect of number of nodes Vs delay. The inference of the graph is when the number of nodes is less, the delay is less when the nodes are more the delay is also more, but compared to the conventional method the delay is less for the protocols that uses GA concepts.
The above Fig. 8 shows the effect of number of nodes vs delay for a mobility of 20 m sec −1 . The inference of the graph is compared to previous graph this graph has more delay value, this one occurs, as the speed of the node is increased congestion takes place in the network. Common links are used for the transmission, thus sharing the bandwidth of the network. According to our proposed scheme non intercepting path can be found with higher path preference probability. Thus, delay decreases as the number of nodes increases. Similar thing happens if we apply a speed of 30 m sec −1 .   1 2 3 5 6 9 Science Publications  Figure 9 shows that as the speed of the network increases the throughput decreases. Our proposed method for AODVGA has high throughput than the others. Next OLSRGA has high throughput. Thus we can say that reactive protocol with our proposed method has high throughput than the proactive protocol. Figure 10 shows the packet delivery ratio for all the protocols. Comparatively AODVGA and OLSRGA gives better resu.

CONCLUSION
In this study, we have proposed a QoS module with respect to genetic algorithm for mobile adhoc networks to support multimedia applications. An optimal path was found out from the source node to the destination node using the GA module, which provides QoS guarantees in terms of better packet delivery ratio, less delay and better throughput. In our analysis, we have taken two reactive protocol and two proactive protocol for comparison of the performance. We have found that our proposed method works well for AODV and OLSR protocols than DSDV and TORA protocols. In future, we have planned to work with real time multimedia data against various proposed QoS algorithms for mobile adhoc networks using various mobility models.