AE1APS Algorithmic Problem Solving John Drake.  Coursework 3 due on Thursday at 1pm  (i.e. before the start of the tutorial).  Submit either hard-copy.

Slides:



Advertisements
Similar presentations
Combinatorial Auction
Advertisements

Linear Programming. Businesses use linear programming to find out how to maximize profit or minimize costs. Most have constraints on what they can use.
Do Now The cost of renting a pool at an aquatic center id either $30 an hr. or $20 an hr. with a $40 non refundable deposit. Use algebra to find for how.
AE1APS Algorithmic Problem Solving John Drake. The island of Knights and Knaves is a fictional island to test peoples ability to reason logically. There.
Stat 35b: Introduction to Probability with Applications to Poker Outline for the day: 1.Midterms 2.Flushes 3.Hellmuth vs. Farha 4.Worst possible beat 5.Jackpot.
Great Theoretical Ideas in Computer Science
Make sure you know the day and time of the final exam for this section of Math 110: Day: ______ Date:______ Time: ______ to _______ All Math 110.
THE WELL ORDERING PROPERTY Definition: Let B be a set of integers. An integer m is called a least element of B if m is an element of B, and for every x.
Reaching Agreements II. 2 What utility does a deal give an agent? Given encounter  T 1,T 2  in task domain  T,{1,2},c  We define the utility of a.
AE1APS Algorithmic Problem Solving John Drake
AE1APS Algorithmic Problem Solving John Drake
Rizwan Rehman Centre for Computer Studies Dibrugarh University
Alpha-Beta Search. 2 Two-player games The object of a search is to find a path from the starting position to a goal position In a puzzle-type problem,
EC941 - Game Theory Prof. Francesco Squintani Lecture 4 1.
NON - zero sum games.
1 Discrete Structures & Algorithms Graphs and Trees: III EECE 320.
An Approximate Truthful Mechanism for Combinatorial Auctions An Internet Mathematics paper by Aaron Archer, Christos Papadimitriou, Kunal Talwar and Éva.
15 Backward induction: chess, strategies, and credible threats Zermelo Theorem: Two players in game of perfect information. Finite nodes. Three outcomes:
MIT and James Orlin © Dynamic Programming 1 –Recursion –Principle of Optimality.
AE1APS Algorithmic Problem Solving John Drake.  Invariants – Chapter 2  River Crossing – Chapter 3  Logic Puzzles – Chapter 5  Matchstick Games -
Two-Player Zero-Sum Games
1 Chapter 9 Dynamic Programming General Problem-Solving strategy Was born in the 1950s (Bellman) Based on successive decomposition Leads to functional.
TRANSPORTATION PROBLEM Finding Initial Basic Feasible Solution Shubhagata Roy.
One more definition: A binary tree, T, is balanced if T is empty, or if abs ( height (leftsubtree of T) - height ( right subtree of T) )
Chapter 5 Understanding Randomness
AE1APS Algorithmic Problem Solving John Drake..  Previously we introduced matchstick games, using one pile of matches  It is possible to have more than.
Network Optimization Models: Maximum Flow Problems
Great Theoretical Ideas in Computer Science.
Computability and Complexity 23-1 Computability and Complexity Andrei Bulatov Search and Optimization.
1 Discrete Structures & Algorithms Graphs and Trees: II EECE 320.
Network Optimization Models: Maximum Flow Problems In this handout: The problem statement Solving by linear programming Augmenting path algorithm.
NetworkModel-1 Network Optimization Models. NetworkModel-2 Network Terminology A network consists of a set of nodes and arcs. The arcs may have some flow.
PROBABILITY AND STATISTICS FOR ENGINEERING Hossein Sameti Department of Computer Engineering Sharif University of Technology Independence and Bernoulli.
Part II - Sums of Games Consider a game called Boxing Match which was defined in a programming contest m.short.html.
Final Lecture. Instructions in Exam ANSWER 2 QUESTIONS. There will be a choice of 3 questions. Each question will be in parts e.g. a, b, c. You can see.
Surreal Number Tianruo Chen. Introduction In mathematics system, the surreal number system is an arithmetic continuum containing the real number as infinite.
Lesson 1: Solving Inequalities Using Addition and Subtraction.
6 Sums of Games.. Lecture6 Admin Plagiarism forms Answer football cup final problem. //Daisy Problem hints e.g. try a smaller size. General problem solving.
Games. Adversaries Consider the process of reasoning when an adversary is trying to defeat our efforts In game playing situations one searches down the.
Backtracking and Games Eric Roberts CS 106B January 28, 2013.
Assignment 2 (from last week) This is a pen-and-paper exercise, done in the same groups as for Practical 1 Your answer can be typeset or hand-written There.
CS 4407, Algorithms University College Cork, Gregory M. Provan Network Optimization Models: Maximum Flow Problems In this handout: The problem statement.
Addition & Subtraction
Lecture Coursework 2 AGAIN. Rectangle Game Look at proof of matchsticks A rectangular board is divided into m columns by n rows. The area of the board.
Earliness and Tardiness Penalties Chapter 5 Elements of Sequencing and Scheduling by Kenneth R. Baker Byung-Hyun Ha R1.
Thursday, May 2 Dynamic Programming – Review – More examples Handouts: Lecture Notes.
SPANNING TREES Lecture 21 CS2110 – Fall Nate Foster is out of town. NO 3-4pm office hours today!
ARTIFICIAL INTELLIGENCE (CS 461D) Princess Nora University Faculty of Computer & Information Systems.
Solving Absolute Value Equations The absolute value of x is defined as Example 1.
Example 31: Solve the following game by equal gains method: Y I II I II I X II II
Lecture Coursework 2. Rectangle Game Look at proof of matchsticks Read thru the question. A rectangular board is divided into m columns by n rows. The.
::Network Optimization:: Minimum Spanning Trees and Clustering Taufik Djatna, Dr.Eng. 1.
Content Game of Nim Impartial Games Sprague-Grundy theorem
Unit 8 Solving Inequalities Essential Question: How can you use inequalities to solve real world problems?
Solving Absolute Value Equations
Great Theoretical Ideas in Computer Science
Chapter 4: Divide and Conquer
2.2 Limits Involving Infinity, p. 70
Artificial Intelligence
Alpha-Beta Search.
2.2 Limits Involving Infinity
NIM - a two person game n objects are in one pile
Artificial Intelligence
Alpha-Beta Search.
The Alpha-Beta Procedure
Alpha-Beta Search.
The Limit of a Function.
Alpha-Beta Search.
Alpha-Beta Search.
Unit II Game Playing.
Presentation transcript:

AE1APS Algorithmic Problem Solving John Drake

 Coursework 3 due on Thursday at 1pm  (i.e. before the start of the tutorial).  Submit either hard-copy (including name/student number), or soft-copy to me.  Normal university regulations apply to late submissions  Please let me know if you have any problems!  Office SEB325 

 The position in a given sum game is (l, r).  A move affects one component (i.e one game)  An assignment can either be l := l’ or r :=r’  (i.e. the left or right component is affected)  Define two functions L and R on the left and right positions such that; (l, r) is a losing position exactly when L(l) = R(r)

 L and R must have equal values on end positions  All moves from a losing position should result in a winning position satisfying L(l) != R(r)  Applying the winning strategy from a winning position, should result in a losing position

 We require that:  For end positions L(l) = R(r) = 0  For every l’ such that there is a move from l to l’ - L(l) != L(l’)  For any number m < R(r), it is possible to move from r to r’ such that R(r’) = m (similar for left).

 Fortunately for us such a function exists  The MEX function, short for “minimal excludant”, satisfies these conditions and is therefore used as the functions L and R

 Let p be a position in a game. The mex value of p (mex(p)), is defined as the smallest natural number, n, such that  There is no move in the game from p to position q satisfying mex(q) = n  For m < n, there is a move from p to q satisfying mex(q) = m.  This is a recursive definition.

 Informally, mex(p) is the minimum number that is excluded from the mex numbers of positions q to which a move can be made from p (i.e. q is a successor of p).

 The graphs do not have regular structure, so the mex numbers must be calculated by hand  End positions have a mex number of 0  A mex number can be give to a node when all its successors have been assigned a mex number  The number is the smallest number that is not included in the mex numbers of its successors

 Suppose we start with “ok” (o,k) as our position  This is a winning position because the mex numbers are different  The winning strategy is to move the right graph to node i which has the same mex number as “O” i.e. we are restoring the balance (R(r ) = L(l ))  The opponent will then disrupt the balance (making this an inequality)  The first player the repeats the strategy of making the mex numbers equal, moving in the game with the highest mex number, until the opponent can move no further

 Note that due to the lack of structure, the mex number of the 15 left and 11 right positions were calculated individually  In total we only did (=24) calculations, and not 15*11 (=165) calculations

b) a) b) (15)(20)