Number Systems: By: Miss. Chrisna L. Fucio

Download as pdf or txt
Download as pdf or txt
You are on page 1of 49

NUMBER SYSTEMS

by: Miss. CHRISNA L. FUCIO


Number can classify into “sets” called
number system.

The decimal number 1 is an example


of this sort of symbol
In counting, the simplest system is not
decimal system but as /one to one
comparison between the objects to
be counted and the count, or tally.

Mark marks as IIII.


This system is nothing more
than a code where each distinct
quantity is assigned symbols.

In the decimal system the ff.


digits are used: 0, 1, 2, 3, 4, 5, 6, 7, 8,
and 9. These symbols are called Arabic
numerals
Defined as a string of decimal digits

Decimal Fraction is a string of


decimal digits together with an
embedded decimals point

Decimal Integer can be


expressed as the sum of each of its
digits times a power of ten.
85463= 8x104 + 5x103 + 4x102 + 6x101 + 3x100
= 8x10000 + 5x1000 + 4x100 + 6x10 + 3x1

A number raised to a power is


called a base; hence, 10 is the base
of the decimal system.
may also be expressed in expanded
notation, but the place values of the
digits to the right of the decimal point
are the negative powers of ten as 10-1
or 1/10, 10-2, 1/100, and 10-3 or 1/1000

736.258
= 7x102 + 3x101 + 6x100 + 5x10-1 + 2x10-2 + 2x10-3
= 7x100 + 3x10 + 6x1 + 5/10 + 2/100 + 8/1000
Scientific notation provides a convenient
scheme for representation of such quantities.

Positive numbers expresses in scientific


notation when it is written as the product of
an integral power of 10 and a number
between 1 and 10.

Form: Mx10n where M is a number between


1 and 10.
a. 226, 400,000 = 2.264 x 100,000,000 = 2.264x 108
b. 300,000,000 = 3x100,000,000 = 3x 108
c. 9,240,000,000,000,000
= 9.24x100, 000,000,000,000
= 9.24x1015
d. 0.000,000,2 = 2x0.000,000,1 = 2x10-7
Rounding off a value is the process of
dropping or eliminating one or more of the
final digits on the right so that the value
contains only the significant figures required
for further computation or for reporting in
the final results.

a. Rounding Down
Ex.Original Number: 124.244 138.563
Rounded Off: 124.24 138.56
b. Rounded Off
Ex.Original Number: 1.395 26.175
Rounded Off: 1.40 26.18

c. Rounding Up
Ex.Original Number: 26.276 566.666
Rounded Off: 26.28 566.67
Suppose that one simply deletes the digits
after a certain digit rather than rounding off
the number. This process is called truncating
or chopping

Ex.
Original Number: 88.76 246.8 178.9587
Rounded Off: 88 246 178
In the computer, data is recorded as
electronic signals or indications. The presence
or absence of these signals in specific circuitry
represents data in the computer just as the
presence or absence of punched holes
represents data on a punched card.

A binary method of notation can be used to


describe settings of binary components.
Binary Notation use only two symbols: 0 and 1
Gottfried W. Von Leibniz
The symbols used in binary notation (0
and 1) are called bits, which is a short way of
saying binary digits.

The rule is simple:


To convert decimal whole numbers from base
10 to any other base, divide that number repeatedly
by the value of the base to which number is being
converted. The division operation is repeated until
the quotient is zero. The remainder - written in
reverse of the order in which they were obtained,
from the new equivalent numeral.
Convert 139 to binary
Division Quotient Reminders
139/2 69 1
69/2 34 1
34/2 17 0
17/2 8 1
8/2 4 0
4/2 2 0
2/2 1 0
1/2 0 1

Therefore 13910 = 10010112


Binary numerals can be converted to
decimal by the use of expanded notation.

Example:
a. 101 = 1x22 + 0x21 + 1x20
= 4+0+1
= 5

b. 1100 = 1x23 + 1x22 + 0x2 + 0x20


= 8+4+0+0
= 12
c. 100100 = 1x25 + 0x24 + 0x23 + 1x22 +
1x21 + 0x20
= 32 + 0 + 0 + 4 + 2 + 0
= 38

d. 111111 = 1x25 + 1x24 + 1x23 + 1x22 +


1x21 +1x20
= 32 + 16 + 8 + 4 + 2 + 1
= 63
A decimal fraction may also be converted
into an equivalent binary notation.

A much simpler method consists of


repeatedly doubling the decimal fraction and
noting the integral part of the product.
Convert decimal fractions to binary equivalent.
a. Multiplications Integral Parts
0.375x2 = 0.75 0
0.75x2 =1.5 1 therefore
0.5x2 = 1.0 1 0.37510 = 0.0112

b. Multiplications Integral Parts


0.40625x2 = 0.8125 0
0.8125x2 = 1.625 1
0.625x2 = 1.25 1
0.25x2 = 0.5 0 therefore
0.5x2 = 1.0 1 0.4062510 = 0.011012
The binary equivalent of a terminating decimal
fraction does not always terminate or is not exactly
converted.
Multiplications Integral Parts
0.8x2=1.6 1
0.6x2=1.2 1
0.2x2=0.4 0
0.4x2=0.8 0
0.3x2=1.6 1 therefore
0.6x2=1.2 1 0.8 = 0.1100 1100 1100 …. …. ….
10 2

0.2x2=0.4 0
0.4x2=0.8 0
0.8x2=1.6 1
…….
Example:
Converting the decimal number 24.625 to its binary
equivalent

1st step: Converting the integral part


Divisions Quotients Remainders
24/2 12 0
12/2 6 0
6/2 3 0
3/2 1 1 therefore
1/2 0 1 2410 = 110002
2nd step: Converting the fractional part

Multiplication Integral Part


0.625x2=1.25 1
0.25x2 = 0.5 0 therefore
0.5x2=1.0 1 0.62510 = 0.1012

3rd steps: The binary equivalent of 24.625 is simply the


sum of these two equivalents. Thus
2410 + 0.62510 = 110002 + 0.1012
24.62510 = 11000.1012
Example:
a) 0.101 = 1x2-1 + 0x2-2 + 1x2-3
= 1/2 + 0 + 1/8
= 0.5 + 0 + 0.125
= 0.625

b)11.011 = 1x21 + 1x20 + 0x2-1 + 1x2-2 + 1x2-3


= 2 + 1 + 0 + 1/4 +1/8
= 3 + 0.25 + 0.125
= 3.375
Binary Addition is simple to learn since there
are only two characters, 0 and 1, to consider.
Four possible combination
0+0=0
0+1=1
1+0=1
1 + 1 = 0 Plus a carry over of 1
Example:
a. BINARY DECIMAL
11 3
+ 100 + 4
111 7
Example:
b. BINARY DECIMAL
1010 10
+1100 + 12
10110 22
c. BINARY DECIMAL
11.01 3.25
+101.11 + 5.75
1001.00 9.00
d. BINARY DECIMAL
101011 43
+ 110011 + 51
1011110 94
Example:
e. BINARY DECIMAL
101 (1st number) 5
100 (2nd number) 4
10 (3rd number) 2
1010 (4th number) 10
+ 1110 (5th number) + 14
? (sum) 35
The binary sum is obtained as follows
e. BINARY
101 (1st number)
+ 100 (2nd number)
1001 (1st sub – total)
+ 10 (3rd number)
1011 (2nd sub – total)
+ 1010 (4th number)
10101 (3rd sub – total)
+ 1110 (5th number)
100011 (Final total)
Checking
100011 = 1x20 1x20 + 1x21 + 0x22 + 0x23 +1x25
= 1+2+0+0+0+32
= 35
Binary Subtraction is little more complicated than that
of addition. It is inverse operation of addition.
Table for subtraction is as follows:
0–0=0
1–0=1
1–1=0
0 – 1 = 0 with a borrow of 1
Example:
a. BINARY DECIMAL
1010 10
– 100 – 4
110 6
Example:
b. BINARY DECIMAL
1111 15
- 1000 - 8
111 7
c. BINARY DECIMAL
1000.11 8.75
- 11.01 - 3.25
101.10 5.50
Complement arithmetic has particular appeal
in the case of the binary system since to obtain the
inverse of binary numbers no subtraction is
required, only bit inversion.

Example
BINARY DECIMAL
110011 51
- 11101 - 29
? 22
Solution
Example:
a) BINARY
110011
+ 00010 (complement of the subtrahend 11101)
110101 (binary sum)
+ 1 (end – around carry)
10110 (answer)
b) BINARY DECIMAL
1100.01 12.25
- 1010.10 - 10.50
? 1.75
Solution using ones complement
1100.01
+0101.01 (complement of the subtrahend 1010.10)
10001.10 (binary sum)
+ 1 (end-around carry)
1.11 (answer)
The rule for decimal multiplication also holds
for binary multiplication. It is simpler since
multiplying numbers by the bit 0 or 1 yields
respectively 0 or 1 the number.
Multiplication consists of adding a number to
itself as many times as is specified by the
multiplier
The binary multiplication table is
0x0=0 0x1=0
1x0=0 1x1=1
Example:

a) BINARY DECIMAL
111 (multiplicand) 7
x 101 (multiplier) x 5
111 (1st partial product) 35
000 (2nd partial product)
111 (3rd partial product)
100011 (column sums yield the answer)
Example:

b) BINARY DECIMAL
11.00 3.0
x 10.10 x 2.5
0000 150
1100 60
0000 7.5
1100
111.1000 (answer)
Binary Division is a very simple process.
Division is inverse of multiplication and division
by zero is similarly meaningless.
The complete table for binary division is
0/1 = 0 1/1 = 1
Example:
a) BINARY DECIMAL
12/4 = 3
The above problem could be also solved by
the process of repeated subtraction.

BINARY DECIMAL
1100 12/4 = 3
- 100 (1st subtraction)
1000
- 100 (2nd subtraction)
100
100 (3rd subtraction) Therefore:
000 11002/1002 = 112
The octal number system was adapted
because of the difficulty of dealing with long
strings of binary 0’s and 1’s in converting them
into decimals.

The eight basic digits of the octal system are


0,1,2,3,4,5,6, and 7.

Octal represent eight to the zero power or 80


units; the second (next most significant) column
represents eight to the first power 81 or eights,
and so on.
converting for decimal to octal, we divide
decimal by eight note the remainders after each
division. This technique called the remainder
method.
a. DIVISION REMAINDERS
18/8 = 2 2
2/8 = 0 2
b. DIVISION REMAINDERS
255/8 = 31 7
31/8 = 3 7
3/8 = 0 3
Therefore: 1810 = 228
25510 = 3778
Octal number system each digit corresponds
to a power of 8.

a. 258 = 2x81 + 5x80


= 16 + 5
= 2110

b. 15.358 = 1x81 + 5x80 + 3x8-1 + 5x8-2


= 8 + 5 + 3/8 + 5/64
= 13.45312510

Therefore: 258 = 2110


15.358 = 15.358
When converting decimal fractions to octal
fractions multiply the decimal number by eight
and note the carry into the integer position.

Example:
Multiplication Carry Over
0.2575x8 = 2.06 2
0.06 x 8 = 0.48 0
0.48 x 8 = 3.84 3
0.84 x 8 = 6.72 6
0.72 x 8 = 5.75 5
Therefore: 0.257510 = 0.203658
Example

a. 458 = ?2
since: 48 = 1002
and 58 = 1012
b. 124.578 = ?2
since: 18 = 0012 , 28 = 0102 , 48 = 1002
58 = 1012, and 78 = 1112
Converting from binary to octal is the reverse
of the procedure

a. 101101112 = ? 8
Grouping the bits into three:
1011011112 = 010 110 1112 or 2678
b. 1011.011012 = ? 8
Grouping the bits into three:
1011. 01101 = 001 011.011 1012 or 13.328

Binary 000 001 010 011 100 101 110 111


Number
Octal 0 1 2 3 4 5 6 7
Number
The hexadecimal number system provides
another convenient and simple method for
expressing values represented by binary
numerals.

This system is a combination of the ten numbers,


0 through 9 and a choice of six letters of the
alphabet, which are also treated as number. It
uses a base, or radix of 16 and the place values
are the powers of 16.
One way to perform a decimal to hexadecimal
conversion is to go from decimal to binary and
then to hexadecimal.

a. DIVISION REMAINDERS
58/16 = 3 10 (or A) therefore:
3/16 = 0 3 5810 = 3A16

b. DIVISION REMAINDERS
362/16 = 22 10 (or A) therefore:
22/16 = 1 6 36210 = 16A16
1/16 = 0 1
One way is to convert from hexadecimal to
binary and then decimal.

a. 4B616 = 4x162 + 11x161 + 6x160


= 1024 + 176 + 6
= 120610

b. 4139.B88
= 4x163 + 1x162 + 3x161 + 9x160 +11x16-1 + 8x16-2
= 16384 + 256 + 48 + 9 + 0.6875 + 0.03125
= 16697.7187510
The conversion from hexadecimal to binary is a
simple procedure and easily done is replacing
each hexadecimal digit by its 4-bit equivalent.

a. 2C8516 = ?2
since: 216 = 00102 ,, C16 = 11002 , 816 = 10002
, and 516 = 01012
therefore 2C8516 = 0010 1100 1000 01012
b. 8A.5B16 = ?2
since: 816 = 10002 ,A16 = 10102 ,
516 = 01012 , B16 = 10112
therefore 8A.5B16 = 1000 1010 . 010110112
Converting from binary to hexadecimal is the
reverse of the procedure

a. 1011101100100112 = ? 16
Grouping the bits into four:
1011101100100112
= 0101 1101 1001 00112 or 5D9316
b. 110001010.011011102 = ? 16
Grouping the bits into four:
110001010.01101110
=0001 1000 1010.0110 11102 or 18A.6E16
Hexadecimal Number Binary Number
0 0000
1 0001
2 0010
3 0011
4 0100
5 0101
6 0110
7 0111
8 1000
9 1001
10 or A 1010
11 or B 1011
12 or C 1100
13 or D 1101
14 or E 1110
15 or F 1111

You might also like