Loading content...
While North America developed B8ZS for its T-carrier systems, the rest of the world took a different path. The CCITT (now ITU-T) developed HDB3 (High-Density Bipolar 3-zeros) as the international standard for zero suppression in E-carrier systems and beyond.
HDB3 embodies the same fundamental insight as B8ZS—using intentional bipolar violations to signal zero sequences—but with a crucial difference: HDB3 substitutes after only 4 consecutive zeros, compared to B8ZS's 8. This more aggressive approach provides stronger synchronization guarantees but requires more sophisticated encoding logic.
Understanding HDB3 is essential for anyone working with international telecommunications, as it is the standard used in E1 (2.048 Mbps), E2 (8.448 Mbps), E3 (34.368 Mbps), and higher-order systems throughout Europe, Asia, Africa, and South America.
By the end of this page, you will master HDB3 encoding and decoding, understand its more complex substitution rules, compare its properties with B8ZS, and appreciate why HDB3 became the dominant international standard for wired digital transmission.
HDB3 builds on the same AMI (Alternate Mark Inversion) foundation as B8ZS, but with different design choices:
Key Differences from B8ZS:
| Aspect | B8ZS | HDB3 |
|---|---|---|
| Trigger | 8 consecutive zeros | 4 consecutive zeros |
| Pattern length | 8 bits | 4 bits |
| Violation count | 2 per substitution | 1 or 2 per substitution |
| DC balance method | Always 2+2 pulses | Conditional B pulse |
| Complexity | Simpler | More complex |
The HDB3 Design Philosophy:
HDB3 targets a maximum of 3 consecutive zeros (hence the '3' in HDB3). By acting at 4 zeros rather than 8, HDB3 provides:
The tradeoff is increased complexity and slightly more frequent substitution overhead.
| Condition | Pattern | Example |
|---|---|---|
| Odd number of 1s since last substitution, last pulse + | 000+ | Previous: + → Substitute: 000+ |
| Odd number of 1s since last substitution, last pulse - | 000- | Previous: - → Substitute: 000- |
| Even number of 1s since last substitution, last pulse + | +00+ | Previous: + → Substitute: +00+ |
| Even number of 1s since last substitution, last pulse - | -00- | Previous: - → Substitute: -00- |
Understanding the Substitution Logic:
HDB3's substitution patterns are more nuanced than B8ZS because HDB3 must maintain DC balance while using only 4 bit positions. The key insight is that HDB3 uses two types of substitution patterns:
Pattern Type 1: 000V (when ones count is odd)
Pattern Type 2: B00V (when ones count is even)
Why Two Patterns?
The clever design ensures overall DC balance:
HDB3 maintains DC balance through a clever tracking mechanism: when the number of 1s since the last substitution is even, an extra balance pulse (B) is added to ensure the averaged signal is zero. This pulse follows AMI rules, so it doesn't violate polarity—only the V pulse is a violation.
HDB3 encoding requires tracking two state variables:
The Encoding Algorithm:
Initialize:
last_polarity = undefined (first pulse can be either)
ones_count = 0
For each input bit:
If bit = 1:
Transmit pulse with polarity opposite to last_polarity
Update last_polarity
ones_count = ones_count + 1
If bit = 0:
Add to zero_run_buffer
If zero_run_buffer has 4 zeros:
If ones_count is odd:
Transmit 000V (V has same polarity as last_polarity)
Update last_polarity to V's polarity
Else (ones_count is even):
Transmit B00V (B is opposite of last_polarity, V is same as B)
Update last_polarity to V's polarity
ones_count = 0
Clear zero_run_buffer
Else:
(Wait for more bits)
Detailed Example:
Let's encode: 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1
This contains two groups: first 4 zeros, then 8 zeros (which will trigger two substitutions).
Step 1: Bit 1 (data 1)
Step 2-5: Bits 2-5 (0000)
Step 6: Bit 6 (data 1)
Step 7-10: Bits 7-10 (0000)
Step 11-14: Bits 11-14 (0000)
Step 15: Bit 15 (data 1)
| Position | 1 | 2-5 | 6 | 7-10 | 11-14 | 15 |
|---|---|---|---|---|---|---|
| Data | 1 | 0000 | 1 | 0000 | 0000 | 1 |
| HDB3 | 000+ | 000- | +00+ | |||
| Type | Data | 000V | Data | 000V | B00V | Data |
| Violation? | No | Pos 5 | No | Pos 10 | Pos 14 | No |
Notice how the first two substitutions used 000V (because ones_count was odd—there was one data 1 between them), but the third substitution used B00V (because ones_count was zero after reset). This alternation is key to HDB3's DC balance maintenance.
HDB3 decoding exploits the fact that violations are recognizable:
Decoding Algorithm:
For each received symbol:
If symbol is 0:
Buffer the zero
If symbol is non-zero (+ or -):
Check if this is a bipolar violation (same as last pulse)
If violation detected:
This is a V pulse
Look back for B00V or 000V pattern:
If 3 positions back is non-zero: B00V pattern
Replace last 4 symbols with 0000
Else: 000V pattern
Replace last 4 symbols with 0000
Else:
Normal pulse = output 1
Output any buffered zeros (up to 2)
Update last polarity tracking
Decoding the Previous Example:
Received: + 0 0 0 + - 0 0 0 - + 0 0 + -
| Position | Received | Last Polarity | Violation? | Action | Output |
|---|---|---|---|---|---|
| 1 | — | No (first) | Normal pulse | 1 | |
| 2-4 | 000 | — | Buffer zeros | (waiting) | |
| 5 | Yes! (same) | Detect V, check pattern | — | ||
| — | — | — | — | Position 2 is 0 → 000V | 0000 |
| 6 | No (opposite) | Normal pulse | 1 | ||
| 7-9 | 000 | — | Buffer zeros | (waiting) | |
| 10 | Yes! (same) | Detect V, check pattern | — | ||
| — | — | — | — | Position 7 is 0 → 000V | 0000 |
| 11 | No (opposite) | Check for B... | — | ||
| 12-13 | 00 | — | Buffer zeros | (waiting) | |
| 14 | Yes! (same) | Detect V, check pattern | — | ||
| — | — | — | — | Position 11 is + → B00V | 0000 |
| 15 | No (opposite) | Normal pulse | 1 |
Final decoded output: 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1
✓ Matches original data exactly!
Distinguishing B00V from 000V:
The decoder determines which pattern was used by examining the symbol 3 positions before the violation:
This works because:
Handling Ambiguity:
Could a normal AMI sequence look like a B pulse? Consider a data sequence 1 0 0 0 0:
But wait—the incoming data '1' just set ones_count to 1 (odd), so 000V would be used instead!
The algorithm ensures that whenever a real data '1' occurs immediately before zeros, ones_count is odd, and 000V is used. B00V only occurs when the preceding positions were also substitution or the count accumulated to even.
HDB3's patterns are self-documenting: the violation (V) is always detectable because it violates AMI rules, and the pattern type (B00V vs 000V) is determined by looking at whether there's a pulse at the start of the 4-bit sequence. This makes decoding robust and unambiguous.
HDB3's DC balance mechanism is more subtle than B8ZS's and deserves detailed analysis.
The Challenge:
With only 4 bit positions, HDB3 can't guarantee internal DC balance within each substitution like B8ZS does with its 2+2 pattern. Instead, HDB3 achieves DC balance over multiple substitutions.
Analyzing 000V:
The 000V pattern contains one pulse:
Without correction, consecutive 000V patterns could accumulate DC:
000+ 000+ 000+ → DC accumulation of +3
The B Pulse's Role:
The B00V pattern contains two pulses of the same polarity:
This seems worse! But the key is when B00V is used.
The Balancing Act:
Consider what happens with long zero runs:
| Substitution | ones_count | Pattern | Pulses | DC Added | Cumulative DC |
|---|---|---|---|---|---|
| 1st | 0 (even) | B00V | +00+ | +2 | +2 |
| 2nd | 0 (even) | B00V | -00- | -2 | 0 |
| 3rd | 0 (even) | B00V | +00+ | +2 | +2 |
| 4th | 0 (even) | B00V | -00- | -2 | 0 |
With continuous zeros, B00V alternates polarity, and DC oscillates between +2 and 0, never accumulating unbounded.
With Mixed Data:
When data contains ones between zero runs, the pattern changes:
| Event | ones_count Before | Pattern/Data | Change | Balance Effect |
|---|---|---|---|---|
| Data 1 | 0 → 1 |
| +1 | — |
| 4 zeros | 1 (odd) | 000+ | +1 | V matches last |
| Data 1 | 0 → 1 |
| -1 | Opposite of last V |
| 4 zeros | 1 (odd) | 000- | -1 | V matches last |
| Net | — | — | 0 | Balanced! |
Why It Works:
The mathematical insight is:
Data 1s alternate polarity by AMI rules, contributing net zero DC over time
000V patterns inherit the last polarity, so they track the alternation
B00V patterns occur when ones_count is even, meaning an equal number of + and - data pulses have occurred since the last substitution
B pulses follow AMI rules, so they also alternate
V pulses in B00V match B, creating pairs that alternate each substitution
Proof of Bounded DC:
Let's prove that DC never exceeds bounded limits:
Maximum DC deviation is bounded by 2 pulse units, regardless of input data.
While HDB3's DC balance isn't perfect cycle-by-cycle like B8ZS, the bounded deviation is acceptable for transformer-coupled systems. The transformers and coupling capacitors have enough energy storage capacity to handle momentary imbalances without causing baseline wander.
Understanding the differences between HDB3 and B8ZS illuminates the design tradeoffs in zero suppression techniques.
| Aspect | HDB3 | B8ZS |
|---|---|---|
| Zero run trigger | 4 consecutive zeros | 8 consecutive zeros |
| Maximum zeros | 3 consecutive | 3 consecutive (in pattern) |
| Pattern length | 4 bits | 8 bits |
| Violations per pattern | 1 (000V) or 2 (B00V) | Always 2 |
| DC balance method | B pulse when needed | Always 2+2 pulses |
| DC balance quality | Bounded, may deviate ±2 | Perfect within pattern |
| Clock recovery | Stronger (max 3 zeros) | Good (max 3 zeros) |
| Encoding complexity | Higher (track ones_count) | Lower (only polarity) |
| Substitution frequency | Higher (more triggers) | Lower (fewer triggers) |
| Primary usage | E1, E2, E3, ITU-T world | T1, DS1, North America |
| Standards body | ITU-T (CCITT) | ANSI, Telcordia |
Historical Context:
The different approaches reflect different evolutionary paths:
T-Carrier (North American) Evolution:
E-Carrier (International) Evolution:
Why Both Survive:
Neither standard displaced the other because:
Modern equipment often supports both, configurable for the region.
Higher-speed systems (SONET/SDH, 10G Ethernet, etc.) use scrambling techniques that supersede both HDB3 and B8ZS. These older techniques remain relevant for legacy T1/E1 infrastructure, which still forms the 'last mile' in many telecommunications networks.
Understanding how HDB3 operates within E1 systems provides practical context for its application.
E1 System Overview:
The E1 carrier system transmits 2.048 Mbps (slightly faster than T1's 1.544 Mbps):
Unlike T1's 24 channels, E1 provides 30 user channels—a 25% capacity advantage.
| Parameter | E1 (ITU-T) | T1 (North America) |
|---|---|---|
| Line rate | 2.048 Mbps | 1.544 Mbps |
| Frame size | 256 bits (32 × 8) | 193 bits (24 × 8 + 1) |
| User channels | 30 | 24 |
| User data rate | 1.920 Mbps | 1.536 Mbps (clear channel) |
| Frame rate | 8,000 fps | 8,000 fps |
| Bit period | 488 ns | 648 ns |
| Line coding | HDB3 | B8ZS (or AMI) |
| Max zeros | 3 consecutive | 3 consecutive (with B8ZS) |
HDB3 Application Points:
Traffic Data → E1 Framing → HDB3 Encoding → AMI Line Transmission
HDB3 operates at the physical layer, processing the complete 2.048 Mbps bit stream including frame overhead.
Frame Alignment Word (FAW):
E1 uses a Frame Alignment Word in time slot 0 for synchronization:
The FAW pattern is carefully chosen:
CRC-4 Multiframe:
Modern E1 uses CRC-4 for error monitoring:
HDB3 is applied independently of the CRC-4 structure—it operates on the continuous bit stream regardless of higher-level framing.
When troubleshooting E1 circuits, HDB3 violations that don't form valid patterns indicate transmission errors. Modern test equipment counts these 'code violations' separately from decoded errors, helping isolate physical layer problems from higher-layer issues.
While E1 is HDB3's most common application, the technique is used throughout the PDH (Plesiochronous Digital Hierarchy) at multiple rates.
| Level | Bit Rate | E1 Equivalent | Zero Suppression |
|---|---|---|---|
| E1 | 2.048 Mbps | 1 × E1 | HDB3 |
| E2 | 8.448 Mbps | 4 × E1 | HDB3 |
| E3 | 34.368 Mbps | 16 × E1 | HDB3 |
| E4 | 139.264 Mbps | 64 × E1 | CMI* |
| E5 | 565.148 Mbps | 256 × E1 | CMI/Optical |
*CMI = Coded Mark Inversion, a different technique used at E4 and above
Why HDB3 at E2 and E3?
At higher bit rates (E2: 8.448 Mbps, E3: 34.368 Mbps), the challenge of clock recovery intensifies:
HDB3's guarantee of maximum 3 consecutive zeros remains critical at these rates. The algorithm scales directly—the same encoding rules apply, just at faster rates.
E3 Specifically:
E3 (34.368 Mbps) carries 16 E1s or 480 voice channels:
Bit period: 29.1 ns
Maximum zero run (with HDB3): 3 bits = 87.3 ns
Without zero suppression: Unlimited → clock loss
At this speed, clock recovery circuits are already challenged. Without HDB3, even moderate zero runs would cause problems.
The Transition to CMI:
At E4 (139.264 Mbps) and above, HDB3 is replaced by CMI (Coded Mark Inversion):
CMI's advantage at very high speeds is its guaranteed transition every bit period, eliminating any dependence on data patterns.
The PDH hierarchy (E1, E2, E3, etc.) has been largely superseded by SDH (Synchronous Digital Hierarchy) and SONET for backbone transport. These synchronous systems use different scrambling techniques. However, E1 with HDB3 remains ubiquitous for customer access and legacy circuits.
We have thoroughly explored HDB3, the international standard for zero suppression. Let's consolidate the essential knowledge:
Looking Ahead:
With B8ZS and HDB3 mastered, you understand the two major substitution-based zero suppression techniques. The next page explores Randomization—the mathematical foundations of pseudo-random sequence generation that underpin more general scrambling techniques used in modern high-speed systems.
Randomization extends beyond simple substitution to transform entire data streams, enabling even stronger guarantees for clock recovery and spectral properties.
You now understand HDB3 encoding and decoding, including both substitution patterns, the ones-count tracking mechanism, and practical applications in E-carrier systems. This knowledge is essential for international telecommunications work.