# Robust Wireless Local Area Networks Based on Compressed Sensing
## 3 Proposed Algorithms
### RTNTM Algorithm  
The proposed algorithm is based on a conventional Fast Fourier Transformation (FFT) to check signal sparsity in a WLAN [31]. These signals have \(K\) non-zero coefficients and (N-K) zero coefficients with K \(\leq\) M, and can be well recovered using \(M\) projections or measurements, such that K \(\leq\) M << N. As a result, the number of non-zero coefficients is small; the CS theory can, therefore, be applied to reduce the load of sampling rate in a WLAN. Typically, in a WLAN, we have the following properties:* There is a total of N wireless nodes randomly located in a WLAN. * We denote K as the number of random sparse wireless nodes. * K is a random number and is much smaller than N.
* We denote [D]N\({}_{\times 1}\) as the event vector. * Each component of [D]N\({}_{\times 1}\) has a random value. * Obviously [D]N\({}_{\times 1}\) is a sparse vector since K \(\leq\) N
* There are M active monitoring wireless nodes trying to capture \(K\) events. * The number of events K, the number of active wireless nodes \(M\), and total of sources N, have the following relation [32]: \[\text{K}\leq\text{M}<<\text{N}\] (1) Based on the proposed algorithm:
* We are able to organize a network traffic framework to help in ensuring the quality of service in a given wireless local area network. * We can classify network traffic to allow us to organize traffic of packets into the traffic of packet classes or categories, on the basis of whether the traffic of packets matches specific criteria. * We can classify network traffic as the foundation for enabling many QoS features in the WLANs. * We can classify network traffic to a set of group traffic classes in order to apply specific QoS treatments. The QoS treatments might include faster forwarding packets from wireless nodes by intermediate wireless routers and switches, or reduced probability of the traffic being dropped due to lack of buffering resources. * We can identify and categorize network traffic into traffic classes for different types of networks, effectively separating network traffic into different paths. * We can classify network traffic by using class maps and policy maps with the Modular Quality of Service Command-Line Interface (MQC) method, in order to improve the level of QoS. The RTNTM method works based on the following steps:  
* Consider the pairs of measured QoS and the multiple attribute values as input for the CS. * Estimates a multiple attribute compressed vector in which each element indicates the degree of QoS degradation caused by each wireless networking segment or device. * Apply the estimated multiple attribute vector to identify the cause of QoS degradation. The proposed algorithm is comprised based on the following steps:  
* Apply segmentation algorithm to the WLAN in order to define the required number of segments [32]. The number of segments is calculated based on the following equation:  
\[\text{M}=\text{C}\log\left(\text{5N}\right)\text{ with C between 20--25} \tag{2}\]  
which M is the number of segments and N is the number of wireless nodes in the WLAN. * Collect QoS vector for each segment. * Generate compressed [QoS]M\({}_{\times\text{N}}\) matrix. * Check the performance of the compressed [QoS]M\({}_{\times\text{N}}\) matrix based on the following condition: \[\left(\text{1}-\text{C}\right)\parallel\left[\text{QoS}\right]_{\text{M} \times\text{N}}\text{Y}\parallel\text{\text{\  
* Calculate Packet Loss Matrix (PLS) and Mean Opinion Score (MOS). PLS is a quantitative measure of information lost over a WLAN and MOS is a good measure of QoS. * Check the performance of the network based on MOS number. Table 1 compares the different quality levels of a WLAN to the different number of MOS. The proposed algorithm is based on the following sub-steps:  
1. Estimate the end-to-end QoS in the normal state. 2. Calculate the degree of end-to-end QoS degradation by subtracting the estimated QoS in the normal. 3. Subtract a baseline from then apply the CS to the data after subtracting it. 4. Construct an estimation of QoS. 5.