水平和垂直奇偶校验码

发布于 2024-09-27 12:00:42 字数 167 浏览 20 评论 0原文

我正在阅读有关水平和垂直奇偶校验码的内容。这些代码的特性之一是最终奇偶校验(右下位)等于水平奇偶校验和的模 2,也等于垂直奇偶校验和的模 2。

我不明白为什么这是真的。我可以在示例中看到它们,但我真的无法提出任何正式/直观的证据。

任何帮助/提示将不胜感激。

谢谢, 钱德

I was reading about horizontal and vertical parity check codes. One of the properties of these codes is that the final parity check (the lower right bit) is equal to modulo 2 sum of horizontal parity checks and also equal to modulo 2 of sum of vertical parity checks.

I did not understand, why this is true. I can see them in the examples but i really cant come up with any formal/intuitive proof about the same.

Any help/hints will be appreciated.

Thanks,
Chander

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

娇俏 2024-10-04 12:00:42

每行和每列都对模 2 求和。结果是所有数字的和模 2。无论您如何计数。

规则是:
((a mod c) + (b mod c)) mod c == (a+b) mod c

Each row and column is sum modulo 2. And result is sum of all numbers mod 2. It does not matter how you count.

Rule is:
((a mod c) + (b mod c)) mod c == (a+b) mod c

你列表最软的妹 2024-10-04 12:00:42

这是因为每个错误的位都会水平或垂直地传播奇偶校验。

考虑一下您的位矩阵:

A B C D
E F G H
I J K L
M N O P

现在其中一些位被错误地传输,因此总共有 y 个错误被放置周围,​​但你不知道矩阵内部的位置。

如果按行进行(因此计算水平奇偶校验),如果该行中有偶数个错误,则可以确保每行奇偶校验模 2 的总和将为 0,否则为 1。您还将确信您正在考虑所有这些,因为您对每一行都进行了这项工作。

最后,如果您想从一行中纠正一点并在另一行中更改另一行,则最终结果不会改变,因为您基本上从一行中删除 1 以将其添加到其他位置。

然后考虑按列进行操作,您最终会得到相同的行为,唯一的区别是错误可以以不同的方式分布,但将垂直奇偶校验加在一起模 2 将考虑相同的考虑因素。由于总错误数相同,因此行和列的错误总数将是偶数或奇数。

This is because every wrong bit propagates the parity either horizontally either vertically..

think about having your matrix of bits:

A B C D
E F G H
I J K L
M N O P

now some of these bits are wrongly transmitted, so you have a total of y errors that are layed around but you don't know where inside the matrix.

If you go by rows (so you calculate horizontal parity) you will be sure that the sum of every row parity modulo 2 will be 0 if you have an even number of errors in that row, 1 otherwise. You will be also sure of the fact that you are considering all of them since you do this work for every row.

Finally if you suppose to correct a bit from a row and alter another one in another one the final result won't change, since you basically remove 1 from a rows to add it elsewhere.

Then think about doing it by columns, you will end up with the same exact behaviour, the only difference is that errors can be distribuited in a different way but adding vertical parity together modulo 2 will take into account same considerations. Since the number of total errors is the same it will be an even number or an odd number either for rows and columns.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文