How to write the statement for the following?
If it does not rain, then if we go swimming then we have to take the bus.
I have been confused with the above "then" repetition...
How to write the statement for the following?
If it does not rain, then if we go swimming then we have to take the bus.
I have been confused with the above "then" repetition...
Let
Does not rain $\equiv A$
Go swimming $\equiv B$
Take the bus $\equiv C$
the n your statement becomes $A → [B → C]$. For better understanding, you can say: Assume that it doesn't rain, then if we go swimming then we take the bus.
Let $p =$ “It is raining.”, $q =$ “We will swim.” and $r =$ “We are taking the bus.”. The proposition that we have is
If it does not rain, then if we go swimming then we have to take the bus.
As pointed at the answer given by Jotabeta, we have that this proposition has the form
\begin{align*} \neg p \implies (q \implies r) \end{align*}
You have an hypothesis that is $p$ (If it does not rain), but then at the conclusion you other implication, i.e., the conclusion itself is another implication, namely $q \implies r$. Then, you just put all together.
Also, you can check by yourself, it would be the same if we have written $(\neg p \wedge q) \implies r$. You can use a truth table to immediately conclude that
\begin{align*} (\neg p \Rightarrow (q \Rightarrow r)) \iff ((\neg p \wedge q) \Rightarrow r) \end{align*}