Binary Codes 27
Total Page:16
File Type:pdf, Size:1020Kb
r.rrdlrtcr -Iit4, Fortunately,we don't.have to actuaily write out ail the possibrec.des t, determinehow many therewould r". att to do is murtipry2 by itserf over and over again. -.i"r. Morse code is said a-.!#at#Ft-' to be a binary (literally meaning tuo becausethe components by two) code of thecode'c;il;;? o.,tyt.'"r iirirgr'-"-i", a dash'That's similar to a coin, ChapterThree which canland only on the headside or "ra tail side'Binary objects (such the ascoinrl rlrr"ry codes(such tutorr..oa.) are alwaysdescribed by powers of two."rrJ ", vl"' we're doing by,anaryzing , binarycodes is a simpleexercise in rhe branchof mathematicsknown or combinotirii' orotyr*. Tiaditionally,combinatoriar ^t1o*biiotirics analysisir oftenin ,rr. ri.il or prou- ability and statisticsbecause it involves"t.l -o* Brailleand d.t..-inirrg rrr. rru-u., oi*"y, trr", things,like coinsand dice, canbe.r-bi;;;.;ut it arsohelps us understand how codescan be put together r"t." ""a "plrr. BinaryCodes .-A{*?+ff:f. amuel Morse wasn't the first person to successfullytranslate the let- ters of written languageto an interpretablecode. Nor was he the first person to be rememberedmore as the name of his code than as him- self.That honor must go to a blind Frenchteenager born some 18 yearsafter Samuel Morse but who made his mark much more precociously.Little is known of his life, but what is known makes a compelling story. Louis Braillewas born in 1809 in Coupvra5 France,iust 25 miles east of Paris. His father was a harnessmaker. At the age of three-an age when young boys shouldn't be playing in their fathers' workshops-he accidentally stuck a pointed tool in his eye. The wound becamein- fected,and the infection spreadto his other eye, leaving him totally blind. Normally he would have been doomed to a life of ignorance and poverty (asmost blind people were in those days), but young Louis's intelligence and desireto learn were soon recognized.Through the intervention of the village priest and a schoolteacher,he first attended school in the village with the other children and at the age of 10 was sent to the Royal Institution for Blind Youth in Paris. 15 ( )hapter 'I'bree nrdllle dnd nrndry r,(r(fft 'l'hc one major obstaclein the educationof the brind is, of course,their in- dots withirr :r two-by-thrccccll. dotsof thc cellarc commonlynumbered a.bility to read printed books. Valentin Hany e74s-rg2z), the founder of I thror.rgh6: the Paris school, had invented a systemof raised letters on paper that could be read by touch' But this systemwas very difficult to ur., and only a few rOO+ books had been produced using this method. zOOs The sighted Haiiy was stuck in a paradigm. To him, an A was an A was an A, and the letter A.must look (or feel) like an A. (If given a flashlight to :oos communicate, he might have tried drawing letters in the air as *e did be- fore we discoveredit didn't work very weil.; Hatiy probably didn't realize In modern-day use, specialtypewriters or embosserspunch the Braille dots that a type of code quite different from the printed alphabet might be more into the paper. appropriate for sightlesspeople. Becauseembossing just a couple pagesof this book in Braillewould be The origins of an alternative type of code came from an unexpected prohibitively expensive,I've used a notation common for showing Braille source. charles Barbier, a captain of the French army had by 1g1,9devised on the printed page.In this notation, all six dots in the cell are shown. Large a system of writing he called 1criture nocturne, or "night writing.,' This dots indicate the parts of the cell where the paper is raised. Small dots indi- system used a partern of raiseddots and dasheson heavy paper and was cate the parts of the cell that are flat. For example, in the Braille character intended for use by soldiersin passingnotes to each other in'the dark when quiet-was necessary.The soldiers were able to poke these dots and dashes into the back of the paper using an awl-like stylui. The raiseddots could then !i be read with the fingers. The problem with Barbier's systemis that it was quite complex. Rather dots 1, 3, and 5 are raisedand dots 2,4, and 6 are not. than 'u7hat using patterns of dots and dashesthat correspondedto letters of the should be interesting to us at this point is that the dots are binary. alphabet,Barbier devisedparterns rhat corresponded'tosounds, often requir- A particular dot is either flat or raised.That meanswe can apply what we've ing many codes for a single word. The ryrt.- worked fine for shorr mes- learned about Morse code and combinatorial analysisto Braille. We know sagesin the field bur was distinctly inadequate for longer texts, let alone that there are 5 dots and that eachdot can be either flat or raised,so the total entire books. number of combinations of 5 flat and raised dots is2 x 2 x 2 x 2 x 2 x 2, or Louis Braille becamefamiliar with Barbier's systemat the age of 12. He 26,or 64. liked the useof raised dots, not only becauseit pioved easyto rlad with the Thus, the system of Braille is capable of representing54 unique codes. fingers but also becauseir was easy to tarite. A student in the classroom Here they are-all 54 possible Braille codes: equipped with paper and a stylus could actually take notes and read them back. .a Louis Braille diligently tried to improve th. ,yrt.- and within three years (at :: :? the age of 15) had come up with his own, rhe basicsof which are still used today. For many years, th. ryrt..n was known only within aa ?: ?: the :: :: .a .a yh99l' but it gradually made its way to the rest of the world. In 1g35, Louis .a .a .a Braille contracted ruberculosis, which a. a. a' would eventually kill him shortiy after :? .a .a his 43rd birthday in 1852. aa aa a. aa Today, o. aa a. a' enhanced versions of the Braille system compete with tape- .a .a reco.rded_booksfor providing the blind with accessto the written word, but .a ,. Braille .a .a :? still remainsan invaluable systemand the only way to read for people a. o. a. aa who are both blind and deaf. In recent years, aa a. aa aa a. oa Brailie has becomemore fa- .a ,a .a .a miliar in the public arena as elevatorsand automatic teller machines are made ;. a. a. aa aa aa more accessibleto the blind. .a .o .a .a 's7hat a. aa aa a. aa oa we're going to do in this chapter is dissectBraille a. a. a' aa aa aa 'we code and seehow it works. don't aa a. aa aa o. oa have to actually rearn Braire or memorize anything. we a. aa ao a. aa aa o. o. a. aa aa aa just want some insight into the nature of codes. In Braille' . every symbol used in normal written language-specificallS letters,numbers, and punctuation marks-is encoded on. or more raised "r ( .l,,tl,l(r I t,r(( llr,ttllt ,tnl lltn,trt' ( ttlts lv If we find fewerthan 54 codcsusctl in Braille,we sh'ulcl qrcsri()' why ao aa a ao oa o. .a .a :: :. .a :: :: ?: :? ?: ?: some of the 64 possiblecodes aren't being used.If we find nnrc th^n 64 codesused in Braille,we should questioneither our sanity or fundamental (rtonc ) hut eiln d0 cvery fftrnr go have (none) just truths of mathematics,such as 2 plus 2 equaling4. To begin dissectingthe code o o. ao oa a. ao aa a. 'a .o of Braille, let's look at the basiclowercase a. 'a 'a a. oa oa o. O' alphabet: o. o. a. a. a. a' a. o. a. a' knowledge likc more not (none) people quite rather so that o. a' oo oo a. oo aa o. .o .a :: :: :: :? :: ?: :: ?: :: :: o. o. oa oa o. ao oa a. .o .a o. .o .a a' aa oa o. aa aa oa oo aa aa ao oa aa aa ao abcdefghiy us very rr you as and for of the with a. o. ao oa a. aa ao a. .o ,o a. .a .a o. aa ao a. ao a. o. o. a' a. a. o. a. a. a. Thus, the phrase"you and me" can be written in Grade 2 Braille as this: klmnopqrsr oa oa aa a' .a a. ,. .o a. a. oa aa a. oa oa a. a. 'a .a oa aa aa oa oa uvxyz So far, I've described31 codes-the no-raised-dotsspace between words and the 3 rows of 10 codesfor letters and words. We're still not closeto the For example,the phrase"you and me" in Braille looks like this: 64 codesthat are theoretically available. In Grade 2 Braille, as we shall see, nothing is wasted. oa a' o. a. aa aa ao a. First, we can use the codesfor lettersa through combined with a raised .o .a . .o .o .o i ao o. ao ' o. a. dot 5. These are used mostly for contractions of letters within words and also include u and another word abbreviation: Notice that the cells for each letter within a word are separatedby a little bit of space;a larger space(essentially a. a. aa oa o. aa oa o. .a .a a cell with no raised dots) is used o.