# FOL: Translation of sentences into logical proposition

Translate the following sentences into wfs.

John hates all people who do not hate themselves.

Let O:= hate themselve, h:=John hates.

Then $\forall x ( \lnot O(x) \to h(x) )$

Is this translation correct?

Also, for this sentence

Any sets that have the same members are equal,

what can I do?

For the first one you want to use a 2-place predicate $H(x,y)$ that stands for '$x$ hates $y$'
for the second one, use a 2-place predicate $x \in y$ that expresses that $x$ is an element of $y$
• For the second one, $H(x,y):=x$ is an element of $y$. $\forall x \forall y (H(x,y) \iff H(y,x))$ this would be correct answer? – América Nov 19 '17 at 0:49
• @Michelle No. If you translate that back into English you get that '$x$ is an element of $y$ if and only if $y$ is an element of $x$'. ... which makes little sense: $1$ is an element of the set if natural numbers, but the set of natural numbers is of course not an element of $1$. Instead, use the $x$ and $y$ for the two sets, but use a third variable $z$ to talk about the members of those sets. So try again. Also, do you have another attempt for the first one? – Bram28 Nov 19 '17 at 2:12
• ok, for the first one would be $\forall x (\lnot H(x,x)\to H(J,x))$, where J is for John so it shouldn't be quantified right? – América Nov 19 '17 at 2:28
• $\forall x\forall y( \forall z [(H(z,x) \leftrightarrow H(z,y))])\to (x=y) )$ now? – América Nov 19 '17 at 3:47