An Improved Particle Swarm Optimization-Based Feed-Forward Neural Network Combined with RFID Sensors to Indoor Localization

Abstract: Location-based services (LBS) have long been recognized as a significant component of the emerging information services. However, the localization cost and the performance of algorithm still need to be optimized. In the study, an improved particle swarm optimization algorithm based on a feed-forward neural network (IMPSO-FNN) combined with RFID sensors is proposed, which can achieve the best indoor positioning location and overcome the problems effectively. In IMPSO-FNN, an improved PSO algorithm (IMPSO) is developed to determine the optimal connecting weights and markedly optimize the network parameters and structural parameters for the FNN, and then an optimal location prediction model is established by the IMPSO-FNN. To avoid the interference of environmental noise for the experimental data, some preprocessing methods are used during the positioning process. The computational results for learning two continuous functions show that the proposed positioning algorithm has a faster convergence rate and higher generalization performance. The model evaluation results also verify that the proposed positioning method really is superior to other algorithms in terms of the learning ability, efficiency, and positioning accuracy.


Introduction
With the large-scale deployment of mobile computing devices and wireless networks, the application of location-based services (LBS) in an indoor environment has attracted more and more attention.The Global Positioning System (GPS)-based positioning technology is mature, with ever increasing accuracy, availability, and reliability [1].However, GPS can only be used in the outdoor environment where the satellite signals can be received.When it comes to indoor areas, due to the poor reception of satellite signals, GPS is unreliable.At the same time, GPS is expensive for deployment to automatically track individual material items [2].To solve this problem, a variety range of technologies were used for indoor location sensing, such as wireless local area network (WLAN) [3], ultra-wideband (UWB) [4], indoor GPS-based solutions [5], and infrared positioning systems [6].
Radio frequency identification (RFID) [7] technology may also be applied in the indoor positioning field.RFID is one of the recent wireless communication technologies, which has many advantages, such as contactless, high repeated availability, durability, and multi-readability.It is important that RFID data can be stored in tags and retrieved with readers that can communicate with these tags, using radio frequency waves [8].Ranky [9] proposed RFID as one of the most important ten technologies of this century.Li and Becerik-Gerber [10] presented a comparative study of eight indoor positioning sensing technologies taking into consideration the accuracy, power supply, affordability, wireless communication, line of sight, on-board data storage, context independence, and wide application in the industry.On the basis of that study, they suggested that RFID technology is the most suitable for indoor positioning sensing technology.Choi [11] stated that the passive UHF RFID-based localization overcomes the shortcomings of the traditional indoor positioning systems.Wang et al. [12,13] proposed a method based on measured phase to track mobile RFID tags with millimeter-level (mm-level) accuracy.
Therefore, RFID was used in this study, which has already been successfully implemented for indoor positioning system at a relatively lower cost.A back-propagation neural network (BP) can learn the relationship between the received signal strength indication (RSSI) values measured by the RFID reader and the location of the tags, and establish a positioning model.Unfortunately, the BP neural network uses the steepest descent method to determine the connecting weights, and is easy to be trapped in a local minimum.In addition, the structure and optimization network parameters of the BP network are difficult to be determined.Therefore, in view of the excellent performance of particle swarm optimization (PSO) in many fields [14], we first develop an improved PSO algorithm (IMPSO) to determine the connecting weights and optimize the network parameters and structural parameters for the feed-forward neural network (FNN), and then establish an optimal location prediction model based on the IMPSO-FNN to solve the problem of positioning accuracy.The simulation results show that the proposed IMPSO-FNN algorithm outperforms the compared algorithms in searching ability and learning ability of the particles, and in approximation ability.
The remaining parts of the paper are organized as follows: Section 2 reviews the important related works about the current research; Section 3 discusses the details of the proposed indoor positioning system; Section 4 demonstrates the feasibility of the proposed method using some benchmark functions and RFID positioning data, respectively; and, finally, the conclusions and a discussion of future research directions are presented in Section 5.

Literature Review
This section briefly presents the relevant research in the areas of RFID, particle swarm optimization, and applications of the proposed IMPSO-FNN method to an indoor positioning system.

Localization Techniques
With respect to measuring the distance between the sensor nodes, localization techniques can be divided into the range-free and range-based methods [15].In the range-free methods, they do not require specific ranging devices, and provide a direct and simple localization option for many wireless sensing location applications.However, due to its limited localization accuracy, the range-free localization techniques cannot provide satisfactory localization solutions for the RFID applications that require high-precision positioning.In the range-based methods, the time of arrival (TOA), angle of arrival (AOA), time difference-of arrival (TDOA), and received signal strength indicator (RSSI) [16] are some of the commonly used physical measures for the localization.TDOA and TOA measure the signal travel time between the signal source and the receiver.AOA is a category of signal measurement, which considers the direction of the signal propagation.Amongst these measures, a class of low-cost and easily-implemented range-based localization schemes is provided by the RSSI-based localization technique [17,18].Therefore, this study also adopts RSSI as the basic measure for localization.

Particle Swarm Optimization
The particle swarm optimization algorithm (PSO) has, at its origin, the simulation of the social behavior of organisms; for example, the movement of schools of fish, animal herds, and birds in a flock, which is a population-based stochastic optimization technique [19].In PSO, the basic element handled by the algorithm is the particle.A particle represents a possible solution to a given problem.The swarm represents a set of the possible solutions.Every iterative process, the position and velocity of the ith particle is updated according to Equations ( 1) and (2), respectively, until a fixed number of times is iterated or a predetermined minimum error is achieved.
where i = 1, 2, • • • , M, M is the number of particles in the population; x i and v i are the position and velocity of the ith particle, respectively; the t + 1 is the index of the current, new, iteration and t refers to the previous, old, iteration; w is a parameter that weighs the inertia of the particle; c 1 and c 2 are the parameters that weigh the cognitive and social constituents, respectively; rand 1 and rand 2 are random numbers which are uniformly distributed within the range [0, 1]; p g is the best position inferred by the swarm considering the experience of all the particles, and p i is the best position visited by the ith particle so far.
For Equations ( 1) and ( 2), in order to make the component part of x t i , v t i in the reasonable area, setting where the maximum value of the velocity is determined according to the length of the particle.Generally, if the scope of solution is [−x max , x max ], then v max = t * x max , 0.1 ≤ t ≤ 0.2. Figure 1 shows the particles constantly update their position and velocity to approach the target.handled by the algorithm is the particle.A particle represents a possible solution to a given problem.The swarm represents a set of the possible solutions.Every iterative process, the position and velocity of the th particle is updated according to Equations ( 1) and ( 2), respectively, until a fixed number of times is iterated or a predetermined minimum error is achieved.
where  = 1,2, ⋯ , ,  is the number of particles in the population;   and   are the position and velocity of the th particle, respectively; the  + 1 is the index of the current, new, iteration and  refers to the previous, old, iteration;  is a parameter that weighs the inertia of the particle;  1 and  2 are the parameters that weigh the cognitive and social constituents, respectively;  1 and  2 are random numbers which are uniformly distributed within the range [0,1];   is the best position inferred by the swarm considering the experience of all the particles, and   is the best position visited by the th particle so far.
For Equations ( 1) and ( 2), in order to make the component part of    ,    in the reasonable area, setting where the maximum value of the velocity is determined according to the length of the particle.Generally, if the scope of solution is [− max ,  max ], then  max =  *  max , 0.1 ≤  ≤ 0.2. Figure 1 shows the particles constantly update their position and velocity to approach the target.In addition, the velocity   of the th particle is updated based on three constituents: the social term, which is based on the global best solution found by the swarm; the cognition of the particle, which is based on the best solution obtained by the particle so far; and the inertia of the particle.
It is worth mentioning that some variants of the classical PSO are not discussed in this section.However, in order to improve the performance of the algorithm it has been developed, in particular, with regard to the avoidance of convergence to a local optimum [20,21].

Applications of Soft Computing Techniques to Indoor Positioning System
In order to overcome the shortcomings that are faced by traditional positioning methods (relying on empirical models and inability to establish the accurate signal loss model), machine learning methods, such as classification, have been applied to solve complex positioning problems.
Li and Chung [22] used an ant colony system (ACS) to find the connecting weights for a back-propagation (BP) neural network to improve its predictive performance.Lin et al. [23] also utilized simulated annealing to determine the training rate, momentum and number of hidden layer nodes for a BP neural network, which makes the BP neural network perform better.Ceravolo et al. [24] combined the genetic algorithm (GA) and the BP algorithm to predict and control the In addition, the velocity v i of the ith particle is updated based on three constituents: the social term, which is based on the global best solution found by the swarm; the cognition of the particle, which is based on the best solution obtained by the particle so far; and the inertia of the particle.
It is worth mentioning that some variants of the classical PSO are not discussed in this section.However, in order to improve the performance of the algorithm it has been developed, in particular, with regard to the avoidance of convergence to a local optimum [20,21].

Applications of Soft Computing Techniques to Indoor Positioning System
In order to overcome the shortcomings that are faced by traditional positioning methods (relying on empirical models and inability to establish the accurate signal loss model), machine learning methods, such as classification, have been applied to solve complex positioning problems.
Li and Chung [22] used an ant colony system (ACS) to find the connecting weights for a back-propagation (BP) neural network to improve its predictive performance.Lin et al. [23] also utilized simulated annealing to determine the training rate, momentum and number of hidden layer nodes for a BP neural network, which makes the BP neural network perform better.Ceravolo et al. [24] combined the genetic algorithm (GA) and the BP algorithm to predict and control the environmental temperature.The result showed that it can provide better performance compared to the conventional BP neural network.Kuo et al. [25] developed an intelligent supplier decision support system which employed a PSO-based fuzzy neural network to derive the rules for qualitative data and build an integration model by taking into account both qualitative and quantitative factors.Gong et al. [14] developed a novel PSO algorithm with the tentative reader elimination (TRE) operator to deal with the RFID network planning (RNP) problem.The TRE operator tentatively deletes readers during the search process of PSO and the mutation operator is embedded into the algorithm to improve the success rate of TRE.Wang et al. [26] proposed a PSO-BP-based positioning algorithm, which uses the PSO to optimize the BP network and the Gauss method to pre-process the experimental data.The results indicate that the proposed PSO-BP can provide better predictions than a traditional method.In addition, Tao et al. [27] proposed an improved particle swarm method (SA-PSO), which can restrict the position change of original and new particles in the iteration process and accelerate the convergence speed of the algorithm.The simulation results show that the addressed SA-PSO algorithm can solve a problem of multi-objective combination optimization.
Huang et al. [28] employed the fuzzy neural network architecture to adaptively tune the environmental parameters.Kehua et al. [29] proposed a GA-BP neural network-based indoor positioning algorithm to solve the problems caused by the complication and variation of indoor environments.Sá et al. [30] also presented genetic and backtracking search optimization algorithms to solve localization problems, in the case of a single hop.Lin et al. [31] proposed a combination of a functional-link based neural fuzzy network (FNFN) with immune particle swarm optimization (IPSO) to solve prediction and control problems.It is noteworthy to mention that the above research has achieved some good results, however, for a positioning model based on PSO-FNN, the relationship between the inertia weight and learning factor parameters was still neglected, and the improved algorithms for parameter were relatively few.

The Proposed IMPSO-FNN Method-Based Positioning System
The main objective of this study is to propose a RFID positioning system which employs an improved PSO algorithm to optimize the FNN.Compared to other hybrid optimization algorithms, it does not need to be combined with other algorithms, and does not increase the complexity of the original algorithm.In addition, the proposed algorithm can quickly learn the relationship between the RSSI signals and tag positions, and through the established optimal positioning model, the position of a new tag can be accurately estimated.
The proposed RFID-based positioning system is consisted of two parts.The first part is the establishment of an indoor positioning model.In the second part, the IMPSO-FNN algorithm is introduced in detail.

Location Prediction Model Based on PSO-FNN
For the RFID positioning system, in order to locate the position of tags, it is essential to build the mapping relationship between the RSSI values measured by the RFID reader and the location (Loca) of tags, which can be expressed as follows: n } is the RSSI measurement vector in the positioning system, which is measured by the reader every time, at a fixed point S; RSSI m j is the RSSI value of jth reference tag, which is measured by the corresponding mth reader at the fixed point S; P i is the location of the ith tag, P i = (x i , y i ).The given training data set is defined as the RFing k .
where Q is the number of reference tags.The goal of positioning is to find a mapping relationship f : R → R , making f (x i ) ≈ P i .Since the mapping relation belongs to the nonlinear mapping relation, and the FNN can be used to solve the problem of nonlinear relation, the PSO-FNN is selected in this study, and the problem of LBS can be equivalent to the optimization problem of the PSO-FNN.Defining Z : A → R n , min Z(t), t ∈ A, the mathematical model of the PSO-FNN can be expressed as follows: where y k (t) is the expected output matrix of training sample network; ŷk (t) is the actual output matrix of training sample network.M is the population size of the PSO.N is the number of training samples.
where w is nonlinear inertia weight parameters of the PSO; θ is the threshold between the input layer and the hidden layer; v is the connection weight between hidden layer and output layer; r is the threshold between the hidden layer and the output layer.
where f (x) is the activation function.
In order to evaluate the quality of each particle in the population, the fitness function is introduced.The quality of particles indicates the accuracy of neural network.In the process of network training, the smaller the mean square error of the sample, the better the corresponding particle's fitness will be.The fitness function f it(t) is defined in Equation ( 6): where the larger the fitness function value is, the better the solution will be; t represents a particle position considering a swarm of N particles.
In the PSO-FNN, P i is the position of the ith particle, which can be taken as a solution of the stated problem.(x i , y i ) ∈ P i represents the coordinates of the ith tag, and the original particle P old will be replaced by the new one P new with the probability of pro, according to Equation (7).
∆e can be expressed as: where M tem represent the parameter of temperature in the Metropolis rule.Through a certain number of iterations, the particle will reach the optimal fitness value and the function has an optimal solution, and the ultimate estimated location (x i , y i ) of the tag can be obtained.

The Learning Factor of Asynchronous Change Strategy
There are two learning factors, c 1 and c 2 , in the PSO algorithm, which determine the relative influence of the social and cognitive components.c 1 regulates the maximum step size of flight in the direction of its individual extreme value, and the c 2 regulates the maximum step size of flight in the direction of global extreme value.They reflect the experience of the individual and group, and, further, influence the motive trace and information exchange within the particle swarm.Thus, the right c 1 and c 2 can not only speed up the rate of convergence, but also cannot easily fall into local optimum.Moreover, it can reflect the optimization performance of the algorithm.
In this study, the learning factor of asynchronous change strategy (Equations ( 9) and ( 10)) is constructed, which makes the learning factor dynamically adjusted in the iterative process for the algorithm.As presented in Figure 2, in the initial stage of the search, c 1 takes a larger value, while c 2 takes a smaller value, which can make the particles learn more from their own optimal solutions and learn less from the social optimal solutions, so that the global search ability of the particle is strengthened.On the contrary, in the later stage of the search, c 1 takes a smaller value, while c 2 takes a larger value, which can make the particles learn more from the social optimal solutions and learn less from their own optimal solutions, and is conducive to quickly converge to the global optimal solution.In addition, in the reference literature [32][33][34], the relative nonlinear adjustment pairing experiments were carried out, and it was found that when the sum of c 1 and c 2 is less than 3, the algorithm performance is the best.Therefore, the learning factor of asynchronous change strategy is adopted in this study, as shown in Equations ( 9) and (10).It is helpful to maintain the diversity of population and improve convergence speed of the algorithm.
where the initial value of c 1 and c 2 are c 1ini and c 2ini , respectively; the final values are c 1 f in and c 2 f in , respectively; T max is the maximum number of iterations, and t is the current number of iterations. ) where the initial value of  1 and  2 are  1 and  2 , respectively; the final values are  1 and  2 , respectively;  max is the maximum number of iterations, and  is the current number of iterations.

The Nonlinear Inertia Weight Parameters 𝑤
The inertia weight  reflects the searching ability of particle.Controlling  can adjust the global and local optimization ability of the PSO algorithm.If the  value is larger, the global search ability is stronger, and the local search ability is weaker; conversely, the local search ability is enhanced, and the global search ability is weakened.However, the most improved PSO algorithms usually employ a linear decreasing strategy (LDW) [19] to change the inertia weight, and in the actual search process it is not effective to reflect the complex nonlinear behavior of the particle swarm.In addition, the direction of the heuristic search of the particle is not strong since some of the information cannot be fully utilized, which is provided by the objective function.In the early stage, the initial inertia weight can acquire the larger value of the global search, but the algorithm requires very high computing resources, and convergence speed is slow [35].Moreover, it is easy to be trapped into a local optimal solution in the late stage.Therefore, the inertia weight is also very important to the optimization performance of the algorithm.If we cannot find the suitable inertia weight in the early stage, it will be very difficult for the algorithm to converge to its best point.
In order to avoid the particles falling into a local optimum, we need to strengthen the global search ability of particles at the initial stage of iteration, and increase the corresponding global

The Nonlinear Inertia Weight Parameters w
The inertia weight w reflects the searching ability of particle.Controlling w can adjust the global and local optimization ability of the PSO algorithm.If the w value is larger, the global search ability is stronger, and the local search ability is weaker; conversely, the local search ability is enhanced, and the global search ability is weakened.However, the most improved PSO algorithms usually employ a linear decreasing strategy (LDW) [19] to change the inertia weight, and in the actual search process it is not effective to reflect the complex nonlinear behavior of the particle swarm.In addition, the direction of the heuristic search of the particle is not strong since some of the information cannot be fully utilized, which is provided by the objective function.In the early stage, the initial inertia weight can acquire the larger value of the global search, but the algorithm requires very high computing resources, and convergence speed is slow [35].Moreover, it is easy to be trapped into a local optimal solution in the late stage.Therefore, the inertia weight is also very important to the optimization performance of the algorithm.If we cannot find the suitable inertia weight in the early stage, it will be very difficult for the algorithm to converge to its best point.
In order to avoid the particles falling into a local optimum, we need to strengthen the global search ability of particles at the initial stage of iteration, and increase the corresponding global search time; once the approximate range of the optimal solution is determined, it is required to strengthen the local search ability of the particles, and increase the corresponding local search time to perform fine local search.Therefore, the nonlinear inertia weight w is defined in Equation (11): where w max is 0.9, w min is 0.4, k is a regulatory factor; when k is 6, the inertia weight w change curve is shown in Figure 3.
Information 2017, 8, 9 7 of 18 search time; once the approximate range of the optimal solution is determined, it is required to strengthen the local search ability of the particles, and increase the corresponding local search time to perform fine local search.Therefore, the nonlinear inertia weight  is defined in Equation (11): where  max is 0.9,  min is 0.4,  is a regulatory factor; when k is 6, the inertia weight  change curve is shown in Figure 3.It can be seen from Figure 3 that the inertia weight  maintains a larger value for a long time in the initial period of iteration, and maintains a smaller value for a long time in the later period of iteration; thus, the global search time at the beginning of iteration and the local search time at the later stage of iteration are increased, further, improving the global search ability at the initial stage of iteration, and the local search ability at the late stage of iteration, and provides better balance to the global and local search capabilities.Therefore, the improved  can improve the convergence rate of the algorithm and avoid falling into a local optimal solution.

Maximum Velocity
The maximum velocity  max determines the maximum moving distance of particles in an iterative process, regulating movement velocity of each particle, which can helpfully prevent search divergence.In a sense, setting the maximum velocity is the variable range of each dimension, and choosing the maximum problems requires a certain prior knowledge of the research problem.In this study, the maximum speed  max is set in the interval [−1, 1].The flowchart of the proposed IMPSO-ANN based indoor positioning system is shown in Figure 4 and the pseudo-code is shown in Algorithm 1.

Data Collection
At time   , all RFID tags with known positions located within the detection range of the reader antennas were activated, and the RFID signals between the tags and the antennas of reader were obtained.Defining   = {  ,   ,   | = 1,2, ⋯ , ;  = 1,2, ⋯ , ;   =  1 ,  2,⋯,   }, where   = (  ,   ) represents the coordinate of the th tag to be measured;  is the number of the antennas of reader; and  l = { , 1 ,  , 2 , ⋯ ,  ,  } is the acquired RSSI vector for tag  that is composed of different RSSI values at  time measured by the th antennas of reader.The acquired RFID signal   was stored in the original database, and the dataset can be expressed as  = (, | 1 ,  2 ,  3 ,  4 ), where  is 4. It can be seen from Figure 3 that the inertia weight w maintains a larger value for a long time in the initial period of iteration, and maintains a smaller value for a long time in the later period of iteration; thus, the global search time at the beginning of iteration and the local search time at the later stage of iteration are increased, further, improving the global search ability at the initial stage of iteration, and the local search ability at the late stage of iteration, and provides better balance to the global and local search capabilities.Therefore, the improved w can improve the convergence rate of the algorithm and avoid falling into a local optimal solution.

Maximum Velocity
The maximum velocity V max determines the maximum moving distance of particles in an iterative process, regulating movement velocity of each particle, which can helpfully prevent search divergence.In a sense, setting the maximum velocity is the variable range of each dimension, and choosing the maximum problems requires a certain prior knowledge of the research problem.In this study, the maximum speed V max is set in the interval [−1, 1].The flowchart of the proposed IMPSO-ANN based indoor positioning system is shown in Figure 4 and the pseudo-code is shown in Algorithm 1.

Data Collection
At time t v , all RFID tags with known positions located within the detection range of the reader antennas were activated, and the RFID signals between the tags and the antennas of reader were obtained.Defining , where L j = x j , y j represents the coordinate of the jth tag to be measured; m is the number of the antennas of reader; and F l = RSSI j,l 1 , RSSI j,l 2 , • • • , RSSI j,l k is the acquired RSSI vector for tag j that is composed of different RSSI values at k time measured by the lth antennas of reader.The acquired RFID signal DQ i was stored in the original database, and the dataset can be expressed as D = (x, y|F 1 , F 2 , F 3 , F 4 ), where m is 4.    %% Input: The RSSI values between the reference tags RSSI j,l and the antennas of reader; the coordinates of reference tags L j = x j , y j %% %% Output: The locations of the positioning tags L j,pos = x j,pos , y j,pos %% begin for 1 ≤ l ≤ N do %% l is each particle ]; %% V l and X l are the velocity and position of lth particle respectively if f (X l ) > f (pBest l ) then %% pBest l is the best position of lth particle pBest l = X l ; end if end for gBest = opti{pBest l |1 ≤ l ≤ N} %% obtain the optimum solution while not stop

RFID Data Preprocessing
This section consists of the data filtering and the data normalization.

• Step1: Data filtering
The signal measurement is susceptible to environmental effects (such as people walking) that cause the RSSI measurements collected to be embedded with noise.The Gaussian filter is used to process the RSSI values, because the RSSI value of the repeated measurement in a fixed position by the reader obeys the Gauss distribution (Equation ( 12)).
where σ 2 is the variance, and ϕ is the expected value.
The original Gaussian filter is improved to adapt the filtering of RSSI values, and the standard deviation via σ is estimated as in Equation ( 13): where ϕ is the estimation of expected value of RSSI, according to Equation ( 14): where n is the number of all RSSI; RSSI jl is the jth RSSI for jth tag received by the lth antenna of reader.
According to the 3σprinciple of Gaussian distribution, the small probability event of RSSI j,l − ϕ > 3σ is excluded, and the data of RSSI j,l − ϕ < 3σ is chosen as effective experimental data.The effective RSSI value from the jth tag received by the lth antenna of reader is RSSI j,l , RSSI j,l ⊆ RSSI j,l (j = 1, 2, • • • , n; l = 1, 2, • • • , m).

• Step2: Data normalization
In order to ensure all of the RSSI vectors have the same contribution for training and testing, all RSSI values from the jth tag should be normalized in [0, 1].The RSSI value of the jth tag received by the lth antenna of reader was normalized according to the following formula: where the preprocessed RFID signal RSSI j,l was stored in the new database, and the dataset can be The RFID data D will be input to the proposed positioning system for training and testing.

Performance Analysis
Based on the IMPSO-FNN algorithm presented in Section 3, this section will apply two benchmark functions to evaluate the proposed algorithm first.MATLAB (2013a Version, MathWorks Corporation, Natick, MA, USA) is used to design a computer program that simulates different algorithms.Two non-linear functions, the Ackley function and the Rastrigrin function, are selected, and the dimension of the data is m, as shown in Table 1.Training results are used to demonstrate the fitness value of test data.In order to determine the algorithm performance of the IMPSO-FNN, the performance is compared with a genetic algorithm-based FNN (GA-FNN), the linearly decreasing weight PSO algorithm-based FNN (LDWPSO-FNN) [19] and the random inertia weight PSO algorithm-based FNN (RWPSO-FNN) [36].The detailed parameters of the algorithm are presented in Table 1.

Performance Test
In this study, the 200 groups of four-, six-, and eight-dimensional data were randomly selected from the two experimental functions, respectively.In addition, the 150 group data were randomly selected from the 200 group data to train the neural network, and the remaining 50 group data as the network prediction samples.Figures 5 and 6 show the optimal fitness value curves of the four, six, and eight dimensions for four different algorithms in the training process of neural network.
In order to evaluate the performance of the proposed positioning algorithm, some performance evaluation criteria such as the average error (AE) and average relative errors (ARE) are described as follows: where n is the number of samples; y i is the actual output value, and y i is the expected output value.

Case 1: Ackley function
The related information about Ackley function is as follows: (1) Definition: (2) Search domain: Number of local minima: Some (4) The global minima: From Figure 5, we can see that, for the fitness curve of the Ackley function, the fitness value of the IMPSO-FNN is the largest, and the mean square error is the smallest in the process of training the neural network, which shows that the IMPSO-FNN algorithm has high training accuracy and good learning ability.As seen in Figure 5b, for the fitness change curve of the training sample of the IMPSO-FNN, in the first 10 iterations, the fitness curve changes faster; in iterations 10-60, the fitness curve changes slowly, while the fitness curve changes very quickly in iterations 60-73, and after 73 iterations, the fitness curve trends the optimal value.However, in the fitness curve of the training sample of the other three algorithms (LDWPSO-FNN, RWPSO-FNN, and GA-FNN) a fitness stagnation phenomenon appears in many places, which indicates that the algorithm falls into a local solution in the evolutionary process of the neural network.(1) Definition:

Dimension Algorithm GA-FNN LDWPSO-FNN RWPSO-FNN IMPSO-FNN
(2) Search domain: x i ∈ [−5.12, 5.12], i = 1, 2, • • • , m; m = 4, 6, 8 (3) Number of local minima: Some (4) The global minima: Case 2: Rastrigrin function The related information about the Rastrigrin function is as follows: (1) Definition: Similar to the analysis with Case 1, in the fitness curves of the GA-FNN, LDWPSO-FNN, and RWPSO-FNN algorithms, a fitness stagnation phenomenon also appears in some places in the evolution process, which indicates that the algorithms easily fall into a local optimal and cannot achieve the optimal location information.However, in the case of the same number of iterations, the fitness value of the IMPSO-FNN algorithm is the largest for different training data, which shows that the output value of the network is closest to the actual value, and the training error is the minimum.It also indicates that it can be used for indoor positioning to achieve a good positioning result.
Table 3 lists the training error of neural network for the Rastrigrin function.The training results are similar to the results of Table 2.In addition, we found that the performance of the Similar to the analysis with Case 1, in the fitness curves of the GA-FNN, LDWPSO-FNN, and RWPSO-FNN algorithms, a fitness stagnation phenomenon also appears in some places in the evolution process, which indicates that the algorithms easily fall into a local optimal and cannot achieve the optimal location information.However, in the case of the same number of iterations, the fitness value of the IMPSO-FNN algorithm is the largest for different training data, which shows that the output value of the network is closest to the actual value, and the training error is the minimum.It also indicates that it can be used for indoor positioning to achieve a good positioning result.
Table 3 lists the training error of neural network for the Rastrigrin function.The training results are similar to the results of Table 2.In addition, we found that the performance of the algorithm is increased with a decrease in the dimension of the test function, and the performance of the IMPSO-FNN algorithm is significantly better than the other four algorithms.

Case Study
This section will demonstrate the way to apply the proposed IMPSO-FNN algorithm to the RFID-based positioning system.The RFID system includes the UHF RFID reader (LJYZN-401), UHF antennas (Laird-S8658WPL) with a main working frequency of 865-956 MHz, and passive UHF RFID tags (IMPINJ-H47), and are shown in Figure 7a.In our experiments, all of the passive tags in the experimental area can be activated [11,37], and the reader can obtain their RSSI values because of the effective radio frequency coverage of the reader antennas can be as long as 10 m, as shown in Figure 7b.The measured RSSI values by the reader were not inversely proportional to distance due to the influence of various factors in the environment.Therefore, this study repeatedly tested the signal value and had obtained its feature through the network training.For the purpose of comparison, three other algorithms, including the GA-FNN, LDWPSO-FNN, and RWPSO-FNN, will also be tested.algorithm is increased with a decrease in the dimension of the test function, and the performance of the IMPSO-FNN algorithm is significantly better than the other four algorithms.

Case Study
This section will demonstrate the way to apply the proposed IMPSO-FNN algorithm to the RFID-based positioning system.The RFID system includes the UHF RFID reader (LJYZN-401), UHF antennas (Laird-S8658WPL) with a main working frequency of 865-956 MHz, and passive UHF RFID tags (IMPINJ-H47), and are shown in Figure 7a.In our experiments, all of the passive tags in the experimental area can be activated [11,37], and the reader can obtain their RSSI values because of the effective radio frequency coverage of the reader antennas can be as long as 10 m, as shown in Figure 7b.
The measured RSSI values by the reader were not inversely proportional to distance due to the influence of various factors in the environment.Therefore, this study repeatedly tested the signal value and had obtained its feature through the network training.For the purpose of comparison, three other algorithms, including the GA-FNN, LDWPSO-FNN, and RWPSO-FNN, will also be tested.

Experimental Scenario
Figure 7 shows the simulated experimental environment, and the size of the environment was approximately 10 m × 6 m with 45 reference tags and four UHF RFID antennas.The distance between adjacent markers is about 1.2 m.In addition, in order to increase the measurement

Experimental Scenario
Figure 7 shows the simulated experimental environment, and the size of the environment was approximately 10 m × 6 m with 45 reference tags and four UHF RFID antennas.The distance between adjacent markers is about 1.2 m.In addition, in order to increase the measurement accuracy of RSSI values, a wired RFID receiver was connected to four receiving antenna, and the four antennas of the reader was placed at the four positions, which are Antenna 1 (0.3, 0.2), Antenna 2 (0.3, 5.4), Antenna 3 (10.5, 5.4), and Antenna 4 (10.5, 0.2).The RSSI values collected from the antennas are regarded as input values of the IMPSO-FNN network.
Based on the experiments presented in the Section 4, compared with other algorithms, the convergence rate of the IMPSO-FNN algorithm is the fastest and the generalization ability is the best.In addition, we found that the dimension of training sample affects the performance of the algorithm.In this study, the original data is reduced dimension and normalized processing.The optimal fitness value curves of four and six-dimensions for the training sample in the training process of the neural network are shown in Figure 8.The error results of training sample for RFID data is presented in Table 4.

Performance Results
The mean absolute error (MAE) and root mean square error (RMSE) are used to make a better analysis for the experimental results, according to the following equations: where 2 , (  ,   ), (  ′ ,   ′ ) represents the real location coordinates and

Performance Results
The mean absolute error (MAE) and root mean square error (RMSE) are used to make a better analysis for the experimental results, according to the following equations: where Err j = x j − x j 2 + y j − y j 2 , x j , y j , x j , y j represents the real location coordinates and estimated location coordinates of the jth tag, respectively.Figure 8 shows that applying the IMPSO algorithm to train the FNN can have the maximum fitness value, while the GA-FNN algorithm is the worst.The IMPSO-FNN algorithm has a faster convergence rate, and can be better used for indoor positioning.In addition, for the LDWPSO-FNN and RWPSO-FNN algorithms, in the fitness curves of the training sample a fitness stagnation phenomenon appears in many places, which indicates that they fall into the local solution in the process of network evolution.That is to say, the acquired position data in the process of localization is not the optimal.
Based on the results listed in Table 4, the performance of proposed IMPSO-FNN-based positioning algorithm can achieve better performance compared to other algorithms, and not only are ARE and MAE the smallest, but the RMSE is also the least, which reveals that IMPSO-FNN has good extensiveness and robustness, and contributes to improving the accuracy of indoor positioning.Additionally, when the dimension of RFID data is four, the performance of the algorithm is obviously superior to the performance of the six-dimensional RFID data.Therefore, the performance of the algorithm can be improved by further reducing the dimension of the training RFID data for the positioning system.

Comparison with Other Algorithms
This experiment aims to further determine the proposed algorithm can achieve a higher positioning accuracy.The parameter selection for all localization algorithms is presented in Table 1, Figure 8 shows a comparison of the position-prediction performance of the five methods, and the positioning error is shown in Table 5.For the Figure 9a, with a positioning error tolerance of 1.00 m, the average positioning accuracy probability of IMPSO-FNN, LDWPSO-FNN, RWPSO-FNN, LANDMARC, and GA-FNN are 72.36%,64.1%, 62.2%, 48.97%, and 59.3%, respectively.The IMPSO-FNN enhances the cumulative percentile positioning accuracy by 12.9% over LDWPSO-FNN, 16.3% over RWPSO-FNN, 47.8% over LANDMARC, and 22.0% over GA-FNN.When the error tolerance is 1.50 m, the cumulative percentile of positioning accuracy for the IMPSO-FNN is 100%.Generally, the optimizing machine learning-based positioning algorithms have the ability to obtain higher localization accuracy than LANDMARC.We can come to a conclusion that the IMPSO-FNN algorithm performs best among the three machine-learning algorithms in terms of training and positioning accuracy.Additionally, as seen in Figure 9b, with a positioning error tolerance of 1.00 m, the average positioning accuracy probability of IMPSO-FNN, LDWPSO-FNN, RWPSO-FNN, LANDMARC, and GA-FNN are 67.85%,60.5%, 56.0%, 48.01%, and 54.4%, respectively.Compared with Figure 9a, the cumulative percentile positioning accuracy of IMPSO-FNN, LDWPSO-FNN, RWPSO-FNN, LANDMARC, and GA-FNN are reduced by 4.5%, 3.6%, 6.2%, 1.0%, and 4.9%, respectively.This indicates that the dimension of the original data can be reduced to a certain extent, which can further improve the indoor positioning accuracy.The experimental results also demonstrate that the proposed algorithm achieves the highest positioning accuracy among all five algorithms due to its relatively fast convergence rate.

Analysis and Discussion
We designed an RFID indoor positioning system based on the IMPSO-FNN.From the experimental results, we found that the traditional positioning algorithms (such as LANDMARC) cannot solve this problem accurately and efficiently for complex environments.Machine learning provides a different perspective to solve the problem.In Table 5, the IMPSO-FNN can obtain higher localization accuracies than other positioning methods.Further, the IMPSO-FNN-based positioning algorithm can better overcome the problem of signal fluctuation, which is caused by environment layout and fluctuations of signal strength.On the other hand, the LANDMARC methods require extensive searching/ranking of reference tags and, thus, the efficiency is low.Machine learning algorithms can run faster than conventional positioning algorithms when solving the positioning problem.Further, the IMPSO-FNN performs best among the four machine-learning algorithms in terms of training and testing efficiency, and is capable of improving the indoor positioning accuracy and efficiency due to its better generalization ability and faster convergence.

Conclusions and Future Work
In this study, we comprehensively take into account the localization cost and the performance of the positioning algorithm, and an improved particle swarm optimization-based feed-forward neural network (IMPSO-FNN) algorithm combined with RFID sensors has been presented, which introduces the improved particle swarm optimization algorithm, and can achieve the optimal connecting weights and network parameters and structural parameters for the FNN in the iteration process and accelerate the convergence speed of the algorithm.Furthermore, the proposed IMPSO-FNN algorithm can quickly learn the relationship between the RSSI values and the position of tags, and establish an optimal indoor localization model.The experimental results demonstrate that the proposed positioning system effectively achieves the highest positioning accuracy and efficiency among all five methods.However, in the experiments, we found that the specific theoretical guidance information about improving the inertia weight and learning factors of the PSO are less; therefore, other soft computing techniques, such as artificial fish swarm optimization and artificial bee colony optimization, might be integrated into the heuristics to provide better estimation.In addition, future study will also analyze the relation between the positioning accuracy and the dimension of RFID data for the positioning system.
Acknowledgments: Support of our work by the National Natural Science Foundation of China (No. 61272097),

Analysis and Discussion
We designed an RFID indoor positioning system based on the IMPSO-FNN.From the experimental results, we found that the traditional positioning algorithms (such as LANDMARC) cannot solve this problem accurately and efficiently for complex environments.Machine learning provides a different perspective to solve the problem.In Table 5, the IMPSO-FNN can obtain higher localization accuracies than other positioning methods.Further, the IMPSO-FNN-based positioning algorithm can better overcome the problem of signal fluctuation, which is caused by environment layout and fluctuations of signal strength.On the other hand, the LANDMARC methods require extensive searching/ranking of reference tags and, thus, the efficiency is low.Machine learning algorithms can run faster than conventional positioning algorithms when solving the positioning problem.Further, the IMPSO-FNN performs best among the four machine-learning algorithms in terms of training and testing efficiency, and is capable of improving the indoor positioning accuracy and efficiency due to its better generalization ability and faster convergence.

Conclusions and Future Work
In this study, we comprehensively take into account the localization cost and the performance of the positioning algorithm, and an improved particle swarm optimization-based feed-forward neural network (IMPSO-FNN) algorithm combined with RFID sensors has been presented, which introduces the improved particle swarm optimization algorithm, and can achieve the optimal connecting weights and network parameters and structural parameters for the FNN in the iteration process and accelerate the convergence speed of the algorithm.Furthermore, the proposed IMPSO-FNN algorithm can quickly learn the relationship between the RSSI values and the position of tags, and establish an optimal indoor localization model.The experimental results demonstrate that the proposed positioning system effectively achieves the highest positioning accuracy and efficiency among all five methods.However, in the experiments, we found that the specific theoretical guidance information about improving the inertia weight and learning factors of the PSO are less; therefore, other soft computing techniques, such as artificial fish swarm optimization and artificial bee colony optimization, might be integrated into the heuristics to provide better estimation.In addition, future study will also analyze the relation between the positioning accuracy and the dimension of RFID data for the positioning system.

Figure 1 .
Figure 1.The process of the position and velocity update of particles.

Figure 1 .
Figure 1.The process of the position and velocity update of particles.

Figure 2 .
Figure 2. The change curve of the learning factor.

Figure 2 .
Figure 2. The change curve of the learning factor.

Figure 3 .
Figure 3.The change curve of inertia weight.

Figure 3 .
Figure 3.The change curve of inertia weight.

Figure 4 .Algorithm 1 .
Figure 4.The framework of the PSO-ANN-based indoor positioning system.

Figure 4 .Algorithm 1 .
Figure 4.The framework of the PSO-ANN-based indoor positioning system.

Figure 5 .
Figure 5.The fitness curve of different dimensions (m) for the four compared algorithms.(a) Ackley function; (b) optimization curve for the Ackley function, m = 6; (c) optimization curve for the Ackley function, m = 8; and (d) optimization curve for the Ackley function, m = 10.Table 2 lists the training error of the neural network for the Ackley function, which shows that the AE and ARE of the IMPSO-FNN algorithm are the smallest in the training process, and the algorithm has high training accuracy and good learning ability.Table2.The error results of training data for the Ackley function.

Figure 5 .
Figure 5.The fitness curve of different dimensions (m) for the four compared algorithms.(a) Ackley function; (b) optimization curve for the Ackley function, m = 6; (c) optimization curve for the Ackley function, m = 8; and (d) optimization curve for the Ackley function, m = 10.Table 2 lists the training error of the neural network for the Ackley function, which shows that the AE and ARE of the IMPSO-FNN algorithm are the smallest in the training process, and the algorithm has high training accuracy and good learning ability.Case 2: Rastrigrin function The related information about the Rastrigrin function is as follows:

Figure 6 .
Figure 6.The fitness curve of different dimensions (m) for the four compared algorithms.(a) Rastrigrin function; (b) optimization curve for the Rastrigrin function, m = 6; (c) optimization curve for the Rastrigrin function, m = 8; and (d) optimization curve for the Rastrigrin function, m = 10.

Figure 7 .
Figure 7.The simulated experimental environment.(a) The testing environment; (b) UHF RFID antenna coverage; (c) the testing RSSI data; and (d) tags and antennas layout.

Figure 7 .
Figure 7.The simulated experimental environment.(a) The testing environment; (b) UHF RFID antenna coverage; (c) the testing RSSI data; and (d) tags and antennas layout.

Figure 8 .
Figure 8.The fitness curve of different dimensions (m) for the four compared algorithms.(a) The optimization curve for the RFID data, m = 4; and (b) the optimization curve for RFID data, m = 6.

Figure 8 .
Figure 8.The fitness curve of different dimensions (m) for the four compared algorithms.(a) The optimization curve for the RFID data, m = 4; and (b) the optimization curve for RFID data, m = 6.

Table 1 .
The parameters setting for different algorithms.

Table 2 .
The error results of training data for the Ackley function.

Table 3 .
The error results of training data for the Rastrigrin function.

Table 3 .
The error results of training data for the Rastrigrin function.

Table 4 .
The error results of training data for RFID data.

Table 4 .
The error results of training data for RFID data.

Table 5 .
Error of location results for different methods (m).