• Skip to primary navigation
  • Skip to main content
SRI logo
  • About
    • Press room
  • Expertise
    • Advanced imaging systems
    • Artificial intelligence
    • Biomedical R&D services
    • Biomedical sciences
    • Computer vision
    • Cyber & formal methods
    • Education and learning
    • Innovation strategy and policy
    • National security
    • Ocean & space
    • Quantum
    • QED-C
    • Robotics, sensors & devices
    • Speech & natural language
    • Video test & measurement
  • Ventures
  • NSIC
  • Careers
  • Contact
  • 日本支社
Search
Close
Cyber & formal methods publications June 1, 1983 Journal Article

Applied Logic and Its Use and Implementation As A Programming Tool

Citation

Copy to clipboard


Warren, D. H. (1978). Applied logic: its use and implementation as a programming tool.

Abstract

The first part of the thesis explains from first principles the concept of “logic programming’’ and its practical application in the programming language Prolog. Prolog is a simple but powerful language which encourages rapid, error-free programming and clear, readable, concise programs. The basic computational mechanism is a pattern matching process (“unification”) operating on general record structures (“terms’’ of logic). The ideas are illustrated by describing in detail one sizable Prolog program which implements a simple compiler. The advantages and practicability of using Prolog for “real’’ compiler implementation are discussed. The second part of the thesis describes techniques for implementing Prolog efficiently. In particular, it is shown how to compile the patterns involved in the matching process into instructions of a low-level language. This ideas has actually been implemented in a compiler (written in Prolog) from Prolog to DECsystem-10 assembly language. However, the principles involved are explained more abstractly in terms of a “Prolog Machine.” The code generated is comparable in speed with that produced by existing DEC10 Lisp compilers. Comparison is possible since pure Lisp can be viewed as a (rather restricted) subset of Prolog. It is argued that structured data objects, such as lists and trees, can be manipulated by pattern matching using a “structure sharing’’ representation as efficiently as by conventional selector and constructor functions operating on linked records in “heap’’ storage. Moreover, the pattern matching formulation actually helps the implementor to produce a better implementation.

↓ Download

Share this

How can we help?

Once you hit send…

We’ll match your inquiry to the person who can best help you.

Expect a response within 48 hours.

Career call to action image

Make your own mark.

Search jobs

Our work

Case studies

Publications

Timeline of innovation

Areas of expertise

Institute

Leadership

Press room

Media inquiries

Compliance

Careers

Job listings

Contact

SRI Ventures

Our locations

Headquarters

333 Ravenswood Ave
Menlo Park, CA 94025 USA

+1 (650) 859-2000

Subscribe to our newsletter


日本支社
SRI International
  • Contact us
  • Privacy Policy
  • Cookies
  • DMCA
  • Copyright © 2022 SRI International