Getting Started    

Running the Hamming Code Model

To run the model, select Start from the Simulation model. The model terminates after 100 errors occur. The error rate, displayed in the top window of the Display block, is approximately .001. Note that you get slightly different results if you change the Initial seed parameters in the model or run a simulation for a different length of time.

You expect an error rate of approximately .001 for the following reason. The probability of two or more errors occurring in a code word of length 7 is

If the code words with two or more errors were decoded randomly, you would expect about half the bits in the decoded message words to be incorrect. This indicates that .001 is a reasonable value for the bit error rate.

To obtain a lower error rate for the same probability of error, you can try using a Hamming code with larger parameters. To do this, change the parameters Code word length and Message length in the Hamming Encoder and Decoder block masks. You also have to make the appropriate changes to the parameters of the Bernoulli Binary Generator block and the Binary Symmetric Channel block.


  Setting Parameters in the Hamming Code Model Displaying Frame Sizes