Sunday, December 31, 2023

Error detecting codes Parity bits, checksums, and cyclic redundancy checks (CRC)

Error detection codes त्रुटि पता लगाने वाले कोड:-
Parity bits, checksums, and cyclic redundancy checks (CRC) are all methods used for error detection in data communication. They involve adding additional information (bits or values) to the original data, and the receiver can use this additional information to detect whether errors have occurred during transmission.
समता बिट्स, चेकसम और चक्रीय अतिरेक जांच (सीआरसी) डेटा संचार में त्रुटि का पता लगाने के लिए उपयोग की जाने वाली सभी विधियां हैं। उनमें मूल डेटा में अतिरिक्त जानकारी (बिट्स या मान) जोड़ना शामिल है, और रिसीवर इस अतिरिक्त जानकारी का उपयोग यह पता लगाने के लिए कर सकता है कि ट्रांसमिशन के दौरान त्रुटियां हुई हैं या नहीं।

1. Parity Bits समता बिट्स:-
Parity is a simple method that adds an extra bit to a group of bits to make the total number of ones either even or odd.The most common types are even parity and odd parity.Even parity means that the total number of ones, including the parity bit, is even.
Example:-
Original data: 1011
Parity bit added for even parity: 1011 1
If an odd number of bits are in error, the error will be detected. Parity bits can only detect single-bit errors.

समता एक सरल विधि है जो बिट्स के समूह में एक अतिरिक्त बिट जोड़ती है ताकि बिट्स की कुल संख्या सम या विषम हो। सबसे सामान्य प्रकार सम समता और विषम समता हैं। सम समता का मतलब है कि बिट्स की कुल संख्या, जिसमें शामिल हैं समता बिट, सम है.
उदाहरण:-
मूल डेटा: 1011
सम समता के लिए समता बिट जोड़ा गया: 1011 1
यदि विषम संख्या में बिट्स त्रुटिपूर्ण हैं, तो त्रुटि का पता लगाया जाएगा। समता बिट्स केवल एकल-बिट त्रुटियों का पता लगा सकते हैं।

2. Checksums चेकसम :-

Checksums involve summing up the values of all the data units (such as bytes) and adding this sum to the transmitted data.The receiver performs the same calculation on the received data and checks if the calculated sum matches the sum included in the transmitted data.
Example:-
Suppose we have data bytes: 1101 0110 1010.
Calculate the sum: 1101 + 0110 + 1010 = 01001.
Add this sum to the data: 1101 0110 1010 01001.
The receiver performs the same calculation and checks if the sum matches and If it is different then error will be detected. Checksums can detect errors in groups of bits and are widely used in networking protocols.

चेकसम में सभी डेटा इकाइयों (जैसे बाइट्स) के मूल्यों को जोड़ना और इस योग को प्रेषित डेटा में जोड़ना शामिल है। रिसीवर प्राप्त डेटा पर समान गणना करता है और जांचता है कि गणना की गई राशि प्रेषित डेटा में शामिल योग से मेल खाती है या नहीं।
उदाहरण:-
मान लीजिए हमारे पास डेटा बाइट्स हैं: 1101 0110 1010
योग की गणना करें: 1101 + 0110 + 1010 = 01001
इस योग को डेटा में जोड़ें: 1101 0110 1010 01001
रिसीवर समान गणना करता है और जाँचता है कि क्या योग मेल खाता है और यदि यह भिन्न है तो त्रुटि का पता लगाया जाएगा। चेकसम बिट्स के समूहों में त्रुटियों का पता लगा सकते हैं और नेटवर्किंग प्रोटोकॉल में व्यापक रूप से उपयोग किए जाते हैं।

3. Cyclic Redundancy Check (CRC) चक्रीय अतिरेक जांच (सीआरसी):-
CRC is a more sophisticated error-checking technique. It involves polynomial division, where the remainder is appended to the original data. The receiver performs the same polynomial division and checks if the remainder is zero.
Example:-
Suppose we want to send 1101101 with a CRC code.
Choose a generator polynomial, say G(x) = 1011.
Perform polynomial division:1101101 divided by 1011 = 101 (R(x) = 101).
Append the remainder to the original data: 1101101101.
The receiver performs the same division and checks if the remainder is zero. CRC can detect a broader range of errors and is commonly used in data storage and network protocols.

सीआरसी एक अधिक परिष्कृत त्रुटि-जाँच तकनीक है। इसमें बहुपद विभाजन शामिल है, जहां शेष को मूल डेटा से जोड़ा जाता है। रिसीवर समान बहुपद विभाजन करता है और जाँच करता है कि शेषफल शून्य है या नहीं।
उदाहरण:-
मान लीजिए हम सीआरसी कोड के साथ 1101101 भेजना चाहते हैं।
एक जनरेटर बहुपद चुनें, मान लीजिए G(x) = 1011
बहुपद विभाजन करें: 1101101 को 1011 से विभाजित करें = 101 (R(x) = 101)
शेषफल को मूल डेटा में जोड़ें: 1101101101
रिसीवर समान विभाजन करता है और जाँच करता है कि शेषफल शून्य है या नहीं। सीआरसी त्रुटियों की एक विस्तृत श्रृंखला का पता लगा सकता है और आमतौर पर डेटा भंडारण और नेटवर्क प्रोटोकॉल में उपयोग किया जाता है।

No comments:

Post a Comment

Data Link control Flow and Error Control

 In data communication, Data Link Control (DLC) refers to the services and protocols that ensure reliable and efficient communication betwee...