Xor Gate
Xor Gate
DEPARTMENT: COMPUTING
Group 1
Group Members
F = A BI + A I B = A ⊕ B
Where;
F is the ouput,
Can be built from other logic gates like NAND or NOR gates
(considered "universal gates" as any logic function can be built
from them).
A B F
0 0 0
0 1 1
1 0 1
1 1 0
2. 3-input XOR Gate: A 3-input XOR gate takes three binary inputs
and produces a single output. The XOR operation evaluates to true (1)
when an odd number of inputs are true (1), and false (0) otherwise.
The 3-input XOR gate follows the same logic as a two input XOR gate
but with three input signals.
The Boolean expression for a three input XOR gate is, F = A ⊕ B ⊕ C.
THREE INPUT TRUTH TABLE OF AN XOR GATE
A B C F
0 0 0 0
0 0 1 1
0 1 0 1
0 1 1 0
1 0 0 1
1 0 1 0
1 1 0 0
1 1 1 1
3. 4-input XOR Gate: This type of XOR gate has four inputs and one
output. The output is high if an odd number of inputs are high, and low
0+0=0
0+1=1
∴F=1
0+0=0
0+1=1
∴F=1
0+1=1
1 + 0 = 1,
∴F=1
0+1=1
1 + 1 = 0,
∴F=0
Therefore the led- blue will turn off indicating the output is 0.
Here the inputs are x=1, y =0, z = 0;
1+0=1
1 + 0 = 1,
∴F=1
1+0=1
1 + 1 = 1,
∴F=0
Therefore the led- blue will turn off indicating the output is 0.
Here the inputs are x=1, y =1, z = 0;
1+1=0
0 + 0 = 0,
∴F=0
Therefore the led- blue will turn off indicating the output is 0.
Here the inputs are x=1, y =1, z = 1;
1+1=0
0 + 1 = 1,
∴F=1
An XOR gate can be used as a one-bit adder that adds any of the
two bits together to produce one bit as output. For instance, if we
add 1 plus 1 in binary, we can expect a two-bit answer, as 10 (it
means 2 in decimal).
In computer memory systems, XOR gates can be used for
address decoding. By combining address lines using XOR
operations, specific memory locations can be selected, enabling
efficient memory access in systems with multiple memory
modules.
In digital communication systems, XOR gates are used for error
detection and correction. By comparing corresponding bits in
transmitted and received data streams using XOR operations,
errors can be identified and corrected.
Since an XOR gate can generate a logic '1' output (when its 2
input bytes are unequal). In this case, it can be used in dealing
with a basic logic comparator. A Basic logic comparator is
a combinational logic circuit that compares the magnitudes of
two binary quantities to determine which one has the greater
magnitude. In other word, a comparator determines the
relationship of two binary quantities.
XOR logic acts as a simple system for encrypting and decrypting
data, i.e., performing an XOR of a digitized message with a binary
key produces encrypted ciphertex (encrypted text transformed
from plaintext using an encryption algorithms). Hence, XOR gates
are a fundamental building block of cryptographic circuit.
XOR gate is mainly used in the operation of half and full adders.
The concept of XOR gate is also used in the implementation of
microprocessors and circuits for digital signal processing.
XOR gates are essential components in the design of various
digital circuits, such as adders, subtractors, multiplexers, and flip-
flops. They are used to perform arithmetic operations, implement
control logic, and realize sequential circuits in digital systems.
In digital systems with multiple clock domains, XOR gates are
used for clock domain crossing synchronization. By XORing the
clocks from different domains and feeding the result to
synchronization elements, such as flip-flops, data transfers
between the domains can be synchronized to prevent timing
violations.