Logic Gates

Logic Gates - And or Or?

Without logic gates, your computer would not function. Most people are aware of the fact that computers function on a form of math that is comprised entirely of 1s and 0s. This is what defines them as binary devices. The logic gates allow the computer to actually perform the mathematical operations that allow it to do everything from display a red pixel when it gets the appropriate data from an image file to crunching enormously complex math problems in fractions of a second.

One way to think of a logic gate is as a switch that is turned on or off depending upon logical input received from another device. Computers, microcontrollers and other digital devices are essentially incredibly complex combinations of these devices, which illustrates why computers are sometimes described as being machines that are simply made up of an enormous number of different on and off switches. In logic gates, on and off corresponds to 1 and 0, respectively, which is also described as true or false.

 

What are Logic Gates?

In the simplest terms, a logic gate is an electronic device that can perform a Boolean function. These can be made out of a variety of different types of components. In today's world, most logic gates are made using transistors and diodes. It is possible, however, to make logic gates out of just about anything, including mechanical devices, optical devices and many other components. Logic gates can also be utilized in theoretical settings, in which case there is no physical device, as detailed by Jaeger in his book Microelectronic Circuit Design from 1997.

Inside a computer, there are hundreds of millions of logic gates working in concert. The memory has logic gates, the microprocessor has an enormous number of logic gates and, quite simply, logic gates are really at the heart of what makes a computer work.

In the simplest terms, logic gates can perform one logical operation and will always output the same number given the same input. In some cases, however, multiple different logic gates can be combined into entirely new logic gates or multiple logic gates can be combined to take up the function of a single, simple logic gate by combining one of the two universal types of logic gates.

 

History and Development of Logic Gates

If you're an electrical engineer or just have a hobbyist interest in electronics, you're likely well aware of the fact that some of the most exciting developments in electronics occurred during the end of the 19th and beginning of the 20th centuries. The case is the same with logic gates. The first theoretical development that is documented comes from 1886, when Charles Sanders Peirce theorized how circuits could be utilized to carry out logical operations. Vacuum tubes were eventually employed for this exact purpose and, in 1907, Lee De Forest developed an AND logic gate. Development has never ceased since the first logic gates were conceived, with logic gates working at the smallest scales & $150; meaning atomic computers – being currently developed in the world's most advanced laboratories.

 

Difference between Distinctive Shape and Rectangular Shape

There are two different shapes used to represent logic gates in schematics. The first type is called the distinctive shape. The distinctive shape originated in the military and is a simplified way of representing the function of a logic gate. The rectangular shape is the second shape utilized to represent logic gates in schematics. These use simple rectangles to represent the component, with a symbol on the inside of the rectangle describing its function. The rectangular shapes are more versatile, allowing a wider variety of logic gates to be represented. The distinctive shapes are very easy to read and make it convenient to ascertain the function of a logic gate in a circuit when looking at a schematic diagram.

Universal logic gates, when they are configured to be the equivalent of a different type of logic gate by combining them in various ways, will be represented on schematic diagrams either by the standard symbol for the logic gate that they have been assembled into or by showing each of the various logic gates involved in creating a single component out of a combination of many components.

 

What is Boolean Algebra and How can it be used to Describe Logic Gates?

Boolean algebra is a form of algebra where the variables are true or false. These are represented as the number 1 and the number 0. Boolean algebra utilizes terms such as AND and OR, NOT and NOR, XNOR and others where electronics are concerned, from which the names of various logic gates are derived. This form of algebra is not particularly old, having been introduced in 1854. It takes its name from the author of the book ''An Investigation of the Laws of Thought'' by George Boole.

Some logic gate types do not conform to Boolean algebra. For example, some logic gates have three outputs. The logical outputs still conform to Boolean algebra, but the third output determines whether the logic gate even factors into the condition of the circuit to which it is attached. These logic gates don't have a third state in terms of algebra, but they do have a third state in that they have a higher impedance level that can be utilized to remove them from the circuit.

The basic concepts of Boolean algebra are also used in philosophical logic and the term truth table is used in that field, as well, though the usage and the application are different than they are when discussing electronic devices, though they share some intriguing similarities.

 

What are Truth Tables?

Truth tables are used in Boolean algebra and in logic. They are made up of columns that describe logical operations and a column that describes the value that results from that logical operation. These are some of the most basic tools utilized by engineers when they are building complex logic circuits. An engineer can look at a truth table and determine what kind of output a given logic gate will produce if given specific inputs.

For basic logic gates, truth tables tend to be consistent. For compound logic gates, however, the truth table that will apply depends upon the configuration of the gates being combined and what types of gates are being combined.

 

What types of Logic Gates Exist?

There are numerous different types of logic gates available. The simplest ones perform one logical function. There are also logic gates that are constructions made out of multiple types of simple logic gates, called compound logic gates. In addition to this, there are logic gates that are designed to have more than two types of output, allowing them to be completely removed from a circuit under conditions when their input needs to be ignored by a device. There are also logic gates that are universal, meaning that they can be used to construct any other type of logic gate.

 

What is an AND Gate?

AND gates are types of logic gates utilized to implement logical conjunction. It will only output a 1 under the condition that both of the inputs are 1s.

Distinctive shape

 

Rectangular shape

 

Boolean algebra between A & B      

An AND will output a 0 unless both of the inputs are 1s.

Truth table – Figure 4

INPUT

OUTPUT

 

A

B

A AND B

0

0

0

0

1

0

1

0

0

1

1

1

 

What is AND-OR-Invert?

An AND-OR Invert is a type of compound logic gate. It has two levels and consists of a NOR gate preceded by one or more AND gates.

Distinctive Shape

Note that this shape is dependent upon the number of gates used. Below is an example.

 

Rectangular Shape

This shape is dependent upon number of gates used and how they are arranged.

Boolean algebra between A & B

Truth Table

The number of gates affects the truth table for this type of compound gate. The following truth table is for a 2-2 AOI as per Wikitronics.

 

What is an Inverter Logic Gate?

An inverter gate is also called a NOT gate. These gates implement negation.

Distinctive shape

Rectangular shape

Boolean algebra between A & B

Truth table

 

What is a NAND Gate?

A NAND gate will output a 0 only under the condition that both inputs are 1s. Under any other condition, this type of gate will output a 1.

Distinctive shape

 

Rectangular Shape

 

Boolean Algebra between A & B

 

Truth table

 

What is a NOR Gate?

A NOR gate outputs a 1 only under the condition that both inputs are 0. In every other instance, it outputs a 0.

 

Distinctive shape

 

Rectangular shape

 

Boolean algebra between A & B

 

Truth table

 

What is a NOT Gate?

NOT gates are gates that are designed to output logical negation. These take one input and output the opposite of whatever input they receive.

 

Distinctive shape

 

Rectangular shape

 

Boolean algebra between A & B

 

Truth table

 

What is an OR Gate?

In an OR gates, the output is a 1 if either input is a 1. Another way to describe this function is that an OR gate outputs the maximum of two binary digits that constitute its input.

 

Distinctive shape

 

Rectangular shape

 

Boolean algebra between A & B

 

Truth table

 

What is a XNOR Gate?

The function of this type of logic gate is exactly the opposite of the OR gate. If both the inputs into this gate are identical, it outputs a 1.

 

Distinctive shape

 

Rectangular shape

 

Boolean algebra between A & B

   or   

 

Truth table

 

What is a XOR Gate?

This is a type of gate that implements an exclusive OR. It will output a 1 if only one of the inputs is a 1, but will output a 0 in any other case. In basic terms, an XOR gate will output a 1 only under conditions of inequality.

 

Distinctive shape

 

Rectangular shape

 

Boolean algebra between A & B

 

Truth table

 

What are Three-state Logic Gates?

Three state logic gates have what amounts to a separate output aside from the 1 or 0 that most logic gates can output. These logic gates also have a high impedance output, which has the effect of removing the influence of the logic gate from the circuit. These are utilized in certain types of devices, such as buses, which can only take input from one device at a time. The third logic state allows any and all output from the three state logic gate to be eliminated altogether from the circuit, freeing up that circuit for other output from other devices.

 

What are Universal Logic Gates?

NAND and NOR gates are both universal logic gates. The concept behind this is really quite simple, though it is often times very complex in execution. Either of these types of gates can be combined in various ways to obtain the exact same functions as any other logic gate. Because of this, entire systems can be constructed of only NAND and NOR gates, according to All About Circuits.