Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

// request.cf · coarse context

A page that knows where it met you.

Only coarse request metadata is shown. This demo does not display or persist visitor IP addresses.

Country
US
Cloudflare location
CMH
Connection
HTTP/2
Language
Not provided

Ray ID: a23262f0c8c8cb43

Jump to content

// Workers AI · dad joke modeWhat did NFA minimization say to its date? You reduce me.

From Wikipedia, the free encyclopedia

In automata theory (a branch of theoretical computer science), NFA minimization is the task of transforming a given nondeterministic finite automaton (NFA) into an equivalent NFA that has a minimum number of states. While efficient algorithms exist for DFA minimization, NFA minimization is PSPACE-complete.[1] No efficient (polynomial time) algorithms are known, and under the standard assumption that PPSPACE, none exist. The most efficient known algorithm is the Kameda–Weiner algorithm.[2]

Non-uniqueness of minimal NFA

[edit]
NFA 2
NFA 1

Unlike deterministic finite automata, minimal NFAs need not be unique. There can be several non-isomorphic NFAs with the same (minimum) number of states accepting the same regular language, with no smaller equivalent NFA existing.[2]

For example, the language ending in , denoted by over the alphabet , has no NFA with fewer than 3 states. There is a three-state minimal DFA that deterministically tracks how much of the suffix has been seen so far (see picture NFA 1). Furthermore, there is a non-isomorphic minimal NFA for the same language that instead non-deterministically guesses at each whether it begins the final , accepting if that guess is confirmed by the string's end (NFA 2).

References

[edit]
  1. Jiang, Tao; Ravikumar, B. (1993), "Minimal NFA Problems are Hard", SIAM Journal on Computing, 22 (6): 1117–1141, doi:10.1137/0222067
  2. 1 2 Kameda, Tsunehiko; Weiner, Peter (August 1970). "On the State Minimization of Nondeterministic Finite Automata". IEEE Transactions on Computers. C-19 (7). IEEE: 617–627. doi:10.1109/T-C.1970.222994. S2CID 31188224. Retrieved 2020-05-03.
[edit]
  • A modified C# implementation of Kameda–Weiner (1970)