100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.2 TrustPilot
logo-home
Class notes

Lecture notes Number Representation

Rating
-
Sold
-
Pages
17
Uploaded on
31-08-2023
Written in
2021/2022

basic knowledge of computer language.

Institution
Course










Whoops! We can’t load your doc right now. Try again or contact support.

Written for

Study Level
Examinator
Subject
Unit

Document information

Uploaded on
August 31, 2023
Number of pages
17
Written in
2021/2022
Type
Class notes
Professor(s)
Zafar ali khan
Contains
All classes

Subjects

Content preview

Computer Science 9608 (Notes)
Chapter: 1.1 Information representation



Topic: 1.1.1 Number representation
Fundamentals of Data Representation:

Before we jump into the world of number systems, we'll need a point of reference; I recommend that you
copy the following table that you can refer to throughout this chapter to check your answers.


Hexadecimal Binary Denary

0 0000 0

1 0001 1

2 0010 2

3 0011 3

4 0100 4

5 0101 5

6 0110 6

7 0111 7

8 1000 8

9 1001 9

A 1010 10

B 1011 11

C 1100 12

D 1101 13

E 1110 14

F 1111 15




Page 1 of 17

,Computer Science 9608 (Notes)
Chapter: 1.1 Information representation



Topic: 1.1.1 Number representation
Denary/Decimal

Denary is the number system that you have most probably grown up with. It is also another way of saying
base 10. This means that there are 10 different numbers that you can use for each digit, namely:

0,1,2,3,4,5,6,7,8,9

Notice that if we wish to say 'ten', we use two of the numbers from the above digits, 1 and 0.

Thousands Hundreds Tens Units
10^3 10^2 10^1 10^0
1000 100 10 1
5 9 7 3

Using the above table we can see that each column has a different value assigned to it. And if we know
the column values we can know the number, this will be very useful when we start looking at other base
systems. Obviously, the number above is: five-thousands, nine-hundreds, seven-tens and three-units.

5*1000 + 9*100 + 7*10 + 3*1 = (5973) 10 R




Binary Number System:

Binary is a base-2 number system, this means that there are two numbers that you can write for each digit
0, 1.
With these two numbers we should be able to write (or make an approximation) of all the numbers that we
could write in denary. Because of their digital nature, a computer's electronics can easily manipulate
numbers stored in binary by treating 1 as "on" and 0 as "off."

2^7 2^6 2^5 2^4 2^3 2^2 2^1 2^0
128 64 32 16 8 4 2 1
0 1 1 0 1 0 1 0

Using the above table we can see that each column has a value assigned to it that is the power of two (the
base number!), and if we take those values and the corresponding digits we can work out the value of the
number: 1*64 + 1*32 + 1*8 + 1*2 = 106.

If you are asked to work out the value of a binary number, the best place to start is by labeling each
column with its corresponding value and adding together all the columns that hold a 1. Let's take a look at
another example:
(00011111) 2
R




128 64 32 16 8 4 2 1
0 0 0 1 1 1 1 1

Page 2 of 17

, Computer Science 9608 (Notes)
Chapter: 1.1 Information representation



Topic: 1.1.1 Number representation
So now all we need to do is to add the columns containing 1s together:
1*16 + 1*8 + 1*4 + 1*2 + 1*1 = 31

Exercise: Binary
U




Convert the following binary numbers into denary
>>(00001100) 2 R




Answer :
128 64 32 16 8 4 2 1
0 0 0 0 1 1 0 0
8+4 = (12) 10
R




Convert the following binary numbers into denary
(01011001) 2 R




Answer :
128 64 32 16 8 4 2 1
0 1 0 1 1 0 0 1
64 + 16 + 8 + 1 = (89) 10 R




Convert the following binary numbers into denary
>>(00000111) 2 R




Answer :
128 64 32 16 8 4 2 1
0 0 0 0 0 1 1 1
4 + 2 + 1 = (7) 10
R




Convert the following binary numbers into denary
>>(01010101) 2 R




Answer :
128 64 32 16 8 4 2 1
0 1 0 1 0 1 0 1
64 + 16 + 4 + 1 = (85) 10 R




How do we tell if a binary number is odd?

Answer :
It's right most digit is a one
Page 3 of 17
$26.42
Get access to the full document:

100% satisfaction guarantee
Immediately available after payment
Both online and in PDF
No strings attached

Get to know the seller
Seller avatar
nafizatasnim

Get to know the seller

Seller avatar
nafizatasnim University of East London
Follow You need to be logged in order to follow users or courses
Sold
0
Member since
2 year
Number of followers
0
Documents
2
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Frequently asked questions