Math 2.0

Computer science Definition

Regular language

Builds on Formal languageDeterministic finite automatonAlphabet

Definition

Let Σ\Sigma be an alphabet. A formal language L⊆Σ∗L \subseteq \Sigma^* is regular when there is a deterministic finite automaton AA with input alphabet Σ\Sigma such that L(A)=LL(A) = L.

Remarks

Example: over Σ={a,b}\Sigma = \set{a, b}, the language of words with an even number of aa's is regular. The DFA with states {0,1}\set{0, 1}, initial and accepting state 00, where aa swaps the two states and bb fixes them, accepts it. Non-example: {anbn:n≥0}\set{a^n b^n : n \ge 0} is not regular. Suppose a DFA with kk states accepted it. Then two of the words a0,a1,…,aka^0, a^1, \ldots, a^k, say aia^i and aja^j with i≠ji \ne j, would lead to the same state. So aibia^i b^i and ajbia^j b^i would be both accepted or both rejected. This is a contradiction, since aibi∈La^i b^i \in L and ajbi∉La^j b^i \notin L. Equivalent forms: LL is regular if and only if it is accepted by a nondeterministic finite automaton, if and only if it is the language of a regular expression. Every finite language is regular.

Reading path

To understand this page from the ground up, read these 4 pages in order. The foundations come first.

Show the path as a graph
Each page uses the pages above it. The colour of the bar on a box shows how strong the evidence is, and the box also gives it as text. The list has the same pages.
  • no evidence level
  1. Alphabet concept
  2. Deterministic finite automaton concept
  3. Formal language concept
  4. Regular language definition

Further reading

  1. Web https://en.wikipedia.org/wiki/Regular_language
About this page
TagNJ7G0XFCX3
URIm2://NJ7G0XFCX3
Kinddefinition
WritingW0 stub
MSC68Q45
DefinesRegular language
UsesFormal language, Deterministic finite automaton, Alphabet
Changed3 November 2026

Markdown · JSON · Edit on GitHub

What this page needs for W1

  • an inventory row: the row of the inventory that the node accounts for (0 of 1)
  • a source with a locator (0 of 1)

The writing levels say how complete the text of a page is. They do not measure its truth.

What links here

No page links to this page yet.