





Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
IGCSE Chapter 2 Binary Numbers
Typology: Exams
1 / 9
This page cannot be seen from the preview
Don't miss anything!






1.1 DATA REPRESENTATION
The binary number system plays a central role in how information of all kinds is stored on computers. Understanding binary can lift a lot of the mystery from computers, because at a fundamental level they’re really just machines for flipping binary digits on and off. There are several activities on binary numbers in this document, all simple enough that they can be used to teach the binary system to anyone who can count! Generally children learn the binary system very quickly using this approach, but we find that many adults are also excited when they finally understand what bits and bytes really are.
In mathematics and digital electronics, a binary number is a number expressed in the binary numeral system, or base-2 numeral system, which represents numeric values using two different symbols: typically 0 (zero) and 1 (one). The base-2 system is a positional notation with a radix of 2. Because of its straightforward implementation in digital electronic circuitry using logic gates, the binary system is used internally by almost all modern computers and computer-based devices. Each digit is referred to as a bit.
Number System
A number system is a method of calculation and counting and working with digits and numbers. Scientists and mathematicians use four numbers systems as follows:
Binary 2 2 0, 1
Octal 8 8 0,1,2,3,4,5,6,
Decimal 10 10 0,1,2,3,4,5,6,7,8,
Hexadecimal 16 16 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
1.1 DATA REPRESENTATION
Binary Number System
In an 8-bit binary number system the counting is done using the following binary scale: 8 7 6 5 4 3 2 1
128 64 32 16 8 4 2 1
Binary counting may be represented (by adding each bit’s value) using binary scale as follows:
Decimal numbers
Binary numbers
1.1 DATA REPRESENTATION
Relationship between measurements
Size Equal to Unit
8 bits 1 byte B
1024 bytes 1 kilobyte KB
1024 kilobytes 1 megabyte MB
1024 megabytes 1 gigabyte GB
1024 gigabytes 1 terabyte TB
1024 terabytes 1 petabyte PB
1024 petabytes 1 Exabyte EB
1024 exabytes 1 Zettabyte ZB
1024 zettabytes 1 Yottabyte YB
The size of a file and a storage device's capacity will always be written in its simplest form. For example, an operating system would report a 1 terabyte hard disk's size as 1TB not as 1024GB, although both are correct.
Example file sizes
The table below lists files commonly found on a computer and their typical file size (compressed):
File File size
Photo 3MB
Song 5MB
Film 700MB
A file’s size can be influenced by a number of factors but ultimately the more information a file stores, the larger it will be.
In Data storage and when describing memory size, a Kilobyte is 2^10 , or 1024 bytes. Bytes are always some multiple or exponent of two.
1.1 DATA REPRESENTATION
Bit: Short for bi nary digi t. The smallest unit of information handled by a computer. One bit expresses a 1 or a 0 in a binary numeral, or a true or false logical condition, and is represented physically by an element such as a high or low voltage at one point in a circuit or a small spot on a disk magnetized one way or the other.
Byte : Short for b inar y te rm. A unit of data, today almost always consisting of 8 bits. A byte can represent a single character, such as a letter, a digit, or a punctuation mark.
Conversion of positive denary integers into binary and positive binary integers into denary
Denary (Decimal) Integers into binary
Method 1:
(26) 10 (? ) 2
Since the denary number (base 10) needs to be converted into the binary number (base 2), therefore the number has to be divided by 2.
2 26 2 13 – 0 2 6 – 1 2 3 – 0 2 1 – 1
= (11010) 2 is the binary integer of (26) 10 Denary integer
Method 2:
Use the binary scale and mark a “ 1 ” (on) to the bits positions that add up to make 42. i.e. 32 + 8 + 2 = 42
26 divided by 2 is 13, and remainder is 0 13 divided by 2 is 6, and remainder is 0
Collect all the remainders from bottom to top. Hence: 1 1 0 1 0
1.1 DATA REPRESENTATION
What you can see from this expression is that each digit is a placeholder for the next higher power of 10, starting in the first digit with 10 raised to the power of zero.
The Base-2 System and the 8-bit Byte
The reason computers use the base-2 system is because it makes it a lot easier to implement them with current electronic technology. You could wire up and build computers that operate in base-10, but they would be fiendishly expensive right now. On the other hand, base-2 computers are relatively cheap.
So computers use binary numbers, and therefore use binary digits in place of decimal digits. The word bit is a shortening of the words "Binary digIT." Whereas decimal digits have 10 possible values ranging from 0 to 9, bits have only two possible values: 0 and 1. Therefore, a binary number is composed of only 0s and 1s, like this: 1011. How do you figure out what the value of the binary number 1011 is? You do it in the same way we did it above for 6357, but you use a base of 2 instead of a base of 10. So:
(1 * 2^3 ) + (0 * 2^2 ) + (1 * 2^1 ) + (1 * 2^0 ) = 8 + 0 + 2 + 1 = 11
You can see that in binary numbers, each bit holds the value of increasing powers of 2. That makes counting in binary pretty easy. Starting at zero and going through 20, counting in decimal and binary looks like this:
When you look at this sequence, 0 and 1 are the same for decimal and binary number systems. At the number 2, you see carrying first take place in the binary system. If a bit is 1, and you add 1 to it, the bit becomes 0 and the next bit becomes 1. In the transition from 15 to 16 this effect rolls over through 4 bits, turning 1111 into 10000.
Bits are rarely seen alone in computers. They are almost always bundled together into 8-bit collections, and these collections are called bytes. Why are there 8 bits in a byte? A similar question
1.1 DATA REPRESENTATION
is, "Why are there 12 eggs in a dozen?" The 8-bit byte is something that people settled on through trial and error over the past 50 years.
With 8 bits in a byte, you can represent 256 values ranging from 0 to 255, as shown here: 0 = 00000000 1 = 00000001 2 = 00000010 ... 254 = 11111110 255 = 11111111
Measuring Bytes in Devices
The hard disk A hard disk stores: the operating system software applications or programs the majority of your data files
Hard disks spin at very high speeds (around 7,200 RPM - revolutions per minute) within a sealed unit inside the computer. Hard disks store large amounts of data - 200GB to 1TB is common in desktop computers. The data stored on a hard disk is retained until deleted, but it needs to be loaded into main store RAM before it can be used.
Floppy disk Floppy discs became popular in the 1970s. The most common format was 1.44 MB, capable of holding only very small amounts of data. Computers need a floppy drive to read floppy disks, and many modern computers are no longer supplied with a floppy disc drive because we now work with much larger files.
Now we are capable of storing 16 GB of data on a memory card which is, physically, six times smaller then a floppy disk. It would take roughly 11,111 floppy disks to store 16 GB of data.
In the past, floppy disks were used to: transfer small files of data from one machine to another backup important small files stored on a hard disk store restricted files that you didn’t want other users of your computer seeing
Zip disk Zip disks are like large floppy disks but can store 250MB or more of data. To read them a computer needs a zip drive. Their use is similar to that of floppy disks.
Newer storage mediums such as DVD-RWs and memory sticks have replaced floppy/zip disks
External backing stores: optical discs
There are several different types of optical disc, although they all look pretty much the same.
CD (Compact Disc) Optical discs that use the same technology as music CDs. They store up to 700MB of data. CDs can be used for multimedia applications such as encyclopaedias and can store pictures, sounds and video clips or anything else that will fit.
There are several formats on the market, such as: CD-ROM - read only, the data is written to them before they are sold. CD-R - meaning CD-Recordable, the user can write data to the CD once or fill it over time using multi-session (writing to the same disc on separate occasions).