All Manuals > KnowledgeWorks and Prolog User Guide > 7 Reference Guide

not Backward Chaining Goal

Summary

A goal that is satisfied when another goal fails.

Package

kw

Signature

not {condition}*

Arguments
condition
Any backward chaining goal.
Description

If the backward chaining goal not is used in a backward chaining clause, it succeeds if condition fails. In this usage, only one condition is allowed.

If not is used in a forward chaining pre-condition, it succeeds if any condition contained within it fail. In this usage, each condition may only contain expressions normally allowed in forward chaining pre-conditions (object base references and lisp tests). See 3.1.2 Forward Chaining Syntax for more details.

Examples
(not (truck ?truck driver ?driver) (test ?driver))
See also

test


KnowledgeWorks and Prolog User Guide (Macintosh version) - 01 Dec 2021 19:35:35