English to propositional logic translation I'm taking a discrete maths course and we're covering propositional logic. In class, we were tasked with converting the following English sentence into propositional logic:
You can take a picture of the painting only if your camera's flash is off or you are not close to the painting.
We split the sentence into propositions, namely:
p: You can take a picture of the painting.
q: Your camera's flash is off.
r: You are close to the painting.
Everyone agreed on the "or" and the "not". However, the class was pretty evenly split regarding the "only if" part of the statement. Some were saying that the correct translation is p ↔ (q ∨ ¬r) and some are saying that it should be p → (q ∨ ¬r).
Which one of these is correct?
Personally, I think it is the biconditional statement because the original sentence can be rewritten as the following two sentences while keeping the same meaning and also fulfill (p → q) ∧ (q → p) = p ↔ q:

*

*If you can take a picture of the painting, then your camera's flash is off or you are not close to the painting.

*If your camera's flash is off or you are not close to the painting, then you can take a picture of the painting.
I believe they both imply each other. If you can take a picture of the painting, then it is implied that you are not close to the painting or your camera's flash is off. If your camera's flash is off or you are not close to the painting, then it is implied that you can take a picture of the painting.
 A: *

*Think about it:

*

*$$\text{A is true only if B is true}\\\text{B being true is a necessary condition for A to be true}$$

*$$\text{if B is false, then A must also be false}\\\lnot B\implies\lnot A$$

*$$\text{there is no way for A to be true yet B false}\\\text{if A is true, then B must be true too}\\\text{B is true if A is true}\\A\implies B\\\text{A being true is a sufficient condition for B to be true}$$
I've divided the above into three groups, but all nine statements are in fact logically equivalent to one another.
Thus, the correct translation of “only if” as a logical connective is
$\to.$


*Echoing the first two comments: while in natural language “[blah blah] only when [bleh bleh]” is generally contextually understood to be bi-implicational, in formal logic, mathematics, and computer science, “only if” $(\to,\implies)$ and “if and only if” $(\leftrightarrow,\iff)$ are well-defined to have distinct meanings.
To be clear: “only if” $(\to,\implies)$ is not a stronger form of “if” $(\leftarrow,\impliedby).$
