Boolean Algebra George Boole 2 November 1815 – 8 December ...
Algebra de Boole y Simplificacion
-
Upload
notanumber11 -
Category
Documents
-
view
245 -
download
0
Transcript of Algebra de Boole y Simplificacion
-
8/13/2019 Algebra de Boole y Simplificacion
1/45
Seminario: lgebra de Boole y
simplificacin lgicaAutomtica Industrial
Grado en Ingeniera QumicaUniversidad de Santiago de Compostela
-
8/13/2019 Algebra de Boole y Simplificacion
2/45
Funciones bsicas
Boolean functions : NOT, AND, OR,exclusive OR(XOR) : odd function
exclusive NOR(XNOR) : even function(equivalence)
-
8/13/2019 Algebra de Boole y Simplificacion
3/45
Funciones bsicas
AND Z=X Y or Z=XY
Z=1 if and only if X=1 and Y=1, otherwise Z=0
OR Z=X + Y
Z=1 if X=1 or if Y=1, or both X=1and Y=1. Z=0 if and only ifX=0 and Y=0
NOT Z=Xor
Z=1 if X=0, Z=0 if X=1
-
8/13/2019 Algebra de Boole y Simplificacion
4/45
Funciones bsicas
-
8/13/2019 Algebra de Boole y Simplificacion
5/45
Operaciones booleanas
Boolean AdditionLogical OR operation
Ex 4-1) Determine the values of A, B, C, and D that make the sum termA+B+C+D
Sol) all literals must be 0 for the sum term to be 0A+B+C+D=0+1+0+1=0A=0, B=1, C=0, and D=1
Boolean Multiplication
Logical AND operation
Ex 4-2) Determine the values of A, B, C, and D for ABCD=1
Sol) all literals must be 1 for the product term to be 1
ABCD=1010=1A=1, B=0, C=1, and D=0
-
8/13/2019 Algebra de Boole y Simplificacion
6/45
Identidades bsicas
-
8/13/2019 Algebra de Boole y Simplificacion
7/45
Propiedades del lgebra de Boole
Propiedad commutativaEl orden de los literales no importa
A + B = B + A
A B = B A
-
8/13/2019 Algebra de Boole y Simplificacion
8/45
Propiedades del lgebra de Boole
Propiedad asociativa:
A + (B + C) = (A + B) + C (=A+B+C)
A(BC) = (AB)C (=ABC)
-
8/13/2019 Algebra de Boole y Simplificacion
9/45
Propiedades del lgebra de Boole
Propiedad distributiva : A(B + C) = AB + AC
-
8/13/2019 Algebra de Boole y Simplificacion
10/45
Propiedades del lgebra de Boole
(A+B)(C+D) = AC + AD + BC + BD
-
8/13/2019 Algebra de Boole y Simplificacion
11/45
Teorema de DeMorgan
Teorema de DeMorgan
F(A,A, , + , 1,0) = F(A, A, + , ,0,1)
(A B) = A + B and (A + B) = A B
-
8/13/2019 Algebra de Boole y Simplificacion
12/45
Teorema de DeMorgan
-
8/13/2019 Algebra de Boole y Simplificacion
13/45
Anlisis de circuitos lgicos
Expresin Booleana de un circuito lgico:
-
8/13/2019 Algebra de Boole y Simplificacion
14/45
Tabla de verdad de un circuito lgico
Input OutputA B C D A(B+CD)
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 00 1 0 1 0
0 1 1 0 0
0 1 1 1 0
1 0 0 0 0
1 0 0 1 0
1 0 1 0 0
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
A(B+CD)=AB(C+C) (D+D) +A(B+B)CD=ABC(D+D) +ABC(D+D) +ABCD+ABCD=ABCD+ABCD+ABCD+ABCD+ABCD+ABCD
=ABCD+ABCD+ABCD+ABCD +ABCD
A(B+CD)=m11+m12+m13+m14+m15=(11,12,13,14,15)
-
8/13/2019 Algebra de Boole y Simplificacion
15/45
Simplificacin usando lgebraBooleana
Usando lgebra Booleana , simplificar la expresin:
AB+A(B+C)+B(B+C)
Sol) AB+AB+AC+BB+BC =B(1+A+A+C)+AC=B+AC
-
8/13/2019 Algebra de Boole y Simplificacion
16/45
Mapas de Karnaugh (*)This method coverts the truth table information into a
two-dimensional map. It then converts areas of 1s onthe map into groups. These groups are then identifiedand this gives us the simplest expression.
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
17/45
-
8/13/2019 Algebra de Boole y Simplificacion
18/45
STEP ONE
of the simplification process would be to fill in theKarnaugh Map
(Note: we normally only transfer 1s onto the map.)
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
19/45
STEP TWO
is to group the 1s. Groups are formed using the
following rules:1. Group sizes must be powers of 2 1, 2, 4, 8, 16, etc
no other size groups are allowed.
2. Groups must be square of rectangles (1 x 4 or 2 x 2
etc)3. Groups must be as large as possible (never group 2
groups of 2 if a group of 4 can be made.)
4. All 1s mustbe grouped.
5. A 1 may be grouped more than once.
6. Do not include redundant groups a redundant groupis a group that contains 1s which have all beenpreviously grouped.
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
20/45
STEP THREEidentifies the expression for each group. The groups
are examined one at a time. For a group the followingquestion is asked for each input one at a time:
For the group:Is the input logic state for every square in the group:
Always 1 if it is then the input appears in theexpression Always 0 - if it is then the not input appears in
the expression Both 1 and 0 - if it is then the input does not
appears in the expressionAfter each input has been checked, the expression is
the AND of the inputs states identified.
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
21/45
STEP FOUR
identifies the complete expression for the function.The individual group expressions are OR-ed togetherto give the simplified expression.
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
22/45
Example
The Truth Table and Karnaugh Map are shown below:
BABABAY
A B Y B A 0 1 Y0 0 0
0 1
1 0 1
1 1
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
23/45
111
1101
010
0100
Y10B AYBA
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
24/45
111
11101
01011
0100
Y10B AYBA
STEP 1
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
25/45
A B Y B A 0 1 Y
0 0 1 01 1
0 1 0
1 0 1 11
1 1 1
STEP 2
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
26/45
A B Y B A 0 1 Y
0 0 1 01 1
0 1 0
1 0 1 11
1 1 1
STEP 3
A always 1 so AB 1 and 0 so no BExpression
A 1 and 0 so no A
B always 0 so not BExpression
AB
(*) Fuente: Logic Equation Simplification.University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
27/45
-
8/13/2019 Algebra de Boole y Simplificacion
28/45
-
8/13/2019 Algebra de Boole y Simplificacion
29/45
Note there is one additional rule for grouping 1s on this
map and larger maps:
Rule: 1s may be grouped between the left hand columnand the right hand column.
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
30/45
ExampleA function F has the truth table shown below. Determine the
simplest Boolean Expression for the function.
A B C F A 0 0 1 1
0 0 0 1 C B 0 1 1 0 F
0 0 1 0 00 1 0 0
0 1 1 1 1
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 1
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
31/45
1111
1011
11011001
11111110
0010111
00100
F0110C B1000
1100AFCBA
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
32/45
1111
1011
11011001
11111110
0010111
00100
F0110C B1000
1100AFCBA
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
33/45
1111
1011
11011001
11111110
0010111
00100
F0110C B1000
1100AFCBA
A always 1 so AB 1 and 0 so no B
C 1 and 0 so no CExpression
A 1 and 0 so no AB always 1 so BC always 1 so CExpression
A
CB
A 1 and 0 so no AB always 0 so not BC always 0 so not C
Expression CB
-
8/13/2019 Algebra de Boole y Simplificacion
34/45
1111
1011
11011001
11111110
0010111
00100
F0110C B1000
1100AFCBA
Complete expression CBCBAF
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
35/45
ExampleThree judges A, B and C vote: 1 guilty and 0 not guilty. Design
a logic circuit using NAND only which will allow a majority
decision (F) to be found. e.g. A = 1, B = 0, C = 0 gives anoutput of 0 (not guilty)
A B C F A 0 0 1 1
0 0 0 C B 0 1 1 0 F0 0 1 0
0 1 0
0 1 1 1
1 0 01 0 1
1 1 0
1 1 1(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
36/45
A B C D Y A 0 0 1 1
0 0 0 0 C D B 0 1 1 0 Y
0 0 0 1
0 00 0 1 0
0 0 1 1 0 1
0 1 0 0
0 1 0 1 1 1
0 1 1 0
0 1 1 1 1 0
1 0 0 0
1 0 0 1
1 0 1 0
1 0 1 11 1 0 0
1 1 0 1
1 1 1 0
1 1 1 1
4-input
Karnaugh Map
This has 16 entrieson the Truth Table
and so theKarnaugh Map has16 squares
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
37/45
1111
0111
1011
00111101
0101
1001
0001
1 01110
0110
1 11010
0010
0 11100
0100 0 0
1000
Y0110C D B0000
1100AYDCBA
Note there is oneadditional rulefor grouping 1s
on this map and
larger maps:Rule: 1s maybe groupedbetween the top
row and thebottom row.
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
38/45
Example
Four judges A, B, C and D vote: 1 guilty and 0 not guilty.Obtain a Boolean Expression that will allow a majoritydecision to be found. In the case of a split decision
the vote of A determines the outcome Y.
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
39/45
11111
10111
11011
1001111101
10101
11001
0000111
1 01111000110
1111 101010
0001011
0 101100
00100 10 001000
Y0110C D B00000
1100AYDCBA
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
40/45
11111
10111
11011
1001111101
10101
11001
0000111
1 01111000110
1111 101010
0001011
0 101100
00100 10 001000
Y0110C D B00000
1100AYDCBA
Now formgroups
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
CA
-
8/13/2019 Algebra de Boole y Simplificacion
41/45
11111
10111
11011
1001111101
10101
11001
0000111
1 01111000110
1111 101010
0001011
0 101100
00100 10 001000
Y0110C D B00000
1100AYDCBA
Identify groups
A always 1 so AB 1 and 0 so no BC always 1 so CD 1 and 0 so no DExpression
CA
A always 1 so AB 1 and 0 so no B
C 1 and 0 so no CD always 1 so DExpression
DA
A always 1 so AB always 1 so BC 1 and 0 so no CD 1 and 0 so no DExpression
BA
A 1 and 0 so no A
B always 1 so BC always 1 so CD always 1 so DExpression
DCB
CA
-
8/13/2019 Algebra de Boole y Simplificacion
42/45
11111
10111
11011
1001111101
10101
11001
0000111
1 01111000110
1111 101010
0001011
0 101100
00100 10 001000
Y0110C D B00000
1100AYDCBA
Boolean Expression
DCBDACABAY
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
43/45
ExampleTwo 2-bit numbers (A,B) and (C,D) are to be compared.
If (A,B) > (C,D)then the G (greater than) output is to equal 1
If (A,B) < (C,D)then the L (less than) output is to equal 1
If (A,B) = (C,D)
then the E (Equal to) output is to equal 1e.g. A = 1, B = 0, C = 1, D = 1
10 (2) is less than 11 (3) so L = 1
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
44/45
1111
0111
1011
00111101
0101
1001
0001
1 01110
0110
1 11010
0010
0 11100
0100 0 0
1000
G0110C D B0000
1100AELGDCBA
(*) Fuente: Logic Equation Simplification.
University of Wales, Newport
-
8/13/2019 Algebra de Boole y Simplificacion
45/45
A 0 0 1 1
C D B 0 1 1 0 L
0 0
0 1
1 1
1 0
A 0 0 1 1
C D B 0 1 1 0 E
0 0
0 1
1 1
1 0
Expression GExpression L
Expression E(*) Fuente: Logic Equation Simplification.