Content deleted Content added
caps |
Randy Kryn (talk | contribs) →Computer science: uppercase per direct link (Apollo Guidance Computer) |
||
(19 intermediate revisions by 12 users not shown) | |||
Line 1:
{{Short description|
{{Logical connectives sidebar}}
<!-- :''"Truth functional" redirects here. For the truth functional conditional, see [[Material conditional]].''
IMHO by no means the material conditional may not be referred to or abbreviated as the adjective "truth functional", omitting a noun like "conditional" or "implication". Seems more like an internal link spamming rather than an appropriate dab hatnote. --Incnis Mrsi -->
In [[logic]], a '''truth function'''<ref>Roy T. Cook (2009). ''A Dictionary of Philosophical Logic'', p. 294: Truth Function. Edinburgh University Press.</ref> is a [[function (mathematics)|function]] that accepts [[truth value]]s as input and produces a unique truth value as output. In other words:
[[Classical logic|Classical propositional logic]] is a truth-functional logic,<ref>[http://www.iep.utm.edu/prop-log/ Internet Encyclopedia of Philosophy: Propositional Logic], by Kevin C. Klement</ref> in that every statement has exactly one truth value which is either true or false, and every logical connective is truth functional (with a correspondent [[truth table]]), thus every compound statement is a truth function.<ref>Roy T. Cook (2009). ''A Dictionary of Philosophical Logic'', p. 47: Classical Logic. Edinburgh University Press.</ref> On the other hand, [[modal logic]] is non-truth-functional.
== Overview ==
A [[logical connective]] is truth-functional if the truth-value of a compound sentence is a function of the truth-value of its sub-sentences. A class of connectives is truth-functional if each of its members is. For example, the connective "''and''" is truth-functional since a sentence like "''Apples are fruits and carrots are vegetables''" is true ''[[if and only if|if, and only if]],'' each of its sub-sentences "''apples are fruits''" and "''carrots are vegetables''" is true, and it is false otherwise. Some connectives of a natural language, such as English, are not truth-functional.
Connectives of the form "x ''believes that'' ..." are typical examples of connectives that are not truth-functional. If e.g. Mary mistakenly believes that Al Gore was President of the USA on April 20, 2000, but she does not believe that the moon is made of green cheese, then the sentence
Line 107 ⟶ 109:
|{{logicalconnective
|main=Sheffer stroke
|title=Non-conjunction/Alternative denial
|notation=''P'' ↑ ''Q''<br />''P'' {{pipe}} ''Q'' <br />''P'' NAND ''Q''
|equivalents=''P'' → ¬''Q'' <br /> ¬''P'' ← ''Q''<br />¬''P'' ∨ ¬''Q''<br />D''pq''
Line 130 ⟶ 132:
|{{logicalconnective
|main=Logical NOR
|title=Non-disjunction/Joint denial
|notation=''P'' ↓ ''Q''<br />''P'' NOR ''Q''
|equivalents=''P'' ↚ ¬''Q'' <br /> ¬''P'' ↛ ''Q'' <br /> ¬''P'' ∧ ¬''Q''<br />X''pq''
Line 188 ⟶ 190:
| {{logicalconnective
|main=Exclusive or
|title=Non-equivalence/Exclusive disjunction
|notation=''P'' ↮ ''Q'' <br /> ''P'' ≢ ''Q'' <br /> ''P'' ⨁ ''Q''<br />''P'' XOR ''Q''
|equivalents=''P'' {{eqv}} ¬''Q'' <br /> ¬''P'' {{eqv}} ''Q'' <br /> ¬''P'' ↮ ¬''Q''<br />J''pq''
Line 199 ⟶ 201:
|{{logicalconnective
|main=Logical biconditional
|title=Equivalence/Biconditional
|notation=''P'' {{eqv}} ''Q'' <br /> ''P'' ≡ ''Q''<br />''P'' XNOR ''Q''<br /> ''P'' IFF ''Q''
|equivalents=''P'' ↮ ¬''Q'' <br /> ¬''P'' ↮ ''Q'' <br /> ¬''P'' {{eqv}} ¬''Q''<br />E''pq''
Line 225 ⟶ 227:
Some truth functions possess properties which may be expressed in the theorems containing the corresponding connective. Some of those properties that a binary truth function (or a corresponding logical connective) may have are:
*
*
*
*
*
A set of truth functions is [[functional completeness|functionally complete]] if and only if for each of the following five properties it contains at least one member lacking it:
*
*
*
*
*
=== Arity ===
Line 243 ⟶ 245:
A concrete function may be also referred to as an ''operator''. In two-valued logic there are 2 nullary operators (constants), 4 [[unary operation|unary operators]], 16 [[binary operation|binary operators]], 256 [[ternary operation|ternary operators]], and <math>2^{2^n}</math> ''n''-ary operators. In three-valued logic there are 3 nullary operators (constants), 27 [[unary operation|unary operators]], 19683 [[binary operation|binary operators]], 7625597484987 [[ternary operation|ternary operators]], and <math>3^{3^n}</math> ''n''-ary operators. In ''k''-valued logic, there are ''k'' nullary operators, <math>k^k</math> unary operators, <math>k^{k^2}</math> binary operators, <math>k^{k^3}</math> ternary operators, and <math>k^{k^n}</math> ''n''-ary operators. An ''n''-ary operator in ''k''-valued logic is a function from <math>\mathbb{Z}_k^n \to \mathbb{Z}_k</math>. Therefore, the number of such operators is <math>|\mathbb{Z}_k|^{|\mathbb{Z}_k^n|} = k^{k^n}</math>, which is how the above numbers were derived.
However, some of the operators of a particular arity are actually degenerate forms that perform a lower-arity operation on some of the inputs and ignore the rest of the inputs. Out of the 256 ternary
[[Negation|"Not"]] is a [[unary operation|unary operator]], it takes a single term (¬''P''). The rest are [[binary operation|binary operators]], taking two terms to make a compound statement ({{math|''P'' ∧ ''Q'',
The set of logical operators {{math|Ω}} may be [[Partition of a set|partitioned]] into disjoint subsets as follows:
Line 264 ⟶ 266:
Instead of using [[truth table]]s, logical connective symbols can be interpreted by means of an interpretation function and a functionally complete set of truth-functions (Gamut 1991), as detailed by the [[principle of compositionality]] of meaning.
Let
* ''f''<sub>nand</sub>(T,T) = F; ''f''<sub>nand</sub>(T,F) = ''f''<sub>nand</sub>(F,T) = ''f''<sub>nand</sub>(F,F) = T
Line 284 ⟶ 286:
| ''I''(&) {{=}} ''I''({{and}}) {{=}} ''f''<sub>and</sub>
| ''I''(''v'') {{=}} ''I''({{or-}}) {{=}} ''f''<sub>or</sub>
| ''I''(~
| ''I''(
}}
etc.
Thus if ''S'' is a sentence that is a string of symbols consisting of logical symbols ''v''<sub>1</sub>...''v''<sub>''n''</sub> representing logical connectives, and non-logical symbols ''c''<sub>1</sub>...''c''<sub>''n''</sub>, then if and only if {{math|size=100%|''I''(''v''<sub>1</sub>)...''I''(''v''<sub>''n''</sub>)}} have been provided interpreting ''v''<sub>1</sub> to ''v''<sub>''n''</sub> by means of ''f''<sub>nand</sub> (or any other set of functional complete truth-functions) then the truth-value of {{tmath|I(s)}} is determined entirely by the truth-values of ''c''<sub>1</sub>...''c''<sub>''n''</sub>, i.e. of {{math|size=100%|''I''(''c''<sub>1</sub>)...''I''(''c''<sub>''n''</sub>)}}. In other words, as expected and required, ''S'' is true or false only under an interpretation of all its non-logical symbols.
== Definition ==
Using the functions defined above, we can give a formal definition of a proposition's truth function.<ref>{{Cite web |title=An Introduction to Mathematical Logic |url=https://store.doverpublications.com/products/9780486497853?srsltid=AfmBOoo9mFyD06QpIypwYtJnNn2CYOf-Ps2CCwMYl_IgAfLRwgeh7v1s |access-date=2025-02-20 |website=Dover Publications |language=en}}</ref>
Let ''PROP'' be the set of all propositional variables,
: <math> PROP = \{p_1,p_2,\dots\}</math>
We define a '''truth assignment''' to be any function <math>\phi:PROP\to \{T,F\}</math>. A truth assignment is therefore an association of each propositional variable with a particular truth value. This is effectively the same as a particular row of a proposition's truth table.
For a truth assignment, <math>\phi</math>, we define its '''extended truth assignment''', <math>\overline\phi</math>, as follows. This extends <math>\phi</math> to a new function <math>\overline \phi</math> which has ___domain equal to the set of all propositional formulas. The range of <math>\overline\phi</math> is still <math>\{T,F\}</math>.
# If <math>A \in PROP</math> then <math>\overline\phi(A) = \phi(A)</math>.
# If ''A'' and ''B'' are any propositional formulas, then
## <math>\overline\phi(\neg A) = f_{\text{not}} (\overline\phi(A))</math>.
## <math>\overline\phi(A\land B) = f_{\text{and}} (\overline\phi(A),\overline\phi(B))</math>.
## <math>\overline\phi(A\lor B) = f_{\text{or}} (\overline\phi(A),\overline\phi(B))</math>.
## <math>\overline\phi(A\to B) = \overline\phi(\neg A\lor B)</math>.
## <math>\overline\phi(A\leftrightarrow B) = \overline\phi((A\to B)\land (B\to A))</math>.
Finally, now that we have defined the extended truth assignment, we can use this to define the truth-function of a proposition. For a proposition, ''A'', its '''truth function''', <math>f_A</math>, has ___domain equal to the set of all truth assignments, and range equal to <math>\{T,F\}</math>.
It is defined, for each truth assignment <math>\phi</math>, by <math>f_A(\phi) = \overline\phi(A)</math>. The value given by <math>\overline\phi(A)</math> is the same as the one displayed in the final column of the truth table of ''A'', on the row identified with <math>\phi</math>.
== Computer science ==
Line 296 ⟶ 322:
The "logical equivalence" of "NAND alone", "NOR alone", and "NOT and AND" is similar to [[Turing equivalence (theory of computation)|Turing equivalence]].
The fact that all truth functions can be expressed with NOR alone is demonstrated by the [[Apollo
== See also ==
Line 306 ⟶ 332:
* [[Binary function]]
* [[Boolean ___domain]]
* [[Boolean logic]]
* [[Boolean-valued function]]
* [[List of Boolean algebra topics]]
* [[Logical constant]]
* [[Modal operator]]
* [[Propositional calculus]]
* [[Truth-functional propositional logic]]
{{div col end}}
Line 333 ⟶ 354:
[[Category:Mathematical logic]]
[[Category:
|