Research Article  Open Access
Yali Yuan, Caihong Li, Yi Yang, Xiangliang Zhang, Lian Li, "CAF: Cluster Algorithm and AStar with Fuzzy Approach for Lifetime Enhancement in Wireless Sensor Networks", Abstract and Applied Analysis, vol. 2014, Article ID 936376, 17 pages, 2014. https://doi.org/10.1155/2014/936376
CAF: Cluster Algorithm and AStar with Fuzzy Approach for Lifetime Enhancement in Wireless Sensor Networks
Abstract
Energy is a major factor in designing wireless sensor networks (WSNs). In particular, in the real world, battery energy is limited; thus the effective improvement of the energy becomes the key of the routing protocols. Besides, the sensor nodes are always deployed far away from the base station and the transmission energy consumption is index times increasing with the increase of distance as well. This paper proposes a new routing method for WSNs to extend the network lifetime using a combination of a clustering algorithm, a fuzzy approach, and an Astar method. The proposal is divided into two steps. Firstly, WSNs are separated into clusters using the Stable Election Protocol (SEP) method. Secondly, the combined methods of fuzzy inference and Astar algorithm are adopted, taking into account the factors such as the remaining power, the minimum hops, and the traffic numbers of nodes. Simulation results demonstrate that the proposed method has significant effectiveness in terms of balancing energy consumption as well as maximizing the network lifetime by comparing the performance of the Astar and fuzzy (AF) approach, cluster and fuzzy (CF)method, cluster and Astar (CA)method, Astar method, and SEP algorithm under the same routing criteria.
1. Introduction
In recent years, wireless sensor networks have gained the worldwide attention. In particular with the development of microelectromechanical system (MEMS) technology, more and more intelligent sensors have come into being. These sensors are small, with limited processor and computing resources, and are cheaper than traditional sensors. Smart sensor nodes can be used to detect, measure, and gather information from the surrounding environment. They can pass the collected data to the user through a number of local decisionmaking systems.
As a new mode of information acquisition and processing, wireless sensor networks (WSNs) [1] have now become a hot research of concern at home and abroad. WSN collects the information of perceived objects in the network coverage area through large numbers of sensor nodes deployed in the monitoring region and periodically provides the end users with information which has been collected and processed by means of the multihop wireless communication method. WSNs, which do not acquire the support of the fixed network, have features of fast expansion and strong survivability and also have a wide field of applications for military target tracking and monitoring [2, 3], natural disasters rescue [4], biological medical health monitoring [5, 6], dangerous environmental exploration and remote earthquake sensing [7], environmental monitoring [8, 9], and special fields like these. In largescale data acquisition networks, the energy of sensor nodes is provided by a small inexpensive battery which can run a long time [10]. Figure 1 shows the schematic of WSN, which consists of sensor nodes, base station, task management centers, and so on.
WSNs are always deployed at a remote location where people are unable to get close and energy cannot be replaced. Wireless sensor nodes are small and batterypowered, which leads to many problems, such as limited capacity of single node processing and storage, limited communication range, and limited energy. The energy issue is the most critical. Uneven energy consumption is an inherent problem in multihop WSNs. Imbalance in energy consumption reduces the network lifetime to a large extent. The whole network can be split because of the death of some nodes, ultimately leading to the termination of the entire network. The lifetime of a wireless sensor network is a critical parameter for evaluating the performance of routing protocols [11, 12]. Therefore, designing an effective policy to control energy loss is the core issue for prolonging the network lifetime [13, 14].
In order to solve this problem in WSNs, researchers have proposed a variety of methods. In [15], the authors proposed to shorten the hop count of the route to reduce the energy consumption of endtoend transmission and used the ratio of currently selected path hops and the shortest path as metrics. The authors of [16] presented the optimized forwarding by fuzzy inference systems (OFFIS) for flat sensor networks. OFFIS protocol favors four descriptors (small hops, shortest path, maximum remaining battery power, and link usage) to select the best node from candidate nodes in the forwarding paths. A linkaware clustering mechanism (LCM) for energyefficient routing in WSNs is proposed to determine an energyefficient and reliable routing path [17]. The LCM algorithm evaluated the qualification of cluster head (CH) nodes and gateways to construct clusters. Liao et al. [18] used a balanced clustering algorithm with distributed selforganization for WSNs on the basis of their distance and density distribution, taking into account the optimal configuration of clusters. This makes it essentially different from the previous clustering algorithms. A Stable Election Protocol (SEP) for clustered heterogeneous WSNs is used to prolong the time interval before the death of the first node, which is crucial for many applications where the feedback from the sensor network must be reliable. SEP is based on weighted election probabilities of each node to become a CH according to the remaining energy in each node [19]. Some of the researchers adopted the combination of fuzzy and clustering method. In [20], Gupta et al. proposed to use three fuzzy descriptors (residual energy, concentration, and centrality) during the clusterhead selection. In [21], a fuzzylogicbased clustering approach with an extension to the energy predication (LEACHERE) has been proposed to prolong the lifetime of WSNs using the fuzzy method to evenly distribute the workload. It selects the CHs considering expected residual energy of the sensor nodes. Rana and Zaveri [22] exploited the Astar method to search the optimal route from the source to destination. If the sensor node’s residual energy level is below the predefined minimum energy level, it would not participate in routing. The work in [23] presented a combination of a fuzzy approach and an Astar algorithm (AF) in terms of balancing energy consumption and maximization of network lifetime. The authors used three fuzzy descriptors (the highest remaining battery power, minimum number of hops, and minimum traffic loads) and compared the proposed approach with the Astar search algorithm and fuzzy approach using the same routing criteria in two different topographical areas.
From the aforementioned literatures, we note that most of the present routing algorithms are routing methods based on flat multipath routing protocols or routing protocols with simple clustering. As for the WSNs with large sensor nodes, uneven nodes distribution density, and realtime changing network topology, the flat multipath routing methods may cause network partition because some nodes that are part of the efficient path are drained from their battery energy quicker. In many cases, the lifetime of a sensor network is over as soon as the battery power in critical nodes is depleted. The simple clustering routing protocols send the merging data directly to the sink node. However, most of the cluster heads are far away from the sink node and the energy cost by transmission is index times increasing with respect to distance. As to the above problems, this paper presents a new routing method called CAF which means a cluster algorithm and Astar with fuzzy approach for lifetime enhancement in WSNs. The CAF routing method, which takes into account the advantage of SEP algorithm, Astar method, and fuzzy inference approach by favoring the remaining power, the minimum hops, and the traffic numbers of nodes, provides a good solution to the problem of uneven energy consumption and prolongs the lifetime of the network effectively. The proposal adopts a method of single hop within clusters and multihop among clusters to communicate.
The rest of this paper is organized as follows. Section 2 describes the concept of routing metrics and presents some assumptions. In Section 3, the SEP method is put forward, fuzzy approach, and Astar algorithm by describing each part in detail. In Section 4, the CAF algorithm is proposed. Then, a radio energy dissipation model and the simulation results based on simulation environment, parameters, and metrics are presented in Section 5. Finally, Section 6 concludes this paper.
2. Preliminaries
This section describes the concept of routing metrics which have been used to prolong the lifetime of WSNs and presents some assumptions on which all works have been done in this paper.
2.1. Assumptions
(a)The sensors are randomly (uniformly) distributed and are not mobile, the coordinates of the sink and the dimensions of the sensor field are known, and the sink is not energy limited (at least in comparison with the energy of other sensor nodes) [19]. The base station’s position is fixed and far from sensor nodes in the network.(b)A percentage of the node population is equipped with more energy than the rest of the nodes in the same network; this is the case of heterogeneous sensor networks and they are all uniformly distributed in space [19].(c)Each node can be informed of the total energy in the network and set the probability of selected CHs according to their residual energy [24].(d)All sensor nodes are randomly distributed in the area and each sensor node is assumed to recognize its own position as well as that of its neighbors and the sink [23].(e)Each node has a certain amount of traffic pending in the node’s queue. The node’s queue includes the application traffic and also the traffic that a node has already committed to forward [23].(f)The base station prepares the routing schedule and broadcasts it to each node. The Astar algorithm which is used to find the optimal route from the node to the base station is applied to each node [23].
2.2. Definition of Terminology
(a)Remaining power (RP): in WSNs, the most critical aspect of routing is energy efficiency. Under this standard, the size of the battery capacity in the current node is in focus. Routing protocols adopted by this measure tend to select a path which has maximum total energy from the source node to the destination node. That is, the node which has more residual energy is more likely to be selected as the node in the best path [25, 26].(b)Small multiple hops (SMH): the SMH are a common standard in routing protocols which passes through a minimum number of relay nodes from the source node to the destination node. The basic idea of this measure is that it takes the shortest path to get endtoend relay nodes and uses less resource consumption, because of a minimum of forwarding nodes involved [15, 25–27].(c)Traffic numbers (TN): the node traffic numbers can be defined as the pending amount of traffic in a node’s queue. These traffic numbers include the amount of the transfer being sent and previously being transmitted. In the case of the concentrated events of a particular subregion, using the shortest path would cause an implosion phenomenon on this path. High loading will cause sensor node data queue overflows, resulting in the loss of important information. In addition, the entire sensor network lifetime would be shortened, due to the quick energy consumption of batteries in the sensor nodes [26–28].(d)Stable phase: it is the time interval between the operation of the network and the death of the first sensor node in the network.(e)Period of instability: it is the time interval between the death of the first node and the death of the last one in the network.(f)Network lifetime: it is the time interval between the operation of the network and the death of the last sensor node in the network.
3. SEP Method, Fuzzy Approach, and AStar Algorithm
3.1. SEP Method
Organizing WSNs into clusters enables the efficient utilization of the limited energy resources of the deployed sensor nodes. Low energy adaptive clustering hierarchy (LEACH) protocol is an applicationspecific protocol architecture [24, 29]. LEACH protocol is the first one to raise the hierarchical routing protocol of data aggregation which is to balance the energy consumption of each node in the network. Periodically, CH is elected in each round, and each round of elections is as follows. Each node generates a random number in the range , if a number is less than a threshold , then the node would be seen as a CH in the current round. The threshold is set as where is the probability of becoming a CH, is the token of the node, is the number of the current round of elections, and is the most recent round of the set of the CH.
The clustering method in this paper uses the SEP algorithm in [19] which is an improved algorithm based on the protocol of LEACH. SEP improves the stable region of the clustering hierarchy process by the characteristic parameters of heterogeneity in which is the advanced nodes fraction and is the additional energy factor between advanced and normal nodes.
To achieve the goal of extending the time of stable phase, advanced nodes have more chance to become cluster heads than the normal nodes, which is equivalent to a fairness constraint on energy consumption. The new heterogeneous setting which consists of advanced and normal nodes has no effect on the spatial density of the network so the priori setting of has the same value as the one from (1). SEP method is based on the weighted election probabilities of each node in order to become a CH according to the residual energy in each node.
The main objective of the SEP method is to avoid the node with low energy becoming a CH and control the number of the CHs to the optimal number as well as reducing the uneven distribution of CHs during every round. In this way, it can reduce the energy cost and extend the life of the network.
3.2. Fuzzy Approach
Fuzzy inference is an approximate inference that simulates people’s everyday inference, which is booming in the mathematical core of fuzzy control technology. Zadeh introduced fuzzy logic in the 1960s to represent and use fuzzy and uncertain knowledge [30]. From the early 1980s, there have been many scholars engaged in research on artificial intelligence and committed to the study of the fuzzy logic method application in the field of artificial intelligence. These provide the basis for further improvement of the fuzzy inference or incorporation into the appropriate logical framework [31–33]. In recent years, many academicians have gradually made various improved methods of the fuzzy inference [34–36]. At present, in the research of the fuzzy theory and its applications, fuzzy logic and fuzzy inference have achieved certain results and are moving in the direction of the development of axioms, intelligence, and information. Fuzzy logic has been successfully used in a variety of areas, including communication systems [37] and prediction of water level in reservoirs [38], and as a classifier in fault diagnosis of roller bearing [39]. All of these studies have achieved good results.
The fuzzy logic system, a nonlinear inputoutput mapping as a whole, processes information by using fuzzy set. The fuzzy set in universe is expressed as a membership function , the value of which is in the interval . can be expressed as .
The two most important concepts in fuzzy logic are fuzzy language variables and fuzzy inference rules.
Fuzzy language variables refer to words or sentences in a statement. Their value is not a usual number, but a fuzzy set is represented in fuzzy language. This value is a description to some extent. For example, the language variable “age” can be referred to as “young,” “middle,” or “old.” Language variable is an important concept, which provides a formal way to quantize language description.
The fuzzy inference rule which is also named as the “ifthen” rule is the core of fuzzy logic. For example, if is , then is . In this example, and are language values defined, respectively, in the range by a fuzzy set. The if part “ is ” in the fuzzy rule is known as the premise or assumption of the rule, and then the part “ is ” is known as the result or conclusion. In essence, this expression describes the relationship between variables and . Therefore, the ifthen rule can be defined as binary fuzzy relations.
There is a fuzzy control rule, “if is and is , then is ,” which is achieved by a fuzzy implication (fuzzy relation) and is defined as where and is a fuzzy set in , is a fuzzy implication (relation) in , and represents a fuzzy implication function.
The most widely used application in engineering is a rulebased fuzzy inference system (FIS), which has the following four basic elements, as shown in Figure 2.
The fuzzy system contains all of the applicable fuzzy algorithms and the necessary ingredients resolving all related ambiguities. It consists of the following four basic elements.(1)Knowledge base: it includes the definition of fuzzy sets and fuzzy operators.(2)Inference mechanisms: they perform all of the output calculation.(3)Fuzzifier: it represents the true input value as a fuzzy set.(4)Defuzzifier: it transfers the output fuzzy sets into real value.
Knowledge base contains the definitions for each of the fuzzy sets and maintains a system operator to achieve the basic logic (AND, OR, etc.), as well as expressing fuzzy rules mapping with a rule reliability matrix. Inference units with fuzzifiers and antifuzzies calculate real output values from the real input values. The fuzzifier represents the input as a fuzzy set, making the inference unit match with it in the rules stored in the knowledge base. Then, inference units calculate the strength of each rule and output a fuzzy distribution.
3.3. AStar Algorithm
Peter Hart, Nils Nilsson, and Bertram Raphael of Stanford Research Institute (now SRI International) first described the Astar algorithm in 1968 [40]. It is a combination of heuristic methods such as BFS and methods like Dijkstra algorithm [41].
Astar search method is a highly efficient heuristic algorithm used in the graph searching algorithm and it is also used in finding a variable or low cost path. Noted for its performance and accuracy, it is widely used in WSNs. In practical systems, it can preprocess the graph to attain better performance [42].
Astar method uses a bestfirst search and finds a leastcost path from a given initial node to a one goal node (out of one or more possible goals). As the Astar traverses the graph, it follows a path of the lowest expected total cost or distance, keeping a sorted priority queue of alternate path segments along the way.
Astar method uses a knowledgeplusheuristic cost function of node (usually denoted by ) to determine the order in which the search visits the nodes in the tree. The cost function is a sum of two functions. Consider the following.(a)The past pathcost function is the known distance from the starting node to the current node (usually denoted by ).(b)A future pathcost function is an admissible “heuristic estimate” of the distance from to the goal (usually denoted by ). depends on the heuristic information. In the heuristic function, the more the heuristic information (the problem of knowledge) is, the less the extending node will be, so the destination node can be searched quickly.
The evaluation function used in the paper is given as
The part of the function must be an admissible heuristic; that is, it must not overestimate the distance to the goal. Thus, for an applicationlike routing, might represent the straightline distance to the goal, since that is physically the smallest possible distance between any two nodes.
In short, Astar algorithm firstly creates two lists, an open list and a closed list. The open list corresponds to a container of nodes that will be checked. The closed list corresponds to a container of nodes that have already been examined. Initially, put the starting node into the open list. Then, extending the starting node means to calculate the evaluation function of all adjacent nodes. Assuming that the adjacent nodes are not in the closed list, if the evaluation function values of the nodes are larger than the values of nodes in the open list, replace the nodes in the open list, and,if not, add them to the open list. When it iterates, the optimal node will take the top of the priority list. Then, check whether it is the destination node. If so, the algorithm is finished. Otherwise, repeat the above operations. If it does not find a solution, then it can guarantee that no such solution exists. Astar algorithm will find a path with the lowest possible cost. It looks for the shortest path with minimum cost, which mainly depends on the choice of the evaluation function [43].
Astar method can be accomplished as follows.(1)Put the initial node into the open list; let and .(2)If the open list is empty, then exit the algorithm and return false.(3)Move out the first node from the open list, which has the smallest value; let it be best node, and put it into the closedlist.(4)If best node is the target node, then exit the algorithm, and return to the target node.(5)Otherwise, extend the best node. If the node does not have the successor node, go to (2).(a)Otherwise, generate its entire legal successor nodes. For each successor node , calculate .(b)If it neither belongs to the open list nor to the closed list, then let and , and put into the open list.(c)If belongs to either the open list or the closed list, and , then let and , and if belongs to the open list, then it is retained. If it belongs to the closed list, then it will be moved out from the closed list into the open list.(d)Reorder the values of the nodes in ascending order in the open list.(e)Go to (2).
4. Proposed CAF Algorithm
The lifetime of a wireless sensor network is a critical parameter for assessing the performance of routing protocols. Imbalance in energy consumption reduces the network lifetime to a large extent. Therefore, designing an effective routing method to control energy loss is the core issue for prolonging the network lifetime.
The primary goal of this paper is to design a protocol which can extend the network lifetime by limiting energy consumption and balance the distribution of energy cost. This paper proposes the CAF routing method which makes use of the SEP method, fuzzy approach, and Astar algorithm. The proposal selects the optimal node to construct the multihop tree by considering the three routing criteria mentioned in Section 2.2 (i.e., highest remaining power, minimum number of hops, and lowest traffic numbers). The implementation of the proposal includes four parts.
4.1. Implementation of the SEP Method
As with LEACH, SEP in each round consists of two phases: setup phase and stability phase.
4.1.1. SetUp Phase
The setup phase is essentially the preparation stage of data transmission. This stage is primarily for the transmission of the control information, the formation of the clusters, and the random generation of the CHs. This stage, without data transmission, but with a series of preparatory work prior to data transmission, fully prepares for the data transfer.
This paper optimizes the CH selection algorithm and aims to let the nodes with more energy rather than less energy become the first cluster head in the clusters, thus avoiding the lesser energy node’s premature death because of the fast energy consumption while being elected as the CH and subsequently affecting the network lifetime. Therefore, the energy factor can be added during the process of the choosing CHs which ensures that the node with more residual energy can be elected to be the CH and all nodes run out of energy almost at the same time.
The critical aspect of the cluster setup phase is to set the threshold as . The selection of the CH in the SEP method is carried out from the advanced node and the normal node. The ratio of the advanced node in the total number of nodes is . Set the total nodes as . The energy of the advanced node is times larger than the normal node.
SEP provides constraints and limits for balancing energy consumption in order to extend the lifetime of the steady state. The advanced node is more likely to become a CH node than a normal node, which is fairly a constraint for the energy consumption. If the energy of each node is initialized to , the energy of each advanced nodes is . The total energy of the initial nodes in the network is .
Total energy of the SEP is times larger than the total energy of the LEACH.
Let the weighted selection probabilities of the normal node be and let the weighted selection probabilities of the advanced node be . They are defined as where the ratio of the advanced node in the total number of nodes is and the energy of the advanced node is times larger than the normal node.
, the threshold of the normal node, is the average probability of the normal node which has not yet become the CH in the round to be the CH. , the threshold of advanced node, is the average probability of the advanced node which has not yet become the CH in the round to be the CH. They could be obtained by (5) and (6). Consider where is the current round and is the set of normal nodes that have not been CHs within the last round at each step. is to ensure that each normal node can have the opportunity to become the CH node in the round at each step where is the current round and is the set of advanced nodes that have not been CHs in the last round at each step. is to ensure that each advanced node can have the opportunity to become the CH in the round at each step.
Figures 3 and 4 have shown the different situation of the cluster figures using the CAF algorithm. In these two figures, the Voronoi diagram was used to cluster the nodes in WSN. Consider a set of coplanar points P. For each point Px in the set P, you can draw a boundary enclosing all the intermediate points lying closer to Px than to other points in the set P. Such a boundary is called a Voronoi polygon, and the set of all Voronoi polygons for a given point set is called a Voronoi diagram which is composed of many Voronoi cells. Each cell has a CH.
In these two figures, “” is a normal node, “” is a CH, “+” is an advanced node, and “∙” is a dead node. If the nodes are alive, the nodes which are in the same Voronoi cell will report messages to the CH of this cell.
4.1.2. Stability Phase
The stability phase is the cluster communication phase. In the LEACH protocol, between the node in the cluster and the CH and between the CH and the base station both use direct single hop communication. The node in the cluster is close to the CH, so the easy direct communication can be used. However, the CH node is often far from the base station, and the transport energy consumption increases exponentially as the distance increases. Therefore, direct communication will consume a relatively large amount of energy of the CH. To solve this issue, the CAF protocol in this paper uses multihop communication to transmit data from the CH to the base station, which creates a multihop path tree using Astar method and fuzzy approach. Only the root node of the path or the independent node which has no parent node needs a long distance communication with the base station, while other CHs only need close communication within the sensing area.
After a period of the stability of the data transmission phase, the network reenters the setup phase of the cluster and goes to the next cycle of the cluster of refactoring. The flowchart of the SEP method is shown in Figure 5.
4.2. Implementation of Fuzzy Approach
Find the best node by integrating several factors in the problem, such as residual energy, traffic numbers, and minimum number of hops. This is equivalent to finding the optimal path from the start node to the sink node. For the fuzzy method, the fuzzy value is processed by FIS, which includes a rule base and various ways to infer these rules. There are a series of ifthen rules in rule base, and fuzzy sets are combined with the input and output fuzzy language variables which are described by the fuzzy implication operator to construct the FIS jointly.
To handle uncertainties, this paper has used the FIS for the probability computation of each node as shown in Figure 6. The two input variables for the FIS are the residual energy and the traffic numbers, and the single output parameter is the probability of a node to be selected as the best node in the optimal path. The greater the probability value will mean that the node has more chance to be a best node. The value range of RE is , the value range of TN is , and the probability is . According to the current simulation environment, the fields of fuzzy variables are selected for inputs as well as outputs. When the environment changes, the value ranges can be modified as well.
The values of the residual energy for fuzzy input variables are very low (VL), low (L), medium (M), high (H), and very high (VH). The values of the traffic number for fuzzy input variables are very low (VL), low (L), medium (M), high (H), and very high (VH). The values of the node probability for fuzzy output variables are very small (VS), small (S), medium (M), large (G), and very large (VG). Membership function (MF) is a curve, and it defines how each point of the input space is mapped to a membership between 0 and 1. This paper selects the Gaussian membership function as the membership function for input and output variables. Equation (7) shows the Gaussian membership function as follows: where and are the center and standard deviation of membership function, respectively.
The membership functions of the inputoutput fuzzy variables and surface viewer of the FIS are given in Figures 7 and 8, respectively. Nodes with small probability would not be selected as the next hop.
The probability calculation is accomplished using predefined fuzzy ifthen mapping rules to handle the uncertainty. Based on the two fuzzy input variables, 25 fuzzy mapping rules are defined in Table 1. From the fuzzy rules, the fuzzy variable probability can be obtained which has to be transformed to a single crisp number that is a form which can be used in practice. In the CAF approach, the process of output in fuzzy inference is actually a defuzzifier process. Generally, fuzzy rules can be generated either from heuristics or from experimental data. Fuzzy rules are used with the principle: a node which holds more remaining power and lower traffic numbers has a higher probability. The greater the probability of nodes as well as the lower the node hops is, the easier the node will be selected to be the next hop in the optimal path.

The defuzzification method adopted in this paper is the most commonly used formula of gravity calculation. The value of the probability obtained using the gravity method of the defuzzifier could be represented as where is the output of the rule base and is the center of the output membership functions. The flowchart of the AF algorithm is shown in Figure 9.
4.3. Implementation of AStar Algorithm
Astar algorithm which is used to find the optimal route from the CHs to the base station is applied to each CH and builds a multihop transmission path among CHs using a weight function . Evaluation function can be obtained via where and is cost of the CH node of the . The value of is obtained by the fuzzy inference algorithm which considers the residual energy, the minimum number of hops, and the traffic numbers of each node. Its range is . The maximum cost of the node is .
is the maximum distance from the base station in the network. The actual cost from the initial node (start node) to the next node is . The estimated cost of the optimal path from node to the target node (destination node) is , which depends on the heuristic information of the problem area [44]. In the above formula, is a constant, , which is used to balance the energy cost of the node and distance parameters. Clearly, the node with a larger cost will be closer to the base station.
4.4. Implementation of CAF Algorithm
CAF algorithm is divided into two steps. Firstly, apply the Stable Election Protocol (SEP) algorithm to the wireless sensor network in order to cluster. The nodes are divided into advanced nodes and normal nodes. The advanced node’s energy is two times the normal node. It is proposed to let the candidate nodes run for the CH based on the residual energy within a certain range, to make the even distribution of the CH. Secondly, among the CH nodes, the combined algorithms of the fuzzy inference and Astar method are used, taking into account the residual energy, minimum hops count, and traffic loads of each CH and looking for the best path from the source node to the destination node. Figures 10 and 11 present the results using the CAF routing method to find the optimal route. The pseudocode of the proposed CAF routing method is described as Algorithm 1.

5. Performance Evaluations
The simulation environment, parameters, and metrics are presented in this section, followed by the simulation results. This paper adopts the combined methods of the SEP method, the Astar algorithm, and the fuzzy approach, and experimental simulation results are given to evaluate the merits of the algorithm. This paper selects the SEP, AF, and Astar algorithms as a comparison of the CAF method. Simulation results show that the CAF algorithm performs better than others.
5.1. Simulation Environment
Construct a simulation environment of the algorithm test using the Matlab2010a. In order to verify the adaptive capacity of the CAF algorithm under different network topologies, this paper sets two topological regions, A and B. The region size of A is , while the region size of B is . According to the actual situation, coordinates of the base station are fixed and are far from the sensor nodes in the network, so this paper sets the base station coordinates as follows: A is and B is . In the two different topological regions, A and B, 100 nodes are placed randomly as a test network.
For nonclustering routing algorithms, such as AF and Astar, each node has the same initial energy of 0.55 J. For clustering routing algorithms, such as SEP and CAF, the initial energy of the advanced node is 1 J, and normal node’s initial energy is 0.5 J. The size of the message that nodes send to their CHs as well as the size of the (aggregate) message that a CH send to the sink is 2000 bits. The packet size is 2000 bit, and the initial ratio of CH is 0.1.
Simulations are done using the values 50 nJ/bit and 100 pJ/bit/m^{2} for and , respectively. Table 2 presents the systems parameters in detail.

5.2. Energy Model
Once the node is placed, it is no longer moved and the node died when the energy is zero. The experiment utilized a firstorder radio model [45] which is commonly used in the WSNs. The radio energy consumption model is shown in Figure 12.
The energy consumed by the sensor nodes in this paper is divided into two categories. First is the energy consumed by the normal or advanced node (nonCH and nonparent node). According to Figure 12, when the distance is and transmit bit message, the energy required by common sensor nodes while transmitting electronics can be defined as where is the packet size of transmitted data, is the distance between the sender and the receiver, is power circuits for sending or receiving, determined by the digital coding, modulation, filtering, and spread signal and other factors, and is the distance threshold. When the transmission distance is less than the threshold, the free space channel model is used. On the contrary, when the transmission distance is more than the threshold, the multipath fading channel model is used [46]. Amplifier power and is determined by transmission distance and the accepting error rate. When , let .
The received electronics energy consumption when the normal node receives the bit message is shown as
The next is the energy consumed by the CH or parent node (PN). As a CH or PN, except that the sending and receiving messages consume energy, the data processing also consumes the energy. The energy consumed by the CH or PN while transferring bit data can be obtained via where is the energy consumed by CH or PN while processing 1 bit message and is the distance between the sender and the receiver. The received energy circuit consumption for CH or PN when they receive bit message can be defined as
The values used in the firstorder radio model are described in Table 2.
5.3. Simulation Results
Handy et al. [47] proposed the metric first node dies (FND) and half of the nodes alive (HNA). FND metric is useful in these scenarios where it is necessary that all nodes stay alive as long as possible, since network quality decreases considerably as soon as one node dies, such as intrusion or fire detection. In these cases, it is important to know when the first node dies. HNA metric is useful in these scenarios where sensors are placed in proximity to each other. Adjacent sensors could record related or identical data. In these cases, the loss of a single or few nodes does not automatically diminish the quality of service of the network. Hence, HNA metric is useful in densely deployed sensor networks.
The rounds of FND and HNA are simulated using Astar, AF, CF, CA, SEP, and CAF, the six different approaches, for both areas A and B. The results are shown in Figures 13 and 14, respectively. Clearly, the CAF method outperforms the Astar, AF, CF, CA, and SEP algorithms in both areas, A and B. In Figure 13, the FND improvements 3240%, 1216%, 121%, 30%, and 104% are accomplished by comparing the algorithms of Astar, AF, CF, CA, and SEP, respectively. HNA improves by 282%, 270%, 51%, 39%, and 57%, while, in Figure 14, the FND improvements 3660%, 766%, 151%, 37%, and 42% are accomplished by comparing the algorithms of Astar, AF, CF, CA, and SEP, respectively. HNA improves by 275%, 264%, 41%, 43%, and 33%. It can be seen that the times for the FND and HNA in the proposed method are much longer than the times for the FND and HNA for all the three methods in both areas A and B.
Moreover, Figures 15 and 16 show the simulation results for this configuration. It can be seen that the number of nodes alive in the proposed method is always higher than that of all Astar, AF, CF, CA, and SEP algorithms. The two figures can also show that the performance of the SEP and CF algorithm is obviously affected by the topographic regions. The SEP and CF algorithm performance varies greatly in different topographic regions. In Figure 15 with the position of the sink node , the survival rate of nodes for SEP and CF algorithm is lower than those in Figure 16 with the position of the sink node , while the CAF algorithm this paper proposed has achieved good performance both in areas A and B. The CAF algorithm has a strong adaptive capacity under different network topologies.
Figures 17 and 18 show the total remaining energy of a WSN with the round number increasing for the six approaches in areas, A and B, respectively. This validates that the proposed CAF method actually consumes less energy than the Astar, AF, CF, CA, and SEP algorithms. A better energy balance in a WSN is achieved by the proposed method in both areas A and B. The simulation results indicate that the proposed CAF is superior to the other mechanisms in terms of FND, HNA, residual total energy, and the number of sensor nodes alive with different topographical areas.
From the aforementioned simulation results, it is clear that the proposed CAF method outperforms the AF algorithm, CF approach, CA algorithm, SEP method, and Astar approach in terms of balancing energy consumption and maximization of network lifetime. This is because the CAF algorithm selects a CH first. The CH is selected randomly from the advanced nodes as well as normal nodes and it always selects the node with the highest residual energy as a CH. The sensor nodes are clustered in the zone using the Voronoi cell and the member nodes send messages directly to the CH instead of the base station, which reduces the message communication distance of the member nodes greatly. Meantime, the AF routing algorithm is used to find the optimal path among the CHs. The multiple factors including the residual energy, traffic load, and minimum hop are taken into consideration to propose a metric of finding the next hop in the optimal path. In this way, the energy cost of CHs can be controlled in minimum in message communication. The CAF algorithm guarantees that the discovered routing path can remain consistent.
6. Conclusions
Energy is a major factor for designing WSNs in the real world. Unfortunately, the battery energy is inherently limited. Therefore, efficient utilization of the energy is most important. To improve the energy efficiency, many algorithms are proposed. One of the main characteristics of these algorithms shows that the network lifetime is highly related to the routing selection. This paper has proposed a cluster algorithm and the Astar with fuzzy method, called CAF, providing an energyefficient routing in WSNs. The main goal of the CAF algorithm is to prolong the lifetime of the WSN by evenly distributing the workload, retaining the remaining energy, and reducing the number of the hops. To achieve this goal, this paper has mostly focused on selecting proper CHs from existent sensor nodes and the optimum next hop from the CHs. The SEP algorithm has been used to choose the best CHs, while the Astar method and fuzzy approach is used to select the proper next hop of the optimal path.
Simulation results confirming the CAF method produce the following advantages. Firstly, this algorithm is stable and adaptable to different topologies; secondly, the algorithm has low energy consumption and effectively balances the energy consumption of each sensor node, and the algorithm significantly extends the survival time of the network.
In conclusion, the proposed CAF achieves a better FND, HNA, residual total energy, and the number of sensor nodes alive than the original SEP, Astar, CF, CA, and AF techniques with different topographical areas. However, in the real world, there may be certain situations that one or even more of the sensors in the critical pathway becomes intermittent in the ability to function normally. Such behavior may add performance noise (fluctuations) into the WSNs. Ongoing research is investigating the practicality of using the CAF routing protocol for data gathering in WSNs.
Conflict of Interests
The authors declare that there is no conflict of interests regarding the publication of this paper.
Acknowledgments
The authors would like to thank to the Natural Science Foundation of China (61073193 and 61300230), the Key Science and Technology Foundation of Gansu Province (1102FKDA010), Natural Science Foundation of Gansu Province (1107RJZA188), and the Science and Technology Support Program of Gansu Province (1104GKCA037) for supporting this research.
References
 I. F. Akyildiz, W. Su, Y. Sankarasubramaniam, and E. Cayirci, “A survey on sensor networks,” IEEE Communications Magazine, vol. 40, no. 8, pp. 102–105, 2002. View at: Publisher Site  Google Scholar
 X. Wang, J. Ma, S. Wang, and D. Bi, “Distributed energy optimization for target tracking in wireless sensor networks,” IEEE Transactions on Mobile Computing, vol. 9, no. 1, pp. 73–86, 2010. View at: Publisher Site  Google Scholar
 H. Mahboubi, A. Momeni, A. G. Aghdam, K. SayrafianPour, and V. Marbukh, “An efficient target monitoring scheme with controlled node mobility for sensor networks,” IEEE Transactions on Control Systems Technology, vol. 20, no. 6, pp. 1522–1532, 2011. View at: Publisher Site  Google Scholar
 M. CastilloEffen, D. H. Quintela, R. Jordan, W. Westhoff, and W. Moreno, “Wireless sensor networks for flashflood alerting,” in Proceedings of the 5th IEEE International Caracas Conference on Devices, Circuits and Systems (ICCDCS '04), pp. 142–146, November 2004. View at: Google Scholar
 Q. Ling, Z. Tian, Y. Yin, and Y. Li, “Localized structural health monitoring using energyefficient wireless sensor networks,” IEEE Sensors Journal, vol. 9, no. 11, pp. 1596–1604, 2009. View at: Publisher Site  Google Scholar
 L. Wang, G.Z. Yang, J. Huang et al., “A wireless biomedical signal interface systemonchip for body sensor networks,” IEEE Transactions on Biomedical Circuits and Systems, vol. 4, no. 2, pp. 112–117, 2010. View at: Publisher Site  Google Scholar
 G. WernerAllen, K. Lorincz, M. Welsh et al., “Deploying a wireless sensor network on an active volcano,” IEEE Internet Computing, vol. 10, no. 2, pp. 18–25, 2006. View at: Publisher Site  Google Scholar
 H.C. Lin, Y.C. Kan, and Y.M. Hong, “The comprehensive gateway model for diverse environmental monitoring upon wireless sensor network,” IEEE Sensors Journal, vol. 11, no. 5, pp. 1293–1303, 2011. View at: Publisher Site  Google Scholar
 D. Dardari, A. Conti, C. Buratti, and R. Verdone, “Mathematical evaluation of environmental monitoring estimation error through energyefficient wireless sensor networks,” IEEE Transactions on Mobile Computing, vol. 6, no. 7, pp. 790–802, 2007. View at: Publisher Site  Google Scholar
 S. Cui, A. J. Goldsmith, and A. Bahai, “Energyconstrained modulation optimization,” IEEE Transactions on Wireless Communications, vol. 4, no. 5, pp. 2349–2360, 2005. View at: Publisher Site  Google Scholar
 J. N. AlKaraki and A. E. Kamal, “Routing techniques in wireless sensor networks: a survey,” IEEE Wireless Communications, vol. 11, no. 6, pp. 6–27, 2004. View at: Publisher Site  Google Scholar
 S. C. Ergen and P. Varaiya, “PEDAMACS: power efficient and delay aware medium access protocol for sensor networks,” IEEE Transactions on Mobile Computing, vol. 5, no. 7, pp. 920–930, 2006. View at: Publisher Site  Google Scholar
 J. C. F. Li, S. Dey, and J. Evans, “Maximal lifetime power and rate allocation for wireless sensor systems with data distortion constraints,” IEEE Transactions on Signal Processing, vol. 56, no. 5, pp. 2076–2090, 2008. View at: Publisher Site  Google Scholar  MathSciNet
 C. Karakus, A. Gurbuz, and B. Tavli, “Analysis of energy effficiency of compressive sensing in wireless sensor networks,” IEEE Sensors Journal, vol. 13, no. 5, pp. 1999–2008, 2013. View at: Publisher Site  Google Scholar
 M.J. Tsai, H.Y. Yang, and W.Q. Huang, “Axisbased virtual coordinate assignment protocol and deliveryguaranteed routing protocol in wireless sensor networks,” in Proceedings of the 26th IEEE International Conference on Computer Communications (INFOCOM '07), pp. 2234–2242, May 2007. View at: Publisher Site  Google Scholar
 M. A. Azim and A. Jamalipour, “Performance evaluation of optimized forwarding strategy for flat sensor networks,” in Proceedings of the 50th Annual IEEE Global Telecommunications Conference (GLOBECOM '07), pp. 710–714, November 2007. View at: Publisher Site  Google Scholar
 S.S. Wang and Z.P. Chen, “LCM: a linkaware clustering mechanism for energyefficient routing in wireless sensor networks,” IEEE Sensors Journal, vol. 13, no. 2, pp. 728–736, 2013. View at: Publisher Site  Google Scholar
 Y. Liao, H. Qi, and W. Li, “Loadbalanced clustering algorithm with distributed selforganization for wireless sensor networks,” IEEE Sensors Journal, vol. 13, no. 5, 2013. View at: Google Scholar
 G. Smaragdakis, I. Matta, and A. Bestavros, “SEP: a stable election protocol for clustered heterogeneous wireless sensor networks,” in Proceedings of the 2nd International Workshop on Sensor and Actor Network Protocols and Applications (SANPA '04), Boston, Mass, USA, 2004. View at: Google Scholar
 I. Gupta, D. Riordan, and S. Sampalli, “Clusterhead election using fuzzy logic for wireless sensor networks,” in Proceedings of the 3rd Annual Communication Networks and Services Research Conference (CNSR '05), pp. 255–260, May 2005. View at: Publisher Site  Google Scholar
 J. S. Lee and W. L. Cheng, “Fuzzylogicbased clustering approach for wireless sensor networks using energy predication,” IEEE Sensors Journal, vol. 11, no. 9, pp. 2891–2897, 2012. View at: Google Scholar
 K. M. Rana and M. A. Zaveri, “ASSER: a routing method to extend life of twotiered wireless sensor network,” International Journal of Advanced Smart Sensor Network Systems, vol. 11, no. 2, pp. 1–16, 2011. View at: Google Scholar
 I. S. Alshawi, L. Yan, W. Pan, and B. Luo, “Lifetime enhancement in wireless sensor networks using fuzzy approach and Astar algorithm,” IEEE Sensors Journal, vol. 12, no. 10, pp. 3010–3018, 2012. View at: Google Scholar
 W. Heinzelman, Applicationspecific protocol architectures for wireless networks [Ph.D. thesis], Massachusetts Institute of Technology, 2000.
 Y. M. Lu and V. W. S. Wong, “An energyefficient multipath routing protocol for wireless sensor networks,” International Journal of Communication Systems, vol. 20, no. 7, pp. 747–766, 2007. View at: Publisher Site  Google Scholar
 W. Dargie and C. Pollabauer, “Network layer,” in Fundametal of Wireless Sensor Networks Theory and Practice, pp. 163–204, Wiley, 2010. View at: Google Scholar
 S.Y. Chiang and J.L. Wang, “Routing analysis using fuzzy logic systems in wireless sensor networks,” in KnowledgeBased Intelligent Information and Engineering Systems, vol. 5178 of Lecture Notes in Computer Science, no. 2, pp. 966–973, 2008. View at: Publisher Site  Google Scholar
 C. Park and I. Jung, “Trafficaware routing protocol for wireless sensor networks,” in Proceedings of the International Conference on Information Science and Applications, pp. 1–8, April 2010. View at: Google Scholar
 W. B. Heinzelman, A. P. Chandrakasan, and H. Balakrishnan, “An applicationspecific protocol architecture for wireless microsensor networks,” IEEE Transactions on Wireless Communications, vol. 1, no. 4, pp. 660–670, 2002. View at: Publisher Site  Google Scholar
 L. A. Zadeh, “Soft computing and fuzzy logic,” IEEE Software, vol. 11, no. 6, pp. 48–56, 1994. View at: Publisher Site  Google Scholar
 K. L. Tang and R. J. Mulholland, “Comparing fuzzy logic with classical controller designs,” IEEE Transactions on Systems, Man and Cybernetics, vol. 17, no. 6, pp. 1085–1087, 1987. View at: Google Scholar
 C.W. Xu and Y.Z. Lu, “Fuzzy model identification and selflearning for dynamic systems,” IEEE Transactions on Systems, Man and Cybernetics, vol. 17, no. 4, pp. 683–689, 1987. View at: Google Scholar
 C. C. Lee, “Fuzzy logic in control systems: fuzzy logic controller—part I,” IEEE Transactions on Systems, Man and Cybernetics, vol. 20, no. 2, pp. 404–418, 1990. View at: Publisher Site  Google Scholar  MathSciNet
 J. J. Simpson and R. H. Keller, “An improved fuzzy logic segmentation of sea ice, clouds, and ocean in remotely sensed arctic imagery,” Remote Sensing of Environment, vol. 54, no. 3, pp. 290–312, 1995. View at: Google Scholar
 J. Schneider, N. Bitterlich, and G. Schulze, “Improved sensitivity in the diagnosis of gastrointestinal tumors by fuzzy logicbased tumor marker profiles including the tumor M2PK,” Anticancer Research, vol. 25, no. 3A, pp. 1507–1515, 2005. View at: Google Scholar
 M. N. Uddin and M. A. Rahman, “Highspeed control of IPMSM drives using improved fuzzy logic algorithms,” IEEE Transactions on Industrial Electronics, vol. 54, no. 1, pp. 190–199, 2007. View at: Publisher Site  Google Scholar
 Q. Deng, D.L. Xie, and S.Z. Chen, “A fuzzy logic based QoS evaluation model for wireless sensor network,” in Proceedings of the 5th International Conference on Wireless Communications, Networking and Mobile Computing (WiCOM '09), pp. 1–4, September 2009. View at: Publisher Site  Google Scholar
 F.J. Chang and Y.T. Chang, “Adaptive neurofuzzy inference system for prediction of water level in reservoir,” Advances in Water Resources, vol. 29, no. 1, pp. 1–10, 2006. View at: Publisher Site  Google Scholar
 V. Sugumaran and K. I. Ramachandran, “Automatic rule learning using decision tree for fuzzy classifier in fault diagnosis of roller bearing,” Mechanical Systems and Signal Processing, vol. 21, no. 5, pp. 2237–2247, 2007. View at: Publisher Site  Google Scholar
 P. E. Hart, N. J. Nilsson, and B. Raphael, “A formal basis for the heuristic determination of minimumcost paths,” IEEE Transactions on Systems Science and Cybernetics, vol. 4, no. 2, pp. 100–107, 1968. View at: Publisher Site  Google Scholar
 S. Bandi and D. Thalmann, “Path finding for human motion in virtual environments,” Computational Geometry: Theory and Applications, vol. 15, no. 1–3, pp. 103–127, 2000. View at: Google Scholar
 D. Delling, P. Sanders, D. Schultes, and D. Wagner, “Engineering route planning algorithms,” Algorithmics of Large and Complex Networks, Springer, vol. 5515, pp. 117–139, 2009. View at: Publisher Site  Google Scholar
 X. H. Li, S. H. Hong, and K. L. Fang, “WSNHAGAHR: a greedy and A* heuristic routing algorithm for wireless sensor networks in home automation,” IET Communications, vol. 5, no. 13, pp. 1797–1805, 2011. View at: Publisher Site  Google Scholar
 K. M. Passino and P. J. Antsaklis, “Metric space approach to the specification of the Heuristic function for the A* algorithm,” IEEE Transactions on Systems, Man and Cybernetics, vol. 24, no. 1, pp. 159–166, 1994. View at: Publisher Site  Google Scholar
 W. R. Heinzelman, A. Chandrakasan, and H. Balakrishnan, “Energyefficient communication protocol for wireless microsensor networks,” in Proceedings of the 33rd Annual Hawaii International Conference on System Siences (HICSS '00), pp. 1–10, January 2000. View at: Google Scholar
 T. S. Rappaport, Wireless Communications: Principles and Practice, PrenticeHall, Englewood Cliffs, NJ, USA, 2002.
 M. J. Handy, M. Haase, and D. Timmermann, “Low energy adaptive clustering hierarchy with deterministic clusterhead selection,” in Proceedings of the International Workshop Mobile and Wireless Communication Networks, pp. 368–372, 2002. View at: Google Scholar
Copyright
Copyright © 2014 Yali Yuan et al. This is an open access article distributed under the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.