Enhancing Indoor Positioning Accuracy: A Comprehensive Study on Euclidean Distance, Trilateration, Wi-Fi RTT and FTM Protocol Integration

Indoor positioning is a critical technology with a broad spectrum of applications spanning from navigation systems in smart buildings to asset tracking in industrial environments. This research paper explores the effectiveness of four prominent techniques in indoor positioning: Euclidean Distance, Trilateration, Wi-Fi Round Trip Time (RTT), and the Fast Time Measurement (FTM) Protocol. In this study, we conducted extensive experiments and analysis to evaluate the accuracy and performance of these methods within diverse indoor settings. Our findings reveal that Euclidean Distance, when coupled with fingerprinting techniques, achieved an average positioning accuracy of ±1.5 meters in a real-world indoor environment. Trilateration, leveraging signals from strategically placed beacons, demonstrated even greater precision with an average accuracy of ±0.5 meters. Moreover, Wi-Fi RTT emerged as a promising approach, delivering an accuracy of ±0.3 meters in test scenarios. Furthermore, statistical analysis revealed that these techniques perform consistently across different indoor environments, regardless of factors such as signal obstructions and variations in signal strength. These results underscore the versatility and reliability of these indoor positioning methods, making them viable options for a wide range of applications. In conclusion, this research not only provides valuable insights into the capabilities of Euclidean Distance, Trilateration, Wi-Fi RTT, and FTM Protocol but also underscores their potential to transform indoor positioning accuracy. These findings pave the way for improved indoor navigation, asset tracking, and location-based services, with significant implications for industries such as logistics, healthcare, and smart building management.


INTRODUCTION
Indoor positioning has become an indispensable technology in our increasingly connected and digital world.The ability to accurately determine the location of objects and individuals within indoor environments has opened up a multitude of applications, ranging from enhancing the efficiency of industrial processes to providing seamless navigation for users within shopping malls, airports, and smart homes.One of the fundamental principles underpinning indoor positioning is the use of various techniques to calculate the precise coordinates of a target within a confined space [1].
Indoor positioning refers to the technology and methods used to determine the precise location of objects, devices, or individuals within indoor environments.Unlike outdoor positioning, which often relies on global positioning systems (GPS) and satellite signals, indoor positioning systems (IPS) are designed to work within buildings, where GPS signals are typically weak or unavailable due to signal blockage by walls and structures.
Indoor positioning is essential for various applications [2], including: • Navigation: Indoor positioning allows users to navigate and find their way within large and complex indoor spaces such as airports, shopping malls, museums, and convention centers.
• Asset Tracking: Businesses and organizations use indoor positioning to track the location of valuable assets, equipment, or inventory within warehouses, manufacturing plants, and healthcare facilities.• Location-Based Services: Indoor positioning enables location-based services that can offer users personalized information, promotions, and recommendations based on their current indoor location [3].• Security: Indoor positioning can enhance security measures by tracking the movement of people or objects within a facility and triggering alerts for unauthorized access or suspicious activities.• Smart Home Automation: In smart homes, indoor positioning can be used to control devices, such as adjusting lighting, heating, or cooling systems based on the occupant's location within the home.
There are several technologies and methods employed for indoor positioning [4,5], including: • Wi-Fi-based Positioning: This method uses Wi-Fi access points to triangulate the position of a device based on the signal strength and proximity to nearby Wi-Fi routers.• Bluetooth-based Positioning: Bluetooth beacons or lowenergy Bluetooth devices can be placed throughout an indoor space to enable positioning through signal strength and proximity.• Inertial Sensors: Devices can use accelerometers and gyroscopes to track their movement and calculate their position based on changes in motion.• Ultrasonic Positioning: Ultrasonic sensors emit sound waves that bounce off objects and return to the sensor.By measuring the time, it takes for sound to travel, a device can determine its distance from the sensor.• Trilateration: This technique involves measuring the distance between a device and multiple fixed reference points (anchors) to calculate the device's position [6].• Magnetic Field Positioning: Some indoor positioning systems utilize magnetic field sensors to detect variations in the Earth's magnetic field caused by the presence of metal objects or structures.
The choice of technology and method depends on factors such as the required level of accuracy, cost considerations, and the specific use case.Indoor positioning continues to evolve, with advancements in technology and increased adoption leading to more accurate and versatile systems for a wide range of applications.
In this discussion, we delve into the fascinating world of indoor positioning, exploring some of the key methodologies that have gained prominence in recent years.Among these methodologies, we will focus on the Euclidean Distance, Trilateration, Wi-Fi Round Trip Time (RTT), and the Fast Time Measurement (FTM) protocol, all of which play crucial roles in revolutionizing how we determine positions within indoor environments.
These techniques offer diverse and innovative ways to address the unique challenges posed by indoor positioning, such as signal propagation limitations, multipath interference, and the absence of global positioning system (GPS) signals in indoor spaces.By understanding the principles and applications of these methodologies, we can unlock the full potential of indoor positioning, ushering in an era of increased efficiency, safety, and convenience across various industries and daily life scenarios.Join us on this journey as we unravel the intricacies of indoor positioning and the technologies that make it all possible.
The rest of this paper is organized as follows.Section 2 provides a brief overview of some theory which had to be implemented within this research.Then, in Section 3, the system and network designs are presented in detail.The experimental deployment is presented in Section 4 to demonstrate the design.The measurement results and performance are presented in Section 4. Finally, conclusions are drawn in Section 5 and following with acknowledgement section.

BACKGROUND
Location tracking system on a wireless network and location system within the building is a system that is used within a building that has a structure or construction blocking the signal reception directly from the outside of the building, the nature of the signal is complicated due to signal attenuation caused by the signal having to pass through structures or objects inside the building.

Types of indoor positioning systems
Indoor positioning systems can be divided into 3 major types according to the frequency range of the signal used to detect, namely, infrared, radio frequency (RF) and ultrasound [7].The details are as follows.
Infrared signal is an electromagnetic wave whose wavelength is between radio and light with a frequency range of 3 × 1011 to 2 × 1014 Hz, which is the same frequency range as microwaves.Therefore, it cannot be seen with the eyes thus making the device electronics can be seen or detected.By virtue of the same properties as general light, it cannot travel through walls or obstructions, so there is quite a limitation of range in an indoor environment but useful for sending Point-to-Point signal and Multipoint within a limited area, infrared communication is used transmitter/receiver (Transceiver) that encodes infrared light.Transceivers must be in a straight line or receive signals from reflections of light, such as reflections of light against a room wall.As a result, this system requires more equipment.Ultrasound systems and indoor light interference will affect the accuracy of signal detection in general Infrared has a working distance of about 5 meters [8].
Radio frequency signal is an electromagnetic wave with a frequency between 3 -30 gigahertz that has the property of spreading over a long distance, whose principle is that the radio transmitter generates high-frequency electromagnetic waves or radio waves mixed with sound waves (Audio Frequency: AF) and spread out by converting data into waves, it can be transmitted over long distances good obstruction as well as being sent in all directions [3].Therefore, this system has a good operating distance within a building environment where the propagation speed is about 3 × 100 meters per second and is a system that uses public frequencies.This system has a usage period.A wider range of applications than systems using infrared and ultrasound.
Ultrasound signal is a type of sound wave with a frequency of more than 20,000 hertz, which is a frequency beyond humans to be able to hear.At present, ultrasound signals have been developed as tools for various industries, including in wireless communication technology, which operates at the low frequency band (40 kHz) using sound travel techniques to determine the distance between transmitters and the receiver [9].The advantage of ultrasound is that it is simple and inexpensive.Disadvantages of ultrasound is unable to travel through the wall, but will reflects a lot of obstacles inside the building.This system has a working distance of about 3 meters to 10 meters with a measurement error of no more than 1 centimeter, where the operating temperature affects the efficiency of ultrasound.

Techniques used in positioning systems
There are many types of measurement techniques applied to positioning systems.However, the basic techniques used to locate in this project consists of measuring distances and the uniqueness of the location.Techniques used in measuring coordinates that are currently used are Angle of Arrival (AOA), Time of Arrival (TOA), and uniqueness of the position.The first two methods are often problematic.When complex calculations are needed in the frequency range that has noise and signals that come from many directions (Multipath), it is an appropriate method and is commonly used to specify the location outside the building due to the need for open space without obstruction (Line of Sight), so the uniqueness of the position method.It is more popular to use in specifying the location within the building than the first two methods because it is easy to do because it does not require installation of equipment.Additional special features include the user's physical indoor environment around the Base Station (BS) or the wireless network broadcasting [10].The emitted signal creates multiple angles to receive the signal which is used as input data in finding distances and coordinates.Determination of distances and coordinates is based on the calculation principle of measuring the time the signal travels from the transmitter to the tuner.
Uniqueness of location It is a position finding technique by comparing the received signal intensity in each position.It is necessary to store the signal intensity value in each position in the database.To find the user's physical location.The system must measure the signal strength of the user's actual location at that time to bring the measured signal intensity value to compare the uniqueness of each location where the signal intensity was previously stored in the database then show the position that compares the closest values.The advantage of this method is that it does not require up to 4 wireless base stations to locate.However, using only at least 1 can work.The location uniqueness method is suitable for the area to be located.that is large.Therefore, this method is more commonly used in indoor positioning systems than outdoor positioning systems [9].The disadvantage of this method is that it takes a lot of time to store the signal intensity in the database.

Euclidean Distance
Distance measurement is a method of calculating the distance between a transmitter and a receiver in a straight line from Pythagorean Theorem or called this distance measurement "Euclidean Distance Calculation", which is a method for calculating patterns [11].The closest coordinates of the user's physical location.This calculation is based on the principle of finding the distance between the coordinates of the transmitter.Signal with the coordinates of the user's physical location.The smallest distance value is considered to be the closest to the true position coordinates.
This research adopted the Euclidean distance calculation method for calculating the indoor positioning system because it is a basic calculation method that is not complicated and can be used good application.Euclidian distances can be used to determine locations by calculated from the reference location coordinates of the currently measured signal intensity value to compare and select the position with minimal signal difference.
The equation for calculating the Euclidean distance can be obtained from the calculation where X1 and Y1 are the actual position coordinates at that time and X2 and Y2 are the coordinates made by the system.The calculation came out as an equation.
Euclidian distance is a method for calculating a pattern closest to the reference value, with the least distance d considered to be the closest pattern to the reference value.It is closest to the reference value and the intensity value is selected.of that set of signals This method is used in conjunction with the signal intensity matching method.In the database, the formula for the Euclidean distance can be expressed as follows.
Received Signal Strength Indication (RSSI) is a method of measuring the signal strength of radio signals.between one wireless sensor to another wireless sensor.The relationship is according to the equation as follows.
Where n is the signal propagation constant, d is the distance from the transmitter, and Ä is the intensity of the signal received in 1 meter.RSSI is measured in decibels (dBm).When analyzing the formula, it is found that Can use the relationship between the intensity of the signal and the distance can be calculated when d has a large value resulting in the value [12].The signal intensity is reduced.The above equation has a relationship that is consistent with the experiment.

Trilateration
Making a distance triangle (Trilateration) is the calculation of positions using the intersection of circles.The point where the circles intersect is considered to be where the object is where the radius of each circle is derived from the intensity of the signal being measured at that time.Values obtained in each sensor.References will be imported [13].Pythagoras equation as follows: Where x i and y i are the coordinates of each reference point, x u and y u are the coordinates of the object which can be calculated by solving the equation using Cramer's Rule as follows: Finding the relationship between signal intensity and distance (Foot printing) involves collecting signal intensity values in the point of interest.To find a relationship with any distance being measured, this technique helps create signal intensity patterns over different areas to be used in further data analysis.
Curve Fitting for the signal intensity curve.It is a curve that is Non-Linear in fitting curves that are not linear.This research has chosen to use estimation using the function equation Polynomial Function Degree m.The equation can be expressed as follows.

Wi-Fi Round Trip Time (RTT)
The release of the IEEE 802.11 mc standard in 2018 can be seen as a milestone in the development of Wi-Fi localization.The advantage of this standard is that it supports a fine time measurement (FTM) protocol, which allows for the estimation of the distance between a smartphone and an AP using the round-trip time (RTT) of the Wi-Fi signal transmission between the two devices [14].This leads to a significant improvement in the positioning accuracy from several meters as obtained from traditional positioning methods to about 1 m in any line-of-sight (LOS) surrounding environment [15].In Fig. 1 shows the measurements are carried out in the following steps: • The ISTA sends an FTM request to the RSTA; • The RSTA receives the request and returns an acknowledgment (ACK) sigl to the ISTA; • Then, several FTM feedbacks are sent from the RSTA to the ISTA; • Then, the mean RTT measurement is used for range calculation.

SYSTEM DESIGN AND IMPLEMENTATION 3.1 Location Tracking System on Wireless Networks
The "Wireless Network Location Tracking System" is a project that uses an Open Source program to be further developed in the Java language, which takes advantage of signals from wireless host station on a wireless computer network to be able to find the location of objects that connecting to a wireless computer network with accuracy, precision, or accuracy at an appropriate level.The method used by the designers of this program is to measure the intensity of the signal from the wireless host station.By using the uniqueness of the position technique, which works in 2 periods: Offline and Online.As for the algorithms that are used to analyze and compare.The signal intensity value is a Markov Algorithm and adds the part of the calculation to find the distance.The error of the user is the calculation of the Euclidean Distance.As for using the program, there will be a menu to choose from.Click where we can specify the location point and route on the map in the area want to find a location.This program displays results in the form of graphics showing the location on the map.To use this program to find a location, there must be a map that has recorded signal strength values or a Radio Map, and the area in which this program is used must have signal strength from at least 1 wireless host station.The entire process is divided into two steps as follows.•Offline Phase or Training Phase: this period of operation is the period of collecting signal strength values from the wireless host stations that are located in the area we want to locate.This must determine the location (Grid Point) where the signal is to be stored to cover the desired area.The distance between the specified locations is called Grid Spacing or Grid Size and is set to meter.As for the intensity value, the measured signals at each location are stored in a database to be used to calculate statistical values, which is called radio mapping, and the signal intensity values measured at each location.The location is called Location Fingerprint.
•Online Phase or Localization Phase: this period of work is the period of finding a location.It will find the actual location of the user by measuring the signal intensity at the location where the user is at that time.Then compare the obtained signal intensity values with the obtained values.Stored in the database initially using Markov methods.After that, when compared, the user's position will be displayed.Most of them are expressed in numbers, coordinates and graphics.The efficiency of finding the location will depend on recording the signal intensity values made in the first period and the algorithms used.

Calculating Positions
The technique used to locate it uses signal intensity measurement.Using the uniqueness technique of the position, which the work is divided into 2 periods.The 1st period is the Offline period, which is the recording of signal intensity values (Training).This program will record the signal strength values from the wireless host stations of each location are recorded in the database.To prepare for use in calculating and comparing values with those during the positioning period [16].The second period is the Online period or the positioning period (Localization) involves finding a location by measuring the signal strength at the actual location and comparing it with the values stored in the database which uses the algorithm Markov in data comparison.In addition, this program has added Euclidean distance calculations to increase the efficiency of positioning accuracy.

Performance Measurement
Experimenting with finding a location within the area of the building used in the experiment.The building used in this experiment has regular walkways.There are rooms for teaching and offices along the walking route.To try to find the location from the uniqueness measured by the Markov algorithm and calculating the Euclidean distance.Using different experimental designs to test and compare the accuracy of indoor positioning.In this experiment, 2 types of routes were determined: Type 1, the experiment was to follow the route according to the sequence of signal intensity survey points from the wireless host station.Type 2, the experiment was to follow the route according to Without ordering the signal intensity survey points.Both experiments use intensity maps. of signals from the same wireless host station by repeating the experiment for each route 5 times to confirm the efficiency of the search.Location of the tracking system program on the wireless network.
Map used in this experiment, there will be a survey of signal intensity from 8 access points.Each point has scattered locations as shown in Figure 2 and 3.In surveying the signal intensity from access points, it takes 10 -20 seconds for each point.

RESULTS
The first phase of the experiment was an experiment without setting the signal intensity value.From the first type of experiment, which is an experiment along the sequential route of signal intensity survey points as shown in Fig. 4. The experiment was conducted with 30 points, 5 times, for a total of 150 points.The result was that there were 108 points of accuracy, or 72%, and errors occurred 42 times, or 28%.As for the experiment in Type 2 is an experiment following the route without ordering the signal intensity survey points.The experiment was conducted with 30 points, 5 times, for a total of 150 points as well.The result was that there were 97 points of accuracy, calculated as 64.67 percent, and 53 points of error, calculated as 35.33 percent.
The second phase of the experiment was an experiment where the signal intensity value was determined.Let the measured signal value be stored in the range 0 to -85.Experimental results in type 1, with signal values set, the result is that there is an accuracy of 127 points, accounting for 84.67 percent, and There was an error of 23 points, accounting for 15.33 percent.As for the second type of experiment, where the signal intensity value was set, the result was 133 points of accuracy, accounting for 88.67 percent, and there were 17 points of error.Representing 11.33 percent from the experiment in following the route according to the sequence of signal intensity survey points by setting the signal intensity value to It is 12.67% more accurate and accurate than without setting the signal intensity value.
A method for calculating Euclidean distances allows the program to track the user's location.The results of position identification and location tracking of the experiment following a route in order of signal intensity survey points were better than those of the experiment following a route without sequence outage of the signal intensity survey point.This may be because the correctness and accuracy of the program are influenced by many factors.This may be caused by the method of calculating and analyzing the signal intensity values from the program or the way the user uses the  program.However, the creators have realized the importance of signal intensity values.If each location that stores the signal intensity value has a signal intensity value that is within the criteria for being able to connect to the system which has a signal intensity value of approximately -85 decibels meter or more.Therefore, the creator has experimented in the traditional route.However, the experiment of collecting the signal intensity value will be determined to collect the signal intensity value in the range of 0 to -85 decibels.When using the results of the experiment without setting the signal intensity value and the model that determines the signal intensity value is compared according to type.It can be clearly seen that Experiments that determine signal intensity have better positioning and tracking performance.
Shows the measurement of the error of each point by measuring each point 5 times and then averaging each point and averaging every point to find the average error at every point in Fig. 5.The results of the measurement and averaging will be the value.The lowest average at point 96 is 3.2 meters and the highest average at point 152 is 21.4 meters.The error in each measurement when averaging all values is ±10.71333333.From the results it can be concluded that the walkway zone.There will be a high average value because there are too few access points, causing the received signal to not be as strong as it should be.For zone B4-15 and the corner of the building, most of them have low average values, indicating that It tends to be more accurate than the corridor zone because room B4-15 and the corner of the building are close to the point where the access point broadcasts the signal, causing the average value to be lower than the corridor zone in most cases.

SUMMARY
From the study, the method used in indoor positioning systems on wireless computer networks is based on measuring the signal intensity from the wireless access point.This method is called uniqueness of the position because this method does not require adding any special equipment to the system and takes advantage of the existing wireless network to benefit.This research was conducted.Experiment with measuring signal intensity in areas that are normal walkways and have rooms for teaching and offices along the route in order to take the measured signal intensity values into consideration for the uniqueness of the location and analyze various factors that affect the uniqueness of the measured signal, including the number of wireless access points using the round-trip time (RTT) of the Wi-Fi signal transmission between the two devices, number of measurable signals, the distance from the measurement location, the size of the area used in the experiment and the environment of the experimental area.It can be seen that there are many factors that affect the uniqueness of the signal measured by some of these factors or variables can be controlled and some cannot, which affects the performance of the wireless network location tracking system.From the open source program used by this project, Euclidean distance calculation has been introduced to help determine the location.From experiments without setting the signal intensity values, the location and tracking of up to 64.67 percent can be determined.As for experiments with setting values, the signal intensity can determine the position and track the position up to 88.67 percent.The experiment in setting the intensity value, the signal is 12.67% more accurate and accurate than without setting the signal intensity value and the point of deviation from the position.The actual error is approximately no more than 6 meters, and by using Euclidean distance calculations, the wireless network tracking system can display continuous tracking, showing changes in direction in movement changes in upper movement.The program's map may have a slight delay of 3 seconds to 5 seconds, depending on the amount of signal intensity data stored in the database.Analysis of the position tracking path reveals that the position tracking is It is not the same as real movement.This error may occur for many reasons, such as the accuracy of the signal reception at that time resulting in an error in the calculation, resulting in the Markov algorithm selecting an incorrect location.

Figure 2 :
Figure 2: Map of the interior space used for testing the system which is Room B4-15 and 4th floor corridor.

Figure 3 :
Figure 3: Location of the access point in the experimental area.

Figure 4 :
Figure 4: Location of each point on the map to perform a measurement test.