I. Introduction to the Declarative Paradigm A. Motivation 1. review of the course plan why? what approaches did we identify? 2. programming is difficult, expensive What are the steps in building a computer system to do some job? What steps cost the most? Can we separate them? Which could we automate? 3. rapid prototyping How do we know if we're building the right system? What would help us do that better? What are the costs we care about in rapid prototyping? 4. summary ------------------------------------------ MOTIVATIONS FOR DECLARATIVE PROGRAMMING GOALS OF DECLARATIVE PROGRAMMING ------------------------------------------ B. Goals So what should our goals for declarative programming be, to solve the problems that motivate the paradigm? C. Orientation (reminder) How would you classify this kind of programming language, versus the others you know about? What are the categories of programming languages? 1. Procedural a. Imperative or von Neumann (mutation, assignment) b. Applicative (no mutation, no assignment) 2. Declarative (nonprocedural) a. Logic-oriented (horn-clauses) b. Database systems (relations + queries) c. Constraint-based ------------------------------------------ CONSTRAINT EXAMPLE ; Farenheit and Celsius F = M*C + B ; linear relationship 212 = M*100 + B ; boiling points 32 = M*0 + B ; freezing points F = 80 => C = 26.667 ------------------------------------------ d. Equational-logic based e. Rule-based (forward chaining)