Abstract

In recent years, how to improve the performance of smart factories and reduce the cost of operation has been the focus of industry attention. This study proposes a new type of location-based service (LBS) to improve the accuracy of location information delivered by self-propelled robots. Traditional localization algorithms based on signal strength cannot produce accurate localization results because of the multipath effect. This study proposes a localization algorithm that combines the Kalman filter (KF) and the adaptive-network-based fuzzy inference system (ANFIS). Specifically, the KF was adopted to eliminate noise during the signal transmission process. Through the learning of the ANFIS, the environment parameter suitable for the target was generated, to overcome the deficiency of traditional localization algorithms that cannot obtain real signal strength. In this study, an experiment was conducted in a real environment to compare the proposed localization algorithm with other commonly used algorithms. The experimental results show that the proposed localization algorithm produces minimal errors and stable localization results.

1. Introduction

Through the development of artificial intelligence, the maintenance and repair of machines in smart factories are different from the old way. There are already smart factories that use mechanical vibration and noise detection or environmental data to improve the reliability of equipment or knives [14]. However, installing sensors for detection in all the equipment would increase the cost significantly. This time, self-propelled robots can be used for inspection, effectively reducing the related costs. Of course, location-based service technology is very important at this point because it can effectively provide accurate equipment information. Location-based services (LBSs) have been widely applied in warehouse management, transportation, personnel tracking, and medical care [5, 6].

Currently, the commonly used location-based systems can be divided into indoor and outdoor systems [7]. In particular, although the global positioning system (GPS) is the most frequently used outdoor location-based system, it cannot be effectively used in an indoor environment because of the shading effect of buildings. Therefore, other techniques, such as radio frequency identification, wireless local area network, Bluetooth, and ZigBee, are required for indoor localization [8]. All of these techniques involve transmitting radio wave signals to establish a wireless sensor network for positioning. However, during the transmission process, signals may be influenced by the multipath effect; therefore, information received by the reader may be distorted, influencing the accuracy and stability of localization [911].

The interference in signal transmission is not entirely caused by obstacles; signal transmission may be interfered with by signals emitted from other electronic devices [12]. In addition, various receivers may experience different levels of interference because of varying transmission directions, despite using the same signal transmitter. Therefore, the result of positioning is influenced by obstacles in an environment, signals from other electronic devices, and the direction of signal transmission [13].

To solve the problems produced by varying transmission directions and the multipath effect caused by obstacles, this study proposed a localization algorithm by combining the Kalman filter (KF) to enhance the accuracy and stability of localization. The proposed algorithm was subsequently compared with existing localization algorithms.

This study has proposed an adaptive tracking system. Section 2 discusses related literature, the concepts of the location algorithm, Kalman filter, and adaptive-network-based fuzzy inference system (ANFIS). Section 3 illustrates the proposed algorithm for the smart factory. Section 4 details the demonstration of the experimental operations and examines the algorithm in the smart factory environment. Finally, Section 5 includes the conclusion and highlights follow-up research.

Among the propagation path loss models, the most widely used models are the free-space propagation, log-distance path loss, and Hata models. In the free-space propagation model, the Friis free-space model is typically adopted. When the distance between a transmitter and receiver is given, the model can be used to calculate the average received power of the receiver as follows [14]:where Pt represents the transmission power of the transmitter; λ is the wavelength of the electromagnetic wave; L denotes the system dissipation coefficient; and Gt and Gr are the antenna gains for the transmitter and receiver, respectively. The calculation of antenna gains is related to the effective aperture (Ae):

The effective aperture is related to the antenna design. Therefore, when the transmitter and receiver use different antennas, despite using the same transmission power, the power received by the receiver may differ.

In equation (1), when the distance between the transmitter and receiver is 0 (d = 0), the received power cannot be determined. Therefore, a close-in distance (d0) is defined in the model, and the received power in this condition is a reference power. Thus, the Friis free-space model can be expressed as (3):

2.1. Kalman Filter

The KF is a well-known tool used to eliminate noise and can provide an efficient calculation approach for estimating system states [15,16]. By applying a series of regression models, the efficiency of the least-square method can be enhanced [17]. Because the internal state of a system cannot consistently be directly estimated, the KF has two primary assumptions: (1) the system is linear, and (2) the system error distribution and initial estimate probability distribution are both Gaussian distributions [16]. The KF applies the linear stochastic difference equation to construct prediction and measurement models, as expressed in equations (4) and (5):where xk indicates the state of a system at time k, A represents the conversion model for the system state, B denotes the control model for the control factor uk, zk is the observation state of a system at time k, and H is an observation model. In addition, and are system noise and observation noise, respectively, which are assumed to be mutually independent and to follow Gaussian distribution. and are expressed as equations (6) and (7):

The calculation of the KF is a regression process that involves two steps, namely, prediction and correction. At the prediction step, the system state () at time k-1 is used to calculate the a priori state of the system () at time k.

At the correction step, the observation value of the system at time k is used to adjust the system state at time k.where is the a priori estimation error of the system at time k, pk is the estimation error of the system at time k, and Kk indicates the Kalman gain of the system at time k. In the KF, the Kalman gain is applied to adjust the state estimates; therefore, the estimation errors of the systems can converge over time.

Other KF-related studies include that of Yim et al., who used KNN to find the distance between the target and the antenna and gave different weights to the EKF depending on whether the target was located at a corner or not [15].

2.2. Adaptive-Network-Based Fuzzy Inference System

The ANFIS has the characteristic of neural network learning and the advantage of the rules of a fuzzy inference system and can thus process nonlinear and complex systems and identify system rules. Figure 1 shows the framework of the ANFIS, which consists of five layers. The layers that comprise squares involve parameters, among which an optimal parameter can be obtained in each layer through learning adjustment. No parameters are involved in the layers comprising circles. The layers are explained as follows.

2.2.1. Layer 1: Input Layer

where x is the input of A, and Ai is the ith semantic tag for input A. μAi(x) is the membership function (MF) for the ith semantic tag of input A. The bell-shaped distribution is the most frequently used MF that has values within the range of 0 to 1, as shown in (11):where ai, bi, and ci are parameters of the MF.

2.2.2. Layer 2: Rule Layer

The firing strength of the fuzzy rules is calculated using equation (12):

2.2.3. Layer 3: Normalization Layer

2.2.4. Layer 4: Inference Layer

The output of the normalization layer is multiplied by the fuzzy rules to calculate the result of each rule.where fi is the ith rule, and pi, qi, and ri are parameters for the ith rule.

2.2.5. Layer 5: Output Layer

The weighted average of the results of the inference layer is computed to be the output of the ANFIS.

The parameters in each layer of the ANFIS are adjusted using a hybrid learning algorithm. When the optimal parameter adjustment is achieved, the calculation efficiency of the system and the output accuracy can be improved. Related studies using ANFIS include the following: Oliveira et al. combined signal strength and Link Quality Indication (LQI) to calculate distance and then used a fuzzy inference system to find the target location [19]; Lee et al. applied the parameters considered in the computational process to a fuzzy inference system to generate a new filter, which was then combined with a prototype filter to find the location of the target [20]; and other related practical applications of the relevant literature [21, 22].

3. Methods

3.1. Localization Algorithm Combining the Kalman Filter and Adaptive-Network-Based Fuzzy Inference System

The proposed localization algorithm assumed that the relationship between RSSI and distance remains the same in the same environment with the same distance. In addition, the concept of reference tag was used to identify the environment parameters suitable for the targeted object. The algorithm comprises four steps, as shown in Figure 2. The following section describes Figure 2. For more information, please refer to the descriptions on pages 7–11.

First, considering the use of antennas to receive the signal of the reference tag and the object to be measured, the signal will be distorted by the influence of multipath during the transmission process. Therefore, this study uses the characteristics of the Kalman filter (KF) to eliminate the noise during the transmission of the signal, so that the received signal is clean. The KF was then integrated with the modified Friis free-space model to identify the relationship between signals and distance. Through the correction learning of the ANFIS, the environment parameter suitable for the target was yielded, which was then combined with the modified WCG to determine the location of the target.

3.1.1. Kalman Filter

The KF can filter noise caused by interference in signal transmission; therefore, readers can receive clean signals emitted by reference tags and the target without interference. Because all of the reference tags and targets used in this study were static, their states would not change during the system conversion from the true state to the observation state, except for being interfered with by noise. Therefore, the prediction and measurement models of the KF were simplified as equations (16) and (17):wherewhere Sk is the true state of the system at time k, represents the signal strength of a reference tag at time k, signifies the signal strength of the target at time k, indicates the noise in the true state of the system at time k, and Q is the variance of the true system state. However, because the variation of the system’s true state cannot be obtained easily, Q is typically excluded from the consideration.where Zk is the observation state of the system at time k; is the observed signal of a reference tag at time k; represents the observed signal of a target at time k; indicates the noise in the observation state of the system at time k; and R denotes the variance of the observation state.

The observation state of the system was used to predict the estimate of the true state of the system, and the correction was performed to reduce errors in the estimate and the actual value. The initial estimate () and error (P0) were given, and iteration calculation was performed, as shown in equations (20)–(24):where is the a priori true state estimate of the system at time k, is the true state estimate of the system at time k, signifies the a priori estimation error of the system at time k, Pk indicates the estimation error of the system at time k, and Kk is the Kalman gain of the system at time k.

3.1.2. Friis Free-Space Model

The Friis free-space model is the propagation path loss model obtained in a free space based on the inverse square law, which assumes that RSSI is inversely square proportional to distance (RSSI 1/d2). However, the real environment is subject to the influence of the multipath effect; in other words, the signals received by readers frequently interfere. Therefore, the relationship between signal values and distance is not inversely square proportional. Thus, the Friis free-space model was modified to bewhere and are Pr (d0) and d0 in equation (25); and n is the environment parameter, which varies according to the change in environment and distance.

Moreover, when the environment and distance between the transmitter and receiver are the same, the receiver signal strength is influenced by various levels of interference in signal transmission, causing changes in the value of n. Thus, this study employed reference tags to determine the possible value of n in the environment. The approach is as follows:

Assume that I readers (i = 1, 2, …, I) and J reference tags (j = 1, 2, …, J) were deployed in an indoor environment for localization. The value of n was calculated as follows:where represents the clean signal sent by the jth reference tag and received by the ith reader, dij indicates the distance between the ith reader and the jth reference tag, and is the value of n for the ith reader corresponding to the jth reference tag.

3.1.3. Adaptive-Network-Based Fuzzy Inference System

This study applied the ANFIS to obtain the value of n for the target connected to various readers. The ANFIS model involves three input data, one output data, and five layers. The input data represented as (i = 1, 2, 3) were clean signals received by the ith reader. The output data were the values of n for readers corresponding to reference tags and the target.

(1) Input Layer. Each input involved three MFs, which can be expressed as follows:where indicates the first MF of the clean signal received by the ith reader. The MF was a bell-shaped distribution with values ranging from 0 to 1, as shown in (28), where x is the input signal, and al, bl, and cl are MF parameters.

(2) Rule Layer. The firing strength of the fuzzy rules was calculated as follows:where m is the mth rule; a, b, and c are the semantic tags for the first, second, and third readers, respectively; and a = b = c = 1, 2, 3.

(3) Normalization Layer. The firing strength of all rules was normalized using (30).

(4) Inference Layer. The output of the normalization layer was multiplied with the fuzzy rules to calculate the result of each rule.where fm is the mth rule, and pm, qm, rm, and sm are parameters for the mth rule.

(5) Output Layer. The results yielded in the inference layer were summed to be the output value of the ANFIS.

The clean signal of reference tags () and the n values for reference tags corresponding to various readers () were used as the input and output of training data in the hybrid learning algorithm. Consequently, the optimal ANFIS in the environment was employed to determine the value of n () for the target corresponding to various readers.

3.1.4. Calculation of the Target Location

The n () obtained using the ANFIS was incorporated in the modified WCG as follows:where (xt, yt) is the coordinate of the target; (xi, yi) is the coordinate of the ith reader; and indicates the clean signal sent by the target and received by the ith reader.

4. Experiment Evaluation

This study aims to evaluate whether the proposed algorithm meets the future operational requirements of the smart factory through three practical experimental operations. First, the proposed localization algorithm was verified to be capable of generating a more accurate and stable localization result. Second, the number of reference tags was adjusted to examine whether the localization accuracy was influenced by the number of reference tags used. Finally, the localization environment was interfered with to demonstrate that the proposed localization algorithm can generate the same localization results regardless of the interference.

4.1. Experimental Operation 1

The first experiment was conducted in a 20 m × 10 m smart factory environment, in which three readers, six reference tags, and one target was deployed, as shown in Figure 3. The first experiment comprised two parts. In the first part, the type and number of MFs in the ANFIS in the proposed localization algorithm were altered to determine the parameters that can generate satisfactory localization outcomes. The quality of the localization outcomes depended on the distance difference between the actual location and the estimated location of the target given in equation (34) as well as the level of distance difference.where x and y denote the actual x-axis and y-axis coordinate values for the target, and xt and yt are the estimated x-axis and y-axis coordinate values for the target, respectively.

The initial state of the system () is zero, and the initial covariance (P0) is 100. By setting the system observation state and initial parameters, the Kalman gain during the calculation process was adjusted and further used to identify the true state of the system, enabling covariance convergence.

The localization algorithm proposed in this study categorized the MFs of the ANFIS into three types, namely, triangular-shaped, bell-shaped, and Gauss curves. Two and three MFs were adopted from each type for analysis. Through various combinations of the MFs, the environment parameters that generated superior localization results and were suitable for the target were calculated by employing the MATLAB toolbox for the ANFIS. The experimental results are presented in Table 1.

The standard deviations shown in Table 1 revealed that the results generated using three MFs were more stable compared with those generated using two MFs. Moreover, among the three MF types, the average error produced by the Gauss curve MF was the smallest, and the bell-shaped MF produced optimal stability. Because the Gauss curve and bell-shaped MFs had similar average errors, this study adopted three bell-shaped MFs for the ANFIS parameter setting. The proposed localization algorithm was compared with other frequently used algorithms, such as the LANDMARC [23], WCG [24], ANFIS, and DV-Hop [25] algorithms, and the comparison results are shown in Table 2.

Figure 4 shows that the proposed localization algorithm that combined the KF and ANFIS produced minimal localization errors, compared with other algorithms. The comparison presented in Table 2 revealed that the proposed localization algorithm demonstrated optimal localization stability.

The localization results using LANDMARC, WCG, and ANFIS algorithms contained a high number of errors and lacked stability because these algorithms did not consider possible interference in the signal propagation process or the consequent signal distortion. This study applied the concept of reference tag and eliminated noise in the signal transmission process by employing the KF. The propagation path loss model was then used to generate environment parameters, and the environment parameter that was most suitable for the target was obtained using the ANFIS. The weighting method was finally adopted to determine the location of the target. The experimental results indicated that the proposed localization algorithm that combined the KF and ANFIS can be applied to indoor localization.

4.2. Experimental Operation 2

By changing the number of reference tags, the experiment in this experiment aimed to verify whether the number of reference tags influenced the localization results produced by the proposed localization algorithm. Thus, the number of reference tags was set as three and six. The experiment was conducted in a 5 m × 6 m smart factory environment (Figures 5 and 6).

Table 3 indicates that the proposed localization algorithm produced stable localization results regardless of using three or six reference tags; however, the result obtained using six reference tags was superior. This can be explained as follows: The proposed localization algorithm applied the ANFIS to calculate possible environment parameters. In the calculation, the data of the reference tags were used as the training data to identify the inference system suitable for the environment. Therefore, using a high number of reference tags, the possible environment parameters can be identified easily, and accurate localization results can be obtained.

4.3. Experimental Operation 3

The experimental results obtained in the second experiment were used in experiment 3. An interference experiment was conducted in a 9 m × 10 m smart factory environment. Specifically, in a localization environment, the transmission of signals was interfered with by human walking. Subsequently, data were analyzed to verify whether the proposed localization algorithm can generate a localization result at a high level of accuracy and stability. The third experimental environment is shown in Figure 7.

Because the proposed localization algorithm applied the KF to eliminate noise during the signal transmission process, the interference of human walking did not cause the localization results to change significantly. Table 4 and Figure 8 show that the tests with and without interference produced similar average errors and stable localization results.

In this study, we compared the proposed method with the current common localization algorithms (LANDMARC, WCG, ANFIS, and DV-Hop) operated in the smart factory environment through experimental operation 1; the results confirm that the proposed algorithm has significantly improved the localization error and is relatively stable (lowest value of standard deviation). Furthermore, experimental operation 2 was used to verify whether the larger the number of reference tags, the more it interferes with the accuracy of localization in the smart factory environment; as a result, in the smart factory environment, the more the number of reference tags is in the proposed algorithm, the more likely it is to find the possible interference parameters and to obtain more accurate localization results. However, in the real-life application, it is not possible to completely exclude the interference of the movement of people on the positioning. Therefore, in experimental operation 3, we verified whether the interference of human movement on the signal transmission affects the accuracy and stability of localization in the smart factory environment. Overall, we conclude that regardless of the interference of signal transmission caused by the movement of people, there is no effect on the positioning results in terms of average positioning error or stability.

5. Conclusion

Traditional localization algorithms based on signal strength cannot produce accurate localization results because of the multipath effect. This study provides a practical contribution by offering an adaptive tracking system with improved tracking algorithms. The system combines KF and ANFIS and applies the concept of reference tags to a smart factory environment. Compared with the positioning error derived from the conventional ANFIS algorithm, the hybrid positioning algorithm (KF + ANFIS) provided in this study reduces the positioning error by up to 89% (=(628.12–67.03)/628.12). Compared with other common localization algorithms, including LANDMARC, WCG, and DV-Hop, the localization error is also reduced by at least 50%. Specifically, the KF was employed to eliminate noise in signal transmission, and a propagation path loss model was adopted to obtain the environment parameters in signal transmission. Through the learning of the ANFIS, the environment parameter most suitable for the target was generated and was subsequently used in the weighting method to determine the location of the target. This technology can be applied not only in smart factories but also in the marketing field. In recent years, it has been proposed to provide local advertising with the user’s location information. This helps to market products and services. The contribution of this study can improve the accuracy of indoor positioning and reduce the provision of misinformation.

Moreover, this study involved experimenting in a real environment for parameter setting, and the proposed localization algorithm was compared with other commonly used localization algorithms. The data analysis revealed that the proposed localization algorithm can produce an accurate and stable localization result superior to that produced by others. In addition, experiments regarding the number of reference tags and interference in a localization environment were conducted in this study. The experimental result revealed that an increase in the number of reference tags can cause an increase in localization accuracy. The proposed localization algorithm can produce stable localization results with similar errors regardless of interference in the localization environment.

Although the results produced by the localization algorithm proposed in this study still involved errors, a certain level of stability was achieved. Future studies can identify the stability errors in an environment to obtain an accurate localization result. The combination of various types and numbers of MFs in the ANFIS can be used to improve the accuracy of the localization result for self-propelled inspection robots, thereby effectively reducing the related costs. This location-based service technology can effectively provide accurate equipment information that widely applies in warehouse management, transportation, personnel tracking, and medical care.

Data Availability

“No data were used to support this study”.

Conflicts of Interest

The authors declare that they have no conflicts of interest.

Acknowledgments

This work was partially supported by the Ministry of Science and Technology of Taiwan under grant no. MOST 110-2221-E-992-086.