Let a, b and c be propostional wffs. Find two different wffs where the statement "if a then b else c" reflects the meaning of each wffs.
I found what this statement is represented as but i got stuck from there. Please help!!!
Let a, b and c be propostional wffs. Find two different wffs where the statement "if a then b else c" reflects the meaning of each wffs.
I found what this statement is represented as but i got stuck from there. Please help!!!
The problem (I have) here is to precisely interpret the statement "if A then B else C". If as a programmer I would interpret it as if $A$ is true then the truth value of the statement is that of $B$ otherwise (if $A$ is false) it's the truth value is that of $C$.
One could for example express this (in disjunctive normal form) as:
$$(A\land B) \lor (\neg A\land C)$$
Then one could of course rewrite it (in conjunctive normal form) as:
$$(A\lor C) \land (\neg A\lor B)$$
If you're a mathematician you might tend to interpret the statement as something extending the notion of implication. Beginning with if $A$ then $B$ would mean that $A$ implies $B$, and extending that into that also $\neg A$ implies $C$. In that case it would be expressed as:
$$(A\Rightarrow B)\land(\neg A\Rightarrow C)$$
which is the same as the above since in disjunctive normal normal form it would be:
$$(A\land B)\lor(\neg A\land C)$$
Combine these two statements using "and", and we have: $$(a\Rightarrow b)\wedge (\neg a \Rightarrow c)$$
This statement can be represented equivalently as: $$(\neg a \vee b)\wedge (a \vee c)$$
Edit
According to the comment by @amWhy:
"if $a$ then $b$ else $c$" is true iff $a$ and $b$ are true or $a$ is false and $c$ is true. It leads to another equivalent statement: $$(a\wedge b)\vee(\neg a \wedge c)$$ So let's denote: $$P(a,b,c)=(a\Rightarrow b)\wedge (\neg a \Rightarrow c)\\ Q(a,b,c)=(\neg a \vee b)\wedge (a \vee c)\\ R(a,b,c)=(a\wedge b)\vee(\neg a \wedge c)\\ S(a,b,c)=(a\Rightarrow b)\vee(\neg a \Rightarrow c)$$ We wan't to find statements that are equivalent to $R(a,b,c)$. Let's biuld a table: $$\begin{array}.a&b&c&|&P(a,b,c)&|&Q(a,b,c)&|&R(a,b,c)&|&S(a,b,c)\\ \hline 0&0&0&|&0&|&0&|&0&|&\color{red}1\\ 0&0&1&|&1&|&1&|&1&|&1\\ 0&1&0&|&0&|&0&|&0&|&\color{red}1\\ 0&1&1&|&1&|&1&|&1&|&1\\ 1&0&0&|&0&|&0&|&0&|&\color{red}1\\ 1&0&1&|&0&|&0&|&0&|&\color{red}1\\ 1&1&0&|&1&|&1&|&1&|&1\\ 1&1&1&|&1&|&1&|&1&|&1\end{array}$$ As we can see, the statemets $P(a,b,c), Q(a,b,c)$ and $R(a,b,c)$ are equivalent, while statement $S(a,b,c)$ is different from these three in four cases
I think one equivalent statement would be $(a\land b)\vee(\neg a\land c)$. If you redistribute that I think you get $(a\lor\neg a)\land(b\lor c)\iff b\lor c$. The first shows your two scenarios, while the second highlights that one of $b$ or $c$ will occur regardless or $a$.