[go: up one dir, main page]

0% found this document useful (0 votes)
14 views7 pages

Number Systems and Binary Additions2

The document provides an overview of number systems, specifically focusing on denary, binary, and hexadecimal systems, including their conversions and calculations. It explains how to convert between binary and denary, as well as how to perform binary addition and handle signed numbers using two's complement. Additionally, it highlights the importance of understanding these systems for computing and data representation.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views7 pages

Number Systems and Binary Additions2

The document provides an overview of number systems, specifically focusing on denary, binary, and hexadecimal systems, including their conversions and calculations. It explains how to convert between binary and denary, as well as how to perform binary addition and handle signed numbers using two's complement. Additionally, it highlights the importance of understanding these systems for computing and data representation.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Number systems and further Binary

2.2.1.0 INTRODUCTIO N TO NUMBER SYSTEMS

• A number system is a system established to convert a


specific type to another . Eg – Binary to denary

2.2.1.1 denary system


• A denary system is a base – 10 value chart that has an increasing by 10 times value change from
right to left
Eg - 3639
103 102 101 100
1000(100*10) 100(10*10) 10(1*10) 1
3 6 3 9

(3*1000)+(6*100)+(10*3)+(1*9)
3000+600+30+9

Binary system

• Base 2 hence to the power of 2

27 26 25 24 23 22 21 20
128 64 32 16 8 4 2 1

NOTE –
THAT EACH VALUE MUST CONTAIN 8 values since a byte contains 8 bits more than that
is an overflow
Since each binary answer is a byte .

2.2.2.1 CONVERTIONS OF BINARY AND DENARY

EG – convert 213 to binary

Steps –
1 ) find the nearest lowest value to the given number but note for your level the maximum is 128 you
will figure it later
If we have 213 it is near to 128 which is technically 27

Rashmitha Jayawardhana Grade 9/10 computing Edexcel


2) subtract the converting value by different values

For an instance :
27 26 25 24 23 22 21 20
128 64 32 16 8 4 2 1
1 1 0 1 0 1 0 1

213 – 128 = 85
85-64 – 21
21-16=5
5-4=1
1-1=0

Therefore, the answer is 11010101 2

MAKE SURE TO DO THE QUESTIONS


ATTACHED

HEXADECIMAL SYSTEM

- We have come across 8-bit binary numbers, but


they could be 32 and 64 bits.
- It is hard to memorize 8 bits , how about 32 and 64
bits ? it would be impossible. Hence the
hexadecimal system can be used.
- However, computers do not use hexadecimal ,
instead they still use binary.
- It has a base of 16 , hence a power of 16
- It has a different alphabet than human –

TO TURN BINARY TO HEXADECIMAL

Rashmitha Jayawardhana Grade 9/10 computing Edexcel


0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
0 1 2 3 4 5 6 7 8 9 A B C D E F
Take 11100110 for an instance –

1 1 1 0 0 1 1 0

1 1 1 0 0 1 1 0

23 22 21 20 23 22 21 20
8 4 2 1 8 4 2 1

8*1 +2*1 +4*1 4*1 + 2*1

14 6
14 in hexadecimal would be E
6 IN HEXADECIMAL WOULD BE 6
THEREFORE, E6 IS THE ANSWER

TO CONVERT HEXADECIMAL TO BINARY


CONSIDER AC
AC

Rashmitha Jayawardhana Grade 9/10 computing Edexcel


10 12
8 4 2 2^0= 1 8 4 2 2^0= 1
1 0 1 0 1 1 0 0

10-8-2 12 -8 = 4
2-2=0 4-4 =0

AMSWER = 10101100
• NOTE THAT SOMEHOW BOTH SIDE MUST HAVE 4 BITS
IF LESS ADD ZEROS

FURTHER BINARY !
Further binary is extended and advanced calculations
done from binary values

3.1 BINARY ADDITIONS


Before doing any calculations know what any binary
digit would cause –
1+1 = 1 0
0+0 = 0
0+1 = 1
1+0 = 1

Rashmitha Jayawardhana Grade 9/10 computing Edexcel


1 +1 +1 = 0 and a carry-over of 1

how much is 11010110+01100111 in binary

11010110
+ 01100111
-----------
overflow 100111101

But it should be 8 bit but here we have 9 so it is an


overflow

SIGN AND UNSIGNED NUMBERS

IN DENARY A (–) AND (+) IS IDENTIFIE


HOWEVER IN BINARY YOU CANNOT

Sign And Magnitude


In a bit value the left most value is called the MSB (
most significant bit). We can use it to represent signs
We use 0 as + and 1 as –

For an instance –
11111000

Rashmitha Jayawardhana Grade 9/10 computing Edexcel


The MSB IS 1
SINCE THE GREATEST DIGIT IS TAKEN BY THE
SIGN THE LARGEST POSITIVE NUMBER
PRODUCED BY A BYTE IS 127

Adding Signed integers


Normally if we add -28 and + 28 we get 0
but if we use binary addition to do it we
will get – 56 which is wrong
Hence to do it properly we use two’s
compliment theory
1) FINDING TWO’S COMPLEMENT IN A BINARY
NUMBER
- Flip all of the bits change 1 to 0 and 0 to 1
- Add 1 to the value given

power 2^7 2^6 2^5 2^4 2^3 2^2 2^1 2^0


Exponentiation 128 64 32 16 8 4 2 1
Num 0 0 0 1 1 1 0 0
Flip 1 1 1 0 0 0 1 1
carry 1 1
+1 1 1 1 0 0 1 0 0
It is 11100100

Since 1 is the MSB and it denotes minus


-128+64+32+4
-128+100

Rashmitha Jayawardhana Grade 9/10 computing Edexcel


-28

Two’s complement to denary

Method 1 – reverse calculation

Imagine -28
The binary value is 11100100
First we flip it
- 28 1 1 1 0 0 1 0 0
flip 0 0 0 1 1 0 1 1
Add 1 0 0 0 1 1 1 0 0
power 2^7 2^6 2^5 2^4 2^3 2^2 2^1 2^0
Exponentiation 128 64 32 16 8 4 2 1
-128+64+32+4 =-28

Second method – place


power 2^7 2^6 2^5 2^4 2^3 2^2 2^1 2^0
Exponentiation 128 64 32 16 8 4 2 1
1 1 1 0 0 1 0 0
-128 +64 +32 +4

Therefore it is -28

Rashmitha Jayawardhana Grade 9/10 computing Edexcel

You might also like