Logic Puzzles Miran Kim Ben Seelbinder Matthew Sgambati.

Slides:



Advertisements
Similar presentations
Techniques for Solving Logic Puzzles. Logic Puzzles Logic puzzles operate using deductive logic. Logic puzzles operate using deductive logic. A well-designed.
Advertisements

AE1APS Algorithmic Problem Solving John Drake. The island of Knights and Knaves is a fictional island to test peoples ability to reason logically. There.
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
CSE 20 DISCRETE MATH Prof. Shachar Lovett Clicker frequency: CA.
Solving Word Problems II
The psychology of knights and knaves Lance J. Rips, University of Chicago, 1989.
Two puzzles about omnipotence
The Island of Knights and Knaves. Knights always tell the truth.
Island of Knights and Knaves Jack says: “At least one of us is a knave.” Question: Is Jack a knight or knave? What about Jill? Answer: If Jack is a knave,
Some Puzzles About Truth (and belief, knowledge, opinion, and lying)
The Island of Knights and Knaves. Raymond Smullyan 1978 A little learning is a dangerous thing; Drink deep, or taste not the Pierian spring: There shallow.
Malcolm’s ontological argument Michael Lacewing
Truth Trees Intermediate Logic.
Homework quiz Simplify Completely: Test Friday 3/2 Simplifying expressions –Exponent properties (4.1, 4.2) Know how to apply the specific properties.
True/False. False True Subject May Go Here True / False ? Type correct answer here. Type incorrect answer here.
Logical and Rule-Based Reasoning Part I. Logical Models and Reasoning Big Question: Do people think logically?
SOLVING SYSTEMS USING SUBSTITUTION
1 Topic Mathematical Proofs. 2 Topic Mathematical Proofs California Standards: 24.2 Students identify the hypothesis and conclusion in logical.
Logical Puzzles Truth and Lies. The Island of Rilas On the island of Rilas there are just two types of people: knights and knaves Knights always tell.
Find opposites of numbers EXAMPLE 4 a. If a = – 2.5, then – a = – ( – 2.5 ) = 2.5. b. If a =, then – a = –
Part 2 Module 3 Arguments and deductive reasoning Logic is a formal study of the process of reasoning, or using common sense. Deductive reasoning involves.
The Foundations: Logic and Proofs
What is Critical Thinking?
PSAT Club Math – Multiple Choice.
CSCI 2110 Discrete Mathematics Tutorial 10 Chin 1.
Conditional Statements
Key Stone Problem… Key Stone Problem… next Set 22 © 2007 Herbert I. Gross.
Lecture 5 Knights and Knaves.. Administration Show hand in form. Show plagiarism form. Any problems with coursework? Google knight and knaves and look.
CS 173, Lecture B September 1, 2015 Tandy Warnow.
Dr. Naveed Riaz Design and Analysis of Algorithms 1 1 Formal Methods in Software Engineering Lecture # 24.
1 Sections 1.5 & 3.1 Methods of Proof / Proof Strategy.
Hilbert’s Progamme Early in C20, the mathematician Hilbert led a programme to formalise maths; to reduce it to a clear set of axioms and show that all.
PROCESS OF ELIMINATION INDUCTIVE REASONING. DISCLAIMER Logic is a very complex field of study. Our goal in this unit is just to starting thinking about.
Properties and Numbers 1.4. Deductive Reasoning Using facts, properties or rules to reach a valid conclusion Conjecture: statement that could be true.
Algebra Problems… Solutions Algebra Problems… Solutions © 2007 Herbert I. Gross Set 10 By Herbert I. Gross and Richard A. Medeiros next.
MATH 224 – Discrete Mathematics
Propositional Calculus CS 270: Mathematical Foundations of Computer Science Jeremy Johnson.
ConcepTest • Section 2.3 • Question 1
LOGICAL REASONING FOR CAT 2009.
Today’s Topics Introduction to Proofs Rules of Inference Rules of Equivalence.
Solving Linear Equations. Example 1 It’s obvious what the answer is. However, we need to start with the basics and work our way up because we need to.
Deductive Reasoning 1-2C What is deductive reasoning? What is the difference between deductive reasoning and inductive reasoning?
Dr. Naveed Riaz Design and Analysis of Algorithms 1 1 Formal Methods in Software Engineering Lecture # 25.
1.4 Properties of Real Numbers ( )
Megan FrantzOkemos High School Math Instructor.  Use inductive reasoning to identify patterns and make conjectures.  Determine if a conjecture is true.
Logic Development Problems. Puzzle #1 Smita has a full 8-quart container (Container A) of peanut oil. She wants to share half of the oil with her sister.
Section 1.1. Propositions A proposition is a declarative sentence that is either true or false. Examples of propositions: a) The Moon is made of green.
Which list of numbers is ordered from least to greatest? 10 –3, , 1, 10, , 1, 10, 10 2, 10 – , 10 –3, 1, 10, , 10 –3,
+ Properties of Real Numbers. + Properties Relationships that are always true fro real numbers are called properties. Properties are rules used to rewrite.
CS 270 Lecture 1 In Class Problems. Q1: Logic Puzzle You arrive at the end of a long hallway. There are two knights guarding two doors. One knight always.
1 Section 7.1 First-Order Predicate Calculus Predicate calculus studies the internal structure of sentences where subjects are applied to predicates existentially.
Chapter 2 Reasoning and Proof 2.1 Conditional Statements.
WARM UP Solve: 1. 3x – 5 = (3x -5) = x – 3 + 4x = (2x – 4) = 6.
Identities, Contradictions and Conditional Equations.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
Liar liar.
Factors, multiple, primes: Factors from prime factors
Check It Out! Example 1 Write an indirect proof that a triangle cannot have two right angles. Step 1 Identify the conjecture to be proven. Given: A triangle’s.
Applications of Propositional Logic
Indirect Proofs.
CS 220: Discrete Structures and their Applications
Equations and Inequalities
Propositional Logic.
SECTION 2-4 : SOLVING EQUATIONS WITH THE VARIABLE ON BOTH SIDES
Knights and Knaves.
Let Q be the question Let A be “the native is a knight”
Discrete Structures Prepositional Logic 2
Logical and Rule-Based Reasoning Part I
6.6 Solve Radical Equations
Factors, multiple, primes: Multiples
Presentation transcript:

Logic Puzzles Miran Kim Ben Seelbinder Matthew Sgambati

What are logic puzzles? “A puzzle deriving from the mathematics field of deduction” Produced by Charles Lutwidge Dodgson A puzzle that can be solved using logical reasoning It helps work with rules of logic (and, or, xor, etc.) Programs that carry out logical reasoning use these puzzles to illustrate capabilities

The Master of Logic Puzzles High School dropout who got a Ph.D. in logic at Princeton Wrote many books on logic puzzles such as Alice in Puzzle-Land and To Mock a Mockingbird Most famous for his “Knights and Knaves Problem” Raymond Smullyan

Knights and Knaves Encounter two people Knights always tell the truth Knaves always lie Figure out whether each person is a knight or a knave from their statements Example: A says, “At least one of us is a knave” and B says nothing I don’t lie! Neither do I!

Knight and Knave Problem A says “At least one of us is a knave” and B says nothing. P(x): x is a knight ¬P(x): x is a knave Suppose A is a knave. ¬P(A) ⇔ T What A says must be false ¬P(A) ∨ ¬P(B) ⇔ F Check: ¬P(A) ∨ ¬P(B) ⇔ T ∨ ¬P(B) ⇔ T A is a knight and what A says must be true. P(A) ¬P(A) ∨ ¬P(B) ∴ ¬P(B) Impossible Answer: A is a knight. B is a knave.

Knight and Knave Problem A says “The two of us are both knight” and B says “A is a knave.” P(x): x is a knight ¬P(x): x is a knave Suppose A is a knight. P(A) ⇔ T What A says must be true P(A) ∧ P(B) ⇔ T P(B) ⇔ T However, B says ¬P(A) ⇔ T P(A) ⇔ F A is a knave and what A says is false. ¬P(A) ⇔ T P(A) ∧ P(B) ⇔ F ∧ P(B) ⇔ F B is a knight because his statement (A is a knave) is true. Impossible Answer: A is a knave. B is a knight.

Knight and Knave Problem A says, “I am a knave or B is a knight” and B says nothing. – A is a knight – B is a knight Both A and B say, “I am a knight.” – Cannot determine the answer A says, “We are both knaves” and B says nothing. – A is a knave – B is a knight A says, “B is a knight” and B says, “The two of us are opposite types.” – A is a knave – B is a knave

Knight, Knave and Spy Problem from Alice in Puzzle-Land Added rule: Spy can lie or tell the truth. There is one spy, one knight, and one knave. A says that C is a knave. B says that A is a knight. C says “I am the spy.” Which one is the spy, which one is the knight, which one is the knave? Knight(x): x is a knight Knave(x): x is a knave Spy(x): x is a spy From C’s statement, C can’t be a knight because a knight never lie about his identity. Therefore, C is either a knave or a spy.

Knight, Knave and Spy Problem cont. from Alice in Puzzle-Land Suppose C is a spy. ¬Knight(C) ∧ ¬Knave(C) ∧ Spy(C) ⇔ T ¬Knave(C) ⇔ T(simplification) Knave(C) ⇔ F What A says is false, so A is knave. ¬Knight(A) ∧ Knave(A) ∧ ¬ Spy(A) ⇔ T ¬Knight(A) ⇔ T(simplification) B must be a knight, and what B says must be true. Check: Knight(A) ⇔ T ¬Knight(A) ⇔ F Impossible ∴ C isn’t a spy. There is one spy, one knight, and one knave. A says that C is a knave. B says that A is a knight. C says “I am the spy.” Answer: C is a knave. A is telling the truth, so A is a knight. B is a spy.

Multiple Choice Help You encounter a problem on an exam with only answer choices, the question has been omitted. Here are the answers: A.Answer A B.Answer A or Answer B C.Answer B or Answer C We may determine the correct answer using discrete math R(x): Answer x is right The correct answer must be the only one Suppose A correct ( R(A) = True ), we have the following answers: R(A) ⇔ T ⇔ True R(A) ∨ ¬R(B) ⇔ T ∨ F ⇔ True ¬R(B) ∨ ¬R(C) ⇔ F ∨ F ⇔ False Knowing this may only have one correct answer, we can determine that this answer is not right. False

Multiple Choice Help Suppose R(B) = True ¬R(A) ⇔ F ⇔ False ¬R(A) ∨ R(B) ⇔ F ∨ T ⇔ True R(B) ∨ ¬R(C) ⇔ T ∨ F ⇔ True Suppose R(C) = True ¬R(A) ⇔ F ⇔ False ¬R(A) ∨ ¬R(B) ⇔ F ∨ F ⇔ False ¬R(B) ∨ R(C) ⇔ F ∨ T ⇔ True Comparing each solution, we know that the correct answer must be C. We didn’t have to look at the question! TrueFalse

False Statement Which statement is false (assuming only one is false)? A.Statement D is true B.Statement A is false C.Statement B is false D.Statement C is true When statement B is true, it results in statement A being false, which results in statement D being false also. This results in more than one false statement, so statement B is the false one.

Conclusion What are logic puzzles? Who started logic puzzles? The master of logic puzzles – Knights and Knaves Method of thinking for logic puzzles Questions?

Pop Quiz! 1.The next question with the same answer as this one is: (A) 2 (B) 3 (C) 4 (D) 5 2.The first question with answer C is: (A) 1 (B) 2 (C) 3 (D) 4 3.The last question with answer A is: (A) 5 (B) 6 (C) 7 (D) 8 4.The number of questions with answer D is: (A) 1 (B) 2 (C) 3 (D) 4 5.The answer occurring the most is (if tied, first alphabetically): (A) A (B) B (C) C (D) D 6.The first question with the same answer as the question following it is: (A) 2 (B) 3 (C) 4 (D) 5 7.The answer occurring the least is (if tied, last alphabetically): (A) A (B) B (C) C (D) D 8.The highest possible score on this test is: (A) 5 (B) 7 (C) 6 (D) 8