<?xml version="1.0" encoding="UTF-8"?>
<quiz>
  <question type="description">
    <name>
      <text>3.1.19 (Truth Tables)</text>
    </name>
    <questiontext format="html">
      <text><![CDATA[<h1>Truth tables</h1>
<p>Many of the mathematical and logical questions we have met so far have been concerned with establishing that certain mathematical statements are true. This is because proof is also concerned with establishing the truth of certain statements. Mathematicians often use a two-valued logic (often called <strong>Boolean logic</strong>), where every statement is either true or false. This is called the <strong>Law of the excluded middle.</strong></p>
<p>We have seen that we can use logical connectives or operators to form more complicated statements. The truth or falsity of statements built with such connectives depends on the truth or falsity of its components. For example the truth of \(A \implies (B \vee C)\) depends on the truth of \(A, B\) and \(C\). One technique we can use to understand the truth of such statements is to use a <strong>truth table</strong>. A truth table has one column for each input variable and a final column for the logical combination of the statements that the table represents. Then each row of the table represents each possible combination of whether the input variables are true or false.</p>
<br/>
<p>We begin by noting the truth tables for each of the logical connectives we have met so far. In each case, assume that we have statements \(A\) and \(B\).</p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="@@PLUGINFILE@@/Truth%20table%20always%20truefalse.png" alt="Truth tables of always true and always false" width="479" height="195" /></p>
<br/>
<p>We can see that for the connective "always true", no matter whether the given statement is true or false, the output is true. Similarly, for "always false" no matter the input, the output is always false. These are somewhat unusual logical operations that we don't often use. </p>
<br/>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="@@PLUGINFILE@@/Truth%20table%20negation.png" alt="Truth table of negation" width="209" height="174" /></p>
<br/>
<p>The truth table for negation is as expected. Recall that the negation of \(A\) means not \(A\). Therefore the truth table above says that if \(A\) is true then not \(A\) is false and vice versa.</p>
</br>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="@@PLUGINFILE@@/Truth%20table%20conjuctiondisjunction.png" alt="Truth tables of conjunction and disjunction" width="580" height="228" /></p>
</br>
<p>These truth tables show us the precise difference between the connectives "or" and "and". The "and" connective requires <i>both</i> input statements to be true in order to be true, whereas "or" merely requires at least one of the input statements to be true in order to be true.</p>
<br/>
<p>We can actually define connectives via their truth tables. For example we could define the operation "and" to be the connective such that \(A \wedge B\) is true precisely when both the input statements are true!</p>]]></text>
<file name="Truth table always truefalse.png" path="/" encoding="base64">[encoded data, 19696 characters]</file>
<file name="Truth table conjuctiondisjunction.png" path="/" encoding="base64">[encoded data, 26060 characters]</file>
<file name="Truth table negation.png" path="/" encoding="base64">[encoded data, 13876 characters]</file>
    </questiontext>
    <generalfeedback format="html">
      <text/>
    </generalfeedback>
    <defaultgrade>0</defaultgrade>
    <penalty>0</penalty>
    <hidden>0</hidden>
    <idnumber/>
  </question>
</quiz>
