HOME

TheInfoList



OR:

In
mathematical logic Mathematical logic is the study of formal logic within mathematics. Major subareas include model theory, proof theory, set theory, and recursion theory. Research in mathematical logic commonly addresses the mathematical properties of forma ...
,
propositional logic Propositional calculus is a branch of logic. It is also called propositional logic, statement logic, sentential calculus, sentential logic, or sometimes zeroth-order logic. It deals with propositions (which can be true or false) and relations b ...
and
predicate logic First-order logic—also known as predicate logic, quantificational logic, and first-order predicate calculus—is a collection of formal systems used in mathematics, philosophy, linguistics, and computer science. First-order logic uses quantifie ...
, a well-formed formula, abbreviated WFF or wff, often simply formula, is a finite
sequence In mathematics, a sequence is an enumerated collection of objects in which repetitions are allowed and order matters. Like a set, it contains members (also called ''elements'', or ''terms''). The number of elements (possibly infinite) is called ...
of
symbols A symbol is a mark, sign, or word that indicates, signifies, or is understood as representing an idea, object, or relationship. Symbols allow people to go beyond what is known or seen by creating linkages between otherwise very different co ...
from a given
alphabet An alphabet is a standardized set of basic written graphemes (called letters) that represent the phonemes of certain spoken languages. Not all writing systems represent language in this way; in a syllabary, each character represents a syllab ...
that is part of a
formal language In logic, mathematics, computer science, and linguistics, a formal language consists of words whose letters are taken from an alphabet and are well-formed according to a specific set of rules. The alphabet of a formal language consists of sym ...
. A formal language can be identified with the set of formulas in the language. A formula is a
syntactic In linguistics, syntax () is the study of how words and morphemes combine to form larger units such as phrases and sentences. Central concerns of syntax include word order, grammatical relations, hierarchical sentence structure (constituency) ...
object that can be given a semantic meaning by means of an
interpretation Interpretation may refer to: Culture * Aesthetic interpretation, an explanation of the meaning of a work of art * Allegorical interpretation, an approach that assumes a text should not be interpreted literally * Dramatic Interpretation, an event ...
. Two key uses of formulas are in propositional logic and predicate logic.


Introduction

A key use of formulas is in
propositional logic Propositional calculus is a branch of logic. It is also called propositional logic, statement logic, sentential calculus, sentential logic, or sometimes zeroth-order logic. It deals with propositions (which can be true or false) and relations b ...
and
predicate logic First-order logic—also known as predicate logic, quantificational logic, and first-order predicate calculus—is a collection of formal systems used in mathematics, philosophy, linguistics, and computer science. First-order logic uses quantifie ...
such as
first-order logic First-order logic—also known as predicate logic, quantificational logic, and first-order predicate calculus—is a collection of formal systems used in mathematics, philosophy, linguistics, and computer science. First-order logic uses quantifie ...
. In those contexts, a formula is a string of symbols φ for which it makes sense to ask "is φ true?", once any
free variable In mathematics, and in other disciplines involving formal languages, including mathematical logic and computer science, a free variable is a notation (symbol) that specifies places in an expression where substitution may take place and is not ...
s in φ have been instantiated. In formal logic,
proof Proof most often refers to: * Proof (truth), argument or sufficient evidence for the truth of a proposition * Alcohol proof, a measure of an alcoholic drink's strength Proof may also refer to: Mathematics and formal logic * Formal proof, a c ...
s can be represented by sequences of formulas with certain properties, and the final formula in the sequence is what is proven. Although the term "formula" may be used for written marks (for instance, on a piece of paper or chalkboard), it is more precisely understood as the sequence of symbols being expressed, with the marks being a
token Token may refer to: Arts, entertainment, and media * Token, a game piece or counter, used in some games * The Tokens, a vocal music group * Tolkien Black, a recurring character on the animated television series ''South Park,'' formerly known a ...
instance of formula. This distinction between the vague notion of "property" and the inductively-defined notion of well-formed formula has roots in Weyl's 1910 paper "Uber die Definitionen der mathematischen Grundbegriffe". Thus the same formula may be written more than once, and a formula might in principle be so long that it cannot be written at all within the physical universe. Formulas themselves are syntactic objects. They are given meanings by interpretations. For example, in a propositional formula, each propositional variable may be interpreted as a concrete proposition, so that the overall formula expresses a relationship between these propositions. A formula need not be interpreted, however, to be considered solely as a formula.


Propositional calculus

The formulas of
propositional calculus Propositional calculus is a branch of logic. It is also called propositional logic, statement logic, sentential calculus, sentential logic, or sometimes zeroth-order logic. It deals with propositions (which can be true or false) and relations b ...
, also called
propositional formula In propositional logic, a propositional formula is a type of syntactic formula which is well formed and has a truth value. If the values of all variables in a propositional formula are given, it determines a unique truth value. A propositional for ...
s, are expressions such as (A \land (B \lor C)). Their definition begins with the arbitrary choice of a set ''V'' of
propositional variable In mathematical logic, a propositional variable (also called a sentential variable or sentential letter) is an input variable (that can either be true or false) of a truth function. Propositional variables are the basic building-blocks of proposit ...
s. The alphabet consists of the letters in ''V'' along with the symbols for the propositional connectives and parentheses "(" and ")", all of which are assumed to not be in ''V''. The formulas will be certain expressions (that is, strings of symbols) over this alphabet. The formulas are inductively defined as follows: * Each propositional variable is, on its own, a formula. * If φ is a formula, then ¬φ is a formula. * If φ and ψ are formulas, and • is any binary connective, then ( φ • ψ) is a formula. Here • could be (but is not limited to) the usual operators ∨, ∧, →, or ↔. This definition can also be written as a formal grammar in
Backus–Naur form In computer science, Backus–Naur form () or Backus normal form (BNF) is a metasyntax notation for context-free grammars, often used to describe the syntax of languages used in computing, such as computer programming languages, document format ...
, provided the set of variables is finite: Using this grammar, the sequence of symbols :(((''p'' → ''q'') ∧ (''r'' → ''s'')) ∨ (¬''q'' ∧ ¬''s'')) is a formula, because it is grammatically correct. The sequence of symbols :((''p'' → ''q'')→(''qq''))''p'')) is not a formula, because it does not conform to the grammar. A complex formula may be difficult to read, owing to, for example, the proliferation of parentheses. To alleviate this last phenomenon, precedence rules (akin to the standard mathematical order of operations) are assumed among the operators, making some operators more binding than others. For example, assuming the precedence (from most binding to least binding) 1. ¬   2. →  3. ∧  4. ∨. Then the formula :(((''p'' → ''q'') ∧ (''r'' → ''s'')) ∨ (¬''q'' ∧ ¬''s'')) may be abbreviated as :''p'' → ''q'' ∧ ''r'' → ''s'' ∨ ¬''q'' ∧ ¬''s'' This is, however, only a convention used to simplify the written representation of a formula. If the precedence was assumed, for example, to be left-right associative, in following order: 1. ¬   2. ∧  3. ∨  4. →, then the same formula above (without parentheses) would be rewritten as :(''p'' → (''q'' ∧ ''r'')) → (''s'' ∨ ((¬''q'') ∧ (¬''s'')))


Predicate logic

The definition of a formula in
first-order logic First-order logic—also known as predicate logic, quantificational logic, and first-order predicate calculus—is a collection of formal systems used in mathematics, philosophy, linguistics, and computer science. First-order logic uses quantifie ...
\mathcal is relative to the
signature A signature (; from la, signare, "to sign") is a Handwriting, handwritten (and often Stylization, stylized) depiction of someone's name, nickname, or even a simple "X" or other mark that a person writes on documents as a proof of identity and ...
of the theory at hand. This signature specifies the constant symbols, predicate symbols, and function symbols of the theory at hand, along with the arities of the function and predicate symbols. The definition of a formula comes in several parts. First, the set of terms is defined recursively. Terms, informally, are expressions that represent objects from the
domain of discourse In the formal sciences, the domain of discourse, also called the universe of discourse, universal set, or simply universe, is the set of entities over which certain variables of interest in some formal treatment may range. Overview The doma ...
. #Any variable is a term. #Any constant symbol from the signature is a term #an expression of the form ''f''(''t''1,…,''t''''n''), where ''f'' is an ''n''-ary function symbol, and ''t''1,…,''t''''n'' are terms, is again a term. The next step is to define the
atomic formula In mathematical logic, an atomic formula (also known as an atom or a prime formula) is a formula with no deeper propositional structure, that is, a formula that contains no logical connectives or equivalently a formula that has no strict subformu ...
s. #If ''t''1 and ''t''2 are terms then ''t''1=''t''2 is an atomic formula #If ''R'' is an ''n''-ary predicate symbol, and ''t''1,…,''t''''n'' are terms, then ''R''(''t''1,…,''t''''n'') is an atomic formula Finally, the set of formulas is defined to be the smallest set containing the set of atomic formulas such that the following holds: #\neg\phi is a formula when \phi is a formula #(\phi \land \psi) and (\phi \lor \psi) are formulas when \phi and \psi are formulas; #\exists x\, \phi is a formula when x is a variable and \phi is a formula; #\forall x\, \phi is a formula when x is a variable and \phi is a formula (alternatively, \forall x\, \phi could be defined as an abbreviation for \neg\exists x\, \neg\phi). If a formula has no occurrences of \exists x or \forall x, for any variable x, then it is called quantifier-free. An ''existential formula'' is a formula starting with a sequence of
existential quantification In predicate logic, an existential quantification is a type of quantifier, a logical constant which is interpreted as "there exists", "there is at least one", or "for some". It is usually denoted by the logical operator symbol ∃, which, ...
followed by a quantifier-free formula.


Atomic and open formulas

An ''atomic formula'' is a formula that contains no
logical connective In logic, a logical connective (also called a logical operator, sentential connective, or sentential operator) is a logical constant. They can be used to connect logical formulas. For instance in the syntax of propositional logic, the binary ...
s nor quantifiers, or equivalently a formula that has no strict subformulas. The precise form of atomic formulas depends on the formal system under consideration; for
propositional logic Propositional calculus is a branch of logic. It is also called propositional logic, statement logic, sentential calculus, sentential logic, or sometimes zeroth-order logic. It deals with propositions (which can be true or false) and relations b ...
, for example, the atomic formulas are the
propositional variable In mathematical logic, a propositional variable (also called a sentential variable or sentential letter) is an input variable (that can either be true or false) of a truth function. Propositional variables are the basic building-blocks of proposit ...
s. For
predicate logic First-order logic—also known as predicate logic, quantificational logic, and first-order predicate calculus—is a collection of formal systems used in mathematics, philosophy, linguistics, and computer science. First-order logic uses quantifie ...
, the atoms are predicate symbols together with their arguments, each argument being a
term Term may refer to: * Terminology, or term, a noun or compound word used in a specific context, in particular: **Technical term, part of the specialized vocabulary of a particular field, specifically: ***Scientific terminology, terms used by scient ...
. According to some terminology, an ''open formula'' is formed by combining atomic formulas using only logical connectives, to the exclusion of quantifiers. This is not to be confused with a formula which is not closed.


Closed formulas

A ''closed formula'', also ''
ground Ground may refer to: Geology * Land, the surface of the Earth not covered by water * Soil, a mixture of clay, sand and organic matter present on the surface of the Earth Electricity * Ground (electricity), the reference point in an electrical c ...
formula'' or ''sentence'', is a formula in which there are no free occurrences of any variable. If A is a formula of a first-order language in which the variables have free occurrences, then A preceded by is a closure of A.


Properties applicable to formulas

* A formula A in a language \mathcal is '' valid'' if it is true for every
interpretation Interpretation may refer to: Culture * Aesthetic interpretation, an explanation of the meaning of a work of art * Allegorical interpretation, an approach that assumes a text should not be interpreted literally * Dramatic Interpretation, an event ...
of \mathcal. * A formula A in a language \mathcal is ''
satisfiable In mathematical logic, a formula is ''satisfiable'' if it is true under some assignment of values to its variables. For example, the formula x+3=y is satisfiable because it is true when x=3 and y=6, while the formula x+1=x is not satisfiable ove ...
'' if it is true for some
interpretation Interpretation may refer to: Culture * Aesthetic interpretation, an explanation of the meaning of a work of art * Allegorical interpretation, an approach that assumes a text should not be interpreted literally * Dramatic Interpretation, an event ...
of \mathcal. * A formula A of the language of
arithmetic Arithmetic () is an elementary part of mathematics that consists of the study of the properties of the traditional operations on numbers— addition, subtraction, multiplication, division, exponentiation, and extraction of roots. In the 19th ...
is ''decidable'' if it represents a decidable set, i.e. if there is an
effective method In logic, mathematics and computer science, especially metalogic and computability theory, an effective method Hunter, Geoffrey, ''Metalogic: An Introduction to the Metatheory of Standard First-Order Logic'', University of California Press, 1971 or ...
which, given a
substitution Substitution may refer to: Arts and media *Chord substitution, in music, swapping one chord for a related one within a chord progression *Substitution (poetry), a variation in poetic scansion * "Substitution" (song), a 2009 song by Silversun Pic ...
of the free variables of A, says that either the resulting instance of A is provable or its negation is.


Usage of the terminology

In earlier works on mathematical logic (e.g. by
Church Church may refer to: Religion * Church (building), a building for Christian religious activities * Church (congregation), a local congregation of a Christian denomination * Church service, a formalized period of Christian communal worship * Chri ...
), formulas referred to any strings of symbols and among these strings, well-formed formulas were the strings that followed the formation rules of (correct) formulas. Several authors simply say formula. Modern usages (especially in the context of computer science with mathematical software such as
model checkers In computer science, model checking or property checking is a method for checking whether a finite-state model of a system meets a given specification (also known as correctness). This is typically associated with hardware or software systems ...
,
automated theorem prover Automated theorem proving (also known as ATP or automated deduction) is a subfield of automated reasoning and mathematical logic dealing with proving mathematical theorems by computer programs. Automated reasoning over mathematical proof was a m ...
s, interactive theorem provers) tend to retain of the notion of formula only the algebraic concept and to leave the question of
well-formedness __NOTOC__ Well-formedness is the quality of a clause, word, or other linguistic element that conforms to the grammar of the language of which it is a part. Well-formed words or phrases are grammatical, meaning they obey all relevant rules of gramma ...
, i.e. of the concrete string representation of formulas (using this or that symbol for connectives and quantifiers, using this or that parenthesizing convention, using Polish or
infix An infix is an affix inserted inside a word stem (an existing word or the core of a family of words). It contrasts with '' adfix,'' a rare term for an affix attached to the outside of a stem, such as a prefix or suffix. When marking text for i ...
notation, etc.) as a mere notational problem. While the expression ''well-formed formula'' is still in use, these authors do not necessarily use it in contradistinction to the old sense of ''formula'', which is no longer common in mathematical logic. The expression "well-formed formulas" (WFF) also crept into popular culture. ''WFF'' is part of an esoteric pun used in the name of the academic game "
WFF 'N PROOF WFF 'N PROOF is a game of modern logic, developed to teach principles of symbolic logic. It was developed by Layman E. Allen in 1962 a former professor of Yale Law School and the University of Michigan. Rules In the game, players must be able ...
: The Game of Modern Logic," by Layman Allen, developed while he was at
Yale Law School Yale Law School (Yale Law or YLS) is the law school of Yale University, a private research university in New Haven, Connecticut. It was established in 1824 and has been ranked as the best law school in the United States by '' U.S. News & World ...
(he was later a professor at the
University of Michigan , mottoeng = "Arts, Knowledge, Truth" , former_names = Catholepistemiad, or University of Michigania (1817–1821) , budget = $10.3 billion (2021) , endowment = $17 billion (2021)As o ...
). The suite of games is designed to teach the principles of symbolic logic to children (in
Polish notation Polish notation (PN), also known as normal Polish notation (NPN), Łukasiewicz notation, Warsaw notation, Polish prefix notation or simply prefix notation, is a mathematical notation in which operators ''precede'' their operands, in contrast ...
). Its name is an echo of ''
whiffenpoof A whiffenpoof was a tool for training Boy Scouts in tracking skills. The whiffenpoof itself was a small log, about the size of a stick of firewood, with nails driven into it on all sides, so that it bristled with nails. This was dragged through th ...
'', a
nonsense word A nonsense word, unlike a sememe, may have no definition. Nonsense words can be classified depending on their orthographic and phonetic similarity with (meaningful) words. If it can be pronounced according to a language's phonotactics, it is a ps ...
used as a
cheer Cheering involves the uttering or making of sounds and may be used to encourage, excite to action, indicate approval or welcome. The word cheer originally meant face, countenance, or expression, and came through Old French into Middle Engli ...
at
Yale University Yale University is a private research university in New Haven, Connecticut. Established in 1701 as the Collegiate School, it is the third-oldest institution of higher education in the United States and among the most prestigious in the w ...
made popular in ''The Whiffenpoof Song'' and
The Whiffenpoofs The Yale Whiffenpoofs is a collegiate a cappella singing group. Established at Yale University in 1909, it is the oldest such group in the United States. The line-up is completely replaced each year: the group is always composed of rising senio ...
.Allen (1965) acknowledges the pun.


See also

*
Ground expression In mathematical logic, a ground term of a formal system is a term that does not contain any variables. Similarly, a ground formula is a formula that does not contain any variables. In first-order logic with identity, the sentence Q(a) \lor P(b ...
*
Well-defined expression In mathematics, a well-defined expression or unambiguous expression is an expression whose definition assigns it a unique interpretation or value. Otherwise, the expression is said to be ''not well defined'', ill defined or ''ambiguous''. A func ...


Notes


References

* * * * * * * * *


External links


Well-Formed Formula for First Order Predicate Logic
- includes a short
Java Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
quiz.
Well-Formed Formula at ProvenMath
{{DEFAULTSORT:Well-Formed Formula Formal languages Metalogic Syntax (logic) Mathematical logic