Masters Theses
Date of Award
8-1986
Degree Type
Thesis
Degree Name
Master of Science
Major
Electrical Engineering
Major Professor
J. Douglas Birdwell
Committee Members
Robert W. Rochelle, J. Robin B. Cockett
Abstract
A software interface was designed and implemented to enable programs written in Prolog to create Fortran data objects and invoke Fortran subroutines with reference to these objects.
This research is a part of CASCADE, for Computer Aided System and Control Analysis and Design Environment, which is a government-sponsored project for research into computer aids for control systems designers [Birdwell 1984]. The CASCADE system was implemented in Prolog and Fortran.
Prolog programs must be executed within a Prolog programming environment. Its data structures and procedure invocation conventions are vastly different from those of conventional procedural languages such as Fortran. The effect is that most Prolog interpreters cannot communicate with other programming languages. Our knowledge-based computer aided design system requires both symbolic processing, for knowledge interpretation, and numerical processing, for model analysis and simulation; the symbolic processing software must interface with the numerical software.
An efficient interface has been implemented in this research to allow Prolog to create Fortran data objects and refer them to Fortran subroutines. To the user, the finished product appears as several pre-defined procedures (analogous to system supplied functions) in the Prolog programming environment. These procedures have side effects which create Fortran data objects and invoke Fortran subroutines.
This project was successful. Fortran arrays have been created and passed to Fortran subroutines which ran normally. But as a tool to connect Prolog to Fortran, the interface is still crude, as expected from a first attempt. Mamy potentially useful enhancements, such as more complex data structures and better input/output facilities, were contemplated, but more user experience is needed to select the few truly beneficial features.
To maintain a logical and regular structure, the interface was designed to connect Prolog to standard Fortran, without particular biases to facilitate the implementation of CASCADE. Although this caused delays in its subsequent adaptation to CASCADE, its regular structure should benefit long-term maintenance. The application of this software to other engineering problems in general is an important design consideration.
Recommended Citation
Fung, Kin M., "A data interface between Prolog and Fortran. " Master's Thesis, University of Tennessee, 1986.
https://trace.tennessee.edu/utk_gradthes/13696