Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Binary number system

  1. Mar 23, 2008 #1

    Defennder

    User Avatar
    Homework Helper

    I have no idea where to put this thread, so I'm trying out this forum.

    Why do computers use the binary number system instead of other n-base number systems? I did a Google search and I saw that one explanation was that in a circuit, certain devices are either turned on or off (1 or 0) which is why base 2 was used historically. I'm rather clueless about this, so excuse me if I sound naive. But hasn't technology progressed enough such that we can build computers which are not constrained by either on or off binary systems?

    Another reason I found was that otherwise the complexity involved in using something other than 2-base number system would burn out the system, more room for errors. Here: http://wiki.answers.com/Q/Why_do_computers_use_the_binary_code_instead_of_the_decimal_system

    Or are there other reasons why such is not possible or feasible?
     
  2. jcsd
  3. Mar 23, 2008 #2

    mgb_phys

    User Avatar
    Science Advisor
    Homework Helper

    On or off is still the simplest system. You could use a system with more levels but this would be more complicated.

    Consider doing an addition, you could have 100 voltages levels between say 0 and 5V and add them in an amplifier to give an output in the range 0-10V. But your system would have to have a noise of less than 0.05V otherwise you would read say 10 as 11 or 9. Then how would you do fractions, you would have to make smaller and smaller fractions of a volt represent the decimal places.
    It would also be hard to store values because you would have to care about any changes in the stored voltage changing the value.
     
  4. Mar 23, 2008 #3

    Defennder

    User Avatar
    Homework Helper

    In what base is this working in?

    Why isn't the problem of fractions present in the binary system?

    Can you elaborate on this, and how this doesn't also affect binary systems?
     
  5. Mar 23, 2008 #4

    chroot

    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    The reason computers use binary is ultimately because you want them to be fast. Most logic gates are effectively open-loop amplifiers with extremely high gains (as much as millions of volts / volt). When the input changes, the amplifier immediately swings to its opposite state, and this transition is engineered to be as fast as technologically possible, on the order of picoseconds.

    If logic gates had many different levels, rather than just "on" and "off," then you've opened up a Pandora's box of problems. If each state was represented by only a small range of voltages, then you'd to deal with the inevitable problems of ringing and oscillation and settling-time. The end result is that the inputs would have to be allowed to settle for a comparatively long time before the output will be reliable -- something on the order of hundreds of nanoseconds or maybe even microseconds.

    There are also major manufacturing problems with many-state logic. No two manufactured transistors are ever exactly the same, and these mismatches cause offset errors. If your states were represented by 100 mV bands, and you had some logic gates with 240 mV of offset, you wouldn't have a computer -- you'd have a paperweight.

    So, in order to make fast, easily manufactured computers, you have to use as few states as possible. Binary is, in a sense, the most "forgiving" number system possible.

    - Warren
     
  6. Mar 23, 2008 #5

    DaveC426913

    User Avatar
    Gold Member

    As you can see, binary is the most efficient system.
     
  7. Mar 28, 2008 #6

    Defennder

    User Avatar
    Homework Helper

    I can't say I understand most of what was said, but thanks guys.
     
  8. Mar 29, 2008 #7
    In binary, arithmetic is simplified to a sequence of AND, OR and inversion decisions that can be handled by electronic switches. For example, consider the four addition problems: 0+0=0, 0+1=1, 1+0=1, and 1+1=10 (10 is the binary equivalent for the decimal number 2). Look at the pattern of the answers in terms of the sameness or difference of digits. If the two numbers are not the same (the exclusive-OR) either 0+1 or 1+0, then the answer is 1. If the two numbers are the same (the inversion of the exclusive-OR), either 0+0 or 1+1, then the answer is 0, with the qualifier that in the case of 1+1 (AND) we have to carry a 1 to the next column, but in the case of 0+0 (NOR) we don't carry. Keep thinking that way and you can make an array of transistors do any arithmetic.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?