Skip to main content
Humanities LibreTexts

33.1: Truth Tables

  • Page ID
    95346
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    The whole point of learning how to symbolize sentences in the last chapter is that we are now able use them in truth tables. Truth tables are a formal logic tool that allow us to determine under what conditions a statement or group of statements are true or false or, in other words, the statement’s truthvalue. ‘Truth-value’ is the term we use to refer to whether a statement is true, false, or indeterminant. We will be able to use these tables to determine:

    1. If a statement is a tautology, a contradiction, or a contingency.
    2. If a pair of statements are consistent or logically equivalent.
    3. If an argument is valid or invalid.

    This will be a fair amount to take in. For now, let’s focus on tables and how to make them.

    Getting Started

    It is helpful to think of a truth table as a type of spreadsheet chart. On one side of the chart there will be columns representing the possible truth-value combinations for the terms in the statement, and on the right we will be using these truth-values to “solve” the table by getting information about the sentence. The left side will look more or less the same for every truth table, so you should be able to get the hang of setting them up fairly quickly. The number of columns and rows the left side of the table has depends on the number of variables (one for each symbolized simple sentence in the statement we are considering. For every simple sentence in the claim, there will be one column for that variable and the number of rows will start at 2 and double for every additional simple sentence. So, for a claim ‘P’ we would have one column and two rows. For ‘P & Q,’ we would have two columns and 4 rows, for ‘(P & Q) & R’ we would have three columns and 8 rows, etc. Technically speaking, there is no cap to how big a table can be, so you could make one for any number of simple sentences. They get pretty unwieldy pretty quickly though, so we won’t ever ask you to work one for more than three variables. At this point, it will help to look at some examples.

    Screenshot (140).png

    Screenshot (141).png

    Now that we have the blank tables, we need to fill them in with the truth value combinations. To do that, we will enter T’s and F’s into the boxes. As you might expect, ‘T’ stands for ‘true,’ and ‘F’ stands for ‘false.’ The idea is that these T’s and F’s will show us all the possible combinations in which our simple sentence can be true or false relative to each other. Let’s go back to the examples. When there is only one simple sentence, there are only two possible options: P can be true or false. So, the table looks like this.

    Screenshot (143).png

    If there are two variables, there will be twice as many possibilities, because both can be true, the first can be false and the second true, the first can be true and second false, and both can be false. This gives us a table that looks like this:

    Screenshot (144).png

    Things get more complicated for our set of three variables. Rather than write out all the options, we can just look at the table below. Notice that each row has a different combination of truth values for each letter, starting with them all being true and ending with them all being false.

    Screenshot (145).png

    Just as a reminder, you can always build a table with more simple sentences, but every time you will be doubling the number of rows.

    The most observant of you will likely have noticed a pattern in how these three examples were set up. The furthest right column is T’s halfway down and then F’s the rest of the way down. The column furthest to the left alternates T’s and F’s, and the middle column alternates by twos. This will always be the case, and the great thing about this is it helps us populate the truth values on the left side of the table very quickly. There is no need to worry about whether we’ve covered all the permutations. If we alternate like this, we will have all the options with no repeats. (If we did find ourselves making a table for 4 simple sentences, then we would just add another row to the inside; the table would be twice as long, so we’d have 8 T’s and then 8 F’s).

    The Rules

    The right side of a truth table is where the work really gets done. On the right side, we use the values we entered on the left side and a handful of rules to determine the truth-values of complex sentences. Each of the logical connectors we used to symbolize sentences in the last chapter (&, v, →, ← →, ~) have a corresponding chart that tells us what the truth-value should be for a given row on the right side. Let’s look at the charts one by one, starting with the and (&) function.

    Screenshot (146).png

    In order for ‘P & Q’ to be true, both ‘P’ and ‘Q’ need to be true. This should be obvious, given the way ‘and’ works in our traditional grammar. It should also be obvious that no other combination of truth-values will make ‘P & Q’ true, because either ‘P’ or ‘Q’ will be false on every other line of the table, and they can’t both be true if one of them is false. This is what the above table tells us. When we want to know the truth value for the ‘&,’ we look to the columns on the left side of the table for the variables on either side of the ‘&’ symbol. Going down each row, we look to see if both of them are true. If they are, we put a ‘T,’ and if even one of them is false, we put an ‘F’.

    The ‘or’ (v) function is a little more complicated. This is because ‘or’ is a tricky word in English. Sometimes we use ‘or’ to mean ‘just one of two options,’ and sometimes we mean ‘either or both’. The former we call an exclusive ‘or,’ and the latter is an inclusive ‘or’. What’s important to keep in mind is that when we use the logical operator ‘v,’ we always mean the inclusive ‘or’. So, the conditions of ‘v’ are met if one or both of the variables are true. This means that the truth of ‘P’ is enough to make ‘P v Q’ true, as is the truth of ‘Q,’ and the truth of ‘P’ and ‘Q’. ‘P v Q’ is represented in the following chart.

    Screenshot (147).png

    This chart should look as you expected – the only line of the table where ‘P v Q’ is false is the line where neither ‘P’ nor ‘Q’ are true.

    Conditionals (→) complicate things a bit more. We talked about conditionals at length in Chapter 3. As a reminder, a conditional says that if the first statement is true, then the second one is also. Thinking about what this means in reverse, the only way that a conditional would be false is if the first statement is true, and the second one false. If that makes sense to you, then this table should as well. If not, hopefully the table will help.

    Screenshot (148).png

    Looking at first line of the table, it should be obvious that ‘P’ and ‘Q’ being true makes ‘P → Q’ true (if the ‘P’ is true, and it is, then ‘Q’ will be true, and it is). Now, look at the second line. It is saying: ‘P’ is not true, and ‘Q’ is. The conditional says that if ‘P’ is true, then ‘Q’ will be true, but it doesn’t say anything about ‘P’ not being true. So, the conditional is still true. It is the third line where we see the conditional shown to be false. The conditional requires that if ‘P’ is true, then ‘Q’ is as well, and that isn’t the case with this truth-value pairing. The last row is true for the same reason the second line is. The conditional only cares about cases where ‘P’ is true.

    Next, we will look at the biconditional (← →). Essential to understanding the biconditional table is grasping that the second statement is only true when the first one is as well. Since the second statement is only true when the first statement is, when the first is not true, the second one cannot be true either. Thinking about this in terms of the concepts from Chapter 3, a biconditional occurs when the antecedent and consequent of a conditional are jointly necessary and sufficient for each other. Here is the table:

    Screenshot (149).png

    The final table is the negation (~). The negation just means when the proposition that follows the negation is false, the negation is true, and when the proposition following the negation is true, the negation is false. Negations are the easiest connector to deal with because all you have to do is take the opposite – turn T’s to F’s and F’s to T’s. Here is the table:

    Screenshot (150).png

    You now have all the basic tools to make truth tables. These tools can be used to make tables for any complex sentence, using any number of logical connectors.

    Completing the Table

    With these rules in place, we can now use them to solve some tables. Let’s start with the complex sentence:

    ~(P v Q)

    The first step is set up the left side of the table. With two variables, that will mean 4 rows.

    Screenshot (151).png

    Next we set up the right side. We are solving for ~(P v Q), so that will go at the top of the right column.

    Screenshot (152).png

    Next, we need to determine the truth-values for the complex sentence. We can see that two logical operators – ‘~’ and ‘v’ – are being used, so we know we need to refer to the tables that direct us on how to use those operators. The ‘~’ table tells us we need to take the opposite of what follows the ‘~’ symbol. But before we can do that, we need to know the truth value for (P v Q). To figure that out, we use the ‘v’ rule. As we can see from the ‘v’ table, P v Q is true every time either P or Q is true. Giving us:

    Screenshot (153).png

    Lastly, we take the opposite of those truth-values (applying the negation rule) and we get:

    Screenshot (154).png

    Thinking through what ~(P v Q) means, that neither P or Q are true, this table should make sense. The only line that is marked as true is the last one (where P and Q are both false).

    For more complicated tables, it helps to have some scrap paper on hand. Consider [~(P v ~Q)] & (Q → P)]. In these complex sentences, just like in math, we work from inside the parentheses out. Let’s look at it step by step. We know that ‘P v ~Q’ is true on every line where ‘P’ is true. So, we put a ‘T’ on rows 1 and 3. We also know it is true on every line that ‘Q’ is false. So, we put a ‘T’ on row 4 (and there already is one on line 3). The only row left is the second, and that one gets an ‘F’.

    Screenshot (155).png

    Now we apply the negation rule and take the opposite of that to get:

    Screenshot (156).png

    Next, we do the second side of the conjunction. Using the conditional rule, we know if ‘Q’ is true, then ‘P’ must be true. Look for the line where this isn’t the case (line 2). This line is false, and all other ones are true.

    Screenshot (157).png

    All that is left now is to apply the conjunction rule and identify the lines where both [~(P v ~Q)] and (Q → P) are true. The table shows that there is no line where this is the case, so they all get an ‘F’.

    Screenshot (158).png

    And that is how you make truth tables. The complex sentences we are solving for can get more complex either by involving more logical operators or more variables, but we will solve them by making tables like we just did in the previous two examples. Keep in mind that you can also use the tricks you learned last week for negation reduction to make the table simpler. So, if you have to do a table for ~ (~P v ~Q), you can first pull the negation out, turning it into: ~~(P & Q), and then eliminating the negation, making it: P & Q.

    Some of you probably feel pretty confident, and others likely are feeling a bit uneasy. As we mentioned at the start of this section, just like with math, the only real way to get comfortable and to make sure you know what you’re doing is to work through examples. The next section will ask you to construct tables for some complex sentences. If you take your time and think it through step by step, it will start to click, even if you are feeling lost. The appendix for this section also has all the rules from earlier on one page. You might want to have that open as you work through the tables.

    Exercises

    Construct a truth table for the following complex sentences.

    1. ~ (~P & Q)
    2. P ← → (P v Q)
    3. P v (Q v R)
    4. P & (~P → Q)
    5. P ← → (Q ← → ~P)
    6. Q v ~P
    7. (P & ~Q) & R
    8. P → ~Q
    9. (P & ~Q) v P
    10. Q v (P ← → ~P)
    11. ~Q ← → (P & ~Q)
    12. P → (Q v ~R)
    13. (P v R) ← → (P ← →R)
    14. ~(~Q v P) & Q
    15. R & [(R → P) → Q]
    16. ~P v [(~Q → P) v ~(P → ~Q)]
    17. [(P v ~P) v (Q v ~Q)] v ([(R v ~ R) v (P & ~P)] v [(Q & ~Q) v (R & ~R)])
    18. (~P v ~R) → [~Q & (~P → ~R)]
    19. ~[(P v ~P) v (Q v ~Q)]
    20. (~~[(P --?~Q) & (P v R)]) ← → [(~R v R) v (P & Q)]
    Answers to Selected Exercises
    1. ~(~P & Q)

    We start by using the negation manipulation rules from last chapter to make this simpler. ~(~P & Q) is the same as P v ~Q, but there are fewer logical operators to deal with. The sentence has two variables, so the table will be four lines long. The values for P come from the left side of the table, so all we have to do is copy them down. For ~Q, we take the opposite of Q on the left side of the table.

    Screenshot (167).png

    Now, we use those new values and the ‘or’ rule to complete the table. The ‘or’ rule says we put a T in the box any time either the claim to the left of the ‘v’ or the one to the right of the ‘v’ is true, and we put an F when both of them are false. So, lines 1, 3 and 4 get T’s and line 2 gets an F.

    Screenshot (168).png

    Now we’re done.

    1. P ← → (P v Q)

    There is no way to simplify this sentence, so we just start by making a table. Again, there are only 2 letters (although one appears twice), so the table is 4 lines long. The first step is to put the truth values for P and Q under the letters on the right. Again, these values just come from the left of the table.

    Screenshot (169).png

    Now we can start solving the table. We have to work from inside parentheses out, just like in algebra, so we will use the ‘or’ rule, just as in problem 1. The first three lines will be T, and the last will be F.

    Screenshot (170).png

    Now we solve for the ← →, the last step. The rule for the ← → says that when the left and the right side of the symbol are true then you put a T. It also says that whenever the left and right side of the symbol are false you put a T and in all other cases you put an F. So, Lines 1, 3 and 4 are all T and line 2 is F.

    Screenshot (171).png

    1. P v (Q v R)

    Just like with question 2, this sentence can’t be simplified. So, we will make a table for the sentence as it stands. This time there are three variables, so the table will be 8 lines long. As always, the first step is to put in the truth-values for all of the letters on the right.

    Screenshot (172).png

    Now we work from the parentheses out. So, using the ‘or’ rule, we look for any line where the Q is false and the R is false, as this is the only line where we put an F. On every other line, we put a T.

    Screenshot (173).png

    Now we use the ‘or’ rule again, using the values for P and the ones we just computed from the parentheses. Again, every line gets a T except when both sides of the ‘v’ are false.

    Screenshot (174).png

    Now we are done.

    With those examples under our belts, let’s move on to learning how to actually use the tables.


    This page titled 33.1: Truth Tables is shared under a CC BY-NC 4.0 license and was authored, remixed, and/or curated by Jason Southworth & Chris Swoyer via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.