Truth table

A way to organize the results of combining logical Boolean variables for a single Boolean operation.

Since there are 22=4 possible combinations of two Boolean variables, there are 24 = 16 possible Boolean operations on two variables (If we had three variables, there would be 23=8 possible outcomes and thus 28=256 possible operations). If we combine all of the possible truth tables into a single table, we can order the truth tables by the number that results from interpreting the four results as a binary representation:

Each four-digit binary representation can also be interpreted as a hexadecimal digit; This will be familiar to old-time GUI (Windows and X) programmers as the list of raster operators when performing something like a bitblt.

If you have a boolean equation of True OR False, you can use the table find that the equation equals True. For larger equations, such as (True ^ ¬(False OR False)), resolve what's in the innermost parentheses first (in this case, False nor False is True), then work outwards. This example resolves to (True ^ True) or True.

Actually, larger (more-than-two-variable) truth tables are pretty easy to make, but as the math guru who taught this to me said, it will make your arms hurt a bit. Here's how to make larger truth tables:

A truth table will always have 2^n lines (ie, 2^n different combinations), where n is the number of variables. Thus 2-variable truth table will have 4 lines, 3-variable table will have 8 lines, 4-variable table will have 16 lines and so on. I've made a 6-variable table (64 lines) once, on paper - that was pretty boring. =)

How to fill the columns? First column will have half of the table True and other half False; Second will have one-fourth (half of previous) True, False, True, False, Third will have one-eighth, and so on. Final column will thus look like "T,F,T,F,T,F..." then.

In Boolean logic, each statement evaluates to either T or F, representing True or False. Because each operator has one or two operands, which may only have the values T or F, we can define our logical operators by means of truth tables.

D ('it is dark or we are wearing sunglasses') is only
false when both A and B are false. We only need one
out of A and B to be true in order for D to be true.
Thus, we can precisely define how we want 'or'to behave
in our algebra.

the table for the not operator is very simple, because
it only has one operand:

A not A
---+------
F | T
T | F

This just says that if A is true, then 'not A' is false, and the converse.

4.26 If all true elementary propositions are given, the result is a complete description of the world. The world is completely described by giving all elementary propositions, and adding which of them are true and which false.

4.27 For n states of affairs, there are Kn = Σ(from ν = 0 to n) (n above ν) possibilities of existence and non-existence.

4.28 There correspond to these combinations the same number of possibilities of truth -- and falsity -- for n elementary propositions.

4.3 Truth-possibilities of elementary propositions mean possibilities of existence and non-existence of states of affairs.

4.31 We can represent truth-possibilities by schemata of the following kind ('T' means 'true', 'F' means 'false'; the rows of 'T's' and 'F's' under the row of elementary propositions symbolize their truth-possibilities in a way that can easily be understood):

And thereafter with a number of remarks in a similar vein. Clearly he is working this out as a new idea. In his later work (foremost in Philosophical Investigations) he repudiated this atomistic picture of the world being composed of all the things that were true about it, but his legacy of the truth table remains useful.

In propositional logic there are a few operational symbols:
~ NOT (negation)
& AND (conjunction)
v OR (disjunction)
V exclusive OR
→ IF....THEN (implication)
↔ IF AND ONLY IF (biconditional)
that are used to show the relationships of sentences. Variables (A,B,C,P,Q,R...) are used to represent the sentence.

Example:
A - Max is a dog.
B - Max is hungry.
so the sentence Max is a dog and hungry. would be represented as A & B.

On to truth tables. On the left side of the truth table is all the possible true-false combinations for the variables we are using. For one variable there are two possible truth combinations : T (true) or F (false). For two variables there are 4 combinations, for 3 variables there are 8 combinations and so on. On the right side of the table there is the truth value for the statement.

This truth table tells us that the conjunction of A and B is only true when both A and B are true.

v - Disjunction

A B | A v B
------------
T T | T
T F | T
F T | T
F F | F

This truth table says that as long as one of the variables is true, the disjunction is true (either A or B is true). It was argued by some logiticians that the conversational implication of saying either-or is that we do not know which one is true, just that one of them is. If we knew A and B were both true, we would say A&B not A v B. Because of this, the special exclusive disjunction (represented by the symbol V (capital v) should be used. The truth table for V is below:

V - Exclusive Disjunction

A B | A V B
------------
T T | F
T F | T
F T | T
F F | F

This truth table says that the statement is true only when A or B have different truth values. When A and B are both true or both false, the sentence is false.

→ - Implication, If-Then

A B| A→B
------------
T T | T
T F | F
F T | T
F F | T

This is often the hardest truth table to grasp. For most of the other operational symbols, their truth tables very closely resemble or match what their engligh translations mean. The If-Then table is not so clear. It says that if A is true and A→B is true, then B is true. Or, if we look at just the first two lines, a true statement cannot imply a false statment. If it does, the whole thing is false. The last two lines on the table say that if we start with a false statment or premise, it doesn't matter what the second part is, the whole thing is true (ie: If I gave birth to puppies than you would be their father. is true, because I am never going to give birth to puppies. The statement I gave birth to puppies. is always going to be false.)

↔ - Biconditional

A B | A↔B
------------
T T | T
T F | F
F T | F
F F | T

The biconditional states that when both sentences have the same truth value, the statment is true. So, when both A and B are true, or when they are both false, the biconditional true. (this truth table is the same as for ~(A V B), the negation of the exclusive or).

Here is our truth table for this sentence. To start, we will have to assess the truth value of the sub-formula S&M. To do this, we just look at the truth values for S and M, we are ignoring P for now. We will record the truth value for each line under the & symbol. By placing it there, we know that that column in our table applies to S&M. Here is the table with that column completed:

Now that we have the truth value of our sub-formula we can find the truth value for the whole sentence. If there were more sub-formulas you would continue finding thier truth values and in essence work "outward" until you had the truth value for the whole sentence. For the next step we are going to treat S&M as a single variable. We are going to nickname S&M - Q for simplicity. Now we can asess the truth value of Q v P. The table for Q v P would look like:

The column for Q (on the left) is the same as the column for S&M on the above truth table. The column for P in this table is also the same as the column for P above.

It is not nessisary to make an entirely new truth table for this step. I only did so for clarity. It is preferable to write this final column on the original table, placing it under the disjunction (v) operator like so:

The far right column under v is the truth value for the entire statement given the contions of truth or falsehood given on the left side of the table. We can see that this table is accurate just by thinking about what it represents. For example, on line 4, Sam runs, but Mark doesn't and neither does Pat. So the statement Either Sam and Mark go running or Pat goes running. is false in this case, and that is what the truth table tells us. We can think about all 8 lines this way, keeping in mind that we are not using the exclusive or (V) - even if everyone goes running the statment is still true.

It should be noted that there are many other variations on how to write out a truth/logic table. I prefer this method because involves the least amount of writing, and I think it is fairly straight forward. The left-right division of variables and formulas is not nessisary, but it makes it easier for other people who are looking at your work to read.