SlideShare a Scribd company logo
1 of 42
Common Number Systems
Conversion Among Bases 
• The possibilities: 
Decimal 
Hexadecimal
2510 = 110012 = 318 = 1916
Decimal to Decimal 
Decimal Octal 
Hexadecimal 
Binary
N=푎푚푟푚−1 + 푎푚−1푟푚−2 + ….. +푎2푟1 + 푎1푟0.+ 
푏1푟−1+푏2푟−2+ ……+ 푏푛푟−푛 
r=10 (decimal)
12510 => 5 x 100 = 5 
2 x 101 = 20 
1 x 102 = 100 
125 
Base 
Weight
Binary to Decimal 
Decimal Octal 
Hexadecimal 
Binary
Binary to Decimal 
• Technique 
• Multiply each bit by 2n, where n is the “weight” of the bit 
• The weight is the position of the bit, starting from 0 on 
the right 
• Add the results
Example 
1010112 => (1 x 20)+(1 x 21)+(0 x 22)+(1 x 23)+(0 x 24) 
+(1 x 25) 
= 1+2+0+8+0+32 
= 4310 
Bit “0”
Decimal to Binary 
Decimal Octal 
Hexadecimal 
Binary
Decimal to Binary 
• Technique 
• Divide by two, keep track of the remainder 
• First remainder is bit 0 (LSB, least-significant bit) 
• Second remainder is bit 1 
• Etc.
Example 
12510 = ?2 
2 125 
2 6 2 1 
2 3 1 0 
2 1 5 1 
2 7 1 
2 3 1 
1 1 
12510 = 11111012
Example: 
(0.3125)10 
0.3125 x 2=0.625 0 MSB 
0.625 x 2=1.25 1 
0.25 x 2=0.50 0 
0.50 x 2=1.00 1 LSB 
Ans.:- (0101)2
Binary Arithmetic: 
Binary Addition: 
• Two 1-bit values 
A B A + B 
0 0 0 
0 1 1 
1 0 1 
1 1 10 
“two”
Binary Addition 
• Two n-bit values 
• Add individual bits 
• Propagate carries 
• E.g., 
1 1 
10101 21 
+ 11001 + 25 
101110 46
Binary Subtraction 
Rules for binary subtraction are: 
0 – 0 = 0 
1 – 0 = 1 
1 – 1 = 0 
0 – 1 = 1 , with 1 borrowed from the next column 
Ex 1: 1100101 – 100111 
Verify the result in decimal system. 
Solution: 
(10011)2 = 1*24 + 1*21 + 1*20 = (19)10
Complements of Binary Numbers 
• 1’s complements 
• 2’s complements 
18
1’s and 2’s Complement: 
 The 1’s complement of a binary number is simply obtained by 
replacing every 1 by 0 , and every 0 by 1. 
 The 2’s complement of a binary number can be obtained in 
two ways: 
 By adding 1 to the 1’s complement. 
 Start the binary number from right. Leave the binary digits 
unchanged until the first 1 appear, then replace every 1 by 
0 , and every 0 by 1.
Complements of Binary Numbers 
• 1’s complement 
• Change all 1s to 0s and all 0s to 1s 
1 0 1 0 1 0 1 0 
0 1 0 1 0 1 0 1
Ex 1: Obtain the two’s complement of the binary number 1011010.110 
First solution 
Second solution
Ex 2: Calculate the following binary Subtraction: 1101.101 – 11011.11 , 
then verify the result in decimal System. 
Solution
Basic Logic Gates
NOT Gate -- Inverter 
X Y 
0 
1 
1 
0 
NOT 
X Y 
Y 
= ~X
NOT 
X ~X ~~X = X 
X ~X ~~X 
0 1 0 
1 0 1
AND Gate 
AND 
X 
Y 
Z 
Z = X & Y 
X Y Z 
0 0 0 
0 1 0 
1 0 0 
1 1 1
OR Gate 
OR 
X 
Y 
Z 
Z = X | Y 
X Y Z 
0 0 0 
0 1 1 
1 0 1 
1 1 1
NAND Gate 
NAND 
X 
Y 
Z 
X Y Z 
0 0 1 
0 1 1 
1 0 1 
1 1 0 
Z = ~(X & Y) 
nand(Z,X,Y)
NAND Gate 
NOT-AND 
X 
Y 
Z 
W = X & Y 
Z = ~W = ~(X & Y) 
X Y W Z 
0 0 0 1 
0 1 0 1 
1 0 0 1 
1 1 1 0 
W
NOR Gate 
NOR 
X 
Y 
Z 
X Y Z 
0 0 1 
0 1 0 
1 0 0 
1 1 0 
Z = ~(X | Y) 
nor(Z,X,Y)
NOR Gate 
NOT-OR 
X 
Y 
W = X | Y 
Z = ~W = ~(X | Y) 
X Y W Z 
0 0 0 1 
0 1 1 0 
1 0 1 0 
1 1 1 0 
Z 
W
NAND Gate 
X 
Y 
X 
Y 
Z Z 
= 
Z = ~(X & Y) Z = ~X | ~Y 
X Y W Z 
0 0 0 1 
0 1 0 1 
1 0 0 1 
1 1 1 0 
X Y ~X ~Y Z 
0 0 1 1 1 
0 1 1 0 1 
1 0 0 1 1 
1 1 0 0 0
De Morgan’s Theorem-1 
~(X & Y) = ~X | ~Y 
• NOT all variables 
• Change & to | and | to & 
• NOT the result
NOR Gate 
X 
Y 
Z 
Z = ~(X | Y) 
X Y Z 
0 0 1 
0 1 0 
1 0 0 
1 1 0 
X 
Y 
Z 
Z = ~X & ~Y 
X Y ~X ~Y Z 
0 0 1 1 1 
0 1 1 0 0 
1 0 0 1 0 
1 1 0 0 0
De Morgan’s Theorem-2 
~(X | Y) = ~X & ~Y 
• NOT all variables 
• Change & to | and | to & 
• NOT the result
De Morgan’s Theorem 
• NOT all variables 
• Change & to | and | to & 
• NOT the result 
• -------------------------------------------- 
• ~X | ~Y = ~(~~X & ~~Y) = ~(X & Y) 
• ~(X & Y) = ~~(~X | ~Y) = ~X | ~Y 
• ~X & !Y = ~(~~X | ~~Y) = ~(X | Y) 
• ~(X | Y) = ~~(~X & ~Y) = ~X & ~Y
Exclusive-OR Gate 
X Y Z 
XOR 
X 
Y 
Z 0 0 0 
0 1 1 
1 0 1 
1 1 0 
Z = X ^ Y 
xor(Z,X,Y)
Exclusive-NOR Gate 
X Y Z 
XNOR 
X 
Y 
Z 0 0 1 
0 1 0 
1 0 0 
1 1 1 
Z = ~(X ^ Y) 
Z = X ~^ Y 
xnor(Z,X,Y)
Boolean Algebra 
• Boolean Algebra is a set of rules and theorems by 
which logical operations can be expressed 
mathematically.
Boolean Logic Operations 
• AND function 
Y=A.B 
• OR function 
Y=A+B 
• NOT function 
Y=Ᾱ
Arithmetic of Boolean Algebra 
• Boolean Addition | Boolean Multiplication 
0+0=0 | 0.0=0 
0+1=1 | 0.1=0 
1+0=1 | 1.0=0 
1+1=1 | 1.1=1 
|
Basic Laws 
1. Commutative Property 
A+B=B+A / A.B=B.A 
2. Associative Property 
(A+B)+C=A+(B+C) / (A.B).C=A.(B.C) 
3. Distributive Property 
A+BC=(A+B)(A+C) / A.(B+C)=A.B+A.C 
4. Absorption Property 
A+AB=A / A.(A+B)=A

More Related Content

What's hot

Ejerciciosderivadasresueltos
EjerciciosderivadasresueltosEjerciciosderivadasresueltos
Ejerciciosderivadasresueltos
bellidomates
 
Limites trigonometricos1
Limites trigonometricos1Limites trigonometricos1
Limites trigonometricos1
orvy
 
Bresenham's line algo.
Bresenham's line algo.Bresenham's line algo.
Bresenham's line algo.
Mohd Arif
 

What's hot (20)

the two phase method - operations research
the two phase method - operations researchthe two phase method - operations research
the two phase method - operations research
 
Simplex method
Simplex methodSimplex method
Simplex method
 
Operations Research - The Big M Method
Operations Research - The Big M MethodOperations Research - The Big M Method
Operations Research - The Big M Method
 
Operations Research - The Two Phase Method
Operations Research - The Two Phase MethodOperations Research - The Two Phase Method
Operations Research - The Two Phase Method
 
Bolum1cozumler
Bolum1cozumlerBolum1cozumler
Bolum1cozumler
 
Simplex Algorithm
Simplex AlgorithmSimplex Algorithm
Simplex Algorithm
 
5. Error Coding
5. Error Coding5. Error Coding
5. Error Coding
 
Two phase method lpp
Two phase method lppTwo phase method lpp
Two phase method lpp
 
Class10
Class10Class10
Class10
 
Circle algorithm
Circle algorithmCircle algorithm
Circle algorithm
 
Ejerciciosderivadasresueltos
EjerciciosderivadasresueltosEjerciciosderivadasresueltos
Ejerciciosderivadasresueltos
 
Operations Research - The Dual Simplex Method
Operations Research - The Dual Simplex MethodOperations Research - The Dual Simplex Method
Operations Research - The Dual Simplex Method
 
Ecuaciones cuadráticas completas
Ecuaciones cuadráticas completasEcuaciones cuadráticas completas
Ecuaciones cuadráticas completas
 
2007
20072007
2007
 
Operation research - the revised simplex method
Operation research - the revised simplex methodOperation research - the revised simplex method
Operation research - the revised simplex method
 
Limites trigonometricos1
Limites trigonometricos1Limites trigonometricos1
Limites trigonometricos1
 
Simplex Method Explained
Simplex Method ExplainedSimplex Method Explained
Simplex Method Explained
 
NUMERICAL METHODS
NUMERICAL METHODSNUMERICAL METHODS
NUMERICAL METHODS
 
Bresenham's line algorithm
Bresenham's line algorithmBresenham's line algorithm
Bresenham's line algorithm
 
Bresenham's line algo.
Bresenham's line algo.Bresenham's line algo.
Bresenham's line algo.
 

Similar to Digital electronics

Lecture4 binary-numbers-logic-operations
Lecture4  binary-numbers-logic-operationsLecture4  binary-numbers-logic-operations
Lecture4 binary-numbers-logic-operations
markme18
 

Similar to Digital electronics (20)

Lecture4 binary-numbers-logic-operations
Lecture4  binary-numbers-logic-operationsLecture4  binary-numbers-logic-operations
Lecture4 binary-numbers-logic-operations
 
Boolean alebra
Boolean alebraBoolean alebra
Boolean alebra
 
Bca 2nd sem-u-1.6 digital logic circuits, digital component
Bca 2nd sem-u-1.6 digital logic circuits, digital componentBca 2nd sem-u-1.6 digital logic circuits, digital component
Bca 2nd sem-u-1.6 digital logic circuits, digital component
 
digital logic circuits, digital component
 digital logic circuits, digital component digital logic circuits, digital component
digital logic circuits, digital component
 
UNIT-1_CSA.pdf
UNIT-1_CSA.pdfUNIT-1_CSA.pdf
UNIT-1_CSA.pdf
 
B.sc cs-ii-u-1.6 digital logic circuits, digital component
B.sc cs-ii-u-1.6 digital logic circuits, digital componentB.sc cs-ii-u-1.6 digital logic circuits, digital component
B.sc cs-ii-u-1.6 digital logic circuits, digital component
 
BasicLogicGates.ppt
BasicLogicGates.pptBasicLogicGates.ppt
BasicLogicGates.ppt
 
21EC201– Digital Principles and system design.pptx
21EC201– Digital Principles and system design.pptx21EC201– Digital Principles and system design.pptx
21EC201– Digital Principles and system design.pptx
 
B sc cs i bo-de u-ii logic gates
B sc cs i bo-de u-ii logic gatesB sc cs i bo-de u-ii logic gates
B sc cs i bo-de u-ii logic gates
 
Floating_point_representation.pdf
Floating_point_representation.pdfFloating_point_representation.pdf
Floating_point_representation.pdf
 
Number_Systems_and_Boolean_Algebra.ppt
Number_Systems_and_Boolean_Algebra.pptNumber_Systems_and_Boolean_Algebra.ppt
Number_Systems_and_Boolean_Algebra.ppt
 
Digital Electronics and Computer Language
Digital Electronics and Computer Language Digital Electronics and Computer Language
Digital Electronics and Computer Language
 
digitalelectronics.ppt
digitalelectronics.pptdigitalelectronics.ppt
digitalelectronics.ppt
 
Combinational logic 2
Combinational logic 2Combinational logic 2
Combinational logic 2
 
Unit-1 Digital Design and Binary Numbers:
Unit-1 Digital Design and Binary Numbers:Unit-1 Digital Design and Binary Numbers:
Unit-1 Digital Design and Binary Numbers:
 
number system.ppt
number system.pptnumber system.ppt
number system.ppt
 
Arithmatic &Logic Unit
Arithmatic &Logic UnitArithmatic &Logic Unit
Arithmatic &Logic Unit
 
Computer Architecture
Computer ArchitectureComputer Architecture
Computer Architecture
 
Computer Architecture
Computer ArchitectureComputer Architecture
Computer Architecture
 
ARITHMETIC FOR COMPUTERS
ARITHMETIC FOR COMPUTERS	  ARITHMETIC FOR COMPUTERS
ARITHMETIC FOR COMPUTERS
 

Recently uploaded

會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽
會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽
會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽
中 央社
 
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes GuàrdiaPersonalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
EADTU
 
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdfContoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdf
cupulin
 

Recently uploaded (20)

Sternal Fractures & Dislocations - EMGuidewire Radiology Reading Room
Sternal Fractures & Dislocations - EMGuidewire Radiology Reading RoomSternal Fractures & Dislocations - EMGuidewire Radiology Reading Room
Sternal Fractures & Dislocations - EMGuidewire Radiology Reading Room
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & Systems
 
Rich Dad Poor Dad ( PDFDrive.com )--.pdf
Rich Dad Poor Dad ( PDFDrive.com )--.pdfRich Dad Poor Dad ( PDFDrive.com )--.pdf
Rich Dad Poor Dad ( PDFDrive.com )--.pdf
 
Stl Algorithms in C++ jjjjjjjjjjjjjjjjjj
Stl Algorithms in C++ jjjjjjjjjjjjjjjjjjStl Algorithms in C++ jjjjjjjjjjjjjjjjjj
Stl Algorithms in C++ jjjjjjjjjjjjjjjjjj
 
8 Tips for Effective Working Capital Management
8 Tips for Effective Working Capital Management8 Tips for Effective Working Capital Management
8 Tips for Effective Working Capital Management
 
會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽
會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽
會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽會考英聽
 
An overview of the various scriptures in Hinduism
An overview of the various scriptures in HinduismAn overview of the various scriptures in Hinduism
An overview of the various scriptures in Hinduism
 
Mattingly "AI and Prompt Design: LLMs with NER"
Mattingly "AI and Prompt Design: LLMs with NER"Mattingly "AI and Prompt Design: LLMs with NER"
Mattingly "AI and Prompt Design: LLMs with NER"
 
Improved Approval Flow in Odoo 17 Studio App
Improved Approval Flow in Odoo 17 Studio AppImproved Approval Flow in Odoo 17 Studio App
Improved Approval Flow in Odoo 17 Studio App
 
ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH FORM 50 CÂU TRẮC NGHI...
ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH FORM 50 CÂU TRẮC NGHI...ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH FORM 50 CÂU TRẮC NGHI...
ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH FORM 50 CÂU TRẮC NGHI...
 
UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024
 
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
 
diagnosting testing bsc 2nd sem.pptx....
diagnosting testing bsc 2nd sem.pptx....diagnosting testing bsc 2nd sem.pptx....
diagnosting testing bsc 2nd sem.pptx....
 
e-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopale-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopal
 
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
 
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes GuàrdiaPersonalisation of Education by AI and Big Data - Lourdes Guàrdia
Personalisation of Education by AI and Big Data - Lourdes Guàrdia
 
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdfContoh Aksi Nyata Refleksi Diri ( NUR ).pdf
Contoh Aksi Nyata Refleksi Diri ( NUR ).pdf
 
How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17
 
Observing-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptxObserving-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptx
 
PSYPACT- Practicing Over State Lines May 2024.pptx
PSYPACT- Practicing Over State Lines May 2024.pptxPSYPACT- Practicing Over State Lines May 2024.pptx
PSYPACT- Practicing Over State Lines May 2024.pptx
 

Digital electronics

  • 1.
  • 3. Conversion Among Bases • The possibilities: Decimal Hexadecimal
  • 4. 2510 = 110012 = 318 = 1916
  • 5. Decimal to Decimal Decimal Octal Hexadecimal Binary
  • 6. N=푎푚푟푚−1 + 푎푚−1푟푚−2 + ….. +푎2푟1 + 푎1푟0.+ 푏1푟−1+푏2푟−2+ ……+ 푏푛푟−푛 r=10 (decimal)
  • 7. 12510 => 5 x 100 = 5 2 x 101 = 20 1 x 102 = 100 125 Base Weight
  • 8. Binary to Decimal Decimal Octal Hexadecimal Binary
  • 9. Binary to Decimal • Technique • Multiply each bit by 2n, where n is the “weight” of the bit • The weight is the position of the bit, starting from 0 on the right • Add the results
  • 10. Example 1010112 => (1 x 20)+(1 x 21)+(0 x 22)+(1 x 23)+(0 x 24) +(1 x 25) = 1+2+0+8+0+32 = 4310 Bit “0”
  • 11. Decimal to Binary Decimal Octal Hexadecimal Binary
  • 12. Decimal to Binary • Technique • Divide by two, keep track of the remainder • First remainder is bit 0 (LSB, least-significant bit) • Second remainder is bit 1 • Etc.
  • 13. Example 12510 = ?2 2 125 2 6 2 1 2 3 1 0 2 1 5 1 2 7 1 2 3 1 1 1 12510 = 11111012
  • 14. Example: (0.3125)10 0.3125 x 2=0.625 0 MSB 0.625 x 2=1.25 1 0.25 x 2=0.50 0 0.50 x 2=1.00 1 LSB Ans.:- (0101)2
  • 15. Binary Arithmetic: Binary Addition: • Two 1-bit values A B A + B 0 0 0 0 1 1 1 0 1 1 1 10 “two”
  • 16. Binary Addition • Two n-bit values • Add individual bits • Propagate carries • E.g., 1 1 10101 21 + 11001 + 25 101110 46
  • 17. Binary Subtraction Rules for binary subtraction are: 0 – 0 = 0 1 – 0 = 1 1 – 1 = 0 0 – 1 = 1 , with 1 borrowed from the next column Ex 1: 1100101 – 100111 Verify the result in decimal system. Solution: (10011)2 = 1*24 + 1*21 + 1*20 = (19)10
  • 18. Complements of Binary Numbers • 1’s complements • 2’s complements 18
  • 19. 1’s and 2’s Complement:  The 1’s complement of a binary number is simply obtained by replacing every 1 by 0 , and every 0 by 1.  The 2’s complement of a binary number can be obtained in two ways:  By adding 1 to the 1’s complement.  Start the binary number from right. Leave the binary digits unchanged until the first 1 appear, then replace every 1 by 0 , and every 0 by 1.
  • 20. Complements of Binary Numbers • 1’s complement • Change all 1s to 0s and all 0s to 1s 1 0 1 0 1 0 1 0 0 1 0 1 0 1 0 1
  • 21. Ex 1: Obtain the two’s complement of the binary number 1011010.110 First solution Second solution
  • 22. Ex 2: Calculate the following binary Subtraction: 1101.101 – 11011.11 , then verify the result in decimal System. Solution
  • 24. NOT Gate -- Inverter X Y 0 1 1 0 NOT X Y Y = ~X
  • 25. NOT X ~X ~~X = X X ~X ~~X 0 1 0 1 0 1
  • 26. AND Gate AND X Y Z Z = X & Y X Y Z 0 0 0 0 1 0 1 0 0 1 1 1
  • 27. OR Gate OR X Y Z Z = X | Y X Y Z 0 0 0 0 1 1 1 0 1 1 1 1
  • 28. NAND Gate NAND X Y Z X Y Z 0 0 1 0 1 1 1 0 1 1 1 0 Z = ~(X & Y) nand(Z,X,Y)
  • 29. NAND Gate NOT-AND X Y Z W = X & Y Z = ~W = ~(X & Y) X Y W Z 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 W
  • 30. NOR Gate NOR X Y Z X Y Z 0 0 1 0 1 0 1 0 0 1 1 0 Z = ~(X | Y) nor(Z,X,Y)
  • 31. NOR Gate NOT-OR X Y W = X | Y Z = ~W = ~(X | Y) X Y W Z 0 0 0 1 0 1 1 0 1 0 1 0 1 1 1 0 Z W
  • 32. NAND Gate X Y X Y Z Z = Z = ~(X & Y) Z = ~X | ~Y X Y W Z 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 X Y ~X ~Y Z 0 0 1 1 1 0 1 1 0 1 1 0 0 1 1 1 1 0 0 0
  • 33. De Morgan’s Theorem-1 ~(X & Y) = ~X | ~Y • NOT all variables • Change & to | and | to & • NOT the result
  • 34. NOR Gate X Y Z Z = ~(X | Y) X Y Z 0 0 1 0 1 0 1 0 0 1 1 0 X Y Z Z = ~X & ~Y X Y ~X ~Y Z 0 0 1 1 1 0 1 1 0 0 1 0 0 1 0 1 1 0 0 0
  • 35. De Morgan’s Theorem-2 ~(X | Y) = ~X & ~Y • NOT all variables • Change & to | and | to & • NOT the result
  • 36. De Morgan’s Theorem • NOT all variables • Change & to | and | to & • NOT the result • -------------------------------------------- • ~X | ~Y = ~(~~X & ~~Y) = ~(X & Y) • ~(X & Y) = ~~(~X | ~Y) = ~X | ~Y • ~X & !Y = ~(~~X | ~~Y) = ~(X | Y) • ~(X | Y) = ~~(~X & ~Y) = ~X & ~Y
  • 37. Exclusive-OR Gate X Y Z XOR X Y Z 0 0 0 0 1 1 1 0 1 1 1 0 Z = X ^ Y xor(Z,X,Y)
  • 38. Exclusive-NOR Gate X Y Z XNOR X Y Z 0 0 1 0 1 0 1 0 0 1 1 1 Z = ~(X ^ Y) Z = X ~^ Y xnor(Z,X,Y)
  • 39. Boolean Algebra • Boolean Algebra is a set of rules and theorems by which logical operations can be expressed mathematically.
  • 40. Boolean Logic Operations • AND function Y=A.B • OR function Y=A+B • NOT function Y=Ᾱ
  • 41. Arithmetic of Boolean Algebra • Boolean Addition | Boolean Multiplication 0+0=0 | 0.0=0 0+1=1 | 0.1=0 1+0=1 | 1.0=0 1+1=1 | 1.1=1 |
  • 42. Basic Laws 1. Commutative Property A+B=B+A / A.B=B.A 2. Associative Property (A+B)+C=A+(B+C) / (A.B).C=A.(B.C) 3. Distributive Property A+BC=(A+B)(A+C) / A.(B+C)=A.B+A.C 4. Absorption Property A+AB=A / A.(A+B)=A