---
title: "Line coding 100000000001101 with HDB3 and B8ZS"
subject: "Communication Systems"
chapter: 6
key: "semester_6/communication_systems:line-codes-polarrz-diffmanch-hdb3-b8zs"
source: https://www.bctengineer.com/q/semester_6/communication_systems/line-codes-polarrz-diffmanch-hdb3-b8zs
site: BCT Engineering
---

# Line coding 100000000001101 with HDB3 and B8ZS

Communication Systems · Chapter 6: Baseband Digital Data Transmission

- Asked in: 2081 Chaitra, 10 marks
- Video: [B8ZS AND HDB3(SCRAMBLING)TUTORIAL-1 BY-SHUBHAM KUMAR](https://www.youtube.com/watch?v=dJoFqocrJuo) — Learn it by Fun
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_6/communication_systems/line-codes-polarrz-diffmanch-hdb3-b8zs
- Whole chapter: https://www.bctengineer.com/md/semester_6/communication_systems/chapter-6

## Question

Consider that the bit sequence 100000000001101 is to be transmitted. Draw the resulting waveform if the sequence is transmitted using Polar RZ, Differential Manchester, HDB3 and B8ZS, and compare their bandwidths.

## Short answer

Polar RZ: half-width ±V pulses. Differential Manchester: mid‑bit transition always; start transition for 0, none for 1. HDB3: AMI with 000V or B00V replacing 4 zeros. B8ZS: AMI with 000VB0VB replacing 8 zeros. Bandwidths: Polar RZ and Diff Manchester ≈ 2Rb; HDB3 and B8ZS ≈ Rb, all with no DC.

## Answer

Bit sequence: **1 0 0 0 0 0 0 0 0 0 0 1 1 0 1** (15 bits: a 1, ten 0s, then 1101). Each waveform is drawn in two parts: bits 1–8, then bits 9–15.

#### Polar RZ
1 is sent as a +V pulse for half the bit, and 0 as a −V pulse for half the bit. The line returns to zero in the second half of every bit.

**Polar RZ**

```text
    1   0   0   0   0   0   0   0  
+V ──|                             
 0   |─| |─| |─| |─| |─| |─| |─| |─
-V     |─| |─| |─| |─| |─| |─| |─| 

    0   0   0   1   1   0   1  
+V             |─| |─|     |─| 
 0   |─| |─| |─| |─| |─| |─| |─
-V ──| |─| |─|         |─|     
```

#### Differential Manchester
There is always a transition at the middle of each bit (used for the clock). Data is carried by the start of the bit: **0 = transition at the start**, **1 = no transition at the start**. The line is assumed to be at −V before the first bit.

**Differential Manchester**

```text
    1   0   0   0   0   0   0   0  
+V   |─| |─| |─| |─| |─| |─| |─| |─
-V ──| |─| |─| |─| |─| |─| |─| |─| 

    0   0   0   1   1   0   1  
+V   |─| |─| |───|   |─| |───| 
-V ──| |─| |─|   |───| |─|   |─
```

#### HDB3 (High Density Bipolar 3)
HDB3 is AMI, except that every run of four 0s is replaced:
- **000V** if the number of pulses since the last substitution is odd,
- **B00V** if it is even.

V (violation) has the **same** polarity as the pulse before it. B follows the normal AMI rule. This makes successive V pulses alternate, so no DC builds up.

- Bit 1 → +.
- Zeros 2–5: 1 pulse since start (odd) → 000V = 0 0 0 +.
- Zeros 6–9: 0 pulses since the last V (even) → B00V = − 0 0 −.
- Zeros 10–11 → 0 0.
- 1101 → + − 0 +.

HDB3 pulses: **+ 0 0 0 + − 0 0 − 0 0 + − 0 +**

**HDB3 (half-width pulses)**

```text
    1   0   0   0   0   0   0   0  
+V ──|             |─|             
 0   |─────────────| |─| |─────────
-V                     |─|         

    0   0   0   1   1   0   1  
+V             |─|         |─| 
 0   |─────────| |─| |─────| |─
-V ──|             |─|         
```

#### B8ZS (Bipolar with 8-Zero Substitution)
B8ZS is AMI, except that every run of eight 0s is replaced by **000VB0VB**. Taking the previous pulse as +, the substitute is 0 0 0 + − 0 − +.

- Bit 1 → +.
- Zeros 2–9 → 0 0 0 + − 0 − +.
- Zeros 10–11 → 0 0.
- 1101: the last pulse was +, so this gives − + 0 −.

B8ZS pulses: **+ 0 0 0 + − 0 − + 0 0 − + 0 −**

**B8ZS (half-width pulses)**

```text
    1   0   0   0   0   0   0   0  
+V ──|             |─|             
 0   |─────────────| |─| |─────| |─
-V                     |─|     |─| 

    0   0   0   1   1   0   1  
+V ──|             |─|         
 0   |─────────| |─| |─────| |─
-V             |─|         |─| 
```

#### Bandwidth comparison
| Code | Main-lobe (first-null) bandwidth | DC component | Remarks |
|---|---|---|---|
| Polar RZ | $2R_b$ | None (equiprobable bits) | Pulses half-width, so double bandwidth |
| Differential Manchester | $2R_b$ | None | Self-clocking, polarity-insensitive |
| HDB3 | $R_b$ (most power near $R_b/2$) | None | Bipolar; keeps timing on long 0 runs (E1) |
| B8ZS | $R_b$ (most power near $R_b/2$) | None | Bipolar; keeps timing on long 0 runs (T1) |

HDB3 and B8ZS need about **half the bandwidth** of polar RZ and differential Manchester, and they still keep timing information when long strings of 0s occur.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. In differential Manchester, how is data carried?
   A. 1 = transition at start of bit, 0 = no transition
   B. 0 = transition at start of bit, 1 = no transition at start; there is always a mid-bit transition
   C. By the polarity of the mid-bit transition only
   D. By alternate polarity of 1s
   Answer: B. A mid-bit transition always exists for the clock; a 0 adds a transition at the start of the bit, a 1 does not. (Key point: Differential Manchester rule)

2. In HDB3, a run of four zeros is replaced by 000V or B00V. When is B00V used?
   A. When the number of pulses since the last substitution is even
   B. When the number of pulses since the last substitution is odd
   C. Always
   D. Never; B8ZS uses it
   Answer: A. Even count gives B00V; odd gives 000V. This makes successive V pulses alternate, so no DC builds up. (Key point: HDB3 substitution)

3. What replaces a run of eight 0s in B8ZS?
   A. 000VB0VB
   B. B00V
   C. 00000000 unchanged
   D. VB000VB0
   Answer: A. B8ZS replaces eight 0s with 000VB0VB, containing two violations, so DC is balanced. (Key point: B8ZS substitution)

4. How do the bandwidths compare?
   A. HDB3 and B8ZS need about 2Rb, polar RZ needs Rb
   B. HDB3 and B8ZS need about Rb, half of polar RZ and differential Manchester (2Rb)
   C. All need 2Rb
   D. All need Rb/2
   Answer: B. Polar RZ and differential Manchester have 2Rb first-null bandwidth, while bipolar HDB3/B8ZS need about Rb and still keep timing. (Key point: Bandwidth comparison)

## Related in Communication Systems

- [Line coding 110011000001 (unipolar RZ, Manchester, HDB3)](https://www.bctengineer.com/question.md?key=semester_6%2Fcommunication_systems%3Aline-codes-110011000001) — Communication Systems, chapter 6
- [Line coding 1011001010 (polar NRZ, polar RZ, Manchester, AMI)](https://www.bctengineer.com/question.md?key=semester_6%2Fcommunication_systems%3Aline-codes-1011001010) — Communication Systems, chapter 6, asked 8×
- [Line coding 1001001101 (polar NRZ, polar RZ, Manchester, AMI)](https://www.bctengineer.com/question.md?key=semester_6%2Fcommunication_systems%3Aline-codes-1001001101) — Communication Systems, chapter 6, asked 8×
- [Line coding 1001101101 (unipolar NRZ, polar RZ, AMI, Manchester)](https://www.bctengineer.com/question.md?key=semester_6%2Fcommunication_systems%3Aline-codes-1001101101) — Communication Systems, chapter 6, asked 8×
- [Line coding 1101010111 (polar NRZ, polar RZ, Manchester, AMI)](https://www.bctengineer.com/question.md?key=semester_6%2Fcommunication_systems%3Aline-codes-1101010111-polar-ami) — Communication Systems, chapter 6, asked 8×
- [Line coding 10110101 (polar NRZ, unipolar RZ, AMI, Manchester)](https://www.bctengineer.com/question.md?key=semester_6%2Fcommunication_systems%3Aline-codes-10110101) — Communication Systems, chapter 6, asked 8×

## Related in other subjects

- [Line coding: polar RZ and bipolar AMI](https://www.bctengineer.com/question.md?key=semester_5%2Fdata_communication%3Aline-coding-polar-rz-ami) — Data Communication, chapter 5
- [B8ZS line coding](https://www.bctengineer.com/question.md?key=semester_5%2Fdata_communication%3Ab8zs-coding) — Data Communication, chapter 5, asked 2×
- [HDB3 (HD3S) line coding](https://www.bctengineer.com/question.md?key=semester_5%2Fdata_communication%3Ahdb3-coding) — Data Communication, chapter 5, asked 2×
- [Line coding waveforms for 1101110111](https://www.bctengineer.com/question.md?key=semester_5%2Fdata_communication%3Aline-coding-1101110111) — Data Communication, chapter 5
