Skip to content
User Avatar
#1056
Auto-translated
Well, I did use hash functions in one case, but I called them parity for two bits. But the idea itself is interesting, to transmit the function directly instead of the message itself.

Added 1 hour 2 minutes ago
Function F is a hash, which is also parity (0 - identical characters, 1 - different characters). The message itself is ABCD, and the numbers are the bit numbers. Bit 1: F(A, B) Bit 2: F(C, D) Bit 3: F(1, 2) The presence or absence of an error can be seen among the first three bits. Bit 4: F(A, D) Bit 5: F(B, C) Bit 6: A Bit 7: C If there is an error in the first three bits, we can still read the message. Let's assume there is no error there. We can check for an error in bits 4 and 5: We definitely know from bits 1 and 2 whether A and B are the same or different, and C and D are the same or different. That is, 00, 01, 10, or 11. If bits 1 and 2 have values of 00 or 11, then bits 4 and 5 should also be either 00 or 11 (both combinations of identical values are allowed). For 01 and 10, the unknown values, if there is no error, should also be 01 and 00. If there is an error among bits 4 and 5, we still construct the message using bits 1, 2, 6, and 7. Let's assume there is no error. The error is in A, in C, or there is no error at all. If there is no error at all, then by substituting A and C into functions 1, 2, and 3, 4, we get the original message in both cases, and it will be the same. If it is different, then by inverting either A or C, we can absolutely accurately determine F(A, C). I don't know why, but it seems that by solving a system of equations with this function and the functions from bits 1-2, 4-5, we can find out whether the error is in A or C. But it seems not, but I'm too lazy to think about it anymore. But I have improved the previous result. I can read the message in 5 cases of a corrupted bit and in the case of no error, and only in the case of corruption of two specific bits do I have 2 message options, and I know about it. We can also try, but take the control bit (bit 3) as F(2, 6).