为什么电脑二进制工作? [英] Why do computers work in binary?

查看:217
本文介绍了为什么电脑二进制工作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经做了一些搜索,但没有找到一个真正满意的答案。作为一个开发者,我想投入​​必要的时间理解这个,所以我要寻找一个完成这个解释,并随时提供任何有益的借鉴。

I have done some searching but have not found a truly satisfactory answer. As a developer i want to invest the necessary time in understanding this, thus i am looking for a complete explanation on this and feel free to provide any useful references.

感谢。

推荐答案

我会建议买这个<一个href=\"http://www.pearsonhighered.com/educator/product/Structured-Computer-Organization/9780131485211.page\"相对=nofollow>书 rel=\"nofollow\">安德鲁·斯图尔特·塔能鲍姆。他开发了predecessors到Linux所谓的Minix之一。我用<一个href=\"http://www.pearsonhighered.com/educator/product/Structured-Computer-Organization/9780131485211.page\"相对=nofollow>结构计算机组成为我的大学课程的一部分。

I would recommend buying this book by Andrew S. Tanenbaum. He developed one of the predecessors to Linux called Minix. I used Structured Computer Organization as part of my university course.

为什么电脑使用二进制不只是一个开关上下文的问题。

Why computers use binary is not just a matter of switch context.

相对说3V的参考电压。 + 1V(4V)=真或1和-1V(2V)= FALSE或0。

Relative to a reference voltage of say 3v. +1v(4v) = true or 1 and -1v(2v) = false or 0.

它也有创造或控制逻辑电路的最有效的方法来做。这与实施成本做。需要多少成本来构建二进制工作相比,带有小数点或模拟的看到这个答案

It also has to do with the most efficient method of creating controlling or logic circuits. This has to do with cost of implementation. How much does it cost to build circuits that work with binary compared to circuits that work with decimal or analogue see this answer.

如果你比较几十亿的二进制电路晶体管如何适应到一个现代的CPU。这样做的成本与小数说(或模拟)系统,成倍增加你要添加为你现在必须添加更多的控制电路,每一个数字。

If you compare how many billions of binary circuit transistors fit on to a modern CPU. The cost of doing that with say decimal (or analogue) system increases exponentially for every digit you want to add as you now have to add that much more controlling circuitry.

如果您想了解一些有助于使二元默认的标准逻辑和控制电路,阅读和理解维基百科以下主题的最重要贡献的组成部分。这将需要约4小时通过最重要的课题,其中有一些用于创建电路电气工程做阅读。

If you want to understand some of the most important contributing components that have helped to make binary the default standard for logic and controlling circuitry read and understand the following topics from Wikipedia. It will take about 4 hours to read through the most important topics, which have to do with some of the electrical engineering used to create the circuits.

我试着在你需要了解实际的交换机是如何工作的,以及为什么他们使用的概念这个列表完整。以及为什么二进制算术是在硬件计算这样一种有效形式。

I tried to be complete in this list of concepts you need to understand how the actual switches work and why they are used. As well as why Binary Arithmetic is such an efficient form of computation in hardware.


  • 晶体管类型了解的 PNP和NPN晶体管类型的理解,形成了开关的实际迂曲如何工作的。这些电路是非常便宜的制造和可缩小到微不足道的(纳米米)大小

  • 逻辑电路。如果你了解基本的逻辑电路,你就会明白如何实际的晶体管类型用于实现它们。这些涉及到一些编程构造诸如和&功放;&安培; 或||和如果分支结构。

  • DigitalCircuitry 有采用全缺点部分模拟比较
    与数字电路

  • NAND逻辑门是重要的,因为所有其他逻辑门电路可以实现只用这一个逻辑门。简化了制造过程中,由于用于创建电路的机械的复杂性,可以简化。

  • 加法电路以了解使用逻辑门的另外如何做基本

  • 二进制补码这非常有助于在充分了解再presentation号实际的CPU。它也很便宜,以实现这种类型的算术的CPU中,因为它需要较少的晶体管。例如一个简单的加法电路是所有是需要做加减。如果添加一个负数,你得到正确的答案,即+7 +(-4)= +3。这也有助于了解整数溢出

  • Binary_number

  • 这是一些用于控制其它电路最常用的马戏团。当电路被接通和关断这些控制。 德codeR 恩codeR 如何(如果或分支机构)的条件逻辑来实现。

  • 复用器是到路由是怎么做的根本。在CPU,总线和网络。一种在大多数的数字设备中发现的最常见的逻辑电路。

  • Transistor types Understand the pnp and npn transistor types to understand how the actual circuity that forms the switches works. These circuits are very cheap to make and can be shrunk to minuscule(nano meter) size
  • Logic Circuitry. If you understand the basic logic circuitry you will understand how the actual transistor types are used to implement them. These relate to some of the programming constructs such as "and &&" "or ||" and "if, branch" constructs.
  • DigitalCircuitry has a use full disadvantages section comparing analog and digital circuits
  • NAND Logic Gate is important as all other logic gate circuits can be implemented using just this one logic gate. Simplifying the manufacturing process, as the complexity of the machinery used to create the the circuits can be streamlined.
  • Adder Circuits To understand how basic addition is done using logic gates.
  • Twos Complement this is very help full in understand number representation in actual CPUs. It is also very cheap to implement this type of arithmetic in a CPU, as it requires fewer transistors. For instance a simple addition circuitry is all that is need to do addition and subtraction. If you add a negative number you get the correct answer ie +7 + (-4) = +3. This also helps to understand the integer overflow
  • Binary_number
  • These are some of the most used circus for controlling other circuits. These control when circuits are switched on and off. Decoder Encoder How (if or branch) condition logic is implemented.
  • Multiplexer Is fundamental to how routing is done. In a CPU, BUS and in a network. One of the most common logic circuits found in most digital devices.

现在对于一些硬核的东西。 C.和C ++来编写,为实际的硬件说话的设备驱动程序。如果你真的想进入特定的设备是如何工作的,你的CPU和或外部设备学习汇编 。你会开始看到如何通过一定的设备寄存器设置为特定值时,将要由逻辑电路读取更改设备状态关闭设备。例如,你就会明白为什么(0101)BASE2 = 5(二进制相关的东西)将借道电路一种特定的方式来切换和关闭设备。

Now for some hard cores stuff. C. and C++ is used to write device drivers that speak to actual hardware. If you really want to get into how certain devices work, your CPU, and or external devices learn Assembler. You will begin to see how you can switch off a device by setting a certain device register to a specific value, that will be read by a logic circuit to change the devices state. For example you will understand why (0101) base2 = 5 (binary related stuff) will route a specific way through the circuits to switch the device on and off.

这篇关于为什么电脑二进制工作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆