What are forward and backward reasoning explain their chaining rules?
Forward chaining (or forward reasoning) is one of the two main methods of reasoning when using an inference engine and can be described logically as repeated application of modus ponens. Forward chaining is a popular implementation strategy for expert systems, business and production rule systems. The opposite of forward chaining is backward chaining.
Forward chaining starts with the available data and uses inference rules to extract more data (from an end user, for example) until a goal is reached. An inference engine using forward chaining searches the inference rules until it finds one where the antecedent (If clause) is known to be true. When such a rule is found, the engine can conclude, or infer, the consequent (Then clause), resulting in the addition of new information to its data.
Inference engines will iterate through this process until a goal is reached.
Suppose that the goal is to conclude the color of a pet named Fritz, given that he croaks and eats flies, and that the rule base contains the following four rules:
Let us illustrate forward chaining by following the pattern of a computer as it evaluates the rules. Assume the following facts:
With forward reasoning, the inference engine can derive that Fritz is green in a series of steps:
1. Since the base facts indicate that "Fritz croaks" and "Fritz eats flies", the antecedent of rule #1 is satisfied by substituting Fritz for X, and the inference engine concludes:
Fritz is a frog
2. The antecedent of rule #3 is then satisfied by substituting Fritz for X, and the inference engine concludes:
Fritz is green
The name "forward chaining" comes from the fact that the inference engine starts with the data and reasons its way to the answer, as opposed to backward chaining, which works the other way around. In the derivation, the rules are used in the opposite order as compared to backward chaining. In this example, rules #2 and #4 were not used in determining that Fritz is green.
Because the data determines which rules are selected and used, this method is called data-driven, in contrast to goal-driven backward chaining inference. The forward chaining approach is often employed by expert systems, such as CLIPS.
One of the advantages of forward-chaining over backward-chaining is that the reception of new data can trigger new inferences, which makes the engine better suited to dynamic situations in which conditions are likely to change.
In this page we will learn about What is Forward Chaining and backward chaining in AI?, What is Inference engine?, Forward Chaining, Properties of Forward-Chaining, Facts Conversion into FOL,
What is Forward Chaining and backward chaining in AI?
Forward and backward chaining is an essential topic in artificial intelligence, but before we go into forward and backward chaining, let's look at where these two phrases come from.
What is Inference engine?
In artificial intelligence, the inference engine is a component of the intelligent system that applies logical rules to the knowledge base to infer new information from known facts. The expert system included the first inference engine. Inference engines often operate in one of two modes:
Horn Clause and Definite clause:
Horn clause and definite clause are sentence types that allow the knowledge base to apply a more limited and efficient inference algorithm. Forward and backward chaining techniques are used in logical inference algorithms, and they both need KB in the form of a first-order definite sentence.
A. Forward Chaining
When employing an inference engine, forward chaining is also known as forward deduction or forward reasoning. Forward chaining is a type of reasoning that starts with atomic sentences in a knowledge base and uses inference rules (Modus Ponens) to extract more data in the forward direction until a goal is attained.
The Forward-chaining algorithm begins with known facts, then activates all rules with satisfied premises and adds their conclusion to the known facts. This process continues until the issue is resolved.
Properties of Forward-Chaining:
"As per the law, it is a crime for an American to sell weapons to hostile nations. Country A, an enemy of America, has some missiles, and all the missiles were sold to it by Robert, who is an American citizen."
Prove that "Robert is criminal."
Facts Conversion into FOL:
Difference between backward chaining and forward chainingFollowing is the difference between the forward chaining and backward chaining:
Forward chainingBackward chaining1.Forward chaining begins with known facts and uses inference rules to extract more data units until it gets the desired outcome.Backward chaining starts with the objective and works backwards using inference rules to locate the necessary facts to support it.2.It is a bottom-up approach.It is a top-down approach.3.Forward chaining is also regarded as a data-driven inference strategy because it allows us to attain our goal using the data we already have.Backward chaining is a goal-driven strategy since it begins with the objective and divides it into sub-goals in order to extract the facts.4.Forward chaining is also regarded as a data-driven inference strategy because it allows us to attain our goal using the data we already have.Backward chaining is a goal-driven strategy since it begins with the objective and divides it into sub-goals in order to extract the facts.5.All of the available rules are subjected to forward chaining testing.Only a few required rules are tested via backward chaining.6.Forward chaining is appropriate for applications such as planning, monitoring, control, and interpretation.Backward chaining is a useful technique for diagnosing, prescribing, and debugging.7.Forward chaining can lead to an unlimited number of different outcomes.The number of possible conclusions generated by backward chaining is finite.8.It works in the forward direction.It works in the backward direction.9.The goal of forward chaining is to reach any conclusion.Backward chaining is only for the data that is required.
What is forward and backward reasoning?
The forward reasoning is data-driven approach while backward reasoning is a goal driven. The process starts with new data and facts in the forward reasoning. Conversely, backward reasoning begins with the results. Forward reasoning aims to determine the result followed by some sequences.
When to use forward chaining and backward chaining explain with an example?
Forward chaining can be used for tasks such as planning, design process monitoring, diagnosis, and classification, whereas backward chaining can be used for classification and diagnosis tasks. Forward chaining can be like an exhaustive search, whereas backward chaining tries to avoid the unnecessary path of reasoning.
What is the difference between backward and forward chaining?
As the name implies, forward chaining begins with known facts and moves forward by applying inference rules to extract more data, and it continues until it reaches the goal, whereas backward chaining begins with the goal and moves backward by applying inference rules to determine the facts that satisfy the goal.
What is forward reasoning in AI?
Forward Reasoning It is a data-driven task. It begins with new data. The object is to find a conclusion that would follow. It uses an opportunistic type of approach. It flows from incipient to the consequence.