Skip to main content

Types of noise; Shannon-Fano and Huffman coding efficiency

Short answer

Three noise types: thermal (Johnson) noise from electron motion, shot noise from random carrier arrival, and flicker (1/f) noise in semiconductors at low frequencies. For the six-symbol source with probabilities {0.36, 0.18, 0.18, 0.12, 0.09, 0.07}, entropy is 2.3695 bits/symbol. Both Shannon-Fano and Huffman coding yield average length 2.44 bits/symbol, efficiency 97.11%, redundancy 2.89%.

Define any three types of noises. Calculate coding efficiency of a six symbol source with probabilities P = {0.36, 0.18, 0.12, 0.09, 0.07} using Shannon Fano and Huffman's coding techniques.

Three types of noise

  • Thermal (Johnson) noise: caused by random motion of free electrons in a conductor due to temperature. It is white and Gaussian, with power Pn=kTBP_n = kTB (k=1.38×10−23k = 1.38\times10^{-23} J/K).
  • Shot noise: caused by the random arrival of charge carriers crossing a junction in diodes and transistors. Its mean-square current is in2‾=2qIdcB\overline{i_n^2} = 2qI_{dc}B.
  • Flicker (1/f1/f) noise: found in semiconductor devices at low frequencies (below a few kHz); its power spectral density varies as 1/f1/f, due to surface and contact irregularities.

(Others: partition noise, transit-time noise, atmospheric and man-made external noise.)

Coding efficiency

Only five probabilities are given, and they add to 0.82, so the missing sixth probability is 1−0.82=0.181 - 0.82 = 0.18 (the standard form of this problem is P={0.36,0.18,0.18,0.12,0.09,0.07}P = \{0.36, 0.18, 0.18, 0.12, 0.09, 0.07\}).

Take x1=0.36x_1 = 0.36, x2=0.18x_2 = 0.18, x3=0.12x_3 = 0.12, x4=0.09x_4 = 0.09, x5=0.07x_5 = 0.07 and the missing symbol x6=0.18x_6 = 0.18.

Entropy:

Symbolpip_ilog⁡2(1/pi)\log_2(1/p_i)pilog⁡2(1/pi)p_i\log_2(1/p_i)
x10.361.47390.5306
x20.182.47390.4453
x30.123.05890.3671
x40.093.47390.3127
x50.073.83650.2686
x60.182.47390.4453
Total12.3695
H=2.3695 bits/symbolH = 2.3695\ \text{bits/symbol}

Shannon–Fano coding (split into groups of nearly equal probability: {0.36, 0.18} = 0.54 vs {0.18, 0.12, 0.09, 0.07} = 0.46, and so on):

Symbolpip_iStep 1Step 2Step 3Step 4Codelil_i
x10.3600002
x20.1801012
x60.1810102
x30.121101103
x40.09111011104
x50.07111111114
LˉSF=0.36(2)+0.18(2)+0.18(2)+0.12(3)+0.09(4)+0.07(4)=0.72+0.36+0.36+0.36+0.36+0.28=2.44 bits/symbolηSF=2.36952.44=97.11%\begin{aligned} \bar L_{SF} &= 0.36(2)+0.18(2)+0.18(2)+0.12(3)+0.09(4)+0.07(4) \\ &= 0.72+0.36+0.36+0.36+0.36+0.28 = 2.44\ \text{bits/symbol} \\ \eta_{SF} &= \frac{2.3695}{2.44} = 97.11\% \end{aligned}

Huffman coding (combine the two lowest each time, move the sum as high as possible; 0 to upper, 1 to lower):

Reduction (sum of two lowest moved up as high as possible):

StageProbabilities (descending)Combined
10.36, 0.18, 0.18, 0.12, 0.09, 0.070.09 + 0.07 = 0.16
20.36, 0.18, 0.18, 0.16, 0.120.16 + 0.12 = 0.28
30.36, 0.28, 0.18, 0.180.18 + 0.18 = 0.36
40.36, 0.36, 0.280.36 + 0.28 = 0.64
50.64, 0.360.64 + 0.36 = 1
Symbolpip_iHuffman codelil_i
x10.36002
x20.18102
x60.18112
x30.120113
x40.0901004
x50.0701014
LˉH=0.36(2)+0.18(2)+0.18(2)+0.12(3)+0.09(4)+0.07(4)=2.44 bits/symbolηH=2.36952.44=97.11%\begin{aligned} \bar L_{H} &= 0.36(2)+0.18(2)+0.18(2)+0.12(3)+0.09(4)+0.07(4) = 2.44\ \text{bits/symbol} \\ \eta_{H} &= \frac{2.3695}{2.44} = 97.11\% \end{aligned}
MethodLˉ\bar L (bits/symbol)EfficiencyRedundancy
Shannon–Fano2.4497.11 %2.89 %
Huffman2.4497.11 %2.89 %
Fixed length (3 bits)378.98 %21.02 %

Answer: both Shannon–Fano and Huffman give Lˉ=2.44\bar L = 2.44 bits/symbol and efficiency 97.11 % for this source (Huffman is never worse than Shannon–Fano; here they are equal).

✓ Answer checked by Claude Opus 5.5 (high effort)

All Communication Systems chapter 6 questions →