{"id":1540,"date":"2011-11-03T10:11:21","date_gmt":"2011-11-03T10:11:21","guid":{"rendered":"http:\/\/gigihfordanama.wordpress.com\/?p=1540"},"modified":"2012-08-08T00:00:46","modified_gmt":"2012-08-08T00:00:46","slug":"penjelasan-tentang-hamming-code","status":"publish","type":"post","link":"https:\/\/dosen.unila.ac.id\/gigih\/2011\/11\/03\/penjelasan-tentang-hamming-code\/","title":{"rendered":"Penjelasan tentang Hamming Code"},"content":{"rendered":"<p><strong>Code Creation<\/strong><\/p>\n<p>Mark all bit positions that are powers of two as parity bits. (positions 1, 2, 4, 8, 16, 32, 64, etc.)\u00a0 All other bit positions are for the data to be encoded. (positions 3, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 17, etc.)\u00a0 Each parity bit calculates the parity for some of the bits in the code word. The position of the parity bit determines the sequence of bits that it alternately checks and skips.<\/p>\n<p><strong>Position 1:<\/strong> check 1 bit, skip 1 bit, check 1 bit, skip 1 bit, etc.\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 (1,3,5,7,9,11,13,15,&#8230;)<br \/>\n<strong>Position 2:<\/strong> check 2 bits, skip 2 bits, check 2 bits, skip 2 bits, etc. \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 (2,3,6,7,10,11,14,15,&#8230;)<br \/>\n<strong>Position 4:<\/strong> check 4 bits, skip 4 bits, check 4 bits, skip 4 bits, etc. (4,5,6,7,12,13,14,15,20,21,22,23,&#8230;)<br \/>\n<strong>Position 8:<\/strong> check 8 bits, skip 8 bits, check 8 bits, skip 8 bits, etc.\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 (8-15,24-31,40-47,&#8230;)<br \/>\n<strong>Position 16:<\/strong> check 16 bits, skip 16 bits, check 16 bits, skip 16 bits, etc. (16-31,48-63,80-95,&#8230;)<br \/>\n<strong>Position 32:<\/strong> check 32 bits, skip 32 bits, check 32 bits, skip 32 bits, etc. (32-63,96-127,160-191,&#8230;)<br \/>\netc.<\/p>\n<p>Set a parity bit to 1 if the total number of ones in the positions it checks is odd.<br \/>\nSet a parity bit to 0 if the total number of ones in the positions it checks is even.<\/p>\n<p><strong>Example<\/strong> <strong>1<\/strong><br \/>\n<strong>A byte of data: 01010101<\/strong><\/p>\n<p><a href=\"http:\/\/gigihfordanama.files.wordpress.com\/2011\/11\/hummingcode1.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/gigihfordanama.files.wordpress.com\/2011\/11\/hummingcode1.jpg\" alt=\"\" width=\"640\" height=\"362\" \/><\/a><\/p>\n<p style=\"text-align:justify\">Let us number the bits of this character b12, b11, b10, b9, b7, b6, b5,\u00a0 b3,\u00a0 and we will number bits from right to left (dari kanan ke kiri), leaving space for the soon-to-be-added check bits. Now add to these bits the following check bits: c8, c4, c2, and c1. where c8 generate a simple even parity for bits\u00a0 b12, b11, b10, b9\u00a0 . The check bit c4 will generate a simple even parity for bits b12, b7, b6, b5. Check bit c2 will generate a simple even parity for bits b11, b10, b7, b6, b3.\u00a0 And c1 will generate a simple even parity for bits b11, b9, b7, b5, b3. Note that each bit here is checking different sequence of data bits.<\/p>\n<p style=\"text-align:justify\"><!--more--><br \/>\n<img decoding=\"async\" src=\"http:\/\/gigihfordanama.wordpress.com\/wp-includes\/js\/tinymce\/plugins\/wordpress\/img\/trans.gif\" alt=\"\" \/><strong>Position 1<\/strong> checks bits 1,3,5,7,9,11:\u00a0 (check beginning bit\u00a0 from left to right)<\/p>\n<p>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 ?\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 ?\u00a0\u00a0 1\u00a0\u00a0 ?\u00a0\u00a0 (? find value position1 )\u00a0 shown that this parity\u00a0 error<\/p>\n<p>1\u00a0\u00a0\u00a0 1\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 1\u00a0 (Generate sum of all check bit , the value is 1)<\/p>\n<p>Even parity so set position 1 to a 1:\u00a0\u00a0 <strong>0\u00a0 1\u00a0 0\u00a0 1\u00a0 _\u00a0\u00a0 0\u00a0 1\u00a0 0\u00a0\u00a0 _\u00a0 1\u00a0 _\u00a0 1<\/strong><\/p>\n<p><strong>Position 2<\/strong> checks bits 2,3,6,7,10,11: (check beginning bit from left to right, put the c1 bit also)<\/p>\n<p>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 _\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 _\u00a0\u00a0 1\u00a0\u00a0 (? find value position2 )\u00a0 1\u00a0\u00a0 shown that this parity no error<\/p>\n<p>1\u00a0\u00a0 0\u00a0\u00a0 0\u00a0\u00a0\u00a0 1\u00a0\u00a0 1\u00a0 (Generate sum of all check bit , the value is 1)<\/p>\n<p>Odd parity so set position 2 to a 1:\u00a0 <strong>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 _\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 _\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1<\/strong><\/p>\n<p><strong>Position 4<\/strong> checks bits 4,5,6,7,12:<\/p>\n<p>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 _\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 ?\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1<\/p>\n<p>0\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0 (Generate sum of all check bit , the value is 1) shown that this parity no error<\/p>\n<p>Odd parity so set position 4 to a 1:\u00a0 <strong>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 _\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1<\/strong><\/p>\n<p><strong>Position 8<\/strong> checks bits 8,9,10,11,12:<\/p>\n<p>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 ?\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1<\/p>\n<p>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1 (Generate sum of all check bit , the value is 0)\u00a0 shown that this parity error<\/p>\n<p>Even parity so set position 8 to a 0:\u00a0 <strong>0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1<\/strong><\/p>\n<p>Finally we find the code word\u00a0 :\u00a0\u00a0<strong> 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 0\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1\u00a0\u00a0 1<\/strong><\/p>\n<p><strong>Example<\/strong> <strong>2<\/strong><\/p>\n<p>Test if these code words are correct, assuming they were created using an even parity Hamming Code\u00a0. If one is incorrect, indicate what the correct code word should have been. Also, indicate what the original data was.<\/p>\n<p><strong>a.\u00a0 010101100011\u00a0 <\/strong>all bit is right<br \/>\n<strong>b.\u00a0 111110001100\u00a0 <\/strong>bit 11 is wrong,\u00a0 should be 101110001100<br \/>\n<strong><br \/>\n<\/strong><\/p>\n<p>Kekurangan si Hamming code ini, satu parity hanya bisa untuk pengecekan 1 bit data tidak bisa lebih dari itu.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Code Creation Mark all bit positions that are powers of two as parity bits. (positions 1, 2, 4, 8, 16, 32, 64, etc.)\u00a0 All other bit positions are for the data to be encoded. (positions 3, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 17, etc.)\u00a0 Each parity bit calculates the parity for &hellip; <a href=\"https:\/\/dosen.unila.ac.id\/gigih\/2011\/11\/03\/penjelasan-tentang-hamming-code\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Penjelasan tentang Hamming Code&#8221;<\/span><\/a><\/p>\n","protected":false},"author":25,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1348,7],"tags":[396,917],"class_list":["post-1540","post","type-post","status-publish","format-standard","hentry","category-kiat-sukses-menjadi-seorang-network-engineer-2","category-world-of-academic","tag-hamming-code","tag-penjelasan-tentang-hamming-code"],"_links":{"self":[{"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/posts\/1540"}],"collection":[{"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/users\/25"}],"replies":[{"embeddable":true,"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/comments?post=1540"}],"version-history":[{"count":0,"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/posts\/1540\/revisions"}],"wp:attachment":[{"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/media?parent=1540"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/categories?post=1540"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dosen.unila.ac.id\/gigih\/wp-json\/wp\/v2\/tags?post=1540"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}