A Greedy Heuristic for Maximizing the Lifetime of Wireless Sensor Networks Based on Disjoint Weighted Dominating Sets

Dominating sets are among the most well-studied concepts in graph theory, with many realworld applications especially in the area of wireless sensor networks. One way to increase network lifetime in wireless sensor networks consists of assigning sensors to disjoint dominating node sets, which are then sequentially used by a sleep–wake cycling mechanism. This paper presents a greedy heuristic for solving a weighted version of the maximum disjoint dominating sets problem for energy conservation purposes in wireless sensor networks. Moreover, an integer linear programming model is presented. Experimental results based on a large set of 640 problem instances show, first, that the integer linear programming model is only useful for small problem instances. Moreover, they show that our algorithm outperforms recent local search algorithms from the literature with respect to both solution quality and computation time.


Introduction
Wireless sensor networks (WSNs) have received increasing attention in the last decade due to their potential applications in various fields such as environmental monitoring, medical and health applications, security surveillance and emergency operations [1]. They are generally composed of a rather large number of small devices, called sensors, with a limited low-power supply that depletes rather quickly. The lifetime of a sensor device (in hours) is generally calculated by dividing the battery capacity (in Watt hours) by the average power drain (in Watts). However, as the energy consumption also depends on other factors-such as, for example, the operating temperature-the estimation of the lifetime of a sensor node is not trivial [2]. One of the most challenging issues in WSNs is extending the lifetime of the network while providing sufficient sensing coverage and communication reliability. The lifetime of a network is defined as the time (duration) in which the network is fully functional with respect to the tasks that have to be fulfilled, that is, the time duration in which the overall sensing coverage is maintained. Therefore, WSN lifetime significantly depends on the energy consumption of sensors in the context of limited energy availability. Examples of real-world applications for maximizing sensor network lifetime can be found in [3] (human activity monitoring), [4] (smart agriculture monitoring), [5] (road traffic monitoring), and [6] (structural health monitoring).
According to [7], power saving strategies can usually be classified under one of the following mechanisms: • Sleep-wake cycling (also called duty cycling): Sensors switch between active and sleep mode. • Power control by adjusting the transmission range of wireless nodes.
• Energy efficient routing, and data gathering. • Reducing the amount of transmitted data and avoiding useless activity.
This study focuses on the first possibility, in the following way. The problem of extending (prolonging) WSN lifetime is addressed by organizing the sensors into a number of disjoint subsets that are activated successively. We require that each of these subsets is a dominating set of the communication graph defined by a sensor network. Note that, given the locations of the sensors, the communication graph is obtained by joining two sensors with an edge in case they can communicate with each other via their wireless antennas. The requirement of a subset of sensors being a dominating set is introduced such that each subset of nodes is able to cover the whole coverage area.
The maximization of network lifetime has been studied in the literature from different perspectives. Most of them addressed the problem either via the set K-cover problem (also known as the target coverage problem) or as the domatic partition problem (also known as the maximum disjoint dominating sets problem). Slijepcevic and Potkonjak [8] were the first ones to model the problem as a set K-cover problem and proved its NP-hardness using a polynomial time transformation from the minimum cover problem. The set K-cover problem is defined over a bipartite graph of two node sets (sensors and targets) with the aim to partition the sensors into a maximum number of disjoint sets (covers) over all targets. These sensor covers are then activated one after the other to effectively extend the WSN lifetime. The sensors of an active cover are able to monitor the entire set of targets. Due to the hardness of the problem, a variety of approximate algorithms have been devised, also for different variants of the problem. Examples include a greedy heuristic [8], memetic algorithms [9][10][11], cuckoo search [12] and a genetic algorithm [13].
As mentioned before, the maximization of the lifetime of WSNs is often approached through the domatic partition problem in which the goal is to find a partition of the nodes of a given network-represented as a simple, undirected graph-into a maximum number of disjoint dominating sets. Throughout this paper, we refer to the domatic partition problem as maximum disjoint dominating sets (MDDS) problem. The MDDS problem, which belongs to the large and important family of dominating set problems [14][15][16], is known to be NP-hard for general graphs [17]. Cardei et al. [18] proved the NP-completeness of one of its variants known as the 3-disjoint dominating sets problem that asks for deciding whether or not a given graph contains three disjoint dominating sets. The same authors showed that, unless P = NP, the MDDS problem has no polynomial-time approximation with a performance guarantee of less than 1.5. They also introduced a heuristic approach based on graph coloring. In the same year, Feige et al. [19] proved that every graph of order n with maximum degree ∆ and minimum degree δ includes a domatic partition (a collection of disjoint dominating sets) of size (1 − o(1))(δ + 1)/ ln ∆. Here, the term o(1) tends to zero as n increases. Moreover, they showed that there is no approximation algorithm for the MDDS problem with an approximation ratio of (1 + o(1)) ln n unless NP ⊆ DTI ME(n O(log log n) ). The same authors also provided a centralized algorithm to find a domatic partition of size Ω(δ/ ln ∆). Based on this later work, Moscibroda and Wattenhöfer [20] defined the MDDS problem as the maximum cluster-lifetime problem and introduced a randomized, distributed algorithm that has-with high probability-a performance ratio of O(log(n)). Nguyen and Huynh [21] demonstrated that the 3-disjoint dominating sets problem remains NP-complete even for planar unit disk graphs and studied the performance comparison of four greedy heuristics for the MDDS problem. In [22], a greedy heuristic of time complexity O(n 3 ) is described. More recently, Pino et al. [23] focused on a weighted variant of the MDDS problem which is henceforth labelled the maximum weighted disjoint Dominating Sets (MWDDS) problem. In this problem, each node of the input graph-corresponding to a deployed sensor device-carries a weight that corresponds to its remaining lifetime. The lifetime of a dominating set is then defined as the minimum of the lifetimes of the nodes that form part of the set. The optimization goal of the MWDDS is to find a domatic partition such that the sum of the lifetimes of the corresponding dominating sets is maximized. Pino et al. devised three local search algorithms for the MWDDS problem. Each local search algorithm is seeded with an initial feasible solution generated by a modified greedy heuristic from [22] and iteratively swaps nodes between different dominating sets in the solution, in the hope to increase the total lifetime of the network. These local search approaches differ in the way they realize the swaps.
The main contributions of this paper can be summarized as follows: • We introduce an integer linear programming (ILP) model for the MWDDS problem. • We propose an efficient greedy heuristic for the MWDDS problem. • We conduct comprehensive experiments on a set of 640 problem instances in order to investigate the performance and the advantages of our greedy heuristic in comparison to the application of CPLEX and to recent state-of-the-art methods.
The rest of this paper is organized as follows. In Section 2 we provide a technical description of the MWDDS problem and recall some required notations and basic definitions. Next, an ILP model for the MWDDS problem is presented in Section 3. In Section 4, we introduce a new greedy algorithm. Finally, in Section 5 we present and discuss the experimental results, while Section 6 summarizes the work and offers directions for future work.

The Maximum Weighted Disjoint Dominating Sets Problem
Let G = (V, E, lifetime) be a simple, undirected, node-weighted graph, where V (with |V| = n) is the set of nodes, E ⊆ V × V (with |E| = m) is the set of edges, and lifetime : V → R + is a weight function that assigns a positive weight value lifetime(v) > 0 to each node v ∈ V. Note that such a graph may represent the communication graph of a WSN, and the node weight may represent the lifetime of the node. However, before technically introducing the MWDDS problem, let us briefly recall some basic definitions and notations used throughout this paper. For more details on graph theoretic aspects, the readers may refer to [24]. We say that two nodes v = u ∈ V are neighbors (adjacent to each other) if and only if there exists an edge between them, that is, Definition 1 (Dominating set). A subset D ⊆ V of the nodes of a simple, undirected graph G = (V, E) is called a dominating set of G if and only if each node v ∈ V \ D has at least one neighbor in D. Each node in a dominating set D is called a dominator, otherwise it is called a dominatee. A dominator dominates (covers) itself and all its neighbors.
Note, for example, that-given a simple, undirected graph G = (V, E)-the complete set of nodes (V) is a dominating set. Definition 2 (Domatic partition). A set D = {D 1 , D 2 , · · · , D k } of subsets D i ⊆ V is called a domatic partition of a simple, undirected graph G = (V, E), if each D i (i = 1, . . . , k) is a dominating set of G and all sets of D are pairwise disjoint, which is the case if for all 1 ≤ i < j ≤ k it holds that D i ∩ D j = ∅.
Definition 3 (Domatic number). The domatic number of a simple, undirected graph G = (V, E) is determined as |D * | where D * := argmax{|D| | D is a domatic partition of G}. In other words, the domatic number of G is the size of the largest domatic partition of G. It is known that the domatic number of a graph G is limited from above by δ + 1, where δ is the minimum degree of the nodes in V.
Given a simple, undirected graph G = (V, E), the maximum disjoint dominating sets (MDDS) problem requires to find a domatic partition of G of maximal size. Furthermore, given a graph G = (V, E, lifetime) as introduced above, the maximum weighted disjoint dominating sets (MWDDS) problem is defined as follows. Any domatic partition D of G is a valid solution. The objective function value of a valid solution D In other words, the quality of a subset D i is determined as the minimum lifetime of all its nodes. The objective is to find a valid solution D * that maximizes f (). More formally, the problem can be expressed as follows: Equation (3) ensures that each set D i is a dominating set and Equation (4) asks for all subsets of D to be pairwise disjoint. Figure 1 provides an illustrative example of the MWDDS problem. Figure 1a,b provide a problem instance and the lifetime values of the nodes in terms of node weights, respectively. Note that, for the sake of simplicity, the lifetime values are normalized between 0 and 1. Figure 1c shows a feasible solution D :

Illustrative Example
The lifetimes of nodes 3 and 4 are 0.775 and 0.424, respectively. Therefore, the lifetime of D 1 is 0.424. Moreover, the lifetimes of nodes 1, 5, and 6 are 0.804, 0.782 and 0.021, respectively. This means that the lifetime of D 2 is 0.021. As a consequence, the objective function value f (D) of D is the sum of 0.424 and 0.021, which results in 0.445. In contrast, Figure 1d shows the optimal solution to this problem instance, that is, D * : According to the lifetime values of the single nodes, the lifetime of D 1 is 0.775, while the lifetime value of D 2 is 0.021. Therefore, the objective function value f (D * ) of D * is 0.796. Finally, note that, since this graph contains a node of degree 1, any valid solution contains at most two disjoint dominating sets.

An ILP Model for the MWDDS Problem
Our ILP model for the MWDDS problem requires the following sets of variables. First, we introduce a binary variable x ij for each node v i (i = 1, . . . , n) and each possible disjoint set D j (j = 1, . . . , δ(G) + 1). Hereby, δ(G) := min{deg(v) | v ∈ V}. (Remember that the maximum number of disjoint dominating sets in a graph is δ(G) + 1.) When x ij = 1, node v i is assigned to the j-th dominating set. Second, a binary variable y j (j = 1, . . . , δ(G) + 1) indicates whether or not the j-th set is opened. Finally, a real-valued variable z j ∈ [0, M] (M ∈ R + ) stores the weight of the j-th dominating set. Hereby, Based on these variables, the MWDDS can be stated as an ILP in the following way.
The objective function sums over the weight values of all dominating sets. Note that, for this objective function to be correct, the weight value of those dominating sets that are not opened must be set to zero by respective constraints. Constraints (6) require that each node of the graph is assigned to at most one dominating set. This assures the disjointness of the dominating sets. Next, constraints (7) are the so-called dominating set constraints, that is, they ensure that, if the j-th set is opened, then the set of nodes assigned to the j-th set form a dominating set of G. Further, constraints (8) make sure that nodes can only be assigned to opened dominating sets. Constraints (9) are responsible for correctly determining the weights of the opened dominating sets. In other words, the value of variable z j of the j-th dominating set (if open) is set to the minimum of the lifetime-values of all nodes assigned to this set. Next, constraints (10) ensure that the weight values of dominating sets that are not opened are set to zero. Finally, the last two sets of constraints-that is, constraints (11) and (12)-are not necessary for the correctness of the ILP. They are tie-breaking constraints that ensure that (1) if k dominating sets are opened, they are assigned to sets 1, . . . , k and (2) the opened dominating sets are ordered according to a non-increasing weight value.

Proposed Greedy Heuristic
Greedy algorithms are constructive heuristics for building feasible solutions to combinatorial optimization problems. They start from an empty solution and iteratively add the most favorable component from a set of feasible extensions of the current partial solution until a complete solution is reached. That is, the component to be added at each construction step is chosen deterministically according to some greedy function, which is a measure for the goodness of the solution components. In general, greedy heuristics do not require overly large computation times. The main drawback of a greedy heuristic is that the single constructed solution is most likely not optimal.
The pseudo-code of our greedy algorithm, henceforth labelled GH-MWDDS, is presented in Algorithm 1. Note that our greedy algorithm is a centralized algorithm which must be executed on a central unit that has the knowledge about the topology of the network and about the lifetime values of the individual nodes. At the start of the algorithm, the following sets are initialized. Solution D is initialized to the empty set. Furthermore, set V rem , which contains all nodes that may still be added to a dominating set, is initialized to V. Finally, set V done , which collects all nodes that already form part of a dominating set in D, is initialized to the empty set. Counter k counts the number of dominating sets that are being constructed. It is initialized to zero. At each main iteration k ≥ 1, the algorithm generates a dominating set D k consisting of nodes from set V rem which, as mentioned above, contains all nodes of G that do not form part of any of the already generated dominating sets D i , i = 1, . . . , k − 1; see lines 5 and 21. The algorithm stops once no further dominating set can be generated from the nodes in V rem . This is the case if at least one node v ∈ V and all its neighbors form part of V done . More formally, the algorithm stops if there is at least one v ∈ V such that N[v] is a subset of V done (see line 5).
for each node v ∈ V do 8: color(v) ← WHITE 9: end for 10: for each node u ∈ N(v * ) do 16: if ( color(u) = WHITE ) then 17: color(v) ← GRAY 18: end if 19: end for 20: color(v * ) ← BLACK 21: end while 22: The construction of a dominating set D k at round k of the algorithm is done as follows. First, D k is initialized to the empty set. At each moment, each node of the input graph G belongs to one of the following sets: Remember, in this context, that N(D k ) and N[D k ] denote the open neighborhood and the closed neighborhood of D k , respectively. Given these definitions, D k is iteratively generated by adding at each construction step exactly one node from {G(D k ) ∪ W (D k )} ∩ V rem , that is, a nodes that is (1) either gray or white, and (2) that is not already added to one of the dominating sets from previous rounds. In order to make this choice, all nodes from {G(D k ) ∪ W (D k )} ∩ V rem are evaluated by means of greedy function score(), which is defined as follows: In other words, the greedy function of a node v is obtained by multiplying the lifetime of the node with the number of white nodes from the closed neighborhood of v.
To further improve the quality of solutions, the dominating set D k might be reduced by removing redudant nodes before adding D k to solution D. This is done in the optional function Reduce(D k , V rem , V done ); see line 22 of the pseudo-code. Formally, a node v ∈ D k is redundant if each node from its closed neighborhood N[v] is dominated by at least two nodes from D k , that is, N[v] ⊂ u∈D k \{v} N[u] [25]. Redundant nodes are identified and removed in an iterative way. Moreover, sets V rem and V done are updated accordingly.

Time Complexity of GH-MWDDS
In this section, we analyze the complexity of our greedy algorithm, without the optional reduction mechanism from line 22. The main while loop (line 5) of the algorithm is iterated k times (rounds), where k refers to the number of disjoint dominating sets returned by the algorithm. Since the maximum number of dominating sets in a domatic partition of a graph G = (V, E) is less or equal to δ + 1 [19], where δ is the minimum degree of any node of G, it holds that k ≤ δ + 1. As a result, checking the condition in line 5 and executing lines 7-9 is both done in O(δ · n) time. Further, n is clearly an upper bound for the number of times that the inner while loop (lines 11-21) is iterated. To determine the time complexity of line 12, we proceed as follows. Remember that for any node v the calculation of its white_degree(v) value requires deg(v) operations. Moreover, for choosing the first node v * 1 of a dominating set, line 12 requires a time of deg(v 1 ) + deg(v 2 ) + · · · + deg(v n ).

Experimental Evaluation
The proposed greedy algorithm (GH-MWDDS) was implemented in ANSI C++ using GCC 7.4.0 for compiling the software. Its performance was compared with three recent local search approaches available from the related literature [23]: Local Search (LS), Fixed Depth (FD), and Variable Depth (VD). In order to conduct a fair comparison to the three local search algorithms (LS, FD and VD) we used the original source code provided by the authors of [23]. GH-MWDDS and the three local search algorithms were experimentally evaluated on a laptop equipped with a 64-bit 2.5-GHz Intel® Core™ i5-7200U processor and 8 GB of RAM. We applied GH-MWDDS to a set of 640 problem instances that are described below. Moreover, in order to test the usefulness of our ILP model, we applied the ILP solver ILOG CPLEX 20.01 in single-threaded mode to all problem instances. The time limit for each application of CPLEX was set to 2 CPU hours. Moreover, the experiments with CPLEX were performed on a cluster of machines with two Intel ® Xeon ® Silver 4210 CPUs with 10 cores of 2.20 GHz and 92 Gbytes of RAM.

Problem Instances
We used the source code provided in [23] for generating 640 diverse problem instances. Each problem instance was generated according to two control parameters: The size of the network n (number of nodes) and its average degree d, where d = 2m/n and m is the number of edges. More specifically, we considered five different network sizes: 50, 100, 150, 200 and 250 nodes. For each network size, we considered between 5 to 8 different average degrees in a way such that networks over a range from sparse to dense networks are generated. In addition, each node (sensor) of the network was given a random real value between 0 and 1 as node weight (lifetime). Then, for each combination of n and d, 20 different networks were randomly generated resulting in a total of 640 problem instances for the experimental evaluation. Table 1 reports on the performance comparison of GH-MWDDS (without the optional reduction procedure) and LS, FD, VD, and CPLEX. The first two columns indicate the problem instance type. More specifically, the number of nodes (n) is provided in the first column, whereas the average degree (d) is shown in the second column. Obviously, the higher d, the more dense is the network. Remember that for each combination of n and d-that is, for each table row-there are 20 randomly generated problem instances. The values shown in the tables represent the average results obtained for these 20 instances per table row. Table columns 3  In addition to evaluating GH-MWDDS, we also tested the following two additional versions. Henceforth we refer to the version of GH-MWDDS that removes redundant nodes in line 22 as GH-MWDDS + . In addition, the algorithm can be easily adapted in order to solve the maximum disjoint dominating sets (MDDS) problem, instead of the MWDDS. The resulting greedy algorithm, which is called GH-MDDS, is obtained by replacing the score(·) function in line 12 of Algorithm 1 by the white_degree(·) function of Equation (14). The experiential results obtained with GH-MDDS and GH-MWDDS + are provided in Table 2, whose structure is very similar to the one of Table 1.

Results and Discussion
From the results displayed in Tables 1 and 2, the following observations can me made: • First of all, the ILP model (solved by CPLEX) is only useful in the context of the smallest problem instances. In fact, CPLEX obtains the best results for all networks with 50 nodes. As an additional information we can say that CPLEX was able to solve 8 out of 20 problem instances with 50 nodes and an average degree of 15 to optimality. Figure 2 exemplary shows the optimal solution obtained by CPLEX for network number 14 of those networks with 50 nodes and an average node degree of 15. Note that the nodes are divided into six dominating sets (as indicated by the colors of the nodes). The nodes which are colored in green are not assigned to any dominating set. • CPLEX already starts to fail for the instances with 100 nodes, for which the results are already inferior to those of GH-MWDDS. In fact, for most of the problem instances (starting from 150 nodes and an average degree of 60) CPLEX is unable to find anything but the trivial solution that contains no dominating set. • Concerning GH-MWDDS, we can observe that it dominates the three competitors from the literature for all problem instances in terms of solution quality as well as computational time. It is significantly better than the best of the other three approaches, while requiring a computation time that is approximately five orders of magnitude smaller than the time needed by the other methods. The improvement ratio of our algorithm with respect to VD (the best approach from the literature) is about 5.37.
• As expected, most solutions suffer from the existence of redundant nodes. As a result, GH-MWDDS + is able to produce solutions whose size (in terms of the number of disjoint dominating sets) is increased with respect to the solutions produced by GH-MWDDS. This is achieved without compromising the quality of the generated solutions. On the contrary, the quality of the obtained solutions is slightly improved, at the cost of a negligible amount of computation time. • In addition, from Table 2 we can observe that GH-MDDS and GH-MWDDS + achieve an overall average solution quality (see that last row of Table 2) of 3.667 and 9.515, respectively, and an average solution size (in terms of the number of disjoint dominating sets) of 24.089 and 21.541, respectively. It is worthwhile to note that GH-MDDS always produces solutions with the maximum possible size (equal to δ(G) + 1). However, the quality of these solutions (as measured by the objective function of the MWDDS problem) is, of course, lower than the quality of the solutions produced by GH-MWDDS. This is because GH-MDDS is primarily focused on finding solutions of large size, without taking into consideration the problem-specific knowledge of the lifetime values of the nodes. Therefore, a solution to the MWDDS problem with the maximum size does not necessarily correspond to the best MWDDS-solution. For example, in the case where n = 250 and d = 140, for which GA-MDDS finds a solution with an average value 9.584 and an average size 53.6, GH-MWDDS + finds solutions with an average value 22.514 and average size 47.7. • From above observations we can say that the poor performance of the three local search algorithms proposed by Pino et al. [23] is mainly due to greedy heuristic used for producing the initial solutions for their local search approaches. Since this greedy heuristic was developed for the MDDS problem, and the local search approaches try to improve these solutions by making swaps among nodes of different disjoint dominating sets, they are limited to the size of the solutions found by the initial greedy heuristic, which cannot be changed later. As can be seen by our results, this way of proceeding limits too much the possibility of the local search algorithms to find improvements.
In summary we can say that our GH-MWDDS approach is clearly a new state-of-theart method for the MWDDS problem. In order to study the scalability of our approach, we finally generated two large-scale random geometric graphs with 10,000 nodes. Both graphs were generated by scattering 10,000 nodes randomly in the unit square, and connecting each pair of nodes whose geometric distance is below r = 0.02 (first graph), respectively r = 0.03 (second graph). The first graph has 61,646 edges, while the second one has 137,317 edges. The computation time of GH-MWDDS was 1.829 seconds for the first graph and 5.054 seconds for the second graph. This difference in computation time between the first and the second graph is due to the different density, which leads to a solution with two dominating sets in the case of the first graph and a solution with six dominating sets in the case of the second graph. The important point, however, is that the computation time of our algorithm is still very low, even in the context of large-scale graphs. The solutions of GH-MWDDS are graphically shown in Figure 3. Note that, in the case of the first graph, red and green nodes form dominating sets, while all but the pink-colored nodes in the case of the second graph are assigned to six different dominating sets.

Conclusions
This paper deals with the network lifetime maximization problem using the approach of computing disjoint dominating sets in a given network in which sensors are characterized by different lifetime values. In other words, we considered a version of the weighted disjoint dominating sets problem. In this context, we have proposed a greedy heuristic that benefits from the use of problem-specific knowledge. To assess the performance of our algorithm, 640 problem instances of different sizes (both sparse and dense graphs) were evaluated and the obtained results were compared with those of three recently published local search algorithms. Computational results show the superiority of our greedy algorithm over recent approaches available from the literature. In addition, we stated the considered problem as an integer linear programming model. However, the results of applying CPLEX to solve the model have shown that this approach is only useful for the smallest ones of the considered networks.
Finally, note that our approach can directly be applied to disconnected graphs, that is, our implementation considers the possible existence of disconnected sub-graphs. Moreover, the approach can easily be adapted to directed graphs. The only aspect that has to change for the application to directed graphs is the definition of a dominating set (see, for example, [26]) and the way in which such dominating sets are generated at each main loop of the greedy heuristic.
In the future we plan to develop well-working metaheuristics on the basis of the developed greedy heuristic in order to further improve the obtained results. Options include ant colony optimization or iterated greedy algorithms, which are both based on the step-by-step construction of solutions. Another line of research will focus on hybrid techniques such as construct, merge, solve and adapt (CMSA) [27], which make it possible to take profit from ILP solvers such as CPLEX even in the context of instances of large problem.