Context-sensitive language
Builds on Formal grammarFormal languageContext-free language
Definition
A context-sensitive grammar is a formal grammar in which every rule has one of the following forms:
- , where , and is nonempty;
- , allowed only if does not occur on the right side of any rule.
A formal language is context-sensitive if for some context-sensitive grammar .
Remarks
Equivalently, is context-sensitive if it is generated by a noncontracting grammar, one whose rules satisfy , again with the exception . Example: is context-sensitive; the rules , , , , , , form a noncontracting grammar for it. Non-example: a rule is not allowed, since it shortens the string and is not of the form of clause 2. Every context-free language is context-sensitive, and every context-sensitive language is decidable.
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
- no evidence level
- Context-free language concept
- Formal grammar concept
- Formal language concept
- Context-sensitive language definition
Further reading
About this page
| Tag | 9YGQ5X06J6 |
|---|---|
| URI | m2://9YGQ5X06J6 |
| Kind | definition |
| Writing | W0 stub |
| MSC | 68Q45, 68Q42 |
| Defines | Context-sensitive language |
| Uses | Formal grammar, Formal language, Context-free language |
| Changed | 3 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.