Truth Tables PDF
Document Details
Uploaded by SimplifiedIodine
Tags
Summary
This document explains truth tables, a crucial concept in logic. It details how truth tables are used to solve logical operations (AND, OR, NOT) in binary systems. The document looks at truth tables in the context of the knight and knave problems.
Full Transcript
Truth Tables Return to Table of Contents https://njctl.org/video/?v=yPRJxdSpiJY Knight vs. Knave Logic problems, or somet...
Truth Tables Return to Table of Contents https://njctl.org/video/?v=yPRJxdSpiJY Knight vs. Knave Logic problems, or sometimes called brain teasers, can appear difficult to solve for many. Let's examine the problem of the Knight and Knave which has long been the inspiration for many other problems with a seemingly impossible choice. The problem is this: Knights always tell the truth and Knaves always lie. On a path, you encounter both. The first says to you "we are both knaves". How can you determine who is the knight and who is the knave? Truth Tables The question seems impossible, however, in reality, it is a simple binary problem. Truth tables help us perform logical operations between inputs to show a final output. They determine the truth value of an argument. Truth Tables In the case of our knight and knave, let's examine all the possibilities below. The table shows any outcome of the 1st and 2nd person lying. 1st 2nd T T T F F T F F Truth Tables The statement made is "we are both knaves." If the first person is telling the truth, that would make the 1st and 2nd person knaves, regardless of whether the second person is telling the truth or not. 1st 2nd 1st 2nd T T knave knave T F knave knave F T F F Truth Tables The statement made is "we are both knaves." If the first person is lying, he can't be a knight, but because his statement is a lie, that would make the 2nd person a knight. 1st 2nd 1st 2nd T T knave knave T F knave knave F T knave knight F F knave knight Truth Tables By looking at the truth tables, we can see which line the false matches up with a knave and the true matches up with a knight. Therefore, we can draw the conclusion that the 1st person is the knave and the 2nd person is the knight. 1st 2nd 1st 2nd T T knave knave T F knave knave F T knave knight F F knave knight Truth Tables Truth tables are very useful in solving logical operations. The most common operations are: 1) AND 2) OR 3) NOT Truth Tables AND is the logic operation where given two binary inputs, p and q (denoted by Λ), both need to be true for the output to be true. p q pΛq T T T T F F F T F F F F Truth Tables OR is the logic operation where given two binary inputs, p and q (denoted by v), only one or the other need to be true for the output to be true. p q pvq T T T T F T F T T F F F Truth Tables NOT is the logic operation for negation where given a binary input, p (denoted by ~), the opposite is the result. p ~p T F F T