SUDOKO PROBLEM: Modeled as an ILP* Daryl L. Santos, Ph.D. Professor – Systems Science and Industrial Engineering Thomas J. Watson School of Engineering.

Slides:



Advertisements
Similar presentations
Design of Experiments Lecture I
Advertisements

Lecture 3 Linear Programming: Tutorial Simplex Method
The Management Science Approach
Solving Sudoku1 Website: Labelling scheme.
Modeling problems with Integer Linear Programming (ILP) Name: Chuan Huang.
Number puzzles in the paper Did you know there’s a whole range of number puzzles you can try in most newspapers? Click on the puzzles below to complete.
Operations Research Assignment Problem.
Introduction to Management Science. Definition The application of the scientific method to solving managerial decision problems  Usually involves a mathematical.
The Simplex Algorithm An Algorithm for solving Linear Programming Problems.
CPSC 322, Lecture 11Slide 1 Constraint Satisfaction Problems (CSPs) Introduction Computer Science cpsc322, Lecture 11 (Textbook Chpt 4.0 – 4.2) January,
Economics 214 Lecture 37 Constrained Optimization.
LINEAR PROGRAMMING. Introduction n Introduction: n objective n Constraints n Feasible Set n Solution.
Constraint Systems Laboratory March 26, 2007Reeson–Undergraduate Thesis1 Using Constraint Processing to Model, Solve, and Support Interactive Solving of.
5.6 Maximization and Minimization with Mixed Problem Constraints
Operations Research I Lecture 1-3 Chapter 1
SOLVING THE KAKURO PUZZLE Andreea Erciulescu Department of Mathematics, Colorado State University, Fort Collins (Mentor: A. Hulpke)
Solving Sudoku Mark PTTLS Micro teach. Solving Sudoku What is a Sudoku? A Sudoku is a number puzzle based on a 9x9 grid made up from smaller 3x3 blocks.
CS194 Project: Sudoku Difficulty Kha Chu Advisor: Professor Sahai.
SOLVING SUDOKU WITH MATLAB VERIFICATION FUNCTION correctness verification of the puzzle: checks if the current element appears twice in the same line,
Operations Research Models
Decision Making via Linear Programming: A simple introduction Fred Phillips
Operations Research Lecturer Eng. Ahmed H. Abo absa 2 nd Semester ITGD4207 University of Palestine.
1 CSC 221: Introduction to Programming Fall 2013 See online syllabus (also accessible via BlueLine2): Course goals:  To develop.
SOLVING SUDOKU WITH MATLAB Raluca Marinescu, Andrea Garcia, Ivan Castro, Eduard Enoiu Mälardalen University, Västerås,
Introduction of Engineering (ENGR 10) Guest Lecture March 24, 2014.
Constraint Satisfaction Problems (CSPs) CPSC 322 – CSP 1 Poole & Mackworth textbook: Sections § Lecturer: Alan Mackworth September 28, 2012.
2009/11/14GPW20091 Analysis of the Behavior of People Solving Sudoku Puzzles Reijer Grimbergen School of Computer Science, Tokyo University of Technology.
Model Driven DSS Chapter 9. What is a Model? A mathematical representation that relates variables For solving a decision problem Convert the decision.
Computing Science 1P Large Group Tutorial 20 Simon Gay Department of Computing Science University of Glasgow 2006/07.
Formal Methods & Verification: Project 1 Sudoku for Nonomino board Farn Wang.
Data Structures Using C++ 2E1 Recursion and Backtracking: DFS Depth first search (a way to traverse a tree or graph) Backtracking can be regarded as a.
Sudoku Solver Comparison A comparative analysis of algorithms for solving Sudoku.
Sudoku Jordi Cortadella Department of Computer Science.
Propositional Satisfiability A compound proposition is satisfiable if there is an assignment of truth values to its variables that make it true. When no.
Lecture 4 Looping. Building on the foundation Now that we know a little about  cout  cin  math operators  boolean operators  making decisions using.
Units Of Output TFCTVCTCMCAFCAVC Marginal Cost Puzzle 20.
This presentation shows how the tableau method is used to solve a simple linear programming problem in two variables: Maximising subject to three  constraints.
1 Chapter 1: Introduction to Mathematical Optimization 1.1 Introduction 1.2 Simple Examples 1.3 The OPTMODEL Procedure.
To create a program, written in C++, that could generate a Sudoku. Elements to take into consideration: The Sudoku created must have one unique solution.
Gomory Cuts Updated 25 March Example ILP Example taken from “Operations Research: An Introduction” by Hamdy A. Taha (8 th Edition)“Operations Research:
How Do I Solve This Thing?. You are familiar with Sudoku puzzles. For this variation, place the integers 1 – 9 into each row or column such that the.
Monster (“Mega”) Sudoku
Backtracking & Brute Force Optimization Intro2CS – weeks
Managerial Economics Linear Programming Aalto University School of Science Department of Industrial Engineering and Management January 12 – 28, 2016 Dr.
CompSci Problem Solving: Sudoku  Rules of the Game Sudoku is played with a 9 by 9 "board" consisting of nine 3 by 3 sub-boards. The symbols 1 -
Welcome! Cinda Heeren Lecturer Department of CS UIUC The Beauty of Computer Science.
SUDOKU SOLVER Will Bazil, Ryan Covert, Ricky Parker.
Introduction It had its early roots in World War II and is flourishing in business and industry with the aid of computer.
Elimination Method - Systems. Elimination Method  With the elimination method, you create like terms that add to zero.
The Beauty of Computer Science
deterministic operations research
Special Cases in simplex method applications
Managerial Economics Linear Programming
Monster (“Mega”) Sudoku
EGR 115 Introduction to Computing for Engineers
Linear Algebra Lecture 4.
Constraint Satisfaction Problem
Gomory Cuts Updated 25 March 2009.
Jordi Cortadella Department of Computer Science
Using WinQSB to solve Linear Programming Models
Engineering design is the process of devising a system, component, or process to meet desired needs. It is a decision-making process in which the basic.
Integer Programming with What’sBest
What I Believe Lyle D. Feisel Dean Emeritus
Sudoku.
9.3 Linear programming and 2 x 2 games : A geometric approach
Integer Programming with What’sBest
Solving Sudoku with Consistency: A Visual and Interactive Approach
Year 2 Summer Term Week 8 Lesson 5
CSC 221: Introduction to Programming Fall 2018
Management Information Systems
Presentation transcript:

SUDOKO PROBLEM: Modeled as an ILP* Daryl L. Santos, Ph.D. Professor – Systems Science and Industrial Engineering Thomas J. Watson School of Engineering and Applied Science Vice Provost for Diversity and Inclusiveness Binghamton University – State University of New York KAIST ISE Visiting Professor – Summer 2006 and 2007 GUEST LECTURE FOR KAIST ISE – APRIL 14, 2014 *From “Teaching Integer Programming via Sudoko and Other Math Puzzles”, D.L. Santos, proceedings of IERC Conference, Nashville, TN, 2007.

“Sudoku” Puzzle -Each 3x3 grid (“block”) contains 1-9 (no repeats) -Each row contains 1-9 (no repeats) -Each column contains 1-9 (no repeats) Block 1 Block 2 Block 3 Block 4 Block 5 Block 6 Block 7 Block 8 Block 9

“Sudoku” Puzzle (Example Solved) -Each 3x3 block contains 1-9 (no repeats) -Each row contains 1-9 (no repeats) -Each column contains 1-9 (no repeats)

3 Features of all LP/ILP Models 1.Definition of alternatives (decision variables) 2.Definition of constraints (equalities/inequalities) 3.Definition of the objective function (what we will optimize)

“Sudoku” Puzzle – a solution method using ILP 1.Decision Variables: should be obvious that we are trying to decide the values of the cells. 2.Constraints: these are give to the player/decision- maker. Each row, column, and block must contain integers (1-9) with no repeats in them. 3.Objective function: maybe the trickiest part (but simple). If all constraints are satisfied, the game is solved. WE CAN HAVE ANY OBJECTIVE FUNCTION WE WANT.

i j

Consider “Block 6” and lowest Row and Column numbers… Block 6 j =7 = low “j” for Block 6 i =4 = low “i” for Block 6

Example’s Constraint Set 5 x117 = 1 x152 = 1 x194 = 1 x212 = 1 x226 = 1 x289 = 1 x293 = 1 x349 = 1 x365 = 1 x428 = 1 x457 = 1 x486 = 1 x491 = 1 x536 = 1 x573 = 1 x613 = 1 x622 = 1 x659 = 1 x685 = 1 x741 = 1 x762 = 1 x811 = 1 x829 = 1 x887 = 1 x895 = 1 x918 = 1 x953 = 1 x996 = 1

Solution of Example Example was input into LINDO© and only non- zero values was asked for output

Solution of Example See PDF file….

To conclude… When I model puzzles like this and others, it helps me to learn and appreciate the power of OR techniques.