# Optimal Energy Aware Clustering in Sensor Networks

^{*}

## Abstract

**:**

## 1. Introduction

## 2. Problem Description

^{c}where c > 2, significant amount of energy savings can be made by partitioning the sensor nodes into clusters and transmitting the information in a hierarchical fashion [4,19]. Moreover clustering can drastically relax the resource requirements at the base stations.

**Figure 1.**Partitioning the nodes into clusters A and B leads to a solution dissipating less communication energy compared to clusters C and D.

_{1},…,S

_{k}(clusters) such that:

- Each point belongs to exactly one of clusters.
- Clusters are balanced, i.e.:$$\frac{1}{k}-\delta \le \frac{\left({S}_{i}\right)}{n}\le \frac{1}{k}+\delta \text{\hspace{1em}\hspace{1em}\hspace{1em}\hspace{1em}}i=1,\dots ,k$$
- The total cost over all clusters is minimized. Specifically, the cost for each cluster S
_{i}is:$${C}_{i}={\displaystyle \sum _{x\subset {S}_{i}}f\left(x,{a}_{i}\right)}$$_{i}are the locations (x and y coordinates) of a sensor and the master node in cluster i. f(x, a_{i}) is the message transmission energy dissipation between a sensor and a master node. Function f can be as simple as the square of the distance between these two points. The balanced clustering feature makes the k-clustering problem in our work distinct from previous works [19,8,18]. In the next section, We solve this problem optimally by transforming it to matching on bipartite graphs.

## 3. Optimal k-Clustering for Energy Optimization

#### 3.1 General Clustering (no balance constraint)

#### 3.2 Balanced k-Clustering

_{i}), we put a directed edge from x to a

_{i}in G. Each edge has a weight equal to the message transmission energy dissipation between the two end vertices. For example, an edge connecting x and a

_{i}has weight f(x, a

_{i}). A source node S and a sink node T are also added to G. There are n directed edges from S to all vertices corresponding to sensors nodes. Similarly, there are k directed edges from vertices corresponding to master nodes to T. All edges incident to S or T have weight 0. Finally, nodes corresponding to sensors have capacity 1, while nodes corresponding to master nodes have capacity n/k. S and T both have infinite capacity. Figure 3 shows an example of G built for a sample network of sensors.

**Figure 3.**Transforming a balanced k-clustering instance to a minimum cost flow instance. Each sensor node has unit capacity, while each master nodes has capacity n/k.

^{3}) time [16,11] where |V| is the total number of vertices in the graph. Constructing G and the corresponding k-clustering solution can be done in O(n.k) time. Hence, the k-clustering problem can be optimally solved in O((n+k)

^{3}) time.

## 4. 2–Clustering to Minimize the Maximum Diameter

#### 4.1 2–Clustering for Minimizing the Maximum Diameter

^{2}log

^{2}n) time. Asano, et. al. [15] proved that there exists an optimal solution that is linearly separable, and improved the algorithm performance to O(n log n) using the maximum spanning tree. Capoyleas [18] extended this work to k-clustering problem and found that the problem is polynomially solvable as long as the objective is a monotone increasing function of the diameters or radii of the clusters. The paper gave O(n

^{6k}) for general k-clustering problem. Focusing on 2-clustering version of the problem, Asano et. al. [15] gave an algorithm which minimizes the larger diameter of two clusters in time O(n log n) and space O(n). The basis of the approach is a theorem which indicates that for any clustering P with the maximum diameter d, there exists a clustering P' with maximum diameter d', such that P' is linearly separable and d' ≤ d . Therefore the optimal clustering can be found by checking only the linearly separable clusters.

_{1},e

_{2},…,e

_{p}the maximum index i such that <e

_{1},e

_{2},…,e

_{i}> allows a line intersecting with each edge while <e

_{1},e

_{2},…,e

_{i},e

_{i+}

_{1}> does not is called a threshold stabbing line. The partitioning induced by this threshold stabbing line is the optimal clustering solution.

**Figure 4.**An example showing that an optimal balanced clustering is not necessarily a linearly separable partition. The point set contains four points, which are the endpoints of two unit-length segments $\overline{ab}$ and $\overline{cd}$, with a being slightly to the left of $\overline{cd}$. The optimal clustering is {a,b,c} and {d}, which is linearly separable; while the optimal balanced clustering is {a,b} and {c,d}, which is not linearly separable.

**Theorem 4.1:**

_{1}and S

_{2}be the two partitions for an optimal minmax diameter mn-clustering with |S

_{1}| = m, |S

_{2}| = n and m − n ≥ 2. Let v be a point such that v ∈ S

_{1}and diam(S

_{2}∪{v}) for any S

_{1}∈S

_{2}. Assume that there exists an optimal bi-partitioning ${S}_{1}^{*}$ and ${S}_{2}^{*}$ such that ${S}_{1}\subset {S}_{1}^{*}$ and ${S}_{2}^{*}\subset {S}_{2}$. Then the S

_{1}- {v} and S

_{2}∪{v} form the optimal (m-1)(n+1)-clustering.

**Proof:**

_{1}and S

_{2}be d

_{1}and d

_{2}, respectively. Assume S

_{1}' = S

_{1}−{v} and S

_{2}' = S

_{2}∪{v}. Let d

_{1}' and d

_{2}' be the diameters of S

_{1}' and S

_{2}' . Obviously we have d

_{1}' ≤ d

_{1}≤ d

_{1}

^{*}and d

_{2}`≥ d

_{2}≥ d

_{2}

^{*}.

_{2}' < d

_{1}

^{*}, the proof is trivial since d

_{1}' = d

_{1}

^{*}. Otherwise d

_{1}' < d

_{1}

^{*}, causing max(diam(S

_{1}' ),diam(S

_{2}' )) < ${d}_{1}^{*}$, which contradicts with the optimal bi-partitioning ${S}_{1}^{*}$ and ${S}_{2}^{*}$.

_{2}' ≥ d

_{1}

^{*}, meaning that the maximum diameter of partition S

_{1}' and S

_{2}' is determined by d

_{2}' . We discuss two cases:

_{2}' > d

_{2}, meaning the diameter of S

_{2}increases after including point v. Therefore v must belong to one of the farthest point pairs in S

_{2}' . Assume that the other point in this point pair is u. We claim that S

_{1}' and S

_{2}' construct the optimal (m-1)(n+1)-clustering. If this is not the case, there exists a partitioning A and B with the larger diameter less than d

_{2}' . Apparently u and v can not be in the same partition (otherwise the diameter of this partition is at least d

_{2}' ). Moreover, there are m-1 points (except v) which have distance to u larger than or equal to d

_{2}' . These points together with v have to be partitioned into the set other than the set containing u. Thus one partition has at least m points. Note that m-n>2, thus it contradicts with (m-1)(n+1) -clustering definition.

_{2}' = d

_{2}, we can prove that v still belongs to one of the farthest point pairs in S

_{2}' , otherwise v would be chosen earlier.

_{1}, find the one with minimum diameter increasing on S

_{2}if it is added into S

_{2}. This can be done in O(n

^{2}) time. There are at most [|S|/2]. Therefore the total running time of Algorithm 1 is O(n

^{3}).

## 5. Preliminary Experiments

**Figure 8.**The effect of changing the master nodes' capacity constraint on the clustering. Each master node can handle 4 sensors in this example.

## 6. Conclusion

## References

- Chandrakasan, A.; Amirtharajah, R.; Cho, S. H.; Goodman, J.; Konduri, G.; Kulik, J.; Rabiner, W.; Wang, A. Design Considerations for Distributed Microsensor Systems. In Proc. of IEEE Custom Integrated Circuits Conference, 1999; pp. 279–286.
- Estrin, D.; Govindan, R.; Heidemann, J.; Kumar, S. Next Century Challenges Scalable Coordination in Sensor Networks. In Proceedings of the ACM IEEE International Conference on Mobile Computing and Networking, 1999; pp. 263–270.
- Chang, J.; Tassiulas, L. Energy Conserving Routing in Wireless Ad hoc Networks. In Proc. of IEEE INFOCOM, 2000.
- Li, Q.; Aslam, J.; Rus, D. Hierarchical Power aware Routing in Sensor Networks. In Proceedings of the DIMACS Workshop on Pervasive Networking, 2001.
- Singh, S. S.; Woo, M.; Raghavendra, C. S. Power Aware Routing in Mobile Ad Hoc Networks. In Proceedings of the ACM IEEE International Conference on Mobile Computing and Networking, 1998.
- Srivastava, A.; Sobaje, J.; Potkonjak, M.; Sarrafzadeh, M. Optimal Node Scheduling for Effective Energy Usage in Sensor Networks. In IEEE Workshop on Integrated Management of Power Aware Communications Computing and Networking, 2002.
- Wang, A.; Chandrakasan, A. Energy Efficient System Partitioning for Distributed Wireless Sensor Networks. In Proc. of IEEE International Conference on Acoustics Speech and Signal Processing, 2001.
- Avis, D. Diameter Partitioning. Discrete and Computational Geometry
**1986**, 1, 265–276. [Google Scholar] [CrossRef] - Shamos, M.; Preparata, F. Computational Geometry; Springer Verlag, 1985. [Google Scholar]
- Cadez, I. V.; Ganffey, S.; Smyth, P. A General Probabilistic Framework for Clustering Individuals and Objects. In Proceedings of the KDD, 2000; pp. 140–149.
- Edmonds, J.; Karp, R. M. Theoretical Improvements in Algorithmic Efficiency for Network Flow Problems. Journal of the Association for Computation Machine
**1972**, 19, 248–261. [Google Scholar] [CrossRef] - Kleinhans, J. M.; Sigl, G.; Johannes, F. M.; Antreich, K. J. GORDIAN: VLSI Placement by Quardratic Programming and Slicing Optimization. IEEE Trans on Computer Aided Design
**1991**. [Google Scholar] [CrossRef] - Min, R.; Bhardwaj, M.; Cho, S. H.; Sinha, A.; Shih, E.; Wang, A.; Chandrakasan, A. Low Power Wireless Sensor Networks. Proc. of VLSI Design
**2001**. [Google Scholar] - Rabaey, J. M.; et al. PicoRadio supports ad hoc ultra low power wireless networking In Computer. 2000. [Google Scholar]
- Asano, T.; Bhattacharya, B.; Keil, M.; Yao, F. Clustering Algorithms Based on Minimum and Maximum Spanning Trees. In Proceedings of the 4th Annual Symposium on Computational Geometry, 1988; pp. 252–257.
- Rivest, R.; Cormen, T.; Leiserson, C. An introduction to algorithms. In MIT Press; 1990. [Google Scholar]
- Feder, T.; Greene, D. H. Optimal Algorithms for Approximate Clustering. In Proc. 20th Annu. ACM Symp. Theory Computing ACM, 1988; pp. 434–444.
- Capoyleas, V. Geometric Clusterings. Journal of Algorithms
**1991**, 12, 341–356. [Google Scholar] [CrossRef] - Heinzelman, W. R.; Chandrakasan, A.; Balakrishnan, H. Energy efficient Communication Protocols for Wireless Microsensor Networks. In Proc. Hawaaian Int’l Conf. on Systems Science, 2000.

- Sample Availability: Available from the authors.

© 2002 by MDPI (http://www.mdpi.net). Reproduction is permitted for noncommercial purposes.

## Share and Cite

**MDPI and ACS Style**

Ghiasi, S.; Srivastava, A.; Yang, X.; Sarrafzadeh, M.
Optimal Energy Aware Clustering in Sensor Networks. *Sensors* **2002**, *2*, 258-269.
https://doi.org/10.3390/s20700258

**AMA Style**

Ghiasi S, Srivastava A, Yang X, Sarrafzadeh M.
Optimal Energy Aware Clustering in Sensor Networks. *Sensors*. 2002; 2(7):258-269.
https://doi.org/10.3390/s20700258

**Chicago/Turabian Style**

Ghiasi, Soheil, Ankur Srivastava, Xiaojian Yang, and Majid Sarrafzadeh.
2002. "Optimal Energy Aware Clustering in Sensor Networks" *Sensors* 2, no. 7: 258-269.
https://doi.org/10.3390/s20700258