Skip to content

Latest commit

 

History

History
13 lines (7 loc) · 1020 Bytes

File metadata and controls

13 lines (7 loc) · 1020 Bytes

Hamming codes

Error checking in $2^n$ bit message packets:

  • hamming16.rs: first naive attempt at writing a checking and fixing algorithm for $16$-bit messages

  • slowhamming.rs: extension of the previous algorithm to work for $256$-bit message blocks

I did some more reading and finished the 3B1B videos on this topic and realised that all I had to do was XOR across the array and as such:

  • hamming.rs: a much more efficient and clean algorithm to check and fix Hamming codes for $256$-bit message blocks

Hamming Distance: not really related to Hamming codes in any way except that they share a name but I didn't feel like making an entire new repo for such a simple script