aboutsummaryrefslogtreecommitdiffstats
path: root/doc/thesis/chapters/theory.tex
blob: 2c4687bcdefc5c3e417e778c430ccdd5dae999ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
% vim: set ts=2 sw=2 noet spell:

\chapter{Theory}

\begin{figure}
	\centering
	\resizebox{\linewidth}{!}{
		\input{figures/tikz/overview}
	}
	\caption{
		Block diagram for a general wireless communication system with annotated signal names. Frequency domain representations of signals use the uppercase symbol of their respective time domain name.
		\label{fig:notation}
	}
\end{figure}

In this section we will briefly give the mathematical background required by the modulation schemes used in the project. The notation used is summarised in figure \ref{fig:notation}. For conciseness encoding schemes and (digital) signal processing calculations are left out and discussed later. Thus for this section \(m_e = m\).

%% TODO: Par on notation m(n) = m(nT) = discrete time

%% TODO: A section on maths?
% \section{Signal space and linear operators}

\section{Quadrature amplitude modulation (\(M\)-ary QAM)}

\begin{figure}
	\centering
	\resizebox{\linewidth}{!}{
		\input{figures/tikz/qam-modulator}
	}
	\caption{
		Block diagram of a \(M\)-ary QAM modulator.
		\label{fig:quadrature-modulation}
	}
\end{figure}

Quadrature amplitude modulation is a family of modern digital modulation methods, that use an analog carrier signal. The simple yet effective idea behind QAM is to encode extra information into an orthogonal carrier signal, thus increasing the number of bits sent per unit of time \cite{Gallager,Kneubuehler,Mathis,Hsu}. A block diagram of the process is shown in figure \ref{fig:quadrature-modulation}.

%% TODO: Quick par on "we will dicusss M-Ary QAM, M is 2^something"

\subsection{Modulation of a digital message}

\paragraph{Bit splitter}

As mentioned earlier, quadrature modulation allows sending more than one bit per unit time. The first step to do it is to use a so called bit splitter, that converts the continuous bitstream \(m(n)\) into pairs of chunks of \(\sqrt{M}\) bits. The two bit vectors of length \(\sqrt{M}\), denoted by \(\vec{m}_i\) and \(\vec{m}_q\) in figure \ref{fig:quadrature-modulation}, are called in-phase and quadrature component respectively\cite{Hsu}. The reason will become more clear later.

\paragraph{Binary to level converter}

%% TODO: explain why gray code

Both bit vectors \(\vec{m}_i, \vec{m}_q \in \{0,1\}^{\sqrt{M}}\) are sent through a binary to level converter. It's purpose is to reinterpret the bit vectors as a numbers, usually in gray code, and to convert them into analog waveforms, which we will denote with \(m_i(t)\) and \(m_q(t)\) respectively. Mathematically the binary to level converter can be described as:
\begin{equation}
	m_i(t) = \text{Level}(\vec{m}_i) \cdot p(t),
\end{equation}
i.e. a pulse function\footnote{Typically a root raised cosine to optimize for bandwidth \cite{Hsu}.} \(p(t)\) scaled by the interpreted binary value, written here using a ``Level'' function. So at this point a level of each analog waveform is encodes \(\sqrt{M}\) bits per unit time, and there are two of such waveforms.


\paragraph{Mixer}

Having analog level signals, it is this now possible to mix them with radio frequency carriers. Because there are two waveforms, one might expect that two carrier frequencies are necessary, however this is not the case. The two component \(m_i(t)\) and \(m_q(t)\) are mixed with two different periodic signals \(\phi_i(t)\) and \(\phi_q(t)\) that have the same frequency \(\omega_c = 2\pi / T\). How this is possible is explained in the next section.


\subsection{Orthogonality of carrier signals}

Before explaining how the two carrier signals are generated, we first need to discuss some important mathematical properties \(\phi_i\) and \(\phi_q\) need to have, in order to modulate two messages over the same frequency \(\omega_c\). The two carriers need to be \emph{orthonormal}\footnote{Actually orthogonality alone would be sufficient, however then the left side of \eqref{eqn:orthonormal-condition} would not equal 1, and an inconvenient factor would be introduced in many later equations \cite{Gallager,Hsu}.} to each other, mathematically this is expressed by the conditions
\begin{subequations} \label{eqn:orthonormal-conditions}
	\begin{align}
		\langle \phi_i, \phi_q \rangle
			&= \int_T \phi_i \phi_q^* \, dt
			= 0, \text{ and } \label{eqn:orthogonal-condition} \\
		\langle \phi_k, \phi_k \rangle
			&= \int_T \phi_k \phi_k^*  \,dt = 1,
			\text{ where } k \text{ is either } i \text{ or } q. \label{eqn:orthonormal-condition}
	\end{align}
\end{subequations}
Provided these rather abstract conditions, let's define a new signal 
\begin{equation}
	s = m_i\phi_i + m_q\phi_q.
\end{equation}
%% TODO: is this assumption correct?
Notice that assuming \(m_i\) and \(m_q\) are constant\footnote{This is an approximation assuming that the signal changes much slower relative to the carrier.} over the carrier's period \(T\),
\begin{align*}
	\langle s, \phi_i \rangle = \int_T s \phi_i^* \,dt
		&= \int m_i \phi_i \phi_i^* + m_q \phi_q \phi_i^* \,dt \\
		&= m_i \underbrace{\int_T \phi_i \phi_i^* \,dt}_{1}
			+ m_q \underbrace{\int_T \phi_q \phi_i^* \,dt}_{0} = m_i,
\end{align*}
which effectively means that it is possible to isolate a single component \(m_i(t)\) out of \(s(t)\). The same of course works with \(\phi_q\) as well resulting in \(\langle s, \phi_q \rangle = m_q\). Thus (remarkably) it is possible to send two signals on the same frequency, without them interfering with each other. Since each signal can represent one of \(\sqrt{M}\) values, by having two we obtain \(\sqrt{M} \cdot \sqrt{M} = M\) possible combinations.

A graphical way to see what is happening, is to observe a so called \emph{constellation diagram}. An example is shown in figure \ref{fig:qam-constellation} for \(M = 16\). The two carrier signals \(\phi_i\) and \(\phi_q\) can be understood as bases of a coordinate system.

\subsection{Construction of orthogonal carrier signals}


If \(\phi_i\) is a real valued signal (which is typical) it is possible to find a function the quadrature carrier using the \emph{Hilbert transform}:
\begin{equation}
	\hilbert g(t) = g(t) * \frac{1}{\pi t}
		= \frac{1}{\pi} \int_\mathbb{R} \frac{g(\tau)}{t - \tau} \,d\tau
		= \frac{1}{\pi} \int_\mathbb{R} \frac{g(t - \tau)}{\tau} \,d\tau,
\end{equation}
i.e. a linear operator that introduces a phase shift of \(\pi / 2\) over all frequencies \cite{Hsu,Gallager}. It is a known property of the Hilbert transform that given a real valued function \(g(t)\) then \(\langle g, \hilbert g \rangle = 0\) \cite{Kschischang,Kneubuehler}.
In practice \(\phi_i(t) = \cos(\omega_c t)\) and \(\phi_q(t) = \hilbert \phi_i(t) = \sin(\omega_c t)\).  

\paragraph{Oscillator and phase shifter}

\subsection{Spectral properties of a QAM signal}

\begin{figure}
	\hfill
	\begin{subfigure}{.4\linewidth}
		\input{figures/tikz/qam-constellation}
		\caption{16-QAM\label{fig:qam-constellation}}
	\end{subfigure}
	\hfill
	\begin{subfigure}{.4\linewidth}
		\input{figures/tikz/psk-constellation}
		\caption{8-PSK\label{fig:psk-constellation}}
	\end{subfigure}
	\hfill
	\caption{
		Examples of constellation diagrams. Each dot represents a possible location for the complex amplitude of the passband signal.
	}
\end{figure}


\section{Phase shift keying (\(M\)-PSK)}

PSK is a popular modulation type for data transmission\cite{Meyer2011}. With a bipolar binary signal, the amplitude remains constant and only the phase will be changed with phase jumps of 180 degrees, which can be seen as a multiplication of the carrier signal with $\pm$ 1. That is alow known as binary phase shift keying.

% \begin{figure}
% 	% TODO: Better Image
% 	% https://sites.google.com/site/billmahroukelec675/bipolar-phase-shift-keying
% 	\includegraphics[width=5cm]{./image/BPSK2.png}
% \end{figure}

Two bits are modulated at ones with the same bandwidth as a 2-PSK so more informations are transmitted at the same time. \cite{Meyer2011}
%TODO: Image Signal Raum 
Most times there is noise and the points on the constellation diagram become a surface. 
If the surfaces overlap there will be a problem with decoding. 

\section{Wireless channel}

In the previous section, we discussed how the data is modulated and demodulated at the two ends of the transmission system. In this section we will discuss what happens between the sender and receiver when the modulated passband signal is transmitted wirelessly.

In theory because wireless transmission happens through electromagnetic radiation, to model a wireless channel one would need to solve Maxwell's equations for either the electric or magnetic field, however in practice that is not (analytically) possible. Instead what is typically done, is to model the impulse response of the channel using a geometrical or statistical model, parametrized by a set of coefficients that are either simulated or measured experimentally \cite{Gallager}.

In our model we are going to include an additive white Gaussian noise (AWGN) and a Rician (or Rayleighan) fading; both are required to model physical effects of the real world. The former in particular is relevant today, as it mathematically describes dense urban environments.

\subsection{Additive white Gaussian noise}

%% TODO: Discuss thermal stuff etc?

\subsection{Geometric multipath fading model}

The simplest way to understand the multipath fading, is to consider it from a geometrical perspective. Figure \ref{fig:multipath-sketch} is a sketch a wireless transmission system affected by multipath fading. The sender's antenna radiates an electromagnetic wave in the direction of the receiver (red line), however even under the best circumstances a part of the signal is dispersed in other directions (blue lines).

\begin{figure}
	\centering
	\input{figures/tikz/multipath-sketch}
	\caption{
		Sketch of channel with multipath fading
		\label{fig:multipath-sketch}
	}
\end{figure}

The problem is that, as is geometrically evident, some paths are longer than others. Because of this fact, the signal is seen by the receiver multiple times with different phase shifts \cite{Gallager,Messier}. To mathematically model this effect, we describe the received signal \(r(t)\) as a linear combination of delayed copies of the sent signal \(s(t)\), each with a different attenuation \(c_k\) and phase shift \(\tau_k\):
\begin{equation} \label{eqn:geom-multipath-rx}
	r(t) = \sum_k c_k s(t - \tau_k).
\end{equation}

The linearity of the model is justified by the assumption that the underlying electromagnetic waves behave linearly (superposition holds) \cite{Gallager}. How many copies of \(s(t)\) (usually referred to as ``taps'' or ``rays'') should be included in the formula, depends on the precision requirements of the model.

A further complication arises, when one end (or both) is not stationary. In that case the lengths of the paths change over time, and as a result both the delays \(\tau_k\) as well as the attenuations \(c_k\) become functions of time: \(\tau_k(t)\) and \(c_k(t)\) respectively \cite{Gallager,Messier}. Even worse is when the velocity at which the device is moving is high, because then Doppler shifts of the electromagnetic wave frequency become non negligible \cite{Gallager}.

We have thus observed that the arrangement can be modelled as a linear time-\emph{varying} system (LTV), if the sender or the receiver (or anything else in the channel) is moving, and as a linear time \emph{invariant} (LTI) system if the geometry is stationary. Regardless of which of the two cases, linearity alone is sufficient to approximate the channel as finite impulse response (FIR) filter \cite{Messier}. Mathematically we can rewrite LTV version of equation \eqref{eqn:geom-multipath-rx} using a convolution product as following:
\begin{align*}
	r(t) = \sum_k c_k(t) s(t - \tau_k(t)) &= \sum_k c_k(t) \int_\mathbb{R} s(\tau) \delta(\tau - \tau_k(t)) \,d\tau \\
		&= \int_\mathbb{R} s(\tau) \sum_k c_k(t) \delta(\tau - \tau_k(t)) \,d\tau = s(\tau) * h(\tau, t),
\end{align*}
obtaining a new function
\begin{equation} \label{eqn:multipath-impulse-response}
	h(\tau, t) = \sum_k c_k(t) \delta(\tau - \tau_k(t)),
\end{equation}
that describes the \emph{impulse response} of the channel. This function is dependant on two time parameters: actual time \(t\) and convolution time \(\tau\). To better understand \(h(\tau, t)\), consider an example in shown in figure \ref{fig:multipath-impulse-response}. Each stem represents a weighted Dirac delta, so each series of stems of the same color, along the convolution time \(\tau\) axis, is a channel response at some specific time \(t\). Along the other \(t\) axis we see how the entire channel response changes over time\footnote{In the figure only a finite number of stems was drawn, but actually \(h(\tau, t)\) is continuous in \(t\), i.e. the weights \(c_k(t)\) of the Dirac deltas change continuously.}. Notice that the stems are not quite aligned to the \(\tau\) time raster (dotted lines), that is because in equation \eqref{eqn:multipath-impulse-response} not only the weights \(c_k\) but also the delays \(\tau_k\) are time dependent.

\begin{figure}
	\centering
	\input{figures/tikz/multipath-impulse-response}
	\caption{
		LTV impulse response of a multipath fading channel.
		\label{fig:multipath-impulse-response}
	}
\end{figure}

\subsection{Spectrum of a multipath fading channel}

With a continuous time channel model we can now discuss the spectral properties of a fading channel, since the frequency response is the Fourier transform of the impulse response, mathematically \(H(f, t) = \fourier h(\tau, t)\). In this case however \(h(\tau, t)\) depends on two time variables, but that is actually not an issue, it just means that the frequency response is also changing with time. Hence we perform the Fourier transform with respect to the channel (convolution) time variable \(\tau\) to obtain
\begin{equation} \label{eqn:multipath-frequency-response}
	H(f, t) = \int_\mathbb{R} \sum_k c_k(t) \delta(\tau - \tau_k(t)) e^{-2\pi jf\tau} \, d\tau
	= \sum_k c_k(t) e^{-2\pi jf \tau_k(t)}.
\end{equation}

Equation \eqref{eqn:multipath-frequency-response} indicates that the frequency response is has a periodic (complex) sinusoidal shape, which has some important implications. A series of plots of the magnitude of the frequency response is shown in figure \ref{fig:multipath-frequency-response-plots}.

\subsection{Discrete-time model}

\subsection{Statistical model}

%% TODO: write about advantage of statistical model instead of geometric

\section{Receiver DSP chain}