33 views

Que. Consider domain is the set of all people in the world.

$F(x,y) =x \text{ is the friend of y}.$

Represent each of the following sentences using first-order logic statements
$1.$ Every person has $at most \ 2$ friends.
$2.$ Every person has $exactly \ 2$ friends.
$3.$ Every person has $at least \ 2$ friends.

My attempt –
$1. \forall x \exists y_1\exists y_2(F(x,y_1) \wedge F(x,y_2) \wedge \forall z(F(x,z) \implies ((z= y_1) \vee (z= y_2))))$
$2. \forall x \exists y_1\exists y_2(F(x,y_1) \wedge F(x,y_2) \wedge (y_1 \neq y_2) \wedge \forall z(F(x,z) \implies ((z= y_1) \vee (z= y_2))))$
$3. \forall x \exists y_1\exists y_2(F(x,y_1) \wedge F(x,y_2) \wedge (y_1 \neq y_2))$

asked ago | 33 views
+1
0
Every person has $atmost$ 2 friends. - means he can have either 0, 1 or 2 friends. According to me it should be

$\forall x \exists y_1\exists y_2(F(x,y_1) \wedge F(x,y_2) \wedge \forall z(F(x,z) \implies (((z \neq y_1) \wedge (z \neq y_2))\vee (z= y_1) \vee (z= y_2)))))$

Let me know if i am making any mistake in this.
0

@!KARAN, I don't think so it will work. Try when x has 3 friends.
There is a flaw in my formula too. It's not covering "0" case,

1
+1 vote