# Plotting a sampled signals DTFT using its CTFT

So I know the connection between the DTFT and the CTFT is the following:

Where the left-hand side is the discrete time fourier transform.

I need to choose a sampling rate which won't cause any aliasing, so I'll find a sample that satisfies the inequality

$$f_s\ge 2\bullet f_m$$ where $f_m$ is the max frequency of the signal. In this case, $f_m$=60, leaving us with sampling rate of 120.

And we need the period:

$T=\frac{1}{120}$

Now using the above formula:

$X^f(\theta)=120\sum^\infty_{-\infty}X^F\left(120\bullet(\theta-2\pi k\right))$

But I thought that we want to compress the signal? Here we're stretching it out, leading me to believe I'm not understanding this idea properly. I'd appreciate any help

• you don't have a connection between the Discrete-Time Fourier Transform, $$X(e^{j \omega}) = \sum\limits_{n=-\infty}^{\infty} x[n] e^{-j \omega n}$$ and the continuous-time Fourier Transform, $$X(j \Omega)=\int\limits_{-\infty}^{\infty} x(t) e^{-j \Omega t}\, dt$$ until you make a connection, in both directions, between the discrete-time signal $x[n]$ and the continuous-time signal $x(t)$. – robert bristow-johnson Nov 10 '17 at 16:59
• In this case would the connection be $\theta = \omega T$? – RonaldB Nov 10 '17 at 16:59
• make a connection, in both directions, between $x[n]$ and $x(t)$.  in one direction, it is easy: $$x[n] \triangleq x(nT)$$ where $T = \frac{1}{f_\text{s}}$. – robert bristow-johnson Nov 10 '17 at 17:00
• Isn't the Sampling theorem that I used up above a result of both-direction connections? – RonaldB Nov 10 '17 at 17:09
• you're on the right track! so can you come up with a relationship that expresses $x(t)$ in terms of the samples $x[n]$? – robert bristow-johnson Nov 10 '17 at 17:11

So you have a continuous-time function $x(t)$ with continuous-time Fourier Transform

$$X(j \Omega)\triangleq \mathscr{F} \Big\{ x(t) \Big\} = \int\limits_{-\infty}^{\infty} x(t) \, e^{-j \Omega t} \, dt$$

and you have the corresponding discrete-time function $\tilde{x}[n]$ and Discrete-Time Fourier Transform

$$\tilde{X}(e^{j \omega}) \triangleq \mathcal{DTFT} \Big\{ \tilde{x}[n] \Big\} = \sum\limits_{n=-\infty}^{\infty} \tilde{x}[n] \, e^{-j \omega n}$$

The argument to $\tilde{X}(e^{j \omega})$ is periodic in $\omega$ with period of $2 \pi$.

$$e^{j (\omega + 2 \pi)} = e^{j \omega}\,e^{j2\pi} = e^{j \omega} \cdot 1 = e^{j \omega} \qquad \forall \omega \in \mathbb{R}$$

This means

$$\tilde{X}(e^{j (\omega + 2 \pi)}) = \tilde{X}(e^{j \omega}) \qquad \forall \omega \in \mathbb{R}$$

This is why I denote frequency-domain spectrum $\tilde{X}(e^{j \omega})$ and it's inverse DTFT, $\tilde{x}[n]$ with a little wavy tilde to denote that we know $\tilde{X}(e^{j \omega})$ is periodic.

You're sampling continuous-time function $x(t)$ at a sample rate of $f_\text{s} \triangleq \frac{1}{T}$ ($T>0$ is the sampling period). We say that the samples are

$$\tilde{x}[n] \triangleq x(nT) \qquad n \in \mathbb{Z}$$

but that is not enough to describe the situation. Using a scaling convention that is a little different than most textbooks, the continuous-time representation of the sampled signal is:

\begin{align} x_\text{s}(t) &= x(t) \left( T \sum\limits_{n=-\infty}^{\infty} \delta(t-nT) \right) \\ &= T \sum\limits_{n=-\infty}^{\infty} x(t) \delta(t-nT) \\ &= T \sum\limits_{n=-\infty}^{\infty} x(nT) \delta(t-nT) \\ &= T \sum\limits_{n=-\infty}^{\infty} \tilde{x}[n] \delta(t-nT) \\ \end{align}

$x_\text{s}(t)$ is a continuous-time signal, but is zero for all time, $t$, except when $t=nT$, when it is a dirac impulse function. This throws away all information about $x(t)$ between these sampling instances when $t=nT$, which is essentially what uniform sampling is all about.

So what the Poisson Summation Formula and the sampling theorem tell us is that when we uniformly sample in one domain (say the "time domain"), this causes a periodic extension to happen in the reciprocal domain (here the "frequency domain"):

\begin{align} X_\text{s}(j\Omega) &= \mathscr{F} \Big\{ x_\text{s}(t) \Big\} \\ &= \mathscr{F} \Bigg\{x(t) \left( T \sum\limits_{n=-\infty}^{\infty} \delta(t-nT) \right) \Bigg\} \\ &= \mathscr{F} \Big\{T \sum\limits_{n=-\infty}^{\infty} \tilde{x}[n] \delta(t-nT) \Big\} \\ &= T \sum\limits_{n=-\infty}^{\infty} \tilde{x}[n] \mathscr{F}\Big\{ \delta(t-nT) \Big\} \\ &= T \sum\limits_{n=-\infty}^{\infty} \tilde{x}[n] e^{-j \Omega \, nT} \\ &= T \sum\limits_{n=-\infty}^{\infty} \tilde{x}[n] e^{-j \omega n} \Bigg|_{\omega = \Omega T} \\ \end{align}

which is $T$ times the DTFT

$$X_\text{s}(j\Omega) = T \cdot \tilde{X}(e^{j \omega}) \Bigg|_{\omega = \Omega T}$$

The reason I include this $T$ factor to scale is for dimensional clarity. Because $x(t)$ and $\tilde{x}[n]$ have the same dimension, then in the integral of the Fourier Transform, $X(j\Omega)$ (and later $X_\text{s}(j\Omega)$) pick up an addition dimensional factor of time. Having the $T$ on the right is necessary for both sides of the equation to be dimensionally equivalent.

Another way to look at it is to consider that the sampling operator is periodic, so it has a Fourier series

$$T \sum\limits_{n=-\infty}^{\infty} \delta(t-nT) = \sum\limits_{k=-\infty}^{\infty} e^{j 2 \pi k f_\text{s} t}$$

and all the Fourier series coefficients = 1 (only if the $T$ factor is included on the left side of the equation).

If you use the frequency translation theorem of the Fourier Transform, the continuous spectrum of that ideally sampled function is

\begin{align} X_\text{s}(j\Omega) &= \mathscr{F} \Big\{ x_\text{s}(t) \Big\} \\ &= \mathscr{F} \Big\{x(t) \left( T \sum\limits_{n=-\infty}^{\infty} \delta(t-nT) \right) \Big\} \\ &= \mathscr{F} \Big\{x(t) \sum\limits_{k=-\infty}^{\infty} e^{j 2 \pi k f_\text{s} t} \Big\} \\ &= \mathscr{F} \Big\{\sum\limits_{k=-\infty}^{\infty} x(t) e^{j 2 \pi k f_\text{s} t} \Big\} \\ &= \sum\limits_{k=-\infty}^{\infty} \mathscr{F} \Big\{ x(t) e^{j 2 \pi k f_\text{s} t} \Big\} \\ &= \sum\limits_{k=-\infty}^{\infty} X\big(j (\Omega - 2 \pi k f_\text{s}) \big) \\ \end{align}

You can see that both spectra of the sampled signal, $x_\text{s}(t)$ and of the samples, $\tilde{x}[n]$ are periodic with period in $\Omega$ of $2 \pi f_\text{s}$ and a period in $\omega$ of $2 \pi$. The reason $f_\text{s}$ appears in the continuous-time spectrum is because the sampling frequency needs to be known for $X_\text{s}(j\Omega)$ but that and sampling period $T$ are normalized out of the expressions for both $\tilde{x}[n]$ and $\tilde{X}(e^{j \omega})$.

Equating the two expressions for the continuous-time sampled signal, $X_\text{s}(j\Omega)$:

$$\sum\limits_{k=-\infty}^{\infty} X\big(j (\Omega - 2 \pi k f_\text{s}) \big) = T \cdot \tilde{X}(e^{j \omega}) \Bigg|_{\omega = \Omega T}$$

Now here is the last thing. If you bandlimit the continuous-time input, $x(t)$, so that

$$X(j\Omega) = 0 \qquad \forall \ |\Omega| \ge \pi f_\text{s}$$

which means there is no energy in $x(t)$ for frequencies equal to or greater than the Nyquist frequency which is, in angular frequency, $\pi f_\text{s}$, then you know that adjacent images of $X(j\Omega)$, which are

$$X\big(j (\Omega - 2 \pi k f_\text{s}) \big) \qquad \text{for } k \in \mathbb{Z} \ ,$$

then these images do not overlap. That means when looking at the original baseband spectrum (when $k=0$)

\begin{align} X(j \Omega) &= \sum\limits_{k=-\infty}^{\infty} X\big(j (\Omega - 2 \pi k f_\text{s}) \big) \qquad & |\Omega| < \pi f_\text{s} \\ &= X_\text{s}(j \Omega) \qquad & |\Omega| < \pi f_\text{s} \\ &= T \cdot \tilde{X}(e^{j \omega}) \Bigg|_{\omega = \Omega T} \qquad & |\Omega| < \pi f_\text{s} \\ \end{align}

So this relates the DTFT spectrum directly to the spectrum of the original continuous-time (and bandlimited) signal.

Just for your information, the reconstruction part of the sampling theorem is that, since the samples $\tilde{x}[n]$ are sufficient information to represent $x(t)$ (this is because you bandlimited $X_\text{s}(j \Omega)$ to be non-zero only for $\Omega < 2 \pi f_\text{s}$ ), then the original $x(t)$ in terms of the samples is:

$$x(t) = \sum\limits_{n=-\infty}^{\infty} \tilde{x}[n] \operatorname{sinc}\big( \tfrac{1}{T}(t-nT) \big)$$

where $\operatorname{sinc}(u) \triangleq \frac{\sin(\pi u)}{\pi u}$. This is consistent with above, $x(nT)=\tilde{x}[n]$ for all integer $n$.

This explicitly relates, in both directions, the continuous-time signal $x(t)$ to the samples $\tilde{x}[n]$ and their respective spectra, $X(j \Omega)$ and $\tilde{X}(e^{j \omega})$.

• Hi Robert: I'm just tip-toeing in this field so I'm not gonna try to understand above right now. but I did find a beautiful exposition of the dft and how it's an approximation to both the fourier series and the fourier transform. the book is by briggs and henson but unfortunately they don't touch the DTFT. Do you know of a text that talks about what you've done above regarding the DTFT and the FT. I have many texts so I may have that text if you know of one. The amount of material in this field is quite great and sometimes I find great explanations but it's not easy. Thanks. – mark leeds Nov 11 '17 at 7:19
• it is not meant to be confusing or even particularly difficult. it is meant to be explicit and rigorous. that means it should be easier to follow than if i had left out a bunch of steps. i am too lazy to capitalize properly and will not object if some other OCD sufferer wants to do that. – robert bristow-johnson Nov 11 '17 at 8:41
• hi robert: I'm sure the explanation is very well done just like your others. my style is just to read a textbook first and then go to the relevant explanations like yours. they tend to be easier for me to understand that way. So, if you or anyone knows of a textbook exposition of what robert said above, it's appreciated. – mark leeds Nov 11 '17 at 19:52
• hi robert: just to give a clearer explanation of what I'm saying: above requires understanding of nyquist, sampling rates, reconstruction and whatever else. sometimes the texts construct the setting and all the background noise which aids in my understanding. dsp answers often assume some knowledge which is totally understandable. thanks. – mark leeds Nov 11 '17 at 19:58
• HI Robert: It's appreciated. – mark leeds Nov 12 '17 at 2:45