This document provides an overview of Boolean algebra and logic gates. It discusses topics such as number systems, binary codes, Boolean algebra, logic gates, theorems of Boolean algebra, Boolean functions, simplification using Karnaugh maps, and NAND and NOR implementations. The document also describes binary arithmetic operations including addition, subtraction, multiplication, and division. It defines binary codes and discusses weighted and non-weighted binary codes.
This document provides an overview of Boolean algebra and logic gates. It discusses topics such as number systems, binary codes, Boolean algebra, logic gates, theorems of Boolean algebra, Boolean functions, simplification using Karnaugh maps, and NAND and NOR implementations. The document also describes binary arithmetic operations including addition, subtraction, multiplication, and division. It defines binary codes and discusses weighted and non-weighted binary codes.
The document provides information about computer arithmetic and binary number representation. It discusses addition and subtraction in binary, signed and unsigned numbers, overflow, and multiplication algorithms. It explains how binary addition and subtraction work using bit-by-bit operations. For multiplication, it describes the shift-add algorithm where the multiplicand is shifted and added to the product based on the multiplier bits. Hardware for implementing this algorithm with registers is also shown.
The document provides information about computer arithmetic and binary number representation. It discusses addition and subtraction in binary, signed and unsigned numbers, overflow, and multiplication algorithms. It explains how binary addition and subtraction work using bit-by-bit operations. For multiplication, it describes the shift-add algorithm where the multiplicand is shifted and added to the product based on the multiplier bits. Hardware for implementing this algorithm with registers is also shown.
1) The ALU performs arithmetic operations like addition, subtraction, multiplication and division on fixed point and floating point numbers. Fixed point uses integers while floating point uses a sign, mantissa, and exponent.
2) Binary numbers are added using half adders and full adders which are logic circuits that implement addition using truth tables and K-maps. Subtraction is done using 1's or 2's complement representations.
3) Multiplication is done using sequential or Booth's algorithm approaches while division uses restoring or non-restoring algorithms. Floating point uses similar addition and subtraction steps but first normalizes the exponents.
The document discusses binary number representation and arithmetic. It explains decimal to binary conversion. It also describes signed number representation using sign-magnitude and one's complement and two's complement methods. The key advantages of two's complement are that addition can be performed using the same method for positive and negative numbers. Subtraction using two's complement is performed by adding the number to the complement of the subtrahend. Examples of binary addition and subtraction are provided to illustrate these concepts.
UNIT-II ARITHMETIC FOR COMPUTERS
Addition and Subtraction Multiplication Division Floating Point Representation Floating Point Addition and Subtraction.
This document discusses decimal arithmetic operations using binary coded decimal (BCD) numbers. It describes how decimal numbers are represented in BCD format and processed using microoperations in the arithmetic logic unit (ALU). Addition and subtraction of decimal numbers are performed by converting the numbers to BCD, performing binary addition or subtraction on the digits, and converting the output back to decimal if needed. Block diagrams of BCD adders and examples of decimal addition and subtraction are provided.
This document discusses data representation and number systems in computers. It covers binary, octal, decimal, and hexadecimal number systems. Key points include:
- Data in computers is represented using binary numbers and different number systems allow for more efficient representations.
- Converting between number systems like binary, octal, decimal, and hexadecimal is explained through examples of dividing numbers and grouping bits.
- Signed numbers can be represented using complement representations like one's complement and two's complement, with subtraction implemented through addition of complements. Fast methods for calculating two's complement are described.
Digital electronics is the study of electronic circuits that are used to process and control digital signals. In contrast to analog electronics, where information is represented by a continuously varying voltage, digital signals are represented by two discrete voltages or logic levels
This document discusses digital electronics topics including number systems, codes, Boolean algebra, and digital circuits. It provides examples and explanations of converting between decimal, binary, octal, and hexadecimal number systems. Binary coded decimal, gray code, and excess-3 code are also defined. Combinational and sequential digital circuits as well as memory devices are listed as topics to be covered.
Inductive programming incorporates all approaches which are concerned with learning programs or algorithms from incomplete (formal) specifications. Possible inputs in an IP system are a set of training inputs and corresponding outputs or an output evaluation function, describing the desired behavior of the intended program, traces or action sequences which describe the process of calculating specific outputs, constraints for the program to be induced concerning its time efficiency or its complexity, various kinds of background knowledge such as standard data types, predefined functions to be used, program schemes or templates describing the data flow of the intended program, heuristics for guiding the search for a solution or other biases.
Output of an IP system is a program in some arbitrary programming language containing conditionals and loop or recursive control structures, or any other kind of Turing-complete representation language.
In many applications the output program must be correct with respect to the examples and partial specification, and this leads to the consideration of inductive programming as a special area inside automatic programming or program synthesis, usually opposed to 'deductive' program synthesis, where the specification is usually complete.
In other cases, inductive programming is seen as a more general area where any declarative programming or representation language can be used and we may even have some degree of error in the examples, as in general machine learning, the more specific area of structure mining or the area of symbolic artificial intelligence. A distinctive feature is the number of examples or partial specification needed. Typically, inductive programming techniques can learn from just a few examples.
The diversity of inductive programming usually comes from the applications and the languages that are used: apart from logic programming and functional programming, other programming paradigms and representation languages have been used or suggested in inductive programming, such as functional logic programming, constraint
programming, probabilistic programming
Research on the inductive synthesis of recursive functional programs started in the early 1970s and was brought onto firm theoretical foundations with the seminal THESIS system of Summers[6] and work of Biermann.[7] These approaches were split into two phases: first, input-output examples are transformed into non-recursive programs (traces) using a small set of basic operators; second, regularities in the traces are searched for and used to fold them into a recursive program. The main results until the mid 1980s are surveyed by Smith.[8] Due to
This document discusses number systems and binary arithmetic. It covers decimal, binary, octal and hexadecimal number systems. For binary, it explains how to convert between decimal and binary, and discusses binary addition, subtraction, and complement representations. The key advantages of using two's complement for binary numbers are that addition and subtraction can both be performed using the same hardware circuitry.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
Reviewing number systems involves understanding various ways in which numbers can be represented and manipulated. Here's a brief overview of different number systems:
Decimal System (Base-10):
This is the most common number system used by humans.
It uses 10 digits (0-9) to represent numbers.
Each digit's position represents a power of 10.
For example, the number 245 in decimal represents (2 * 10^2) + (4 * 10^1) + (5 * 10^0).
Binary System (Base-2):
Used internally by almost all modern computers.
It uses only two digits: 0 and 1.
Each digit's position represents a power of 2.
For example, the binary number 1011 represents (1 * 2^3) + (0 * 2^2) + (1 * 2^1) + (1 * 2^0) in decimal, which equals 11.
Octal System (Base-8):
Less commonly used, but still relevant in some computer programming contexts.
It uses eight digits: 0 to 7.
Each digit's position represents a power of 8.
For example, the octal number 34 represents (3 * 8^1) + (4 * 8^0) in decimal, which equals 28.
Hexadecimal System (Base-16):
Widely used in computer science and programming.
It uses sixteen digits: 0 to 9 followed by A to F (representing 10 to 15).
Each digit's position represents a power of 16.
Often used to represent memory addresses and binary data more compactly.
For example, the hexadecimal number 2F represents (2 * 16^1) + (15 * 16^0) in decimal, which equals 47.
Each number system has its own advantages and applications. Decimal is intuitive for human comprehension, binary is fundamental in computing due to its simplicity for electronic systems, octal and hexadecimal are often used for human-readable representations of binary data in programming, particularly when dealing with memory addresses and byte-oriented data.
Understanding these number systems is essential for various fields such as computer science, electrical engineering, and mathematics, as they provide different perspectives on how numbers can be represented and manipulated.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
Binary addition, Binary subtraction, Negative number representation, Subtraction using 1s complement and 2s complement, Binary multiplication and division, Arithmetic in octal, hexadecimal number system, BCD and Excess 3 arithmetic
The document discusses various methods for representing signed integers in binary, including signed magnitude, 1's complement, 2's complement, and excess binary. It provides examples of adding, subtracting, and multiplying numbers in binary using these different representations. 2's complement is described as the most common method used today due to its simplicity. The key aspects of 2's complement include representing negative numbers by flipping all bits and adding 1, and performing subtraction by adding the 2's complement. Overflow conditions for addition are also explained.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
The document discusses number representation in computers. It begins by introducing different number systems like decimal, binary, and hexadecimal. It then discusses how numeric data is stored in memory, including how integers, floats, characters and strings are represented. It also covers binary operations like addition, subtraction, multiplication and division. Finally, it discusses signed number representation using sign-magnitude, one's complement and two's complement methods.
Were excited to share our product profile, showcasing our expertise in Industrial Valves, Instrumentation, and Hydraulic & Pneumatic Solutions.
We also supply API-approved valves from globally trusted brands, ensuring top-notch quality and internationally certified solutions. Lets explore valuable business opportunities together!
We specialize in:
Industrial Valves (Gate, Globe, Ball, Butterfly, Check)
Instrumentation (Pressure Gauges, Transmitters, Flow Meters)
Pneumatic Products (Cylinders, Solenoid Valves, Fittings)
As authorized partners of trusted global brands, we deliver high-quality solutions tailored to meet your industrial needs with seamless support.
UNIT-II ARITHMETIC FOR COMPUTERS
Addition and Subtraction Multiplication Division Floating Point Representation Floating Point Addition and Subtraction.
This document discusses decimal arithmetic operations using binary coded decimal (BCD) numbers. It describes how decimal numbers are represented in BCD format and processed using microoperations in the arithmetic logic unit (ALU). Addition and subtraction of decimal numbers are performed by converting the numbers to BCD, performing binary addition or subtraction on the digits, and converting the output back to decimal if needed. Block diagrams of BCD adders and examples of decimal addition and subtraction are provided.
This document discusses data representation and number systems in computers. It covers binary, octal, decimal, and hexadecimal number systems. Key points include:
- Data in computers is represented using binary numbers and different number systems allow for more efficient representations.
- Converting between number systems like binary, octal, decimal, and hexadecimal is explained through examples of dividing numbers and grouping bits.
- Signed numbers can be represented using complement representations like one's complement and two's complement, with subtraction implemented through addition of complements. Fast methods for calculating two's complement are described.
Digital electronics is the study of electronic circuits that are used to process and control digital signals. In contrast to analog electronics, where information is represented by a continuously varying voltage, digital signals are represented by two discrete voltages or logic levels
This document discusses digital electronics topics including number systems, codes, Boolean algebra, and digital circuits. It provides examples and explanations of converting between decimal, binary, octal, and hexadecimal number systems. Binary coded decimal, gray code, and excess-3 code are also defined. Combinational and sequential digital circuits as well as memory devices are listed as topics to be covered.
Inductive programming incorporates all approaches which are concerned with learning programs or algorithms from incomplete (formal) specifications. Possible inputs in an IP system are a set of training inputs and corresponding outputs or an output evaluation function, describing the desired behavior of the intended program, traces or action sequences which describe the process of calculating specific outputs, constraints for the program to be induced concerning its time efficiency or its complexity, various kinds of background knowledge such as standard data types, predefined functions to be used, program schemes or templates describing the data flow of the intended program, heuristics for guiding the search for a solution or other biases.
Output of an IP system is a program in some arbitrary programming language containing conditionals and loop or recursive control structures, or any other kind of Turing-complete representation language.
In many applications the output program must be correct with respect to the examples and partial specification, and this leads to the consideration of inductive programming as a special area inside automatic programming or program synthesis, usually opposed to 'deductive' program synthesis, where the specification is usually complete.
In other cases, inductive programming is seen as a more general area where any declarative programming or representation language can be used and we may even have some degree of error in the examples, as in general machine learning, the more specific area of structure mining or the area of symbolic artificial intelligence. A distinctive feature is the number of examples or partial specification needed. Typically, inductive programming techniques can learn from just a few examples.
The diversity of inductive programming usually comes from the applications and the languages that are used: apart from logic programming and functional programming, other programming paradigms and representation languages have been used or suggested in inductive programming, such as functional logic programming, constraint
programming, probabilistic programming
Research on the inductive synthesis of recursive functional programs started in the early 1970s and was brought onto firm theoretical foundations with the seminal THESIS system of Summers[6] and work of Biermann.[7] These approaches were split into two phases: first, input-output examples are transformed into non-recursive programs (traces) using a small set of basic operators; second, regularities in the traces are searched for and used to fold them into a recursive program. The main results until the mid 1980s are surveyed by Smith.[8] Due to
This document discusses number systems and binary arithmetic. It covers decimal, binary, octal and hexadecimal number systems. For binary, it explains how to convert between decimal and binary, and discusses binary addition, subtraction, and complement representations. The key advantages of using two's complement for binary numbers are that addition and subtraction can both be performed using the same hardware circuitry.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
Reviewing number systems involves understanding various ways in which numbers can be represented and manipulated. Here's a brief overview of different number systems:
Decimal System (Base-10):
This is the most common number system used by humans.
It uses 10 digits (0-9) to represent numbers.
Each digit's position represents a power of 10.
For example, the number 245 in decimal represents (2 * 10^2) + (4 * 10^1) + (5 * 10^0).
Binary System (Base-2):
Used internally by almost all modern computers.
It uses only two digits: 0 and 1.
Each digit's position represents a power of 2.
For example, the binary number 1011 represents (1 * 2^3) + (0 * 2^2) + (1 * 2^1) + (1 * 2^0) in decimal, which equals 11.
Octal System (Base-8):
Less commonly used, but still relevant in some computer programming contexts.
It uses eight digits: 0 to 7.
Each digit's position represents a power of 8.
For example, the octal number 34 represents (3 * 8^1) + (4 * 8^0) in decimal, which equals 28.
Hexadecimal System (Base-16):
Widely used in computer science and programming.
It uses sixteen digits: 0 to 9 followed by A to F (representing 10 to 15).
Each digit's position represents a power of 16.
Often used to represent memory addresses and binary data more compactly.
For example, the hexadecimal number 2F represents (2 * 16^1) + (15 * 16^0) in decimal, which equals 47.
Each number system has its own advantages and applications. Decimal is intuitive for human comprehension, binary is fundamental in computing due to its simplicity for electronic systems, octal and hexadecimal are often used for human-readable representations of binary data in programming, particularly when dealing with memory addresses and byte-oriented data.
Understanding these number systems is essential for various fields such as computer science, electrical engineering, and mathematics, as they provide different perspectives on how numbers can be represented and manipulated.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
Binary addition, Binary subtraction, Negative number representation, Subtraction using 1s complement and 2s complement, Binary multiplication and division, Arithmetic in octal, hexadecimal number system, BCD and Excess 3 arithmetic
The document discusses various methods for representing signed integers in binary, including signed magnitude, 1's complement, 2's complement, and excess binary. It provides examples of adding, subtracting, and multiplying numbers in binary using these different representations. 2's complement is described as the most common method used today due to its simplicity. The key aspects of 2's complement include representing negative numbers by flipping all bits and adding 1, and performing subtraction by adding the 2's complement. Overflow conditions for addition are also explained.
The document discusses different number systems including binary, decimal, and hexadecimal. It defines base-N number systems and provides examples of decimal, binary, and hexadecimal numbers. Key concepts covered include positional notation, bits and bytes, addition and subtraction in different bases, signed numbers represented using sign-magnitude and two's complement, and arithmetic operations like addition and subtraction on signed binary numbers. Sign extension is introduced as an important concept for performing arithmetic on numbers of different bit-widths in a signed system.
The document discusses number representation in computers. It begins by introducing different number systems like decimal, binary, and hexadecimal. It then discusses how numeric data is stored in memory, including how integers, floats, characters and strings are represented. It also covers binary operations like addition, subtraction, multiplication and division. Finally, it discusses signed number representation using sign-magnitude, one's complement and two's complement methods.
Were excited to share our product profile, showcasing our expertise in Industrial Valves, Instrumentation, and Hydraulic & Pneumatic Solutions.
We also supply API-approved valves from globally trusted brands, ensuring top-notch quality and internationally certified solutions. Lets explore valuable business opportunities together!
We specialize in:
Industrial Valves (Gate, Globe, Ball, Butterfly, Check)
Instrumentation (Pressure Gauges, Transmitters, Flow Meters)
Pneumatic Products (Cylinders, Solenoid Valves, Fittings)
As authorized partners of trusted global brands, we deliver high-quality solutions tailored to meet your industrial needs with seamless support.
How to Build a Maze Solving Robot Using ArduinoCircuitDigest
油
Learn how to make an Arduino-powered robot that can navigate mazes on its own using IR sensors and "Hand on the wall" algorithm.
This step-by-step guide will show you how to build your own maze-solving robot using Arduino UNO, three IR sensors, and basic components that you can easily find in your local electronics shop.
Engineering at Lovely Professional University (LPU).pdfSona
油
LPUs engineering programs provide students with the skills and knowledge to excel in the rapidly evolving tech industry, ensuring a bright and successful future. With world-class infrastructure, top-tier placements, and global exposure, LPU stands as a premier destination for aspiring engineers.
Optimization of Cumulative Energy, Exergy Consumption and Environmental Life ...J. Agricultural Machinery
油
Optimal use of resources, including energy, is one of the most important principles in modern and sustainable agricultural systems. Exergy analysis and life cycle assessment were used to study the efficient use of inputs, energy consumption reduction, and various environmental effects in the corn production system in Lorestan province, Iran. The required data were collected from farmers in Lorestan province using random sampling. The Cobb-Douglas equation and data envelopment analysis were utilized for modeling and optimizing cumulative energy and exergy consumption (CEnC and CExC) and devising strategies to mitigate the environmental impacts of corn production. The Cobb-Douglas equation results revealed that electricity, diesel fuel, and N-fertilizer were the major contributors to CExC in the corn production system. According to the Data Envelopment Analysis (DEA) results, the average efficiency of all farms in terms of CExC was 94.7% in the CCR model and 97.8% in the BCC model. Furthermore, the results indicated that there was excessive consumption of inputs, particularly potassium and phosphate fertilizers. By adopting more suitable methods based on DEA of efficient farmers, it was possible to save 6.47, 10.42, 7.40, 13.32, 31.29, 3.25, and 6.78% in the exergy consumption of diesel fuel, electricity, machinery, chemical fertilizers, biocides, seeds, and irrigation, respectively.
This PPT covers the index and engineering properties of soil. It includes details on index properties, along with their methods of determination. Various important terms related to soil behavior are explained in detail. The presentation also outlines the experimental procedures for determining soil properties such as water content, specific gravity, plastic limit, and liquid limit, along with the necessary calculations and graph plotting. Additionally, it provides insights to understand the importance of these properties in geotechnical engineering applications.
Integration of Additive Manufacturing (AM) with IoT : A Smart Manufacturing A...ASHISHDESAI85
油
Combining 3D printing with Internet of Things (IoT) enables the creation of smart, connected, and customizable objects that can monitor, control, and optimize their performance, potentially revolutionizing various industries. oT-enabled 3D printers can use sensors to monitor the quality of prints during the printing process. If any defects or deviations from the desired specifications are detected, the printer can adjust its parameters in real time to ensure that the final product meets the required standards.
18. How to find 1s Complement of given
number
1s complement of a number is found by changing
all 1s to 0s and all 0s to 1s.
Ex: 1s complement of a number 10111 is = 01000
Solve---- Find 1s complement of
a. 11010 = 00101
b. 101101= 010010
c. 1010= 0101
d. 1111=0000
e. 1011001=0100110
19. How to find 2s Complement of given number
The 2s complement of a number is obtained by adding
1 to the LSB of 1s complement of that number
2s complement = 1s complement + 1
Ex: obtain 2s complement of a number (10110010)2
Solution:
20. Solve
Find 2s complement of following numbers.
a. (1101)2 0010=1=0011
b. (10111)2 01000+1=01001
c. (101101)2 010010+1=010011
d. (1011111)2 010000+1=010001
e. (101111101)2 010000010+1=010000011
21. Subtraction using 1s
complement
A) For subtracting a smaller number from a larger
number, the 1s
complement method is as follows:
1. Determine the 1s
complement of the smaller number.
2. Add the 1s
complement to the larger number.
3. Remove the final carry and add it to the result. This is
called the end-around carry.
22. Binary subtraction using 1s complement
method
To perform subtraction (A)2 - (B)2
Step 1: convert number to be subtracted (B)2 to its 1s complement.
Step 2: Add first number (A)2 and 1s complement of (B)2 using rules
of binary addition.
Step 3: if final carry is 1 then add it to the result of addition obtained
in step 2 to get final result.
**If final carry in step 2 is 1 then result obtained in step 2 is Positive
and in its true form no conversion required.
Step 4: if final carry in step 2 is 0 then result obtained in step 2 is
negative and in 1s complement form. So convert it to its true form.
23. Binary subtraction using 1s complement
10---------------------------------- 10
-3 - 11-----1complement of 11 +00
--- -----
-1 10 result
1s complement of result 01 final
result
carry 0 so result sign is negative
0
25. Binary subtraction using 1s complement
9 1001 1001
- 15 1111 1s complement +0000
------- -------
-6 1001
1s complement of result 0110 ---6
carry is 0 so result sign is negative
0
26. Binary Subtraction Questions Using 1s Complement
Question 1:
(110101)2 (100101)2
Solution:
(1 1 0 1 0 1)2 = 5310------- minuend.
(1 0 0 1 0 1)2 = 3710 subtrahend
Now take the 1s complement of the subtrahend and add with minuend.
1 carry
1 1 0 1 0 1
(+) 0 1 1 0 1 0
0 0 1 1 1 1
+ 1 carry
0 1 0 0 0 0
Therefore, the solution is 010000
(010000)2 = 1610
1
27. Binary Subtraction Questions Using 1s
Complement
Question 2:
(101011)2 (111001)2 43-57= -14
Solution:
Take 1s complement of the subtrahend
1 1 1
1 0 1 0 1 1
(+) 0 0 0 1 1 0 (1s complement)
1 1 0 0 0 1
Now take the 1s complement of the resultant since it does not carry 1
The resultant becomes 0 0 1 1 1 0
Now, add the negative sign to the resultant value
Therefore the solution is (001110)2.
28. Binary subtraction using 2s complement
method
To perform subtraction (A)2 - (B)2
Step 1: convert number to be subtracted (B)2 to its 2s complement.
Step 2: Add first number (A)2 and 2s complement of (B)2 using rules
of binary addition.
Step 3: if final carry is 1 then the result Positive and in its true form
no conversion required.
Step 4: if final carry in step 2 is 0 then result obtained in step 2 is
negative and in 2s complement form. So convert it to its true form.
** Carry always be discarded.
29. Binary subtraction using 2s complement
5 101
-7 111 1s comple.---000
---- + 1
-2 ------
2s complement 001
+101
-------
result 110
1s complement 001
+ 1
--------
2s complement 010 final result
Carry is 0 so result is negative
0
41. Multiplication
Binary, two n-bit values
As with decimal values
E.g.,
1110
x 1011
1110
1110
0000
1110
10011010
42. Binary Multiplication
Perform the following multiplication in binary
number system: 1510 810
Perform the following multiplication in binary
number system: 10012 11012
Perform the following multiplication in binary
number system: 111.112 101.12
43. Solve
(205)10 x (3)10
(1110101)2 x (1001)2
(110)2 x (10)2
(1111101)2 x (101)2
(15)10 x (8)10