# PEiD: Precise and Real-Time LOS/NLOS Path Identification Based on Peak Energy Index Distribution
## 3 Preliminaries
### Explore Randomness of NLOS Patlhs  
Due to the bandwidth limitation, the envelope of CIR is not a prominent feature for LOS/NLOS identification. To break the situation and fully exploit CIR, we focus on the time index of peak energy and study its distribution characteristics. The intuition is that the randomness of NLOS paths still resides in CIR despite the poor time resolution and limited bandwidth of commodity WiFi. Since peak energy in CIR represents the principal component of signal arrived, we think that its time index can be used as a fair indicator to capture the change of channel properties.  
To validate this idea, we conduct experiments with different scenarios (two rooms of Lab 1 and Lab 2) and equipment (two kinds of PC). For each configuration, we apply the same experimental settings introduced above and continuously collect 300 packets in 0.6 s (500 packets per second) under both LOS/NLOS paths. In each measurement, we obtain 300 CIR samples after applying the iFFT. Then, we record the number of time bins where peak energy appears (seven for the case of Figure 1a and nine for Figure 1b) and thus obtain a sequence of time indexes. For simplicity in description, we use the term SIPE (Sequence of the Index corresponding to Peak Energy) to denote it. We study the statistical characteristics of these sequences and plot their distributions (peak energy index distribution) in Figures 2 and 3. The STD of SIPE is calculated for each configuration.  
Figure 1: The energy distribution of CIR obtained from a single packet: (**a**) LOS case; (**b**) NLOS case.  
Huge differences can be seen from the peak energy index distribution obtained in the two cases. First, the time index obtained in LOS paths tends to be a fixed value. For all four configurations in LOS paths, there are always over 80% of packets that reach peak energy in the same position. However, the maximum number of the identical time index in NLOS paths is no more than 50% (except for the case of Figure 2b). Second, the range of time index obtained in NLOS paths is generally broader than in LOS paths. Most peak energy in LOS paths only appears in three of the time bins, but the NLOS path extends that to five or seven. Finally, the STD of SIPE obtained in NLOS paths is higher (around twice) than in LOS paths, indicating a very noisy channel property. It seems reasonable to exploit the STD as a quantitative indicator of LOS/NLOS identification.  
The above experimental results demonstrate the randomness of the NLOS path and verify its universality across different environments and devices. The selected feature, peak energy index distribution, reveals the noise level of two distinct channel states. It works because the peak energy time index of CIR is closely related to ToA. With a sufficient capacity of equipment, we can derive the propagation distance based on the time index and speed of light [43]. However, it is impossible to build a ToA or range estimation model for commodity WiFi. As a result, we directly explore the peak energy index distribution and discuss its feasibility for LOS/NLOS identification, providing a solution for devices with limited bandwidth.