study of logic gates

Post on 31-Oct-2014

146 views 5 download

Tags:

description

full details about logic gates is given.will enjoy watching,downloading and sharing!@deksto

Transcript of study of logic gates

MADE BY :

SHUBHAM DESHPANDE

Class xii

@ dekstotwitter

ACKNOWLEDGEMENT

I express our sincere thanks to all those who have provided me valuable guidance towards the completion of this investigatory project as a part of the syllabus of class XII Physics. At first, I extend my thanks to honorable Mrs. Mala Chembath, Narayana Vidyalayam, Nagpur for providing me the varieties of opportunities, infrastructure, facilities and inspiration to gather professional knowledge and material without which it would have been impossible to complete this hard work.

I hereby take the opportunity to express deep sense of gratitude and whole hearted thanks to my project guide Mr Abhay Domle for his inspiration and guidance throughout the course in this project work

Finally, I extend special thanks and respect to my parents and friends for encouraging me for class XII Physics.

Thank you.

2

3

4

INTRODUCTION

A logic gate is an idealized or physical device implementing a Boolean function, that is, it performs a logical operation on one or more logic inputs and produces a single logic output. Depending on the context, the term may refer to an ideal logic gate, one that has for instance zero rise time and unlimited fan-out, or it may refer to a non-ideal physical device (see Ideal and real op-amps for comparison).

Logic gates are primarily implemented using diodes or transistors acting as electronic switches, but can also be constructed using electromagnetic relays (relay logic), fluidic logic, pneumatic logic, optics, molecules, or even mechanical elements. With amplification, logic gates can be cascaded in the same way that Boolean functions can be composed, allowing the construction of a physical model of all of Boolean logic, and therefore, all of the algorithms and mathematics that can be described with Boolean logic.

Logic gates can also be used to store data. A storage element can be constructed by connecting several gates in a "latch" circuit. More complicated designs that use clock signals and that change only on a rising or falling edge of the clock are called edge-triggered "flip-flops". The combination of multiple flip-flops in parallel, to store a multiple-bit value, is known as a register. When using any of these gate setups the overall system has memory; it is then called a sequential logic system since its output can be influenced by its previous state(s).

These logic circuits are known as computer memory. They vary in performance, based on factors of speed, complexity, and reliability of storage, and many different types of designs are used based on the application.

5

WHAT IS TRUTH TABLE?

A truth table is a mathematical table used in logic—specifically in connection with Boolean algebra, Boolean functions, and propositional calculus—to compute the functional values of logical expressions on each of their functional arguments, that is, on each combination of values taken by their logical variables. In particular, truth tables can be used to tell whether a propositional expression is true for all legitimate input values, that is, logically valid.

Practically, a truth table is composed of one column for each input variable (for example, A and B), and one final column for all of the possible results of the logical operation that the table is meant to represent (for example, A XOR B). Each row of the truth table therefore contains one possible configuration of the input variables (for instance, A=true B=false), and the result of the operation for those values. See the examples below for further clarification.

6

TYPES OF LOGIC GATES

There are three types of logic gates:

1) Basic Logic gates2) Universal Logic gates3) Digital Logic gates

Basic Logic Gates:

Basic logic gates are classified into three types:

-NOT gate

-AND gate

-OR gate

Universal Logic Gates:

Universal logic gates are classifies into two types:

-NAND gate

-NOR gate

Exclusive Logic Gates:

Digital logic gates are classified into two types:

-XNOR

-XOR

7

THE ‘NOT’ GATE

The NOT gate is also known as an inverter; simply because it changes the input to its opposite (inverts it). The NOT gate accepts only one input and the output is the opposite of the input. In other words, a low-voltage input (0) is converted to a high-voltage output (1).

SYMBOL:

TRUTH TABLE:

INPUT OUTPUT0 11 0

 

8

*** The output Q is true when the input A is NOT true; the output is the inverse of the

input. A NOT gate can only have one input. A NOT gate is also called an inverter.

Boolean expression for NOT gate:

For a not gate or inverter, the Boolean expression is given by,

 

Consider the following circuit diagram:

In above circuit, at left side we have connected the battery. Switch key is referred as input and LED or bulb represents output. Closed switch key means high input and opened switch key means low or zero. Glowing LED represents high output and if it’s OFF, it represents low at output.

If switch is open, circuit will not complete and hence the LED will not glow showing low at output. But when switch key is closed, the circuit will complete and shows high at output.

9

THE ‘AND’ GATE

The AND gate is a basic digital logic gate that implements logical conjunction - it behaves according to the truth table to the right. A HIGH output (1) results only if both the inputs to the AND gate are HIGH (1). If neither or only one input to the AND gate is HIGH, a LOW output results. In another sense, the function of AND effectively finds the minimum between two binary digits, just as the OR function finds the maximum. Therefore, the output is always 0 except when all the inputs are 1s.

SYMBOL:

TRUTH TABLE:

10

A B OUTPUT

0 0 00 1 01 0 01 1 1

***The output Q is true if input A AND input B are both true. An AND gate can have two or more inputs, its output is true if all inputs are true.

Boolean expression for AND gate:

Three switch keys-A,B and C are inputs. In the left we have connected the battery and in right side bubble named X is a AND gate's output (LED). Open switch is referred to low, off or zero and closed switch key is referred as high, On or One. When the LED is glowing, It is showing High, On state or one and when LED is not glowing, it is showing low, off state or zero.The LED will glow only when these all three inputs i.e. switches are closed. If any one of them is open then LED doesn't glow and thus represents low or off state or zero.

11

THE ‘OR’ GATE The OR gate is a digital logic gate that implements logical disjunction - it behaves according to the truth table to the right. A HIGH output (1) results if one or both the inputs to the gate are HIGH (1). If neither input is HIGH, a LOW output (0) results. In another sense, the function of OR effectively finds the maximum between two binary digits, just as the complementary AND function finds the minimum.

SYMBOL:

TRUTH TABLE:

12

A B OUTPUT

0 0 00 1 11 0 11 1 1

***The output Q is true if input A OR input B is true (or both of them are true). An OR gate can have two or more inputs, its output is true if at least one input is true.

Boolean expression for OR gate:

In above parallel circuit, three Switch keys A, B and C are used as three inputs, and one bulb at right bottom is shown as output. When switch key will be closed, it represents a High, ON or 1 logic and when switch key is opened, it shows that input is low or 0. When the bulb will glow, it shows a high output and when it turns off, it shows a low or zero at output.

13

THE NAND GATE (NAND = N ot AND )In digital electronics, a NAND gate (Negated AND or NOT AND) is a logic gate which produces an output that is false only if all its inputs are true. A LOW (0) output results only if both the inputs to the gate are HIGH (1); if one or both inputs are LOW (0), a HIGH (1) output results. The NAND gate is significant because any Boolean function can be implemented solely by using a combination of NAND gates.

SYMBOL:

TRUTH TABLE:

14

A B OUTPUT

0 0 10 1 11 0 11 1 0

*** The output is true if input A AND input B are NOT both true. A NAND gate can have two or more inputs; its output is true if NOT all inputs are true.

Boolean expression for NAND gate:

Three switch keys A,B and C in above diagram are referred as three inputs. The bulb marked as X is showing output. Closed switch keys represents high or one and opened switch keys are represents as low inputs. The output is high or one when the bulb or LED glows and output is zero or low when the Led doesn't glow.Bulb doesn't glow when all the switch keys are closed that is inputs are high. Otherwise it will glow at all other inputs.

15

THE NOR GATE (NOR = N ot OR )The NOR gate is a digital logic gate that implements logical NOR - it behaves according to the truth table to the right. A HIGH output (1) results if both the inputs to the gate are LOW (0); if one or both input is HIGH (1), a LOW output (0) results. NOR is the result of the negation of the OR operator. NOR is a functionally complete operation—combinations of NOR gates can be combined to generate any other logical function. By contrast, the OR operator is monotonic as it can only change LOW to HIGH but not vice versa.

SYMBOL:

TRUTH TABLE:

A B OUTPUT

0 0 10 1 01 0 01 1 0

16

   ***The output Q is true if NOT inputs A OR B is true. A NOR gate can have two or more inputs, its output is true if no inputs are true.

Boolean expression for NOR gate:

The three switch keys show three inputs. The bulb named X at right side shows output.The input is one, when the switch key is closed and input is high or one when the switch key is is opened. When bulb will glow it shows one or high at output and when its closed it shows zero or low at output.

17

THE X-NOR (EX clusive-NOR ) GATEThe XNOR gate is a digital logic gate whose function is the inverse of the exclusive OR (XOR) gate. The two-input version implements logical equality, behaving according to the truth table to the right. A HIGH output (1) results if both of the inputs to the gate are the same. If one but not both inputs are HIGH (1), a LOW output (0) results.

SYMBOL:

TRUTH TABLE:

A B OUTPUT

0 0 10 1 01 0 01 1 1

***The output Q is true if inputs A and B are the SAME (both true or both false). EX-NOR gates can only have 2 inputs.

18

THE EX-OR (EX clusive-OR ) GATEThe XOR gate is a digital logic gate that implements an exclusive or; that is, a true output (1) results if one, and only one, of the inputs to the gate is true (1). If both inputs are false (0) or both are true (1), a false output (0) results. Its behavior is summarized in the truth table shown on the right. A way to remember XOR is "one or the other but not both". It represents the inequality function, i.e., the output is HIGH (1) if the inputs are not alike otherwise the output is LOW (0).

SYMBOL:

TRUTH TABLE:

A B OUTPUT

0 0 00 1 11 0 11 1 0

 ***The output Q is true if either input A is true OR input B is true, but not when both of them are true. This is like an OR gate but excluding both inputs being true. The output is true if inputs A and B are DIFFERENT. EX-OR gates can only have 2 inputs.

19

SUMMARY

Simple Logic Gates

The NOT gate gives a 1 when input A is 0.

The AND gate gives a 1 when both A AND B are 1;

The OR gate gives a 1 when A OR B are 1 or both;

The Exclusive OR gate gives a 1 when A or B are 1 but not both;

The NOR gate gives a 1 when both A and B are 0;

The NAND gate gives a 1 when either A or B are 0;

The outputs can be summed up in truth tables.

Combining Logic Gates

The output of one logic gate can be connected to the input of another.

Truth tables can be made for simple combinations.

20

SIMPLIFICATION OF EXPRESSIONThe rules help us to simplify a lot of more complex expressions. We can build a circuit using a Boolean expression, which we will look at now.

A B OUTPUT

0 0 00 1 11 0 11 1 0

1. Look at where the output is 1. It occurs when A is 1 and B is 0, we get a 1, or when A is 0 and B is 1. We can write this in Boolean notation as:

2. This means that we need an OR gate to give us the output Q. So here is the OR gate with its inputs:

3. To achieve the inputs we need to have two AND gates, each of which has ONE of its inputs inverted. This part of the circuit will give out 1 when A = 0 and B = 1.

21

4. This part of the circuit will give out 1 when A = 1 and B = 0

5. So now we need to connect each part to the two inputs A and B.

6. Now we need to connect up our circuit to the OR gate:

22

Bibliography

Wikipedia,

books.google.co.in

wikiforu.com

physicsbook.webs.com

23

FEW EXPERIMENTS PERFORMED

NOR GATE WHEN NO INPUT IS GIVEN

24

WHEN INPUT IS 0, 0 THEN OUTPUT IS 1

25

WHEN IN AND GATE INPUT IS 1, 1 THEN OUTPUT IS 1

26

WHEN IN OR GATE INPUT IS 0, 1 THEN OUTPUT IS 1

27

I PERFORMING THE EXPERIMENT FOR NAND GATE

28