Skip to main content
Mathematics LibreTexts

3.4: The Laws of Logic

  • Page ID
    80507
  • \( \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}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    In this section, we will list the most basic equivalences and implications of logic. Most of the equivalences listed in Table \(\PageIndex{2}\) should be obvious to the reader. Remember, 0 stands for contradiction, 1 for tautology. Many logical laws are similar to algebraic laws. For example, there is a logical law corresponding to the associative law of addition, \(a + (b + c) = (a + b) + c\text{.}\) In fact, associativity of both conjunction and disjunction are among the laws of logic. Notice that with one exception, the laws are paired in such a way that exchanging the symbols \(\land\text{,}\) \(\lor\text{,}\) 1 and 0 for \(\lor\text{,}\) \(\land\text{,}\) 0, and 1, respectively, in any law gives you a second law. For example, \(p \lor 0\Leftrightarrow p\) results in \(p \land 1 \Leftrightarrow p\text{.}\) This is called a duality principle. For now, think of it as a way of remembering two laws for the price of one. We will leave it to the reader to verify a few of these laws with truth tables. However, the reader should be careful in applying duality to the conditional operator and implication since the dual involves taking the converse. For example, the dual of \(p \land q\Rightarrow p\) is \(p \lor q \Leftarrow p\text{,}\) which is usually written \(p\Rightarrow p \lor q\text{.}\)

    Example \(\PageIndex{1}\): Verification of an Identity Law

    The Identity Law can be verified with this truth table. The fact that \((p \land 1)\leftrightarrow p\) is a tautology serves as a valid proof.

    Table \(\PageIndex{1}\): Truth table to demonstrate the identity law for conjunction.

    \(p\) \(1\) \(p\land 1\) \((p\land 1)\leftrightarrow p\)
    \(0\) \(1\) \(0\) \(1\)
    \(1\) \(1\) \(1\) \(1\)

    Some of the logical laws in Table \(\PageIndex{3}\) might be less obvious to you. For any that you are not comfortable with, substitute actual propositions for the logical variables. For example, if \(p\) is “John owns a pet store” and \(q\) is “John likes pets,” the detachment law should make sense.

    Table \(\PageIndex{2}\): Basic Logical Laws - Equivalences

    Commutative Laws
    \(p \lor q\Leftrightarrow q\lor p\) \(p \land q\Leftrightarrow q \land p\)
    Associative Laws
    \((p\lor q)\lor r\Leftrightarrow p\lor (q\lor r)\) \((p\land q)\land r\Leftrightarrow p\land (q\land r)\)
    Distributive Laws
    \(p\land (q\lor r)\Leftrightarrow (p\land q)\lor (p\land r)\) \(p\lor (q\land r)\Leftrightarrow (p\lor q)\land (p\lor r)\)
    Identity Laws
    \(p\lor 0\Leftrightarrow p\) \(p\land 1\Leftrightarrow p\)
    Negation Laws
    \(p\land\neg p\Leftrightarrow 0\) \(p\lor\neg p\Leftrightarrow 1\)
    Idempotent Laws
    \(p\lor p\Leftrightarrow\) \(p\land p\Leftrightarrow p\)
    Null Laws
    \(p\land 0\Leftrightarrow 0\) \(p\lor 1\Leftrightarrow 1\)
    Absorption Laws
    \(p\land (p\lor q)\Leftrightarrow p\) \(p\lor (p\land q)\Leftrightarrow p\)
    DeMorgan's Laws
    \(\neg(p\lor q)\Leftrightarrow (\neg p)\land (\neg q)\) \(\neg(p\land q)\Leftrightarrow (\neg p)\lor (\neg q)\)
    Involution Laws
    \(\neg(\neg p)\Leftrightarrow p\)

    Table \(\PageIndex{3}\): Basic Logical Laws - Common Implications and Equivalences

    Detachment (AKA Modus Ponens) \((p \rightarrow q) \land p\Rightarrow q\)
    Indirect Reasoning (AKA Modus Tollens) \((p \to q) \land \neg q \Rightarrow \neg p\)
    Disjunctive Addition \(p\Rightarrow (p\lor q)\)
    Conjunctive Simplification \((p \land q) \Rightarrow p\) and \((p \land q) \Rightarrow q\)
    Disjunctive Simplification \((p \lor q) \land \neg p \Rightarrow q\) and \((p \lor q) \land \neg q\Rightarrow p\)
    Chain Rule \((p \to q) \land ( q \rightarrow r) \Rightarrow (p\to r)\)
    Conditional Equivalence \(p \rightarrow q \Leftrightarrow \neg p \lor q\)
    Biconditional Equivalences \((p \leftrightarrow q) \Leftrightarrow (p\rightarrow q) \land (q \rightarrow p)\Leftrightarrow (p \land q) \lor (\neg p \land \neg q)\)
    Contrapositive \((p\to q) \Leftrightarrow (\neg q \to \neg p)\)

    Exercises

    Exercise \(\PageIndex{1}\)

    Write the following in symbolic notation and determine whether it is a tautology: “If I study then I will learn. I will not learn. Therefore, I do not study.”

    Answer

    Let \(s=\textrm{I will study}\text{,}\)\(t=\textrm{I will learn.}\) The argument is: \(((s\to t)\land (\neg t))\to (\neg s) ,\) call the argument \(a\text{.}\)

    \begin{equation*} \begin{array}{ccccc} s\text{ } & t\text{ } & s\to t\text{ } & (s\to t)\land (\neg t)\text{ } & a \\ \hline 0\text{ } & 0\text{ } & 1\text{ } & 1\text{ } & 1 \\ 0\text{ } & 1\text{ } & 1\text{ } & 0\text{ } & 1 \\ 1\text{ } & 0\text{ } & 0\text{ } & 0\text{ } & 1 \\ 1\text{ } & 1\text{ } & 1\text{ } & 0\text{ } & 1 \\ \end{array}\text{.} \end{equation*}

    Since \(a\) is a tautology, the argument is valid.

    Exercise \(\PageIndex{2}\)

    Show that the common fallacy \((p\to q) \land \neg p \Rightarrow \neg q\) is not a law of logic.

    Exercise \(\PageIndex{3}\)

    Describe, in general, how duality can be applied to implications if we introduce the relation \(\Leftarrow\text{,}\) read “is implied by.” We define this relation by

    \begin{equation*} (p \Leftarrow q) \Leftrightarrow (q \Rightarrow p)\text{.} \end{equation*}

    Answer

    In any true statement \(S\text{,}\) replace; \(\land\) with \(\lor\text{,}\) \(\lor\) with \(\land\text{,}\) 0 with 1, 1 with 0, \(\Leftarrow\) with \(\Rightarrow \text{,}\) and \(\Rightarrow \) with \(\Leftarrow \text{.}\) Leave all other connectives unchanged.

    Exercise \(\PageIndex{4}\)

    Write the dual of the following statements:

    1. \(\displaystyle (p \land q)\Rightarrow p\)
    2. \(\displaystyle (p\lor q)\land \neg q\Rightarrow p\)

    This page titled 3.4: The Laws of Logic is shared under a CC BY-NC-SA 3.0 license and was authored, remixed, and/or curated by Al Doerr & Ken Levasseur via source content that was edited to the style and standards of the LibreTexts platform.