{"id":82,"date":"2008-06-30T20:32:26","date_gmt":"2008-07-01T01:32:26","guid":{"rendered":"http:\/\/www.circuitdesign.info\/?p=82"},"modified":"2020-11-02T20:08:04","modified_gmt":"2020-11-03T02:08:04","slug":"the-binary-number-system-part-2-binary-weighting","status":"publish","type":"post","link":"https:\/\/www.circuitdesign.info\/blog\/2008\/06\/the-binary-number-system-part-2-binary-weighting\/","title":{"rendered":"The Binary Number System \u2013 Part 2: Binary Weighting"},"content":{"rendered":"\n<p>In <a href=\"https:\/\/www.circuitdesign.info\/blog\/2008\/06\/the-binary-number-system-part-1-decimal-notation\/\" data-type=\"URL\" data-id=\"https:\/\/www.circuitdesign.info\/blog\/2008\/06\/the-binary-number-system-part-1-decimal-notation\/\" target=\"_blank\" rel=\"noreferrer noopener\">part 1<\/a>, I illustrated how our decimal\/Arabic number system is based on our ability to count up to nine with a single digit. After that, we add a digit (with a weighting of ten) and then continue to count the first digit from zero to nine again.<\/p>\n\n\n\n<p>The best way to explain how computers count is to show an example. Let&#8217;s review again the way we count.<\/p>\n\n\n\n<!--more-->\n\n\n\n<h2 class=\"wp-block-heading\">Three versions of 3<\/h2>\n\n\n\n<p>When someone shows three fingers to us (with one finger and a thumb folded down), we interpret the number three:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"480\" src=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures036.jpg\" alt=\"\" class=\"wp-image-68\" srcset=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures036.jpg 640w, https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures036-300x225.jpg 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/figure>\n\n\n\n<p>However, there are more ways of representing the same number:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"480\" src=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures037.jpg\" alt=\"\" class=\"wp-image-70\" srcset=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures037.jpg 640w, https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures037-300x225.jpg 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"480\" src=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures038.jpg\" alt=\"\" class=\"wp-image-72\" srcset=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures038.jpg 640w, https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures038-300x225.jpg 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/figure>\n\n\n\n<p>The reason is that we assign the same value to each finger. Any three fingers being up signifies the number three.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">All fingers are not created equal<\/h2>\n\n\n\n<p>The analogous counting system with computers is to assign different values to each finger. Look closely at the following picture (click on it if you have to). You&#8217;ll notice the numbers eight, four, two, and one on the fingers:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"522\" height=\"480\" src=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures043.jpg\" alt=\"\" class=\"wp-image-74\" srcset=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures043.jpg 522w, https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures043-300x275.jpg 300w\" sizes=\"auto, (max-width: 522px) 100vw, 522px\" \/><figcaption>Illustration 1<\/figcaption><\/figure>\n\n\n\n<p>When we see a hand with fingers up, we add up the numbers on the finger. Some examples:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"438\" height=\"480\" src=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures044copy.jpg\" alt=\"\" class=\"wp-image-76\" srcset=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures044copy.jpg 438w, https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures044copy-273x300.jpg 273w\" sizes=\"auto, (max-width: 438px) 100vw, 438px\" \/><figcaption>Illustration A: The number fourteen (8+4+2)<\/figcaption><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"485\" height=\"480\" src=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures045copy.jpg\" alt=\"\" class=\"wp-image-78\" srcset=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures045copy.jpg 485w, https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures045copy-300x296.jpg 300w\" sizes=\"auto, (max-width: 485px) 100vw, 485px\" \/><figcaption>Illustration B: The number seven (4+2+1)<\/figcaption><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"502\" height=\"480\" src=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures046copy.jpg\" alt=\"\" class=\"wp-image-80\" srcset=\"https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures046copy.jpg 502w, https:\/\/www.circuitdesign.info\/blog\/wp-content\/uploads\/2008\/06\/digitalnumbersystemhandpictures046copy-300x286.jpg 300w\" sizes=\"auto, (max-width: 502px) 100vw, 502px\" \/><figcaption>Illustration C: The number nine (8+1)<\/figcaption><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Putting it in numbers<\/h2>\n\n\n\n<p>So, here&#8217;s how computers represent each number above: They assign a 1 or a 0 to each finger position. If the finger is up, it&#8217;s assigned a 1. If the finger is down, it&#8217;s assigned a 0.<\/p>\n\n\n\n<p>So example A (fourteen) would be represented as <strong>1110<\/strong>. Example B above (seven) would be represented as <strong>0111<\/strong>. Example C would be represented as <strong>1001<\/strong>.<\/p>\n\n\n\n<p>Incidentally, the weighting of 8, 4, 2, 1 on each finger is called <em>binary weighting<\/em>: each finger has a value of twice the finger to the right of it<em>.<\/em> To complete the analogy, each finger represents one <em>bit<\/em>: one unit of binary information (a 1 or a 0). With four fingers\/bits, we can represent any number between zero (all fingers down) to fifteen (Illustration A: all fingers up; 8+4+2+1).<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In part 1, I illustrated how our decimal\/Arabic number system is based on our ability to count up to nine with a single digit. After that, we add a digit (with a weighting of ten) and then continue to count the first digit from zero to nine again. The best way to explain how computers [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[4],"tags":[],"class_list":["post-82","post","type-post","status-publish","format-standard","hentry","category-layperson"],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/poCEy-1k","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/posts\/82","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/comments?post=82"}],"version-history":[{"count":6,"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/posts\/82\/revisions"}],"predecessor-version":[{"id":1191,"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/posts\/82\/revisions\/1191"}],"wp:attachment":[{"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/media?parent=82"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/categories?post=82"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.circuitdesign.info\/blog\/wp-json\/wp\/v2\/tags?post=82"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}