1 / 19

Lecture Coursework 2

Lecture Coursework 2. Rectangle Game. Look at proof of matchsticks

guy
Download Presentation

Lecture Coursework 2

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Lecture Coursework 2

  2. Rectangle Game • Look at proof of matchsticks • Read thru the question. A rectangular board is divided into m columns by n rows.The area of the board is nxm.Each player takes turns to cut the board along a line.The smaller piece is discarded.The game ends with a 1 by 1 board,And the player whose turn it is to move is the loser.

  3. Sum Game • This is a sum game.The component games are copies of the same game.The position in a component game is given by m (a positive integer).A move in the game is to replace m by a number n such thatn < m <= 2n

  4. Symmetry • Clearly one winning strategy is the following.If the board is squareIe the number of rows = the number of columnsThen just copy the opponents moves.Similar to the daisy game.But what if we are not in a position to make the board square.In this case we need mex numbers.

  5. Mex Numbers • Draw a graph of the problemA successor is a state which we can move to from the current state.There maybe one or more successors from the current state.The final state has no moves, as it is the final state.This is given mex number 0A given state has mex number which is the smallest natural number notincluded in the mex numbers of the successor states.Show diagram in my book. • What are the patterns in the mex numbers?The strategy is to get symmetry with the mex numbers.This is how to play the sum game.

  6. Winning and losing positions • A winning position is a position from which there is a losing positionwe can move to.A losing position is a position from which ever position is to awinning position.A winner always wants to push a loser to a losing position, so theloser has no choice but to push to a winning position.Write down an inductive hypothesis about winning/losing positions.Show the tableTalk about similarities with matchstick game.

  7. Disjunction – Or • True when one of the pair is true (p or q)PropertiesIdempotence p or p = pSymmetry p or q = q or pAssociativity p or (q or r) = (p or q) or r Allows us to omit parenthesesDistributivity p or (q = r) = p or q = p or rExcluded middle  p or not p

  8. Golden rule 7.2 • p or q = p = q = p and q(this is a definition of and)And has equal precedence as or.Giving one precedence over the other obscures symmetries in theiralgebraic properties.The golden rule can be read in 3 different ways (at least)

  9. Truth table • p q |   p or q = p |    p and q = q0 0     10 1     01 0     11 1     1

  10. Modus Ponens and De Morgan • Modus Ponens p and (p=q) = p and qnot ( p and q) =  not p or not qnot ( p or q) = not p and not q

  11. Implication • Definition of if p <- q = p = p or q p <- q = q = p and qthese are the same, via the golden rule.

  12. Turning the arrows around • Definition of only-ifp -> q = q = p or qp -> q = p = p and qthese are the same, via the golden rule.

  13. Leibniz (equals for equals) • If two expressions are equal, and F is any function,Then F(x) = F(y)

  14. Return to Knights and Knaves • Knights tell the truth, and knaves lieTruth table of knights and knaves. P4A says I am same type as BIs there gold on the islandThis is exactly the same process as before.

  15. Formulating questions p3 my book • You are at a fork in the road, you want to know if the gold is to theleft or the right.Let Q be the question to be posed.The response to the question will be A = QLet L denote, "the gold can be found by following the left fork"The requirement is that L is the same are the response to Q.i.e. we require L=(A=Q){but as equality is associative}(L = A) = QSo the question Q posed is L=AI.e. "is the value of 'the gold can be found by following the left fork'equal to the value of 'you are a knight'"

  16. Equals for Equals p6 my book • There are three natives A B C.C says "A and B are both the same type".Formulate a question, that when posed to A determines if C is tellingthe truth.Let A be the statement A is a "knight".Let Q be the unknown question.The response we want is C (i.e. if C is true then C is a knight).By the previous section, Q = (A=C) i.e. we replace L by C.C's statement is A=B, so now we know C = (A=B) by equality.So Q = (A = (A=B)) which simplifies to Q = B, so the question to beposed is "is B a knight". Show the formal working from book p 69

  17. Portia's Casket • How do we write the portrait is in one and only one casket?The truth of the portrait being in the gold casket is indicated by thesilver inscription.The inscriptions on the silver casketa. the inscription on the gold casket is true, if this inscription is trueb. the inscription on the gold casket is false, if this inscription is truec. if the inscription on the gold casket is true, this inscription is falsed. if the inscription on the gold casket is false, this inscription is falsesee p 8

  18. variable names • igthe inscription on the gold casket is trueis the inscription on the silver casket is truepg the portrait is in the gold casketps the portrait is in the silver casket.Each of these will end up with a true/false value at the end.Only one of pg and ps can be true.

More Related