In indoor environments, WiFi (RSS) based localization is sensitive to various indoor fading effects and noise during transmission, which are the main causes of localization errors that affect its accuracy. Keeping in view those fading effects, positioning systems based on a single technology are ineffective in performing accurate localization. For this reason, the trend is toward the use of hybrid positioning systems (combination of two or more wireless technologies) in indoor/outdoor localization scenarios for getting better position accuracy. This paper presents a hybrid technique to implement indoor localization that adopts fingerprinting approaches in both WiFi and Wireless Sensor Networks (WSNs). This model exploits machine learning, in particular Artificial Natural Network (ANN) techniques, for position calculation. The experimental results show that the proposed hybrid system improved the accuracy, reducing the average distance error to 1.05 m by using ANN. Applying Genetic Algorithm (GA) based optimization technique did not incur any further improvement to the accuracy. Compared to the performance of GA optimization, the nonoptimized ANN performed better in terms of accuracy, precision, stability, and computational time. The above results show that the proposed hybrid technique is promising for achieving better accuracy in real-world positioning applications.

1. Introduction

In indoor environments, WiFi (RSS) based localization is sensitive to various indoor fading effects and noise during actual data transmission, which are the main causes of localization errors that affect the accuracy [1]. Keeping in view those fading effects, positioning systems based on a single technology are ineffective in getting better accuracy and availability. For this reason, the trend is toward the use of hybrid position systems (combination of two or more wireless technologies) in indoor/outdoor localization scenarios for getting better position accuracy and availability by exploiting the different capabilities of the two technologies [2].

Hybrid localization has opened up new opportunities in healthcare systems, especially using sensor-based technology [3]. Hybrid indoor localization systems, when coupled with vital body signs monitoring devices, can provide improved information for the health and safety of chronic and elderly patients, at home as well as in care centers. For elderly aged people, it is of utmost importance to provide an affordable and a high-quality healthcare service to allow them to live independently. A multitasking monitoring system can be attached to persons in need to provide vital body signs reading (such as temperature, blood pressure, and oxygen saturation) and to provide them to the caretakers, together with the exact location of the person. This monitoring information, which can be precise to the order of 1 meter, can be very important in the case of emergencies when the searching time of a person in need can be significantly reduced.

Another potential application for wireless indoor localization can be found in the positioning detection of elderly patients affected by dementia. Various hospitals worldwide start to implement electronic bracelets, which detect the crossing of wandering patients through doors in the ward [4]. Our system can be applied to extend the crossing detection with a precise measurement of the location of each patient, to facilitate their tracking and retrieval and prevent their confinement in a small area inside the ward.

Hybrid localization can also be beneficial in the autonomous motion of large robotic trolleys and forklifts in huge storage warehouses. Nowadays, distribution companies make use of visual tracking of coloured paths on the floor and of specific markings in their warehouses. With wireless indoor localization, the motion can be based on hybrid localization. Our system can provide the added advantage of a larger motion freedom and improved positional awareness in case the fixed (or conventional) tracking is lost.

Considering the wide deployment of WiFi and the potential of WSNs in pervasive and context-aware applications, their combined utilization is attracting increasing attention in location-based services (LBSs). In the context of indoor positioning, data from both WiFi and WSN systems can be collected and exploited to refine and enhance the derivation of location information. In our work, we design and evaluate hybrid indoor position system, which combines WLAN Access Point and Wireless Sensor Network (WSN) technologies. The main purpose of using hybrid indoor localization approach is to get better accuracy with fast processing time to locate the user/object in the indoor environment, keeping in view the stability of our algorithm too.

The proposed hybrid technique implements indoor localization that adopts fingerprinting approaches in both WiFi and Wireless Sensor Networks (WSNs). This model exploits machine learning techniques for position calculation. In particular, artificial neural network (ANN) based on the gradient descent with momentum (ANN-GDM) back-propagation learning is used [5]. A dataset of location fingerprints in terms of RSS measurements is used to train an ANN and build a classification model. In essence, this model can map the collected RSS signal to the position coordinate (longitude and latitude) of the mobile node. Two outputs were obtained from the ANN: one corresponds to WLAN fingerprinting and the other one corresponds to WSN motes’ values.

Besides this, selection of using ANN approach is because of its robustness against noise and interference which is one of the major factors affecting the accuracy of indoor position system [6]. Two sets of experiments were conducted in a real indoor environment using the individual technologies of WiFi and WSN. Furthermore, Genetic Algorithm (GA) based optimization [7] is also implemented to check the accuracy improvement. In GA case, it did not incur any improvement to the accuracy in this hybrid formation. Compared to the performance of GA optimization, the nonoptimized ANN-GDM performed better in terms of accuracy, precision, stability, and computational time.

The study is organized into four parts, the first part of the study discusses the previous related works, the second part discusses ANN, third part discuss proposed hybrid localization system, the fourth part comprises the results and discussion, and the last part discusses conclusion and future work.

Several efforts have been done to develop location determination systems based on RSS signals from a single wireless technology. Techniques such as Bayesian classification and filtering, -Nearest Neighbors, GPS-like triangulation, Kalman Filtering, neural networks, and support vector machine (SVM) have been employed for solving this problem [810]. However, positioning systems based on a single technology are ineffective in getting better accuracy and availability. For this reason, several researchers have attempted to use hybrid positioning systems in indoor/outdoor localization scenarios towards getting better position accuracy and availability by exploiting the capabilities of different wireless technologies.

A survey of hybrid schemes for location estimation in Wireless Sensor Networks has been presented in detail in [8]. Zhang et al. [11] proposed an RF-based hybrid approach “COCKTAIL,” which combined WSNs and RFID technologies. The model described the relation between variations in RSS and the target, and it utilizes the geometric method as well as the dynamic cluster based probabilistic cover algorithm to solve device-free localization problem. WiFi positioning is combined with pedestrian dead reckoning (PDR) systems in [12]. A hybridization of these two technologies overcomes the fluctuation of RSS-based WiFi positioning due to the fluctuation of RSSs and the accumulation of error over time in PDR system.

Another research work is presented on hybrid indoor localization system based on pyroelectric infrared (PIR) sensors and RF model [13]. This hybrid model works in two stages. In the first stage, the zone of the target person is identified by PIR sensors. In stage two, RF fingerprints within the identified zone will be processed to estimate the final position of the person.

Li et al. [14] presented a hybrid approach for tracking moving objects utilizing fingerprinting and RSS-based techniques, which are fused using RFID tags/readers and particle filtering. A mean error of about 1.3 m accuracy was achieved. Another hybrid localization system by Bahillo et al. [15] implemented an RTT measurement method using 802.11 WLAN transceivers and the robust least-squared multilateration (RLSM) technique. A custom printed circuit board (PCB) was used for time measurements. Position accuracy of lower than 3 m was achieved. Moreover, Cheng et al. [16] proposed a hybrid approach using -medoids clustering algorithm to partition the set of fingerprints into several subsets and train a multicategory support vector machine (SVM) on each subset data. The authors concluded that this hybrid approach could be used to solve 3D WLAN indoor positioning.

A monitoring system based on PIR sensors and RF based on indoor human/robot localization is proposed in [17]. This technique fuses the location information obtained from RF propagation model and PIR. RF propagation model is used for the position of target estimation and it is assumed to be distributed in some probable region. The authors use Cramer-Rao bound (CRB) to determine the probable region.

Another research work presented an indoor positioning system that integrated fingerprinting and trilateration approaches [18]. An online phase of fingerprinting is first used, in which the nearest neighbors (NN) of the target node are calculated. Later on, the trilateration approach is used to estimate the coordinate without the use of radio propagation model. The distance between the calculated NN and detected access points (AP) is estimated using the Euclidian distance, providing the radii for the trilateration approach. The mean error of this proposed approach was only 1.99 and 1.40 meters for 3 and 4 anchor nodes, respectively.

3. Artificial Neural Network

Artificial neural networks (ANNs) method assumes that RSSs cannot be analyzed mathematically because they are too complex. ANNs use nonlinear discriminant functions for classification. Due to the powerful learning and adaptive capabilities, ANN technique has been employed in the positioning applications especially in fingerprinting technique [19]. A widely used ANN structure among modelers is the feed-forward back-propagation neural network. It is also considered one of the simplest and most general methods used for supervised training. Many different varieties of learning algorithms are available, including the popular back-propagation learning algorithm [3].

3.1. Implementation of Gradient Decent with Momentum Back Propagation

In this work, a two-layer artificial neural network with gradient decent with momentum back-propagation learning algorithm was used in the online phase, which is the actual estimation of indoor position. The gradient descent with momentum back-propagation algorithm is an iterative gradient method based algorithm developed to introduce synaptic correction (or weight adjustments) by minimizing the sum of square errors (the objective function). The momentum term helps average out the oscillation occurring during the training process and improving the speed of convergence [20]. The normalized RSS signal from two technologies which are used as training patterns are fed as input to the ANN together with location coordinates fingerprinting patterns that are used as target values during the training phase and form the required output of the ANN during the online phase. The ANN structure is shown in Figure 1. The proposed system was implemented in MATLAB.

We implement the position algorithm based on gradient decent with momentum back-propagation in the following steps:(i)Feed-forward computation.(ii)Back-propagation to the output layer and weight adjustment.(iii)Back-propagation to the hidden layer and weight adjustment.(iv)Global position error calculation.

3.1.1. Feed-Forward Computation

Hybrid training patterns are fed to the input layers of the neural network architecture, which are multiplied with the weighted sum of the input layers to th node in the hidden layer, which is given by

After the training step of neural networks, appropriate weights are obtained. A multilayer perceptron network with two hidden layers is used for the ANN-based positioning system. The input vector of signal strengths is multiplied by the trained input weight matrix and then added to input layer bias as shown in

The result is transmitted to the activation function (sigmoid) of the hidden layer neuron as in

3.1.2. Back-Propagation to the Output Layer and Weight Adjustment

The output of this transfer function is multiplied by the trained hidden layer weight matrix and then added to the hidden layer bias. The output of the system is the estimated location as shown in where is actual activation value of the output node, , = Expected target output for node , and = Derivative of the Sigmoid function.

The weight adjustment , between the output node and the node , is shown in where is learning rate and is momentum.

3.1.3. Back-Propagation to the Hidden Layer and Weight Adjustment

The error signal for hidden nodes is calculated by adjusting the weight, , between the input node, , and the node, , which are calculated as

3.1.4. Global Position Error Calculation

Target data requires normalization before feed to ANN. and coordinates are in meters with a range from −25 to 25 m. and ranges above refer to the extension of the space where the measurements were taken. Besides this, and must be normalizing between 0 and 1, according to this linear transformation:

As ,

As the input is the RSS signal from the four access points, the target training (testing) data is defined as in

Output is shown in

By inverting the formulas we get total positioning error as shown in (11) where mean extends over all training data and is the vector normalized. The important factor to achieving better results from ANN model is tuning its parameters. However, there is no definite and explicit method to select optimal parameters for the ANN. Trial and error method is commonly used to choose appropriate ANN parameters [21]. Many parameters are involved in tuning the ANN, including the number of hidden layers, the number of neurons in each hidden layer, initial weights to start the training, the transfer function, learning rate, and the momentum rate. The parameters of the back-propagation method, which give the least error, are given in Table 1.

3.2. Pseudo Code for Implementing Back-Propagation in Indoor

The proposed two-layer artificial neural network with gradient descent with momentum back-propagation pseudo code to calculate the position estimation is shown in Pseudocode 1. We first compute the feed-forward computation to compute all the activations and output value throughout the network. Then, back-propagation process starts between output layer and hidden layer with weight adjustments. At last global position error calculation is done.

) // initialize the ANN model
  (a) ; // initialize the learning rate
  (b) ; // initialize the momentum
  (c) for each weight   
      = rand (); // initialize the weight with small random number
() while (number of iterations < MAX and distance error > ) // training loop
// MAX and are constant threshold values
for each pattern in the training set
  for each layer in the ANN
    for each node in the layer
     (a) Calculate weighted sum of inputs to (Equation (1));
     (b) Add the bias value to the calculated sum (Equation (2));
     (c) Calculate the activation function for (Equation (3));
  Back propagate error through output layer (Equation (4));
  Back propagate error through hidden layer (Equation (5));
  for each weight   
    Update (Equation (6));
  Calculate distance error (Equation (11)); // Equation (12) for testing data
() Repeat Step () for the testing dataset

4. Proposed Hybrid Indoor Localization System

Numerous wireless communication techniques have been widely used in developing the indoor positioning system. These techniques include the wireless local area network (WLAN), radio frequency identification (RFID), bluetooth, and wireless sensor network (WSN). With the expansion of free WLAN services and popularity of smartphones, location-based services have drawn benefits for many applications. WLAN coverage can be found in common places such as homes, shopping mall, offices, or campuses. In addition, WLAN networks and devices have recently become cheaper. Hence, there is no need to employ any additional hardware and infrastructure for the purpose of indoor tracking. Using WiFi for indoor localization, two approaches are mainly used: a model-based approach and a fingerprinting-based approach [22].

The model-based method relies on the indoor path-loss model to estimate user location. Using a path-loss model, such as log-distance model, the relation between transmitting distance and RSSI could be established and the user location is computed using triangulation. On the other hand, location fingerprinting utilizes the received signal strength (RSS) from several Wireless Access Points (WAPs) or sensor nodes to map the signals features measured at some location into the coordinates of that location, creating a sort of signal identifier, or a fingerprint for each location and stored in a database called “radio map.” A pure model-based method, which does not rely on a radio map shows very low accuracy, due to the fading characteristics of the wireless channel. Walls, objects, and people moving around all distort the signal and the received signal strength deviates from the model [23]. Our work focuses on the fingerprinting-based model.

The proposed hybrid positioning system adopts fingerprint matching as the basic scheme of location determination. Location fingerprinting utilizes the received signal strength (RSS) from several Wireless Access Points (WAPs) or sensor nodes to map the signals features measured at some location into the coordinates of that location, creating a sort of signal identifier, or a fingerprint for each location. The fingerprinting method consists of two phases [24]. Phase 1 is the so-called calibration phase, offline phase, or training phase in which received signal features from all WAPs or sensor nodes at selected locations in a building are recorded in a database called “radio map” as a function of the user’s location information (latitude, longitude).

Phase 2 is the localization phase or online phase, in which the location of an object is determined by applying a pattern-matching algorithm (an ANN model in our case) to match the real-time (online) measurements of RSS with the closest location that can be found in the radio map database. This method does not require specialized hardware in either the mobile device or the receiving end nor is time synchronization necessary between the stations. The major drawback of the fingerprinting approach is the laborious and time-consuming calibration process. The fingerprinting working flow diagram is shown in Figure 2.

4.1. Experimental Setup

Initial data collection and analysis are the first step for location fingerprinting implementation. Experimental data of RSS samples from both IEEE 802.11b/g-based WAPs and ZigBee (XBee S2) sensor nodes were collected in the basement of the Faculty of Engineering and Built Environment, National University of Malaysia (UKM), Malaysia, to represent the indoor environment. Experimental area is surrounded by various laboratories, long corridors, lecture halls, offices, and meeting rooms. The layout of the experimental area is shown in Figure 3.

The measurement set consisted of a laptop computer Lenovo G580 with a core i5 processor, an onboard Atheros AR9285 Wireless Adaptor for the collection of RSS samples with Windows 7 operating system. An adjustable (height) moving table was used to carry the computer at several fixed predetermined heights. The measurement operation consisted of nearly uniformly distributed anchor points which are 1 meter apart in direction and 1.5 meters apart in direction. For hybrid RSS data collection, we marked a total of 96 anchor points from which we collect hybrid data for fingerprinting implementation. The study area is mapped with Cartesian coordinates system with the starting coordinate as .

4.2. Data Collection from WAPs

Four WAPs were used to collect the RSS data for location estimation. Those WAPs formed the existing WLAN communication infrastructure of the building near the experimental area. Positions of access points are not changed. The use of a real communication infrastructure enables the identification of practical limitations and difficulties and ensures a fair evaluation under realistic operating conditions. Open WiFi Scanner software “inSSIDer” [25] was used for collecting and analyzing RSSI values. The modification was made in the “inSSIIDer” to show the time stamps and to save the RSS data in text format with MAC address along with signal strength values. Data were collected during a working day. More than 100 RSS samples were collected at each anchor point (running “inSSIDer” software for about 2 min). Signal fluctuations were suppressed by computing the average RSS from 50 samples.

4.3. Data Collection from WSN Devices

The data measurement and transfer from WSN devices used two types of ZigBee nodes (XBee series 2) [26]; the sensor nodes (to transmit the RSS data) and a coordinator node (to receive RSS data). Four sensor nodes were placed at four corners in of the experimental area, mounted on a surface 1.5 m above the ground. A sensor node has four basic components: a magnetic sensor with a small permanent magnet, an ATmega 328P microcontroller as a Barebone, a ZigBee module (XBee series 2), and a power unit (LiPo rechargeable battery 3.7 v/1000 mAh) [27].

On the other hand, the coordinator, which collects RSS data from sensor nodes, is attached to the laptop which is 90 cm above ground in the default setting. The coordinator has four components: an Arduino Mega board based on the Mega 2560 microcontroller, a liquid crystal display (LCD), a ZigBee module (XBee series 2), and a power unit (LiPo rechargeable battery 7.4 v/1000 mAh). The X-CTU software from DIGI International [28] was used to configure the sensor node with the microcontroller and the coordinator node to establish a communication protocol between the two ZigBee nodes for transmitting and receiving of RSS data. In the first scenario, RSS training data is collected and stored in a database. In the second scenario, from the pool of training data, a small test portion data is randomly selected (in percentage) and given to the ANN for testing purposes. Two outputs were obtained from the ANN: one corresponds to WLAN fingerprinting and the other one corresponds to WSN motes’ values. The proposed hybrid architecture is shown in Figure 4.

5. Results and Discussion

To evaluate the performance of a positioning system, two parameters are used: accuracy and precision. The accuracy of the system is expressed in terms of the positioning error, which is obtained from a test dataset. The test data contain a collection of fingerprints associated with a location; the positioning algorithm processes each fingerprint and attempts to calculate the corresponding location. The obtained estimated location is compared with the real location by calculating the Euclidean distance between the two to obtain the deviation between the original and the estimated values. The average positioning error relies on the true and estimated location to calculate a value that correctly expresses the accuracy of the system. Usually the error between the two positions is expressed in meters or centimeters.

Figure 5 shows the location of the actual coordinates and estimated coordinates of the test data as calculated by the ANN-GDM algorithm. The test dataset was randomly selected from the training dataset. The resulting position error would be approximately 1.36 m with signals from WSN alone and 1.22 m with signals from WiFi only. However, when combining both signals in the hybrid setting, the position error does not exceed 1.05, outperforming the cases of signals from individual technologies. Figure 6 shows the actual and estimated coordinates of the training dataset during the offline phase, which stops training after reaching a prespecified value of error.

The accuracy of a learning algorithm can be improved by spending more time in tuning its performance, which is achieved by allowing a large number of training iterations in the case of ANN. This tradeoff between the accuracy and computational time is illustrated in Figure 7.

The second parameter of evaluation is defined as the success probability of position calculation with respect to predefined accuracy. To evaluate our system with respect to both parameters, we present the Cumulative Distribution Function (CDF) of the error (the difference between the real and calculated location coordinates). Figure 8 shows the CDF plot of the distance error for optimally trained ANN model. Running the positioning system using the test dataset, 50% of the time the resulting position error would be approximately 1.4 m with signals from WSN alone and 1.3 m with signals from WiFi only. However, when combining both signals in the hybrid setting, the position error does not exceed 1.2 m at a probability of 50%, outperforming the cases of signals from individual technologies.

In an attempt to further improve the system accuracy, we tried to use GA to optimize the ANN parameters and thereby enhance its performance. However, the nonoptimized ANN-GDM performance remained the best choice in terms of accuracy, precision, stability, and computational time. Applying GA-based optimization in this case did not incur the expected improvement, despite providing a similar decrease in the training error. Figure 9 shows the accuracy and computational time in both cases as a function of the number of allowed training epochs.

The stability of a learning algorithm is one of the important factors in the neural network [21]. It can be defined as how changes to the training data influence the result of the algorithm by running the algorithm with same parameters several times. To evaluate our algorithm to be stable we ran the network learning code with various training data several times with the parameters kept constant (hidden nodes, learning and momentum rates, and initial weights) and the accuracy reached roughly the same value, as shown in Figure 10. The value of the distance error as a function of the number of iterations for four selected training runs is shown in Figure 10. All profiles are roughly the same for all the performed runs.

6. Performance Comparison

The performance of the hybrid indoor localization approach is summarized and compared with several similar research works in Table 2. The considered studies adopted the fingerprinting approach for localization and are based on two-dimensional data acquisition. When the WiFi and WSN signals are considered separately, we achieved average distance errors of 1.22 m (using 228 anchor points) and 1.35 m (using 96 anchor points), respectively. As expected, using a larger number of anchor points, a better approximation can be obtained. These results show already a better accuracy with respect to other recently published works. Our proposed hybrid indoor WiFi-WSN positioning system outperforms all previous results, providing an accuracy of 1.05 m when using 96 anchor points.

7. Conclusion and Future Works

This paper presented a hybrid WiFi-WSN based indoor positioning system, based on the received signal strength in wireless networks, for the purpose of producing better localization accuracy. The joint use of heterogeneous technologies can overcome the limitations of each technology. We employed an ANN model using gradient descent with momentum learning algorithm for location prediction, trained and tested in a heterogeneous environment. We also conducted an extensive set of experiments in the real indoor scenario to evaluate the performance of our proposal. Results were derived with and without GA optimization technique in terms of accuracy, precision, stability, and computational time. In addition, the accuracy of the proposed hybrid indoor positioning system was compared with other well-known hybrid systems (probabilistic and deterministic), which have been used for indoor localization. The hybrid indoor positioning system presented in this paper had the advantage of better accuracy, low cost, and easy expansibility. We believe the system can be used to locate people and assets in several fields, including those of logistics, healthcare, and manufacturing. Our planned future work includes the extension of the current research into implementations of hybrid 3D indoor environments in a multifloor scenario. In addition, the proposed algorithm will be evaluated over a larger area to test the robustness of the algorithm.

Competing Interests

The authors declare that there is no conflict of interests regarding the publication of this paper.


The authors acknowledge support from Grant Ref. no. GUP-2014-005 and Universiti Kebangsaan Malaysia.