changed XSB negation from tnot() to not_exists()