1
\$\begingroup\$

How many errors can a transmission system which uses code words with 7 data bits and a single parity bit (Checking for Even parity) detect at the receiving end.

While I am aware of the fact that any odd number of errors can be detected with this kind of a system, what exactly would be the answer? Or is the answer just one?

Ps. I'm not sure if this is the right Stack site to post this question. Do let me know if it isn't.

\$\endgroup\$
2
\$\begingroup\$

I'm not sure exactly what you're asking. If you fail a parity check, you are assured that there is at least one bit of the 8 in error (it may be the parity bit). There may be 3, but you have no way of distinguishing the two results. Further, if you have an even number of errors, they will result in no detected error at all.

No matter what, you have no indication which bit is in error, so parity is useless for any error correction.

Parity is generally used in systems which are reliable enough that the probability of having more than one error in N bits (N=8 in this example) is considered negligible.

\$\endgroup\$
0
\$\begingroup\$

A single parity bit within an 8-bit field allows 50 % of field bit errors to be detected. Of its 256 possible values, 128 (50 %) of them have valid parity and 128 have invalid parity.

Parity on your 7-bit value does not let you specifically detect errors in the actual value, only that the overall field's bit pattern is invalid.

\$\endgroup\$
1
  • 1
    \$\begingroup\$ @Dampmaskin, (just relocating our discussion above) easy examples are serial communications and serial data recovery. Bursts of noise from interference, faulty connections, weak input voltages and so on will not be related to the bit length going over the wire. There, multi-bit errors or word-long errors are possible and the higher the bit rate, the more bits they can corrupt. Glad you're not the phantom dv'er :-) \$\endgroup\$ – TonyM Feb 9 '20 at 21:14
0
\$\begingroup\$

We can see the parity bit as a simple checksum. No checksum system, included the parity, can assure the received datum is correct. These system can however reduce the possibility of taking bad data as good, which is totally different.

Let's start talking about a one byte checksum. For every datum (a packet) you receive, you have 256 possible values for the checksum, and of those 256, only one is correct. So, 255 among 256 possible errors are detected. That's no bad.

If now we go to the parity bit, we have only two possible values for the checksum: 0 and 1. So we can detect 1 error among 2.

The bottom line is this, I think: we can not speak about "how many errors can we detect?", instead we can speak about "how much we improve the error detection?". Using no parity bit, there is no error detection; using a single bit of checksum (a parity) we [can potentially] detect 50% of the errors. Depending on which side we look at the question, either we doubled the quality (because we halved the probability of undetected errors), or we have made an infinite step ahead.

Last thought: the parity bit protects every single byte transmitted on a serial line. Often a meaningful message is made of several bytes; if we invalidate the whole message as soon as any single byte fails the parity, then every byte in the message doubles the quality of the error detection.

\$\endgroup\$
4
  • \$\begingroup\$ Note that the probability of having two errors is much lower than the probability of having one error. This means that in real life, a single parity bit can detect much more than 50% of error conditions. \$\endgroup\$ – Dampmaskin Feb 5 '20 at 13:49
  • \$\begingroup\$ @Dampmaskin I agree but only partly. The "much lower" is quite subjective. Take for example sciencedirect.com/topics/engineering/parity-bit - the probability of one error is about 1.5% while the probability of two errors in the same word is 0.7%. The fact that 0.7% is much lower than 1.5% is debatable. \$\endgroup\$ – linuxfan says Reinstate Monica Feb 5 '20 at 16:00
  • \$\begingroup\$ @Dampmaskin, that's not true. The probability depends on the application. For example, parallel data in RAM or serial communications through a medium have very different reliabilities and failure modes, the latter varying with the medium. (Are you my downvoter-without-explanation?) \$\endgroup\$ – TonyM Feb 9 '20 at 8:33
  • \$\begingroup\$ That's interesting. I didn't think that there would be a situation where two simultaneous errors would be (nearly) as likely as one. It would be interesting to read more about the subject, if you can point me to a source. (I cannot recall ever downvoting any of your posts, so that would be no.) \$\endgroup\$ – Dampmaskin Feb 9 '20 at 11:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.