3.1. Field establishment
Establishment of the target area is one of the important issues to execute MSNS. When mobile sensor network is established for various applications, the number of terrains is as many as the number of applications. Therefore, MSNS uses the method of establishing field where mobile sensor network is to be formed and based on such terrain, selecting target area that requires observation.
MSNS uses the GML [11–14] to establish field that includes obstacles. Since the GML is the standard for geospatial data, it has the high compatibility and is convenient for configuring field. And as the GML contains the coordinate information, it is possible to utilize the information to calculate the actual coordinate information of mobile sensors that estimate the locations of each other based on the relative coordinates. In the GML, factors that can be obstacles such as building are written mostly with polygon. Therefore, MSNS sets the polygon of the GML as an obstacle and processes it.
3.2. Coverage of MSNS
Another important issue to implement the MSNS is the moving technique for mobile sensors. The mobile sensors are required to maintain a given connectivity, avoid obstacles, and maximize coverage in the target area. Therefore, this article suggests the coverage method that adds the obstacle avoidance method to the constrained coverage method that maximizes coverage while maintaining the given connectivity [8, 15].
The method has preconditions as follows. First, the method is based on the binary model that mobile sensors sense the target within the sensing range at the rate of 100% but cannot sense the target out of the sensing range. Second, all of the mobile sensors have the equal sensing distance (R_{s}) and the equal communication distance (R_{c}). Third, mobile sensors have the method to determine their location in order to calculate virtual force. Lastly, the method does not take into consideration distortion of sensing range and communication range of mobile sensors due to waves reflected by obstacles.
Based on the potential filed method [6] frequently used for movement of robot in mobile robotics, the three virtual forces such as F_{cover}, F_{degree}, and F_{obstacle} are used for movement of mobile sensors. In order to maximize coverage, mobile sensors are basically required to have a certain distance from one another to ensure that their sensing range is not overlapped with others. F_{cover} is the force with which mobile sensors push against one another to maximize the sensing range in the target area. F_{cover}(i, j) means the force that the sensor S_{
i
} takes from the neighboring sensor S_{
j
} during the unit time, which is expressed in Equation (1).
{F}_{cover}\left(i,j\right)=\frac{{C}_{cover}}{{\Delta}_{ij}^{2}}\cdot \frac{{x}_{i}{x}_{j}}{{\Delta}_{ij}}
(1)
In Equation (1), x_{
i
} and x_{
j
} represent the locations of sensors s_{
i
} and s_{
j
} while Δ_{
ij
} means the Euclidian distance of sensors s_{
i
} and s_{
j
}. And C_{cover} is the constant that means force of field.
In mobile sensor network, the mobile sensor that senses the information that requires observation in the target area uses the connection between mobile sensors in order to send the collected information to sink node. In this case, if a parent sensor on the path that is used to send information to one sink node loses connection for reasons such as failure or malfunction, a child sensor uses an alternative sensor that exists within its communication distance to form a new path. This local connectivity influences the entire connectivity [3]. In addition, sensors are required to maintain communication with a certain number or more of their neighboring sensors in order to deploy numerous mobile sensors in the target area with some sensors in the active state and others in the sleep state, which aims at increasing lifetime of the network [16].
F_{degree} is the force that is exerted by mobile sensors to keep the number of given neighboring sensors at the degree K. Figure 1 shows deployment of sensor nodes in case of K = 3. If the number of neighboring sensors is larger than K that should be kept, F_{degree} does not take place, and sensors become distant from each other due to F_{cover}. The sensors become more distant gradually to maximize coverage, and if the number of neighboring sensors is equal to a given degree K, F_{degree} takes place. As a result, a sensor draws its neighboring sensors to keep the number of neighboring sensors at the given degree K. F_{degree}(i, j) means the force that the sensor S_{
i
} takes from its neighboring sensor S_{
j
} during the unit time, which can be expressed in Equation (2).
{F}_{degree}\left(i,j\right)=\left\{\begin{array}{c}\frac{{C}_{degree}}{{\left({\Delta}_{ij}{R}_{c}\right)}^{2}}\cdot \frac{{x}_{i}{x}_{j}}{{\Delta}_{ij}}\hfill \\ 0\hfill \end{array}\begin{array}{c}\hfill \phantom{\rule{0.3em}{0ex}}\phantom{\rule{0.3em}{0ex}}\phantom{\rule{0.3em}{0ex}}\phantom{\rule{0.3em}{0ex}}if\phantom{\rule{0.3em}{0ex}}count\phantom{\rule{0.3em}{0ex}}of\phantom{\rule{0.3em}{0ex}}neighbor\phantom{\rule{0.3em}{0ex}}sensor=k\\ \hfill otherwise\end{array}\right.
(2)
where R_{c} means communication distance while C_{degree} is the constant that means force of field. Mobile sensors in MSNS are required to maximize coverage, maintain the given connectivity and avoid obstacles. To this effect, this article defines F_{obstacle}.
It is assumed that mobile sensors are equipped with 16 supersonic wave sensors (sender = 8, receiver = 8) in order to obtain F_{obstacle}. Figure 2 shows that supersonic wave sensors locate obstacles. It is assumed that if supersonic wave distance (R_{w}) is determined and a sensor detects obstacle within the distance of R_{w}, the sensor with sensing range of R_{w} is located in the point that is two times of the distance between the obstacle and the sensor. F_{obstacle} is calculated in the same way as F_{cover} in order to maximize the range of R_{w}. F_{obstacle}(i, k) takes place between the sensor node S_{
i
} and the obstacle o_{
k
} during the unit time, which can be expressed in Equation (3).
{F}_{obstacle}\left(i,j\right)=\frac{{C}_{obstacle}}{{\Delta}_{ik}^{2}}\cdot \frac{{x}_{i}{o}_{k}}{{\Delta}_{ik}}
(3)
where o_{
k
} is the location of obstacle while Δ _{
ik
} is the Euclidian distance between mobile sensor and obstacle, and C_{obstacle} is the constant that is caused by obstacle.
F_{cover}, F_{degree}, and F_{obstacle} are used to calculate the total virtual force F that mobile sensor S_{
i
} takes during the unit time, which is expressed in Equation (4).
\mathsf{\text{F}}={\sum}_{neighbors\phantom{\rule{2.77695pt}{0ex}}i}\left({F}_{cover}\left(i,j\right)+{F}_{degree}\left(i,k\right)\right)+{\sum}_{founded\phantom{\rule{2.77695pt}{0ex}}obstacles\phantom{\rule{2.77695pt}{0ex}}k}{F}_{obstacle}\left(i,k\right)
(4)
Mobile sensors continue to move at a constant speed if only F_{cover}, F_{degree}, and F_{obstacle} are considered. The virtual force F_{damper}, which needs to stop sensors from continuous movement, is defined as in Equation (5).
{F}_{damper}=\sigma \cdot {v}_{current}
(5)
where σ is damper constant while v_{current} is moving speed of the current sensor. F_{damper} is calculated based on the damper constant and the moving speed of the current node as shown above. For application of F_{cover}, F_{degree}, and F_{obstacle}, it is required to calculate C_{cover}, C_{degree}, and C_{obstacle} that are used for calculating each force. Mobile sensors push against each other to maximize coverage. And when the distance between them is 2R_{s}, the coverage becomes the highest. In other words, when the distance between the two sensors is 2R_{s}, F_{cover} does not take place between them, which is expressed in Equation (6). And C_{cover} can be calculated.
\u2225{F}_{cover}{F}_{damper}\u2225=0,\phantom{\rule{1em}{0ex}}where\phantom{\rule{0.3em}{0ex}}{\Delta}_{ij}=2{R}_{s}
(6)
In a similar way, when the distance between obstacle and sensor is R_{s}, F_{obstacle} does not take place to sensor, which is expressed in Equation (7). And C_{obstacle} can be calculated.
\u2225{F}_{obstacle}{F}_{damper}\u2225=0,\phantom{\rule{1em}{0ex}}where\phantom{\rule{0.3em}{0ex}}{\Delta}_{ij}={R}_{s}
(7)
Sensors move due to F_{cover}, F_{degree}, and F_{obstacle}. And there exists a moment when such forces reach the static equilibrium and the forces become zero (Equation 8).
\u2225{F}_{cover}+{F}_{degree}+{F}_{obstacle}{F}_{damper}\u2225=0,\phantom{\rule{1em}{0ex}}where,{\Delta}_{ij}=\mu \cdot {R}_{c}
(8)
{\alpha}_{next}=\frac{\left(F{F}_{damper}\right)}{m}
(9)
{v}_{next}={v}_{current}+{\alpha}_{next}\cdot t
(10)
{x}_{next}=x+{v}_{next}\cdot t+\frac{1}{2}\cdot {\alpha}_{next}\cdot {t}^{2}
(11)
In this case, μ is a safety factor, and the range of value is 0 < μ < 1. If the value becomes close to 1, sensors are readily disconnected. This equation is used to calculate C_{degree}.
The calculated force F that one node takes per unit time can be used to calculate acceleration of mobile sensor and to calculate speed by using the acceleration value. And lastly, it is possible to calculate the next location that sensor moves to (Equations 911). The coverage technique algorithm in MSNS is shown as follows.
Algorithm 1. MSNS coverage algorithm

1:
While (MNS is playing)

2:
get neighbor nodes of current node;

3:
for each neighbor node do

4:
get F_{cover} & F_{obstacle};

5:
end for

6:
if # of neighbor node < = K then

7:
for each neighbor node do

8:
get F_{degree};

9:
end for

10:
end if

11:
sum virtual force F;

12:
calculate acceleration;

13:
calculate velocity;

14:
calculate next location;

15:
if next location is contained in obstacle or outside of target area then

16:
next location sets current location;

17:
end if

18:
end while