# Mathematical Logic and Predicate Calculus

Is this translation correct?

A person is maintaining a nuisance if he has a dog that barks at everyone who visits its owner

Px: x is a person

Dy: y is a dog

Ny: y is a nuisance

Oz: another person

Hxy: x has y

Mxy: x maintains y

Byz: y barks z

Vzx: z visits x

$\exists x \exists y \forall z ((Px \land Dy \land Oz \land Hxy \land Vzx \land Byz)\rightarrow (Ny \land Mxy))$

I would recommend putting the quantifiers in the 'appropriate' spot before bringing them all out.

Now, one thing to notice is that this is about any man, mot just 'a man'. As with one of your problems before, they mean this universally, not existentially.

Finally, for long sentences like this, use the 'divide and conquer' strategy, i.e. do this step by step:

$\forall x ($'x is a person who has a dog that barks at every visitor of x' $\rightarrow$ 'x maintains a nuisance')

Now, 'x is a person who has a dog that barks at every visitor' becomes:

$Px \land$ 'there is a dog y that x has and that barks at every visitor of x', and the latter part is:

$\exists y (Dy \land Hxy \land$ 'y barks at every visitor of x'

And the last part of that is:

$\forall z ($ 'z is (another person that is) a visitor of x' $\rightarrow$ ' y barks at z') so that is:

$\forall z ((Oz \land Vzx) \rightarrow Byz)$

The 'x maintains a nuisance ' is $\exists w ( Nw \land Mxw)$

And now you plug it all in:

$\forall x ((Px \land \exists y (Dy \land Hxy \land \forall z ((Oz \land Vzx) \rightarrow Byz)) \rightarrow \exists w (Nw \land Mxw))$

And frankly, I wouldn't even try to get the quantifiers out (even though you can), because it just becomes less readable when you do, especially since those quantifiers can change when you pull them out.

• Fantastic explanation! Thank you for all your teachings! – Beginner Dec 6 '16 at 1:45
• In this case, would be wrong to use instead of $w$ a $y$ because the dog is the nuisance? Thank you so much! – Beginner Dec 8 '16 at 20:16
• @Beginner Well, I don't think the English sentence isn't explicit enough about that, so even though chances are that that is what the nuisance is, I wouldn't make that assumption. It's a good example of the difference between English and logic: In English, lots of things are sort of implicitly implied without being explicitly stated. In logic, you have to explicitly state everything, and if not, then it can't be assumed. Shortly put: English is ambiguous, but logic is not! – Bram28 Dec 8 '16 at 20:29
• Thanks for sharing your wisdom! I appreciate it a lot! – Beginner Dec 8 '16 at 20:38