4

Click here to load reader

Exclusive OR GAte

Embed Size (px)

Citation preview

Page 1: Exclusive OR GAte

LAB OBECTIVE: (02)

“To Analyze the Behavior of Exclusive OR (XOR) Gate”

Definition:

An XOR gate (sometimes referred to by its extended name, Exclusive OR gate) is a digital logic gate

with two or more inputs and one output that performs exclusive disjunction. The output of an XOR gate

is true (1) only when exactly one of its inputs is true (1). If both of an XOR gate's inputs are false (0),

or if both of its inputs are true (1), then the output of the XOR gate is false (0).

XOR can also be viewed as addition modulo 2. As a result, XOR gates are used to implement binary

addition in computers. A Half Adder consists of an XOR gate and an AND GATE. Other uses include

substractors, comparators, and controlled inverters.

Algebraic expression:

The Algebraic expression

And ( )

Both represent the XOR gate with inputs A and B.

Note:

If an XOR gate has more than two inputs, then its behavior depends on its implementation. In the vast

majority of cases, an XOR gate will output true if an odd number of its inputs is true. However, it's

important to note that this behavior differs from the strict definition of exclusive or, which insists that

exactly one input must be true for the output to be true.

Symbol:

Page 2: Exclusive OR GAte

(OR)

Components:

1) Inverter

2) AND Gates

3) OR gate

4) Breadboard

Circuit:

Procedure:

1) First connect the power supply to the circuit board (voltage must be less than 5.5 volts) 2) Take two inputs from the power supply with switches.

3) Take first input & pass it through inverter & then give it to AND gate (A).

4) Take the second input & give it to AND gate (A).

Page 3: Exclusive OR GAte

5) Now take the first input & give it to AND gate (B).

6) Take the second input & pass it through inverter & then give it to AND gate (B).

7) Now take the outputs of both AND gates (A & B) & give it to OR gate.

8) Plug an LED to the output of OR gate.

9) Ground the circuit.

Conclusion:

1) If either of the inputs A or B is true (on/1). The output result will be true (on/1).

2) If both of the inputs A & B are false (off/0). The output result will be false (off/0).

Half Adder Circuit:

The half adder adds two single binary digits A and B. It has two outputs, sum (S) and carry (C).

The carry signal represents an overflow into the next digit of a multi-digit addition. The value of the sum is 2C + S. The simplest half-adder design, pictured on the right, incorporates a ZOR gate for S and an AND gate for C. With the addition of an OR gate to combine their carry outputs, two half adders can be combined to make a full adder.

The half-adder adds two input bits and generates a carry and sum, which are the two outputs of half-adder .The input variables of a half adder are called the augend and addend bits. The output variables are the sum and carry.

Truth table:

A B Sum (S) Carry (C)

1 1 0 1

0 1 1 0

1 0 1 0

Page 4: Exclusive OR GAte

0 0 0 0