0 Bewertungen0% fanden dieses Dokument nützlich (0 Abstimmungen)

155 Ansichten66 Seiten© Attribution Non-Commercial (BY-NC)

PDF, TXT oder online auf Scribd lesen

Attribution Non-Commercial (BY-NC)

Als PDF, TXT **herunterladen** oder online auf Scribd lesen

0 Bewertungen0% fanden dieses Dokument nützlich (0 Abstimmungen)

155 Ansichten66 SeitenAttribution Non-Commercial (BY-NC)

Als PDF, TXT **herunterladen** oder online auf Scribd lesen

Sie sind auf Seite 1von 66

11n

by JIN Pengchong (05723724) ZHANG Hong (05710129)

A Final Year Project Report submitted to the Department of Electronic and Computer Engineering Bachelor of Engineering

Department of Elctronic and Computer Engineering The Hong Kong University of Science and Technology

April 2009

Hong Kong

Abstract

IEEE 802.11n, a new amendment to IEEE 802.11 Wireless LAN standards, provides both physical layer and MAC enhancements by making use of Multiple Input Multiple Output (MIMO) technology. In this project, our objective was to create a simulation platform for the PHY layer of 802.11n. To meet this objective, we reviewed the newly proposed standard, focusing on the PHY-level design such as MIMO and Orthogonal Frequency Division Multiplexing (OFDM). We studied the MIMO channels specied by 802.11 TGn and developed a simulation system which integrated MIMO with OFDM and Forward Error Correction Code (FEC). We also designed a program which gives system optimal system conguration (in term of code rate and modulation scheme, etc.) and the achievable speed for any channel model. We presented our simulation on a Graphical User Interface (GUI) programmed using MATLAB. By the Object-Oriented Programming (OOP) approach, our program can be adopted by the future communication engineers and researchers for further modications.

Keywords

Wireless Communications, IEEE 802.11n, WLAN, MIMO, OFDM, Performance comparison

ii

Acknowledgements

It is our pleasure to thank the many people who made our project possible. It is dicult to overstate our gratitude to my supervisor, Prof. Ross Murch. With his kind support, his insightful guidance and his great eorts to explain things clearly and patiently, he helped to make our journey of research and development be of great interest. During our report-writing period, he inspired us with a number of ideas, provided us with a lot of suggestions and made amendments to the article. We would have been lost without him. I would like to thank the people in the wireless group in HKUST, especially Prof. Roger Cheng, Prof. Wai Ho Mow and Prof. Vincent Lau, for useful courses they oered and for their kind assistance with giving wise advise, explaining concepts patiently, even debugging our programs. It is our great honor and good fortune to meet with them and we really appreciate all the help they gave. Lastly, and most importantly, we wish to thank my parents. To them we dedicate this report.

iii

Contents

Abstract Acknowledgements List of Tables List of Figures 1 Project Overview 1.1 1.2 1.3 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Aim and Objectives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . System Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1.3.1 1.3.2 1.3.3 1.4 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Function Blocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Design Specications . . . . . . . . . . . . . . . . . . . . . . . . . . .

Report Outline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

2 Background 2.1 2.2 History of IEEE 802.11 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Technique Overview of 802.11n D3.03 . . . . . . . . . . . . . . . . . . . . . . 2.2.1 2.2.2 Layered Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Layer Management . . . . . . . . . . . . . . . . . . . . . . . . . . . .

iv

Orthogonal Frequency Division Multiplexing (OFDM) . . . . . . . . PLCP frame . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Multiple Input Multiple Output (MIMO) . . . . . . . . . . . . . . . .

10 11 12 15 15 16 17 17 18 18 18 19 20 20 21 22 23 25 27 27 28 30 32 32 32

3 Methodology 3.1 MIMO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.1.1 3.1.2 3.1.3 Multiplexing Gain . . . . . . . . . . . . . . . . . . . . . . . . . . . . Diversity Gain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.1.3.1 3.1.3.2 3.1.3.3 3.2 Maximum-Likelihood Detection . . . . . . . . . . . . . . . . Zero-Forcing Detection . . . . . . . . . . . . . . . . . . . . . V-BLAST Detection . . . . . . . . . . . . . . . . . . . . . .

Channel Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.2.1 3.2.2 3.2.3 3.2.4 AWGN Channel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Rayleigh Fading Channel . . . . . . . . . . . . . . . . . . . . . . . . . Frequency Selective Channel . . . . . . . . . . . . . . . . . . . . . . . Correlated MIMO Channel . . . . . . . . . . . . . . . . . . . . . . . .

OFDM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Modulation and Calculation of theoretical BER . . . . . . . . . . . . . . . . Coding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3.5.1 3.5.2 Encoder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Viterbi Decoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

3.6

Power and Random Variable . . . . . . . . . . . . . . . . . . . . . . . Program of Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . Numerical Method for Optimal Conguration . . . . . . . . . . . . .

33 34 37 39 41 41 42 45 45 45 46 47

5 Results and Discussion 5.1 Simulation results about modulation schemes and channel . . . . . . . . . . 5.1.1 5.1.2 5.1.3 5.1.4 QPSK over AWGN . . . . . . . . . . . . . . . . . . . . . . . . . . . . QPSK over Rayleigh . . . . . . . . . . . . . . . . . . . . . . . . . . . MIMO, Rayleigh Channel and Detections . . . . . . . . . . . . . . . . MIMO, Frequency Selective Channel, OFDM with Zero Forcing Detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.5 5.1.6 5.2 5.3 5.4 MIMO-OFDM With various Setting . . . . . . . . . . . . . . . . . .

47 48 48 49 51 52 55 56

Performance of V-BLAST . . . . . . . . . . . . . . . . . . . . . . . .

Simulation results about coding . . . . . . . . . . . . . . . . . . . . . . . . . Simulation results about Space Time Block Code . . . . . . . . . . . . . . . Optimization & Planning . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

6 Conclusions Bibliography

vi

List of Tables

2.1 2.2 2.3 5.1 Modulation-dependent parameters in 802.11n [2] . . . . . . . . . . . . . . . . Major specications for the OFDM PHY in 802.11n [2] . . . . . . . . . . . . MCS parameters for optional 40 MHz, Nss = 4, UEQM in 802.11n [2] . . . . MCS Coverage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 13 14 54

vii

List of Figures

1.1 1.2 2.1 2.2 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 The block diagram at transmitter side . . . . . . . . . . . . . . . . . . . . . The block diagram at reciever side . . . . . . . . . . . . . . . . . . . . . . . 2 2 8 12 16 16 17 20 22 23 23 26 27 28 28 30 32 33 39

Multipath Rayleigh Fadin . . . . . . . . . . . . . . . . . . . . . . . . . . . . Frequency selective response . . . . . . . . . . . . . . . . . . . . . . . . . . . A typical OFDM transmitter . . . . . . . . . . . . . . . . . . . . . . . . . . . A typical OFDM reciever . . . . . . . . . . . . . . . . . . . . . . . . . . . . . The Gray Coded constellation for 16 QAM . . . . . . . . . . . . . . . . . . . A example of the convolutional encoder structure . . . . . . . . . . . . . . .

3.10 State transition diagram for the convolutional code in Figure 3.9 . . . . . . . 3.11 Trellis diagram for the convolutional code in Figure 3.9 . . . . . . . . . . . . 3.12 The structure of Alamouti Code . . . . . . . . . . . . . . . . . . . . . . . . . 4.1 4.2 4.3 The structure of the Correlator Receiver . . . . . . . . . . . . . . . . . . . . The simplied Correlator Receiver for BPSK modulation . . . . . . . . . . . The convolutional encoder specied by 802.11n viii . . . . . . . . . . . . . . . .

4.4 4.5 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9

The puncture pattern of rate 3/4 code . . . . . . . . . . . . . . . . . . . . . The screen capture of GUI . . . . . . . . . . . . . . . . . . . . . . . . . . . . BER of QPSK over AWGN Channel . . . . . . . . . . . . . . . . . . . . . . BER of QPSK over Rayleigh Channel . . . . . . . . . . . . . . . . . . . . . . BER of MIMO Over Rayleigh Channel with ZF Detection . . . . . . . . . . BER of OFDM over FS Channel . . . . . . . . . . . . . . . . . . . . . . . . . BER of MIMO-OFDM over various channels specied in [1] . . . . . . . . . BER of BPSK over AWGN Using Convolutional Code . . . . . . . . . . . . . BER of BPSK over Rayleigh Using Convolutional Code . . . . . . . . . . . . BER of BPSK over Rayleigh Using Block Code . . . . . . . . . . . . . . . . BER of 2 1 Alamouti code over Rayleigh Fading Channel . . . . . . . . . .

40 42 45 46 47 48 49 50 50 51 51 52 53 54

5.10 BER of 2 2 Alamouti code over Rayleigh Fading Channel . . . . . . . . . . 5.11 Path Loss vs. Distance in Channel Model B . . . . . . . . . . . . . . . . . . 5.12 MCS Coverage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

ix

1.1

Introduction

Multiple Input Multiple Output (MIMO) is a new technology which can signicantly increase the capacity of wireless networks. It thus can be used to fulll the need of next generation wireless communication systems. MIMO is adopted in IEEE Standard 802.11n D3, the newest amendment to the most widely used Wireless LAN (WLAN) standard 802.11. In our project we developed an applicantion with the Graphic User Interface (GUI) using MATLAB, which can simulate functions of real 802.11n wireless systems. We used our program to simulate the system under dierent conditions and obtained the performance dierences. Based on simulation results we then designed a couple of algorithms to nd the optimal system setting for certain conditions. The results will be useful for site planning and system improvement.

1.2

The ultimate aim of this project was a MATLAB application which is able to simulate the PHY layer of the IEEE 802.11n standard. This program can be used as a testbed

for dierent algorithms. We used our program to do simulations and obtain the optimal system setting, conguration on transmission power, coding scheme and modulation scheme. Furthermore, the program can be used as a part of a software-dened radio, which facilitates the implementation of cognitive radio. The objective of the project was to provide a userfriendly application for algorithm designers to test the performance of their algorithms under dierent channel model.

1.3

1.3.1

Block Diagram

The block diagram for a MIMO wireless communication system is shown in Figure 1.1 and Figure 1.2, illustrating transmitter and receiver respectively, between which is the communication channel.

Figure 1.2: The block diagram at reciever side The bit sequence is generated by the information source which contains information to be communicated. After the encoding and modulation processes, the bit sequence becomes

the symbol stream. The symbol stream passes through the channel where it experiences interference from the environment and the noise at the receiver. As a result, detection is needed at the receiver side. The detected symbols will be demodulated and decoded and nally sent to the data sink. This block diagram demonstrates the information ow of a communication system. According to this general diagram, the simulation program has been developed and each corresponding function block is added.

1.3.2

Function Blocks

Source & Sink The information source generates bit sequence randomly. At the sink the received bit sequence is compared with the original one. We then obtain the Bit Error Rate (BER) to evaluation the system performance. Coding Coding protects the information from being corrupted and it can provide diversity to the system when the channel is the wireless fading channel. By using dierent codes we can obtain lower BER at the expense of a little bit lower transmission date. In our program, we used the convolutional code specied in the standard. Modulation Modulation is the process that converts bit sequences to symbols, which is more feasible to be transmitted. Dierent modulation schemes enable us to tradeo between BER and transmission speed. Modulation schemes supported by our program are BPSK, 4 QAM, 16 QAM, 64 QAM. Then the original modulated symbol will be further modulated to OFDM symbols. Detection For MIMO system detection is needed. We have implemented two detection methods, namely

Zero-Forcing and V-BLAST. Channel Model In our program, we adopted 6 delay proles specied by TGn (target group n) [1] for dierent environment, they are listed below. Model A (optional, should not be used for system performance comparisons), at fading model with 0 ns rms1 delay spread (one tap at 0 ns delay model). This model can be used for stressing system performance, occurs small percentage of time (locations). Model B with 15 ns rms delay spread. Model C with 30 ns rms delay spread. Model D with 50 ns rms delay spread. Model E with 100 ns rms delay spread. Model F with 150 ns rms delay spread. Since Model A is not so realistic, we will not implement it. We will use the MATLAB program written by L. Schumacher to generate the channel matrix [11].

1.3.3

Design Specications

In this project, we used The MathWorksTM MATLAB R2008a as the programming language. In addition to the basic functions in MATLAB, some functions in special toolboxes such as Digital Processing ToolBox, Communication ToolBox, were also used to simplify our code.

1.4

Report Outline

The rest of the report consists of ve chapters. They are Background, Methodology, Implementation, Results and Discussion and Conclusion.

1

In Chapter 2 Background, we will introduce the technical background of MIMO and IEEE Std. 802.11n. In Chapter 3 Methodology, we will discuss the methods we followed to implement our project. In Chapter 4 Implementation, we will explain how we implemented the formulas and design by programming, and introduce our optimization algorithms. In Chapter 5 Results and Discussion, we will present the results of simulation and optimization, then analyze the data. In Chapter 6 Conclusion, a conclusion is given and we summarize the whole project.

Chapter 2 Background

Driven by the explosive increase in demand for tetherless connectivity, the dramatic progress in VLSI technology and the success of second generation (2G) digital wireless standards, the research thrust in the past decade has led to a much richer set of perspectives and research activities has become more and more active. Future wireless networks will allow people on the move to communicate with anyone, anywhere and at any time using a range of multimedia services. However, there are several technical challenges that had to be overcome in order to make our imagination a reality. The time variation of the channel strengths due to the small-scale eect of multipath fading, as well as larger scale eects such as path loss of the transmission power and shadowing by obstacles in dierent environmental setting can signicantly inuence the performance. The interference from dierent users in the system makes the situation even more dicult. Dierent techniques are proposed and among them are Multiple Input Multiple Output (MIMO) and Orthogonal Frequency Division Multiplexing (OFDM). And such techniques has been standardized and IEEE 802.11 is the famous one which is widely used nowadays mainly in Wireless Local Area Network (WLAN).

2.1

Since 1990s, WLANs for the 900 MHz, 2.4GHz and 5GHz license-free ISM (Industrial, Scientic and Medical) bands have been launched by using a range of proprietary techniques [14]. In June 1997, the Institute of Electrical and Electronics Engineers (IEEE) dened an international standard for WLAN, called 802.11. This standard species the Medium Access Control (MAC) protocols and three dierent Physical Layers (PHYs), two of which are based on radio communication in 2.4 GHz band (the other uses infrared light). All the PHYs support a date rate of 1 Mbps and optionally 2 Mbps. Upon the demand for higher bit rates, a new standard was dened, named IEEE 802.11b which describes a PHY providing a more robust rate up to 11 Mps. Motivated by the opening of new unlicensed spectrum in the 5 GHz, a new IEEE 80.11 working group, Task Group a (TGa), began to work on the third generation (3G) WLANs. Orthogonal Frequency Division Multiplexing (OFDM) was selected and the newly dened standard IEEE 802.11a was available in 2000 supporting data rates between 6 and 54 Mbps. A similar standard for 2.4 GHz band, namely IEEE 802.11g, was nished in 2003. At the same year, Task Group TGma was authorized to created a single document that merged 8 amendments (802.11a, b, d, e, g, h, i, j) with the base standard. On approval on March 08, 2007, this standard was renamed to the current base standard IEEE 802.11-2007. 802.11n is a proposed amendment which improves the previous standards by deploying Multiple Input Multiple Output (MIMO) and many other newer features. It will signicantly increase maximum PHY data rate from 54 Mbps to a maximum of 600 Mps. While enterprises have already begun migrating to 802.11n networks based on the Draft 2 of the 802.11n proposal, the TGn workgroup is not expected to nalize the amendment until December 2009.

2.2

2.2.1

Layered Structure

In this section, we introduce the essential functions and the basic layered structure in 802.11n. 802.11n adopts the separated layered architecture which fully species Physical layer (PHY) and Medium Access Control (MAC) sublayer. In PHY layer, there are further two separate sublayers, namely Physical Layer Convergence Procedure (PLCP) and Physical Medium Dependent (PMD). Both the MAC sublayer and PHY conceptually include management entities, called MAC Sublayer Management Entity (MLME) and Physical Layer Management Entity (PLME), respectively. These entities provide the layer management service interfaces through which layer management functions can be invoked. The basic layered structure of 802.11n is shown in Figure 2.1 below.

Figure 2.1: 802.11n Layered Structure MAC sublayer This service provides peer Logical Link Control (LLC) entities with the ability to exchange MAC protocol data units (MSDU). To support this communication, the local MAC uses the underlying PHY-level services dened in PMD to transport an MSDU to another peer MAC entity, where the data will be delivered to the peer LLC. By default, MSDU transport is on a best-eort basis. However, the Quality of Service (QoS) facility uses a trac identier (TID) to specify dierentiated services on a per-MSDU basis. There are no guarantees that

the submitted MSDU will be delivered successfully. PLCP sublayer In order to allow the IEEE 802.11 MAC to operate with minimum dependence on the PMD sublayer, a PHY Physical Layer Convergence Procedure (PLCP) sublayer is dened. This function simplies the PHY service interface to the IEEE 802.11 MAC services. PMD sublayer The Physical Medium Dependent (PMD) sublayer provides a means to send and receive data between two or more stations. All the basic transmission functions and modulation schemes are specied here. This project is mainly concerned with the PMD sublayer. The communication with MAC Sublayer will be done through PHY SAP in PMD, which provides several services to MAC Sublayer. After receiving these primitives from PHY SAP, PHY Sublayer will take action according to the setting of PLME MIB entity. The various transmission modes, encode/decode algorithms and functions like space-time code, beamforming, antenna diversity will be implemented here. The schemes are implemented as functions here and they are ordered for each transmission according to PLME MIB. Once the functions are implemented, the corresponding MIB(Management Information Base) entries in PLME will be changed.

2.2.2

Layer Management

In order to make the MAC sublayer and PHY operate correctly, two layer management entities, MAC Sublayer Management Entity (MLME) and Physical Layer Management Entity (PLME), are dened, providing the layer management interfaces using the layer management functions. In order to provide correct MAC operation, a Station Management Entity (SME) is present within each station as well, which controls the physical layer by setting the entries in PLME MIB table through PLME SAP function. PLME management entity

Here we further explained the control functions in PLME. PLME is a database that contains physical layer MIB, the MIB entries are specied in Annex D of IEEE Std 802.11-2007, with additional entries in Annex D, IEEE Std 802.11n D3. The PLME MIB will provide two interfaces, one for the PMD layer to read data, in order to decide which transmission functions to use, one for SME to access, to implement the algorithms like antenna diversity, and to change transmission modes. For transmission side and receive side the PLME MIB is same.

2.2.3

In this section, we oer readers an overview of Orthogonal Frequency Division Multiplexing (OFDM) in 802.11n. The OFDM system provides a WLAN with data payload communication capabilities of 6, 9, 12, 18, 24, 36, 48 and 54 Mbps. The OFDM system setups 64 subcarriers but it only uses 52 subcarriers because of the fact that the lter output for OFDM processing can not be ideally at. So in order for each OFDM subcarrier to see a relative at frequency response, the subcarriers near two sides of the frequency band are dropped. Among these 52 subcarriers, 48 subcarriers are used to carry the data symbols and the subcarriers at the position -21, -7, 7 and 21 are used for the polit. Each subcarrier is associated with one modulated symbol using binary or quadrature phase shift keying (BPSK or QPSK) or using 16- or 64 quadrature amplitude modulation (16 QAM or 64 QAM). It is done by the conversion process from the encoded and interleaved binary seial input data into complex numbers representing constellation points. The conversion is performed by the Gray-coded constellation mapping and the constellation is multiplied by a normalization factor to ensure the normalized constellation energy. Forward Error Correction (FEC) coding (convolutional coding) is also used with a coding rate of 1/2, 2/3 or 3/4. We list the modulation and coding schemes that 802.11n supports in Table 2.1. For OFDM used in 802.11n, shifting the time by Tguard creates the circular prex to

10

subcarrier (NBPSC)

OFDMsymbol (NCBPS)

1 1 2 2 4 4 6 6

Table 2.1: Modulation-dependent parameters in 802.11n [2] avoid Intersymbol Interference (ISI) from the previous frame. Particularly, three kinds of Tguard are dened: for the short training sequence (= 0 s), for the long training sequence (= TGI2 ) and for data OFDM symbols (= TGI ). These timing-related parameters can be seen in the Table 2.2. Major specications for the OFDM PHY in the standard are listed in Table.

2.2.4

PLCP frame

Next, we briey explain the frame format of PLCP protocol data unit (PPDU). One PPDU frame includes the OFDM PLCP preamble, OFDM PLCP header, PLCP service data unit (PSDU), tail bits and pad bits. Figure 2.2 shows the format of the PPDU frame. The following elds: LENGTH, RATE, a reserved bit, an even parity bit, and the SERVICE eld are included in the PLCP header. In terms of modulation, the LENGTH, RATE, reserved bit, and parity bit (with 6 zero tail bits appended) constitute a separate single OFDM symbol, denoted SIGNAL, which is transmitted with the most robust combination

11

Figure 2.2: 802.11n PPDU Frame Format of BPSK modulation and a coding rate of R = 1/2 since it contains critical parameters for decoding the following data. For example, RATE denes the data rate for this transmission and LENGTH denes the length of the frame. The SERVICE eld of the PLCP header and the PSDU (with 6 zero tail bits and pad bits appended), denoted as DATA, are transmitted at the data rate described in the RATE eld and may constitute multiple OFDM symbols.

2.2.5

Multiple Input Multiple Output (MIMO) technique is a newly added feature in 802.11n. It is specied in the section High Throughput (HT) PHY specication in the draft standard. The MIMO technique in 802.11n has extended up to 4 spatial streams, operating in 20 MHz or even 40 MHz bandwidth. These features are capable of supporting data rates up to 600 Mb/s. Here we explained some data in Table 2.3 specied in the HT PHY section in the standard to illustrate the dramatic increase of data rate by using multiple spatial streams. For example, for the scheme indexed by MCS 76, 4 data streams are modulated by 64 QAM, 64 QAM, 64 QAM and 16 QAM respectively with the convolutional code rate equal to 3/4. The number of coded bits per single carrier is 22 and the number of complex data numbers is 108. After the proper conguration according the data shown in the table, the data rate can reach up to 495 Mbps, signicant increase from the Single Input Single Output (SISO) case.

12

Parameter

NSD : Number of data subcarriers NSP : Number of pilot subcarriers NST : Number of subcarriers, total F: Subcarrier frequency spacing TF F T : Inverse Fast Fourier (IFFT) Transform / Fast (FFT)

48

52 (NSD + NSP )

52 (NSD + NSP )

52 (NSD + NSP )

16s(TSHORT +TLONG )

32s(TSHORT +TLONG )

64s(TSHORT +TLONG )

4.0s(TGI + TF F T )

8.0s(TGI + TF F T )

16.0s(TGI + TF F T )

SIGNAL BPSK-OFDM symbol TGI : GI duration TGI2 : Training symbol GI duration TSY M : Symbol interval TSHORT : Short training se4s(TGI + TF F T ) 8s(10 TF F T /4) 8s(TGI + TF F T ) 16s(10 TF F T /4) 16s(TGI + TF F T ) 32s(10 TF F T /4) 0.8s(TGI /4) 1.6s(TGI /2) 1.6s(TGI /4) 3.2s(TGI /2) 3.2s(TGI /4) 6.4s(TGI /2)

quence duration

Table 2.2: Major specications for the OFDM PHY in 802.11n [2]

13

MCS Index Stream 1 67 16QAM 68 64QAM 69 64QAM 70 64QAM 71 64QAM 72 64QAM 73 64QAM 74 64QAM 75 64QAM 76 64QAM

M odulation Stream 2 16QAM QPSK Stream 3 16QAM QPSK QPSK Stream 4 QPSK

NBP SC

NSD

NSP

NCBP S

NDBP S

NES

3/4

14

108

1512

1134

283.5

3/4

12

108

1296

972

243

270

QPSK

QPSK

3/4

14

108

1512

1134

283.5

315

QPSK

3/4

16

108

1728

1296

324

360

16QAM QPSK

3/4

18

108

1944

1458

364.5

405

3/4

16

108

1728

1296

324

360

QPSK

3/4

18

108

1944

1458

364.5

405

16QAM QPSK

3/4

20

108

2160

1620

405

450

3/4

20

108

2160

1620

405

450

16QAM

3/4

22

108

2376

1782

445.5

495

Table 2.3: MCS parameters for optional 40 MHz, Nss = 4, UEQM in 802.11n [2]

14

Chapter 3 Methodology

In this section, we will describe the theory and concepts used in our program.

3.1

MIMO

MIMO stands for Multiple Input, Multiple Output, which means instead of only one antenna, there are multiple antennas at both transmitter and receiver side. Here we use a 2 by 2 MIMO for example. The channel can be represented by y = Hx

(3.1)

H=

(3.2)

where x and y are 2 by 1 matrix, representing transmitted and received signal on each antenna. The four entries of the channel matrix H correspond to the channel gains between antennas, as shown in Figure 3.1 [10]. The formula 3.1 and 3.2 can be generalize to any number of transmit and receive antennas. By using MIMO there are two possible gains, multiplexing gain and diversity gain.

15

3.1.1

Multiplexing Gain

To achieve multiplexing gain, multiple independent spatial channels is created (shown in Figure 3.2 [10]). Independent information sequences can be transmitted on each channel at the same time. The maximum number of channels is min(M, N), where M is the number to transmission antennas (Tx) and N is the number of receive antennas (Rx). As min(M, N) increases, the number of spatial channels increase linearly. The system capacity also increases linearly.

Figure 3.2: MIMO multiplexing feature The following operations in linear algebra can help illustrate the feature of the multiple independent channels. By Singular Value Decomposition (SVD) [7], a matrix can be decomposed as followings. H = USV H (3.3)

where U and V are unity matrix of size N N and M M respectively, and the superscript H stands for Hermitian transform. Unity means N N = I. And S is a diagonal matrix. If we process the signal by multiplying U at the transmit side and V at the receive side,

16

H = U H HV = (U H U)S(V H V ) =

s11 0

0 s22

(3.4)

H is a diagonal matrix, with gains s11 and s22 . The channel equation 3.1 will become

y1 y2

s11 x1 s22 x2

(3.5)

3.1.2

Diversity Gain

Instead of two independent information sources, we can send some processed representation of a single information source in order to achieve the diversity. The four channels can be seen as independent faded branches (shown in Figure 3.3. So the MIMO channel now has a diversity order of 2 2 = 4. For the generalized MIMO channel, the diversity order is M N.

3.1.3

Detection

For traditional systems like SISO, the problem of detection does not exist. But for MIMO we have to separate the mixed signals at the receiver side. In the presence of noise, the equation 3.1 becomes y = Hx + n 17 (3.6)

3.1.3.1

Maximum-Likelihood Detection

Maximum-Likelihood is the method which produces the most accurate result. It uses the exhaustive search approach, tries all the possible sent symbols x and nd the most likely one, i.e. the one which minimize the equantion 3.7 |y Hx| (3.7)

The draw back of Maximum-Likelihood method is that the computational complexity is very high. It increases exponentially as modulation size of x increases. For example, from 4QAM to 16QAM, the complexity will increase from by

162 42

3.1.3.2

Zero-Forcing Detection

Zero-Forcing is the simplest way of detection. Denote the inverse matrix of H as G. Simply multiply G to the equation 3.6, we get the equation 3.8 below. y = Gy = x + Gn (3.8)

Zero-Forcing detection is very simple. However, the draw back is that since G is the inverse matrix of H, sometimes entries can be very large. As a result, the noise is sometimes enlarged, which will make the performance worse.

3.1.3.3

V-BLAST Detection

A better approach is to do the detection iteratively. A well known method using this approach is V-BLAST. The philosophy of V-BLAST is based on an interpretation of the channel matrix. Recall the equation 3.2. We can interpret entry h21 as the interference generated by the signal of Tx1 on the Rx2 . If we can subtract the interference when we detect the symbol on the Rx2 , we are more likely to get the correct output.

18

So in V-BLAST we use Zero-Forcing detection to get a rst guess on the symbol at Rx1 , namely y1 , and then do the interference cancellation

r =r

h11 h12

y1

(3.9)

Then we perform Zero-Forcing again on the modied receive signal r . But this time, we should use the inverse matrix for the modied channel matrix, i.e.

0 h12

(3.10)

0 h22

The process can be generalized to any size of matrix. The order of interference cancellation is important, which means that we should start form the symbol which enjoys largest channel gain, since its easier to get this symbol correct and the interference generated by this symbol to others is bigger. From the process above we can see using V-BLAST, for MIMO with N spatial streams and we need to do Zero-Forcing detection N times to get the result. The computational complexity increases linearly as N increases. Nevertheless, it is independent of the modulation size.

3.2

Channel Model

In order to design wireless communication system more easily, simulations are needed. Computer based simulations requires the mathematical representation of the channel, i.e. the channel models. We will describe the mathematical models of the channel models used in our simulation including the AWGN Channel, Rayleigh Fading Channel, Frequency Selective Channel, and correlated MIMO Channel.

19

3.2.1

AWGN Channel

In AWGN channel, we assume there is no fading eect. So the received signal can be represented by equation 3.11 y = x + n (3.11)

where is the constant channel gain and n is the Additive White Gaussian Noise, normally generated by the thermal noise in the system.

3.2.2

In real wireless communication systems, signals being received may come form dierent paths associating with various channel gains and arrival time. A typical situation is shown in Figure 3.4 [5] below, where a stands for the amplitude.

Figure 3.4: Multipath Rayleigh Fadin In the gure above, we assume symbol period delay spread, so the delay results only

in phase dierence. We can write the channel as followings. a= ai eji = Re(ai eji ) + Img(ai eji ) (3.12)

When the number of arrival path is large enough, i.e. in the full scattering condition, by Central Limit Theorem, equation 3.12 becomes a = aI + aQ = rej (3.13)

where aI and aQ are zero mean Gaussian random variables. r is called Rayleigh envelope 20

Provided that perfect channel information is known, the phase is known. We can multiply a negative phase to the equation 3.14. Noise always has random phase (whether there is a phase change does not matter), so the equation 3.14 can be simplied as y = rx + n (3.15)

The Probability Density Function (PDF) of r follows the Rayleigh distribution. In simulations the expected value of r is always normalized to 1. Since r has a variance, the performance is much worse than that in the case of AWGN channel. To reduce the variance so that improve the performance, diversity is needed.

3.2.3

In the previous section, we assume the delay spread is much smaller than symbol period. If the delay spread of a channel is in a comparable scale with the signal period, the equation 3.12 no longer holds. So a delta function indicating the delay should be included and the equation 3.12 becomes a= ai eji (t i ) (3.16)

Multipath eect in the time domain will result in frequency selective manner in frequency domain. This can be shown by a simple command line MATLAB program and its result plot in Figure 3.5. >>time domain response = [5 1 3 2 0 0 0]; >>plot(1:7, abs(fft(time domain response))); In the Figure 3.5 we can see that at dierent frequency, the response is dierent. Signal at certain frequency will be selective banded. So the channel is called frequency selective.

21

11 10 9 8 7 6 5 4 3

3.2.4

The channel model discussed here is based on [1]. In this model we denote the correlation occurring at the receiver side and transmission side by RRx and RT x . We can then rewrite the channel matrix as

H H = (RRx )1/2 Hiid (RT x )1/2

(3.17)

This model is justied by the fact that only the surrounding objects at the receiver and at the transmitter cause local antenna correlation [4]. To calculate the correlation matrix, we followed the method specied by [1]. The formulas are listes below.

1 tx21

RT x =

(3.18)

tx31 tx32

rx24 rx34

RRx =

(3.19)

rx31 rx32

where D = 2d/. If the antenna is in Uniform Linear Array (ULA) and the distance between antennas is set to be /2, then D = . The derivation of equation 3.21 and 3.22 can be found in [13].

3.3

OFDM

OFDM stands for Orthogonal Frequency Division Multiplexing. A typical OFDM system structure is shown in Figure 3.6 and Figure 3.7 [15] below.

Figure 3.7: A typical OFDM reciever It uses multiple subcarriers which are orthogonal to each other. Each sub-carrier carries a traditionally modulated symbol. Because the carriers are orthogonal to each other, so the frequency usage is the same as the traditional single carrier system. The advantage of OFDM is that it can cope with the frequency selective manner brought by multipath channel. For

23

y0

y1 y2 . . . . . . . . . .

h0 h1 . . . hp1 0 . . . 0

.. .. .. . . .

0 s0 0 . . .

h0 .. . .. .. .. .. . . .. 0 . . .

y=

= Hs + n =

.. .. ..

. . . .. .. . .

. . . . . . 0

. .

hp1 h1 h0

s1 s2 . + . . . . . . . . .

n0 n1

n2 . . . . . . . . . .

(3.23)

. .

. .

where H is toeplitz. By adding symbol at the tail to the head of the transmission sequence, namely adding cyclic prex (CP), the channel matrix is equivalent to a cyclic matrix.

h1 h0 0 . . . . . . . . . 0 h1 .. .. .. . . .

0 h0 .. .. .. . . .

.. .. .. .. 0 . . . . .. .. .. .. . . . .

0 . . . . . . 0 0

Hs =

h1 h0

h0

.. .. .. 0 . . .

0 .. .. .. . . .

sN 1 s0 . . . sN 1

h1 0 . . . 0

s0 s1 . . . sN 1

h1 h0 0 . . . 0 .. .. . .

h1 h0 (3.24)

H s = Hs

(3.25)

By performing IFFT and FFT at the transmitter and receiver, the channel matrix is transformed to a diagonal matrix, meaning F H HF = D (3.26)

Here we should notice that the length of CP added has to bigger than the delay spread of the channel. And since CP is added in the Guard Interval, the length of CP equals to the length of GI. In the OFDM system specied by Std 802.11 2007, there GI for 20 MHz OFDM is 0.8 ns, which means the largest delay the system can handle is 0.8 ns. In reality, if 24

a pulse with enough energy and the delay is longer than GI, then the matrix D is no longer a diagonal matrix. A command line MABLAB program is very illustrative for this process. >>H = [4 0 2 3; 3 4 0 2; 2 3 4 0; 0 2 3 4]; >>dftmatrix = dftmtx(4)/sqrt(4); >>dftmatrix*H*dftmatrix >>ans = 9 0 0 0 0 2+3i 0 0 0 0 3 0 0 0 0 2-3i The resultant diagonal matrix means the symbols we put on each subcarrier will not have any interference on each other. This is very desirable. However, if both OFDM and traditional signal carrier system is running under a Rayleigh channel, the performance of OFDM will not be better. The advantage of OFDM is that performance under a Frequency Selective channel is the same as under Rayleigh channel (suppose the CP is long enough).

3.4

With enough understanding of the wireless communication system, the modulation process can be thought as mapping codes to the constellation diagram, and the performance of the system under AWGN channel and Rayleigh Channel can be derived from the constellation diagram. A very popular to do such mapping is called Gray code. An example of mapping 25

using Gray code can be found in Figure 3.8 [2]. We derive the theoretical BER for this example, The BER for other mapping can be derived in a similar way, the details can be found in Lecture Notes of [8, 5].

Figure 3.8: The Gray Coded constellation for 16 QAM Dene the distance between two constellation points to be d = 2. Then we can calculate the average energy of each symbol by adding the symbol energy at the right left corner and nd the average, the result is 5 Es = d2 2 Since each symbol carrier 4 bit, the symbol energy is related to bit energy by Eb = Es 4 (3.28) (3.27)

By the Union bound, we can derive the symbol error rate as followings. Ps = d 4Q + 3Q + 3Q + 2Q = 3Q 4 2N0 = 3Q 4Eb 5N0 (3.29)

Since Gray code is used, we can derive the bit error rate form symbol error probability by Pb = Ps 3 = Q log2 M 4 4Eb 5N0 (3.30)

This is the bit error rate in AWGN channel. To nd the bit error rate in Rayleigh channel, we should multiply the SNR by the rayleigh envelope and then integrate with the rayleigh distribution. The resultant formula is Pb =

0

Pe

||2Eb f ()d N0 26

(3.31)

3.5

Coding

This biggest challenge in digital communications is that the transmitted bit sequence may be corrupted at the receiver side and make it dicult to decide what the information is sent. Coding could be considered as one of the eective solutions to combat the fading and noise. Shannon Coding Theorem [12] predicts that with there exists some codes which will achieve zero probability of error when the number of bits to be transmitted is large enough as long as the transmission data rate is no larger than the channel capacity. When coding is used in the communications, redundancy is introduced at the transmitter side in order to facilitate receiver to decode the information. In this section, we will mainly explain the convolutional coding scheme which is adopted in 802.11n.

3.5.1

Encoder

The structure of the convolutional encoder consists of several shift registers and several binary adders. Here a convolutional encoder of two shift registers and two binary adders is shown in Figure 3.9.

Figure 3.9: A example of the convolutional encoder structure The convolutional encoder can be considered as a state machine with the shift registers holding its stages. The constraint length K is dened as the number of a bit shifts over which a single information bit can inuence the output and in our simple encoder in the Figure, K = 3. Since there are two outputs for a single bit, the code rate is 1/2. According

27

to the encoder structure, we can obtain the state transition diagram, which is shown in Figure 3.10 [9].

Figure 3.10: State transition diagram for the convolutional code in Figure 3.9 For example, when the shift registers hold the binary values 0 and 0 and the input bit is 1, the codec will generate the two output bits as 1 and 1 and it will transit to the state 10. Since when the encoder transits to one particular stage, its behavior will be independent of the previous stage, so transitions from dierent previous stages which merge into one current stage will behave the same afterward. Thus we may draw a diagram called trellis diagram (shown in Figure 3.11 [9])to simplify the transitions.

Figure 3.11: Trellis diagram for the convolutional code in Figure 3.9

3.5.2

Viterbi Decoding

Viterbi decoding scheme can be derived from the trellis diagram. As we have mentioned earlier, the transitions from dierent stages which merge into one stage will behave the same,

28

we can eliminate one of two paths which merge to a single stages according to the minimum hamming distance metric (hard decision decoding) or maximum log likelihood metric (soft decision decoding). Next, we will explain the dierence between these two schemes. Additional attention should be paid to the decoding process. The input of this process is from the demodulator output. This output is basically a demodulated system on the signal constellation. For example, for BPSK, the output can be every value on the real line with the largest probabilities to be 1. For QPSK, the output can be every value on the complex plane with the largest probabilities to be 1i. There thus become two decoding scheme, hard and soft decoding. Hard decoding is the decoding method that simply quantize the demodulated constellation symbol (which is most likely not the same as constellation symbol generated by modulation due to the channel noise) to the nearest constellation symbol in modulation schemes and demap that symbol back to bit sequence using the known bit-assignment for each symbol. This scheme is not optimal since the quantization process manually drops information from the received observation or so-called condence, for if the received signal which is near the modulation constellation symbol may indicate our condence to decode to that symbol. The optimal decoding method is the soft decoding where a soft and unquantized output is required from the demodulator and it will be fed into the decoder to process. Here the soft decoding algorithm for BPSK modulation scheme is explained. A sequence of information c = [c1 c2 c3 cn ] is coded through the convolutional encoder and becomes coded sequence x = [x11 x12 x13 x14 x15 x16 x17 x21 x22 ]. This sequence which goes through the BPSK modulator is sent out through the channel. On the decoder side, we get the sequence of observations of the BPSK symbol y = [y1 y2 y3 yn ] (every symbol is most likely to be 1). Based on these observations, the maximum likelihood decoding scheme is used to decode the information sequence, i.e. the decision metric is c = arg max p(y|ci)

ci

(3.32)

29

3.6

Space Time Block Code (STBC) is frequently used in multiple antennas systems to provide the spatial diversity. A simple transmission schemes is proposed by Alamouti [3] in 1998. In the paper, it is demonstrated that the diversity could be gained by simply using multiple transmission antennas, which is more feasible than using multiple reception antennas. Also, Alamouti scheme proofs to be no overhead in term of data rate. The block diagram of the 2 1 Alamouti code is shown in Figure 3.12 [6].

Figure 3.12: The structure of Alamouti Code A basic assumption here is that during the Space Time Coding (STC) codeword, the fading channel h1 and h2 remain the same. When we combine the two paths together, we can decouple the x1 and x2 and optimally combine the two same symbols from two dierent antennas to obtain the diversity of order of 2. After the preprocessing at the transmitters side, the STC codeword is transmitted through the spatial channels h1 and h2 .

y1 y2

x1 x2

x 2 x 1

h1 h2

n1 n2

(3.33)

At the receiver side, it takes the received symbol at time 1 and time 2 as a whole code word and does the postprocessing by multiplying the estimated channel response matrix, which is essentially equivalent to the optimal ratio combining. After the process, the transmitted bit 30

symbols are decoupled successfully only with some randomly noise. The following derivation demonstrates this point. Suppoce the received and processed vector be becomes

r1

r1 , then it r2

r2

h1

h2 h 1

h 2

h1

h2 h1 x1 + h2 x2 + n1 h 1 h x2 1 + h x1 2 + n2

(3.34)

h 2

r1 r2

2 2 2

h n1 1 h n1 2

+ h2 n2 h1 n2

(3.35)

2

31

Chapter 4 Implementation

4.1

Simulations

The MATLAB code for simulation can be found in the appendix. Here we explain some important points in the implementation.

4.1.1

In our simulation we assume correlator receiver, a diagram which represents the process is shown in Figure 4.1.

Figure 4.1: The structure of the Correlator Receiver A simple example is easier to understand. For a receiver for BPSK, the structure is

32

Figure 4.2: The simplied Correlator Receiver for BPSK modulation we dene the signal base as (t) = cos(t), then the BPSK signals can be represented as s0 (t) = A(t) s1 (t) = A(t) (4.1) (4.2)

The received signal can be represented by r(t) = s(t) + n(t), where n denotes a zeros mean Gaussian random variable of variance followings. N=

0 T N0 . 2

n(t)(t)dt

E(N) = 0 V ar(N) =

0 T 0 T

n(t)(t)n( )( )dtd =

Since the integral of a Gaussian random variable is also a Gaussian random variable, we can see from the formulas above the variance remains. So in the received symbol, noise can be represented by a Gaussian random variable N and the transform from n(t) to N is the basic of simulation, which is very important.

4.1.2

In the simulation program, the way to calculate signal power is very important. The power can be calculated in both time domain and frequency domain, by adding up the square of 33

the items or nd the variance. In the following MATLAB program, all four powers have the same value. a = (randn(1,10000)+j*randn(1,10000))*sqrt(1/2); power 0 = var(a); ^ power 1 = sum(abs(a).2)/10000; b=fft(a)/sqrt(10000); power 2 = sum(abs(b).^)/10000; 2 power 3 = var(b);

V2 , R

for resistance. Since in the simulations resistance is normalized, and can be considered as 1, power can be understood as the square of amplitude. If we are going to generate a sequence of signal with certain power Ps , we should multiply the square root of Ps with the modulated sequence with unit power such as sqrt(Es)*([1+j 1-j]*sqrt(1/2))

4.1.3

Program of Simulation

y = modulate(mod obj,baseband out); signal energy = var(y(:,1))/carrier count; sigma = sqrt((signal energy/bit per symbol)/(snr))/sqrt(2); where y is the symbol put on each subcarrier. Since y is in frequency domain, the energy of symbol can be calculated by nding the variance then divide it by the number of items (equals to carrier number). Noise sigma can be calculated by the formula. The reason for dividing by sqrt(2) is that the noise has both real and image part, with each part containing

34

noise1 = fft((randn(64,1)+j*randn(64,1))*sigma); noise2 = fft((randn(64,1)+j*randn(64,1))*sigma); noise = cat(1, noise1, noise2); By using t, we generate the noise in frequency domain.

freq res = channel freq res(carrier count,channel response, Rtx, Rrx,tap time); By calling this function, we generate the channel frequency response from the delay prole (time response) and the correlation matrix. The reason to use the frequency response instead of time response in the simulation is that according to the standard, the bandwidth of OFDM system is 20 MHz, which means the time domain resolution is at most 50 ns, while in the channel model, the time dierence between each tap of the time response is only 10ns. Filter on the channel is needed. One way of doing the lter is to do Fast Fourier Transform (FFT) on the time response, which results in a spectrum of 100 MHz. Then we only take the values of corresponding 20MHz band and use the values as frequency domain response of the OFDM system. For the channel model part we use the code written by L. Schumacher, further information of the code can be found in [6].

gain = sum(PDP linear.^); 2 PDP linear = PDP linear * sqrt(1/gain); For simplicity of checking whether the result is correct, we normalized the channel gain to 1. So once the correlation matrix is set to the identical matrix, the simulation result should be same as the theoretical prediction of the Rayleigh channel. The gain reduced in the nor-

35

A = cat(1,Rtx(n,:,1),Rtx(n,:,2)); B = cat(1,Rrx(n,:,1),Rrx(n,:,2)); ^ H=sqrt(1/2)*PDP linear(1,n)*(B(1/2))*(randn(2)+j*randn(2))*((A^ (1/2))); When we calculate the time domain response, the following formula are used. H=

K P HF + K +1

1 HV K +1

(4.6) (4.7)

(in our simulation K = 0). Then we convert the time domain response at each matrix entry (H is a 2 by 2 matrix) to frequency domain response. The reason for multiplying sqrt(1/2) in H is that we should make the variance of the matrix (randn(2)+j*randn(2)) to be 1.

rand phase = exp(rand(size(freq res))*(2*pi*j)); freq res = rand phase.*freq res; Since in the calculation of channel response we only deal with the absolute value, the random phase of frequency response is ignored. When we multiply it with the symbols to nd received symbol, a random phase should be added.

rx(:,n1)=tx(:,n1)+inv(H)*noise(:,n1); The reason we can use tx sequence directly is that we assume enough CP, so the channel is diagonal and there is no interference between the items of tx. Zero forcing detection has the simple formula as shown above. Formulas for V-Blast detection can be found in reference [3].

conditional snr = temp*sqrt(0.4*snr); qam 16 rayleigh(n) = sum(erfc(conditional snr).*p)*0.001*(3/8); Recall that the BER of 16QAM under rayleigh channel is in equation 3.31 as Pb =

0

Pe

||2Eb f ()d N0

(4.8)

where is the rayleigh envelope and f is the rayleigh PDF. Since in MATLAB we do not have the close form of the integration, we use summation instead. At last we plot the theoretical prediction of BER and the simulation result to compare the performances.

4.1.4

In calculating the coverage corresponding to certain pathloss, weve used the curve tting function and bisection method.

load (PathLoss model B.mat) x 1 = 1:110; f pl = fittype(poly3); curve pl = fit(d,pathloss B,f pl); distance = solve(curve pl, x 1,maximum PathLoss,1); Weve calculated the path loss of B and save the data in the le PathLoss model B.mat. The pathloss was calculated at discrete distances range from 1 to 109m, the dierence between each point is 3m. To nd which distance correspond to the maximum allowed pathloss, we rst use the curve tting function to nd the expression of the curve and then use the function solve to solve for the distance.

(temp,index)=min(abs(y-target)); r = recursion(c,index,-1,target,direction); end c is the curve tting object of the pathloss curve, while x is an array of nature numbers from 1 to 109. We rst nd a integer distance which is closest to the target. Since the index corresponding to distance, the target must lies in the interval (index-0.5, index+0.5). We use the function recursion recursively to approach the target point.

function r = recursion(c,x,d,target,direction) temp = feval(c,x)-target; if abs(temp)>0.01 if direction*temp<0 r = recursion(c,x+2^,d-1,target,direction); d else ^ r = recursion(c,x-2d,d-1,target,direction); end else r = x; end end temp indicates the dierence between the current guess and target point. If the function is increasing, the parameter direction should be set to 1, if the function is decreasing, the parameter direction should be set to -1. The meaning is that for a increasing function, if the current guess smaller than the target point, then we should try a point bigger. After each iterations the possible interval becomes half of the previous one. The parameter d indicate the interval length is 2^ (d), so in each iteration we decrease d by 1. So we pass the following

38

parameters to the function. recursion(c,x+2^,d-1,target,direction); d If the current guess is close enough to the target, we just return the point x.

4.2

Coding

In out system, we implemented the convolutional code with dierent code rate specied by the 802.11n. The convolutional code is used to reduce the required Signal to Noise Ratio (SNR) for particular bit error rate level. The basic encoder structure is shown in the Figure 4.3 [2]. The constraint length is K = 7 and the generator polynomial is [133 171]). In our program, the coder structure is built by the poly2trellis function in the communication toolbox. trellis = poly2trellis(7, [133 171]);

Figure 4.3: The convolutional encoder specied by 802.11n In addition to the rate 1/2 code, the standard denes several punctured code with the higher code rate, e.g. 2/3, 3/4 and 5/6. These punctured codes can increase the transmission data rate with relative small loss of the performance. The punctured patterns are illustrated below. For code rate of 3/4, six-bit block is considered and the positions at B1 and A2 are punctured (as shown in Figure 4.4 [2]. At the decoder side, dummy bits, usually 0 are inserted into the sequence at the corresponding postions B1 and A2 before decoding. A 39

similar procedure can be used for code rate of 2/3 and 5/6.

Figure 4.4: The puncture pattern of rate 3/4 code We created a switch in our encoder and decoder to support the punctured pattern. For the encoder, the punctured bits are set to be null. switch code rate case 1/2 code = mcode; case 2/3 punctcode = mcode; punctcode(4:4:end) = []; code = punctcode; case 3/4 punctcode = mcode; punctcode(4:6:end) = []; punctcode(4:5:end) = []; code = punctcode; otherwise end

40

msg = vitdec(unpunctcode, trellis, 6, trunc, unquant); We used the vitdec function in the communication toolbox for decoding the coded sequence. Here 6 represents the traceback length, and option trunc means that the initial of our encoder/decoder is all-zero state and the decoder traces back from the state with the best metric. Option unqunat means unquantized soft-decision decoder. So the unpunctcode is a sequence of real value which is the demodulation likelihood from the qamdemod function.

4.3

Optimization

Based on the simulation results, weve designed an algorithm to nd the optimized system conguration, on coding and modulation scheme at each distance from transmitter to receiver. For certain system conguration, the BER-SNR curve is xed. So for a required BER, say 0.01, we can nd a required SNR. Since Tx power - Noise power - Required SNR = Path Loss The corresponding path loss can be found. Since path loss only depends on the distance, we can nd the maximum distance from transmitter to receiver. This is the coverage of a certain conguration. For conguration that supports larger transmission speed, the coverage is smaller. So if we plot the circles of coverage, they are going to form concentric circles. When a user lies between 2 circles, the optimized conguration is that correspond to the outer circle.

4.4

In order to make our system easy to use, we also create a Graphical User Interface (GUI) using object-oriented programming in Matlab. In our program, every control widget (e.g.

41

checkbox, slider, popup menu) will control one of the properties in the class called Simulator. These properties such as number of transmission antennas, etc. will be passed to the core functions for simulation. A sample GUI demostration is captured and shown in Figure 4.5.

4.5

User Manual

Here we provide a User Maunal to readers and demostrate how to use our program and what the technical signicance of the parameters is and where to set them.

function mimo ofdm fs(channel model, distance, bit per symbol, range,detection, coding) The function name indicates it simulates on a MIMO-OFDM system in frequency selective channel. To run the code, the parameters should be specied by user, a sample command is like >> mimo ofdm fs(B,20,4,ZF,0) In the GUI, users do not have to input he parameters by hand, instead, they can select them from the interface.

42

carrier count = 64; The OFDM as specied in Std 802.11-2007 has 64 subcarriers, but only 52 of them has been used. In other standards, such as DVB-H, the number of subcarrier can be as large as 6817. User should set the parameter according to the situation to be simulated.

mod obj = modem.qammod(M, 2^it per symbol, SymbolOrder, b Gray,InputType, Bit); demod obj = modem.qamdemod(mod obj); We use the build in object of Communication tool box to do the modulation and demodulation. Weve chosen Gray Code here, if other kind of mapped is needed, the user can change the SymbolOrder here.

Connection = downlink; ID = in ID; CorrelationCoefficientType = complex; ^ CarrierFrequency Hz = 5*(109); distance Tx Rx m = distance; NumberOfTxAntennas = Ntx; NumberOfRxAntennas = Nrx; PAS type Tx = 2; PAS type Rx = 2; Correlation Model Antenna Arrange = ULA; Para 1 = 0.5; Para 2 = 0.5; These parameters are set in the function GenChannelModel, the important parameters include channel mode (ID), carrier frequency, distance between transmitter and receiver, number of antennas, antenna arrange, antenna separation, power angular spread. Further infor-

43

for n = 1:range snr in db = n; ^ snr = 10(snr in db/10); The parameter range is range of SNR level in dB we are going to simulate on. User can change the code to for n = snr to simulate on a specic SNR (dB).

44

With the MATLAB program which has been explained in the previous chapter, weve done many simulations and produce a lot of results. Below is the simulation results and discussion.

5.1

5.1.1

10

1

10

10 BER 10

10

10

5 6 Eb/No (dB)

10

45

This is the most basic transmission scheme. Since there is no fading, the BER decrease quickly as SNR increase. Simulation Result math with Theoretical prediction perfectly for SNR equal and smaller than 9 dB, for the BER at 10 dB there is a little mismatch, this is because of the required simulation numbers increased almost 10 times in order to have same amount of error as in the case SNR equals to 9, but actually the simulation numbers increase only 11%.

5.1.2

10

0

BER Over Rayleigh of QPSK Simulation Result Theoretical Prediction over AWGN Theoretical Prediction

10

10 BER 10

10

10

5 Eb/No (dB)

10

15

Figure 5.2: BER of QPSK over Rayleigh Channel In this gure it is shown that the simulation result and theoretical prediction of QPSK over Rayleigh fading channel is perfectly matched. The curve of QPSK over AWGN channel is plotted for reference. It is very clear that the performance of QPSK in Rayleigh fading channel is much worse than the AWGN channel. At a low SNR (9 dB), the performance in AWGN channel is better than Rayleigh Channel for roughly 103 . The big dierence shown that in wireless communications we should nd good diversity schemes to make BER close

46

5.1.3

10

0

10

10 BER 10

10

10

10 Eb/No (dB)

15

20

Figure 5.3: BER of MIMO Over Rayleigh Channel with ZF Detection In MIMO system, the Zero Forcing Detection performs the same as in SISO Rayleigh channel (showne in Figure 5.3. V-BLAST performs better, and ML performs the best. The simulation result follows the theoretical prediction in Chapter 3.

5.1.4

OFDM is a scheme to combat Frequency Selective Channel. In the feature the Theoretical Prediction is the curve of QPSK over Rayleigh Channel (Figure 5.4), the simulation result match with theoretical prediction, this shown that the OFDM can change a Frequency Selective Channel to a Flat Fading channel [4]. The little mismatch is because there is no close form for calculation the BER, so the curve of the theoretical prediction is a little bit lower than the real value.

47

10

BER Over OFDM In FS Channel Simulation Result Theoretical Prediction Theoretical Prediction of AWGN

10

BER 10

2

10

5 Eb/No (dB)

10

15

5.1.5

In these simulations weuse the channel model B specied by TGn, with 16 QAM modulation. The results are presented in Figure 5.5. For the upper left gure we set the correlation matrix to be identical matrix, and the result match with theoretical prediction, which shows our program is correct. In the upper right gure channel correlation is added, it is clear that the performance degrades. In the lower left gure we use V-BLAST detection instead of Zero-Forcing, the performance increase a little, we will explain way the improvement is not signicant in the next section. In the lower right gure we use 1/2 convolutional code, the improvement is signicant.

5.1.6

Performance of V-BLAST

We have studies the performance of V-BLAST under dierent modulation schemes, and we found that with lower modulation size, the V-BLAST can perform better. For BPSK, 16 QAM, 64 QAM, the improvement is 50.82% (BER ZF/BER VB -1), 13.2% and 5.38% respectively. A possible reason is that V-BLAST act on each symbol, for large symbols (contain more bits) its not likely for V-BLAST to make a correction.

48

10

Simulation Result (Correlated) Theoretical Prediction (Uncorrelated) Theoretical Prediction of AWGN 10 BER

1

10 BER

10

10

10

10 Eb/No (dB)

15

20

10

10 Eb/No (dB)

15

20

10

10

10 BER

10 BER

10

10

10

10 Eb/No (dB)

15

20

10

10 Eb/No (dB)

15

20

5.2

Two kinds of coding schemes have been developed. One is the block code, namely (7,4) Hamming Code. The other is the convolution code, which constraint length and generator structure are specied in the 802.11 standard. The simulation results are shown in Figure 5.6.

It can be seen from the above gure that convolution code is pretty useful when the channel condition is more or less like the AWGN channel. However, since the hard decision is used above (denoted as + line), even convolution code is not ecient over Rayleigh channel. Then it leads to another simulation, focusing on the Rayleigh channel in Figure refg:coding:bpskcovray. The above gure shows the simulation result of the hard decision and soft decision using

49

Figure 5.7: BER of BPSK over Rayleigh Using Convolutional Code convolution code over Rayleigh channel. As mentioned in the previous explanations that hard decision coding is not ecient over Rayleigh channel, we can nd actually that a coding gain between soft decision and hard decision is about 10dB when the BER is xed on 0.001 level. This shows that soft decision is quite ecient over Rayleigh channel. In fact, in reality, we are required to use soft decision in order to get a reasonable good performance. Linear Block code is used in the above simulation. Particularly, (7,4) Hamming code is used. We can see that better performance can be achieved when the channel model is AWGN. Still if the hard decision is used, we get an even worse performance over Rayleigh channel (shown in Figure refg:coding:bpskblock).

50

5.3

Alamouti Code is a kind of Space Time Block Code (STBC), in order to achieve multipath diversity [5]. Here the results are shown in Figure ?? and Figure ??. In the curve it is clear that Alamouti Code provide a signicant diversity gain. It is clear that by using Alamouti code the improvement in performance is signicant.

10

0

BPSK with Alamouti 2 by 1 code over Rayleigh Channel alamouti code no diversity theoretical

10

10 BER 10

10

10

10 Eb/No (dB)

15

20

51

10

BPSK with Alamouti 2 by 2 code over Rayleigh Channel alamouti code no diversity theoretical

10

10

10 BER 10

10

10

10

10 Eb/No (dB)

15

20

5.4

By the regulation body in America, at the 5.15 5.35 GHz band, the maximum energy is 2.5mW/MHz. So for the 20 MHz OFDM system the maximum energy we can send is 50mW, which correspond to 17dBm. Noise level can be calculated by the formula n = kT B (5.2)

Where k = 1.38 1028 , T = 300K, which corresponds to 27 C and B = 20MHz. So n = 100.8dBm We can nd in the simulation result that to achieve BER = 102 ,which SNR at receiver is needed, then by the formular T x power V Noise power V Required SNR = Maximum P ath Loss (5.3)

The maximum path loss can be found. From the code by L. Schumacher we can get the relationship between distance and path loss. The curve for channel model B is shown in Figure 5.11. We can nd the distance corresponds to the maximum path loss from the Figure 5.11. Then the coverage of the schemes can be found. A few transmission schemes, their coverage and the data rate achieved is listed in Table 5.1, and their coverage is plotted in Figure 5.12. 52

110

90

80

70

60

50

20

40

60 Distance (m)

80

100

120

Figure 5.11: Path Loss vs. Distance in Channel Model B To optimize the performance, users locate between two circles should chose the transmission scheme corresponding to the outer circle. The calculation can be extended to other transmission schemes and channel models.

53

Index Scheme

Required Maximum SNR (dB) Allowed Pathloss (dB) 108.5 106.3 105.2 104.2 103.3 102.2 100.2

Distance Data (m) Rate (Mb/s) 97.6 88.0 80.5 71.6 64.1 52.3 48.5 12 12 24 48 48 72 96

1 2 3 4 5 6 7

BPSK, V-BLAST, Coded BPSK, Zero-Forcing, Coded BPSK, V-BLAST, Uncoded 16QAM, V-BLAST, Coded 16QAM, Zero-Forcing, Coded 64QAM, Zero-Forcing, Coded 16QAM, Zero-Forcing, coded Un-

20.8

97.1

40.0

144

54

Chapter 6 Conclusions

In this project, weve implemented a simulation platform for the PHY layer of the WLAN standard IEEE 802.11n. The IEEE 802.11n PHY layer makes use of new developments in wireless technology and is based on MIMO-OFDM. With the platform, weve performed simulations under various channel conditions, and produced a variety of results which reveal the performance of 802.11n. The platform weve implemented can be used as a testbed by communication engineers to perform system evaluation. The results have also helped us to understand the system and to nd what further improvements can be made. We ourselves have learned a lot by completing the project.

55

Bibliography

[1] IEEE P802.11 Wireless LANs TGn Channel Models. Technical report, Target Group n (TGn), 2004. Doc: IEEE 802.11-03/940r4. [2] IEEE Standard for Information technology Telecommunications and information exchange between systems Local and metropolitan area networks Specic requirements. Technical report, Institute of Electrical and Electronic Engineers, 2007. Part 11: Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specications. [3] S. M. Alamouti. A simple transmit diversity technique for wireless communications. IEEE Journal on Select Areas in Communications, 16(8), oct 1998. [4] E. Biglieri and G. Taricco. Transmission and Reception with Multiple Antennas: Theoretical Foundations, volume 1 of Foundations and TrendsTM in Communications and Information Theory. NOW Publishers, 2004. [5] R. S. Cheng. ELEC 343 Wireless Communication Systems, Lecture Notes. Download information: http://course.ee.ust.hk/elec343. [6] V. K. N. Lau. ELEC 546 Wireless Communication Systems, Lecture Notes. Download information: http://course.ee.ust.hk/elec546. [7] D. C. Lay. Linear Algebra and Its Applications. Addison-Wesley Publishing Company, third edition, 2003.

56

[8] W. H. Mow. ELEC 314 Digital Communications, Lecture Notes. Download information: http://course.ee.ust.hk/elec314. [9] W. H. Mow. ELEC 332 Information Theory and Error-Correcting Codes, Lecture Notes. Download information: http://course.ee.ust.hk/elec332. [10] R. D. Murch. ELEC 536 Digital Communications, Lecture Notes. Download information: http://course.ee.ust.hk/elec536. [11] L. Schumacher. WLAN MIMO Channel Matlab program. Download information: http://www.info.fundp.ac.be/ lsc/Research/IEEE 80211 HTSG CMSC/ distribution terms.html. [12] C. E. Shannon. A mathematical theory of communication. The Bell System Technical Journal, 27, oct 1948. [13] D. Tse and P. Viswanath. Fundamentals of Wireless Communication. Cambridge University Press, rst edition, 2005. [14] R. van Nee and R. Prasad. OFDM for Mobile Multimedia Communications. Artech House, 2000. [15] Wikipedia. Orthogonal frequency-division multiplexing.

http://en.wikipedia.org/wiki/OFDM.

57