5

May somebody explain this in other words? http://wiki.answers.com/Q/Why_do_you_read_binary_digits_right_to_left

I know this is an akward question, but I really want to know the answer, it's just curiosity, I'm learning all that stuff of low level programming and learn binary system is one of the first steps to accomplish the objective.

  • Number names in various families of languages far predate positional notation. The Indo-European family, among others, uses left to right ordering, with some exceptions ("four and twenty blackbirds baked in a pie", "seventeen"). – André Nicolas Aug 08 '14 at 19:38
  • I've always pronounced the binary number $1000$ as "one-oh-oh-oh" or "one 'thousand.'" I've never heard anyone pronounce it "oh-oh-oh-one." – Akiva Weinberger Aug 08 '14 at 19:39
  • 3
    Just like decimal numbers, high order digits to the left, no change in your habits. –  Aug 08 '14 at 19:40
  • See http://en.wikipedia.org/wiki/Endianness (Big-endian and Little-endian). Intel style keeps numbers "right-to-left", Motorola style keeps numbers "left-to-right". I think "right-to-left" sometimes is comfortable to show number as a polynomial $$n = b_0 \cdot 2^0 + b_1\cdot 2^1 + b_2\cdot 2^2 + ... + b_{31} \cdot 2^{31},$$ so vector $(b_0,b_1,b_2,...,b_{31})$ is intuitive here to represent number this way (increasing indices $-$ increasing powers of base $2$). – Oleg567 Aug 08 '14 at 19:43

6 Answers6

9

Just as a counterpoint, there is a nice left-to-right method for reading binary numbers: start at the left, and then each time you move rightward, you double your previous total and add the current digit.

Example: $110010_2$:
$1$

$2\cdot 1+1=3$

$2\cdot 3+0=6$

$2\cdot 6+0=12$

$2\cdot 12+1=25$

$2\cdot 25+0=50$.

I have found (and my students too), that with practice, this method is quicker than the right-to-left method.


Edit based on a request for further explanation:

This method works in any base (and it is also the same idea as Horner's method for evaluating a polynomial). For example in base ten, if I started reading you digits of a number from left-to-right, say 3, 7, 9, 2, you could process this digit-by-digit with a provisional total at each step: 3, 37, 379, 3792; where at each step you multiply the previous result by ten (the base) and add the next digit.

In the example in my post (multiplying by two at each step), we get $$((((1\cdot 2+1)\cdot 2+0)\cdot 2 + 0)\cdot 2+1)\cdot 2+0=1\cdot 2^5 + 1\cdot 2^4 + 0 \cdot 2^3 + 0\cdot 2^2 + 1\cdot 2+ 0$$ which is just the base-two expanded form of the numeral.

paw88789
  • 40,402
6

The proper question is not, "Why is binary read right to left?" The question that should be asked is, "How do people usually read binary numbers?"

The answer at http://wiki.answers.com/Q/Why_do_you_read_binary_digits_right_to_left suffers because of the way the question was phrased. (The exact question there was, "Why do you read binary digits right to left?") The correct answer (which I think is what the wiki answer was trying to say) is that binary numbers are used in the same way as decimal numbers, except that (a) each digit position is valued only $2$ times the position to its right, not $10$ times, and (b) the only digits allowed are $0$ and $1$.

In other words, we normally read binary numbers left to right, just as we do with decimal numbers, not right to left.

On the other hand, commonly taught algorithms for adding or multiplying decimal numbers by hand are performed starting at the rightmost digit of each number. You can adapt those same algorithms to addition or multiplication of binary numbers.

There is a related question, which is, "In what order does a computer store the binary digits of a binary number?" The answer to that question depends on which computer is storing the number.

David K
  • 98,388
  • I actually think the proper question would have been "Text is commonly ordered in the same way it is most commonly understood (so that understanding flows chronologically from reading), so for English it would be left to right for both. Then why is binary ordered from left to right, when the most common way of understanding binary is actually from right to left?" – Magne Apr 14 '20 at 10:52
2

A number of useful functions on the integers (or tuples of integers) have this property: to compute the last $N$ digits of the result you only need the last $f(N)$ digits of the input where $f$ is some reasonably slow growing function of $N$. This means it makes sense to evaluate your function on the integers by working from the least significant digit first and working your way towards more significant digits. Depending on how you organise memory, this might make it more convenient to think of your data as stored in the reverse order to the way decimal numbers are written.

For example, addition and multiplication have this property. (This also means that evaluating polynomials in integers also has this property.) Division by a fixed power of two also has this property.

(To set things in a larger mathematical context, many computationally useful functions on the integers are continuous in the 2-adic sense. If you store the binary digits of a number starting with the least significant first, and then read through the digits of an integer starting at the least significant, but stop before you get to the end, the digits you've read so far still give a good approximation to the number in the 2-adic sense. This makes it natural to start with the least significant digits.)

Dan Piponi
  • 4,406
1

Humans usually only use binary in combination with computers. Most, if not all, modern computers do not work on the individual bit level, but on bundles of bits (the word size) where the computer gets the whole bundle based on its number, and you then work on the interesting bits in the bundle and store the bundle back.

In order to group the bits into groups (bytes, ints, longs etc) the same way as they are stored inside the computer, it is the easiest to start from the right.

0

Binary does not read any differently from any other number. Base 10 (decimal) or Base 2 (binary), its the same. It can just be more easier to work out the value working right to left

Decimal Example of 1,044

1000| 100|  10|   1|
 1  |   0|   4|   4|

The above shows there are 1 lots of 1000s, 0 lots of 100s, 4 lots of 10s and 4 lots of 1s. Totalling 1,044. The larger value (1000) on the left and the smaller on the right

The same number in binary is as below

1024| 512| 256| 128|  64|  32|  16|   8|   4|   2|   1|
   1|   0|   0|   0|   0|   0|   1|   0|   1|   0|   0|
0

When speaking decimal digits from left to right, we use special language to describe the exponent of the current digit. This allows a listener to recieve information such that the largest digit is first and its magnitude is known. If I spoke the digits 3 4 2 5 2, you wouldn't know that the 3 is in the 10^4 position until I was done reading the number. If you were trying to verbally send information in binary in a manner where the listener understands the exponent of the current bit at the moment they hear that bit, you would have to first state the exponent of the most left bit, then all the other bits would be understood. If you speak the number from right to left, the exponent of the bits is understood by default, but the most significant information isn't spoken until the end.