# Scope (logic)

In logic, the scope of a quantifier or connective is the shortest formula in which it occurs, determining the range in the formula to which the quantifier or connective is applied. The notions of a free variable and bound variable are defined in terms of whether that formula is within the scope of a quantifier, and the notions of a dominant connective and subordinate connective are defined in terms of whether a connective includes another within its scope.

## Connectives

Logical connectives :
| AND | $A\land B$, $A\cdot B$, $AB$, $A\&B$, $A\&\&B$ |
| equivalent | $A\equiv B$, $A\Leftrightarrow B$, $A\leftrightharpoons B$ |
| implies | $A\Rightarrow B$, $A\supset B$, $A\rightarrow B$ |
| NAND | $A{\overline {\land }}B$, $A\uparrow B$, $A\mid B$, ${\overline {A\cdot B}}$ |
| nonequivalent | $A\not \equiv B$, $A\not \Leftrightarrow B$, $A\nleftrightarrow B$ |
| NOR | $A{\overline {\lor }}B$, $A\downarrow B$, ${\overline {A+B}}$ |
| NOT | $\neg A$, $-A$, ${\overline {A}}$, $\sim A$ |
| OR | $A\lor B$, $A+B$, $A\mid B$, $A\parallel B$ |
| XNOR | $A\ {\text{XNOR}}\ B$ |
| XOR | $A{\underline {\lor }}B$, $A\oplus B$ |
| converse | $A\Leftarrow B$, $A\subset B$, $A\leftarrow B$ |
Related concepts :
Propositional calculusPredicate logicBoolean algebraTruth tableTruth functionBoolean functionFunctional completenessScope (logic) :
Applications :
Digital logicProgramming languagesMathematical logicPhilosophy of logic :
Category :
vte :
The scope of a logical connective occurring within a formula is the smallest well-formed formula that contains the connective in question. The connective with the largest scope in a formula is called its dominant connective, main connective, main operator, major connective, or principal connective; a connective within the scope of another connective is said to be subordinate to it.
For instance, in the formula $(\left(\left(P\rightarrow Q\right)\lor \lnot Q\right)\leftrightarrow \left(\lnot \lnot P\land Q\right))$, the dominant connective is ↔, and all other connectives are subordinate to it; the → is subordinate to the ∨, but not to the ∧; the first ¬ is also subordinate to the ∨, but not to the →; the second ¬ is subordinate to the ∧, but not to the ∨ or the →; and the third ¬ is subordinate to the second ¬, as well as to the ∧, but not to the ∨ or the →. If an order of precedence is adopted for the connectives, viz., with ¬ applying first, then ∧ and ∨, then →, and finally ↔, this formula may be written in the less parenthesized form $\left(P\rightarrow Q\right)\lor \lnot Q\leftrightarrow \lnot \lnot P\land Q$, which some may find easier to read.

## Quantifiers

The scope of a quantifier is the part of a logical expression over which the quantifier exerts control. It is the shortest full sentence written right after the quantifier, often in parentheses; some authors describe this as including the variable written right after the universal or existential quantifier. In the formula ∀xP, for example, P (or xP) is the scope of the quantifier ∀x (or ∀).
This gives rise to the following definitions:
* An occurrence of a quantifier $\forall$ or $\exists$, immediately followed by an occurrence of the variable $\xi$, as in $\forall \xi$ or $\exists \xi$, is said to be $\xi$-binding.
* An occurrence of a variable $\xi$ in a formula $\phi$ is free in $\phi$ if, and only if, it is not in the scope of any $\xi$-binding quantifier in $\phi$; otherwise it is bound in $\phi$.
* A closed formula is one in which no variable occurs free; a formula which is not closed is open.
* An occurrence of a quantifier $\forall \xi$ or $\exists \xi$ is vacuous if, and only if, its scope is $\forall \xi \psi$ or $\exists \xi \psi$, and the variable $\xi$ does not occur free in $\psi$.
* A variable $\zeta$ is free for a variable $\xi$ if, and only if, no free occurrences of $\xi$ lie within the scope of a quantification on $\zeta$.
* A quantifier whose scope contains another quantifier is said to have wider scope than the second, which, in turn, is said to have narrower scope than the first.