{'fraction_non_alphanumeric': 0.031701335271141794, 'fraction_numerical': 0.00931056408393133, 'mean_word_length': 4.384935191978479, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 3, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Clock Error Analysis of Common Time of Flight based Positioning Methods

Today, many applications such as production or rescue settings rely on highly accurate entity positioning. Advanced Time of Flight (ToF) based positioning methods provide highaccuracy localization of entities. A key challenge for ToF based positioning is to synchronize the clocks between the participating entities. This paper summarizes and analyzes ToA and TDoA methods with respect to clock error robustness. The focus is on synchronization-less methods, i.e. methods which reduce the infrastructure requirement significantly. We introduce a unified notation to survey and compare the relevant work from literature. Then we apply a clock error model and compute worst case location-accuracy errors. Our analysis reveals a superior error robustness against clock errors for so called Double-Pulse methods when applied to radio based ToF positioning


I. INTRODUCTION
The ability to locate a device's position is highly valuable in our modern and connected world. A considerable amount of research has therefore been conducted on that field, most recently in particular in the area of Time of Flight (ToF) based positioning. In a typical ToF setup, radio signals are used to estimate distances between so called Anchor and Tag nodes. Anchors have known positions and Tags are to be located. There are two main approaches in ToF, which lead to different solving algorithms. The first one is Time of Arrival (ToA) which measures the sending and receiving time of a signal and is using these values to calculate a distance between two devices. For instance, in a 2D space the distances of one Tag to three Anchors are required to locate the Tag with multilateration algorithms [1]. In ToA the time of signal transmission as well as time of arrival has to be measured. In this basic version, all Anchors and Tags need to have synchronized clocks to perform the measurement.
The second approach is Time Difference of Arrival (TDoA) which measures the difference of signal arrivals. For instance, in a 2D space a signal sent from a Tag which is arriving at three different Anchors can be located by hyperbolic solver algorithms [2]. TDoA approaches do not require the time of signal transmission. Only the differences of the arrival times of the signal at the Anchors need to be known. Unlike the ToA case, this requires the Anchors to be synchronized among each other. No synchronization between Anchors and Tag is needed.
To have synchronized clocks is a considerable infrastructure requirement and, therefore, alternative methods to do synchronization-less ToA and TDoA have been developed [3,4,5,6,7]. Moreover, the fact that some of these meth-ods work with radio waves, some with ultrasound is posing different requirements on the tolerable clock accuracy. The goal of this work is to analyze the relevant ToA and TDoA methods from the field of synchronization-less ToF. To achieve this, an error model is defined and applied to the approaches in order compare them against each other and to point out commonalities and differences.
The rest of the paper is organized as follows. First we will introduce the error model (Section II). Then both, ToA and TDoA methods will be presented in Section III and IV respectively. Finally, in Section V, a comparison and conclusion are given.

II. UNIFIED ERROR MODEL
Our error model is inspired by the works of Neirynck et al. [8] and Tschirschnitz and Wagner [6]. We adopt and optimize their underlying principle to make it applicable to the methods we assess in this paper.

A. Clock Drift and Synchronization
Every clock contains imperfections, making it run at an inconstant rate. No existing clock is able to keep the perfect time [9]. Since ToF-based methods rely on the measurements of signals propagating with high speeds such as the speed of sound or the speed of light (c), clock imperfections make the runtime measurements inaccurate.
To reach a better understanding of clock errors, their deviation is typically described in the parts-per notation which is in the following in the order of magnitude of millions, hence Parts per Million (ppm) [10]. The parts-per notation specify the ratio of how many clock ticks the current clock-value is expected to deviate from the real time. As notation for the rest of this paper we introduce the symbol of A to describe the clock error of device or oscillator A. For quartz oscillators a typical value for is ±20 ppm as defined in IEEE802.15.4 [11].
The current timet of device A can therefore be expressed as:t t is the ideal, error-free clock counter value andt is the erroraffected counterpart.
Since in this paper we focus on ToF, which implies measurement of propagation of radio waves, clock counter precision needs to be below nanoseconds. For instance, 1ns corresponds to ≈ 0.3m of signal propagating with the speed of light.
A typical assumption in the field of ToF is that the drift of a specific clock is constant to allow measurements with the same clock error for some time [8].

B. Measurement Errors and Multipath
The accuracy of time of flight measurements can be affected by additional error factors. The two most relevant factors are Non Line of Sight (NLoS) errors and multipath-propagation effects.
a) Multipath-Propagation Effect: The multipath-effect describes the fact that electromagnetic signals can reach a receiver on multiple paths. They can be reflected by walls or other obstacles for instance. As a consequence, a measured signal propagation time is not always that of the shortest possible path between the emitter and the receiver. However, for accurate distance measurements, the identification of the direct signal path, the so called primary signal is essential. b) NLoS Error: NLoS errors occur if the direct path between a sender and a receiver is blocked by a material with different propagation properties than for example air. The signal traveling on the direct path between sender and receiver goes through the obstacle before reaching the antenna of the receiver. The obstacle changes the propagation speed.
As a consequence of having such material changes in realworld settings, it is impossible to make accurate assumptions about the signals traveling speed between the sender and the receiver. Moreover, NLoS scenarios make the identification of the primary signal under multipath-propagation harder.
Though the previously described problems have high relevance, we assume in the following Line of Sight (LoS) scenarios where the measurement errors can be neglected.
A more detailed description and analysis of those effects can be found in [12].

III. TIME OF ARRIVAL
Having defined this error-model we can now apply it to the relevant ToF methods from the state of the art. We will group the analyzed methods into ToA and TDoA, beginning with the former one.

A. Simple Time-of-Arrival
The simplest ToF setup imaginable would be the one of simple Time-of-Arrival (simple-ToA). Simple-ToA consists of two devices A and B between which one signal is exchanged (compare Fig. 1). This signal sent by A is timestamped (using As clock) at the moment of transmission as well as when it is received at B (using Bs clock). If we now consider for a moment the synchronization between the devices clocks to be perfect, the difference between A and Bs timestamps would resemble the exact ToF between both.
Then the distance between both could be calculated as: Problems arise if we now reconsider the calculation under the assumption that synchronization is not provided and also when considering the presence of clock drift effects (like described in Section II-A). For example, even if we assume to have both clocks to be synchronized at one distinct moment (t = 0), the error would then accumulate from that moment on. We can calculate that worst-case error in the final distance estimate using our clock error model (Section II).
Like in (II-A) we define a clock error model: Based on these erroneous timestamps and using (1) and (2) we then define the erroneous ToA (d AB ) and distance value (AB) as:d Consequently, we define the difference between the erroneous and error-free value as the error.
Moreover, using the fact that t 2 = t 1 + d AB we can substitute t 2 : And since t 1 d AB (d AB is in order of magnitude of nanoseconds) in almost all realistic scenarios, we get the approximation: When assuming the default clock drift of ±20ppm the worst value ( B − A ) can take on is 40 1000000 . So the worst-case error introduced can be estimated as: Therefore we expect an worst case error of 12 × 10 3 meters for every second elapsed on t 1 on from the moment of the last synchronization until the moment the measurement took place. This effect would without question, render such a system for almost all applications unusable.

B. Two-Way-Ranging
A first simple solution to compensate the missing synchronization between devices is the concept of Two Way Ranging (TWR) as determined in IEEE802.15.4 described in [13]. TWR systems include two devices A and B, that are communicating bi-directional to measure a round-trip-time. This concept is simply described by A sending a message at t 1 to B (received at t 2 ) which gets then acknowledged after a fixed and known delay at time t 3 (sent from B). That acknowledgment arrives back at device A at t 4 . According to [13], A can now calculate the ToF as follows: with R A := t 4 − t 1 and D B := t 3 − t 2 (comp. Fig. 2) This method is expected to be better conditioned since we do not rely on the clocks being synchronized at the beginning of the measurement. Therefore the error should not accumulate in the same way as in simple ToA (Section III-A). This intuition is now substantiated. Similar as in Section (II-A) we define an erroneous model for the here relevant values: And by using (3) we can define: Again the difference between erroneous and error-free value states the error. (4) and (5) Using the fact that R A = D B + 2d AB it follows: And since D B d AB in realistic scenarios, we get the approximation: With clock-drift-error the worst value ( A − B ) can take on is 40 1000000 , so the worst case error introduced can be calculated as: We observe that the clock error is only affecting the measurement during D B (on both clocks) and does not accumulate over the whole operation time. Nevertheless, we still consider the system too error prone in most cases since even a D B of one millisecond causes already six meters of error. A similar analysis is shown in [ Similar to the previous method we can also calculate the error margin. First, we create a clock error model for this method like in (II-A):R And by using (6) and (7) we derive: Again the difference between erroneous and error-free value states the error.
We then add and subtract to the inner brackets D B respectively D A : d AB is in order of magnitude of nanoseconds and multiplied with a ≈ 20ppm value, so it follows that the second term is in sub-picosecond order of magnitude. Even under multiplication with the large value of c, this would leave that part of the term as not significant for our accuracy requirements. Therefore only the first part of the term is relevant to us: Again assuming ±20ppm as drift error (comp. Section II-A), the worst case value can then be calculated: Where ( A − B ) can take on the value 40 1000000 in the worst case. So as long as the difference |D A − D B | is relatively small, we can assume a very low error.
In the following, we denote this method as Symmetrical Double Sided Two Way Ranging (SDS-TWR). With this method, it is at least in theory, possible to eliminate the drift error completely by selecting D A and D B to be identical. However, this is, in reality not possible (e.g. due to inaccuracy of scheduling sending time). To remove this requirement, the asymmetric approach was developed.
2) Asymmetric Formula: Keeping the difference |D A −D B | small is not always possible or desired (for instance through technical limitations of the measuring/processing device). To address those restrictions, Neirynck et al. [8] developed a different (asymmetric) formula for the same scheme: AB := c · d AB (11) Fig. 3) When this adjusted formula is applied, we refer to the method as Asymetric Double Sided Two Way Ranging (asym-DS-TWR). The formula is in the following proven to be more resilient to differences between D A and D B . Using the same clock error model as for the symmetric solution (8) and applying it to (9) we define: And equivalently using (10) we derive: With (11) it follows the definition: The difference between erroneous and error-free value states the absolute error.Ã (9) and = c · B d AB using (10) Like in (12) we can combine those: So in the worst case we can assume to have an error of 20 1000000 · AB which is non-significant in almost all cases. This is achieved without having similar D A and D B . It is important to note that we assumed a constant clock drift during the time of measurement in our clock-model (II-A) .

IV. TIME DIFFERENCE OF ARRIVAL
Beside the ToA methods described there is the group of TDoA-based methods.
In contrast to ToA, TDoA methods have less strict device capability requirements. For example, some of the following methods allow to position Tags which are not actively responding in reaction to the Anchors' signals, while some methods allow the Anchor network to stay silent (no transmission) during positioning. A few beneficial features resulting from that are for instance the possibility to increase the number of Nodes that are simultaneously positioned or the ability to position devices without their knowledge or devices which are incapable of measuring time. The difference between ToA and TDoA becomes clear when looking at an example for a simplified version of a TDoA method.

A. Simple TDoA
Simple-TDoA is a method in which we do not measure the ToF between two devices. Instead, we measure the difference in distances/time between each of two devices X and Z to one device Y (comp. Fig. 4). This value is called a Time-Difference-of-Arrival-or short TDoA-value and is in this document denoted as T Y XZ . The mathematical definition of this TDoA value is: The simplest setup in which we would effectively gather that value would consist of three perfectly synchronized and driftfree devices A, B, S from which S transmits a message at a time t 1 , and the signal arrives at A at time t 1 , and at B at time t 2 as depicted in Fig. 5 We can then calculate: The transmitting device S is here interpreted as Tag while A and B are operating as Anchors. Multiple such measurements on additional Anchor devices (with known positions), in relation to the same Tag, would allow to apply hyperbolic solver algorithms like Chan and Ho [2] to determine the Tags position.
When calculating the error of this setup we have to assume that since the last perfect synchronization (t = 0), drift effects have been accumulated by the individual clocks.
As with ToA methods previously we now primarily define our erroneous model like in (II-A): And using (14):

Fig. 6. Whistle
Again the difference between erroneous and error-free value states the error.T Using the fact that t 2 = t 1 + T S AB we can write AB is in order of magnitude of nanoseconds and is multiplied with a ≈ 20ppm value the second part of the term is in sub-picosecond order of magnitude. Therefore only the first part of the term appears to be relevant, and we can approximate it with: That means that we have to assume a worst-case error of ≈ 40 1000000 · t 1 . Which makes the method already after a short time of operation unusable for realistic scenarios.

B. Whistle
To resolve that issue of fast degrading synchronization. Xu et al. [5] proposed a method called Whistle. Whistle tries to reduce the timespan in which the synchronization drift can occur. That is achieved by adding another signal into the simple TDoA scheme as shown in Fig. 6 This additional message exchange between A and B can be interpreted as a form of "resynchronization" between both devices. According to Xu et al. [5] the TDoA value between those devices can now be calculated by: The Anchor that is replying (here B) is called Mirror. Note that we require that the distance between the Mirror and the other Anchor devices is known. Now we calculate the error resulting from this improved protocol. First, we define the erroneous model like in (II-A): AB are in order of magnitude of nanoseconds. And since those are multiplied with a ≈ 20ppm value in the first part of the term, that part of the term is in sub-picosecond order of magnitude. Therefore only the second part of the term is relevant.
Assuming the same realistic worst case drift values as previously we end up with a worst-case error estimate of D B · 40 1000000 . This is an improvement compared to the simple TDoA method since the error is not dependent on synchronized clocks and is therefore also not accumulating. On the other hand, a typical value for D B is one millisecond which leads already to 40 nanoseconds ≈ 12 meters of error. This approach is therefore not practically usable with radio platforms that operate with industry standard clocks.
The essential idea of DJKM is to execute an optimized version of SDS-TWR in a group of Anchor devices. While doing so, it is possible for eavesdropping Tags to collect TDoA information to those Anchors. To simplify the explanation of the method the sequence diagram Fig. 7 was reduced to two Anchors (one of them could be interpreted as "acting Mirror") and a single Tag. For details about the interaction between more than two Anchors we refer to the original paper [7].
The authors derived the following formula to calculate the TDoA values: It is important to note that Tag T is only in receiving mode which is an essential functional difference to Whistle where the Tag S is at all times in transmit mode only. Moreover, when comparing DJKMs TDoA calculation with the one from Whistle (16) and comparing the modes of operation of Anchors and Tags between both method DJKM appears to us like an "inverse Whistle" method. Especially in Ultra Wide Band (UWB) it is common that transmission operations use significantly less energy than receiving (comp. [14,Sct 7.2]), so for battery driven Tag devices the Whistle approach is consuming less energy. Now we demonstrate that the worst-case error for DJKM is identical to Whistle. Again we first define the erroneous model like in (II-A):R The difference between erroneous and error-free value states the error.T Using the fact that R T = D B + d AB + T T AB : For the same reason we described in Whistle (IV-B) we can neglect the first part as not significant and so approximate the term with.
When choosing worst-case epsilons, we end up with the worst case estimate D B · 40 1000000 . That is identical to the estimate for Whistle.
Djaja-Josko and Kolakowski [7] also point out that their scheme simultaneously allows for the calculation of SDS-TWR values between certain Anchors in the ranging scheme. We have shown that the TDoA values of DJKM have a similar error as Whistle. That means that all described methods of synchronization-free TDoA are still prone to clock-drift errors on a scale too large for most radio-based applications.
To circumvent these problems with TDoA and to make the methods more applicable in practice a new approach was proposed by Tschirschnitz and Wagner [6]. This method called Double Pulsed Whistle (DPW) introduces a second pulse to the known Whistle scheme and uses symmetries to reduce the clock error significantly. The error reduction uses similar effects like the methods of DS-TWR. The transmission scheme is displayed in Fig. 8.
Using the findings from Tschirschnitz and Wagner [6] the TDoA value can then be calculated as follows: Using R A + D A = R B + D B we conclude: Again we use the same erroneous clock model as in (8) conforming to our model design in (II-A) to define the erronous timespans (R A ,D A ,R B ,D B ). Then applying it to (20) we define: And equivalently using (21) we derive: We transform the term with denominatorR B +D B : Adding and subtracting (1 + A )d AB to the term brings: Then substituting with (20) delivers: The difference between the erroneous and error-free value is the error:T The fact that T S AB ≤ d AB justifies the last step here. That is true since the TDoA (T S AB ) can never grow larger than the distance between the measuring Anchor pair (d AB ).
Equivalently we can apply this to the term with the divisor R B +D B : Combining the two fraction like in (22) we end up with: We observe that the error is now only depending on the distance value d AB which is in order of nanoseconds for typical positioning setups. We further multiply it with 's which are in magnitudes of ±20ppm. That means that the error is in no significant magnitudes.

V. SUMMARY AND CONCLUSION
In the Table I all of the methods described in this paper are listed. Their worst-case clock-error and the required device capabilities for Anchors and Tags are listed for each method. For better comparison of the worst-case clock-drift errors the methods are divided into ToA and TDoA methods. On the right, the interface requirements for Anchor-and Tag-Nodes are noted for each method.
The table reiterates that all methods which use doublepulses like DPW and asym-DS-TWR are much more robust against clock errors. Especially for radio based ToF methods like UWB it is important to reduce these error sources because the contributions of the clock error in Whistle and DJKM could significantly distort the result.
In future work, approaches like DJKM can be extended to incorporate the Double-Pulse similar to the transition from

Clock-Drift induced Error
Anchor Nodes Tag Nodes Simple ToA ((III-A)) t 1 · ( B − A ) RX TX TWR (III-B) This approach is related to our efforts in designing Double Pulsed Positioning [15] a novel infrastructure-less and synchronisation-free ToF method.