Discrete maths Prove the argument is Valid or Invalid by inference

If my plumbing plans do not meet the construction code, then I cannot build my house.

If I hire a licensed contractor, then my plumbing plans will not meet the construction code.

I hire a licensed contractor. Therefore I can build my house.

Prove by rule of inference is the argument valid or invalid :

below is my attempt

Premise 1: $$\neg P \rightarrow \neg Q$$
Premise 2: $$R \rightarrow \neg P$$
Premise 3: $$R$$
Conclusion: $$Q$$

and to further prove the validity i used this method :

Premise 4 : $$P \rightarrow Q$$ (Inverse of premise 1)
Premise 5 : $$\neg P$$ (Modus ponens of premise 2 + 3)
Premise 6 : $$\ P$$ (negation of premise 5)
$$\ Q$$ (Modus ponens of premise 4 and premise 6)

• Premise 4 doesn't follow from Premise 1. Inverse are not logically equivalent. Hint: Instead, of inverse, take the contrapositive , q implies p. Use rules of inference to show that not Q is true. Conclude that the original argument is invalid. Alternatively, assume Q is true, then not Q is false. Can you derive a contradiction? Commented Feb 17, 2023 at 0:12
• Thank you do much , i just realised they were not logically equivalent !!! Commented Feb 17, 2023 at 0:54

Welcome! it's a good attempt, you almost have it.

Consider,

Premise 1: $$\neg P \rightarrow \neg Q$$
Premise 2: $$R \rightarrow \neg P$$
Premise 3: $$R$$

By premise (2) and (3) + Modus Ponens we have: $$\neg P$$

So,

premise 4: $$\neg P$$

by premise (1) and (4) + Modus Ponens

Conclusion: $$\neg Q$$

What can you say, about the truth of Q, given the above argument?

• thank you so much for the guidance! I have figured out by myself the final solution to the problem Commented Feb 18, 2023 at 2:20