Download presentation
Presentation is loading. Please wait.
Published byDiana Hubbard Modified over 9 years ago
1
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-1 Binary logic Binary logic is a mathematical system that lets us reason about logic statements IF The garage door is open AND The engine is running THEN The car can be backed out of the garage IF The N-S light is green AND The E-W light is red AND (The N-S light has been green for more than 45 sec. OR There are no cars on the N-S road) THEN The N-S lights can be changed from green to yellow The car can be backed out only when both conditions are true The light will become yellow only if it’s been green for > 45 seconds or nobody is on the road
2
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-2 Combinational Logic IF The garage door is open AND The engine is running THEN The car can be backed out of the garage Each input can be either True or False What is the output for each combination of inputs? Door Open?Engine Running?OK to Back Out FalseFalseFalse FalseTrueFalse TrueFalseFalse TrueTrueTrue There are 2 N combinations to be considered for N binary inputs.
3
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-3 Truth tables X Y X and Y FFFFTFTFFTTTFFFFTFTFFTTT Truth tables enumerate all possible input combinations For each input, tabulate the output There may be more than one independent output X not X F T T F InputOutput X Y X or Y FFFFTTTFTTTTFFFFTTTFTTTT A truth table that enumerates all input combinations completely defines any logic function For n inputs: 2 n rows
4
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-4 The Binary Connection X Y X and Y 000010100111000010100111 Truth or Falsehood is a Binary operation Everything is either True or False, no in-betweens Represent True using ‘1’ Represent False using ‘0’ X not X 0 1 1 0 InputOutput 2.2 X Y X or Y 000011101111000011101111 Note: Number combinations in binary numeric order: 00, 01, 10, 11
5
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-5 Example Function F(a,b,c,d) should be 1 whenever there are an even number of inputs that are 1 Function G(a,b,c,d) should be 1 whenever c is 1 or d is 1, but not when a or b is 1 abcdFG000010000101001001001111010000010110011010011100100000100110101010101100110010110100111000111110abcdFG000010000101001001001111010000010110011010011100100000100110101010101100110010110100111000111110
6
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-6 Illegal Inputs The women’s basketball team is looking for good players (women 5’9” or taller) The data available is: M: True if male F: True if female T: True if 5’9” or taller S: True if < 5’9” Many combinations are impossible Can’t be Male and Female Can’t be Tall and Short Impossible input combinations are marked with an ‘X’ Called a don’t care X X X X X 0 0 X X 1 0 X X X X X 1111 0111 1011 0011 1101 0101 1001 0001 1110 0110 1010 0010 1100 0100 1000 0000 GoodSTFM
7
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-7 Logic Primitives precedence rules NOT before AND before OR not(x) x x’ x and y x y xy x or y x y x+y
8
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-8 Complex expressions C D T2T2 C D T1T1 B C D B A Z
9
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-9 Timing diagram A timing diagram may be used to express the behavior of a logic system ABCT1T2Z 000100 001111 010111 011111 100000 101010 110010 111010 B C Z A T2 T1 A B C T2 Z 1 0 1 0 1 0 1 0 1 0 1 0 Inputs 00001111 00110011 01010101 11110000 01110111 01110000
10
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-10 Functions of two variables F0 0 0 0 0 F1 0 0 0 1 F2 0 0 1 0 F3 0 0 1 1 F4 0 1 0 0 F5 0 1 0 1 F6 0 1 1 0 F7 0 1 1 1 F8 1 0 0 0 F9 1 0 0 1 F10 1 0 1 0 F11 1 0 1 1 F12 1 1 0 0 F13 1 1 0 1 F14 1 1 1 0 F15 1 1 1 1 X 0 0 1 1 Y 0 1 0 1 0 XYXYX+Y X Y 1 There are sixteen functions of two variables… We’ve only seen eight of them so far
11
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-11 NANDs and NORs X Y Z 0 0 1 0 1 1 1 0 1 1 1 0 X nand Y = not (X and Y) = X Y Z 0 0 1 0 1 0 1 0 0 1 1 0 X nor Y = not (X or Y) =
12
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-12 XORs and XNORs X Y Z 0 0 0 0 1 1 1 0 1 1 1 0 Exclusive OR - XOR XOR - True if both inputs are different X Y Z 0 0 1 0 1 0 1 0 0 1 1 1 Equivalence gate - XNOR XNOR - True if both inputs are the same
13
Seattle Pacific University EE 1210 - Logic System DesignTruthTables-13 What’s left? Remaining functions are implication functions, which aren’t commonly used F0 0 0 0 0 F1 0 0 0 1 F2 0 0 1 0 F3 0 0 1 1 F4 0 1 0 0 F5 0 1 0 1 F6 0 1 1 0 F7 0 1 1 1 F8 1 0 0 0 F9 1 0 0 1 F10 1 0 1 0 F11 1 0 1 1 F12 1 1 0 0 F13 1 1 0 1 F14 1 1 1 0 F15 1 1 1 1 X 0 0 1 1 Y 0 1 0 1 0 XYX Y X+Y X Y 1
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.