X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/ThesisAli.git/blobdiff_plain/efa13c49ab1c7455dff14995c722caded700073f..refs/heads/master:/CHAPITRE_03.tex?ds=sidebyside diff --git a/CHAPITRE_03.tex b/CHAPITRE_03.tex index 68b15be..ab74629 100644 --- a/CHAPITRE_03.tex +++ b/CHAPITRE_03.tex @@ -1,798 +1,344 @@ + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %% -%% CHAPTER 03 %% +%% CHAPTER 03 %% %% %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\chapter{Distributed Lifetime Coverage Optimization Protocol in Wireless Sensor Networks} -\label{ch3} - - - -\section{Summary} -\label{ch3:sec:01} -In this chapter, a Distributed Lifetime Coverage Optimization protocol (DiLCO) to maintain -the coverage and to improve the lifetime in wireless sensor networks is -proposed. The area of interest is first divided into subregions using a -divide-and-conquer method and then the DiLCO protocol is distributed on the -sensor nodes in each subregion. The DiLCO combines two efficient techniques: -leader election for each subregion, followed by an optimization-based planning -of activity scheduling decisions for each subregion. The proposed DiLCO works -into rounds during which a small number of nodes, remaining active for sensing, -is selected to ensure coverage so as to maximize the lifetime of wireless sensor -network. Each round consists of four phases: (i)~Information Exchange, -(ii)~Leader Election, (iii)~Decision, and (iv)~Sensing. The decision process is -carried out by a leader node, which solves an integer program. Compared with -some existing protocols, simulation results show that the proposed protocol can -prolong the network lifetime and improve the coverage performance effectively. - - -\section{DESCRIPTION OF THE DILCO PROTOCOL} -\label{ch3:sec:02} - -\noindent In this section, we introduce the DiLCO protocol which is distributed on each subregion in the area of interest. It is based on two efficient -techniques: network leader election and sensor activity scheduling for coverage preservation and energy conservation, applied periodically to efficiently -maximize the lifetime in the network. - -\subsection{Assumptions and Network Model} -\label{ch3:sec:02:01} -\noindent We consider a sensor network composed of static nodes distributed independently and uniformly at random. A high density deployment ensures a high -coverage ratio of the interested area at the start. The nodes are supposed to have homogeneous characteristics from a communication and a processing point of -view, whereas they have heterogeneous energy provisions. Each node has access to its location thanks, either to a hardware component (like a GPS unit), or a -location discovery algorithm. Furthermore, we assume that sensor nodes are time synchronized in order to properly coordinate their operations to achieve complex sensing tasks~\cite{ref157}. The two sensor nodes have been supposed a neighbors if the euclidean distance between them is at most equal to 2$R_s$. +\chapter{Evaluation Tools and Optimization Solvers} +\label{ch03} + +%%-------------------------------------------------------------------------------------------------------%% +\section{Introduction} +\label{ch3:1} +%Performance evaluation and optimization solvers are important tools. +In the last few years, several intensive researches have been done about the WSNs, and for a wide range of real-world applications. Therefore, the performance evaluation of algorithms and protocols becomes challenging at various stages of design, development, and implementation. In fact, to perform an efficient deployment, it is desirable to analyze the performance of the newly designed algorithms and protocols in WSNs. Since performance evaluation tools are becoming precious means for evaluating the efficiency of algorithms and protocols in WSNs, they have received a great interest by many researchers around the world. +On the other side, the main challenges in the design of WSNs handle new hard and complex theoretical optimization problems. These optimization problems are related to several topics in WSNs such as coverage, topology control, scheduling, routing, mobility, etc. +%So, the optimization is very important in WSNs because the limited resources of the sensor nodes. +For this reason, several problems are modeled by an optimization problem for instance to optimize the network lifetime while satisfying the application requirements. +%Therefore, in order to get the optimal solutions for these mathematical optimization problems, the optimization solver is the best candidate tool to solve them. The optimization solver takes mathematical optimization problem descriptions in a certain file format and calculates their optimal solution. +Optimization solvers dedicated to specific resolution methods (meta-heuristics, linear programming, etc) are required. +%Many important real-world problems have formulated as integer programming problems. +%In this dissertation, we use linear programming because we used integer programs to optimize the coverage and the lifetime in WSNs. +In this dissertation, we optimize the coverage and the lifetime in WSNs and the problem is formulated through linear programming. These kind of models allow to obtain optimal solutions satisfying an objective (for instance, maximize coverage) under constraints (for instance, available remaining energy). + +The remainder of this chapter is organized as follows. The next section is devoted to the evaluation tools for evaluating and validating the performance of proposed algorithms and protocols. Section \ref{ch3:3} gives the most popular free and commercial linear optimization solvers to solve linear programming problems. Finally, we give concluding remarks in section \ref{ch3:4}. + +\section{Evaluation Tools} +\label{ch3:2} +On the one hand, several proposed works in WSNs require evaluating the power depletion efficiently and accurately for network lifetime prediction. On the other hand, the wrong energy evaluation leads to waste of energy because the sensor nodes might be rendered useless long time before draining their energy. Furthermore, the sensor nodes might die before of the expected lifetime. However, evaluation experiments on actually deployed WSN suffer some constraints because of the large number of sensor nodes and the deployment in hostile and inaccessible environments. Moreover, the analytical (or theoretical) models might be unrealistic for real world systems. + +Two main evaluation tools are available to evaluate and validate the performance of proposed works of researchers in large-scale wireless sensor networks: testbeds and simulations~\cite{ref180}. The energy consumption results obtained by simulation and testbed evaluation tools give an alternative on time, precision, and cost. + +%Therefore, the energy consumption results obtained by simulation and testbed evaluations give an alternative on time, precision and cost. Researchers can also evaluate and test their proposed works with simulation tools as well as testbed devices. +%Two main evaluation tools are available for evaluating and validating large-scale wireless sensor networks performance: testbeds and simulations~\cite{ref180}. -\indent We consider a boolean disk coverage model which is the most widely used sensor coverage model in the literature. Thus, since a sensor has a constant -sensing range $R_s$, every space points within a disk centered at a sensor with the radius of the sensing range is said to be covered by this sensor. We also -assume that the communication range $R_c$ is at least twice the sensing range $R_s$ (i.e., $R_c \geq 2R_s$). In fact, Zhang and Hou~\cite{ref126} proved that if the transmission range fulfills the previous hypothesis, a complete coverage of a convex area implies connectivity among the working nodes in the active mode. We assume that each sensor node can directly transmit its measurements to a mobile sink node. For example, a sink can be an unmanned aerial vehicle (UAV) is flying regularly over the sensor field to collect measurements from sensor nodes. A mobile sink node collects the measurements and transmits them to the base station. -During the execution of the DiLCO protocol, two kinds of packet will be used: +\subsection{Testbed Tools} %~\cite{ref180} + +%The testbed-based evaluations are necessary before deploying the WSN because it provides more realistic results for the complex physical phenomena constraints of the real world. In this section, only some testbeds are explained. +Testbeds enable researchers and programmers to validate the performance of their algorithms and protocols on a physical network. More extensive details about testbeds are available in~\cite{ref178}. \begin{enumerate} [(i)] -\item \textbf{INFO packet:} sent by each sensor node to all the nodes inside a same subregion for information exchange. -\item \textbf{ActiveSleep packet:} sent by the leader to all the nodes in its subregion to inform them to stay Active or to go Sleep during the sensing phase. -\end{enumerate} -There are five possible status for each sensor node in the network: -%and each sensor node will have five possible status in the network: -\begin{enumerate}[(i)] -\item \textbf{LISTENING:} sensor is waiting for a decision (to be active or not). -\item \textbf{COMPUTATION:} sensor applies the optimization process as leader. -\item \textbf{ACTIVE:} sensor is active. -\item \textbf{SLEEP:} sensor is turned off. -\item \textbf{COMMUNICATION:} sensor is transmitting or receiving packet. +\item \textbf{MoteLab:} + +MoteLab~\cite{ref181,ref182} is a WSN testbed developed at the electrical and computer engineering department of Harvard University. It is a public testbed, researchers can execute their WSN systems using a web-based interface. Researchers develop and test their applications and protocols on sensor nodes and visualize sensor nodes output via web-based interface. They are allowed to upload their executable files to run on real mote. Each mote is wall-powered and is connected to a central server that offers scheduling, reprogramming, and data logging. It is composed of 190~TMote Sky wireless sensor nodes. The wireless sensor node has the following specifications: TI MSP430 processor, 10 KB RAM, 1Mb flash, and Chipcon CC2420 radio. Each node is connected to the Ethernet. The users should be familiar with NesC programming language because the MoteLab only supports the TinyOS operating system. + +\item \textbf{WISEBED:} + +The WISEBED~\cite{ref183} is a large-scale WSN testbed with a hierarchical architecture that consists of four major parts: wireless sensor nodes, gateways, portal server, and overlay network. The lowest level of the hierarchy corresponds to the WSN in which a set of these sensor nodes is connected to the gateway to provide access to the other remaining sensor nodes. The gateways are connected to a portal server, which not only supervises the WSN, but also allows user interactions with the testbed. Each WISBED site includes separate portal server. The major goal of this testbed is to provide a multi-level infrastructure of interconnected testbeds of large scale wireless sensor networks for research purposes. It provides an interdisciplinary approach which integrates the hardware, software, algorithms, and data. WISEBED provides heterogeneous large-scale structure because it brings several heterogeneous small-scale devices together to form a large-scale network structure. +%It provides the research with different quality networks due to the heterogeneous structure of the network. + + + + +%Several objectives of WISEBED testbed should be provided such as heterogeneity, virtualization, and facilitate the system evaluation by end users via a variety of interfaces and software environment. + + +\item \textbf{IoT-LAB:} + +IoT-LAB testbed~\cite{ref184,ref185} supplies a very large scale infrastructure service appropriate for evaluating wireless sensor devices and heterogeneous communicating objects. IoT-LAB includes more than 2700 wireless sensor nodes deployed in six different regions in France. Different kinds of wireless sensor nodes are available, with different processor architectures (MSP430, STM32, and Cortex-A8) and different wireless chips (802.15.4 PHY @ 800 MHz or 2.4 GHz). Sensor nodes are either mobile or fixed and can be used in different topologies throughout all the regions. +IoT-LAB provides web-based reservation and tools for protocols and applications development, along with direct command-line access to the platform. Wireless sensor nodes firmware can be constructed from source and deployed on reserved nodes, application activity can be controlled and observed, power consumption or radio interference can be measured using the offered tools. IoT-LAB is a part of the FIT (Future Internet of the Things) experimental platform, a set of supplementary elements that enable experimentation with innovative services for academic and industrial users. + \end{enumerate} -\subsection{Primary Point Coverage Model} -\label{ch3:sec:02:02} -\indent Instead of working with the coverage area, we consider for each -sensor a set of points called primary points. We also assume that the -sensing disk defined by a sensor is covered if all the primary points of -this sensor are covered. By knowing the position (point center: ($p_x,p_y$)) of a wireless -sensor node and its $R_s$, we calculate the primary points directly -based on the proposed model. We use these primary points (that can be -increased or decreased if necessary) as references to ensure that the -monitored region of interest is covered by the selected set of -sensors, instead of using all the points in the area. - -\indent We can calculate the positions of the selected primary -points in the circle disk of the sensing range of a wireless sensor -node (see figure~\ref{fig1}) as follows:\\ -$(p_x,p_y)$ = point center of wireless sensor node\\ -$X_1=(p_x,p_y)$ \\ -$X_2=( p_x + R_s * (1), p_y + R_s * (0) )$\\ -$X_3=( p_x + R_s * (-1), p_y + R_s * (0)) $\\ -$X_4=( p_x + R_s * (0), p_y + R_s * (1) )$\\ -$X_5=( p_x + R_s * (0), p_y + R_s * (-1 )) $\\ -$X_6= ( p_x + R_s * (\frac{-\sqrt{2}}{2}), p_y + R_s * (0)) $\\ -$X_7=( p_x + R_s * (\frac{\sqrt{2}}{2}), p_y + R_s * (0))$\\ -$X_8=( p_x + R_s * (\frac{-\sqrt{2}}{2}), p_y + R_s * (\frac{-\sqrt{2}}{2})) $\\ -$X_9=( p_x + R_s * (\frac{\sqrt{2}}{2}), p_y + R_s * (\frac{-\sqrt{2}}{2})) $\\ -$X_{10}=( p_x + R_s * (\frac{-\sqrt{2}}{2}), p_y + R_s * (\frac{\sqrt{2}}{2})) $\\ -$X_{11}=( p_x + R_s * (\frac{\sqrt{2}}{2}), p_y + R_s * (\frac{\sqrt{2}}{2})) $\\ -$X_{12}=( p_x + R_s * (0), p_y + R_s * (\frac{\sqrt{2}}{2})) $\\ -$X_{13}=( p_x + R_s * (0), p_y + R_s * (\frac{-\sqrt{2}}{2})) $\\ -$X_{14}=( p_x + R_s * (\frac{\sqrt{3}}{2}), p_y + R_s * (\frac{1}{2})) $\\ -$X_{15}=( p_x + R_s * (\frac{-\sqrt{3}}{2}), p_y + R_s * (\frac{1}{2})) $\\ -$X_{16}=( p_x + R_s * (\frac{\sqrt{3}}{2}), p_y + R_s * (\frac{- 1}{2})) $\\ -$X_{17}=( p_x + R_s * (\frac{-\sqrt{3}}{2}), p_y + R_s * (\frac{- 1}{2})) $\\ -$X_{18}=( p_x + R_s * (\frac{\sqrt{3}}{2}), p_y + R_s * (0) $\\ -$X_{19}=( p_x + R_s * (\frac{-\sqrt{3}}{2}), p_y + R_s * (0) $\\ -$X_{20}=( p_x + R_s * (0), p_y + R_s * (\frac{1}{2})) $\\ -$X_{21}=( p_x + R_s * (0), p_y + R_s * (-\frac{1}{2})) $\\ -$X_{22}=( p_x + R_s * (\frac{1}{2}), p_y + R_s * (\frac{\sqrt{3}}{2})) $\\ -$X_{23}=( p_x + R_s * (\frac{- 1}{2}), p_y + R_s * (\frac{\sqrt{3}}{2})) $\\ -$X_{24}=( p_x + R_s * (\frac{- 1}{2}), p_y + R_s * (\frac{-\sqrt{3}}{2})) $\\ -$X_{25}=( p_x + R_s * (\frac{1}{2}), p_y + R_s * (\frac{-\sqrt{3}}{2})) $. - -\begin{figure}[h!] -\centering - \begin{multicols}{3} -\centering -\includegraphics[scale=0.20]{Figures/ch3/fig21.pdf}\\~ ~ ~ ~ ~(a) -\includegraphics[scale=0.20]{Figures/ch3/fig22.pdf}\\~ ~ ~ ~ ~(b) -\includegraphics[scale=0.20]{Figures/ch3/principles13.pdf}\\~ ~ ~ ~ ~(c) -\hfill -\includegraphics[scale=0.20]{Figures/ch3/fig24.pdf}\\~ ~ ~(d) -\includegraphics[scale=0.20]{Figures/ch3/fig25.pdf}\\~ ~ ~(e) -\includegraphics[scale=0.20]{Figures/ch3/fig26.pdf}\\~ ~ ~(f) -\end{multicols} -\caption{Wireless Sensor Node represented by (a)5, (b)9, (c)13, (d)17, (e)21 and (f)25 primary points respectively} -\label{fig1} -\end{figure} - - - -\subsection{Main Idea} -\label{ch3:sec:02:03} -\noindent We start by applying a divide-and-conquer algorithm to partition the -area of interest into smaller areas called subregions and then our protocol is -executed simultaneously in each subregion. - -\begin{figure}[ht!] -\centering -\includegraphics[scale=0.60]{Figures/ch3/FirstModel.pdf} % 70mm -\caption{DiLCO protocol} -\label{FirstModel} -\end{figure} - -As shown in Figure~\ref{FirstModel}, the proposed DiLCO protocol is a periodic -protocol where each period is decomposed into 4~phases: Information Exchange, -Leader Election, Decision, and Sensing. For each period there will be exactly -one cover set in charge of the sensing task. A periodic scheduling is -interesting because it enhances the robustness of the network against node -failures. First, a node that has not enough energy to complete a period, or -which fails before the decision is taken, will be excluded from the scheduling -process. Second, if a node fails later, whereas it was supposed to sense the -region of interest, it will only affect the quality of the coverage until the -definition of a new cover set in the next period. Constraints, like energy -consumption, can be easily taken into consideration since the sensors can update -and exchange their information during the first phase. Let us notice that the -phases before the sensing one (Information Exchange, Leader Election, and -Decision) are energy consuming for all the nodes, even nodes that will not be -retained by the leader to keep watch over the corresponding area. - -Below, we describe each phase in more details. - -\subsubsection{Information Exchange Phase} -\label{ch3:sec:02:03:01} -Each sensor node $j$ sends its position, remaining energy $RE_j$, and the number -of neighbors $NBR_j$ to all wireless sensor nodes in its subregion by using an -INFO packet (containing information on position coordinates, current remaining -energy, sensor node ID, number of its one-hop live neighbors) and then waits for -packets sent by other nodes. After that, each node will have information about -all the sensor nodes in the subregion. In our model, the remaining energy -corresponds to the time that a sensor can live in the active mode. - -\subsubsection{Leader Election Phase} -\label{ch3:sec:02:03:02} -This step includes choosing the Wireless Sensor Node Leader (WSNL), which will be responsible for executing the coverage algorithm. Each subregion in the area of interest will select its own WSNL independently for each round. All the sensor nodes cooperate to select WSNL. The nodes in the same subregion will select the leader based on the received information from all other nodes in the same subregion. The selection criteria are, in order of importance: larger number of neighbors, larger remaining energy, and then in case of equality, larger index. Observations on previous simulations suggest to use the number of one-hop neighbors as the primary criterion to reduce energy consumption due to the communications. - - -\subsubsection{Decision phase} -\label{ch3:sec:02:03:03} -The WSNL will solve an integer program (see section~\ref{ch3:sec:03}) to select which sensors will be activated in the following sensing phase to cover the subregion. WSNL will send Active-Sleep packet to each sensor in the subregion based on the algorithm's results. - - -\subsubsection{Sensing phase} -\label{ch3:sec:02:03:04} -Active sensors in the round will execute their sensing task to -preserve maximal coverage in the region of interest. We will assume -that the cost of keeping a node awake (or asleep) for sensing task is -the same for all wireless sensor nodes in the network. Each sensor -will receive an Active-Sleep packet from WSNL informing it to stay -awake or to go to sleep for a time equal to the period of sensing until -starting a new round. - -An outline of the protocol implementation is given by Algorithm~\ref{alg:DiLCO} -which describes the execution of a period by a node (denoted by $s_j$ for a -sensor node indexed by $j$). At the beginning a node checks whether it has -enough energy to stay active during the next sensing phase. If yes, it exchanges -information with all the other nodes belonging to the same subregion: it -collects from each node its position coordinates, remaining energy ($RE_j$), ID, -and the number of one-hop neighbors still alive. Once the first phase is -completed, the nodes of a subregion choose a leader to take the decision based -on the following criteria with decreasing importance: larger number of -neighbors, larger remaining energy, and then in case of equality, larger index. -After that, if the sensor node is leader, it will execute the integer program -algorithm (see Section~\ref{ch3:sec:03}) which provides a set of sensors planned to be -active in the next sensing phase. As leader, it will send an Active-Sleep packet -to each sensor in the same subregion to indicate it if it has to be active or -not. Alternately, if the sensor is not the leader, it will wait for the -Active-Sleep packet to know its state for the coming sensing phase. - - -\begin{algorithm}[h!] - - \BlankLine - %\emph{Initialize the sensor node and determine it's position and subregion} \; - - \If{ $RE_j \geq E_{th}$ }{ - \emph{$s_j.status$ = COMMUNICATION}\; - \emph{Send $INFO()$ packet to other nodes in the subregion}\; - \emph{Wait $INFO()$ packet from other nodes in the subregion}\; - %\emph{UPDATE $RE_j$ for every sent or received INFO Packet}\; - %\emph{ Collect information and construct the list L for all nodes in the subregion}\; - - %\If{ the received INFO Packet = No. of nodes in it's subregion -1 }{ - \emph{LeaderID = Leader election}\; - \If{$ s_j.ID = LeaderID $}{ - \emph{$s_j.status$ = COMPUTATION}\; - \emph{$\left\{\left(X_{1},\dots,X_{k},\dots,X_{J}\right)\right\}$ = - Execute Integer Program Algorithm($J$)}\; - \emph{$s_j.status$ = COMMUNICATION}\; - \emph{Send $ActiveSleep()$ to each node $k$ in subregion} \; - \emph{Update $RE_j $}\; - } - \Else{ - \emph{$s_j.status$ = LISTENING}\; - \emph{Wait $ActiveSleep()$ packet from the Leader}\; - - \emph{Update $RE_j $}\; - } - % } - } - \Else { Exclude $s_j$ from entering in the current sensing phase} - - % \emph{return X} \; -\caption{DiLCO($s_j$)} -\label{alg:DiLCO} - -\end{algorithm} - - - -\section{COVERAGE PROBLEM FORMULATION} -\label{ch3:sec:03} -\indent Our model is based on the model proposed by \cite{ref156} where the -objective is to find a maximum number of disjoint cover sets. To accomplish -this goal, the authors proposed an integer program which forces undercoverage -and overcoverage of targets to become minimal at the same time. They use binary -variables $x_{jl}$ to indicate if sensor $j$ belongs to cover set $l$. In our -model, we consider that the binary variable $X_{j}$ determines the activation of -sensor $j$ in the sensing phase. We also consider primary points as targets. -The set of primary points is denoted by $P$ and the set of sensors by $J$. - -\noindent Let $\alpha_{jp}$ denote the indicator function of whether the primary -point $p$ is covered, that is: -\begin{equation} -\alpha_{jp} = \left \{ -\begin{array}{l l} - 1 & \mbox{if the primary point $p$ is covered} \\ - & \mbox{by sensor node $j$}, \\ - 0 & \mbox{otherwise.}\\ -\end{array} \right. -%\label{eq12} -\end{equation} -The number of active sensors that cover the primary point $p$ can then be -computed by $\sum_{j \in J} \alpha_{jp} * X_{j}$ where: -\begin{equation} -X_{j} = \left \{ -\begin{array}{l l} - 1& \mbox{if sensor $j$ is active,} \\ - 0 & \mbox{otherwise.}\\ -\end{array} \right. -%\label{eq11} -\end{equation} -We define the Overcoverage variable $\Theta_{p}$ as: -\begin{equation} - \Theta_{p} = \left \{ -\begin{array}{l l} - 0 & \mbox{if the primary point}\\ - & \mbox{$p$ is not covered,}\\ - \left( \sum_{j \in J} \alpha_{jp} * X_{j} \right)- 1 & \mbox{otherwise.}\\ -\end{array} \right. -\label{eq13} -\end{equation} -\noindent More precisely, $\Theta_{p}$ represents the number of active sensor -nodes minus one that cover the primary point~$p$. The Undercoverage variable -$U_{p}$ of the primary point $p$ is defined by: -\begin{equation} -U_{p} = \left \{ -\begin{array}{l l} - 1 &\mbox{if the primary point $p$ is not covered,} \\ - 0 & \mbox{otherwise.}\\ -\end{array} \right. -\label{eq14} -\end{equation} - -\noindent Our coverage optimization problem can then be formulated as follows: -\begin{equation} \label{eq:ip2r} -\left \{ -\begin{array}{ll} -\min \sum_{p \in P} (w_{\theta} \Theta_{p} + w_{U} U_{p})&\\ -\textrm{subject to :}&\\ -\sum_{j \in J} \alpha_{jp} X_{j} - \Theta_{p}+ U_{p} =1, &\forall p \in P\\ -%\label{c1} -%\sum_{t \in T} X_{j,t} \leq \frac{RE_j}{e_t} &\forall j \in J \\ -%\label{c2} -\Theta_{p}\in \mathbb{N}, &\forall p \in P\\ -U_{p} \in \{0,1\}, &\forall p \in P \\ -X_{j} \in \{0,1\}, &\forall j \in J -\end{array} -\right. -\end{equation} -\begin{itemize} -\item $X_{j}$ : indicates whether or not the sensor $j$ is actively sensing (1 - if yes and 0 if not); -\item $\Theta_{p}$ : {\it overcoverage}, the number of sensors minus one that - are covering the primary point $p$; -\item $U_{p}$ : {\it undercoverage}, indicates whether or not the primary point - $p$ is being covered (1 if not covered and 0 if covered). -\end{itemize} +A testbed is a large hardware evaluation tool. However, to construct a suitable tool with capable architecture, the information about the desired requirements is required. For instance, table \ref{Tablex:ch3} presents each research topic and the required abilities and provisions for a specialized testbed in the corresponding field of study~\cite{ref186}. Many existing testbeds are developed without obvious definition of requirements. Therefore, the research efforts may be halted due to the lack of the precisely defined requirements~\cite{ref186}. The tests and experiments on a large number of sensor nodes lead to a scalability challenge, and a large amount of data for logging, debugging, and measurement output. Another drawback is that there are no enough tools to deal (semi-)automatically with the amount of data and supporting the researchers to evaluate their systems. -The first group of constraints indicates that some primary point $p$ should be -covered by at least one sensor and, if it is not always the case, overcoverage -and undercoverage variables help balancing the restriction equations by taking -positive values. Two objectives can be noticed in our model. First, we limit the -overcoverage of primary points to activate as few sensors as possible. Second, -to avoid a lack of area monitoring in a subregion we minimize the -undercoverage. Both weights $w_\theta$ and $w_U$ must be carefully chosen in -order to guarantee that the maximum number of points are covered during each -period. -\section{Simulation Results and Analysis} -\label{ch3:sec:04} - -\subsection{Simulation Framework} -\label{ch3:sec:04:01} - -To assess the performance of DiLCO protocol, we have used the discrete event simulator OMNeT++ \cite{ref158} to run different series of simulations. Table~\ref{tablech3} gives the chosen parameters setting. - -\begin{table}[ht] -\caption{Relevant parameters for network initializing.} -% title of Table -\centering -% used for centering table -\begin{tabular}{c|c} -% centered columns (4 columns) - \hline -%inserts double horizontal lines -Parameter & Value \\ [0.5ex] - +\begin{table}[h] +\caption{WSN research topics vs testbed requirements} +\label{Tablex:ch3} +\resizebox{\textwidth}{!}{% +\begin{tabular}{|c|c|} \hline -% inserts single horizontal line -Sensing Field & $(50 \times 25)~m^2 $ \\ -% inserting body of the table -%\hline -Nodes Number & 50, 100, 150, 200 and 250~nodes \\ -%\hline -Initial Energy & 500-700~joules \\ -%\hline -Sensing Period & 60 Minutes \\ -$E_{th}$ & 36 Joules\\ -$R_s$ & 5~m \\ -%\hline -$w_{\Theta}$ & 1 \\ -% [1ex] adds vertical space -%\hline -$w_{U}$ & $|P|^2$ -%inserts single line +\textbf{WSN research topic} & \textbf{Testbed requirement} \\ \hline +Energy efficiency & Energy consumption estimation and measurement \\ \hline +Mobile sensor nodes & Mobile nodes and localization infrastructure \\ \hline +Realistic WSN context & Deployment in target environments \\ \hline +Scalability and performance in WSNs & simulations and hybrid testbeds, large network size \\ \hline +Sensor node design & Development of sensor nodes, monitoring, measurement, debugging \\ \hline +Interoperability and platform support & Support for different platforms, heterogeneity \\ \hline +Application and protocol design & Tool support for development, debugging and deployment \\ \hline \end{tabular} -\label{tablech3} -% is used to refer this table in the text +} \end{table} -Simulations with five different node densities going from 50 to 250~nodes were -performed considering each time 25~randomly generated networks, to obtain -experimental results which are relevant. The nodes are deployed on a field of -interest of $(50 \times 25)~m^2 $ in such a way that they cover the field with a -high coverage ratio. +Several sensor nodes testbeds are available to support the research efforts in WSNs, but only a few of them provide common evaluation goals for a large number of users~\cite{ref187,ref181}. However, all the WSN testbeds have usually many common properties, such as a typical number of sensors of the order of hundreds and sometimes only tens of nodes; the deployment of the sensor nodes in a static grid topology; metrics and debug information are obtained via wired connections. Therefore, the WSN testbeds impose strong limitations on the WSNs in terms of size and topology. Moreover, the cost of performing an experiment on a testbed is much higher than through a simulation because setting up the experiments, instrumenting the nodes, gathering the metrics on the performance, and so on is so expensive. For evaluating the systems and protocols on large sensor networks, the simulation tools are the better choice due to the costs for hardware and maintenance~\cite{ref186}. Hence, the simulation tools stay the most practical tools to obtain a feedback on the performance of a new solution~\cite{ref180}. -\subsection{Modeling Language and Optimization Solver} -\label{ch3:sec:04:02} -The modeling language for Mathematical Programming (AMPL)~\cite{AMPL} is employed to generate the integer program instance in a standard format, which is then read and solved by the optimization solver GLPK (GNU linear Programming Kit available in the public domain) \cite{glpk} through a Branch-and-Bound method. -\subsection{Energy Consumption Model} -\label{ch3:sec:04:03} +\subsection{Simulation Tools} +% take the simulators from paper "Limitations of simulation tools for large-scale wireless sensor networks" \cite{ref179} -\indent In this dissertation, we used an energy consumption model proposed by~\cite{ref111} and based on \cite{ref112} with slight modifications. The energy consumption for sending/receiving the packets is added, whereas the part related to the sensing range is removed because we consider a fixed sensing range. +Simulation tools are widely used due to the complexity and difficulty to apply real testbed for WSNs experiments. They permit users to evaluate and validate their systems and protocols on WSNs before the deployment. +Simulation tools reduce the correction actions before operating the WSN. In addition, most the works on the WSNs use the simulation tools for performance evaluation. So, these tools are considered as predominant techniques to study and analyze the performance of WSNs. -\indent For our energy consumption model, we refer to the sensor node Medusa~II which uses an Atmels AVR ATmega103L microcontroller~\cite{ref112}. The typical architecture of a sensor is composed of four subsystems: the MCU subsystem which is capable of computation, communication subsystem (radio) which is responsible for transmitting/receiving messages, the sensing subsystem that collects data, and the power supply which powers the complete sensor node \cite{ref112}. Each of the first three subsystems can be turned on or off depending on the current status of the sensor. Energy consumption (expressed in milliWatt per second) for the different status of the sensor is summarized in Table~\ref{table1}. +%This can reduce the correction actions before operating the WSN. +%The large-scale evaluation of systems, applications, and protocols are practicable in a flexible environment~\cite{ref180}. Most of the papers on the wireless sensor networks use the simulation tools to evaluate the performance of their algorithms and protocols. +%This is a confirmation to consider these tools as predominant techniques used to study and analyze the performance of WSNs. +Several simulation tools are available for WSNs, which vary in their characteristics and capabilities. So, this section introduces only some of these simulators, and more details about simulators are available in~\cite{ref188,ref189,ref190}. -\begin{table}[ht] -\caption{The Energy Consumption Model} -% title of Table -\centering -% used for centering table -\begin{tabular}{|c|c|c|c|c|} -% centered columns (4 columns) - \hline -%inserts double horizontal lines -Sensor status & MCU & Radio & Sensing & Power (mW) \\ [0.5ex] -\hline -% inserts single horizontal line -LISTENING & on & on & on & 20.05 \\ -% inserting body of the table -\hline -ACTIVE & on & off & on & 9.72 \\ -\hline -SLEEP & off & off & off & 0.02 \\ -\hline -COMPUTATION & on & on & on & 26.83 \\ -%\hline -%\multicolumn{4}{|c|}{Energy needed to send/receive a 1-bit} & 0.2575\\ - \hline -\end{tabular} +\begin{enumerate} [(i)] -\label{table1} -% is used to refer this table in the text -\end{table} +\item \textbf{NS2:} -\indent For the sake of simplicity we ignore the energy needed to turn on the radio, to start up the sensor node, to move from one status to another, etc. Thus, when a sensor becomes active (i.e., it has already chosen its status), it can turn its radio off to save battery. The value of energy spent to send a 1-bit-content message is obtained by using the equation in ~\cite{ref112} to calculate the energy cost for transmitting messages and we propose the same value for receiving the packets. The energy needed to send or receive a 1-bit packet is equal to $0.2575~mW$. +The Network Simulator-2 (ns-2)~\cite{ref191,ref192} is an open source, discrete event, network simulator. The major goal of ns-2 is to provide a simulation environment for wired as well as wireless networks to simulate different protocols with different network topologies. ns-2 is built in C++ and the simulation interface is provided via OTcl, an object-oriented dialect of Tcl. The network topology is determined by the users by writing OTcl scripts, and then the main program of ns-2 simulates this topology with fixed parameters. ns-2 provides a graphical view of the network by using network animator (Nam). Nam interface includes control features that allow researchers to forward, pause, stop, and control the simulation. ns-2 is the most common and widely used network simulator for scientific research work. +The next version, ns-3, is considered as a new simulator and a final replacement of ns-2, not a simple extension~\cite{ref194}. The ns-3 project~\cite{ref193} was started in mid-2006 and is still under intensive development. Like ns-2, ns-3 is an open source, discrete-event network simulator targeted essentially for research and educational use~\cite{ref195}. ns-3 supports both simulation and emulation using sockets. It also provides a tracing facility to help users in debugging. -%We have used an energy consumption model, which is presented in chapter 1, section \ref{ch1:sec9:subsec2}. -The initial energy of each node is randomly set in the interval $[500;700]$. A sensor node will not participate in the next round if its remaining energy is less than $E_{th}=36~\mbox{Joules}$, the minimum energy needed for the node to stay alive during one round. This value has been computed by multiplying the energy consumed in active state (9.72 mW) by the time in second for one round (3600 seconds), and adding the energy for the pre-sensing phases. According to the interval of initial energy, a sensor may be alive during at most 20 rounds. +\item \textbf{OMNeT++:} -\subsection{Performance Metrics} -\label{ch3:sec:04:04} -In the simulations, we introduce the following performance metrics to evaluate -the efficiency of our approach: +OMNeT++ (Objective Modular Network Testbed) is an open-source, free, discrete-event, component-based C++ simulation library, modular simulation framework for building network simulators~\cite{ref158,ref203}. Even if OMNeT++ is not a network simulator itself, it is very popular as a network simulation platform for both scientific and industrial communities. The major goal behind the development of OMNeT++ is to provide a strong simulation tool, which can be used by the academic and commercial researchers for simulating different types of networks in a distributed and parallel way~\cite{ref197}. OMNeT++ has an extensive Graphical User Interface (GUI) and intelligence support. It runs on Windows, Linux, Mac OS~X, and other Unix-like systems, and provides a component architecture for models. Components (modules) are first programmed in C++, then assembled into larger components and models using a high-level language (NED)~\cite{ref198}. Several simulation frameworks can be used with OMNeT++ such as INET, INETMANET, MiXiM, and Castalia, where each of them provides a set of simulation facilities (modelity and soon) and can be used for specific applications.\\ \\ -\begin{enumerate}[i)] -%\begin{itemize} -\item {{\bf Network Lifetime}:} we define the network lifetime as the time until - the coverage ratio drops below a predefined threshold. We denote by - $Lifetime_{95}$ (respectively $Lifetime_{50}$) the amount of time during which - the network can satisfy an area coverage greater than $95\%$ (respectively - $50\%$). We assume that the sensor network can fulfill its task until all its - nodes have been drained of their energy or it becomes disconnected. Network - connectivity is crucial because an active sensor node without connectivity - towards a base station cannot transmit any information regarding an observed - event in the area that it monitors. - -\item {{\bf Coverage Ratio (CR)}:} it measures how well the WSN is able to - observe the area of interest. In our case, we discretized the sensor field - as a regular grid, which yields the following equation to compute the - coverage ratio: -\begin{equation*} -\scriptsize -\mbox{CR}(\%) = \frac{\mbox{$n$}}{\mbox{$N$}} \times 100. -\end{equation*} -where $n$ is the number of covered grid points by active sensors of every -subregions during the current sensing phase and $N$ is the total number of grid -points in the sensing field. In our simulations, we have a layout of $N = 51 -\times 26 = 1326$ grid points. - -\item {{\bf Energy Consumption}:} energy consumption (EC) can be seen as the - total amount of energy consumed by the sensors during $Lifetime_{95}$ - or $Lifetime_{50}$, divided by the number of periods. Formally, the computation - of EC can be expressed as follows: - \begin{equation*} - \scriptsize - \mbox{EC} = \frac{\sum\limits_{m=1}^{M} \left( E^{\mbox{com}}_m+E^{\mbox{list}}_m+E^{\mbox{comp}}_m - + E^{a}_m+E^{s}_m \right)}{M}, - \end{equation*} - -where $M$ corresponds to the number of periods. The total amount of energy -consumed by the sensors (EC) comes through taking into consideration four main -energy factors. The first one, denoted $E^{\scriptsize \mbox{com}}_m$, -represents the energy consumption spent by all the nodes for wireless -communications during period $m$. $E^{\scriptsize \mbox{list}}_m$, the next -factor, corresponds to the energy consumed by the sensors in LISTENING status -before receiving the decision to go active or sleep in period $m$. -$E^{\scriptsize \mbox{comp}}_m$ refers to the energy needed by all the leader -nodes to solve the integer program during a period. Finally, $E^a_{m}$ and -$E^s_{m}$ indicate the energy consumed by the whole network in the sensing phase -(active and sleeping nodes). - -\item{{\bf Number of Active Sensors Ratio(ASR)}:} It is important to have as few active nodes as possible in each round, -in order to minimize the communication overhead and maximize the -network lifetime. The Active Sensors Ratio is defined as follows: -\begin{equation*} -\scriptsize -\mbox{ASR}(\%) = \frac{\sum\limits_{r=1}^R \mbox{$A_r$}}{\mbox{$S$}} \times 100 . -\end{equation*} -Where: $A_r$ is the number of active sensors in the subregion $r$ during current period, $S$ is the total number of sensors in the network, and $R$ is the total number of the subregions in the network. - -\item {{\bf Execution Time}:} a sensor node has limited energy resources and computing power, therefore it is important that the proposed algorithm has the shortest possible execution time. The energy of a sensor node must be mainly used for the sensing phase, not for the pre-sensing ones. In this dissertation, the original execution time is computed on a laptop DELL with Intel Core~i3~2370~M (2.4 GHz) processor (2 cores) and the MIPS (Million Instructions Per Second) rate equal to 35330. To be consistent with the use of a sensor node with Atmels AVR ATmega103L microcontroller (6 MHz) and a MIPS rate equal to 6 to run the optimization resolution, this time is multiplied by 2944.2 $\left( \frac{35330}{2} \times \frac{1}{6} \right)$. - -\item {{\bf Stopped simulation runs}:} A simulation ends when the sensor network becomes disconnected (some nodes are dead and are not able to send information to the base station). We report the number of simulations that are stopped due to network disconnections and for which round it occurs ( in chapter 3, period consists of one round). -\end{enumerate} +\item \textbf{OPNET:} +OPNET (Optimized Network Engineering Tool)~\cite{ref192,ref200,ref201} is the first commercial simulation tool developed in 1987 for communication networks. It is a discrete event, object-oriented, general purpose network simulator, which is widely used in industry. It uses C and Java languages. It provides a comprehensive development environment for the specification, simulation, configuration, and performance analysis of the communication network. OPNET allows researchers to develop various models by means of a graphical interface. It provides different types of tools such as Probe Editor, Filter Tool, and Animation Viewer for data collection to model graph and animate the resulting output. Unlike ns-2, OPNET provides modeling for different sensor-specific hardware, such as physical-link transceivers and antennas. It includes sensor-specific models such as ad-hoc connectivity, mobility of nodes, node failure models, modeling of power-consumption, etc. OPNET is, a commercial simulator and the license is very expensive. This represents the main disadvantage of that simulator. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\iffalse -\subsection{Performance Analysis for Different Subregions} -\label{ch3:sec:04:05} - -In this subsection, we are studied the performance of our DiLCO protocol for a different number of subregions (Leaders). -The DiLCO-1 protocol is a centralized approach on all the area of the interest, while DiLCO-2, DiLCO-4, DiLCO-8, DiLCO-16 and DiLCO-32 are distributed on two, four, eight, sixteen, and thirty-two subregions respectively. We did not take the DiLCO-1 protocol in our simulation results because it need high execution time to give the decision leading to consume all it's energy before producing the solution for optimization problem. - -\subsubsection{Coverage Ratio} -%\label{ch3:sec:04:02:01} -In this experiment, Figure~\ref{Figures/ch3/R1/CR} shows the average coverage ratio for 150 deployed nodes. -\parskip 0pt -\begin{figure}[h!] -\centering - \includegraphics[scale=0.6] {Figures/ch3/R1/CR.pdf} -\caption{Coverage ratio for 150 deployed nodes} -\label{Figures/ch3/R1/CR} -\end{figure} -It can be seen that DiLCO protocol (with 4, 8, 16 and 32 subregions) gives nearly similar coverage ratios during the first thirty rounds. -DiLCO-2 protocol gives near similar coverage ratio with other ones for first 10 rounds and then decreased until the died of the network in the round $18^{th}$ because it consumes more energy with the effect of the network disconnection. -As shown in the figure ~\ref{Figures/ch3/R1/CR}, as the number of subregions increases, the coverage preservation for area of interest increases for a larger number of rounds. Coverage ratio decreases when the number of rounds increases due to dead nodes. Although some nodes are dead, thanks to DiLCO-8, DiLCO-16 and DiLCO-32 protocols, other nodes are preserved to ensure the coverage. Moreover, when we have a dense sensor network, it leads to maintain the coverage for a larger number of rounds. DiLCO-8, DiLCO-16 and DiLCO-32 protocols are slightly more efficient than other protocols, because they subdivide the area of interest into 8, 16 and 32~subregions; if one of the subregions becomes disconnected, the coverage may be still ensured in the remaining subregions. - -\subsubsection{Active Sensors Ratio} - Figure~\ref{Figures/ch3/R1/ASR} shows the average active nodes ratio for 150 deployed nodes. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R1/ASR.pdf} -\caption{Active sensors ratio for 150 deployed nodes } -\label{Figures/ch3/R1/ASR} -\end{figure} -The results presented in figure~\ref{Figures/ch3/R1/ASR} show the increase in the number of subregions led to increase in the number of active nodes. The DiLCO-16 and DiLCO-32 protocols have a larger number of active nodes but it preserve the coverage for a larger number of rounds. The advantage of the DiLCO-16 and DiLCO-32 protocols are that even if a network is disconnected in one subregion, the other ones usually continues the optimization process, and this extends the lifetime of the network. - -\subsubsection{The percentage of stopped simulation runs} -Figure~\ref{Figures/ch3/R1/SR} illustrates the percentage of stopped simulation runs per round for 150 deployed nodes. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R1/SR.pdf} -\caption{Percentage of stopped simulation runs for 150 deployed nodes } -\label{Figures/ch3/R1/SR} -\end{figure} +\item \textbf{GloMoSim:} -It can be observed that the DiLCO-2 is the approach which stops first because it applied the optimization on only two subregions for the area of interest that is why it is first exhibits network disconnections. -Thus, as explained previously, in case of the DiLCO-16 and DiLCO-32 with several subregions, the optimization effectively continues as long as a network in a subregion is still connected. This longer partial coverage optimization participates in extending the network lifetime. +GloMoSim (Global Mobile System Simulator)~\cite{ref202,ref204,ref205} is an open source, well-documented source code and scalable simulation environment developed in 1998 for mobile wireless networks. It uses a library called Parsec, which is an extension of C for parallel programming. The main feature of GloMoSim simulator is the parallel environment. A parallel network simulation is hard due to the communication among the simulated nodes on different machines. Several types of protocols and models are found in GloMoSim including TCP, +IEEE 802.11 CSMA/CA, MAC, UDP, HTTP, FTP, CBR, ODMRP, WRP, DSR, MACA, Telnet, AODV, etc. It uses a VT visualization tool to observe and debug these protocols. The GloMoSim tool is designed to be extensible with all protocols implemented as modules in its library. It also uses an object-oriented approach. +%It is dividing the nodes, and each object is responsible for executing one layer in the protocol stack of every node for its given division. +This mechanism minimizes the overhead of a large-scale sensor network. -\subsubsection{The Energy Consumption} -We measure the energy consumed by the sensors during the communication, listening, computation, active, and sleep modes for different network densities and compare it for different subregions. Figures~\ref{Figures/ch3/R1/EC95} and ~\ref{Figures/ch3/R1/EC50} illustrate the energy consumption for different network sizes for $Lifetime95$ and $Lifetime50$. +GloMoSim supports a wide range of protocols and its configuration is easy. Due to the parallel processing nature, it supplies a fast simulation. GloMoSim provides efficient simulation for IP networks whilst it does not give an accurate simulation for many sensor network applications. No releasing updates are available since 2000. It is currently updated as a commercial product called QualNet. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R1/EC95.pdf} -\caption{Energy Consumption for Lifetime95} -\label{Figures/ch3/R1/EC95} -\end{figure} + +\item \textbf{SENSE:} + +SENSE (Sensor Network Simulator and Emulator)~\cite{ref206} is an open source, general purpose, discrete event, efficient, easy to use, and powerful network simulator. The main objective of designing this simulator is to support various requirements of the users by taking into consideration the extensibility, reusability, and scalability. The SENSE uses an object-oriented approach and J-Sim's simulator component based architecture. It supports the parallelization with a poor support for users. +SENSE provides a component-port model to release simulation models from interdependency. This allows independence among components and enables the extensibility and reusability. A level of reusability is obtained by the extensive use of C++ template, where a component is usually declared as a template class so that it handles different types of data. The designers improved the scalability by using the same packet in the memories of all sensors, assuming that the packet should not be changed. The core of the simulator still lacks a general set of models, routing protocols, and a wide variety of configuration templates for WSNs. In addition, a visualization tool, which can quickly discover the bugs during the simulation, is desirable. + +\fi + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -The results show that DiLCO-16 and DiLCO-32 are the most competitive from the energy consumption point of view but as the network size increase the energy consumption increase compared with DiLCO-2, DiLCO-4, and DiLCO-8. The other approaches have a high energy consumption due to the energy consumed during the different modes of the sensor node.\\ +\item \textbf{TOSSIM:} -As shown in Figures~\ref{Figures/ch3/R1/EC95} and ~\ref{Figures/ch3/R1/EC50}, DiLCO-2 consumes more energy than the other versions of DiLCO, especially for large sizes of network. This is easy to understand since the bigger the number of sensors involved in the integer program, the larger the time computation to solve the optimization problem as well as the higher energy consumed during the communication. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R1/EC50.pdf} -\caption{Energy Consumption for Lifetime50} -\label{Figures/ch3/R1/EC50} -\end{figure} -In fact, a distributed method on the subregions greatly reduces the number of communications, the time of listening and computation so thanks to the partitioning of the initial network in several independent subnetworks. +TOSSIM~\cite{ref205,ref207,ref208} is a discrete event simulator for TinyOS based sensor networks, where the TinyOS application can be compiled on the TOSSIM framework, which runs on a computer rather than on the mote. This allow the users to test, debug, and analyze theirs algorithms in a controlled and repeatable environment. The users can check up their codes using debuggers and other development tools by executing them on the computer. TOSSIM is regarded as an emulator rather than a simulator because of its ability to simulate both software and hardware of the mote. TOSSIM is specially-designed for TinyOS applications run on Berkeley MICA Motes. TOSSIM needs to be improved to include four requirements: scalability, completeness, fidelity, and bridging, and to manage a large number of sensor nodes with different configurations to be scalable. For completeness, it has to capture behavior and interactions of a system at a different of levels. The simulator should capture behavior of a network with accurate timing of interactions on a mote and among motes for fidelity. The bridging requirement is satisfied due to executing the simulated code directly in a real mote. Two programming interfaces are supported by TOSSIM: Python and C++. The C++ interface transforms the code easily from one form to another. Python allows interaction with an executing simulation dynamically, like a powerful debugger. TOSSIM provides a high fidelity and scalable simulation of a complete TinyOS sensor network. It visualizes and interacts with executing simulations using GUI tool and TinyViz. The users can develop new visualizations and interfaces for TinyViz using simple plug-in model. The simulator's effectiveness for analyzing low-level protocols is decreased due to inaccuracies in the probabilistic bit error model. Moreover, TOSSIM is only supported by MICA motes platform. -\subsubsection{Execution Time} -In this experiment, the execution time of the our distributed optimization approach has been studied. Figure~\ref{Figures/ch3/R1/T} gives the average execution times in seconds for the decision phase (solving of the optimization problem) during one round. They are given for the different approaches and various numbers of sensors. The original execution time is computed as described in section \ref{ch3:sec:04:02}. -%The original execution time is computed on a laptop DELL with intel Core i3 2370 M (2.4 GHz) processor (2 cores) and the MIPS (Million Instructions Per Second) rate equal to 35330. To be consistent with the use of a sensor node with Atmels AVR ATmega103L microcontroller (6 MHz) and a MIPS rate equal to 6 to run the optimization resolution, this time is multiplied by 2944.2 $\left( \frac{35330}{2} \times 6\right)$ and reported on Figure~\ref{fig8} for different network sizes. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\iffalse -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R1/T.pdf} -\caption{Execution Time (in seconds)} -\label{Figures/ch3/R1/T} -\end{figure} +\item \textbf{GTSNetS:} -We can see from figure~\ref{Figures/ch3/R1/T}, that the DiLCO-32 has very low execution times in comparison with other DiLCO versions, because it distributed on larger number of small subregions. Conversely, DiLCO-2 requires to solve an optimization problem considering half the nodes in each subregion presents high execution times. +GTSNetS (Georgia Tech Sensor Network Simulator)~\cite{ref209,ref210} is an open-source, C++, large scale, event-driven simulation tool to evaluate the applications, algorithms, and protocols. It is capable of evaluating the impact of various architectural choices and designs on the lifetime and performance of a particular sensor network. GTSNetS is constructed on the top of the Georgia Tech Network Simulator (GTNetS), where it uses and expands all the design choices of the existing GTNetS simulator. The main feature of GTSNetS simulator is to support several thousand nodes. +It is organized efficiently in a modular way to support large-scale WSNs and designed to be easy to use by the users. Several choices are provided by GTSNetS to users, offering various alternatives in network protocols, energy models, applications, and tracing options. Furthermore, the existing models can be simply extended or replaced according to user need. The network lifetime can be tracked by GTSNetS and the energy consumption of each unit can be evaluated. Therefore, the users can study the impact of different architectural choices on lifetime and energy consumption. The mobility is inherited from GTNetS simulator. Therefore, it provides a specification of mobile sensor nodes, moving sensed objects, as well as a mobile base station. +GTSNetS provides graphical user interface and extensive packet tracing. +%The stopped updating and maintaining the project since Oct, 2008 represents the main disadvantage of this simulator. +The tool is no longer maintained since October 2008. -The DiLCO-32 protocol has more suitable times at the same time it turn on redundant nodes more. We think that in distributed fashion the solving of the optimization problem in a subregion can be tackled by sensor nodes. Overall, to be able to deal with very large networks, a distributed method is clearly required. +\fi +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\end{enumerate} -\subsubsection{The Network Lifetime} -In figure~\ref{Figures/ch3/R1/LT95} and \ref{Figures/ch3/R1/LT50}, network lifetime, $Lifetime95$ and $Lifetime50$ respectively, are illustrated for different network sizes. + +In this section, we investigated some simulation tools for WSNs. A large number of simulation tools are available for WSNs, with different characteristics and capabilities. Hence, it seems hard to decide which simulation tool to choose and which one is more appropriate for large-scale WSNs. Table~\ref{table:1} illustrates a comparison among some simulation tools~\cite{ref179}. According to table~\ref{table:1}, OMNeT++ seems to be a good candidate to be used as an evaluation tool for our proposed protocols in this dissertation. OMNeT++ is a free, extensible, and scalable simulator. It provides an easy-to-use interface using C++ language. Furthermore, several frameworks can be used with OMNeT++ such as INET, INETMANET, Veins, MiXiM, and Castalia to support various needs of users, such as mobility, Internet, vehicular, and sensor networks. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R1/LT95.pdf} -\caption{Network Lifetime for $Lifetime95$} -\label{Figures/ch3/R1/LT95} -\end{figure} -We see that DiLCO-2 protocol results in execution times that quickly become unsuitable for a sensor network as well as the energy consumed during the communication seems to be huge because it is distributed over only two subregions. -As highlighted by figures~\ref{Figures/ch3/R1/LT95} and \ref{Figures/ch3/R1/LT50}, the network lifetime obviously increases when the size of the network increases, with DiLCO-16 protocol that leads to the larger lifetime improvement. By choosing the best suited nodes, for each round, to cover the area of interest and by -letting the other ones sleep in order to be used later in next rounds, DiLCO-16 protocol efficiently extends the network lifetime because the benefit from the optimization with 16 subregions is better than DiLCO-32 protocol with 32 subregion. DilCO-32 protocol puts in active mode a larger number of sensor nodes especially near the borders of the subdivisions. -Comparison shows that DiLCO-16 protocol, which uses 16 leaders, is the best one because it is used less number of active nodes during the network lifetime compared with DiLCO-32 protocol. It also means that distributing the protocol in each node and subdividing the sensing field into many subregions, which are managed independently and simultaneously, is the most relevant way to maximize the lifetime of a network. -\begin{figure}[h!] +\begin{table}[h!] \centering -\includegraphics[scale=0.6]{Figures/ch3/R1/LT50.pdf} -\caption{Network Lifetime for $Lifetime50$} -\label{Figures/ch3/R1/LT50} -\end{figure} +\caption{Comparison among some simulation tools} + +\begin{tabular}{ |>{\centering\arraybackslash}m{0.7in}||>{\centering\arraybackslash}m{0.8in}|>{\centering\arraybackslash}m{1in}|>{\centering\arraybackslash}m{1.2in}|>{\centering\arraybackslash}m{0.8in}|>{\centering\arraybackslash}m{0.8in}| } + \hline + \multirow{2}{*} {\begin{minipage}{0.7in}\centering \textbf{Simulation Tool}\end{minipage}} %{\textbf{Simulation Tool} } + &\multicolumn{5}{|c|}{\textbf{Features of Simulation Tool}} \\ + \cline{2-6} + + &\textbf{Interface} &\textbf{Accessibility \& User Support}&\textbf{Availability of WSNs Modules}&\textbf{Extensibility}&\textbf{Scalability}\\ + \hline \hline + + \textbf{ns -2} & C++/OTcl with limited visual support & Open source with good user support & Energy model, battery model, mobility & Excellent & Limited \\ +\hline + \textbf{OMNeT++} & C++/NED with good GUI and debugging support & Free for academic use, license for commercial use with good user support & Energy model, battery model, accurate wireless channel and radio modeling & Excellent & Large-scale \\ -\subsection{Performance Analysis for Primary Point Models} -\label{ch3:sec:04:06} +\hline -In this section, we are studied the performance of DiLCO~16 approach for a different primary point models. The objective of this comparison is to select the suitable primary point model to be used by DiLCO protocol. + \textbf{OPNET} & C or C++/Java with Excellent GUI and debugging support & Free for academic use, license for commercial use with excellent user support & Energy model, battery model, routing protocols (directed diffusion), mobility, node failure model & Excellent & Moderate \\ -In this comparisons, DiLCO-16 protocol are used with five models which are called Model~1( With 5 Primary Points), Model~2 ( With 9 Primary Points), Model~3 ( With 13 Primary Points), Model~4 ( With 17 Primary Points), and Model~5 ( With 21 Primary Points). -\subsubsection{Coverage Ratio} -In this experiment, we Figure~\ref{Figures/ch3/R2/CR} shows the average coverage ratio for 150 deployed nodes. -\parskip 0pt -\begin{figure}[h!] -\centering - \includegraphics[scale=0.6] {Figures/ch3/R2/CR.pdf} -\caption{Coverage ratio for 150 deployed nodes} -\label{Figures/ch3/R2/CR} -\end{figure} -It is shown that all models provide a very near coverage ratios during the network lifetime, with very small superiority for the models with higher number of primary points. Moreover, when the number of rounds increases, coverage ratio produced by Model~3, Model~4, and Model~5 decreases in comparison with Model~1 and Model~2 due to the high energy consumption during the listening to take the decision after finishing optimization process for larger number of primary points. As shown in figure ~\ref{Figures/ch3/R2/CR}, Coverage ratio decreases when the number of rounds increases due to dead nodes. Although some nodes are dead, -thanks to Model~2, which is slightly more efficient than other Models, because it is balanced between the number of rounds and the better coverage ratio in comparison with other Models. - -\subsubsection{Active Sensors Ratio} - Figure~\ref{Figures/ch3/R2/ASR} shows the average active nodes ratio for 150 deployed nodes. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R2/ASR.pdf} -\caption{Active sensors ratio for 150 deployed nodes } -\label{Figures/ch3/R2/ASR} -\end{figure} -The results presented in figure~\ref{Figures/ch3/R2/ASR} show the superiority of the proposed Model 1, in comparison with the other Models. The -model with less number of primary points uses less active nodes than the other models, which uses a more number of primary points to represent the area of the sensor. According to the results that presented in figure~\ref{Figures/ch3/R2/CR}, we observe that although the Model~1 continue to a larger number of rounds, but it has less coverage ratio compared with other models. The advantage of the Model~2 approach is to use less number of active nodes for each round compared with Model~3, Model~4, and Model~5; and this led to continue for a larger number of rounds with extending the network lifetime. Model~2 has a better coverage ratio compared to Model~1 and acceptable number of rounds. +\hline +% \textbf{GloMoSim} & Parsec (C-Based) with limited visual support & Open source with poor user support & Sensor network specific MAC and network protocols, mobility model & Good & Large-scale \\ -\subsubsection{The percentage of stopped simulation runs} -In this study, we want to show the effect of increasing the primary points on the number of stopped simulation runs for each round. Figure~\ref{Figures/ch3/R2/SR} illustrates the percentage of stopped simulation runs per round for 150 deployed nodes. +%\hline -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R2/SR.pdf} -\caption{Percentage of stopped simulation runs for 150 deployed nodes } -\label{Figures/ch3/R2/SR} -\end{figure} + %\textbf{SENSE} & C++ with good GUI support & Open source with poor user support & Energy models, battery models, mobility, modeling of physical environment & Excellent & Large-scale \\ -As shown in Figure~\ref{Figures/ch3/R2/SR}, when the number of primary points are increased, the percentage of the stopped simulation runs per round is increased. The reason behind the increase is the increase in the sensors dead when the primary points increases. We are observed that the Model~1 is a better than other models because it conserve more energy by turn on less number of sensors during the sensing phase, but in the same time it preserve the coverage with a less coverage ratio in comparison with other models. Model~2 seems to be more suitable to be used in wireless sensor networks. +%\hline +% \textbf{GTSNetS} & C++ with good user interface \& visual support & Open source with good user support & Energy model, battery model, accuracy model, model applications, mobility & Excellent & Very large-scale \\ -\subsubsection{The Energy Consumption} -In this experiment, we study the effect of increasing the primary points to represent the area of the sensor on the energy consumed by the wireless sensor network for different network densities. Figures~\ref{Figures/ch3/R2/EC95} and ~\ref{Figures/ch3/R2/EC50} illustrate the energy consumption for different network sizes for $Lifetime95$ and $Lifetime50$. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R2/EC95.pdf} -\caption{Energy Consumption with $95\%-Lifetime$} -\label{Figures/ch3/R2/EC95} -\end{figure} - -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R2/EC50.pdf} -\caption{Energy Consumption with $Lifetime50$} -\label{Figures/ch3/R2/EC50} -\end{figure} +\hline -We see from the results presented in Figures~\ref{Figures/ch3/R2/EC95} and \ref{Figures/ch3/R2/EC50}, The energy consumed by the network for each round increases when the primary points increases, because the decision for optimization process will takes more time leads to consume more energy during the listening mode. The results show that Model~1 is the most competitive from the energy consumption point of view but the worst one from coverage ratio point of view. The other Models have a high energy consumption due to the increase in the primary points, which are led to increase the energy consumption during the listening mode before producing the solution by solving the optimization process. In fact, we see that Model~2 is a good candidate to be used by wireless sensor network because it preserve a good coverage ratio and a suitable energy consumption in comparison with other models. + \textbf{TOSSIM} & C++/Python with good GUI support & Open source (BSD) with excellent user support & Energy models with power TOSSIM ads-on, Bit-level radio model & Good & Large-scale \\ +\hline +\end{tabular} -\subsubsection{Execution Time} -In this experiment, we have studied the impact of the increase in primary points on the execution time of DiLCO protocol. Figure~\ref{Figures/ch3/R2/T} gives the average execution times in seconds for the decision phase (solving of the optimization problem) during one round. The original execution time is computed as described in section \ref{ch3:sec:04:02}. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R2/T.pdf} -\caption{Execution Time(s) vs The Number of Sensors } -\label{Figures/ch3/R2/T} -\end{figure} +\label{table:1} +\end{table} -They are given for the different primary point models and various numbers of sensors. We can see from Figure~\ref{Figures/ch3/R2/T}, that Model~1 has lower execution time in comparison with other Models, because it used smaller number of primary points to represent the area of the sensor. Conversely, the other primary point models have been presented a higher execution times. -Moreover, Model~2 has more suitable times and coverage ratio that lead to continue for a larger number of rounds extending the network lifetime. We think that a good primary point model, this one that balances between the coverage ratio and the number of rounds during the lifetime of the network. -\subsubsection{The Network Lifetime} -Finally, we will study the effect of increasing the primary points on the lifetime of the network. In Figure~\ref{Figures/ch3/R2/LT95} and in Figure~\ref{Figures/ch3/R2/LT50}, network lifetime, $Lifetime95$ and $Lifetime50$ respectively, are illustrated for different network sizes. +\section{Optimization Solvers} +\label{ch3:3} +There are several optimization solvers to solve linear optimization problems. Linear programming~\cite{ref211} is a technique for determining the maximum or minimum of a linear function of non-negative variables subject to constraints expressed as linear equalities or inequalities. Linear programming is a special case of mathematical programming (mathematical optimization). +Linear programs are problems that can be expressed in canonical form as follows: -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R2/LT95.pdf} -\caption{Network Lifetime for $Lifetime95$} -\label{Figures/ch3/R2/LT95} -\end{figure} + \begin{align} & \text{Maximize}~ (or ~\text{Minimize})~ && \mathbf{c}^\mathrm{T} \mathbf{x}\\ & \text{Subject to} && A \mathbf{x} \leq \mathbf{b} \\ & \text{and} && \mathbf{x} \ge \mathbf{0} \end{align} + +where x represents the vector of variables (to be determined), c and b are vectors of (known) coefficients, A is a (known) matrix of coefficients, and $\left( \cdot \right) ^\mathrm{T}$ is the matrix transpose. The term to be maximized or minimized is called the objective function ($c^Tx$ in this case). The inequalities $Ax \leqslant b$ and $x \geqslant 0$ are the constraints which specify a convex polytope over which the objective function is to be optimized. +A linear programming problem, in which some or all of the unknown variables are restricted to be integers, it is called an integer programming (IP) problem. +%IP problems are a special cases of optimization problems, where the variables can only assume integer values. The IP problems are NP-hard. Mixed integer linear programming (MIP) problems are also special cases, where only some of the variables are restricted to integer values. The optimization problems with integer variables can also be linear or nonlinear, depending on the terms of their objective function and their constraints. However, the terms IP and MIP are almost always associated with problems that have linear features. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R2/LT50.pdf} -\caption{Network Lifetime for $Lifetime50$} -\label{Figures/ch3/R2/LT50} -\end{figure} +Linear optimization is used to solve different problems in various fields of study. It is applied for economic, business, and industry problems. For example, in the industry linear optimization is used to solve transportation, energy, telecommunications, and manufacturing problems. +%Linear optimization is succeeded in modeling different types of problems like planning, routing, scheduling, assignment, and design. +Many approaches have been proposed to solve linear programming (IP or Mixed Integer Programming (MIP)) problems and they are classified into two main groups~\cite{ref221}: -As highlighted by figures~\ref{Figures/ch3/R2/LT95} and \ref{Figures/ch3/R2/LT50}, the network lifetime obviously increases when the size of the network increases, with Model~1 that leads to the larger lifetime improvement. -Comparison shows that the Model~1, which uses less number of primary points, is the best one because it is less energy consumption during the network lifetime. It is also the worst one from the point of view of coverage ratio. Our proposed Model~2 efficiently prolongs the network lifetime with a good coverage ratio in comparison with other models. - +\begin{itemize} +\item \textbf{Heuristic Optimization:} provides good solutions, but not necessarily optimal solutions, for problems that can not be solved efficiently and with acceptable computation time by classical optimization methods. There is no guarantee for the optimal solution. Examples of such approaches are genetic algorithms, swarm intelligence, and tabu search \cite{ref237}. -\subsection{Performance Comparison with other Approaches} -\label{ch3:sec:04:07} -Based on the results, which are conducted from previous two subsections, \ref{ch3:sec:04:02} and \ref{ch3:sec:04:03}, we have found that DiLCO-16 protocol and DiLCO-32 protocol with Model~2 are the best candidates to be compared with other two approaches. The first approach, called DESK that proposed by ~\cite{DESK}, which is a full distributed coverage algorithm. The second approach, called GAF~\cite{GAF}, consists in dividing the region into fixed squares. During the decision phase, in each square, one sensor is chosen to remain on during the sensing phase time. +\item \textbf{Classical Optimization:} provides and guarantees optimal solutions for problems. Examples of such methods are zero-one enumeration algorithms and branch-and-bound algorithm, which are provided by linear optimization solvers \cite{ref221}. -\subsubsection{Coverage Ratio} -In this experiment, the average coverage ratio for 150 deployed nodes has been demonstrated figure~\ref{Figures/ch3/R3/CR}. - -\parskip 0pt -\begin{figure}[h!] -\centering - \includegraphics[scale=0.6] {Figures/ch3/R3/CR.pdf} -\caption{Coverage ratio for 150 deployed nodes} -\label{Figures/ch3/R3/CR} -\end{figure} -It has been shown that DESK and GAF provide a little better coverage ratio with 99.99\% and 99.91\% against 99.1\% and 99.2\% produced by DiLCO-16 and DiLCO-32 for the lowest number of rounds. This is due to the fact that DiLCO protocol versions put in sleep mode redundant sensors using optimization (which lightly decreases the coverage ratio) while there are more nodes are active in the case of DESK and GAF. +\end{itemize} -Moreover, when the number of rounds increases, coverage ratio produced by DESK and GAF protocols decreases. This is due to dead nodes. However, DiLCO-16 protocol and DiLCO-32 protocol maintain almost a good coverage. This is because they optimized the coverage and the lifetime in wireless sensor network by selecting the best representative sensor nodes to take the responsibility of coverage during the sensing phase and this will leads to continue for a larger number of rounds and prolonging the network lifetime; although some nodes are dead, sensor activity scheduling of our protocol chooses other nodes to ensure the coverage of the area of interest. +Linear optimization solvers vary in their characteristics and capabilities. Therefore, in this section, we present the most popular free and commercial linear optimization solvers~\cite{ref212}. -\subsubsection{Active Sensors Ratio} -It is important to have as few active nodes as possible in each round, in order to minimize the energy consumption and maximize the network lifetime. Figure~\ref{Figures/ch3/R3/ASR} shows the average active nodes ratio for 150 deployed nodes. +\begin{enumerate} [(i)] -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R3/ASR.pdf} -\caption{Active sensors ratio for 150 deployed nodes } -\label{Figures/ch3/R3/ASR} -\end{figure} - -The results presented in figure~\ref{Figures/ch3/R3/ASR} show the superiority of the proposed DiLCO-16 protocol and DiLCO-32 protocol, in comparison with the other approaches. We have observed that DESK and GAF have 37.5 \% and 44.5 \% active nodes and DiLCO-16 protocol and DiLCO-32 protocol compete perfectly with only 17.4 \%, 24.8 \% and 26.8 \% active nodes for the first 14 rounds. Then as the number of rounds increases DiLCO-16 protocol and DiLCO-32 protocol have larger number of active nodes in comparison with DESK and GAF, especially from round $35^{th}$ because they give a better coverage ratio than other approaches. We see that DESK and GAF have less number of active nodes beginning at the rounds $35^{th}$ and $32^{th}$ because there are many nodes are died due to the high energy consumption by the redundant nodes during the sensing phase. - -\subsubsection{The percentage of stopped simulation runs} -The results presented in this experiment, is to show the comparison of DiLCO-16 protocol and DiLCO-32 protocol with other two approaches from point of view of stopped simulation runs per round. -Figure~\ref{Figures/ch3/R3/SR} illustrates the percentage of stopped simulation -runs per round for 150 deployed nodes. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R3/SR.pdf} -\caption{Percentage of stopped simulation runs for 150 deployed nodes } -\label{Figures/ch3/R3/SR} -\end{figure} -It has been observed that DESK is the approach, which stops first because it consumes more energy for communication as well as it turn on a large number of redundant nodes during the sensing phase. On the other hand DiLCO-16 protocol and DiLCO-32 protocol have less stopped simulation runs in comparison with DESK and GAF because it distributed the optimization on several subregions in order to optimizes the coverage and the lifetime of the network by activating a less number of nodes during the sensing phase leading to extend the network lifetime and coverage preservation. The optimization effectively continues as long as a network in a subregion is still connected. +\item \textbf{GNU Linear Programming Kit (GLPK):} -\subsubsection{The Energy Consumption} -In this experiment, we have studied the effect of the energy consumed by the wireless sensor network during the communication, computation, listening, active, and sleep modes for different network densities and compare it with other approaches. Figures~\ref{Figures/ch3/R3/EC95} and ~\ref{Figures/ch3/R3/EC50} illustrate the energy consumption for different network sizes for $Lifetime95$ and $Lifetime50$. +GLPK~\cite{ref214,ref213,AMPL} is a free and open source software written in C programming language, which is presented for solving large-scale Linear Programming (LP), Mixed Integer Programming (MIP), and other related problems. It is a mathematical programming project that is a part of the GNU project. The GLPK uses the revised simplex method and the primal-dual interior point method for non-integer problems, and the branch-and-bound algorithm together with Gomory's mixed integer cuts for (mixed) integer problems. +The users use either an interactive command line or C++ and java application programming interface (API) in order to interact with GLPK. Several input file formats are accepted by GLPK such as MPS (Mathematical Programming System), Free MPS, LP, GLPK, and MathProg format. The major components of the GLPK package are primal and dual simplex methods, primal-dual interior-point method, branch-and-cut method, translator for GNU MathProg, API, and stand-alone LP/MIP solver. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R3/EC95.pdf} -\caption{Energy Consumption with $95\%-Lifetime$} -\label{Figures/ch3/R3/EC95} -\end{figure} -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R3/EC50.pdf} -\caption{Energy Consumption with $Lifetime50$} -\label{Figures/ch3/R3/EC50} -\end{figure} +\item \textbf{lp$\_$solve:} -The results show that DiLCO-16 protocol and DiLCO-32 protocol are the most competitive from the energy consumption point of view. The other approaches have a high energy consumption due to activating a larger number of redundant nodes as well as the energy consumed during the different modes of sensor nodes. In fact, a distributed method on the subregions greatly reduces the number of communications and the time of listening so thanks to the partitioning of the initial network into several independent subnetworks. +lp$\textunderscore$solve~\cite{ref215,ref213} is a free linear (integer) programming solver based on the revised simplex method and the branch-and-bound method for the integers. It is freely available under the GNU Lesser General Public License. The primal and dual simplex algorithms are used by lp$\textunderscore$solve for solving LP models. lp$\textunderscore$solve is written using C programming language and can be compiled on many different platforms like Linux and Windows. The users interact with it using either a command line or an API. It provides a C, C$\#$, C++, Java, and .NET API. lp$\textunderscore$solve can read the input MPS, Free MPS, and LP file format. The pure linear, (mixed) integer/binary, semi-continuous and special ordered sets (SOS) models are solved. It handles integer variables, semi-continuous variables, and special ordered sets by means of branch-and-bound algorithm. -\subsubsection{The Network Lifetime} -In this experiment, we have observed the superiority of DiLCO-16 protocol and DiLCO-32 protocol against other two approaches in prolonging the network lifetime. In figures~\ref{Figures/ch3/R3/LT95} and \ref{Figures/ch3/R3/LT50}, network lifetime, $Lifetime95$ and $Lifetime50$ respectively, are illustrated for different network sizes. +\item \textbf{CLP:} -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R3/LT95.pdf} -\caption{Network Lifetime for $Lifetime95$} -\label{Figures/ch3/R3/LT95} -\end{figure} +The COIN-OR Linear Programming (CLP)~\cite{ref216,ref217} is a free, open-source, linear programming solver written in C++ programming language. It is reliable and able to tackle the very large linear optimization problems. The CLP is a part of the Coin-OR project that aims at creating open software for the operations research community. COIN-OR projects such as SYMPHONY, BCP (Branch Cut and Price), and CBC (COIN-OR Branch and Cut) also uses CLP. It includes Dual and Primal Simplex algorithms, but it also contains an Interior Point algorithm. The CLP is available under the Eclipse Public License version 1.0, and the users interact with it through either an interactive command line or through a C++ API. The CLP is able to use the input MPS, Free MPS, and LP file formats. -\begin{figure}[h!] -\centering -\includegraphics[scale=0.6]{Figures/ch3/R3/LT50.pdf} -\caption{Network Lifetime for $Lifetime50$} -\label{Figures/ch3/R3/LT50} -\end{figure} +\item \textbf{CPLEX:} -As highlighted by figures~\ref{Figures/ch3/R3/LT95} and \ref{Figures/ch3/R3/LT50}, the network lifetime obviously increases when the size of the network increases, with DiLCO-16 protocol and DiLCO-32 protocol that leads to maximize the lifetime of the network compared with other approaches. -By choosing the best suited nodes, for each round, by optimizing the coverage and lifetime of the network to cover the area of interest and by letting the other ones sleep in order to be used later in next periods, DiLCO-16 protocol and DiLCO-32 protocol efficiently prolonged the network lifetime. -Comparison shows that DiLCO-16 protocol and DiLCO-32 protocol, which are used distributed optimization over the subregions, is the best one because it is robust to network disconnection during the network lifetime as well as it consumes less energy in comparison with other approaches. It also means that distributing the algorithm in each node and subdividing the sensing field into many subregions, which are managed independently and simultaneously, is the most relevant way to maximize the lifetime of a network. +The IBM ILOG CPLEX Optimization Studio (often informally referred to simply as CPLEX)~\cite{ref218,ref211} is a commercial, analytical decision support, and optimization software toolkit for fast development of optimization models using mathematical and constraint programming. It combines an integrated development environment (IDE) with the powerful Optimization Programming Language (OPL) and high-performance ILOG CPLEX optimizer solvers. The CPLEX is developed by IBM and is designed to tackle the large-scale (mixed integer) linear problems. The CPLEX optimizer includes a modeling layer called "Concert" that provides interfaces to the C++, C$\#$, Python, and Java languages. Furthermore, it provides a connection to Microsoft Excel and MATLAB. The CPLEX is capable of optimizing the business decisions with high-performance optimization engines. It develops and deploys optimization models quickly by using flexible interfaces and pre-constructed deployment scenarios. %In addition, it creates real-world applications. -\section{Conclusion} -\label{ch3:sec:05} -A crucial problem in WSN is to schedule the sensing activities of the different nodes in order to ensure both coverage of the area of interest and longer -network lifetime. The inherent limitations of sensor nodes, in energy provision, communication and computing capacities, require protocols that optimize the use -of the available resources to fulfill the sensing task. To address this problem, this chapter proposes a two-step approach. Firstly, the field of sensing -is divided into smaller subregions using the concept of divide-and-conquer method. Secondly, a distributed protocol called Distributed Lifetime Coverage -Optimization is applied in each subregion to optimize the coverage and lifetime performances. In a subregion, our protocol consists in electing a leader node -which will then perform a sensor activity scheduling. The challenges include how to select the most efficient leader in each subregion and the best representative set of active nodes to ensure a high level of coverage. To assess the performance of our approach, we compared it with two other approaches using many performance metrics like coverage ratio or network lifetime. We have also studied the impact of the number of subregions chosen to subdivide the area of interest, considering different network sizes. The experiments show that increasing the number of subregions improves the lifetime. The more subregions there are, the more robust the network is against random disconnection resulting from dead nodes. However, for a given sensing field and network size there is an optimal number of subregions. Therefore, in case of our simulation context a subdivision in $16$~subregions seems to be the most relevant. +\item \textbf{Gurobi:} + +The Gurobi Optimizer~\cite{ref219,ref220,ref211} is a commercial optimization solver for LP, Quadratic Programming (QP), Quadratically Constrained Programming (QCP), Mixed Integer Linear Programming (MILP), Mixed-Integer Quadratic Programming (MIQP), and Mixed-Integer Quadratically Constrained Programming (MIQCP). The Gurobi optimizer is written in C. It is available on all computing platforms and accessible from several programming languages. The Gurobi optimizer supports interfaces for various programming and modeling languages including object-oriented interfaces for C++, Java, .NET, and Python; matrix-oriented interfaces for C, MATLAB, and R; Links to standard modeling languages like AIMMS, AMPL, GAMS, and MPL; and links to Excel through Premium Solver Platform and Risk Solver Platform are available. + + +\end{enumerate} + + +B. Meindl and M. Templ~\cite{ref212} studied the efficiency of above optimization solvers. They used a set of instances of a difficult optimization problem called the Attacker problems (formulated as a LP) \cite{ref240} in order to achieve a performance comparison of GLPK, lp$\_$solve, CLP, GUROBI, and CPLEX optimization solvers. %They considered a total of 200 problem instances for this study, 100 of these problem instances are based on problems with two dimensions, and 100 problem instances are three-dimensional. + +In tables~\ref{my-label1} and \ref{my-label2}, we report the result of their comparisons the running times of the five linear program solvers to find solutions for instances related to the two-dimensional problem, and for instances related to the three-dimensional problem (with more variables and constraints). +%to the 200 two-dimensional, 200 three-dimensional, and all 400 problem instances. +%In order to solve the attacker’s problem for a given problem instance, it is needed to both minimize and maximize any given problem. Therefore, a total of 400 problem instances had been solved when only 200 problem instances have been generated. +The running time of the fastest solver has been scaled to one and the running times of the other linear solvers were scaled to reflect this scaling. + + +\begin{table}[h] +\caption{Total (in seconds) and scaled running times for 2-dimensional problem instances (results of B. Meindl and M. Templ~\cite{ref212})} +\label{my-label1} +\resizebox{\textwidth}{!}{% +\begin{tabular}{|c|c|c|c|c|c|} +\hline +\textbf{Optimization Solvers} & \textbf{GLPK} & \textbf{lp\_solve} & \textbf{CLP} & \textbf{Gurobi} & \textbf{CPLEX} \\ \hline +\textbf{Total Running Time} & 180.1 & 2861.9 & 273.9 & 73.6 & 20.9 \\ \hline +\textbf{Scaled Running Time} & 9 & 137 & 13 & 4 & 1 \\ \hline +\end{tabular} +} +\end{table} +\begin{table}[h] +\caption{Total (in seconds) and scaled running times for 3-dimensional problem instances (results of B. Meindl and M. Templ~\cite{ref212})} +\label{my-label2} +\resizebox{\textwidth}{!}{% +\begin{tabular}{|c|c|c|c|c|c|} +\hline +\textbf{Optimization Solvers} & \textbf{GLPK} & \textbf{lp\_solve} & \textbf{CLP} & \textbf{Gurobi} & \textbf{CPLEX} \\ \hline +\textbf{Total Running Time} & 48405 & 979876 & 666792 & 38634 & 236 \\ \hline +\textbf{Scaled Running Time} & 205 & 4149 & 2823 & 164 & 1 \\ \hline +\end{tabular} +} +\end{table} + + +%\begin{table}[h] +%\caption{Total (in seconds) and scaled running times for all problems (results of B. Meindl and M. Templ~\cite{ref212})} +%\label{my-label3} +%\resizebox{\textwidth}{!}{% +%\begin{tabular}{|c|c|c|c|c|c|} +%\hline +%\textbf{Optimization Solvers} & \textbf{GLPK} & \textbf{lp\_solve} & \textbf{CLP} & \textbf{Gurobi} & \textbf{CPLEX} \\ \hline +%\textbf{Total Running Time} & 48585 & 982737 & 667066 & 38708 & 257 \\ \hline +%\textbf{Scaled Running Time} & 189 & 3822 & 2594 & 151 & 1 \\ \hline +%\end{tabular} +%} +%\end{table} + + +The results in tables~\ref{my-label1} and \ref{my-label2} indicate that open source solvers perform worse than standard commercial solvers when applied to instances of the attacker’s problem. The GLPK outperforms the other free and open source solvers, but is still slower than CPLEX and GUROBI. We have decided to use the GLPK as an optimization solver in this dissertation to solve the proposed integer programs during the decision phase of the nodes. We motivate the use of the GLPK optimization solver for many reasons, including: + +\begin{enumerate} [(i)] + +\item It is free and its installation is easy. +\item The GLPK does not lead to a fast solution of a large problem as in commercial optimization solvers, but it solves the smaller problems with a reasonable time. In this dissertation, we used a divide-and-conquer method to divide the large problem into smaller instances, and then the GLPK optimization solver is used to solve each of them. +\item It is easy to use the GLPK solver and it is possible to call its routines within a simulator. +\item The GLPK comes with a stand-alone solver, a callable library, and the modeling language GMPL. The GMPL is compatible with AMPL and is extremely easy to learn. + \item Modeling language and solver can be used independently. +\item GUI is available for Windows, Mac OS X, and Linux. Java, Python, and Matlab interfaces are available. +%\item Database support and formatted text output. +%\item Exact simplex algorithm and branch-and-bound method are integrated with GLPK. + +\end{enumerate} + +\section{Conclusion} +\label{ch3:4} +\indent In this chapter, an overview of the evaluation tools for wireless sensor networks and optimization solvers has been presented. Major testbeds for wireless sensor network have been demonstrated. We have found that most researchers in the field of WSNs use the simulators to evaluate theirs works because they are free, easy to use, more flexible, and scalable for large WSNs. Several simulators for wireless sensor networks are described. The comparison among some types of network simulators show that OMNeT++ simulator is a good candidate to be used as performance evaluation tool to evaluate the efficiency of our protocols in this dissertation. This chapter also highlights the optimization problem in WSNs and the most popular free and commercial linear optimization solvers. The commercial optimization solvers outperform the free optimization solvers. GLPK has been chosen as a good candidate to solve the proposed optimization problems in this dissertation because it is free, easy to use, and better than some other free optimization solvers. \ No newline at end of file