Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Number System[HEXADECIMAL].pptx
1. HEXADECIMAL
* BASE OR RADIX - 16
* DIGITS IS FROM 0-9 and A,B,C,D,E,F
DECIMAL 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
HEXADECIMAL 0 1 2 3 4 5 6 7 8 9 A B C D E F
2. HEXADECIMAL TO BINARY
STEP 2: Represent each hex digits by
four binary digits.
STEP 1:Write down the hex number. If there
are any, change the hex values represented by
letters to their decimal equivalents.
1. Convert (10AF)16 into its Binary equivalent
1 0 A F
1 0 10 15
1 0 A F
1 0 10 15
0001 0000 1010 1111
STEP 3: Combine each 4 digit number
to get resultant answer
ANSWER: (0001000010101111)2
3. HEXADECIMAL TO BINARY
STEP 2: Represent each hex digits by
four binary digits.
STEP 1:Write down the hex number. If there
are any, change the hex values represented by
letters to their decimal equivalents.
2. Convert (FACE.32)16 into its Binary equivalent
F A C E 3 2
15 10 12 14 3 2
STEP 3: Combine each 4 digit number to get
resultant answer
ANSWER: (1111101011001110.00110010)2
F A C E 3 2
15 10 12 14 3 2
1111 1010 1100 1110 0011 0010
4. HEXADECIMAL TO BINARY
EXERCISE:
1. CONVERT (A27)16 in to Binary Equivalent
ANSWER : 10 2 7
1010 0010 0111
2. CONVERT (9DB2)16 in to Binary Equivalent
ANSWER : 9 13 11 2
1001 1101 1011 0010
5. HEXADECIMAL TO OCTAL
STEP 4: Separate the binary digits into groups, each
containing 3 bits or digits from right to left. Add 0s to
the left, if the last group contains less than 3 bits..
101 101 011 010
STEP 1: Write the equivalent Hexa number
1. Convert (B5A)16 into its OCTAL equivalent 0-7
B 5 A
11 5 10
B 5 A
11 5 10
1011 0101 1010
STEP 3:Write the all groups binary numbers
together, maintaining the same group.
1 101 011 010
STEP 2:Find the equivalent binary number for each
digit of number. Add 0's to the left if any of the binary
equivalent is shorter than 4 bits
STEP 5 :Find the octal equivalent for each group.
101 101 011 010
5 5 3 2
(5532)8
6. HEXADECIMAL TO OCTAL
STEP 4: Separate the binary digits into groups, each
containing 3 bits or digits from right to left. Add 0s to
the left, if the last group contains less than 3 bits..
00 1 010 001 011 011 110
STEP 1: Write the equivalent Hexa number
1. Convert (A2DE)16 into its OCTAL equivalent
A 2 D E
10 2 13 14
A 2 D E
10 2 13 14
1010 0010 1101 1110
STEP 3:Write the all groups binary numbers
together, maintaining the same group.
001 010 001 011 011 110
STEP 2:Find the equivalent binary number for each
digit of octal number. Add 0's to the left if any of the
binary equivalent is shorter than 4 bits
STEP 6 :Find the octal equivalent for each group.
(121336)8
7. HEXADECIMAL TO OCTAL
EXERCISE:
1. CONVERT (A42)16 in to Binary Equivalent
ANSWER :10 4 2
101 0 01 000 010 5102
2. CONVERT (1BC)16 in to Binary Equivalent
ANSWER : 1 11 12
000 110 11 1 100 674
8. OCTAL TO HEXADECIMAL
STEP 1: Find the equivalent binary number
for each digit of octal number.
1. Convert (345)8 into its Hexadecimal equivalent
3 4 5
011 100 101
STEP 3: Separate the binary digits into groups,
each containing 4 bits or digits from right to left.
Add 0s to the left, if the last group contains less
than 4 bits..
STEP 2:Write the all groups binary numbers together,
maintaining the same group.
STEP 6 :Find the octal equivalent for each group.
0000 1110 0101
0 E 5
(E5)16
011100101
0 1110 0101
9. OCTAL TO HEXADECIMAL
STEP 1: Find the equivalent binary number
for each digit of octal number.
1. Convert (752)8 into its Hexadecimal equivalent
7 5 2
111 101 010
STEP 3: Separate the binary digits into groups,
each containing 4 bits or digits from right to left.
Add 0s to the left, if the last group contains less
than 4 bits..
STEP 2:Write the all groups binary numbers together,
maintaining the same group.
STEP 6 :Find the octal equivalent for each group.
(1EA)16
111101010
0001 1110 1010
10. OCTAL TO HEXADECIMAL
STEP 1: Find the equivalent binary number
for each digit of octal number.
1. Convert (752)8 into its Hexadecimal equivalent
7 5 2
111 101 010
STEP 3: Separate the binary digits into groups,
each containing 4 bits or digits from right to left.
Add 0s to the left, if the last group contains less
than 4 bits..
STEP 2:Write the all groups binary numbers together,
maintaining the same group.
STEP 6 :Find the octal equivalent for each group.
(1EA)16
111101010
0001 1110 1010
12. ARITHMETIC OPERATION
Like we perform the arithmetic operations in numerals, in
the same way, we can perform addition, subtraction, multiplication
and division operations on Binary numbers.
BINARY ADDITION
Rules for adding two numbers
0 + 0 = 0
0 + 1 = 1
1 + 0 = 1
1 + 1 = 0 (Carry 1)
14. ARITHMETIC OPERATION
BINARY SUBTRACTION : Subtracting two binary numbers will give us a
binary number itself. It is also a straightforward method. Subtraction of two
single-digit binary number is given in the table below
1. Subtract 0111 from 1011.
1 0 1 1
0 1 1 1
0 1 0 0
0 - 0 = 0
1 - 0 = 1
1 - 1 = 0
0 - 1 = 1(BORROW 1 FROM
HIGH ORDER DIGIT)
11
7
4
17. ENCODING SCHEMES
What are encoding schemes.
Why are encoding schemes used?
Different Encoding schemes and their
implementation.
ASCII, ISCII, Unicode: UTF-8, UTF-16
18. WHY Encoding schemes are used??
Computers understand or rather stores and processes data in the form of sequence of
bits(0’s & 1’s) and produces outputs in the form digital signals which have only two
states(high & low),
Since it is quite impossible(insanely difficult) for humans to write instructions in 0’s &
1’s for the computers, different encoding schemes were envisaged for implementation, so
that the Computer understands what input the user gives.
When the key ‘A’ is pressed , it is internally mapped to a decimal value 65 (code value), which is then converted
to its equivalent binary value for the computer to understand.
So what is encoding? The mechanism of converting
data into an equivalent cipher using specific code is called encoding
19. VARIOUS CODES OF REPRESENTATION
ASCII (American Standard Code
Information Interchange)
ISCII (Indian Standard Code for
Information Interchange)
UNICODE(Universal Code Standard)
20. ASCII CODE
ASCII is an industry standard code, developed by the American National
Standards Institute (ANSI) and published in 1963.
ASCII is a seven-bit code (a range of 0 to 127 decimal) which assigns a
binary value to letters, numbers, and other characters.(Extended ASCII
represents a range of 0-255)
ASCII codes represent text and control characters in computers
communications equipment, and other devices that work with text.
Computer use an ASCII table to convert binary data into letters or
characters, so we can see visually and vice versa.
21. Encode the word DATA and convert the encoded value into binary
values which can be understood by a computer.
ASCII CODE
Encode the word BYTE and convert the encoded value into binary
values which can be understood by a computer.
B Y T E
ASCII CODE
BINARY CODE
ASCII CODE
22. In 1991 the Bureau of Indian Standards adopted the Indian
Standard Code for Information Interchange (ISCII).
The ISCII code retains all ASCII characters and offers coding
for Indian scripts like Devanagari, Gurmukhi, Gujarati,
Asamese, Bengali, Telugu, Kannada, Oriya, Malayalam and
Tamil scripts also.
ISCII is an 8-bit encoding,capable of coding 256 characters.
ISCII CODE
23. UNICODE
Unicode was developed as a universal character set with an aim: ›
To define all the characters needed for writing the majority of known languages
in use on computers in one place. ›
To be superset of all other characters sets that have been encoded.
The Unicode has different versions like UTF – 8, UTF – 16, UTF – 32.
Unicode maps every character to a specific code, called code point.
25. Main difference between UTF-8, UTF-16 and UTF-32
character encoding is how many bytes it require to
represent a character in memory.
UTF-8 encodes a character into a binary string of one, two,
three, or four bytes.
UTF-16 encodes a Unicode character into a string of either
two or four bytes.
UTF-32 uses 4 bytes to store every character.
UTF-8 is by far the most common encoding for the World Wide
Web, accounting for 81% to 97% of all web pages as of May
2020.
Unicode code points are written as U+ for e.g. U+0050
represent ‘P
27. BOOLEAN LOGIC
Boolean Logic is a form of algebra in which the variables have a logical value of TRUE
or FALSE.
It is named after George Boole, who first defined an algebraic system of logic in
the mid 19th century.
Boolean logic is especially important for computer science because it fits nicely with
the binary numbering system, in which each bit has a value of either 1 or 0
Programs use simple comparisons to help make
decisions.
Boolean Logic is a form of algebra where
all values are either True or False. These values
of true and false are used to test the conditions
28. BINARY VALUES
In our daily live, we need to take logical decisions answers comes in either YES ( T) or
NO(F) .Fo eg
Should I have tea?
Should I Opt for Computer Sciene or not?
The decision which results in Yes or NO only are know as Binary decisions
VALUES T AND F ARE KNOWS AS TRUTH VALUES
Boolean Variable can only be either T pf F.
- Indira Gandhi was the only lady Prime Minister Of India ( it result in True- T) –
Logical st
- What do u want to say ? ( Result will not be in T or F) – It is not a logic st
5 10
x < 10
x < y
29. LOGICALOPERATIONS
Before Proceeding for Operations we will get to know some features of logical
Statement: For Ex.
St- 1 : I want to have tea St 2 – Tea is ready
Now, develop a table with all its aspects
5 10
x < 10
x < y
TEA IS
READY (X)
I WANT TO
HAVE A
TEA(Y)
RESULT®
T T T
T F F
F T F
F F F
TEA IS
READY (X)
I WANT TO
HAVE A
TEA(Y)
RESULT®
1 0 1
1 0 0
0 1 0
0 0 0
TRUTH TABLE
30. LOGICALOPERATORS
AND
OR
NOT
TRUTH TABLE
A table which represents all the possible values of
logical variables along with all possible results of
the given combination of values
TAUTOLOGY
An expression or statement whose result is
always TRUE
FALLACY
An expression or statement whose result is
always FALSE
RULES:
1. CHECK THE VARIABLES
2. DRAW THE COL FOR EACH VARIABLE
AND EXPRESSION
3. DRAW ROWS – 2N
4. WRITE 0’S IN FIRST HALF AND
SECOND HALF AS 1’S
5. CALCULATE THE RESULT
31. and
Operates on two variables/expressions
Operation is logical multiplication
Symbol used is .(DOT)
Ex: X . Y can be read as X AND Y
Truth table for AND
X Y X.Y
0 0 0
0 1 0
1 0 0
1 1 1
32. OR
•Operates on two variables/expressions
•Operation is logical addition
•Symbol used is +(PLUS)
•Ex: X + Y can be read as X OR Y
•Truth table for OR
A B A+B
0 0 0
0 1 1
1 0 1
1 1 1
33. not
•Operates on a single variable
•Operation is called complementation
•Symbols are ~(tilde), ¯(bar), ‘(prime)
•Ex: ~X, X, X’
•Truth table for NOT
X X
0 1
1 0
34. recap
1. WHAT IS A BOOLEAN ALGEBRA?
2. WHAT IS A BOOLEAN VARIABLE?
3. WHAT IS A BOOLEAN STATEMENT?
4. WHAT ARE THE THREE FUNDAMENTAL OPERATORS?
5. DIFFERENTIATE BETWEEN THE THREE FUNDAMENTAL
OPERATORS.
6. WHAT IS A TRUTH TABLE?
7. HOW TO CONSTRUCT THE TRUTH TABLE.
35. Writethe truth table for Boolean expression f=A.B’+c
A B C B’ A.B’ A..B’+C
0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
NOT
AND
OR
36. LOGIC GATES
• A Logic gate is a kind of the basic building block of a digital circuit
having two inputs and one output.
• They perform basic logical functions that are fundamental to digital
circuits.
• Most electronic devices we use today will have some form of logic
gates in them. For example, logic gates can be used in technologies
such as smartphones, tablets or within memory devices.
• THREE FUNDAMENTAL LOGIC GATES:
AND
OR
NOT
NAND – AND NOT
NOR - OR NOT
XOR - EXCLUSIVE-OR
45. Convert 10101 to decimal equivalent
Step by step solution
Step 1: Write down the binary number:
10101
Step 2: Multiply each digit of the binary number by the
corresponding power of two:
1x24+ 0x23 + 1x22 + 0x21 + 1x20
Step 3: Solve the powers:
1x16 + 0x8 + 1x4 + 0x2 + 1x1 = 16 + 0 + 4 + 0 + 1
Step 4: Add up the numbers written above:
16 + 0 + 4 + 0 + 1 = 21.
So, 21 is the decimal equivalent of the binary number
10101.
Convert the decimal number 151.75 to
binary.
•division = quotient + remainder;
151 ÷ 2 = 75 + 1;
75 ÷ 2 = 37 + 1;
37 ÷ 2 = 18 + 1;
18 ÷ 2 = 9 + 0;
9 ÷ 2 = 4 + 1;
4 ÷ 2 = 2 + 0;
2 ÷ 2 = 1 + 0;
1 ÷ 2 = 0 + 1;
multiplying = integer + fractional part;
1) 0.75 × 2 = 1 + 0.5;
2) 0.5 × 2 = 1 + 0;
46. Convert the binary number 1011010 to
hexadecimal.
split that into groups of 4 bits from the right side.
101 1010
now 101 = 5 hex..... 1010 is A in hex.
So it is 5 A in hex form
Convert the hexadecimal number (1E2)16 to
decimal
(1E2)₁₆ = 1 * 16² + E * 16¹ + 2 * 16⁰
= 1 * 256 + (14) * 16 + 2
= 256 + 224 + 2
= 482
(170)10 = (AA)16
Step by step solution
Step 1: Divide (170)10 successively by 16
until the quotient is 0:
170/16 = 10, remainder is 10
10/16 = 0, remainder is 10