Recent from talks
Contribute something
Nothing was collected or created yet.
Truth value
View on WikipediaThis article needs additional citations for verification. (February 2012) |
In logic and mathematics, a truth value, sometimes called a logical value, is a value indicating the relation of a proposition to truth, which in classical logic has only two possible values (true or false).[1][2] Truth values are used in computing as well as various types of logic.
Computing
[edit]In some programming languages, any expression can be evaluated in a context that expects a Boolean data type. Typically (though this varies by programming language) expressions like the number zero, the empty string, empty lists, and null are treated as false, and strings with content (like "abc"), other numbers, and objects evaluate to true. Sometimes these classes of expressions are called falsy and truthy. For example, in Lisp, nil, the empty list, is treated as false, and all other values are treated as true. In C, the number 0 or 0.0 is false, and all other values are treated as true.
In JavaScript, the empty string (""), null, undefined, NaN, +0, −0 and false[3] are sometimes called falsy (of which the complement is truthy) to distinguish between strictly type-checked and coerced Booleans (see also: JavaScript syntax#Type conversion).[4] As opposed to Python, empty containers (Arrays, Maps, Sets) are considered truthy. Languages such as PHP also use this approach.
Classical logic
[edit]| ⊤ | ·∧· | ||
| true | conjunction | ||
| ¬ | ↕ | ↕ | |
| ⊥ | ·∨· | ||
| false | disjunction | ||
| Negation interchanges true with false and conjunction with disjunction. | |||
In classical logic, with its intended semantics, the truth values are true (denoted by 1 or the verum ⊤), and untrue or false (denoted by 0 or the falsum ⊥); that is, classical logic is a two-valued logic. This set of two values is also called the Boolean domain. Corresponding semantics of logical connectives are truth functions, whose values are expressed in the form of truth tables. Logical biconditional becomes the equality binary relation, and negation becomes a bijection which permutes true and false. Conjunction and disjunction are dual with respect to negation, which is expressed by De Morgan's laws:
- ¬(p ∧ q) ⇔ ¬p ∨ ¬q
- ¬(p ∨ q) ⇔ ¬p ∧ ¬q
Propositional variables become variables in the Boolean domain. Assigning values for propositional variables is referred to as valuation.
Intuitionistic and constructive logic
[edit]Whereas in classical logic truth values form a Boolean algebra, in intuitionistic logic, and more generally, constructive mathematics, the truth values form a Heyting algebra. Such truth values may express various aspects of validity, including locality, temporality, or computational content.
For example, one may use the open sets of a topological space as intuitionistic truth values, in which case the truth value of a formula expresses where the formula holds, not whether it holds.
In realizability truth values are sets of programs, which can be understood as computational evidence of validity of a formula. For example, the truth value of the statement "for every number there is a prime larger than it" is the set of all programs that take as input a number , and output a prime larger than .
In category theory, truth values appear as the elements of the subobject classifier. In particular, in a topos every formula of higher-order logic may be assigned a truth value in the subobject classifier.
Even though a Heyting algebra may have many elements, this should not be understood as there being truth values that are neither true nor false, because intuitionistic logic proves ("it is not the case that is neither true nor false").[5]
In intuitionistic type theory, the Curry-Howard correspondence exhibits an equivalence of propositions and types, according to which validity is equivalent to inhabitation of a type.
For other notions of intuitionistic truth values, see the Brouwer–Heyting–Kolmogorov interpretation and Intuitionistic logic § Semantics.
Multi-valued logic
[edit]Multi-valued logics (such as fuzzy logic and relevance logic) allow for more than two truth values, possibly containing some internal structure. For example, on the unit interval [0,1] such structure is a total order; this may be expressed as the existence of various degrees of truth.
Algebraic semantics
[edit]Not all logical systems are truth-valuational in the sense that logical connectives may be interpreted as truth functions. For example, intuitionistic logic lacks a complete set of truth values because its semantics, the Brouwer–Heyting–Kolmogorov interpretation, is specified in terms of provability conditions, and not directly in terms of the necessary truth of formulae.
But even non-truth-valuational logics can associate values with logical formulae, as is done in algebraic semantics. The algebraic semantics of intuitionistic logic is given in terms of Heyting algebras, compared to Boolean algebra semantics of classical propositional calculus.
See also
[edit]References
[edit]- ^ Shramko, Yaroslav; Wansing, Heinrich. "Truth Values". In Zalta, Edward N. (ed.). Stanford Encyclopedia of Philosophy.
- ^ "Truth value". Lexico UK English Dictionary. Oxford University Press. n.d.
- ^ "ECMAScript Language Specification" (PDF). p. 43. Archived from the original (PDF) on 2015-04-12. Retrieved 2011-03-12.
- ^ "The Elements of JavaScript Style". Douglas Crockford. Archived from the original on 17 March 2011. Retrieved 5 March 2011.
- ^ Proof that intuitionistic logic has no third truth value, Glivenko 1928
External links
[edit]- Shramko, Yaroslav; Wansing, Heinrich. "Truth Values". In Zalta, Edward N. (ed.). Stanford Encyclopedia of Philosophy.
Truth value
View on GrokipediaFundamentals
Definition
In logic and philosophy, a truth value is the semantic attribute assigned to a truth-bearer—such as a proposition, declarative sentence, or statement—indicating whether it holds as true, false, or, in non-classical systems, some other designation like indeterminate or partially true.[1] This assignment reflects the proposition's correspondence to reality or its satisfaction within a given interpretive framework.[7] The distinction between a truth value and its bearer is fundamental: the truth-bearer is the entity capable of being true or false, while the truth value is the property or designation it receives upon evaluation. For instance, the simple proposition "It is raining" serves as a truth-bearer; if precipitation is occurring at the relevant time and place, it receives the truth value true, but false otherwise.[8] This separation allows logical analysis to focus on how bearers acquire values without conflating the content with its assessment. The concept of truth value originated in early 20th-century formal logic, coined by Gottlob Frege in his 1891 lecture "Function and Concept," where he treated truth values as objects resulting from the application of concepts to arguments, and further elaborated in his 1892 paper "On Sense and Reference," identifying the reference of a sentence with its truth value.[7] Bertrand Russell adopted and extended the notion in his collaborative work with Alfred North Whitehead on Principia Mathematica (1910–1913), using truth values to ground the semantics of propositional logic. In classical systems, this typically involves bivalence, limiting truth values to true and false.Bivalence in Classical Systems
In classical logical systems, the principle of bivalence asserts that every proposition possesses exactly one of two possible truth values: true, denoted as or , or false, denoted as or , with no intermediate or additional options available.[6] This binary framework forms the semantic foundation of classical logic, ensuring that declarative sentences are exhaustively and exclusively partitioned into truth-valuing categories without gaps or overlaps.[6] The philosophical basis for bivalence traces back to Aristotle, who articulated it through the law of excluded middle, or tertium non datur, stating that for any proposition , either or its negation must hold, leaving no third alternative.[9] In his Metaphysics (Book IV, chapters 3–6), Aristotle defends this as an indemonstrable first principle essential for rational discourse and scientific inquiry, positing that contradictory assertions cannot both be true simultaneously.[9] A key implication of bivalence is the law of excluded middle, formalized as being invariably true for any proposition , which guarantees the exhaustive coverage of all possibilities in binary terms.[6] Complementing this is the law of non-contradiction, expressed as , which prohibits a proposition from being both true and false at once, thereby maintaining the mutual exclusivity of the two truth values.[9] Together, these laws underpin the stability and decisiveness of classical reasoning. However, bivalence faces challenges in natural language, particularly with vague statements that give rise to paradoxes like the sorites, where incremental changes (e.g., removing one grain from a heap) blur the boundary between true and false, suggesting potential truth-value gaps or indeterminacy.[10] Such cases, as explored in semantic theories of vagueness, highlight tensions with strict bivalence, though classical systems uphold it as the default for precise propositional analysis.[10]Logical Frameworks
Classical Logic
In classical propositional logic, propositions are assigned one of two truth values drawn from the Boolean domain: true, denoted , or false, denoted . This bivalence underpins the system's semantics, where every proposition must take exactly one of these values, with no intermediates or gaps.[11] The logic employs truth-functional semantics, such that the truth value of any compound proposition is fully determined by the truth values of its atomic components via specific functions associated with the logical connectives. The primary connectives are negation (), conjunction (), disjunction (), and material implication (). Negation yields if is and if is . Conjunction is if and only if both and are ; otherwise, it is . Disjunction is if at least one of or is ; otherwise, it is . Material implication is only if is and is ; in all other cases, it is . These definitions ensure that compound propositions inherit their truth values systematically from simpler ones.[12] Truth tables provide a complete enumeration of how these connectives operate across all possible input combinations. For negation:Intuitionistic Logic
In intuitionistic logic, truth values are interpreted within the framework of Heyting algebras, which provide a semantic foundation distinct from the binary true/false dichotomy of classical logic. A Heyting algebra forms an ordered lattice bounded by falsehood (⊥) at the bottom and truth (⊤) at the top, allowing for intermediate truth values that reflect degrees of provability, but lacking the classical complements where every element has a precise negation.[13] These structures capture the intuitionistic emphasis on constructive proofs, where a proposition's truth is established only through an explicit verification rather than by elimination of falsity.[14] The semantics of logical connectives in this system are defined relative to the lattice order. For implication, denoted , its truth value is the maximal element in the algebra such that , ensuring that assuming constructively leads to .[13] Negation is derived as , but double negation does not necessarily equate to , as the absence of a proof of falsehood for does not constructively yield a proof of .[15] This contrasts with classical logic, where classical logic emerges as a special case when the Heyting algebra reduces to a Boolean algebra with only ⊥ and ⊤. Intuitionistic logic rejects the law of excluded middle, , which is not generally valid since a proposition may lack a decisive proof in either direction without an intermediate truth value resolving it.[13] Truth values are assigned to propositions only when they are provable constructively; otherwise, they remain undetermined, aligning with the Brouwer-Heyting-Kolmogorov interpretation that equates truth to the existence of a proof. In realizability interpretations, such as Kleene's recursive realizability, truth values for a proposition correspond to the sets of programs (realizers) that witness its constructibility, where a proposition is true if there exists a computable function or index that verifies it relative to the natural numbers.[16] For instance, the truth value of an existential statement is realized by a pair consisting of a witness for and a realizer for , emphasizing effective computation over abstract existence. Applications of these truth values extend to type theory and computer science via the Curry-Howard isomorphism, which equates proofs in intuitionistic logic with programs in typed lambda calculi, where types represent propositions and terms represent proofs with constructive truth.[17] This correspondence enables formal verification of software and automated theorem proving, as a proof's habitability (inhabited type) directly corresponds to the existence of a terminating program realizing the proposition's truth.[18]Non-Classical Extensions
Multi-Valued Logic
Multi-valued logics extend classical bivalent systems by incorporating more than two truth values, typically to handle uncertainty, indeterminacy, or incompleteness in propositions. Unlike binary truth values of true (⊤) and false (⊥), these logics assign values such as an intermediate "unknown" (U) or "undefined" to statements, allowing for finer-grained representations of logical status. This approach maintains truth-functionality, where the truth value of a compound formula depends solely on the truth values of its components via defined operations.[19] The historical roots of multi-valued logic trace back to Jan Łukasiewicz, who in 1920 proposed a three-valued system to address Aristotle's problem of future contingents, such as statements about events that are neither determinately true nor false at present (e.g., "There will be a sea battle tomorrow"). In this framework, the third value represented possibility or indeterminacy, challenging the principle of bivalence for tensed propositions. Łukasiewicz's innovation laid the groundwork for broader many-valued systems, later generalized to n-valued logics for finite n greater than two.[20] A prominent example is Kleene's strong three-valued logic, developed in 1938 to model partial recursive functions and computational indeterminacy. Here, truth values are false (F), unknown (U), and true (T), with connectives extended as follows: negation ¬U = U; conjunction P ∧ Q = min(P, Q), treating U as intermediate between F and T; and disjunction P ∨ Q = max(P, Q). This preserves classical behavior for determinate cases while assigning U to expressions involving undefined components, such as in halting problem analyses.[19] Łukasiewicz logic, originally three-valued but extended to infinitely many values in [0,1], uses finite approximations for discrete cases. The implication connective is defined as P → Q = min(1, 1 - P + Q), enabling the logic to quantify degrees of entailment in a lattice structure. For instance, in the three-valued version, U → T = T and U → F = U, reflecting graded necessity. This system has been axiomatized and applied to modal interpretations of indeterminacy.[20] Supervaluationism provides another multi-valued approach, particularly for vague predicates like "tall" or "heap," where borderline cases receive intermediate values. A proposition is true if it holds in all admissible valuations (e.g., all precise sharpenings of the vague concept), false if it fails in all, and indeterminate otherwise. This preserves classical logic for non-vague sentences while accommodating gaps in truth-value for vagueness, without altering connectives directly.[21]Probabilistic and Fuzzy Variants
Probabilistic and fuzzy variants of truth values extend classical bivalence by allowing degrees of truth to model vagueness, uncertainty, and partial belief, typically drawing from the unit interval [0,1] where 0 represents complete falsity and 1 complete truth.[22] These approaches address limitations in discrete multi-valued logics by incorporating continuous scales, enabling nuanced representations of real-world ambiguity.[22] Fuzzy logic, introduced by Lotfi A. Zadeh in his seminal 1965 paper, formalizes truth values as membership degrees in fuzzy sets, allowing propositions to hold to varying extents rather than strictly true or false.[23] For instance, a statement like "this person is tall" might have a truth value of 0.8, reflecting partial applicability of the vague predicate "tall."[23] Logical operations in fuzzy logic are defined accordingly: conjunction is often the minimum function or the product , while disjunction uses the maximum or probabilistic sum , preserving the interval [0,1].[22] In probabilistic logic, truth values are interpreted as probabilities measuring the degree of belief in a proposition, integrating uncertainty through frameworks like Bayesian inference.[24] Here, the truth of a sentence is its probability under a probability distribution over possible worlds, updated via Bayes' theorem to reflect new evidence; for example, the posterior probability incorporates prior beliefs and likelihood .[25] This approach, formalized in early works like Nilsson's 1986 probabilistic logic, treats logical entailment as probabilistic consequence, where a premise entails a conclusion if the latter's probability exceeds a threshold given the former.[24] The Dunn-Belnap four-valued logic provides another variant by combining classical truth values {T, F} with epistemic dimensions of knowledge and ignorance, yielding values T (true and known), F (false and known), B (both true and false, or inconsistent), and N (neither, or unknown).[26] Introduced by Nuel Belnap in 1977, this system models information states in reasoning systems, such as databases with conflicting or incomplete data, where truth is assessed along truth/falsity and information/gap dimensions independently.[27] In modern AI applications, fuzzy and probabilistic truth values model uncertainty in machine learning, such as through confidence scores in neural networks where softmax outputs yield probabilistic degrees of class membership for predictions. For example, type-2 fuzzy sets enhance interpretability in explainable AI frameworks by modeling higher-order uncertainty, as in image classification tasks.[28] These variants also facilitate Bayesian neural networks, where probability distributions over weights quantify epistemic uncertainty in high-stakes domains like autonomous driving.[29]Algebraic Semantics
Boolean Algebras
In the context of truth values, a Boolean algebra provides the algebraic semantics for classical bivalence, modeling the two truth values—true (⊤) and false (⊥)—as the top and bottom elements of a partially ordered set. Formally, a Boolean algebra is a distributive lattice equipped with a complementation operation ¬ that satisfies specific axioms, ensuring every element has a unique complement. The lattice operations are the meet ∧ (corresponding to logical conjunction) and join ∨ (corresponding to logical disjunction), with the lattice ordered by implication (a ≤ b if a ∧ b = a). Distributivity holds: for all elements a, b, c in the algebra,and
.
Complementation ensures that for every element x, x ∧ ¬x = ⊥ and x ∨ ¬x = ⊤, where ⊥ is the least element (absorbing for meet) and ⊤ is the greatest element (absorbing for join). These properties make the two-element Boolean algebra {⊥, ⊤} the canonical model for classical truth values under conjunction, disjunction, and negation.[30] Any Boolean algebra admits homomorphisms to the two-element algebra of truth values {⊤, ⊥}, which assign consistent truth valuations to its elements. Such a homomorphism φ: B → {⊤, ⊥} preserves the operations: φ(a ∧ b) = φ(a) ∧ φ(b), φ(a ∨ b) = φ(a) ∨ φ(b), and φ(¬a) = ¬φ(a), with φ(⊥) = ⊥ and φ(⊤) = ⊤. These homomorphisms correspond precisely to the ultrafilters of the algebra, where an ultrafilter U is a maximal filter (upward-closed upset closed under meets, containing ⊤ but not ⊥) such that for every a in B, either a ∈ U or ¬a ∈ U but not both. The homomorphism is defined by φ(a) = ⊤ if a ∈ U and ⊥ otherwise, effectively evaluating the algebra at the "truth assignment" given by the ultrafilter. This connection underscores how Boolean algebras generalize the assignment of truth values in classical logic, with ultrafilters representing complete, consistent valuations.[31][32] A foundational result linking Boolean algebras to topology and set theory is Stone's representation theorem, which shows that every Boolean algebra is isomorphic to a field of clopen sets in a compact, totally disconnected Hausdorff space known as its Stone space. Specifically, for a Boolean algebra B, the Stone space X consists of the ultrafilters (or equivalently, maximal ideals) of B, equipped with the topology generated by basis sets {U_a | a ∈ B}, where U_a = {ultrafilters containing a}. The isomorphism maps each element a ∈ B to the clopen set U_a, preserving the algebra operations: U_a ∧ U_b = U_{a ∧ b}, U_a ∨ U_b = U_{a ∨ b}, and ¬U_a = U_{¬a}. This representation, proved in 1936, reveals Boolean algebras as concrete set algebras, with truth values emerging as the fixed points under homomorphisms to {⊤, ⊥}.[33] In classical propositional logic, the Lindenbaum–Tarski algebra provides a direct link between syntactic formulas and Boolean structure. For a set of propositional formulas, define equivalence φ ∼ ψ if the theory proves φ ↔ ψ; the equivalence classes [φ] form the carrier of the algebra, with operations [φ] ∧ [ψ] = [φ ∧ ψ], [φ] ∨ [ψ] = [φ ∨ ψ], and ¬[φ] = [¬φ]. The constants are ⊥ = [φ ∧ ¬φ] and ⊤ = [φ ∨ ¬φ]. This construction yields a Boolean algebra, known as the Lindenbaum–Tarski algebra of the logic, which is free on the generators corresponding to atomic propositions. It models how classical tautologies and contradictions align with the algebraic identities x ∨ ¬x = ⊤ and x ∧ ¬x = ⊥, providing an algebraic quotient of the formula syntax that captures bivalent truth valuations.[34]
