Andreas Bauer, Viorica Botea, Mark Brown, Matt Gray, Daniel Harabor & John Slaney CP 2010, 522—536 Presented by Heath Roehr.

Slides:



Advertisements
Similar presentations
Designing a Program & the Java Programming Language
Advertisements

Introduction. IC-Parc2 ECLiPSe Components Constraint Logic Programming system, consisting of  A runtime core Data-driven computation, backtracking, garbage.
CS0004: Introduction to Programming Visual Studio 2010 and Controls.
G53CLP Constraint Logic Programming Modeling CSPs – Case Study I Dr Rong Qu.
Creating a Program In today’s lesson we will look at: what programming is different types of programs how we create a program installing an IDE to get.
Visual Basic 2010 How to Program. © by Pearson Education, Inc. All Rights Reserved.2.
Visual Basic 2010 How to Program Reference: Instructor: Maysoon Bin Duwais slides Visual Basic 2010 how to program by Deitel © by Pearson Education,
Computer Software & Software Development H&K Chapter 1 Instructor – Gokcen Cilingir Cpt S 121 (June 20, 2011) Washington State University.
Constraint Logic Programming Ryan Kinworthy. Overview Introduction Logic Programming LP as a constraint programming language Constraint Logic Programming.
Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Starting Out with Programming Logic & Design First Edition by Tony Gaddis.
Algorithms and Problem Solving-1 Algorithms and Problem Solving.
System Design and Analysis
The IDE (Integrated Development Environment) provides a DEBUGGER for locating and correcting errors in program logic (logic errors not syntax errors) The.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Java Programming, 3e Concepts and Techniques Chapter 1 An Introduction to Java and Program Design.
1 CSC 1401 S1 Computer Programming I Hamid Harroud School of Science and Engineering, Akhawayn University
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
Programming Fundamentals (750113) Ch1. Problem Solving
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
Principles of Procedural Programming
An Overview of Computers and Programming
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Chapter Introduction to Computers and Programming 1.
Java Programming, 2E Introductory Concepts and Techniques Chapter 1 An Introduction to Java and Program Design.
Programming Languages: Telling the Computers What to Do Chapter 16.
Introduction to Programming Lecture Number:. What is Programming Programming is to instruct the computer on what it has to do in a language that the computer.
© Janice Regan, CMPT 128, Jan CMPT 128 Introduction to Computing Science for Engineering Students Creating a program.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming 1.
Chapter 1: Introduction to Computers and Programming.
Copyright © 2009 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 1: Introduction to Computers and Programming.
PYTHON. Python is a high-level, interpreted, interactive and object- oriented scripting language. Python was designed to be highly readable which uses.
Transformation of Timed Automata into Mixed Integer Linear Programs Sebastian Panek.
Python – Part 1 Python Programming Language 1. What is Python? High-level language Interpreted – easy to test and use interactively Object-oriented Open-source.
Computer Concepts 2014 Chapter 12 Computer Programming.
Introduction to the Visual Studio.NET IDE (LAB 1 )
Visual C++ Programming: Concepts and Projects
1 Problem Solving with C++ The Object of Programming Walter Savitch Chapter 1 Introduction to Computers and C++ Programming Slides by David B. Teague,
An Object-Oriented Approach to Programming Logic and Design Fourth Edition Chapter 5 Arrays.
Guide to Programming with Python Chapter One Getting Started: The Game Over Program.
C++ Programming Language Lecture 2 Problem Analysis and Solution Representation By Ghada Al-Mashaqbeh The Hashemite University Computer Engineering Department.
Control Structures (A) Topics to cover here: Introduction to Control Structures in the algorithmic language Sequencing.
C++ Programming Basic Learning Prepared By The Smartpath Information systems
The basics of the programming process The development of programming languages to improve software development Programming languages that the average user.
Debugging parallel programs. Breakpoint debugging Probably the most widely familiar method of debugging programs is breakpoint debugging. In this method,
Celluloid An interactive media sequencing language.
Weaving a Debugging Aspect into Domain-Specific Language Grammars SAC ’05 PSC Track Santa Fe, New Mexico USA March 17, 2005 Hui Wu, Jeff Gray, Marjan Mernik,
G53CLP Constraint Logic Programming
Programming Languages
Finite State Machines (FSM) OR Finite State Automation (FSA) - are models of the behaviors of a system or a complex object, with a limited number of defined.
 Fall Chart 2  Translators and Compilers  Textbook o Programming Language Processors in Java, Authors: David A. Watts & Deryck F. Brown, 2000,
The Hashemite University Computer Engineering Department
Concepts and Realization of a Diagram Editor Generator Based on Hypergraph Transformation Author: Mark Minas Presenter: Song Gu.
ALGORITHMS AND FLOWCHARTS. Why Algorithm is needed? 2 Computer Program ? Set of instructions to perform some specific task Is Program itself a Software.
Alexandria University Faculty of Science Computer Science Department Introduction to Programming C++
Project Information Abstract Project Objectives The objective of this project is to: Create a visual designer that will allow inexperienced end- users.
Evolution of C and C++ n C was developed by Dennis Ritchie at Bell Labs (early 1970s) as a systems programming language n C later evolved into a general-purpose.
Software Design and Development Languages and Environments Computing Science.
1 Budapest University of Technology and Economics Department of Measurement and Information Systems Budapest University of Technology and Economics Fault.
Chapter 1: Introduction to Computers and Programming.
Programming Languages Concepts Chapter 1: Programming Languages Concepts Lecture # 4.
Chapter 6 Testing and running a solution. Errors X Three types Syntax Logic Run-time.
 Problem Analysis  Coding  Debugging  Testing.
C++ Programming Basics C++ Lecture 1 Stacy MacAllister.
CIS 115 All Exercises Devry University (Devry) FOR MORE CLASSES VISIT CIS 115 All Exercises Devry University.
Programming Logic and Design Seventh Edition Chapter 1 An Overview of Computers and Programming.
IS 350 Course Introduction. Slide 2 Objectives Identify the steps performed in the software development life cycle Describe selected tools used to design.
Advanced Higher Computing Science
1-1 Logic and Syntax A computer program is a solution to a problem.
Programming Right from the Start with Visual Basic .NET 1/e
Programming Fundamentals (750113) Ch1. Problem Solving
Presentation transcript:

Andreas Bauer, Viorica Botea, Mark Brown, Matt Gray, Daniel Harabor & John Slaney CP 2010, 522—536 Presented by Heath Roehr

 The G12 Platform  Zinc: Constraint Modeling Language  The G12 IDE  Modeling Layer: Meet-Pass Scenario  Solving Layer  Visualization Layer  Debugging with the G12 IDE  Conclusion & Questions HEATH ROEHR 2

Software platform for solving large-scale combinatorial optimization problems Supports Linear & mixed integer programming Constraint propagation & inference ┼ A variety of other search & inference techniques for solving complex problems 3 HEATH ROEHR

Zinc is a first-order functional language with simple, declarative semantics Modeling languages separate the constraint model from the constraint program It provides Mathematical notation-like syntax Expressive constraints (finite domain and integer, set and linear arithmetic) Separation of data from model High-level data structures and data encapsulation including constrained types User defined functions and constraints HEATH ROEHR 4

5

 The G12 Platform  Zinc: Constraint Modeling Language  The G12 IDE  Modeling Layer: Meet-Pass Scenario  Solving Layer  Visualization Layer  Debugging with the G12 IDE  Conclusion & Questions HEATH ROEHR 6

Solving The problems are computationally challenging Debugging? Remember your homework... Conceptualizing & improving search Staring at code is not really the smartest strategy 7 HEATH ROEHR

8

9

10 Write constraint models in the input languages of G12 (Zinc & MiniZinc) Vector-oriented drawing tool Associated script editor to build custom animations

HEATH ROEHR 11 MEET-PASS SCENARIO Five sectors of railway track, S1,... S5, are linearly connected There is a siding accessible from S3 big enough to hold one train Initially, there are trains in sectors S1, S2 and S4 S1S2S3S4S5 The safety rules are that No two trains may be in the same sector at the same time No train may enter a sector occupied by another train, even if that other train is about to move on Trains may only move to adjacent sectors, of course Constraints Siding

HEATH ROEHR 12 MEET-PASS SCENARIO Find the shortest plan that moves the train on S1 to S5 and returns the other two trains to their starting positions. Initial Goal

HEATH ROEHR 13 Step 0 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 14 Step 1 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 15 Step 2 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 16 Step 3 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 17 Step 4 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 18 Step 5 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 19 Step 6 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 20 Step 7 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 21 Step 8 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 22 Step 9 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 23 Step 10 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 24 Step 11 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 25 Step 12 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 26 Step 13 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 27 Step 14 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 28 Step 15 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 29 Step 16 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 30 Step 17 MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 31 Step 18: Solution Found MEET-PASS SCENARIO: A POSSIBLE SOLUTION

HEATH ROEHR 32 ZINC EDITOR : MEET-PASS IMPLEMENTATION Five sectors of railway track, S1,... S5, are linearly connected There is a siding accessible from S3 big enough to hold one train Initially, there are trains in sectors S1, S2 and S4 Move the train on S1 to S5 and return the other two trains to their starting positions.

HEATH ROEHR 33 ZINC EDITOR : MEET-PASS IMPLEMENTATION Safety rules Specific implementation is outside the scope of this talk Assume they are accurate and valid Execute the search

HEATH ROEHR 34 ZINC EDITOR : MEET-PASS IMPLEMENTATION Variable Declaration Constraints Variable Definition

HEATH ROEHR 35 ZINC EDITOR: SCREENSHOT Syntax highlighting Project-based code management Outline views

HEATH ROEHR 36 VISUALIZATION EDITOR Define arbitrary visualizations Vector-based graphics editor Script editor Scripting language Any language that supports java integration Python Lisp Default language is Lua Lightweight Portable Suited for animation: used in video games

HEATH ROEHR 37 VISUALIZATION EDITOR Vector-based graphics editor Graphics properties editor Project-based code management

HEATH ROEHR 38 VISUALIZATION EDITOR g12GetFromData(var) This method fetches the current contents of the decision variable var and makes its value available to the script. g12Draw(obj, props) This method sets a list of properties, props, for object obj, where props may contain items such as the object’s positions on the canvas, color, opacity, scaling factor, etc. Written in Java Written in Lua

HEATH ROEHR 39 The actual solver Control the starting & stopping of the solving process Collect detailed information about the solving process

HEATH ROEHR 40 XML-based messaging Separate Processes

HEATH ROEHR 41 Build & display a constraint graph Build & display a search tree Render visualization based on custom animation script Pre-defined visualizations

HEATH ROEHR 42 Constraint Graph Search Tree Sample Pre-Defined Visualizations Collapsed sub tree Domain split

 The G12 Platform  Zinc: Constraint Modeling Language  The G12 IDE  Modeling Layer: Meet-Pass Scenario  Solving Layer  Visualization Layer  Debugging with the G12 IDE  Conclusion & Questions HEATH ROEHR 43

HEATH ROEHR 44

HEATH ROEHR 45 HOW IS DEBUGGING DIFFERENT IN THE G12 IDE?

HEATH ROEHR 46 USER DEFINED BREAKPOINT VIEW User defined breakpoints “Search Events” (Events that induce the breakpoint) The breakpoint “subscribes” to these search events Enable/disable breakpoints

HEATH ROEHR 47

HEATH ROEHR 48 Accomplished by drawing objects binding their animation to events that fire during program execution Debugging is happening At the conceptual level Graphically: Domain-specific CUSTOM VISUALIZATION AND ANIMATION

HEATH ROEHR 49 “MEET-PASS” EXAMPLE Propagation should deduce the position of the train… Original formulation failed to deduce correctly, identifying an incorrect constraint model…

IDEs tailored to CSP solving ECLiPSE CLP Draw charts and graphs for solver output ILOG OPL Studio Offers a search-tree view similar to that of the G12 IDE Choco Java based visualizations from scratch Vector-based graphics processing programs Most are more advanced than G12’s graphics processor Using a custom visualization tool that is tightly integrated with debugging facilities is novel HEATH ROEHR 50 RELATED WORK

HEATH ROEHR 51

HEATH ROEHR 52 G12 IDE redefines the way users can interact with their solving CSPs Users Can not only view classic CSP visualizations (such as search tress) They can also customize animations straight from the IDE G12 IDE Allows users to Update their constraint definitions & solver logic on the fly Based on feedback from the event-driven debugger & real- time visualizations

HEATH ROEHR 53