1.2.3 Proof by Cases

preview_player
Показать описание
MIT 6.042J Mathematics for Computer Science, Spring 2015
Instructor: Albert R. Meyer

License: Creative Commons BY-NC-SA
Рекомендации по теме
Комментарии
Автор

This is very helpful. Thank you for making this content free!

carlosfonseca
Автор

Case 1: If y>100 works. Case 2: If y<=100, only works if x>0. So another simplification would be, if x>0. It can also ne done with boolean algebra or logic.

NicolasABZ
Автор

case1: if the answer on his table, and he will show us in classs. But he cant show it in class, becasuse answer needs to be on table, so True and Flase.
case2: if the answer not on his table, and he will show us in class. Flase and True.
Two cases are flase, so his word is a flase propositional formular.

vilkassharp
Автор

I know jokes are not fun if you explain it. But it is so subtle to understand. So,
Joke explanation on NP=P:
He claims "The answer to this question is on my lecture table and I will show it to you in class tomorrow" and he gives an hint: Proof by Cases.
So, formally
P: The answer to this question is on my lecture table.
Q: I will show it to you in class tomorrow.
P and Q.
The next lecture is "Well Ordering Principle 1", so he won't show you the answer.
Q=false
P and false
false

But, we don't know whether P is true or false. We can guess that P is false since he has published anything.

CarlosSanchezExplica
Автор

Yes the boolean expression can be simplified, but from a "self documenting" code point of view, the extra redundancy is useful, since one has to do some mental logic manipulation of the simplified expression to see what is happening. The redundancy makes the intention clearer. Of course one can comment out the redundant "x<=0 &&".

lewistsao
Автор

"On my lecture table"... What does it mean?

deuteriumtritium
Автор

Is the last part, a joke? lol

Proof by Cases -> The answer is on my desk!

sorry, if i'm being the spoiler ;)

happyboy
Автор

what happens if x = 0
you did not cover that case ((if x <=0) || y>100)

glennoltman