Counting in binary is similar to counting in any other number system. Beginning with a single digit, counting proceeds through each symbol, in increasing order. Before examining binary counting, it is useful to briefly discuss the more familiar decimal counting system as a frame of reference.
Decimal counting[edit]
Decimal counting uses the ten symbols 0 through 9. Counting primarily involves incremental manipulation of the "low-order" digit, or the rightmost digit, often called the "first digit". When the available symbols for the low-order digit are exhausted, the next-higher-order digit (located one position to the left) is incremented, and counting in the low-order digit starts over at 0. In decimal, counting proceeds like so:
000, 001, 002, ... 007, 008, 009, (rightmost digit starts over, and next digit is incremented)
010, 011, 012, ...
...
090, 091, 092, ... 097, 098, 099, (rightmost two digits start over, and next digit is incremented)
100, 101, 102, ...
After a digit reaches 9, an increment resets it to 0 but also causes an increment of the next digit to the left.
Binary counting[edit]
In binary, counting follows similar procedure, except that only the two symbols 0 and 1 are used. Thus, after a digit reaches 1 in binary, an increment resets it to 0 but also causes an increment of the next digit to the left:
0000,
0001, (rightmost digit starts over, and next digit is incremented)
0010, 0011, (rightmost two digits start over, and next digit is incremented)
0100, 0101, 0110, 0111, (rightmost three digits start over, and the next digit is incremented)
1000, 1001, 1010, 1011, 1100, 1101, 1110, 1111 ...
Since binary is a base-2 system, each digit represents an increasing power of 2, with the rightmost digit representing 20, the next representing 21, then 22, and so on. To determine the decimal representation of a binary number simply take the sum of the products of the binary digits and the powers of 2 which they represent. For example, the binary number 100101 is converted to decimal form as follows:
1001012 = [ ( 1 ) × 25 ] + [ ( 0 ) × 24 ] + [ ( 0 ) × 23 ] + [ ( 1 ) × 22 ] + [ ( 0 ) × 21 ] + [ ( 1 ) × 20 ]
1001012 = [ 1 × 32 ] + [ 0 × 16 ] + [ 0 × 8 ] + [ 1 × 4 ] + [ 0 × 2 ] + [ 1 × 1 ]
1001012 = 3710
To create higher numbers, additional digits are simply added to the left side of the binary representation.
Fractions[edit]
Fractions in binary only terminate if the denominator has 2 as the only prime factor. As a result, 1/10 does not have a finite binary representation, and this causes 10 × 0.1 not to be precisely equal to 1 in floating point arithmetic. As an example, to interpret the binary expression for 1/3 = .010101..., this means: 1/3 = 0 × 2−1 + 1 × 2−2 + 0 × 2−3 + 1 × 2−4 + ... = 0.3125 + ... An exact value cannot be found with a sum of a finite number of inverse powers of two, the zeros and ones in the binary representation of 1/3 alternate forever.
Fraction Decimal Binary Fractional approximation
1/1 1 or 0.999... 1 or 0.111... 1/2 + 1/4 + 1/8...
1/2 0.5 or 0.4999... 0.1 or 0.0111... 1/4 + 1/8 + 1/16 . . .
1/3 0.333... 0.010101... 1/4 + 1/16 + 1/64 . . .
1/4 0.25 or 0.24999... 0.01 or 0.00111... 1/8 + 1/16 + 1/32 . . .
1/5 0.2 or 0.1999... 0.00110011... 1/8 + 1/16 + 1/128 . . .
1/6 0.1666... 0.0010101... 1/8 + 1/32 + 1/128 . . .
1/7 0.142857142857... 0.001001... 1/8 + 1/64 + 1/512 . . .
1/8 0.125 or 0.124999... 0.001 or 0.000111... 1/16 + 1/32 + 1/64 . . .
1/9 0.111... 0.000111000111... 1/16 + 1/32 + 1/64 . . .
1/10 0.1 or 0.0999... 0.000110011... 1/16 + 1/32 + 1/256 . . .
1/11 0.090909... 0.00010111010001011101... 1/16 + 1/64 + 1/128 . . .
1/12 0.08333... 0.00010101... 1/16 + 1/64 + 1/256 . . .
1/13 0.076923076923... 0.000100111011000100111011... 1/16 + 1/128 + 1/256 . . .
1/14 0.0714285714285... 0.0001001001... 1/16 + 1/128 + 1/1024 . . .
1/15 0.0666... 0.00010001... 1/16 + 1/256 . . .
1/16 0.0625 or 0.0624999... 0.0001 or 0.0000111... 1/32 + 1/64 + 1/128 . . .
Binary arithmetic[edit]
Arithmetic in binary is much like arithmetic in other numeral systems. Addition, subtraction, multiplication, and division can be performed on binary numerals.
Addition[edit]
Main article: binary adder
The circuit diagram for a binary half adder, which adds two bits together, producing sum and carry bits.
The simplest arithmetic operation in binary is addition. Adding two single-digit binary numbers is relatively simple, using a form of carrying:
0 + 0 → 0
0 + 1 → 1
1 + 0 → 1
1 + 1 → 0, carry 1 (since 1 + 1 = 2 = 0 + (1 × 21) )
Adding two "1" digits produces a digit "0", while 1 will have to be added to the next column. This is similar to what happens in decimal when certain single-digit numbers are added together; if the result equals or exceeds the value of the radix (10), the digit to the left is incremented:
5 + 5 → 0, carry 1 (since 5 + 5 = 10 = 0 + (1 × 101) )
7 + 9 → 6, carry 1 (since 7 + 9 = 16 = 6 + (1 × 101) )
This is known as carrying. When the result of an addition exceeds the value of a digit, the procedure is to "carry" the excess amount divided by the radix (that is, 10/10) to the left, adding it to the next positional value. This is correct since the next position has a weight that is higher by a factor equal to the radix. Carrying works the same way in binary:
1 1 1 1 1 (carried digits)
0 1 1 0 1
+ 1 0 1 1 1
-------------
= 1 0 0 1 0 0 = 36
In this example, two numerals are being added together: 011012 (1310) and 101112 (2310). The top row shows the carry bits used. Starting in the rightmost column, 1 + 1 = 102. The 1 is carried to the left, and the 0 is written at the bottom of the rightmost column. The second column from the right is added: 1 + 0 + 1 = 102 again; the 1 is carried, and 0 is written at the bottom. The third column: 1 + 1 + 1 = 112. This time, a 1 is carried, and a 1 is written in the bottom row. Proceeding like this gives the final answer 1001002 (36 decimal).
When computers must add two numbers, the rule that: x xor y = (x + y) mod 2 for any two bits x and y allows for very fast calculation, as well.
Long carry method[edit]
A simplification for many binary addition problems is the Long Carry Method or Brookhouse Method of Binary Addition. This method is generally useful in any binary addition where one of the numbers contains a long "string" of ones. It is based on the simple premise that under the binary system, when given a "string" of digits composed entirely of n ones (where: n is any integer length), adding 1 will result in the number 1 followed by a string of n zeros. That concept follows, logically, just as in the decimal system, where adding 1 to a string of n 9s will result in the number 1 followed by a string of n 0s:
Binary Decimal
1 1 1 1 1 likewise 9 9 9 9 9
+ 1 + 1
----------- -----------
1 0 0 0 0 0 1 0 0 0 0 0
Such long strings are quite common in the binary system. From that one finds that large binary numbers can be added using two simple steps, without excessive carry operations. In the following example, two numerals are being added together: 1 1 1 0 1 1 1 1 1 02 (95810) and 1 0 1 0 1 1 0 0 1 12 (69110), using the traditional carry method on the left, and the long carry method on the right:
Traditional Carry Method Long Carry Method
vs.
1 1 1 1 1 1 1 1 (carried digits) 1 ← 1 ← carry the 1 until it is one digit past the "string" below
1 1 1 0 1 1 1 1 1 0 1 1 1 0 1 1 1 1 1 0 cross out the "string",
+ 1 0 1 0 1 1 0 0 1 1 + 1 0 1 0 1 1 0 0 1 1 and cross out the digit that was added to it
----------------------- -----------------------
= 1 1 0 0 1 1 1 0 0 0 1 1 1 0 0 1 1 1 0 0 0 1
การตรวจนับในไบนารีจะคล้ายกับการตรวจนับในระบบหมายเลขอื่น ๆ เริ่มต้น ด้วยตัวเลขเดี่ยว การตรวจนับเงินสดรับผ่านแต่ละสัญลักษณ์ เพิ่มจำนวน ก่อนที่จะตรวจสอบการนับไบนารี มันเป็นประโยชน์คร่าว ๆ เกี่ยวกับทศนิยมคุ้นการนับระบบเป็นกรอบอ้างอิง[แก้] การนับเลขฐานสิบการนับเลขฐานสิบใช้สัญลักษณ์สิบ 0 ถึง 9 นับเป็นหลักเกี่ยวข้องกับการจัดการส่วนเพิ่มของหลัก "สั่งต่ำ" หรือหลักขวาสุด มักเรียกว่า "ตัวเลขหลักแรก" เมื่อมีสัญลักษณ์สำหรับเลขสั่งต่ำได้หมดลงแล้ว หลักถัดไปขั้นสูง (อยู่หนึ่งตำแหน่งทางด้านซ้าย) คือเพิ่ม และการตรวจนับในการเริ่มต้นหลักสั่งต่ำกว่า 0 ในเลขฐานสิบ การตรวจนับเงินแบบนั้นเช่น:000, 001, 002, ... 007, 008, 009, (เริ่มต้นหลักขวาสุด และจะเพิ่มหลักถัดไป)010, 011, 012, ... ...090, 091, 092, ... 097, 098, 099, (ขวาสุดสองตำแหน่งเริ่มต้น และจะเพิ่มหลักถัดไป)100, 101, 102, ...หลังจากที่ตัวเลขถึง 9 เพิ่มการรีเซ็ตเป็น 0 แต่ยัง ทำให้เพิ่มตัวเลขหลักถัดไปทางซ้าย[แก้] การนับไบนารีในไบนารี การนับตามขั้นตอนที่คล้ายกัน ยกเว้นว่าจะใช้เพียงสองสัญลักษณ์ 0 และ 1 ดังนั้น หลังจากตัวเลขถึง 1 ในไบนารี การเพิ่มรีเซ็ตเป็น 0 แต่ยัง ทำให้เพิ่มตัวเลขหลักถัดไปทางซ้าย:00000001, (เริ่มต้นหลักขวาสุด และจะเพิ่มหลักถัดไป)0010, 0011, (ขวาสุดสองตำแหน่งเริ่มต้น และจะเพิ่มหลักถัดไป), 0110, 0101, 0111, 0100 (ขวาสุดสามหลักเริ่มต้นใหม่ และจะเพิ่มตัวเลขหลักถัดไป)1000, 1001, 1010, 1011, 1100, 1101, 1110, 1111 ...เนื่องจากเป็นระบบฐาน 2 ไบนารี แต่ละหลักแสดงถึงมีพลังงานเพิ่มขึ้น 2 กับตัวเลขขวาสุดแสดง 20, 21 เป็นตัวแทนถัดไป แล้ว 22 และอื่น ๆ เพื่อกำหนดจุดทศนิยม ของตัวเลขฐานสองแค่ผลรวมของผลิตภัณฑ์ของตัวเลขไบนารีและอำนาจของ 2 ซึ่งแสดง ตัว เลขฐานสอง 100101 ถูกแปลงเป็นทศนิยมแบบฟอร์มเป็นดังนี้:1001012 =× (1) 25 + [(0) × 24] + [(0) × 23] + × (1) 22 × (0) 21 + + × (1) 201001012 = [1 × 32] + [0 × 16] + [0 × 8] + [1 × 4] + [0 × 2] + [1 × 1]1001012 = 3710การสร้างตัวเลขที่สูงขึ้น เลขเพิ่มเติมจะเพิ่มไปด้านซ้ายของนารีที่[แก้] เศษส่วนเศษส่วนในไบนารีเท่านั้นจบถ้าตัวหารมี 2 เป็นตัวนายกรัฐมนตรีเท่านั้น เป็นผล 1/10 ไม่มีนารีที่แน่นอน และทำให้ 10 × 0.1 ไม่แม่นยำเท่ากับ 1 ในจุดลอยทางคณิตศาสตร์ ตัวอย่างเช่น การแปลไบนารีนิพจน์สำหรับ 1/3 =.010101 ..., ซึ่งหมายความว่า: 1/3 = 0 × 2−1 + 1 × 2−2 0 × 2−3 + 2−4 1 × +... = 0.3125 + ... ไม่พบค่าที่แน่นอนกับผลรวมของจำนวนจำกัดอำนาจผกผันของสอง ศูนย์ และหนึ่งในนารีของ 1 ใน 3 ตลอดไปที่อื่นเศษส่วนทศนิยมไบนารีเศษประมาณ1/1 1 หรือ 0.999 ... 1 หรือ 0.111 ... 1/2 + 1/4 + 1/8 ...0.5 1/2 หรือ 0.4999 ... 0.1 หรือ 0.0111 ... 1/4 + 1/8 + 1/16 ...0.333 1 ใน 3 ... 0.010101... 1/4 + 1/16 + 1/64 ...1/4 0.25 หรือ 0.24999 ... 0.01 หรือ 0.00111 ... 1/8 + 1/16 + 1/32 ...1/5 0.2 หรือ 0.1999 ... 0.00110011... 1/8 + 1/16 + 1/128 ...0.1666 1/6 ... 0.0010101... 1/8 + 1/32 + 1/128 ...1/7 0.142857142857 ... 0.001001... 1/8 + 1/64 + 1/512 ...1/8 0.125 หรือ 0.124999 ... 0.001 หรือ 0.000111 ... 1 16 + 1/32 + 1/64 ...1/9 0.111 ... 0.000111000111... 1 16 + 1/32 + 1/64 ...1/10 0.1 หรือ 0.0999 ... 0.000110011... 1 16 + 1/32 + 1/256 ...1-11 0.090909 ... 0.00010111010001011101... 1 16 + 1/64 + 1/128 ...0.08333 1/12 ... 0.00010101... 1 16 + 1/64 + 1/256 ...1/13 0.076923076923 ... 0.000100111011000100111011... 1 16 + 1/128 + 1/256 ...1/14 0.0714285714285 ... 0.0001001001... 1 16 + 1/128 + 1/1024 ...0.0666 1/15 ... 0.00010001... 1 16 + 1/256 ...1 16 0.0625 หรือ 0.0624999 ... 0.0001 หรือ 0.0000111 ... 1/32 + 1/64 + 1/128 ...เลขคณิตฐานสอง [แก้]เลขคณิตในไบนารีเป็นเหมือนเลขคณิตในระบบเลขฐานอื่น ๆ เพิ่ม ลบ คูณ และหารสามารถทำบนตัวเลขไบนารีนอกจากนี้ [แก้]บทความหลัก: บวกไบนารีไดอะแกรมวงจรสำหรับการไบนารีครึ่งบวก ซึ่งเพิ่มบิตสองโดด ผลผลิต และดำเนินการบิตนอกจากนี้การดำเนินการทางคณิตศาสตร์ที่ง่ายที่สุดในไบนารีได้ การเพิ่มตัวเลขไบนารีเดียวหลักสองเป็นค่อนข้างง่าย ใช้แบบฟอร์มการดำเนินการ:0 + 0 → 00 + 1 → 11 + 0 → 1ดำเนินการ 1 + 1 → 0, 1 (ตั้งแต่ 1 + 1 = 2 = 0 + (1 × 21))เพิ่มตัวเลข "1" สองผลิตตัวเลข "0" ในขณะที่ 1 จะต้องถูกเพิ่มไปยังคอลัมน์ถัดไป นี่คือคล้ายกับสิ่งที่เกิดขึ้นในเลขฐานสิบเมื่อมีเพิ่มบางตัวเลขหลักเดียวกัน ถ้าผลลัพธ์เท่ากับ หรือเกินกว่ามูลค่าของฐาน (10), ตัวเลขทางซ้ายเพิ่มขึ้น:5 + 5 → 0 พก 1 (ตั้งแต่ 5 + 5 = 10 = 0 + (1 × 101))ดำเนินการ 1 → 7 + 9 6 (ตั้งแต่ 7 + 9 = 16 = 6 + (1 × 101))นี้เรียกว่าดำเนินการ เมื่อผลของการเพิ่มค่าของตัวเลขที่เกิน ขั้นตอนคือการ "ดำเนิน" หาร ด้วยฐานจำนวนเงินส่วนเกิน (นั่นคือ 10/10) ซ้าย เพิ่มค่าตำแหน่งถัดไป นี้จะถูกต้องเนื่องจากตำแหน่งถัดไปที่มีน้ำหนักที่สูง โดยปัจจัยเท่ากับฐาน ดำเนินการทำงานแบบเดียวกับในไบนารี: 1 1 1 1 1 (ดำเนินหลัก) 0 1 1 0 1+ 1 0 1 1 1-------------= 1 0 0 1 0 0 = 36ในตัวอย่างนี้ ตัวเลขทั้งสองจะมีการเพิ่มกัน: 011012 (1310) และ 101112 (2310) แถวบนแสดงบิตดำเนินการที่ใช้ เริ่มต้นในคอลัมน์ขวาสุด 1 + 1 = 102 1 จะดำเนินการทางด้านซ้าย และ 0 เขียนไว้ที่ด้านล่างของคอลัมน์ขวาสุด เพิ่มคอลัมน์สองจากขวา: 1 + 0 + 1 = 102 อีก ดำเนินการ 1 และ 0 จะเขียนด้านล่าง คอลัมน์ที่สาม: 1 + 1 + 1 = 112 เวลานี้ ดำเนินการ 1 และ 1 เขียนในแถวด้านล่าง ดำเนินการเช่นนี้ให้คำตอบสุดท้าย 1001002 (36 ทศนิยม)เมื่อคอมพิวเตอร์ต้องเพิ่มตัวเลขสอง กฎที่: x xor y = (x + y) สมัยที่ 2 สำหรับใด ๆ บิตสอง x และ y ทำให้รวดเร็วมากการคำนวณ เช่นกันวิธีแครี่ [แก้]เข้าใจง่ายสำหรับไบนารีนอกจากนี้ปัญหามากคือ วิธีการดำเนินการนานหรือ Brookhouse วิธีของไบนารี วิธีนี้เป็นประโยชน์โดยทั่วไปนอกจากนี้ไบนารีใด ๆ ที่ตัวเลขประกอบด้วยความยาว "สาย" ของคน ขึ้นอยู่กับสมมติฐานง่าย ๆ ที่ว่า ภายใต้ระบบไบนารี เมื่อ "สาย" ของ หลักประกอบด้วยทั้งหมด n คน (ที่: n เป็นจำนวนเต็มยาวใด ๆ), เพิ่ม 1 จะส่งผลให้หมายเลข 1 ตาม ด้วยสายอักขระของเลขศูนย์ n แนวคิดที่ต่อไปนี้ เหตุผล เช่นเดียวกับระบบเลขฐานสิบ ที่เพิ่ม 1 สาย n 9s จะส่งผลให้หมายเลข 1 ตาม ด้วยสตริงของ n 0 s: ไบนารีฐานสิบ 1 1 1 1 1 ในทำนองเดียวกัน 9 9 9 9 9 + 1 + 1 ----------- ----------- 1 0 0 0 0 0 1 0 0 0 0 0สายยาวดังกล่าวเป็นเรื่องปกติในระบบเลขฐาน จากที่ หนึ่งพบว่า ตัวเลขไบนารีขนาดใหญ่ที่สามารถเพิ่มโดยใช้ขั้นตอนง่าย ๆ ที่สอง โดยไม่มีการดำเนินการดำเนินการมากเกินไป ในตัวอย่างต่อไปนี้ ตัวเลขทั้งสองจะมีการเพิ่มด้วยกัน: 1 1 1 0 1 1 1 1 1 02 (95810) และ 1 0 1 0 1 1 0 0 1 12 (69110), ใช้แบบดั้งเดิมดำเนินวิธีทางด้านซ้าย และยาวดำเนินวิธีทางขวา:โบราณนำวิธีแครี่วิธี vs 1 1 1 1 1 1 1 1 (ดำเนินหลัก) ←← 1 1 นำ 1 จนกว่าจะมีหลักหนึ่งในอดีต "สตริง" ด้านล่าง 1 1 1 0 1 1 1 1 1 0 1 1 1 0 1 1 1 1 1 0 ข้ามออก "ข้อความ"+ 1 0 1 0 1 1 0 0 1 1 + 1 0 1 0 1 1 0 0 1 1 และข้ามออกตัวเลขที่ถูกเพิ่มเข้าไป----------------------- ----------------------- = 1 1 0 0 1 1 1 0 0 0 1 1 1 0 0 1 1 1 0 0 0 1
การแปล กรุณารอสักครู่..

การนับเลขฐานสองคล้ายกับนับในระบบหมายเลขใด ๆอื่น ๆ เริ่มต้นด้วยเลขหลักเดียว นับเงินผ่านแต่ละสัญลักษณ์ เพื่อ เพิ่ม ก่อนการตรวจสอบไบนารีนับมันเป็นประโยชน์สั้นหารือคุ้นเคยมากกว่าทศนิยมระบบการนับเป็นกรอบของการอ้างอิง[ แก้ไข ] นับทศนิยมทศนิยมนับสิบใช้สัญลักษณ์ 0 ถึง 9 นับหลักเกี่ยวข้องกับการเพิ่มขึ้นของ " คำสั่ง " น้อย หลัก หรือ ตำแหน่ง ตัวเลข มักจะเรียกว่า " ตัวแรก " เมื่อสัญลักษณ์ของตัวเลขการสั่งซื้อต่ำหมด ถัดเลขสั่งซื้อสูง ( อยู่ตำแหน่งเดียวไปทางซ้าย ) จะสั่ง และนับลำดับเลขต่ำเริ่มต้นที่ 0 ทศนิยม , นับเงินดังนี้000 , 001 , 002 , . . . 007 008 009 ( ตำแหน่งเริ่มต้น , ตัวเลข และตัวเลขถัดไปคือสั่ง )010 011 , 012 , . . .. . . . . . .090 091 092 , , , . . . 097 098 , 099 , ( ตำแหน่งเลขสองหลักต่อไป เริ่มต้นใหม่ และสั่ง )100 , 101 , 102 , . . .หลังจากหลักถึง 9 , การเพิ่มการตั้งค่าใหม่เป็น 0 แต่ยังทำให้เกิดการเพิ่มเลขหลักถัดไปทางซ้ายการนับเลขฐานสอง [ แก้ไข ]ในเลขฐานสองนับตามขั้นตอนที่คล้ายกัน ยกเว้นเพียงสองสัญลักษณ์ 0 และ 1 จะใช้ ดังนั้น หลังจากตัวเลขถึง 1 ในเลขฐานสองเพิ่มขึ้นรีเซ็ตเป็น 0 แต่ยังทำให้เกิดการเพิ่มตัวเลขถัดไปด้านซ้าย :0000 ,0001 ( เลขตำแหน่ง เริ่มต้นใหม่ และหลักที่สั่ง )0010 0011 ( เลขสองหลัก , ตำแหน่งเริ่มต้นและหลักถัดไปสั่ง )0100 0101 0110 0111 , , , , ( ตำแหน่งเลขสามหลักเริ่มต้นและตัวเลขถัดไปคือสั่ง )1000 , 1001 1010 , การ์ตูน , 1100 1101 1110 1111 , , , . . .ตั้งแต่ไบนารีเป็นระบบ base-2 แต่ละหลักแสดงถึงการเพิ่มอำนาจของ 2 กับตำแหน่งหลักแทน 20 21 22 ถัดไปแทน จากนั้น และอื่น ๆ เพื่อตรวจสอบแทนทศนิยมของจำนวนเพียงใช้ผลรวมของผลิตภัณฑ์ของตัวเลขไบนารีและพลังของ 2 ที่พวกเขาเป็นตัวแทน ตัวอย่างเช่น เลขฐานสอง 100101 จะถูกแปลงเป็นรูปแบบทศนิยม ดังนี้1001012 = [ ( 1 ) × 25 ] + [ ( 0 ) × 24 ] + [ ( 0 ) × 23 ] + [ ( 1 ) × 22 ] + [ ( 0 ) × 21 ] + [ ( 1 ) × 20 ]1001012 = [ 1 × 32 ] + [ 0 × 16 ] + [ 0 × 8 ] + [ ] + [ 0 1 × 4 × 2 × 1 ] + [ 1 ]1001012 = 0เพื่อสร้างหมายเลขสูงกว่าตัวเลขเพิ่มเติมจะถูกเพิ่มเพียงด้านซ้ายของการแทนเลขฐานสองเศษส่วน [ แก้ไข ]เศษส่วนเลขฐานสองเท่านั้นหากยุติ ส่วนที่ 2 เป็นเพียงปัจจัยนายกรัฐมนตรี เป็นผลให้ 1 / 10 ไม่มีจำกัดไบนารีแทน และนี้เป็นสาเหตุให้ 10 × 0.1 ไม่แม่นยำเท่ากับ 1 ในเลขคณิตจุดลอยตัว . ตัวอย่าง การตีความการแสดงออกของไบนารี 1 / 3 = . 010101 . . . นี้คือ 1 / 3 = 0 × 2 × 2 − 1 + 1 − 2 + 0 × 2 × 2 − 3 + 1 − 2 + . . . . . . . = 0.3125 + . . . . . . . ไม่ได้ มันมีค่าได้ด้วยผลรวมของจำนวนที่จำกัดของสิ่งที่ตรงกันข้ามพลังสอง ศูนย์ ๆในการแทนเลขฐานสอง 1 / 3 สลับกัน ตลอดไปเศษส่วนทศนิยมไบนารีเศษส่วนประมาณ1 / 1 หรือ 0.999 . . . 1 ส.ค. . . . . . . . 1 / 2 + 1 / 3 + 1 / 8 . . . . . . .0.4999 0.5 หรือ 1 / 2 . . . . . . . 0.0111 0.1 หรือ . . . . . . . 1 / 4 + 1 / 8 + 1 / 16 . . . . . . .1 / 3 0.333 . . . . . . . 0.010101 . . . . . . . 1 / 4 + 1 / 16 1 / 64 . . . . . . .1 / 4 หรือ 0.24999 0.25 . . . . . . . 0.01 หรือ 0.00111 . . . . . . . 1 / 8 + 1 / 16 1 / 32 . . . . . . .1 / 5 0.1999 0.2 หรือ . . . . . . . 0.00110011 . . . . . . . 1 / 8 + 1 / 16 1 / 128 . . . . . . . .1 / 6 0.1666 . . . . . . . 0.0010101 . . . . . . . 1 / 8 + 1 / 3 + 1 / 128 . . . . . . . .1 / 7 0.142857142857 . . . . . . . 0.001001 . . . . . . . 1 / 8 + 1 / 64 + 1 / 512 . . . . . . . .1 / 8 เดือน หรือ 0.124999 . . . . . . . 0.000111 0.001 หรือ . . . . . . . 1 / 16 1 / 32 + 1 / 64 . . . . . . .1 / 9 ส.ค. . . . . . . . 0.000111000111 . . . . . . . 1 / 16 1 / 32 + 1 / 64 . . . . . . .1 / 10 0.0999 0.1 หรือ . . . . . . . 0.000110011 . . . . . . . 1 / 16 1 / 32 + 1 / 256 . . . . . . . .1 / 11 0.090909 . . . . . . . 0.00010111010001011101 . . . . . . . 1 / 16 1 / 64 + 1 / 128 . . . . . . . .1 / 12 0.08333 . . . . . . . 0.00010101 . . . . . . . 1 / 16 1 / 64 + 1 / 256 . . . . . . . .1 / 13 0.076923076923 . . . . . . . 0.000100111011000100111011 . . . . . . . 1 / 16 + 1 / + 1 / 128 256 . . . . . . . .1 / 14 0.0714285714285 . . . . . . . 0.0001001001 . . . . . . . 1 / 16 1 / 128 + 1 / 1024 . . . . . . . .1 / 15 0.0666 . . . . . . . 0.00010001 . . . . . . . 1 / 16 1 / 256 . . . . . . . .1 / 16 หรือ 0.0624999 ผล . . . . . . . 0.0000111 0.0001 หรือ . . . . . . . 1 / 32 + 1 / + 1 / 64 128 . . . . . . . .เลขคณิตไบนารี [ แก้ไข ]คณิตศาสตร์ในไบนารีมีมากเหมือนเลขคณิตในระบบตัวเลขอื่น ๆ การบวก การลบ การคูณ และการหาร สามารถใช้เลขไบนารีนอกจากนี้ [ แก้ไข ]บทความหลัก : ไบนารีเพิ่มเติม .แผนภาพวงจรสำหรับวงจรบวกครึ่งไบนารี ซึ่งเพิ่มสองร่วมกัน การผลิตรวมและดำเนินการบิตที่ง่ายที่สุดในการดำเนินการเลขคณิตไบนารีคือนอกจาก การเพิ่มตัวเลขสองหลักเดียว แบบไบนารีคือค่อนข้างง่าย ใช้แบบพกพา :0 + 0 → keyboard - key - name 00 + 1 → keyboard - key - name 11 + 0 → keyboard - key - name 11 + 1 → keyboard - key - name 0 พก 1 ( ตั้งแต่ 1 + 1 = 2 = 0 + ( 1 × 21 )เพิ่มสอง " 1 " ตัวสร้างเลข " 0 " ในขณะที่ 1 จะต้องเพิ่มคอลัมน์ถัดไป นี้จะคล้ายกับสิ่งที่เกิดขึ้นในทศนิยมเมื่อตัวเลขหลักเดียวบางอย่างเพิ่มเข้าด้วยกัน ถ้าผลเท่ากับหรือเกินกว่าค่าของราก ( 10 ) , ตัวเลขด้านซ้ายคือสั่ง :5 + 5 → keyboard - key - name 0 พก 1 ( ตั้งแต่ 5 + 5 = 10 = 0 + ( 1 × 101 )7 + 9 → keyboard - key - name 6 ยก 1 ( ตั้งแต่ 7 + 9 = 18 = 6 + ( 1 × 101 )นี้เป็นที่รู้จักกันเป็น ถือ เมื่อผลของการเพิ่มเกิน
การแปล กรุณารอสักครู่..
