The minimization problem for syntax diagrams is considered. For this purpose, we transform the Wirth diagrams (WD) into syntax diagrams with multiport components (SD), which are similar to WD in their structure, but differ in the fact that the non-terminals in nonterminal nodes are replaced with the starting nodes of the corresponding components. On the set of SD nodes, we introduce a relation which possesses the equivalence property, dividing the set of nodes into equivalence classes. We prove that uniting an equivalence class into one node is an equivalence transformation. If an equivalence class includes the nodes of various components, then, as a result of uniting the class into one node, the components are united into one component, which has several inputs. The algorithms for dividing the set of nodes into equivalence classes and plotting a SD are suggested. The algorithm for dividing the set of nodes into equivalence classes is based on a serial partitioning of the set of nodes into subsets so that non-equivalent nodes fall into different subsets. After partitioning the set of nodes into equivalence classes, an SD is constructed. In the SD construction algorithm, for each equivalence class, the following actions are executed: only one node from the class is left in the SD, the remaining nodes of the class are deleted, and if some arc in the source diagram is going to the deleted node, then it is redirected to one of remaining nodes. We give an example which demonstrates that a SD plotted by the suggested algorithms is considerably smaller than the equivalent WD. The resulting SD, after minimization process, can be used to construct memory efficient programs for formal languages processing.
Download file
Counter downloads: 173
- Title Minimization of syntax diagrams with multiport components
- Headline Minimization of syntax diagrams with multiport components
- Publesher
Tomsk State University
- Issue Prikladnaya Diskretnaya Matematika - Applied Discrete Mathematics 41
- Date:
- DOI 10.17223/20710410/41/9
Keywords
формальный язык, синтаксическая диаграмма, отношение эквивалентности, минимизация, formal language, syntax diagram, equivalence relation, minimizationAuthors
References
Jensen K. and Wirth N. Pascal User Manual and Report. N.Y.: Springer Verlag, 1975. 167p.
Jensen K. and Wirth N. Pascal User Manual and Report. Berlin, Heidelberg: Springer Verlag, 1974. 170 p.
Легалов А.И., Швец Д. А., Легалов И. А. Формальные языки и трансляторы. Красноярск: Сибирский федеральный университет, 2007. 213 с.
Карпов Ю. Г. Теория и технология программирования. Основы построения трансляторов. СПб.: БХВ-Петербург, 2005. 272с.
Овердлов С. З. Методы трансляции. Вологда: ВоГУ, 2016. 235 с.
Овердлов С. З. Конструирование компиляторов. Saarbruken: Lap Lambert, 2015. 571с.
Мартыненко Б. К. Синтаксические диаграммы Н. Вирта и граф-схемы в Syntax-технологии // Компьютерные инструменты в образовании. 2014. №2. С. 3-19.
Рязанов Ю. Д., Севальнева М. Н. Анализ синтаксических диаграмм и синтез программ-распознавателей линейной сложности // Научные ведомости БелГУ. Сер. История. Политология. Экономика. Информатика. 2013. №8. С. 128-136.
Поляков В. М., Рязанов Ю. Д. Алгоритм построения нерекурсивных программ-распознавателей линейной сложности по детерминированным синтаксическим диаграммам // Вестник БГТУ им. В. Г. Шухова. 2013. №6. С. 194-199.

Minimization of syntax diagrams with multiport components | Prikladnaya Diskretnaya Matematika - Applied Discrete Mathematics. 2018. № 41. DOI: 10.17223/20710410/41/9
Download full-text version
Counter downloads: 572