SlideShare a Scribd company logo
2
Most read
9
Most read
17
Most read
BINARY ARITHMETICBinary arithmetic is essential in all digital computers and in many other types of digital systems.
Binary AdditionThe four basic rules for adding binary digits are as follows:		0 + 0 = 0 		Sum of 0 with a carry of 0	0 + 1 = 1		Sum of 1 with a carry of 01 + 0 = 1		Sum of 1 with a carry of 01 + 1 = 10		Sum of 0 with a carry of 1
Examples:Add the following binary numbers11 + 11100 + 10111 + 11110 + 100
Binary subtractionThe four basic rules for subtracting binary digits are as follows:		0 - 0 = 0 		1 - 1 = 0		1 - 0 = 1		      10 - 1 = 10 – 1 with a borrow of 1
ExamplesPerform the following binary subtractions:11 – 0111 – 10110100-11111
Binary MultiplicationThe four basic rules for multiplying binary digits are as follows:		0 x0 = 0 		0 x 1 = 0	1 x 0 = 0	1 x 1 = 1
ExamplesPerform the following binary multiplications:11 x 11101 x 1111001 x 1011
1’s and 2’s complements of binary numbers	The 1’s complement and the 2’s complement of a binary number are important because they permit the representation of negative numbers. The method of 2’s complement arithmetic is commonly used in computers to handle negative numbers.
Obtaining the 1’s complement of a binary number	The 1’s complement of a binary number is found by simply changing all 1s to 0s and all 0s to 1s.Example:0	1	1	1	0	0	1	0   Binary Number	1	0	0	0	1	1	0	1    1’s Complement
Obtaining the 2’s complement of a binary numberThe 2’s complement of a binary number is found by adding 1 to LSB of the 1’s complement.		2’s complement = (1’s complement) + 101110010   	Binary Number 10001101    1’s Complement+                1      add 1    10001110 	2’s Complement
Signed numbersDigital systems, such as the computer must be able to handle both positive and negative numbers. A signed binary number consists of both sign and magnitude information. The sign indicates whether a number is positive or negative and the magnitude is the value of a number. There are three ways in which signed numbers can be represented in binary form: sign-magnitude, 1’s complement, and 2’s complement.
The sign bitThe left most bit in signed binary number is the sign bit, which tell you whether the number is positive or negative. A 0 is for positive, and 1 is for negativeSign - magnitude systemWhen a signed binary number is represented in sign-magnitude, the left most bit is the sign bit and the remaining bits are the magnitude bits.Example	Express the following decimal numbers as an 8-bit number in sign magnitude, 1’s complement and 2’s complement:-39-25-78-55
Arithmetic operations with signed numbersAddition	The two numbers in addition are the addend and the augend. The result is the sum. There are four cases that occur when two signed binary numbers are added.Both numbers are positive Positive number with magnitude larger than negative numbersNegative number with magnitude larger than positive numbersBoth numbers are negative
Examples:	Both numbers are positive  7 + 4 	Positive number with magnitude larger than negative numbers		15 + -6	Negative number with magnitude larger than positive numbers		16 + - 24	Both numbers are negative		-5 + -9
	Perform each of the following subtractions of the signed numbers:	1. 8 – 32. 12 – (-9)3. -25 – (+19)4. -120 – (-30)
divisionWhen two numbers are divided, both numbers must be in true (uncomplemented) form. The basic steps in a division process are as follows:Step 1. 	Determine if the signs of the dividend and divisor are the same or different. 	This determines what the sign of the quotient will be. Initialize the quotient 	to zero.Step 2. 	Subtract the divisor from the dividend using 2’s complement addition to get 	the first partial remainder and add 1 to the quotient. If the partial 	remainder is positive go to step 3. If the partial remainder is zero or 	negative, the division is complete.Step 3. 	Subtract the divisor from the partial remainder and add 1 to the quotient. If 	the result is positive, repeat for the next remainder. If  the result is 	zero or 	negative, the division is complete.Continue to subtract the divisor from the dividend and the partial remainder until there is a zero or negative result.Example: Divide 01100100 by 00011001.
Binary arithmetic

More Related Content

PPTX
Binary Arithmetic
PPTX
Binary true ppt
PPTX
Binary addition.pptx
PPTX
Binary Multiplication & Division.pptx
PDF
Binary codes
PPT
Binary Arithmetic
PPTX
PPTX
Binary Arithmetic
Binary true ppt
Binary addition.pptx
Binary Multiplication & Division.pptx
Binary codes
Binary Arithmetic

What's hot (20)

PDF
Binaty Arithmetic and Binary coding schemes
PDF
Binary Arithmetic Operations
PDF
Floating point presentation
PPTX
Number system
PPTX
Multiplication algorithm
PPT
digital logic design number system
PPTX
Number system in Digital Electronics
PPSX
Fixed point and floating-point numbers
PPTX
1's and 2's complement
PPTX
IEEE floating point representation
PPTX
3.codes( binary code ,excess 3, gray code )
PPTX
Quick tutorial on IEEE 754 FLOATING POINT representation
PDF
Lecture-2(2): Number System & Conversion
PPTX
Data representation
PPT
Digital Logic Design
PPTX
Number System
PDF
Slide03 Number System and Operations Part 1
PPT
Booths Multiplication Algorithm
PDF
Binary codes
PPTX
Booths algorithm for Multiplication
Binaty Arithmetic and Binary coding schemes
Binary Arithmetic Operations
Floating point presentation
Number system
Multiplication algorithm
digital logic design number system
Number system in Digital Electronics
Fixed point and floating-point numbers
1's and 2's complement
IEEE floating point representation
3.codes( binary code ,excess 3, gray code )
Quick tutorial on IEEE 754 FLOATING POINT representation
Lecture-2(2): Number System & Conversion
Data representation
Digital Logic Design
Number System
Slide03 Number System and Operations Part 1
Booths Multiplication Algorithm
Binary codes
Booths algorithm for Multiplication
Ad

Similar to Binary arithmetic (20)

PPT
Number Systems.ppt
PPT
binary arithmetic rules
PDF
Chapter 2_Number system (EEEg4302).pdf
PPT
Digital fundamendals r001a
PPTX
L3 ARITHMETIC OPERATIONS.pptx
PPTX
Binary Arithmetic that is used in Computer Programming.pptx
PPT
Lecture 06 computer arithmatic
PDF
unit-2_DL.pdf
PPT
lec2_BinaryArithmetic.ppt
PDF
Digital logic design of 2nd Lecture 2.pdf
PPT
Digital logic design lecture 02
PPTX
Computer Architecture
PPTX
Computer Architecture
PPTX
Computer Arithmetic and Binary Math.pptx
PPTX
Computer Architecture Binary Arithmetic Lecture.pptx
PDF
IN 1300 LEC_D02(B15) Basic electronic 2.pdf
PPTX
Parallel adders
PPT
Chapter 2 Number Systems, Operations, and Codes
PPTX
Number system
PPTX
ARITHMETIC FOR COMPUTERS
Number Systems.ppt
binary arithmetic rules
Chapter 2_Number system (EEEg4302).pdf
Digital fundamendals r001a
L3 ARITHMETIC OPERATIONS.pptx
Binary Arithmetic that is used in Computer Programming.pptx
Lecture 06 computer arithmatic
unit-2_DL.pdf
lec2_BinaryArithmetic.ppt
Digital logic design of 2nd Lecture 2.pdf
Digital logic design lecture 02
Computer Architecture
Computer Architecture
Computer Arithmetic and Binary Math.pptx
Computer Architecture Binary Arithmetic Lecture.pptx
IN 1300 LEC_D02(B15) Basic electronic 2.pdf
Parallel adders
Chapter 2 Number Systems, Operations, and Codes
Number system
ARITHMETIC FOR COMPUTERS
Ad

More from Elizabeth de Leon Aler (9)

PPT
Excel07 l1 ch1
PPT
Application software
PPTX
Algorithm and flowchart
PPT
Access07 l1 ch2
PPT
Access07 l1 ch1

Recently uploaded (20)

PDF
Machine learning based COVID-19 study performance prediction
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Encapsulation theory and applications.pdf
PPTX
MYSQL Presentation for SQL database connectivity
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
Spectroscopy.pptx food analysis technology
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Network Security Unit 5.pdf for BCA BBA.
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
DOCX
The AUB Centre for AI in Media Proposal.docx
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Spectral efficient network and resource selection model in 5G networks
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Electronic commerce courselecture one. Pdf
PPTX
sap open course for s4hana steps from ECC to s4
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Machine learning based COVID-19 study performance prediction
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Encapsulation theory and applications.pdf
MYSQL Presentation for SQL database connectivity
Understanding_Digital_Forensics_Presentation.pptx
20250228 LYD VKU AI Blended-Learning.pptx
Digital-Transformation-Roadmap-for-Companies.pptx
Spectroscopy.pptx food analysis technology
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Network Security Unit 5.pdf for BCA BBA.
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
The AUB Centre for AI in Media Proposal.docx
Building Integrated photovoltaic BIPV_UPV.pdf
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Spectral efficient network and resource selection model in 5G networks
“AI and Expert System Decision Support & Business Intelligence Systems”
Mobile App Security Testing_ A Comprehensive Guide.pdf
Electronic commerce courselecture one. Pdf
sap open course for s4hana steps from ECC to s4
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...

Binary arithmetic

  • 1. BINARY ARITHMETICBinary arithmetic is essential in all digital computers and in many other types of digital systems.
  • 2. Binary AdditionThe four basic rules for adding binary digits are as follows: 0 + 0 = 0 Sum of 0 with a carry of 0 0 + 1 = 1 Sum of 1 with a carry of 01 + 0 = 1 Sum of 1 with a carry of 01 + 1 = 10 Sum of 0 with a carry of 1
  • 3. Examples:Add the following binary numbers11 + 11100 + 10111 + 11110 + 100
  • 4. Binary subtractionThe four basic rules for subtracting binary digits are as follows: 0 - 0 = 0 1 - 1 = 0 1 - 0 = 1 10 - 1 = 10 – 1 with a borrow of 1
  • 5. ExamplesPerform the following binary subtractions:11 – 0111 – 10110100-11111
  • 6. Binary MultiplicationThe four basic rules for multiplying binary digits are as follows: 0 x0 = 0 0 x 1 = 0 1 x 0 = 0 1 x 1 = 1
  • 7. ExamplesPerform the following binary multiplications:11 x 11101 x 1111001 x 1011
  • 8. 1’s and 2’s complements of binary numbers The 1’s complement and the 2’s complement of a binary number are important because they permit the representation of negative numbers. The method of 2’s complement arithmetic is commonly used in computers to handle negative numbers.
  • 9. Obtaining the 1’s complement of a binary number The 1’s complement of a binary number is found by simply changing all 1s to 0s and all 0s to 1s.Example:0 1 1 1 0 0 1 0 Binary Number 1 0 0 0 1 1 0 1 1’s Complement
  • 10. Obtaining the 2’s complement of a binary numberThe 2’s complement of a binary number is found by adding 1 to LSB of the 1’s complement. 2’s complement = (1’s complement) + 101110010 Binary Number 10001101 1’s Complement+ 1 add 1 10001110 2’s Complement
  • 11. Signed numbersDigital systems, such as the computer must be able to handle both positive and negative numbers. A signed binary number consists of both sign and magnitude information. The sign indicates whether a number is positive or negative and the magnitude is the value of a number. There are three ways in which signed numbers can be represented in binary form: sign-magnitude, 1’s complement, and 2’s complement.
  • 12. The sign bitThe left most bit in signed binary number is the sign bit, which tell you whether the number is positive or negative. A 0 is for positive, and 1 is for negativeSign - magnitude systemWhen a signed binary number is represented in sign-magnitude, the left most bit is the sign bit and the remaining bits are the magnitude bits.Example Express the following decimal numbers as an 8-bit number in sign magnitude, 1’s complement and 2’s complement:-39-25-78-55
  • 13. Arithmetic operations with signed numbersAddition The two numbers in addition are the addend and the augend. The result is the sum. There are four cases that occur when two signed binary numbers are added.Both numbers are positive Positive number with magnitude larger than negative numbersNegative number with magnitude larger than positive numbersBoth numbers are negative
  • 14. Examples: Both numbers are positive 7 + 4 Positive number with magnitude larger than negative numbers 15 + -6 Negative number with magnitude larger than positive numbers 16 + - 24 Both numbers are negative -5 + -9
  • 15. Perform each of the following subtractions of the signed numbers: 1. 8 – 32. 12 – (-9)3. -25 – (+19)4. -120 – (-30)
  • 16. divisionWhen two numbers are divided, both numbers must be in true (uncomplemented) form. The basic steps in a division process are as follows:Step 1. Determine if the signs of the dividend and divisor are the same or different. This determines what the sign of the quotient will be. Initialize the quotient to zero.Step 2. Subtract the divisor from the dividend using 2’s complement addition to get the first partial remainder and add 1 to the quotient. If the partial remainder is positive go to step 3. If the partial remainder is zero or negative, the division is complete.Step 3. Subtract the divisor from the partial remainder and add 1 to the quotient. If the result is positive, repeat for the next remainder. If the result is zero or negative, the division is complete.Continue to subtract the divisor from the dividend and the partial remainder until there is a zero or negative result.Example: Divide 01100100 by 00011001.