 |
advertisement |
|
|
|
|
|
|
|
Instruments and Systems: Monitoring, Control, and Diagnostics Annotation << Back
|
The Oretical Foundations of the Organization of Branches and Repetitions in Programs in the Logical Programming Language Prolog |
D.V. ZDOR
The article is devoted to the problem of branching and repetition organization in the context of logical programming using the example of the Prolog language. A fundamental feature of a program in a logical programming language is the fact that a computer must solve a problem by reasoning like a person. A program in a logical language contains a description of objects and relations between them in the language of mathematical logic. At the same time, the issue of software implementation of branching and repetition remains relevant in the absence of special operators in the logical language that implement the indicated constructions. Purpose of the work: to identify ways to solve problems using branches and repetitions using the logic programming language Prolog, to demonstrate the results obtained using examples of computational problems. Analysis of special literature on the topic of research, generalization and systematization of knowledge, testing of the program, analysis of the progress of the program. Constructions of branching and repetition organization in a Prolog program are proposed. To organize repetitions, various options for completing a recursive cycle in solving problems are proposed. The article discusses various ways of organizing branches and repetitions in the logic programming language Prolog. All considered methods were demonstrated by examples of solving computational problems. The results obtained can be used in the further development of the issues of using recursive predicates in logical programming languages, as well as used in the educational process in the study of logical programming in the Prolog language.
Keywords: logical programming, branching, repetition of predicates, recursive rule, recursion termination condition.
DOI: 10.25791/pribor.9.2021.1290
Pp. 20-24. |
|
|
|
Last news:
Выставки по автоматизации и электронике «ПТА-Урал 2018» и «Электроника-Урал 2018» состоятся в Екатеринбурге Открыта электронная регистрация на выставку Дефектоскопия / NDT St. Petersburg Открыта регистрация на 9-ю Международную научно-практическую конференцию «Строительство и ремонт скважин — 2018» ExpoElectronica и ElectronTechExpo 2018: рост площади экспозиции на 19% и новые формы контент-программы Тематика и состав экспозиции РЭП на выставке "ChipEXPO - 2018" |