Binary Reasoning
1. Reasoning system
Generally speaking, reasoning (or inference) is the process of deriving new knowledge from existing knowledge.
Models of reasoning can be normative (how reasoning should be done according to general principles, e.g., logical reasoning) or descriptive (how reasoning are done by humans, e.g., reasoning studied in psychology).
A logic normally consists of
- a representation language (usually specified by some grammar rules) to express knowledge as sentences,
- the semantic definitions of meaning and truth to make the sentences understandable to the user and to define the validity of inference,
- a set of (valid) inference rules that use the sentences as premises and conclusions.
A reasoning system implements a logic in a computer to answer questions according to given and derived knowledge, so is more capable than a database/knowledge-base. Its major components include
- A user interface to exchange sentences (knowledge, questions, and answers) with the user,
- A memory structure to store the knowledge, questions, and intermediate results,
- Routines for syntactic analysis of the input sentences,
- Routines for the inference rules,
- Routines for premise and rule selection in an inference process.
In problem solving, the overall processes consist of basic steps composed by a control mechanism, as summarized in the slogan "Algorithm = Logic + Control", where the two aspects are relatively independent. This approach is different from the traditional algorithms where the justification is given to the whole process, rather than to the individual steps.
A reasoning process can be naturally analyzed as state-space search.
2. Theorem proving
Theorem proving (or automated reasoning):
deriving theorems from axioms, with the following typical design:
Example: Logic Theorist
Applied outside axiomatic systems: use facts or reliable knowledge as axioms. Example: family relation.
3. Non-monotonic reasoning
There have been many attempts of revising classical logic to make it closer to everyday thinking, which lead to various non-classical logics.
One such attempt takes commonsense reasoning as carrying out defeasible reasoning when information is incomplete, and opening to new evidence and withdrawing conclusions. This type of logic is usually called
non-monotonic logic.
Related techniques include:
4. Simple inference in Prolog
We will use SWI-Prolog online to do some simple inference exercises in Prolog.
- Load the first built-in examples under "First steps / Knowledge base" in the left pane, then run the queries under "examples" in the right pane.
- Use the "likes" example in simple inference exercises to create a notebook in the left pane, then try the sample queries in the right pane.
Reading
- Poole and Mackworth: Chapters 5 & 15
- Russell and Norvig: Chapters 7 & 8 & 9
- Luger: Chapters 2, Sections 14.1-2