ZigBee Network Construction Method Based on Metaheuristics Algorithms Using Angle Modulation Function

Wireless sensor networks have great potential to realize state observation in large scale areas. A ZigBee network is one of the world standards for short-range wireless sensor networks. Previous studies have proposed the application of Discrete binary Particle Swarm Optimization(DPSO), which is one of swarm intelligence algorithms, to sensor networks. However, DPSO has a problem that the performance deteriorates when the target problem becomes large scale. This paper proposes a new scheme that uses Angle Modulation based algorithms to detect the most effective allocation of routers in a ZigBee network. In the proposed scheme, an Angle Modulation function is applied to the search algorithm to generate a bit string for solving the binary problems. The performance of the proposed scheme is evaluated through simulation experiments.


Introduction
As a key network to facilitate ubiquitous information environments, there is growing expectation for a wireless sensor network.A ZigBee network is known as a wireless sensor network technology of an open global standard (1) and has a wide range of applications, such as environmental monitoring, object tracking, inter-vehicle communication which is a network service in intelligent transport systems, and precision agriculture.Types of ZigBee devices include ZigBee coordinator, ZigBee router, and ZigBee end device.ZigBee coordinators and ZigBee routers have a functions for relaying data, while ZigBee end devices do not.The topology of a ZigBee network includes a star network con-sisting of a single ZigBee coordinator and several ZigBee end devices, and a tree and mesh network consisting of a ZigBee coordinator, ZigBee routers, and several ZigBee end devices.This study focuses on tree and mesh networks.It is required that each ZigBee end device can directly send its own sensing data to one of the routers via wireless communication.Therefore, the effective allocation of ZigBee routers in an observation area should be achieved.This means the number of ZigBee routers and their locations should be optimized.This paper proposes a new scheme based on Angle Modulation(AM) based algorithms (2)(3)(4) to detect the effective allocation of routers in a ZigBee network.The AM based algorithms are promising methods for combination optimization problems.In the proposed scheme, an observation area is represented as a grid space, and search algorithms are used to determine whether to allocate a router on each intersection of the grid.In the simulation experiments, we demonstrated that our proposed scheme provided superior results in large scale area such as hundreds or thousands of dimensions compared with other related one.The rest of the paper is organized as follows.Section 2 outlines Discrete binary Particle Swarm Optimization(DPSO).In Section 3, we describe the proposed scheme based on AM based algorithms and construction method of ZigBee networks.In Section 4, the experimental results are reported in detail.Finally, this paper closes with conclusions and ideas for further study in Section 5. (5,6) DPSO is a method for combination optimization problems based on Particle Swarm Optimization(PSO) (7) , which belongs to the broad class of stochastic optimization ) of the i-th particle is updated by the following equations

Discrete binary PSO
where r 1 and r 2 are random numbers, uniformly distributed within the interval[0, 1].ω is a parameter called the inertial weight.c 1 and c 2 are positive constants, which are referred to as the cognitive and social parameters, respectively.In DPSO, each element(variable) of the position vector of each particle is transformed from the variable of continuous type of the binary state variable, i.e., 0 or 1, according to the following rule 0 else where sig(•) is the sigmoid function and ρ is a random number that is uniformly distributed within the interval[0, 1].The method of updating the velocity vector(v id k+1 ) is the same that in the PSO.The value of position vector(x id k+1 ) is determined by comparing the results of the sigmoid function with ρ.

Problems of DPSO
DPSO used in previous studies has two problems.Firstly, the performance of DPSO deteriorates when the target problem becomes large scale.Secondly, in PSO, which DPSO is based on, it is difficult to escape from the local solution.Therefore, the solution search stagnates.In addition, when the target problem becomes large scale, the number of local solutions also increases, which causes the stagnation of solution search even more.Hence, new algorithms for constructing large scale ZigBee network are needed.

Proposed Scheme
In the proposed scheme, the optimum number of ZigBee routers and locations is found using an AM based algorithms.In this section, we detail the proposed scheme.

AM based Algorithms
The AMbased algorithms is a normal search algorithms that use trigonometric functions as a bit string generator.As shown in Eq.( 6), the AM function consists of trigonometric functions and four variables.0 else  6) is positive, the bit value is 1, otherwise the bit value is 0. These processes generate a bit string of arbitrary length.

interval
The advantage of AM based algorithms compared with DPSO is that the search performance is less likely to deteriorate even when the target problem becomes large scale.For example, when the target problem consists of 100 dimensions, the DPSO must optimize the position vector by updating 100 elements, whereas the AM based algorithm only needs to optimize four variables regardless of the number of dimensions in the target problem.The AM based algorithms include AMPSO (2) applied AM function to PSO, AMDE (3) applied AM function to differential evolution method (8) , AMABC (4)

ZigBee network construction method
In this paper, an observation area is represented as a grid space, as shown in Fig. 2. In the proposed scheme, each point where the grid intersects is modeled as a candidate placement point for a ZigBee router.When ZigBee end devices have been randomly placed in an observation area, the proposed scheme determines whether a ZigBee router should be located at each intersection of the grid.In other words, when the ZigBee end devices are randomly located, we uses an AM based algorithm to search for the combination solution to the problem of locating the routers.The input-values to the AM function are allocated to each candidate placement point, as shown in Fig. 3.In this combination optimization problem, each ZigBee end device must be able to directly send its sensing data to one of the routers via wireless communication.In such constraint condition, the AM algorithm searches for the combination solution that minimize the number of ZigBee routers to be deployed.A low-cost large scale sensor network can be constructed by reducing the number of ZigBee routers using the proposed scheme.The proposed scheme includes the construction of tree and mesh networks, which are described in 3.2.1 and 3.2.2.

Construction method of tree networks
In this section, we describe the construction method of tree networks to send the data observed by ZigBee end devices to the ZigBee coordinator with a minimum number of ZigBee routers.The procedure for placing the ZigBee routers is as follows: Step1: Each ZigBee end device checks whether there is a ZigBee router within radio range and, if such a ZigBee router exists, the ZigBee end device is defined as a communicable ZigBee end device.Step2: Count the number of communicable ZigBee end devices.Step3: Each ZigBee router initiates flooding to determine whether it can communicate with the ZigBee coordinator.If it is possible, the ZigBee router is defined as a communicable ZigBee router.Step4: Count the number of communicable ZigBee routers.
Step5: The evaluation value is computed using the objective function f 1 (x).The objective function f 1 (x) is formulated aiming to satisfy the following two conditions: 1.All ZigBee end devices communicate directly with

Candidate Placement Points
ZigBee routers.2. All ZigBee routers communicate indirectly with a ZigBee coordinator via multi-hop communication.
The objective function f 1 (x) that minimizes the number of ZigBee routers is as follows: ( where E all is the total number of ZigBee end devices, E num is the number of ZigBee end devices that can communicate directly with at least one ZigBee router, R all is the total number of deployed ZigBee routers, R num is the number of ZigBee routers that can communicate indirectly with the ZigBee coordinator, and S is the base of the exponent(constant).When all distributed ZigBee end devices and all ZigBee routers placed by the bit string satisfy the above two conditions, the objective function f 1 (x) is equivalent to the number of placed ZigBee routers.DPSO and AM based algorithms are used to search for the solutions (bit string) that minimize the evaluation value of the objective function f 1 (x).

Construction method of mesh networks
We propose a construction method of mesh networks.Although the number of ZigBee routers deployed in a mesh network is larger than that in a tree network, the communications reliability is higher because there are multiple routes for the sending data.The procedure for placing the ZigBee routers is as follows: Step1: Each ZigBee end device checks whether there is a ZigBee router within radio range and, if such a ZigBee router exists, the ZigBee end device is defined as a communicable ZigBee end device.Step2: Count the number of communicable ZigBee end devices.Step3: Each ZigBee router initiates flooding to determine whether it can communicate with the ZigBee coordinator.If it is possible, the ZigBee router is defined as a communicable ZigBee router.Step4: If a ZigBee router is a communicable ZigBee router and more than the specified number of ZigBee routers exists within radio range(=Z), the ZigBee router is defined as a satisfying ZigBee router.
Step 5: Count the number of satisfying ZigBee routers.
Step 6: The evaluation value is computed by the objective function f 2 (x).
The objective function f 2 (x) is formulated aiming to satisfy the following two conditions: 1.All end devices communicate directly with routers.2. All routers are satisfying ZigBee routers.
The objective function f 2 (x) that minimizes the number of ZigBee routers is as follows: where R' num is the number of satisfying ZigBee routers.When all distributed ZigBee end devices and all ZigBee routers placed by the bit string satisfy the above two conditions, the objective function f 2 (x) is equivalent to the number of placed ZigBee routers.DPSO and AM based algorithms are used to search for solutions(bit string) that minimize the evaluation value of the objective function f 2 (x).

Simulation Experiments
A simulation experiment was conducted on a ZigBee network consisting of 300 end devices, and we evaluated the effectiveness of the proposed scheme compared with that of DPSO.

Conditions of simulation and parameter setting
A ZigBee networks composed of static sensor nodes, i.e., ZigBee end devices placed in a 500m×500m square observation area(grid 20 × 20 to 50 × 50) was assumed.A ZigBee coordinator was placed in advance at the upper left of the observation area, and several ZigBee routers were deployed using the proposed scheme for constructing a tree and mesh network.Table 1 shows the conditions of simulation, Table 2 shows common parameter settings on each algorithms, and Table 3 shows parameter settings on each algorithm.Some of the parameter values were based on results obtained from preliminary experiments, while others were adopted from those in Refs.(2-4).The compared algorithm includes DPSO, AMPSO, AMDE, and AMABC.The values of parameters(ω, c 1 , c 2 ) were considered proper default values and they are widely used in the relevant literature on the Discrete binary PSO.In addition, the constant S of the objective function f 1 (x) and f 2 (x) is set as S = 1.2 in the case of 2500 dimensions, and S = 2.0 in other cases.

Experimental results of tree networks
Based on the simulation environment described above and the parameter settings on each algorithm, the results of the best value(Best), average value(Average), and worst value(Worst) of the objective function value f 1 (x) obtained by 50 trials of the simulation experiment are shown in Table 4.In addition, as an example of the solution constructed by the proposed method, the best solution(Best) of 2500 dimensions obtained by AMDE is shown in Fig. 4.
Table 4 shows the number of deployed ZigBee routers.Fig. 4 shows an example of the tree network constructed using the proposed method.It should be noted that the proposed scheme based on AM based algorithms can find acceptable solutions in large scale areas such as a 50 × 50 grid space.There is little difference between DPSO and AM based algorithms in a 20 × 20 grid space.However, DPSO gets worse when the target problem becomes large scale.AMDE has the best value in the Best, Average and worst c-Table 4. Experimental results of the tree networks Fig. 4. A tree network constructed by the proposed method ases, which indicates that has superior performance compared to that of other algorithms used in the experiments.

Experimental results of mesh networks
Tables 5 and 6 show the best, average, and worst case objective function values for f 2 (x) obtained after 50 trials of the simulation experiment when more than the specified number of ZigBee routers existing within radio range(=Z) was 2 or 3, respetively.Figs. 5 and 6 show an optimum ZigBee router allocation obtained by AMDE when the number of intersections of the grid is 50 × 50.In Fig. 5, Z was set to two, and in Fig. 6, Z was set to three.
Tables 5 and 6 show the number of ZigBee routers deployed by AMDE.Figs. 5 and 6 show examples of the mesh network constructed by the proposed scheme.It should be noted that the proposed scheme can find acceptable solutions in large scale areas.As shown in Figs. 5 and 6, we confirmed that the proposed method can be used to construct a mesh network with multiple routes.

Simulation size 500m×500m
The number of ZigBee End Device 300

Radio wave range of ZigBee End Device 100m
Radio  Table 5. Experimental results of mesh networks(Z = 2) Table 6.Experimental results of mesh networks(Z = 3) Fig. 5.A mesh network constructed by the proposed scheme (Z = 2) Fig. 6.A mesh network constructed by the proposed scheme (Z = 3)

Conclusions
In this paper, we have proposed a new scheme based on AM based algorithms to optimize the allocation of ZigBee routers in ZigBee networks and have confirmed its effectiveness.The proposed scheme can provide the ZigBee router allocation that the number of ZigBee routers is minimized and all ZigBee end devices can be directly connect with one of ZigBee routers via wireless communication.In addition, we confirmed the superiority of AMDE by simulation experiments of hundreds or thousands of dimensions.Future work includes a detailed evaluation of the proposed scheme in large scale ZigBee networks and various ZigBee sensor applications.

Grids
where g(•) is the AM function, the coefficient a represents the horizontal shift of the function, b is the maximum frequency of the sin function, c is the maximum frequency of the cos function, and d represents vertical shift of the function.In the continuous-valued optimization algorithms, these four variables are used to obtain a bit string of arbitrary length.Fig. 1 shows the waveforms of the AM function at a = 0.6, b = 1.0, c = 1.0, and d = 0 and the bit string at interval = 1.0,where interval is the control value of the input value x(=interval × i) to the AM function.If the generated output value of g(•) from Eq.(

Fig. 1 .
Fig. 1.Bit string generation by the AM function applied AM function to Artificial Bee Colony algorithm.There are only a few examples where AM based algorithms have been applied to real problems.In addition, although these performance evaluation experiments were carried out in Refs.(2-4), the number of dimensions of the target problems is too low.Therefore, the difference with DPSO(binary PSO in Refs.(2-4)) is not clear.In this paper, we provide an example illustrating the application of this algorithm to ZigBee router placement problems, and clarify the effectiveness of the AM based algorithm for solving combination optimization problems consisting of hundreds or thousands of dimensions.

Fig. 2 .Fig. 3 .
Fig. 2. Grid division in an observation area and the position of each device In PSO, each particle constituting a swarm searches for a solution until a predetermined iteration is reached using the personal best solution(pbest id k ) and the global best solution shared in the swarm found during the search process(gbest k ).Each particle produces a new ve- DOI: 10.12792/icisip2017.051methods.

Table 1 .
Conditions of simulation

Table 2 .
Common parameter settings for all algorithm

Table 3 .
Parameter settings on each algorithm