# Thread: Logic - Truth Tables

1. ## Logic - Truth Tables

i have an exam tommorrow on logic and i dont understand the truth tables at ALL!

i know how to set one up, i just dont understand how to find out if it is True or False at the end. like this for example:
p q [(p→q)^┐q]→┐p
T T T
T F T
F T T
F F T

and

p q [(p→q)^q]→p
T T T
T F T
F T F
F F

If p is F and q is T, why is it T for the first one and F for the second?? im just completely lost.

2. Originally Posted by Foink
i have an exam tomorrow on logic and i don’t understand the truth tables at ALL!
If that is a true statement then you may just have to except what comes.
I do not think that you have enough time before the exam to do fifty truth-tables.
The only way to learn to do then is to do many, many, many tables.

3. I don't care if I have to pull an all-nighter lol.

Can you explain why they were different in the example? I've gone over the rules several times and I keep finding it to be False for the first one as well. It's getting to be frustrating :-/

4. Hello, Foink!

I'm afraid there's no quick fix for you.
I can only show you the truth tables and hope you catch on . . .

$[(p \to q) \:\wedge \sim\!q] \to \:\sim\!p$
$\begin{array}{c|c|cccccccc}
p & q & [(p & \to & q) & \wedge & \sim q] & \to & \sim p \\ \hline
T & T & T & T & T & F & F & {\color{blue}T} & F \\
T & F & T & F & F & F & T & {\color{blue}T} & F \\
F & T & F & T & T & F & F & {\color{blue}T} & T \\
F & F & F & T & F & T & T & {\color{blue}T} & T
\end{array}$

$[(p \to q) \wedge \:q] \to p$
$\begin{array}{c|c|ccccccc} p & q & [(p & \to & q) & \wedge & q] & \to & p \\ \hline
T & T & T & T & T & T & T & {\color{blue}T} & T \\
T & F & T & F & F & F & F & {\color{blue}T} & T \\
F & T & F & T & T & T & T & {\color{blue}F} & F \\
F & F & F & T & F & F & F & {\color{blue}T} & F
\end{array}$

5. OMG it finally clicked. Thank you!

6. Originally Posted by Foink
i have an exam tommorrow on logic and i dont understand the truth tables at ALL!

i know how to set one up, i just dont understand how to find out if it is True or False at the end. like this for example:
p q [(p→q)^┐q]→┐p
F T T
In this one, P is false, so (p→q) Is true no matter what. (because if p then q, but p is false, so it necessitates nothing, if I walk outside then the world will end, but I don't walk outside so the statement it doesn't matter whether the world ends or not, the statement hasn't been shown to be false since it hasn't been tested) So the left half of (p→q)^┐q Is true.

Now if the right half is true, then the "and" statement is true. But q is true, so then you plug true into ┐q and you get ┐true. Thus the right half of (p→q)^┐q is false.

Since "and" requires that both sides be true, the and statement is false.

Since this whole and statement is the antecedent (the "if" part) it means that the the the left part is false, so using the same logic from before, we see that the statement is not tested, and so it does not matter what comes in the "then" portion. The statement is true no matter what comes.

So to recap
[(p→q)^┐q]→┐p
p is false, q is true so this becomes
[(F→T)^┐q]→┐p
which is true so
[T^┐q]→┐p
Then plug in q
[T^┐T]→┐p
which becomes [T^F]→┐p
which is false
F→ ┐p
So at this point, the statement is true no matter what.

-------

[(p→q)^q]→p

Now on the second one, we first assess the left half of the "and" statement.
(p→q) We know P is false, so this half is true.
(p→q)^q becomes T^q

And we know q is true, so this becomes T^T

Since you need T^T for an and statement to be true, it follows that the left half is true.
[(p→q)^q]→p becomes [T^T]→p which becomes T→p

However, we know that P is false, so this becomes T→F

Which is a false statement. (if I go outside the world will end, I went outside, the world did not end, therefore the if-then is false.)

----------

Now try doing the truth table for:
1. (a^b)→ ┐(┐b v ┐b)

2. (┐b → a ) v ┐(a → b)

3. [(b → ┐a) ^ ┐ b] → ┐a