Logic optimization is a process of finding an equivalent representation of the specified
logic circuit under one or more specified constraints. This process is a part of a
logic synthesis applied in
digital electronics and
integrated circuit design.
Generally, the circuit is constrained to a minimum chip area meeting a predefined response delay. The goal of logic optimization of a given circuit is to obtain the smallest
logic circuit that evaluates to the same values as the original one.
The smaller circuit with the same function is cheaper,
takes less space,
consumes less power, have shorter latency, and minimizes risks of unexpected
cross-talk
In electronics, crosstalk is any phenomenon by which a signal transmitted on one circuit or channel of a transmission system creates an undesired effect in another circuit or channel. Crosstalk is usually caused by undesired capacitive, induc ...
,
hazard of delayed signal processing, and other issues present at the nano-scale level of metallic structures on an
integrated circuit
An integrated circuit or monolithic integrated circuit (also referred to as an IC, a chip, or a microchip) is a set of electronic circuits on one small flat piece (or "chip") of semiconductor material, usually silicon. Large numbers of tiny ...
.
In terms of
Boolean algebra, the optimization of a complex
boolean expression is a process of finding a simpler one, which would upon evaluation ultimately produce the same results as the original one.
Motivation
The problem with having a complicated
circuit
Circuit may refer to:
Science and technology
Electrical engineering
* Electrical circuit, a complete electrical network with a closed-loop giving a return path for current
** Analog circuit, uses continuous signal levels
** Balanced circu ...
(i.e. one with many elements, such as
logic gate
A logic gate is an idealized or physical device implementing a Boolean function, a logical operation performed on one or more binary inputs that produces a single binary output. Depending on the context, the term may refer to an ideal logic gate, ...
s) is that each element takes up physical space in its implementation and costs time and money to produce in itself. Circuit minimization may be one form of logic optimization used to reduce the area of complex logic in
integrated circuit
An integrated circuit or monolithic integrated circuit (also referred to as an IC, a chip, or a microchip) is a set of electronic circuits on one small flat piece (or "chip") of semiconductor material, usually silicon. Large numbers of tiny ...
s.
With the advent of
logic synthesis, one of the biggest challenges faced by the
electronic design automation
Electronic design automation (EDA), also referred to as electronic computer-aided design (ECAD), is a category of software tools for designing Electronics, electronic systems such as integrated circuits and printed circuit boards. The tools wo ...
(EDA) industry was to find the most simple circuit representation of the given design description.
While
two-level logic optimization
Logic optimization is a process of finding an equivalent representation of the specified logic circuit under one or more specified constraints. This process is a part of a logic synthesis applied in digital electronics and integrated circuit de ...
had long existed in the form of the
Quine–McCluskey algorithm, later followed by the
Espresso heuristic logic minimizer, the rapidly improving chip densities, and the wide adoption of
Hardware description languages for circuit description, formalized the logic optimization domain as it exists today, including
Logic Friday (graphical interface), Minilog, and ESPRESSO-IISOJS (many-valued logic).
Methods
The methods of logic circuit simplifications are equally applicable to the
boolean expression minimization.
Classification
Today, logic optimization is divided into various categories:
;Based on circuit representation
: Two-level logic optimization
: Multi-level logic optimization
;Based on circuit characteristics
:Sequential logic optimization
:Combinational logic optimization
;Based on type of execution
:Graphical optimization methods
:Tabular optimization methods
:Algebraic optimization methods
Graphical methods
Graphical methods represent the required logical function by a diagram representing the logic variables and value of the function. By manipulating or inspecting a diagram, much tedious calculation may be eliminated.
Graphical minimization methods for two-level logic include:
* ''
Euler diagram'' (aka ''Eulerian circle'') (1768) by
Leonhard P. Euler (1707–1783)
* ''
Venn diagram'' (1880) by
John Venn (1834–1923)
* ''
Karnaugh map'' (1953) by
Maurice Karnaugh
Boolean expression minimization
The same methods of boolean expression minimization (simplification) listed below may be applied to the circuit optimization.
For the case when the Boolean function is specified by a circuit (that is, we want to find an equivalent circuit of minimum size possible), the unbounded circuit minimization problem was long-conjectured to be
-complete in
time complexity (the complexity class of decision problems that can be solved on a deterministic Turing machine in polynomial time), a result finally proved in 2008,
but there are effective heuristics such as
Karnaugh maps and the
Quine–McCluskey algorithm that facilitate the process.
Boolean function minimizing methods include:
*
Quine–McCluskey algorithm
*
Petrick's method
Optimal multi-level methods
Methods which find optimal circuit representations of Boolean functions are often referred as "exact synthesis" in the literature. Due to the computational complexity, exact synthesis is tractable only for small Boolean functions. Recent approaches map the optimization problem to a
Boolean satisfiability problem.
This allows finding optimal circuit representations using a
SAT solver.
Heuristic methods
A
heuristic method uses established rules that solve a practical useful subset of the much larger possible set of problems. The heuristic method may not produce the theoretically optimum solution, but if useful, will provide most of the optimization desired with a minimum of effort. An example of a computer system that uses heuristic methods for logic optimization is the
Espresso heuristic logic minimizer.
Two-level versus multi-level representations
While a two-level circuit representation of circuits strictly refers to the flattened view of the circuit in terms of SOPs (
sum-of-products) — which is more applicable to a
PLA
PLA may refer to:
Organizations Politics and military
* People's Liberation Army, the armed forces of China and of the ruling Chinese Communist Party
* People's Liberation Army (disambiguation)
** Irish National Liberation Army, formerly called ...
implementation of the design — a
multi-level representation
Multilevel or multi-level may refer to:
* A hierarchy, a system where items are arranged in an "above-below" relation.
* A system that is composed of several layers.
* Bombardier MultiLevel Coach
The Bombardier MultiLevel Coach is a bi-level ...
is a more generic view of the circuit in terms of arbitrarily connected SOPs, POSs (
product-of-sums), factored form etc. Logic optimization algorithms generally work either on the structural (SOPs, factored form) or functional (
Binary decision diagrams
In computer science, a binary decision diagram (BDD) or branching program is a data structure that is used to represent a Boolean function. On a more abstract level, BDDs can be considered as a compressed representation of sets or relations. Un ...
, Algebraic Decision Diagrams (ADDs)) representation of the circuit. In sum-of-products (SOP) form, AND gates form the smallest unit and are stitched together using ORs, whereas in product-of-sums (POS) form it is opposite. POS form requires parentheses to group the OR terms together under AND gates, because OR has lower precedence than AND. Both SOP and POS forms translate nicely into circuit logic.
If we have two functions ''F''
1 and ''F''
2:
:
:
The above 2-level representation takes six product terms and 24 transistors in CMOS Rep.
A functionally equivalent representation in multilevel can be:
: ''P'' = ''B'' + ''C''.
: ''F''
1 = ''AP'' + ''AD''.
: ''F''
2 = ''A
'P'' + ''A
'E''.
While the number of levels here is 3, the total number of product terms and literals reduce because of the sharing of the term B + C.
Similarly, we distinguish between
sequential and
combinational circuits, whose behavior can be described in terms of
finite-state machine state tables/diagrams or by Boolean functions and relations respectively.
Combinational circuits are defined as the time independent circuits which do not depends upon previous inputs to generate any output are termed as combinational circuits. Examples –
Priority encoder A priority encoder is a circuit or algorithm that compresses multiple binary inputs into a smaller number of outputs. The output of a priority encoder is the binary representation of the index of the most significant activated line, starting from ...
,
Binary decoder,
Multiplexer,
Demultiplexer.
Sequential circuits are those which are dependent on clock cycles and depends on present as well as past inputs to generate any output. Examples –
Flip-flops,
Counters.
Example

While there are many ways to minimize a circuit, this is an example that minimizes (or simplifies) a Boolean function. The Boolean function carried out by the circuit is directly related to the algebraic expression from which the function is implemented.
Consider the circuit used to represent
. It is evident that two negations, two conjunctions, and a disjunction are used in this statement. This means that to build the circuit one would need two
inverters, two
AND gates, and an
OR gate.
The circuit can simplified (minimized) by applying laws of
Boolean algebra or using intuition. Since the example states that
is true when
is false and the other way around, one can conclude that this simply means
. In terms of logical gates,
inequality simply means an
XOR gate (exclusive or). Therefore,
. Then the two circuits shown below are equivalent, as can be checked using a
truth table:
See also
*
Binary decision diagram (BDD)
*
Don't care condition
In digital logic, a don't-care term (abbreviated DC, historically also known as ''redundancies'', ''irrelevancies'', ''optional entries'', ''invalid combinations'', ''vacuous combinations'', ''forbidden combinations'', ''unused states'' or ''lo ...
*
Prime implicant
In Boolean logic, the term implicant has either a generic or a particular meaning. In the generic use, it refers to the hypothesis of an implication (implicant). In the particular use, a product term (i.e., a conjunction of literals) ''P'' is an ...
*
Circuit complexity — on estimation of the circuit complexity
*
Function composition
In mathematics, function composition is an operation that takes two functions and , and produces a function such that . In this operation, the function is applied to the result of applying the function to . That is, the functions and ...
*
Function decomposition
*
Gate underutilization
Circuit underutilization also chip underutilization, programmable circuit underutilization, gate underutilization, logic block underutilization refers to a physical incomplete utility of semiconductor grade silicon on a standardized mass-produ ...
*
Logic redundancy
*
Harvard minimizing chart
Logic optimization is a process of finding an equivalent representation of the specified logic circuit under one or more specified constraints. This process is a part of a logic synthesis applied in digital electronics and integrated circuit de ...
(Wikiversity) (Wikibooks)
Notes
References
Further reading
* (146 pages)
* (NB. Chapters 7–9 cover combinatorial two-level, combinatorial multi-level, and respectively sequential circuit optimization.)
*
*
*
{{digital electronics
Electronic engineering
Electronic design
Digital electronics
Electronic design automation
Electronics optimization
Boolean algebra
Circuit complexity
Logic in computer science