Logic exercise.

Casual

New member
Joined
Nov 2, 2012
Messages
9
The Subject is Discrete Mathematics as part of a Computer Science major. The exercise is as follows:

Erica, Stanley and Robert were all witnesses in a car crash. Their statements are contradictory to one another, and all of them claimed that someone else lied. Erica claimed that Stanley lied, Stanley claimed that Robert lied, while Robert claimed that both of them lied. After thinking for a little bit, without any further questions the judged figured out who was telling the truth. Who was telling the truth?
I need to provide a step by step proof based on logic equivalences and deductions made based on the rules of logic.

Here's my take on the exercise:

p:Erica is telling the truth.
q:Stanley is telling the truth.
s:Robert is telling the truth.

Based on this representation we have:

p ->
¬q ( if Erica is telling the truth, then Stanley is not telling the truth )
q -> ¬s ( if Stanley is telling the truth, then Robert is not telling the truth )
s -> ¬p ^ ¬q ( if Robert is telling the truth, then both Erica and Stanley are not telling the truth)

Now we will examine the possibilities. If Erica is telling the truth we have:
1. p
2. p -> ¬q
3. ¬(¬s) - Since Stanley is lying, the opposite of what Stanley said is correct
4. s -> ¬p ^ ¬q
These 4 are conditions.
5. s - double negation on 3.
6. ¬p ^ ¬q - Modus Ponens of 4 and 5
7. ¬p - simplification of 6
8. ¬p ^ p - addition of 1 and 7.
Because of this contradiction it is clear that Erica is not telling the truth.

Similarly we will examine if Stanley is telling the truth.
1.q
2.p -> ¬q
3.q -> ¬s
4. ¬(¬p ^ ¬q) - Since Robert is lying, the opposite of what Robert said is true.
These 3 are conditions.
5. ¬p Modus Ponens of 1 and 2
6. ¬s Modus Ponens of 1 and 3
No contradiction, meaning Stanley was in fact telling the truth.

Lastly, let's examine the case if Robert was telling the truth.
1.s
2.
¬(p->¬q) - since Erica is lying, the opposite is true
3.
¬(q->¬s) - since Stanley is lying, the opposite is true
4.
s -> ¬p ^ ¬q
These 4 are conditions.
5.
¬p ^ ¬q - Modus Ponens of 1 and 4.
6.
¬(¬p v ¬q) substitution of the implication in 2
7. p ^ q De Morgan's law on 6.
8. p simplification of 7
9.
¬p simplification of 5
10. p ^
¬p addition of 8 and 9
Because of the contradiction it is clear that Robert also couldn't have been telling the truth.


Can my logic be justified? And is it possible to divide the exercise like so? If not, can you please show me the path to righteousness?(that might've been a bit too cheesy xD ) Thanks!
 

Can my logic be justified? And is it possible to divide the exercise like so? If not, can you please show me the path to righteousness?(that might've been a bit too cheesy xD ) Thanks!
Before I can even consider what I ought to answer, I need to ask you how much and what kind of help is appropriate to provide for what is an assignment for extra credit. If you are unsure, you can always ask your teacher.
 
If you find it morally wrong that you're giving me help with homework that's worth extra credit, it's fine. I wouldn't be able to specify just how much is appropriate, I just know that I could use it. Honestly I don't feel like cheating. I did feel like it when I read your responses on my first thread though. I would ask someone else like my classmates are going to(heck some are even hoping I'd have it done and waiting on me to serve it to them after midterms are over), it's just that I don't have anyone to ask, so I resorted to internet help. My teacher wouldn't agree to check my homework, because she doesn't hold private office hours, so she would be turning the homework into schoolwork by checking if my solution is 'enough' in front of other fellow students. She did specify that the homework would be graded very rigorously, and that's why I'm not sure whether I could use this method or if it's good enough proof. So it's your call. I completely understand your point of view on the matter, and no hard feelings if you refuse to grant me further help.
 
Here is what I am willing to do. I shall tell you how I personally would attack problems of this kind generally.

First, I would write down on a piece of paper every single one of the symbolic transformation rules specified or approved by your book or notes.

Second, I would split a different piece of paper into two columns. On the left, I would write down my logic for solving the problem in English, step by step. On the right, I would translate each step into symbolic form.

Third, I would check that each of the steps in symbolic form is supported by one of your transformation rules or by one of the givens in the problem. If it is not, you will know that there is some kind of hole somewhere in your logic.

I do not say that this is the most efficient method to attack such problems, but it is a systematic method.

Furthermore, I do not feel that suggesting a quite general method to think about a class of problems is letting you avoid doing the work assigned on specific problems. You will still need to find a logical solution to each problem and put it into symbolic form on your own.
 
Thanks JeffM. I gave it a go without splitting into 3 different cases, but by using the opposite implications as well. It worked like a charm and managed to get it done. So that's two down and two more to go. :)
 
Thanks JeffM. I gave it a go without splitting into 3 different cases, but by using the opposite implications as well. It worked like a charm and managed to get it done. So that's two down and two more to go. :)
Good
 
Top