Matrix Grammar

Lecture 2 min.



Matrix grammar is a formal grammar in which the production rules are grouped into finite sequences. The production rules cannot be applied individually, only as a sequence. When such a sequence is applied, the replacement is carried out according to each rule in the sequence, from the first to the last. The sequences are called matrices. A matrix grammar is an extension of a context-free grammar.

Formal definition

A matrix grammar is an ordered quadruple

Matrix Grammar

where

  • Matrix Grammar is a finite set of nonterminal symbols
  • Matrix Grammar is a finite set of terminal symbols
  • Matrix Grammar is the start symbol
  • Matrix Grammar is a finite set of nonempty sequences of ordered pairs

Matrix Grammar

The pairs are called production rules and are written as Matrix Grammar. The sequences are called matrices and are written as

Matrix Grammar

Let Matrix Grammar be the set of all production rules in the matrices Matrix Grammar of the matrix grammar Matrix Grammar. Then the grammar Matrix Grammar is a grammar of type Matrix Grammar, non-contracting, linear, Matrix Grammar-free, context-free or context-sensitive if and only if the grammar Matrix Grammar has this property.

For a matrix grammar Matrix Grammar a binary relation Matrix Grammar is defined, also denoted Matrix Grammar. For any Matrix Grammar, Matrix Grammar holds if and only if there exists an integer Matrix Grammar such that there exist words

Matrix Grammar

over the set V and

  • Matrix Grammar and Matrix Grammar
  • Matrix Grammar
  • Matrix Grammar and Matrix Grammar

If these conditions are satisfied, it is also said that Matrix Grammar holds with the specification Matrix Grammar.

Let Matrix Grammar be the reflexive transitive closure of the relation Matrix Grammar. Then the language generated by the matrix grammar Matrix Grammar is defined as follows:

Matrix Grammar

Example

Consider the matrix grammar

Matrix Grammar

where Matrix Grammar is the collection of the following matrices:

Matrix Grammar

These matrices, which contain only context-free rules, generate a context-sensitive language

Matrix Grammar

See also

  • [[b8374]]

See also

created: 2022-02-06
updated: 2026-09-29
118



Was this answer useful?
Choose a quick rating so we can improve the next answer for you.
How satisfied are you?


Comments

To leave a comment

If you have any suggestion, idea, thanks or comment, feel free to write. We really value feedback and are glad to hear your opinion.
To reply

Lectures and tutorial on "Computational linguistics"

Terms: Computational linguistics