Logical expression that "Someone takes a class and talks to others in the class."

119 Views Asked by At

I would like to represent the statement

"There is a student registered to AI class who talks to other students that are registered to AI class."

to first order logic. I have come up with this but I am not sure if it is the correct solution:

$\exists x,y: \text{Student}(x) \wedge \text{Student}(y) \wedge \text{TakesAI}(x) \wedge \text{TakesAI}(y) \wedge \text{Talk}(x,y)$

I think it means there are two students that take AI and they talk. Should I change my answer to this:

$\exists x,y: \text{Student}(x) \wedge \text{Student}(y) \wedge \text{TakesAI}(x) \wedge \text{TakesAI}(y) \Rightarrow \text{Talk}(x,y)$

I changed the last "and" operator to make it sound like: "If there are two students that take AI, they are talking."

Which do you think is better? What seems like to be the difference? How would you represent the statement in FOL?

Thank you for your answers.

2

There are 2 best solutions below

0
On BEST ANSWER

The first one is correct.

The second one says that there are two people such that if they are both students and take AI, then they talk. This is automatically satisfied by any two people (well, depending on what you're quantifying over, perhaps they don't even need to be people) who are not both students who take AI, whether or not they talk, so it says practically nothing.

4
On

Your change from:

$\exists x,y: \text{Student}(x) \wedge \text{Student}(y) \wedge \text{TakesAI}(x) \wedge \text{TakesAI}(y) \wedge \text{Talk}(x,y)$

to

$\exists x,y: \text{Student}(x) \wedge \text{Student}(y) \wedge \text{TakesAI}(x) \wedge \text{TakesAI}(y) \Rightarrow \text{Talk}(x,y)$

does not give you the right answer, but I think you were right to be concerned about the first answer, and in fact with the second one you were going in the right direction of what I think is the correct answer.

To explain this, go back to the original English statement:

"There is a student registered to AI class who talks to other students that are registered to AI class."

English (and all natural language) is notoriously ambiguous, but I think this is better interpreted as:

"There is a student registered to AI class who talks to all other students that are registered to AI class."

than as:

"There is a student registered to AI class who talks to some other student that are registered to AI class."

for the simple reason that the original statements uses 'students' and 'are', rather than 'student' and 'is'.

Your first logic expression

$\exists x,y: \text{Student}(x) \wedge \text{Student}(y) \wedge \text{TakesAI}(x) \wedge \text{TakesAI}(y) \wedge \text{Talk}(x,y)$

of course captures the

"There is a student registered to AI class who talks to some other student that are registered to AI class."

but in order to capture

"There is a student registered to AI class who talks to all other students that are registered to AI class."

you will need to use a universal. Indeed, it is here that I think you were on the right track to try and paraphrase this as:

"If there are two students that take AI, they are talking."

although that is actually not quite right either, for now you are effectively saying that any pair of students that are both taking AI will be talking, i.e. that would translate as:

$\forall x,y: \text{Student}(x) \wedge \text{Student}(y) \wedge \text{TakesAI}(x) \wedge \text{TakesAI}(y) \to \text{Talk}(x,y)$

and that is too strong of a statement: all you know is that is some student taking AI who is talking to all other students taking AI, and so you need to do something in between:

"There is some student in AI class such that for any other student: If that other students is taking AI, then they are talking."

And that translates to:

$\exists x (\text{Student}(x) \wedge \text{TakesAI}(x) \wedge \forall y ((\text{Student}(y) \wedge \text{TakesAI}(y)) \to \text{Talk}(x,y)))$