The conjunctive normal form of a logical function is called. Conjunctive forms of logical functions

Plain conjunction called conjunction one or several variables, for it is each variable meet not more one times (or itself, or her negation).

For example, is a simple conjunction,

Diauncutive normal form (DNF) called disjunction simple conjunctions.

For example, the expression is the DNF.

Perfect diauncutive normal form (SDNF) called such diauncutive normal the form, w. which in eVERY conjunction enter everything variables this list (or ourselves, or them denial), moreover in one and tom sameorder.

For example, the expression is the DNF, but not SDNF. Expression is a CDNF.

Similar definitions (with the replacement of conjunction for disjunction and vice versa) are true for the PFF and SCFF. We give accurate wording.

Plain disjunction called disjunction one or several variables, for it is each variable included not more one times (or itself, or her negation). For example, the expression is simple disjunction,

Conjunctive normal form (KNF) called conjunction simple disjunctions (for example, the expression - the PFF).

A perfect conjunctive normal form (SCPF) is called such a QFF, in which every simple disjunction includes all variables of this list (either themselves, or their denial), and in the same manner.

For example, expression is SKPF.

We present the transition algorithms from one form to another. Naturally, in specific cases (with a certain creative approach), the use of algorithms is more time consuming than simple transformations that use a specific type of this form:

a) Transition from the DNF to the KNF

The algorithm of this transition is as follows: put over the DNF two denials and with the help of the de Morgan rules (not a touching upper denial) give the DNF denial again to the DNF. At the same time, it is necessary to disclose brackets using the absorption rule (or Blake rules). The denial of the obtained DNF (again according to the rule de Morgan) immediately gives us the CNF:

Note that the CNF can be obtained from the initial expression, if you make w. for brackets;

b) transition from the KNF to the DNF

This transition is carried out by simple disclosure of the brackets (with again, the absorption rule is used)

Thus, they received the DNF.

The reverse transition (from the SDNF to the DNF) is associated with the problem of minimizing the DNF. This will be told in Section. 5, here we will show how to simplify the DNF (or SDNF) according to Blake rule. Such a DNF is called abbreviated DNF;

c) reduction of the DNF (or SDNF) rule Blake

The application of this rule consists of two parts:

If there are foundations among the disjoint terms in the DNF , then add a conception to all the disjunction TO 1 TO 2. We do this operation several times (can be sequentially, you can simultaneously) for all possible pairs of terms, and then, apply usual absorption;

If the term added already was already kept in the DNF, it can be discarded at all, for example,

or

Of course, the abbreviated DNF is not determined by the sole, but they all contain the same number of letters (for example, there is a DNF After applying to it, Blake's rules can be reached to the DNF, equivalent to this):

c) Transition from DNF to SDNF

If in some simple conjunction lacks a variable, for example, z., insert the expression into it, after which we reveal the brackets (with the recurring disjunctive terms do not write). For example:

d) transition from the KNF to SKFF

This transition is carried out in a manner similar to the previous one: if there is not enough variable in simple disjunction (for example, z., I add expression to it (this does not change the disjunction itself), after which we reveal brackets using the distribution law):

Thus, SKFF was obtained from the PFF.

Note that the minimum or abbreviated PFF is usually obtained from the corresponding DNF.

Normal forms of logical functions The representation of the milk function in the form of disjunction of the conjunctitive terms Constituent of the Ki 2.7 unit is called a disjunctive normal form of the DNF of this function. Contains exactly one of one all logical variables taken with denials or without them, this form of a function representation is called the perfect disjunctive normal form of the SDNF of this function. As can be seen in the preparation of the SDNF function, it is necessary to make a disjunction of all minerms in which the function takes value 1.


Share work on social networks

If this job does not come up at the bottom of the page there is a list of similar works. You can also use the Search button.


Lecture 1.xx

Normal forms of logical functions

Representation of the boolean function in the form of disjunction of conjunctive terms (Constituent of units)K I.

, (2.7)

called disjunctive normal form (DNF) of this function.

If all conjunctive terms in the DNF areminerma , i.e. contain exactly one of one all logical variables taken with or without denying, then such a form of a function representation is calledperfect disjunctive normal form (SDNF. ) This function. SDNF is calledperfect because each term in disjunction includes all variables;diauncutive because the main operation in the formula is disjunction. Concept "normal form"Means a unambiguous method for recording a formula that implements the specified function.

Taking into account the above, the following theorem follows from Theorem 2.1.

Theorem 2. Any Boolean feature(not equal identically 0) can be presented in the SDNF, .

Example 3. Let we have a table specified functionf (x 1, x 2, x 3) (Table 10).

Table 10.

f (x 1, x 2, x 3)

Based on formula (2.6) we get:

As can be seen, when compiled by the SDNF, the functions need to be disjunction of all minerms, in which the function takes value 1.

Representation of milk function in the form of conjunction of disjunctive terms (zero constituent)D I.

, (2.8)

called conjunctive normal form (PFF) of this function.

If all the disjunctive terms of the PFF aremastermami , i.e. contain exactly one all logical variable functiontaken with denials or without them, then such a CNF is calledperfect conjunctive normal form (SKFF) of this function.

Theorem 3. Any Boolean feature(not equal identically 1) can be presented in SKFF, And such a representation is the only.

The proof of the theorem can be carried out similarly to the proof of Theorem 2.1 on the basis of the following Shannon Lemma on the conjunctive decomposition.

Lemma Shannon . Any Boolean featuref (x 1, x 2, ..., x m) from m variables can be represented so:

. (2.9)

It should be noted that both forms of representing the logical function (DNF and the PFF) are theoretically equal in their capabilities: any logical formula can be represented both in the DNF (except for the identical zero) and in the KNF (except for the identical unit). Depending on the situation, the representation of the function in one form or another may be shorter.

In practice, the DNF is most often used., since this form is more familiar for a person: since childhood, he is familiar to putting works than multiply the amounts (in last case He intuitively appears the desire to reveal the brackets and go through the DNF).

Example 4. For function f (x 1, x 2, x 3 ) specified Table. 10, write its SCFF.

In contrast to the SDNF, when compiling SKFF in the truth table, you need to watch the combinations of variables in which the function takes the value 0 and make the conjunction of the corresponding macstersms,but the variables need to be taken with inverse inversion:

It should be noted that it is impossible to move directly from the SDNF to its SCBF or vice versa. When you try to try such transformations, the functions inverse to the desired one are obtained. Expressions for SDNF and SCFF function can only be obtained from its truth table.

Example 5. For function f (x 1, x 2, x 3 ) specified Table. 10, try moving from SDNF to SKFF.

Using the result of Example 2.3 We will get:

As can be seen, under the total inversion, the SCFF of a logical function was obtained, which is reverse with respect to the function obtained in Example 2.4:

since. It contains all Masterms that are not in the expression for the SCFF of the function in question.

1. Using the properties of operations (see Table 9) identity (), the sum of module 2 (), implication (), go to operations and, or, not (in the BULLA).

2. Using the properties of denying and laws de Morgan (see Table 9) we achieve the denying operations only to separate variables, and not to entire expressions.

3. Using the properties of logical operations and or or (see Table 9), we obtain a normal form (DNF or PFF).

4. If necessary, proceed to perfect forms (SDNF or SCPF). For example, to obtain SCPF, it is often necessary to use the property :.

Example 6. Convert logical function to SKFF

Performing in order the steps above the algorithm given above, we get:

Using the absorption property, we get:

So we got the PFF functionf (x 1, x 2, x 3 ). To get it SKKF, you need every disjunction, which lacks any variable, repeat twice - with this variable and with its denial:

2.2.6. Minimization of logical functions

Since the same logic function can be represented byz. personal formulas, then finding the simplest phor mules, which defines a Boolean function, simplifies the logical scheme that implements Boolean Funcommon Minimum form L.about ghee function In some basis, it can be considered such that contains the minimum number of superpositions of Funto basis, allowing and brackets. However, it is difficult to build effective al. gorite such minimization to obtain the minimum bracer we.

Consider a simpler minimization problem in the synthesis of combination circuits, in which the minimum bracket form of the function is searched, and its minimum DNF. For this task, there are simple effective algorithms.

Method of Qwaina

The minimized function is presented in the SDNF, and all possible incomplete gluing operations are applied to it.

, (2.10)

and then the absorption

, (2.11)

and this pair of steps is used repeatedly. Thus, it is possible to reduce the rank of terms. This procedure is repeated until not a single term allowing gluing with any other thermal.

notice, that left part Equations (2.10) could immediately minimize a simpler and obvious way:

This method is bad in that, with such a direct minimization, conjunctive terms or disappear, although there are still cases of their use for gluing and absorbing with the remaining thermions.

It should be noted that the Kwain method is quite time consuming, therefore the probability of error assumption during the transformations is quite large. But its advantage is that theoretically, it can be used for any number of arguments and, with an increase in the number of variables, the transformations are not complicated so much.

Method card carno

Method of cards (tables) Carno is a more visual, less time-consuming and reliable way to minimize logical functions, but its use is practically limited to the functions of 3-4 variables, maximum - 5-6 variables.

Map Carno - This is a two-dimensional tabular form of presentation table of the truth of the milk function, allowing in a graphically visual form to easily find the minimum DNF of logical functions. Each cell of the table is compared with a minerm of the SDNF of a minimized function, and so that in any axes of the symmetry of the table correspond to the zones, mutually inverse for any variable. This cell location in the table makes it easy to determine the gluing terms of the CDNF (characterized by the inversion sign only one variable): they are located in the table symmetrically.

TRID Tables and Carno Card for Functions and or Two Pere. changes are presented in Fig. 8. In each cage of the card is recordedbut function on the appropriate set of arguum valuesn TOV.

A) and b) or

Fig. eight. Example map of carno for functions of two variables

In the map map for function and only one 1, so it cannot be gluedhing with anything. The expression for the minimum function will be only the term corresponding to this 1:

f \u003d x y.

Carnot map for a function or already three 1 and you can make two bonding pairs, with 1 corresponding to theirxY. , Used twice. In the expression for the minimum function, you need to write down the terms for glued steam, leaving all the variables in them, which for this pair do not change, and remove the variables that change their value. For horizontal gluing we getx. , and for vertical -y. , in the end we get expression

f \u003d X + Y.

In fig. 9 shows the truth tables of two functions of three variables (but ) and their cards of carno (b and B). Function F 2. It differs from the first fact that it is not defined on three sets of variables (in the table it is indicated by a downtime).

When determining the minimum DNF function, the following rules are used. All cells containing 1 are combined into closed rectangular areas calledk -kubami, where k \u003d log 2 k, k - Number 1 in a rectangular area. At the same time, each region should be a rectangle with the number of cells 2k, where k \u003d 0, 1, 2, 3, .... For k \u003d 1 Rectangle calledone-cubic and contains 2 1 \u003d 2 units; For k \u003d 2 rectangle contains 22 \u003d 4 units and calledtwo-cubic; at k \u003d 3 region of 2 3 \u003d 8 units calledthree-cubic ; etc. Units that cannot be combined into rectangles, you can callzero-cubes which contain only one unit (20 \u003d 1). As can be seen whenk. areas may have a square shape (but not necessarily), and with oddk. - Only rectangles.

b B.

Fig. nine. Example map of carno for three variable functions

These areas can intersect, i.e., the same cells can enter different areas. Then the minimum DNF function is recorded as a disjunction of all conjunctive terms corresponding tok - cubes.

Each of the specified areas on the map of Carno is presented in the minimum DNF conjunction, the number of arguments in whichk. less than the total number of arguments of the functionm. , i.e. this number is equalm - K. . Each conjunction of the minimum DNF is compiled only from those arguments that have values \u200b\u200bfor the corresponding area of \u200b\u200bthe map either without inversions, or only with inversion, i.e. do not change their value.

Thus, when covering the cells of the map, closed regions should strive to ensure that the number of areas is minimal, and each region contains a greater number of cells, since it will be the minimum number of members in the minimum DNF and the number of arguments in the appropriate conjunction will be minimal.

For a function on the map of Carno in Fig. nine,b finding

because for the upper closed area variablesx 1 and x 2 matter without inversions for lowerx 1 It matters with inversion, andx 3 - without inversion.

Unreasonable values \u200b\u200bin the map in Fig. nine,in You can approve, replacing zero or unit. For this feature it is clear that both uncertain values \u200b\u200bare more profitable to replace 1. At the same time, two areas are formed, which are various species 2-cubes. Then the expression for the minimum DNF function will be as follows:

When constructing closed areas, folding card carno in the cylinder is allowed both horizontal andr tikal axes with the association of opposite facesr you, i.e., units located on the edges of the map of Carno symmetryc. but, can also be combined.

Carnation cards can be drawing in different ways (Fig. 10).

x 2 x 3

a B.

Fig. 10. Different ways of image cards Carno
For function 3 variables

But the most convenient variants of carno cards for functions 2-4 variables are shown in Fig. 11 tables, because in them for each cell showbut all variables in direct or inverse form.

a B.

Fig. eleven. The most convenient image of carno cards
For functions 3 (
a) and 4 (b) variables

For functions 5 and 6 variables, the method shown in Fig. 10,in .

Fig. 12. Image card carno for function 5 variables

Fig. 13. Image map of carno for function 6 variables

Other similar works that may interest you. Ishm\u003e

9020. The principle of duality. Decomposition of boolean functions in variables. Perfect disjunctive and conjunctive normal forms 96.34 KB.
This theorem is constructive, as it allows for each function to construct the formula that implements it in the form of perfect d. f. To do this, in the truth table for each for the function, we mark all the lines in which
6490. Description and minimization of logical functions 187.21 Kb.
In verbal form, the relationship between the function arguments and its values \u200b\u200bis expressed. Example: The functions of three arguments takes the value when any two or more function arguments are equal. It consists in building a truth table containing a function value for all sets of argument values. IN this example On the truth table, we get this entry in the form of the DNF ...
6707. Designing relational databases. Problems of design in a classic approach. Principles of Normalization, Normal Forms 70.48 Kb.
What is a relational database project is a set of interrelated relationships in which all attributes are defined by primary relationship keys and some more are set. additional properties Relationships that belong to the principles of integrity support. Therefore, the database project must be very accurate and verified. In fact, the database project is the foundation of the future software package that will be used long and many users.
4849. Forms and methods for the implementation of state functions 197.3 Kb.
The term "function" has in domestic and foreign scientific literature far from the same value. In the philosophical and generalocial plan, it is considered as "the external manifestation of the properties of any object in this system of relations"; as a combination of ordinary or specific actions of individuals or organs
17873. Formation of logical Wood in 3 class students 846.71 KB.
Psychological and pedagogical aspects of the problem of forming a logical universal action For younger students, the methodology for assessing the formation of logical ogud. Development of the concept of universal development academic action in system general Education meets new social requests. The most important task modern system Education is the formation of universal academic actions Wood. The formation of universal educational actions is the key to the prevention of school difficulties.
2638. Technical implementation of logical connections in automatic linking systems 1.04 MB.
Technical implementation of logical links in automotive systems Technical implementation of three-digit and four-digit control algorithms can be achieved with relay contact and non-contact discrete and integral logical elements ...
10203. Application Concept Risk of a focused approach to build structural and logical models of emergence and development of emergency 70.8 Kb.
A common risk analysis The production environment is saturated with powerful technological systems and technologies that make human labor with a productive and less severe physically, however more dangerous. For risk, the surprise and suddenness of the dangerous situation is characteristic. Every day we encounter numerous risks But most of them remain potential t. Theory of risk provides for a quantitative assessment of the negative impact on man as well as damage to his health and life.
11576. Concept, types and forms of transactions. The consequences of non-compliance with the required form of transactions 49.82 Kb.
Recognition of the transaction invalid the types of invalid transaction. Applied value term paper It is to simplify the concept of the transaction that is publicly present in a more accessible form.
6213. Approximation of functions 3.08 MB.
The first consists in replacing some function specified analytically or table with another function close to the original but simpler and more convenient for calculations. For example, the replacement of the function by the polynomial allows to receive simple formulas numerical integration and differentiation; Replacing the table with an approaching function allows you to get values \u200b\u200bat its intermediate points. The second task is also the restoration of the function on a certain section along the values \u200b\u200bof the function specified on this cut in the discrete set of points. The answer to such a question ...
14058. Evolution of state functions 29.99 KB.
Russian state As a legal phenomenon, first of all, should ensure the implementation of the appointment of the state as well as its main constitutional characteristics of both the Democratic Federal Law Social Second State with the Republican Form of the Board. The main purpose of the state is determined by Art.

Normal form logical formula Does not contain implication marks, equivalence and denial of non-elementary formulas.

The normal form exists in two types:

    conjunctive Normal Form (KNF) - conjunction of several disjunctions, for example, $ \\ left (A \\ Vee \\ Overline (B) \\ Vee C \\ Right) \\ WEDGE \\ LEFT (A \\ Vee C \\ Right) $;

    diaunctive Normal Form (DNF) - disjunction of several conjunctions, for example, $ \\ left (A \\ Wedge \\ Overline (B) \\ WEDGE C \\ RIGHT) \\ Vee \\ Left (B \\ Wedge C \\ Right) $.

SKFF

Perfect Conjunctive Normal Form (SCFF) - This is a CNF, satisfying three conditions:

    does not contain the same elementary disjunction;

    none of the disjunction contains the same variables;

    each elementary disjunction contains each variable from those included in this PFF.

Any Boolean formula, which is not identically true, can be represented in SKFF.

Rules for constructing SCFF on the truth table

For each set of variables in which the function is 0, the amount is recorded, and the variables that have 1 are taken with negation.

SDNF.

Perfect disjunctive normal form (SDNF) - This is a DNF satisfying three conditions:

    does not contain the same elementary conjunctions;

    none of the conjunctions contains the same variables;

    each elementary conjunction contains each variable from those included in this DNF, besides in the same order.

Any boolean formula, which is not identically false, can be represented in the SDNF, besides the only way.

Rules for building a SDNF on the truth table

For each set of variables in which the function is 1, the product is written, and the variables that have a value of 0 are taken with negation.

Examples of finding SCPF and SDNF

Example 1.

Record a logical function by its truth table:

Picture 1.

Decision:

We use the Rule of Building the SDNF:

Figure 2.

We will receive the SDNF:

We use the Rule of Building SCPF.

We introduce the concept of elementary disjunction.

Elementary disjunction is called the expression

The conjunctive normal form (PFF) of the logical function is the conjunction of any finite set of pairs of various elementary disjunctions. For example, logical functions

represent the conjunctions of elementary disjunctions. Consequently, they are recorded in a conjunctive normal form.

An arbitrary logical function specified by the analytical expression can be given to the PFF by performing the following operations:

Use of the inversion rule, if the negation operation is applied to a logical expression;

Use of distribution axioms regarding multiplication:

Use of the absorption operation:

Exceptions in disjunction of repetitive variables or their denials;

Removal of all identical elementary disjunctions, except one;

The removal of all disjunctions, which simultaneously enter the variable and its denial.

The justice of the listed operations follows from the main axes and the identical relationship of the Logic algebra.

The conjunctive normal form is called perfect if each incoming elementary disjunction contains in direct or inverse form all the variables on which the function depends on.

The transformation of the CNF to the perfect CNF is carried out by performing the following operations:

Adding to each elementary disjunction of conjunctures of variables and their denials, if they are not included in this elementary disjunction;

Use of distribution axioms;

Removal of all identical elementary disjunctions, except one.

In perfect CNF, any logical function can be presented, except

identical equal unit (). A distinctive feature of the perfect KNF is that the representation of a logical function is unique.

Elementary disjunctions included in the perfect PFF function are called the constituent of zero. Each constituent of zero, which is included in the perfect KNF, turns to zero on the only set of variables, which is a zero set of function. Consequently, the number of zero sets of a logical function coincides with the number of the constituent of zero included in its perfect PFF.

The logic function of the zero constant in the perfect KNF is conjunction 2NConstituent zero. We formulate a rule of compilation of SCFF logical function on the matching table.

For each row of the correspondence table, in which the function is zero, the elementary disjunction of all variables is composed. At the same time, the variable itself enters the disjunction if its value is zero, or denial if its value is one. The obtained elementary disjunctions are combined by the conjunction sign.


Example 3.4.For the logical function z (x), a given table of conformity 2.2, we define a perfect conjunctive form.

For the first row of the table, which corresponds to the zero set of function 000, we find the constituent of zero. By performing similar operations for the second, third and fifth lines, we define the desired perfect PFF function:

It should be noted that for functions, the number of single sets of which exceeds the number of zero sets, more compact is their entry in the form of SCFF and vice versa.

Share with friends or save for yourself:

Loading...