Language

2 min read Last updated Thu Jun 11 2026 13:19:10 GMT+0000 (Coordinated Universal Time)

A set of strings.

Any language over Σ\Sigma is a subset of Σ\Sigma^*.

Operations

Set operations can be applied to languages as they are basically sets.

Language Quotient

Let LΣL \subseteq \Sigma^* and x,yΣx, y \in \Sigma^*. Set of all strings zz such that xzxz is in LL.

L/x={zΣxzL}L/x = \set{ z \in \Sigma^* \mid xz \in L }

Repetition

LkL^k is concatenation of LL with itself kk times. L0={Λ}L^0 = \{\Lambda\}.

Kleene Star and Plus

Kleene Star

LL^* = zero or more concatenations of LL.

Kleene Plus

L+L^+ = one or more concatenations of LL. Can also be written as LLL^*L or LLLL^*.

Basic Language

For a given alphabet Σ\Sigma, its basic languages are:

  • {a}\set{a} for each symbol aΣa \in Σ
  • \varnothing (empty language)
  • {λ}\set{\lambda} (language containing the null string)

Recognizing a Language

Language recognition means deciding whether a given string belongs to a language.

Recognition is done by reading input left to right in one pass.

Distinguishing Strings

2 strings xx and yy are distinguishable with respect to a language LL if their language quotients are different.

x and y are distinguishable in L    L/xL/yx\text{ and }y \text{ are distinguishable in } L \iff L/x \neq L/y

Any string in one of these sets but not the other is said to distinguish xx and yy with respect to LL.

Was this helpful?