I'm currently working on the following task

Use the predicate Like(x, y) which is read as “x likes y”. 
Use the predicate Subject(x) as well, which is read as “x is a school subject”. 
Equal = and not equal ≠ are also to be used. 
Use x and y as variable names. 
Express the following sentences a) – f)  in predicate logic:

, and here are my answers.

(a) Stina likes all subjects. 
  ∀x (Subject(x)  -> Like(Stina, x) )

(b) There is a subject that Gustav likes.  
  ∃x (Subject(x) -> Like(Gustav, x)) 

(c) Hubert likes something that Svante and Gustav like. 
  ∀x (Subject(x) ∧ Like(Svante, x) ∧ Like(Gustav, x) -> Like(Hubert, x))

(d) Rut doesn’t like herself but she likes everyone who likes her.
  ∀x (¬Like(Rut, Rut) ∧ Like(x, Rut) -> Like(Rut, x))

(e) Gustav likes someone who likes math.
  ∀x∃y (Subject(y) ∧ y = math ∧ Like(x, y) -> Like(Gustav, x))

(f) Hubert likes all subjects except for math and logic, and Gustav likes math, Rut likes logic and Svante likes Rut and statistics.
  ∀x (Subject(x) ∧ x ≠ math ∧ x ≠ logic -> Like(Hubert, x))
  ∀x (Subject(x) ∧ x = math -> Like(Gustav, x))
  ∀x (Subject(x) ∧ x = math -> Like(Rut, x))
  ∀x ((Subject(x) ∧ x = statistic) V (x = Rut) -> Like(Svante, x))

In my answer for (f), I ended up writing multiple lines in predicate logic, but is this legitimate? If it's not, how do I sum them up into a single line? Also, is there anything wrong with how I solve the problems in (a)-(e) as well?


(a): correct

(b): correct

(c): Hubert only likes something that Svante and Gustav like, not everything, and it's not said that this something is a subject (in (d), it's about persons), so

∃x (Like(Svante, x) ∧ Like(Gustav, x) ∧ Like(Hubert,x))

(One could think about a rather hardly accessible reading where "something" is indeed to be read as "everything", as in "If Gustav and Svante like a subject, then so does Hubert", which has the form of a donkey sentence and would lead to an interpretation of a as every, but I think such a reading is hardly available or at least not intended here.)

(d): You only need the ∀x after ¬Like(Rut, Rut):

  ¬Like(Rut, Rut) ∧ ∀x(Like(x, Rut) -> Like(Rut, x))

But it doesn't hurt to move the quantifier to the front, the formulas are logically equivalent.

(e): As in (c), your ∀ should be a ∃:

  ∃x∃y (Subject(y) ∧ y = math ∧ Like(x, y) ∧  Like(Gustav, x))

(f): Ruth likes logic, not math (probably just a typo). As in the English sentence, simply use "and" to make your four senteces into one:

∀x (Subject(x) ∧ x ≠ math ∧ x ≠ logic -> Like(Hubert, x))
∧ ∀x (Subject(x) ∧ x = math -> Like(Gustav, x))
∧ ∀x (Subject(x) ∧ x = logic -> Like(Rut, x))
∧ ∀x ((Subject(x) ∧ x = statistic) V (x = Rut) -> Like(Svante, x))

And just a minor thing about notation: It's better to keep writing conventions for non-logical symbols consistent, which includes capitalization, so if you use lowercase for constant names when takling about subjects (like math), then you should consider doing so as well for constant names when talking about people (like svante), or the other way round (writing all constant names uppercase).

  • $\begingroup$ Thank you for the corrections! I believe that now I understand better when to use ∃ symbol. Usage of non-logical symbols also noted. I'll keep it in mind. $\endgroup$ – Shinichi Takagi Apr 30 at 12:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.