[Math] Express logic puzzles with proposition calculus notation

logicpropositional-calculuspuzzle

I’m trying to solve a logic puzzle that goes like this:

The police have three suspects for the murder of Mr. Cooper: Mr. Smith, Mr. Jones, and Mr. Williams. Smith, Jones, and Williams each declare that they did not kill Cooper. Smith also states that Cooper was a friend of Jones and that Williams disliked him. Jones also states that he did not know Cooper and that he was out of town the day Cooper was killed. Williams also states that he saw
both Smith and Jones with Cooper the day of the killing and that either Smith or Jones must have killed him. Can you determine who the murderer was if one of the three men is guilty, the two innocent men are telling the truth, but the statements of the guilty man may or may not be true?

When i was young, i used to solve such puzzles graphically, drawing vertices and arrows and excluding impossible cases. But now i want to do that formally. How can i express this puzzle definition using proposition calculus notation, inference and truth tables? Or, in other words, when you stumble upon a logical puzzle and you want to solve it formally, what is your algorithm?


What i tried. I extracted several propositions from the definition:

  1. S: didn't kill C
  2. S: J knew C
  3. S: W disliked C
  4. J: didn't kill C
  5. J: J didn't know C
  6. J: out of town
  7. W: didn't kill C
  8. W: S with C
  9. W: J with C

There are 3 groups of propositions, two of them are always true, the third may contain either true or false statements. Let be $A = 1 \land 2 \land 3$, $B = 4 \land 5 \land 6$, $C = 7 \land 8 \land 9$. Then from How to find the logical formula for a given truth table? by using truth tables and Karnaugh maps i deduct that the statement “some two of A, B, C are true” looks like $(A \land B \land \neg C) \lor (A \land \neg B \land C) \lor (\neg A \land B \land C)$. But wait, “may or may not be true” means that all statements might be true, not that at least one is false (hence the NAND is not appropriate here). So the sentence should be reformulated as “at least some two of A, B, C are true”. Am i going in the right direction?

Best Answer

You can ignore statements 1,4, and 7 as they contain no information. Then since 2 and 5 are contradictory, one is false, so W is innocent and speaks the truth. Presumably, 9 contradicts 6 (though maybe C was also out of town), so J is the killer. How you formulate your propositional logic is key-does it represent that 2 and 5 contradict and that 6 and 9 contradict? This is often hard going from English to propositional calculus.