Truth Table: AND, OR, NAND, NOR, Conditional and Bi-conditional

Truth Table: AND, OR, NAND, NOR, Conditional and Bi-conditional

Komal MiglaniUpdated on 02 Jul 2025, 07:55 PM IST

In mathematical logic and philosophy, a statement or proposition is a declarative sentence that is either true or false. The truth value of a statement indicates whether it is true (denoted by "$T$") or false (denoted by "$F$"). This binary nature of truth values is fundamental to logical reasoning, enabling us to analyze and construct complex logical expressions systematically.

Truth Table: AND, OR, NAND, NOR, Conditional and Bi-conditional
Truth Table: AND, OR, NAND, NOR, Conditional and Bi-conditional

Truth Value of a Statement

As we know that a statement is either true or false. The truth or falsity of a statement is called truth value.

If the statement is true, then truth value is “$T$”

If the statement is false, then truth value is “$F$”

Truth Table

A table indicating the truth value of one or more statements is called a truth table.

Truth table of one statement ‘$p$’ is

$\begin{array}{|c|}\hline \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}\mathrm{\;\;\;} \\ \hline \mathrm{T}\\ \hline \mathrm{F} \\ \hline\end{array}$

Truth table for two statement ‘$p$’ and ‘$q$’ is

$\begin{array}{|c|c|}\hline \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;\;\;}q\mathrm{\;\;\;\;\;} \\ \hline \mathrm{T}& \mathrm{T} \\ \hline \mathrm{T}&\mathrm{F} \\ \hline \mathrm{F}&\mathrm{T}\\\hline \mathrm{F}&\mathrm{F} \\ \hline\end{array}$

In the case of n statements, there are $2^n $ distinct possible arrangements of truth values of statements.

Truth Table for Negation of a Statement

The truth value of the negation of a statement is always opposite to the truth value of the original statement.

$\begin{array}{|c|c|}\hline \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;}\sim p\mathrm{\;\;\;\;\;} \\ \hline \mathrm{T}& \mathrm{F} \\ \hline \mathrm{F}&\mathrm{T} \\ \hline\end{array}$

Truth Table of Conjunction and Disjunction:

$\begin{array}{|c|c|c|c|c|c|c|c|c|c|}\hline \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;}\sim p\mathrm{\;\;\;}&\mathrm{\;\;\;\;\;}q\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;}\sim q\mathrm{\;\;\;} &\mathrm{\;\;\;}p\wedge q\mathrm{\;\;}&\mathrm{\;\;\;}\sim p\wedge \sim q \mathrm{\;\;}&\mathrm{\;\;\;}p\vee q\mathrm{\;\;}&\mathrm{\;\;\;}\sim\left (p\vee q \right )\mathrm{\;\;} \\ \hline \mathrm{T}&\mathrm{F} & \mathrm{T} &\mathrm{F}&\mathrm{T}&\mathrm{F} &\mathrm{T}&\mathrm{F}\\ \hline \mathrm{T}&\mathrm{F} & \mathrm{F} &\mathrm{T}&\mathrm{F}&\mathrm{F} & \mathrm{T}&\mathrm{F}\\ \hline \mathrm{F}&\mathrm{T} & \mathrm{T} &\mathrm{F}&\mathrm{F}&\mathrm{F} & \mathrm{T}&\mathrm{F}\\ \hline \mathrm{F}&\mathrm{T} & \mathrm{F} &\mathrm{T}&\mathrm{F}&\mathrm{T}& \mathrm{F}&\mathrm{T} \\ \hline\end{array}$

Negation of a Negation

Negation of negation of a statement is the statement itself. Equivalently, we write: $\sim (\sim p) \rightarrow p$

Truth Table

$\begin{array}{|c|c|c|}\hline \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;\;\;}\sim p\mathrm{\;\;\;\;\;} &\mathrm{\;\;\;\;\;}\sim\left (\sim p \right )\mathrm{\;\;\;\;\;} \\ \hline \mathrm{T}& \mathrm{F}&\mathrm{T} \\ \hline \mathrm{F}&\mathrm{T}&\mathrm{F} \\ \hline\end{array}$

Truth Table for Conditional Statement:

A Conditional Statement is false only when p is true and q is false. In all other cases this is true.

$\begin{array}{|c|c|c|}\hline \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;\;\;}q\mathrm{\;\;\;\;\;} &\mathrm{\;\;\;}p\rightarrow q\mathrm{\;\;} \\ \hline \mathrm{T}& \mathrm{T} & \mathrm{T}\\ \hline \mathrm{T}&\mathrm{F}& \mathrm{F} \\ \hline \mathrm{F}&\mathrm{T}& \mathrm{T}\\\hline \mathrm{F}&\mathrm{F} & \mathrm{T}\\ \hline\end{array}$

Truth Table for Biconditional Statements:

A biconditional statement is true when both $p$ and $q$ are true or when both $p$ and $q$ are false

$\begin{array}{|c|c|c|}\hline \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;\;\;}q\mathrm{\;\;\;\;\;} &\mathrm{\;\;\;}p\leftrightarrow q\mathrm{\;\;} \\ \hline \mathrm{T}& \mathrm{T} & \mathrm{T}\\ \hline \mathrm{T}&\mathrm{F}& \mathrm{F} \\ \hline \mathrm{F}&\mathrm{T}& \mathrm{F}\\\hline \mathrm{F}&\mathrm{F} & \mathrm{T}\\ \hline\end{array}$

Relation Between Set Notation and Truth Table

Sets can be used to identify basic logical structure of statements.

Let us understand with an example of two sets $p \{1,2\}$ and $q \{2,3\}$

$\begin{array}{|c|c|c|}\hline\quad p\vee q\quad & \quad p\cup q\quad&\quad 1,2,3\quad \\ \hline p\wedge q& p\cap q&2 \\ \hline p^c& \sim p & 3,4 \\ \hline q^c& \sim q&1,4 \\ \hline\end{array}$

Using this relation we get

$\begin{array}{|c|c|c|c|c|c|c|c|c|c|c|}\hline \text{Element } & \mathrm{\;\;\;\;\;}p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;}q\mathrm{\;\;\;}&\mathrm{\;\;\;\;\;}\sim p\mathrm{\;\;\;\;\;}&\mathrm{\;\;\;}\sim q\mathrm{\;\;\;} &\mathrm{\;\;\;}p\wedge q\mathrm{\;\;}&\mathrm{\;\;}p\vee q\mathrm{\;\;}&\sim\left (p\wedge q \right )\mathrm{\;\;}&\sim p\wedge\sim q\mathrm{\;\;} \\ \hline \hline 1& \mathrm{T}&\mathrm{F} & \mathrm{F} &\mathrm{T}&\mathrm{F}&\mathrm{T}&\mathrm{T}&\mathrm{F} \\ \hline2& \mathrm{T}&\mathrm{T} & \mathrm{F} &\mathrm{F}&\mathrm{T}&\mathrm{T}&\mathrm{F}&\mathrm{F} \\ \hline 3& \mathrm{F}&\mathrm{T} & \mathrm{T} &\mathrm{F}&\mathrm{F}&\mathrm{F}&\mathrm{T}&\mathrm{F} \\ \hline4& \mathrm{F}&\mathrm{F} & \mathrm{T} &\mathrm{T}&\mathrm{F}&\mathrm{F}&\mathrm{T}&\mathrm{T} \\ \hline\end{array}$

Recommended Video


Solved Examples

Example 1: The contrapositive of the statement “I go to school if it does not rain” is :

1) If it rains, I do not go to school.

2) I do not go to school, it rains.

3) If it rains, I go to school.

4) If I go to school, it rains.

Solution

Symbol of If $p$ then $q$ is $p \rightarrow q$ or $p \Rightarrow q$
The contrapositive of $p \rightarrow q$ is $\sim q \rightarrow p$

We need to examine the given statement if says If it does not rain, then I go to school

So contrapositive will be

If I do not go to school, it rains

Example 2: The negation of the statement “If I become a teacher, then I will open a school” is

1) I will become a teacher and I will not open a school

2) Either I will not become a teacher or I will not open a school

3) Neither I will become a teacher nor I will open a school

4) I will not become a teacher or I will open a school

Solution

The given statement is " If I become a teacher, then I will open a school’ "

Negation of the given statement is

"I will become a teacher and I will not open a school"

$
(\because \sim(p \rightarrow q)=p \wedge \sim q)
$

Negation of Conditional Statement -

$
\sim(p \Rightarrow q) \equiv p \wedge \sim q
$

Example 3: Which of the following is true for an if-then statement $p \Rightarrow q$ is true?
1) If $p$ is true, $q$ must be true
2) If $p$ is false, $q$ must be false
3) If $q$ is false, $p$ must be false
4) none of these

Solution

As we have learned

Validating Statements with 'If then' -

By assuming that $p$ is true, prove that $q$ must be true. By assuming that $q$ is false, prove that $p$ must be false.

If $P$ is true, $q$ must be true and If $q$ is false, $p$ must be false

Example 4: Which of the options is sufficient condition for $p \Leftrightarrow q$ to be true ?
1) $p \Rightarrow q$ and $q \neq p$
2) $p \Rightarrow q$ or $q \Rightarrow p$
3) $p \Rightarrow q$ and $q \Rightarrow p$
4) $p \neq q$ and $q \neq p$

Solution

As we have learned

Validating Statements with "If and only if' -

If $p$ is true, then $q$ is true. If $q$ is true then $p$ is true.
Both $p \Rightarrow q$ or $q \Rightarrow p$ must be true
Example 5: What is truth table for $\sim(p \wedge q)$ ?
1) $TTTT$
2) $FFFT$
3) $TTF$
4) $FTTT$

Solution

Construction of truth table -

We prepare table of rows and columns. We write variables denoting sub-statements and we write the truth value of sub statement to get compound statement.

$
\begin{array}{|c|c|c|}
\hline \mathrm{p} & \mathrm{q} & \mathrm{p} \wedge \mathrm{q} \\
\hline \mathrm{~T} & \mathrm{~T} & \mathrm{~T} \\
\hline \mathrm{~T} & \mathrm{~F} & \mathrm{~F} \\
\hline \mathrm{~F} & \mathrm{~T} & \mathrm{~F} \\
\hline \mathrm{~F} & \mathrm{~F} & \mathrm{~F} \\
\hline
\end{array}$

Since truth table for $p \wedge q$ is $TFFF$
For $\sim(p \wedge q)$ is $FTTT$


Frequently Asked Questions (FAQs)

Q: How do truth tables contribute to the understanding of the relationship between formal logic and natural language reasoning?
A:
Truth tables provide a rigorous, formal representation of logical relationships that often underlie natural language statements. By mapping natural language constructs to logical operations and examining their truth tables, we can uncover potential ambiguities or inconsistencies in everyday reasoning and clarify the precise meaning of logical connectives in formal contexts.
Q: What is the concept of a satisfiable formula in propositional logic, and how do truth tables help identify it?
A:
A formula is satisfiable if there exists an assignment of truth values to its variables that makes the entire formula true. Truth tables help identify satisfiable formulas by showing if there's at least one row where the formula evaluates to true.
Q: How can truth tables be used to explore the relationship between conjunction (AND) and disjunction (OR) in logic?
A:
Truth tables clearly show the dual nature of AND and OR: (A ∧ B) is true only when both A and B are true, while (A ∨ B) is false only when both A and B are false. This duality is further illustrated by De Morgan's laws.
Q: What is the role of truth tables in understanding the concept of logical independence versus mutual exclusivity?
A:
Truth tables can show logical independence when all four combinations of truth values are possible for two statements. They show mutual exclusivity when there's no row where both statements are true simultaneously.
Q: How do truth tables help in understanding the concept of contraposition in logic?
A:
Truth tables can show that a conditional statement (A → B) is logically equivalent to its contrapositive (¬B → ¬A) by demonstrating that these two statements have identical truth tables.
Q: What is the concept of a tautological implication, and how do truth tables demonstrate it?
A:
A tautological implication is when one statement logically implies another in all possible cases. Truth tables demonstrate this by showing that whenever the implying statement is true, the implied statement is also true, across all rows of the table.
Q: How can truth tables be used to explore the relationship between necessity and sufficiency in logical statements?
A:
In a truth table for A → B, if B is true whenever A is true, A is sufficient for B. If A is true whenever B is true, A is necessary for B. If both conditions hold, A and B are necessary and sufficient for each other, equivalent to the bi-conditional A ↔ B.
Q: What is the role of truth tables in understanding the principle of bivalence in classical logic?
A:
The principle of bivalence states that every proposition is either true or false. Truth tables embody this principle by assigning only two possible values (T or F) to each proposition, and exhaustively listing all combinations of these values.
Q: How can truth tables be used to understand the concept of logical equivalence versus material equivalence?
A:
Truth tables show that material equivalence (↔) is true when both statements have the same truth value. Logical equivalence, on the other hand, means two statements always have the same truth value, which is demonstrated by their truth tables being identical for all input combinations.
Q: What is the relationship between truth tables and decision trees in logic?
A:
Both truth tables and decision trees represent all possible outcomes of a logical scenario. While truth tables show all combinations at once, decision trees present them as a branching structure. Each level in a decision tree corresponds to a column in a truth table.