Assignment 2 Sample problems. Consider the following expression: ((False and not True) or False or...
-
date post
20-Dec-2015 -
Category
Documents
-
view
291 -
download
3
Transcript of Assignment 2 Sample problems. Consider the following expression: ((False and not True) or False or...
Assignment 2 Sample problems
Consider the following expression:
((False and not True) or False or (True and not True))
• True• False
Consider the following expression:
((False and not True) or False or (True and not True))
• True• False
How can we get ?
1. (False and not True) => False and False=>False2. (True and not True) => True and False=>False3. False or False or False => False
Consider the following expression:
((False and (not True or False)) and (False or True))
• True• False
Consider the following expression:
((False and (not True or False)) and (False or True))
• True• False
How can we get ?
1. (not True or False) => False or False=>False2. (False and (not True or False)) => False and False=>False3. (False or True)) => True4. ((False and (not True or False)) and
(False or True)) =>False and True=>False
Consider the following expression:
(not not True or True) and ((False and False) or (not not True or not False))
• True• False
Consider the following expression:
(not not True or True) and ((False and False) or (not not True or not False))
• True• False
How can we get ?
1. (not not True or True) => True or True=>True2. (False and False) =>False3. (not not True or not False)) => True or
True =>True4. (not not True or True) and ((False and
False) or (not not True or not False)) =>True and (False or True)=>True and True=True
Consider the following expression: X=True Y=False C= True
(not X and Y) or (C and X) or (not not Y or X)) • True• False
Consider the following expression: X=True Y=False C= True
(not X and Y) or (C and X) or (not not Y or X)) • True• False
How can we get ?
1. (not X and Y) =>not True and False=>False2. (C and X) =>True and True=>True3. (not not Y or X) => False or True =>True4. (not X and Y) or (C and X) or (not not Y
or X) =>False or True or True=>True
Consider the following expression: X=True Y=False C= True
(Y and not C) and ((not (Y or X)) or (not (C and X))
• True• False
Consider the following expression: X=True Y=False C= True
(Y and not C) and ((not (Y or X)) or (not (C and X))
• True• False
How can we get ?1. (Y and not C) =>False and False=>False2. (not (Y or X)) =>(not Y)and (not X)=>True
and False=>False3. (not (C and X))=> (not C) or (not X)
=>False or False=>False4. (Y and not C) and ((Y or not X) or (not not
C and not X)) =>False and (False or False)=>False
Without knowing whether X is true or false, the result of
not X and X • True• False
Without knowing whether X is true or false, the result of
not X and X • True• False
How can we get ?
1. (not X and X ) X=True: =>False and False=>False X= False: =>True and False=>False
Consider the following circuit. light is on in function of a, b, c
ba
c
Consider the following circuit. light is on in function of a, b, c
ba
c
(a and b) or c
Fill in the following truth table by entering True or False in the blanks
A B A and (B or not A)
False False
False True
True False
True True
Fill in the following truth table by entering True or False in the blanks
A B A and (B or not A)
False False False
False True False
True False False
True True True
How can we get ?
A and (B or not A)1. False and (False or not False) =>False
and true=>False2. False and (True or not False)=>False and
True => False3. True and (False or not True)=>True and
False=> False4. True and (True or not True)=> True and
True=>True
For each of the truth tables below, write a logical expression to match the truth table (i.e. C = something that can include As, Bs, nots, ands, and ors). The simplest answer is preferred.
A B C
False False False
False True True
True False False
True True False
For each of the truth tables below, write a logical expression to match the truth table (i.e. C = something that can include As, Bs, nots, ands, and ors). The simplest answer is preferred.
The answer is (not A) and B
A B C
False False False
False True True
True False False
True True False
How can we get ?
In the truth table, we find (not A) and B in the second row can make C is True.
For each of the truth tables below, write a logical expression to match the truth table (i.e. C = something that can include As, Bs, nots, ands, and ors). The simplest answer is preferred.
A B C
False False False
False True True
True False True
True True False
For each of the truth tables below, write a logical expression to match the truth table (i.e. C = something that can include As, Bs, nots, ands, and ors). The simplest answer is preferred.
The answer is (not A and B) or (A and not B)Another answer is (A or B) and (not A or not B)
A B C
False False False
False True True
True False True
True True False
How can we get ?
In the truth table
A B C minterm maxterm
False False False not A and not B A or B
False True True not A and B A or not B
True False True A and not B not A or B
True True False A and B not A or not B
Use the circuit shown below to answer the following
questions. A
B
C
Fill in the following truth table by entering True or False in the blanks
A B C
False False
False True
True False
True True
Fill in the following truth table by entering True or False in the blanks
A B C
False False False
False True True
True False False
True True False
What is a logical expression for the circuit/table using boolean operators (AND, OR, NOT)?
What is a logical expression for the circuit/table using boolean operators (AND, OR, NOT)?
The answer is : (not A) and B