The dog has a ball in its mouth.
A dog is in a cage with a muzzle on.
If the dog has a ball in its mouth, it does not have a muzzle on.
exists e1 x1 x2 x3.(n_mouth(x3) & of(x3,x1) & n_thing(x1) & n_dog(x1) & Theme(e1,x2) & Actor(e1,x1) & v_have(e1) & in(x2,x3) & n_ball(x2))
exists p1 s1 x1.(a_on(s1) & Manner(p1,s1) & exists x2 x3.(in(x1,x2) & with(x2,x3) & n_muzzle(x3) & n_cage(x2)) & n_dog(x1))