Here, words like sentences, alphabet, etc. are mathematical terms, and not their traditional meanings.

A formula can be thought of as a string, which here is an array of symbols.

%%🖋 Edit in Excalidraw, and the dark exported image%%

Definition

Formula (Logic) ^definition

A formula, , is defined as a sequence of symbols from some set of symbols, (known as its vocabulary). More specifically, a formula is an element of the set of all finite-length formulae, that can be defined from its corresponding vocabulary:

Well-formed Formula (WFF)

Well-formed Formula ^definition-wff

A formula, , is well-formed if belongs to some formal language, :

Examples

Example: Natural Alphabet

We can take the vocabulary/alphabet to be our natural, English lowercase alphabet. Then . Any permutation of the symbols is a valid formula, even ones that seem to ‘make no sense’:

  • is just as much of a formula as

Our set of all finite-length words would start off as:

Then we begin by looking at all words/formulae of length 2:

(where means the empty formula, consisting of no symbols)

And continue this process for all finite words of length .

Example: Binary

In binary, we have a much smaller vocabulary. . Valid formulas include:

would be the set of all finite-length binary strings.