0% found this document useful (0 votes)
7 views23 pages

Lec 2

The document covers concepts related to digital design, including the calculation of 1's, 9's, and 10's complements of binary and decimal numbers, as well as methods for subtraction using complements. It also discusses Binary Coded Decimal (BCD) and Excess-3 codes, and explains even and odd parity as error detection methods in data transmission. Additionally, it outlines the laws, rules, and theorems of Boolean algebra, such as closure, commutative law, and distributive law.

Uploaded by

Rafay Owais
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views23 pages

Lec 2

The document covers concepts related to digital design, including the calculation of 1's, 9's, and 10's complements of binary and decimal numbers, as well as methods for subtraction using complements. It also discusses Binary Coded Decimal (BCD) and Excess-3 codes, and explains even and odd parity as error detection methods in data transmission. Additionally, it outlines the laws, rules, and theorems of Boolean algebra, such as closure, commutative law, and distributive law.

Uploaded by

Rafay Owais
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 23

0

Digital Design

Lecture#2
1’s Complement of a
Binary Number:
There is a simple algorithm to convert a binary number into 1’s complement. To get
1’s complement of a binary number, simply invert the given number. You can
simply implement logic circuit using only NOT gate for each bit of Binary number
input. Implementation of logic circuit of 4-bit 1’s complement is given as following
below.
Example-1: Find 1’s complement of binary number 10101110.
Simply invert each bit of given binary number, so 1’s complement of given number will
be 01010001.
Example-2: Find 1’s complement of binary number 10001.001.
Simply invert each bit of given binary number, so 1’s complement of given number will
be 01110.110.
Example-3: Find 1’s complement of each 3 bit binary number.
Simply invert each bit of given binary number, so 1’s complement of each 3 bit binary
number will be,
Nine’s complement

Take nine’s complement of


7856825

9’s complement of a decimal


number is the subtraction of
it’s each digits from 9

Answer???

1
Ten’s complement

Take ten’s complement of 7856825

10’s complement of a decimal number


can be found by adding 1 to the 9’s
complement of that decimal number. It is
just like 2s complement in binary number
representation.

For example, let us take a decimal


number 456, 9’s complement of this
number will be 999-456 which will be
543. Now 10s complement will be
2
543+1=544.
Subtraction using
Complements

72532-3250

Solution: Take ten’s complement of 3250


and add in 72532, then discard carry

3
6 Binary Coded Decimal
and Excess three codes
Decimal BCD Excess-3
0 0000 0011
1 0001 0100
2 0010 0101
3 0011 0110
4 0100 0111
5 0101 1000
6 0110 1001
7 0111 1010
8 1000 1011
9 1001 1100
7 EVEN Vs ODD Parity
A parity is an error coding method to find errors in digital
data. A parity bit is an extra bit which is added in binary
message to make total number of 1's either even or odd.
While reading or receiving the data parity check is made
to find the errors in data. It is used for error detection in
the original data at the receiver side and correcting the
data. Parity word denotes the number of 1's in binary
string. There are two parity systems: even or odd.
Even parity and odd parity are two methods which are
used in data transmission to ensure the integrity of
transmitted data. Both methods involve adding an extra
bit to the data being transmitted, which is called parity
bit, which is used for error detection.
Even Parity Check?

In even parity check works by ensuring that the


total number of ones in the data, including parity
bit is even. If in any case the total number of 1 in
the data bit is odd then a single 1 will be added to
make total number of 1 even else 0 will be
appended (if total number of 1 are already even).
Hence, if any error occurs, the parity check circuit
will detect it at the receiver’s end.
Odd Parity Check?
Odd parity, on the other hand, functions
similarly but ensures that the total
number of ones in the data, including the
parity bit, is odd. If total number of 1 in
the given binary string are even then 1 is
appended to make the total count of 1 as
odd else 0 is appended.
What is even parity and how
does it work in data
transmission?
Even parity is a method that is used in data
transmission to ensure data integrity. It consist
of adding an extra bit, called a parity bit, to the
transmitted data. This parity bit is set to 1 or 0
in a way that the total number of ones in the
data, including the parity bit, becomes even. If
the data already contains an even number of
ones then the parity bit is set to 0. If the data
has an odd number of ones then the parity bit
is set to 1. This process allows for the
detection of errors during transmission.
What is odd parity and its
role in ensuring data
integrity?

Odd parity is another method used for error detection in data


transmission. Similar to even parity, it involves adding a
parity bit to the transmitted data. In odd parity the parity bit
is set to 1 or 0 in a way that the total number of ones in the
data including the parity bit becomes odd. If the data already
has an odd number of ones thaen the parity bit is set to 0. If
the data has an even number of ones then the parity bit is set
to 1. This process helps in detecting errors during
transmission.
Laws, Rules & Theorems of
Boolean Algebra

🠶 Closure
🠶 Commutative
Law
🠶 Identity
Element
🠶 Inverse
🠶 Distributive
Law
Commutative
Law
🠶 Commutative Law for
Addition A + B = B + A

🠶 Commutative Law for


Multiplication
A.B = B.A
Distributive
Law
A.(B + C) = A.B
+ A.C
Postulates and Theorems of
Boolean Algebra

You might also like