- Data Structures & Algorithms
- DSA - Home
- DSA - Overview
- DSA - Environment Setup

- Algorithm
- DSA - Algorithms Basics
- DSA - Asymptotic Analysis
- DSA - Greedy Algorithms
- DSA - Divide and Conquer
- DSA - Dynamic Programming

- Data Structures
- DSA - Data Structure Basics
- DSA - Array Data Structure

- Stack & Queue
- DSA - Stack
- DSA - Expression Parsing
- DSA - Queue

- Searching Techniques
- DSA - Linear Search
- DSA - Binary Search
- DSA - Interpolation Search
- DSA - Hash Table

- Sorting Techniques
- DSA - Sorting Algorithms
- DSA - Bubble Sort
- DSA - Insertion Sort
- DSA - Selection Sort
- DSA - Merge Sort
- DSA - Shell Sort
- DSA - Quick Sort

- Graph Data Structure
- DSA - Graph Data Structure
- DSA - Depth First Traversal
- DSA - Breadth First Traversal

- Tree Data Structure
- DSA - Tree Data Structure
- DSA - Tree Traversal
- DSA - Binary Search Tree
- DSA - AVL Tree
- DSA - Spanning Tree
- DSA - Heap

- DSA Useful Resources
- DSA - Questions and Answers
- DSA - Quick Guide
- DSA - Useful Resources
- DSA - Discussion

# Back-off Algorithm for CSMA/CD

**Back Off Algorithm** is an algorithm used for collision resolution. It works as,

When this collision occurs, both the devices wait for a random amount of time before retransmitting the signal again, they keep on trying until the data is transferred successfully. This is called back off, since the nodes ‘back-off’ for a certain amount of time, before they try to re-access it again. *This random amount of time is directly proportional to the number of attempts it has made to transmit the signal.*

## Algorithm

Below is a simple flowchart to explain the Back Off Algorithm in brief.

As can be seen, that after each iteration value of N increases and so does the range [0,2^n-1], this way the probability of collisions decreases!

Moreover, it can be a drawback in some cases because continuous back-off can cause some nodes to discard packets. After all, maximum attempt limits have been reached.

So, after the collision, each node has to wait for a certain amount of time which is given by the formula,

Waiting time = K * Tslot

T_{slot} is the discrete-time slot of length equal to 2t, where t is the maximum propagation delay in the network.

K = [0, 2^{n} -1]. n is the collision number.

- Related Articles
- CSMA with Collision Detection (CSMA/CD)\n
- Difference between CSMA/CA and CSMA/CD
- CSMA/CD with the Binary Exponential Backoff
- CSMA with Collision Avoidance (CSMA/CA)\n
- Non-persistent CSMA protocol
- P-persistent CSMA protocol\n
- Rate Anomaly in CSMA/CA
- C Program for Reversal algorithm for array rotation
- C Program for Naive algorithm for Pattern Searching
- C Program for KMP Algorithm for Pattern Searching
- Java Program for Reversal algorithm for array rotation
- Python Program for Reversal algorithm for array rotation
- Virtual channel sensing using CSMA/CA
- What is CSMA with collision detection?
- What is CSMA with collision avoidance?