# How do I find the truth value in this logic problem: $(( p \lor s) \land \neg q) \rightarrow ( r \rightarrow s)$?

The problem is as follows:

$$[\left ( p \vee s\right) \wedge \sim q\,] \rightarrow \left ( r \rightarrow s \right )$$

From the preceding statement find the truth value of $\textrm{p, q, r, s}$

The alternatives in my book are the following:

1. TFTF
2. TTFT
3. TTTF
4. TFFT
5. TFFF

However I'm confused exactly how do I get to any of those answers.

I tried to build up a truth table to get the answer, since the number of combinations for the four different variables would mean $2^{4}=16$.

The sketch of the table what I build is shown below:

The process was tedious and I'm not sure if the result it is correct but the thing is I don't know if this is what it is being asked. Is there any way to reduce this table to any of the alternatives given?

I have forgotten exactly if there is a way to solve this problem without resorting with this approach or any shortcut?

Can somebody help me to find the right answer or to guide me what to do?.

• There are some tricks to get right assignments. If $[(p \lor s) \land \neg q] \rightarrow (r \rightarrow s)$ is true, then $[(p \lor s) \land \neg q]$ and $(r \rightarrow s)$ be both true, or $[(p \lor s) \land \neg q]$ is false. – ChoMedit Mar 15 '18 at 8:21
• If you split the problem like this, you could check it easier. – ChoMedit Mar 15 '18 at 8:21
• Upon rereading the problem, here's my interpretation of what is being asked from you. You're asked to assume that $(( p \lor s) \land \neg q) \rightarrow ( r \rightarrow s)$ is true. (This means that in your truth table, you're only interestest in the rows where the value of this statement is $T$). And from that, among the given options, you're asked to choose the possible assignment of truth values to the propositional letter that occur in the statement. – Git Gud Mar 15 '18 at 8:26
• Obviously, from the truth table (whose correctness I didn't check - there is software online to these tables for you, even WolframAlpha), there are many assignments that work, but hopefully among the options only one of them is valid.About how to solve this without truth tables, I'd follow the train of thought that ChoMedit started above. – Git Gud Mar 15 '18 at 8:28
• @ChoMedit From your suggestion it feels the same process as assuming both true and the second expression false would render to build up two tables of eight rows. I'm not sure if that is what you wanted to imply. – Chris Steinbeck Bell Mar 15 '18 at 9:11

I don't think the question makes sense. Here's the natural reading of the question, based on what you've said:

Given that $[(p \lor s) \land \lnot q] \to (r \to s)$ is true, which of the following five alternative assignments of truth-values to $p$, $q$, $r$ and $s$ is correct?

Now, you've not specified (or maybe the question doesn't specify) which column on the five assignments corresponds to which letter. But regardless of how we do that, there's always going to be at least two assignments which make the long sentence (which we'll abbreviate as $\phi$) true.

For, if $(r \to s)$ is true, then $\phi$ is true. So if only one of the assignments makes $\phi$ true, then the other four have to make $(r \to s)$ false. To do that, they have to assign T to $r$ and F to $s$. So the column for $s$ would need to contain (at least) four Fs. But there's no column with more than three Fs.

Or, in other words: regardless of which column we take to correspond to $s$, at least two assignments will make $s$ true (and hence $(r \to s)$ true, and hence $\phi$ true).

Please know that a conditional $A \rightarrow B$ is only false when $A$ is true and $B$ is false. In all other cases, it is true.

You have some errors in your truth-table:

In rows $10,12,14$, and $16$, the value of $r \rightarrow s$ should be $T$, not $F$. And in row $4$ it should be $F$, rather than your $T$

In rows $7,10,13,14$, and $16$, the value of the whole expression should be $T$, not $F$

As such, you should end up with only one row where the whole expression is False, namely row $8$, where $p$ and $r$ are $T$, but $q$ and $s$ are $F$

Assuming that the alternatives in the book list the values of $p$, $q$, $r$, and $s$ in that order (confusingly, you did not follow that order in your truth table .. I would recommend for next time to follow the alphabetic order), we thus see that alternative 1 that the book provides is the only alternative where the statement is False.

So, assuming that the book asked for the alternative where it is false, it would be alternative $1$. If it asks you to choose the ones that are true, it would be alternatives $2,3,4$, and $5$

It might be useful to simplify the given expression using some Boolean algebra before checking against the given truth values.

To make the expressions more readable I prefer a more "algebraic" writing style:

$$a \lor b = a + b,\, a \land b = ab \mbox{ and } \neg a = \bar a, \, T = 1, F = 0$$ So, you get, for example:

• $\overline{ab}= \bar a + \bar b$ (De Morgan)
• $(a+b)c = ac + bc$ (Distributivity of $\land$)
• $a + 1 = 1$, $a + 0 = a$, $a\bar a = 0$
• etc. ... just play around with it

Now using the equivalence $a \rightarrow b = \bar a + b$ your expression becomes:

$$[(p \lor s) \land \neg q] \rightarrow (r \rightarrow s) = \overline{(p+s)\bar{q}}+(\bar r + s) \stackrel{Morgan}{=} \overline{p+s}+q+\bar r + s \stackrel{Morgan}{=}\bar p \bar s + q + \bar r + s \stackrel{(\star)}{=}\bar p + q + \bar r + s$$ Now, you can check this expression against the given truth values which is far more convenient than setting up a big truth table.

$(\star):\; \bar p \bar s + s = \overline{\overline{\bar p \bar s + s}}= \overline{(p + s)\bar s} = \overline{(p\bar s + s\bar s)} = \overline{p\bar s} =\bar p + s$.

The problem is as follows:

$$[\left ( p \vee s\right) \wedge \sim q\,] \rightarrow \left ( r \rightarrow s \right )$$

From the preceding statement find the truth value of $\textrm{p, q, r, s}$

Your truth table is incorrect. Try this truth table generator: http://web.stanford.edu/class/cs103/tools/truth-table-tool/

Hint: From its truth table, your statement is true for all combinations of truth values for p, q, r, s except for p=T, q=F, r=T and s=F.