1. Trang chủ
  2. » Kỹ Thuật - Công Nghệ

Lecture Digital logic design - Lecture 4: Boolean algebra

34 57 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 34
Dung lượng 627,42 KB

Nội dung

The main contents of the chapter consist of the following: Basic logic functions can be made from AND, OR, and NOT (invert) functions; the behavior of digital circuits can be represented with waveforms, truth tables, or symbols; primitive gates can be combined to form larger circuits; boolean algebra defines how binary variables can be combined;…

Lecture Boolean Algebra Logical Statements ° A proposition that may or may not be true: • Today is Monday • Today is Sunday • It is raining ° Compound Statements ° More complicated expressions can be built from simpler ones: • Today is Monday AND it is raining • Today is Sunday OR it is NOT raining • Today is Monday AND today is NOT Monday - (This is a contradiction) ° The expression as a whole is either true or false Things can get a little tricky… ° Are these two statements equivalent? • It is not nighttime and it is Monday OR it is raining and it is Monday • It is not nighttime or it is raining and Monday AND it is Monday Boolean Algebra ° Formal logic: In formal logic, a statement (proposition) is a declarative sentence that is either true(1) or false (0) ° It is easier to communicate with computers using formal logic ° Boolean variable: Takes only two values – either true (1) or false (0) They are used as basic units of formal logic Venn Diagrams A A B B A A B B A A A A B A B A A A  A B B   AB B Boolean Algebra ° Boolean Algebra is a mathematical technique that provides the ability to algebraically simplify logic expressions These simplified expressions will result in a logic circuit that is equivalent to the original circuit, yet requires fewer gates A B C AB+A(B+C)+B(B+C) B A C B+A C Boolean Algebra, Logic and Gates ° Logical operators operate on binary values and binary variables ° Basic logical operators are the logic functions AND, OR and NOT ° Logic gates implement logic functions ° Boolean Algebra: a useful mathematical system for specifying and transforming logic functions ° We study Boolean algebra as a foundation for designing and analyzing digital systems! ° A literal is a Boolean variable or its complement A minterm of the Boolean variables x1, x2, …, xn is a Boolean product y1y2…yn, where yi = xi or yi = -xi ° Hence, a minterm is a product of n literals, with one literal for each variable Boolean Switching ° Boolean (switching) variable x ∈ {0,1} • 0, are abstract symbols They may correspond to {false, true} in logic, {off, on} of a switch, {low voltage, high voltage} of a CMOS circuit, or other meanings ° Boolean space {0,1}n ° The configuration space of all possible {0,1 assignments to n Boolean variables E.g., the Boolean space spanned by (x1,x2) is {0,1}2 = {0,1}×{0,1} = {00, 01, 10, 11} Overview ° Logic functions with 1’s and 0’s • Building digital circuitry ° Truth tables ° Logic symbols and waveforms ° Boolean algebra ° Properties of Boolean Algebra • Reducing functions • Transforming functions Binary Variables ° Recall that the two binary values have different names: • True/False • On/Off • Yes/No • 1/0 ° We use and to denote the two values ° Variable identifier examples: • A, B, y, z, or X1 for now • RESET, START_IT, or ADD1 later The AN D Gat e A Y B ° This is an AND gate ° So, if the two inputs signals Truth Table are asserted (high) the A B Y output will also be asserted 0 Otherwise, the output will be deasserted (low) 0 1 The OR Gat e A B Y ° This is an OR gate A B Y ° So, if either of the two 0 input signals are 1 asserted, or both of 1 them are, the output 1 will be asserted Describing Circuit Functionality: Waveforms AND Gate A B Y 0 0 1 0 1 ° Waveforms provide another approach for representing functionality ° Values are either high (logic 1) or low (logic 0) ° Can you create a truth table from the waveforms? Consider three-input gates 3 Input OR Gate Ordering Boolean Functions ° How to interpret A B+C? • Is it A B ORed with C ? • Is it A ANDed with B+C ? ° Order of precedence for Boolean algebra: AND before OR ° Note that parentheses are needed here : Boolean Algebra ° A Boolean algebra is defined as a closed algebraic system containing a set K or two or more elements and the two operators, and + ° Useful for identifying and minimizing circuit functionality ° Identity elements • a+0=a • a.1=a ° is the identity element for the + operation ° is the identity element for the operation Commutatively and Associativity of the Operators ° The Commutative Property: For every a and b in K, • a+b=b+a • a.b=b.a ° The Associative Property: For every a, b, and c in K, • a + (b + c) = (a + b) + c • a (b c) = (a b) c Distributivity of the Operators and Complements ° The Distributive Property: For every a, b, and c in K, • a+(b.c)=(a+b).(a+c) • a.(b+c)=(a.b)+(a.c) ° The Existence of the Complement: For every a in K there exists a unique element called a’ (complement of a) such that, • a + a’ = • a a’ = ° To simplify notation, the operator is frequently omitted When two elements are written next to each other, the AND (.) operator is implied… • a+b.c=(a+b).(a+c) • a + bc = ( a + b )( a + c ) Dua lity ° The principle of duality is an important concept This says that if an expression is valid in Boolean algebra, the dual of that expression is also valid ° To form the dual of an expression, replace all + operators with operators, all operators with + operators, all ones with zeros, and all zeros with ones ° Form the dual of the expression a + (bc) = (a + b)(a + c) ° Following the replacement rules… a(b + c) = ab + ac ° Take care not to alter the location of the parentheses if they are present Involutio n ° This theorem states: a’’ = a ° Remember that aa’ = and a+a’=1 • Therefore, a’ is the complement of a and a is also the complement of a’ • As the complement of a’ is unique, it follows that a’’=a ° Taking the double inverse of a value will give the initial value Absorptio n ° This theorem states: a + ab = a a(a+b) = a ° To prove the first half of this theorem: a + ab = a + ab = a (1 + b) = a (b + 1) = a (1) a + ab = a DeMorgan’s Theorem ° A key theorem in simplifying Boolean algebra expression is DeMorgan’s Theorem It states: (a + b)’ = a’b’ (ab)’ = a’ + b’ ° Complement the expression a(b + z(x + a’)) and simplify (a(b+z(x + a’)))’  = a’ + (b + z(x + a’))’ = a’ + b’(z(x + a’))’ = a’ + b’(z’ + (x + a’)’) = a’ + b’(z’ + x’a’’) = a’ + b’(z’ + x’a) Boolean & DeMorgan’s Theorems 1)     X  0   0 10A)     X  Y   Y   X 2)     X   1   X 10B)     X  Y   Y   X 3)     X   X   X 11A)     X YZ 4)     X   X   0 11B)     X  5)     X  0   X 12A)     X Y 6)     X   1   1 12B)     X Y W 7)     X   X   X 13A)     X XY X Y 8)     X   X   1 13B)     X XY X Y 9)     X   X 13C)     X XY X Y 13D)     X XY X Y Commutative  Law XY Z Y Z Z X Y XY Z 14A)     X Y  X   Y 14B)     X  Y  X  Y Z Associative  Law XZ XW XZ YW Consensus  Theorem DeMorgan’s YZ Distributiv e Law DeMorgan Shortcut BREAK THE LINE, CHANGE THE SIGN Break the LINE over the two variables,  and change the SIGN directly under the line A B A B For Theorem #14A, break the line, and  change the AND function to an OR function.  Be sure to keep the lines over the variables A B A B For Theorem #14B, break the line, and  change the OR function to an AND function.  Be sure to keep the lines over the variables Summary ° Basic logic functions can be made from AND, OR, and NOT (invert) functions ° The behavior of digital circuits can be represented with waveforms, truth tables, or symbols ° Primitive gates can be combined to form larger circuits ° Boolean algebra defines how binary variables can be combined ° Rules for associativity, commutativity, and distribution are similar to algebra ° DeMorgan’s rules are important • Will allow us to reduce circuit sizes ... ion - logic is light on - logic is light off Switches in parallel => OR Switches in series => AND • NOT input: - logic is switch open - logic is switch closed Normally-closed switch => NOT C Logic. .. C Boolean Algebra, Logic and Gates ° Logical operators operate on binary values and binary variables ° Basic logical operators are the logic functions AND, OR and NOT ° Logic gates implement logic. .. 01, 10, 11} Overview ° Logic functions with 1’s and 0’s • Building digital circuitry ° Truth tables ° Logic symbols and waveforms ° Boolean algebra ° Properties of Boolean Algebra • Reducing functions

Ngày đăng: 12/02/2020, 15:51

TỪ KHÓA LIÊN QUAN

w