Skip to main content

DTFT of sgn[n] and u[n]

Short answer

Define sgn[n] as limit of decaying sequences, giving DTFT 2/(1 - e^{-jw}) for w ≠ 2pi k. Then u[n] = 1/2 + (1/2)sgn[n] yields U(e^{jw}) = 1/(1 - e^{-jw}) + pi sum delta(w - 2pi k).

Determine the discrete time fourier transform of signum function (sgn[n]) and use it to find the DTFT of unit-step signal u[n].

The definition used here is sgn[n]=1\mathrm{sgn}[n] = 1 for n≥0n \ge 0 and −1-1 for n<0n < 0, so that u[n]=12(1+sgn[n])u[n] = \frac{1}{2}(1 + \mathrm{sgn}[n]). (A note at the end covers the version with sgn[0]=0\mathrm{sgn}[0] = 0.)

 sgn[n]
   1             *  *  *  *
                 |  |  |  |
 ----+--+--+--+--+--+--+--+--- n
     |  |  |  |
  -1 *  *  *  *
    -4 -3 -2 -1  0  1  2  3

DTFT of sgn[n]

sgn[n]\mathrm{sgn}[n] is not absolutely summable, so take it as a limit of decaying sequences (0<a<10 < a < 1):

sgn[n]=lim⁡a→1[anu[n]−a−nu[−n−1]]\mathrm{sgn}[n] = \lim_{a\to 1}\left[a^n u[n] - a^{-n}u[-n-1]\right]

First part:

∑n=0∞ane−jωn=11−ae−jω\sum_{n=0}^{\infty}a^n e^{-j\omega n} = \frac{1}{1 - ae^{-j\omega}}

Second part, with m=−nm = -n:

∑n=−∞−1a−ne−jωn=∑m=1∞(aejω)m=aejω1−aejω\sum_{n=-\infty}^{-1}a^{-n}e^{-j\omega n} = \sum_{m=1}^{\infty}\left(ae^{j\omega}\right)^m = \frac{ae^{j\omega}}{1 - ae^{j\omega}}

Hence

Sa(ejω)=11−ae−jω−aejω1−aejωS_a(e^{j\omega}) = \frac{1}{1 - ae^{-j\omega}} - \frac{ae^{j\omega}}{1 - ae^{j\omega}}

Let a→1a \to 1. In the second term, divide the numerator and denominator by ejωe^{j\omega}:

ejω1−ejω=1e−jω−1=−11−e−jω\frac{e^{j\omega}}{1 - e^{j\omega}} = \frac{1}{e^{-j\omega} - 1} = -\frac{1}{1 - e^{-j\omega}}

Therefore

sgn[n]↔DTFT21−e−jω,ω≠2πk\boxed{\mathrm{sgn}[n] \xleftrightarrow{DTFT} \frac{2}{1 - e^{-j\omega}}, \quad \omega \ne 2\pi k}

Since sgn[n]\mathrm{sgn}[n] has zero average value, there is no impulse at ω=0\omega = 0.

Magnitude and phase: 1−e−jω=e−jω/2⋅2jsin⁡(ω/2)1 - e^{-j\omega} = e^{-j\omega/2}\cdot 2j\sin(\omega/2), so

21−e−jω=ejω/2jsin⁡(ω/2),∣S(ejω)∣=1∣sin⁡(ω/2)∣\frac{2}{1 - e^{-j\omega}} = \frac{e^{j\omega/2}}{j\sin(\omega/2)}, \qquad |S(e^{j\omega})| = \frac{1}{|\sin(\omega/2)|}

The phase is ω2−π2\frac{\omega}{2} - \frac{\pi}{2} for 0<ω<π0 < \omega < \pi (and ω2+π2\frac{\omega}{2} + \frac{\pi}{2} for −π<ω<0-\pi < \omega < 0).

DTFT of u[n]

u[n]=12+12sgn[n]u[n] = \frac{1}{2} + \frac{1}{2}\mathrm{sgn}[n]

The constant 11 has DTFT 2π∑kδ(ω−2πk)2\pi\sum_k\delta(\omega - 2\pi k). (Its inverse DTFT over one period is 12π∫2πδ(ω)dω=1\frac{1}{2\pi}\int 2\pi\delta(\omega)d\omega = 1.) So

12↔DTFTπ∑k=−∞∞δ(ω−2πk)\frac{1}{2} \xleftrightarrow{DTFT} \pi\sum_{k=-\infty}^{\infty}\delta(\omega - 2\pi k)

By linearity:

U(ejω)=11−e−jω+π∑k=−∞∞δ(ω−2πk)\boxed{U(e^{j\omega}) = \frac{1}{1 - e^{-j\omega}} + \pi\sum_{k=-\infty}^{\infty}\delta(\omega - 2\pi k)}

Check

  • As a→1a \to 1, anu[n]→u[n]a^n u[n] \to u[n] and 11−ae−jω→11−e−jω\frac{1}{1 - ae^{-j\omega}} \to \frac{1}{1 - e^{-j\omega}}. The impulses account for the DC value of u[n]u[n].
  • Accumulation property: u[n]=∑k=−∞nδ[k]u[n] = \sum_{k=-\infty}^{n}\delta[k], which gives 11−e−jω⋅1+π⋅1⋅∑kδ(ω−2πk)\frac{1}{1 - e^{-j\omega}}\cdot 1 + \pi\cdot 1\cdot\sum_k\delta(\omega - 2\pi k), the same result.
  • This is the DT counterpart of u(t)↔1jω+πδ(ω)u(t) \leftrightarrow \frac{1}{j\omega} + \pi\delta(\omega).

Note: if sgn[n]\mathrm{sgn}[n] is defined with sgn[0]=0\mathrm{sgn}[0] = 0, it equals the version above minus δ[n]\delta[n]. Its DTFT is then 21−e−jω−1=1+e−jω1−e−jω\frac{2}{1 - e^{-j\omega}} - 1 = \frac{1 + e^{-j\omega}}{1 - e^{-j\omega}}. Using u[n]=12(1+sgn[n]+δ[n])u[n] = \frac{1}{2}(1 + \mathrm{sgn}[n] + \delta[n]) gives the same U(ejω)U(e^{j\omega}).

✓ Answer checked by Claude Opus 5.5 (high effort)

All Signals and Systems chapter 3 questions →