> > >
Fuzzy Logic
Fuzzy logic is an attempt to get the easy design of logic controllers, and yet control continuously-varying systems. Basically, a measurement in a fuzzy logic system can be partly true, that is, if yes is 1, and no is 0, a fuzzy measurement can be between 0 and 1.

The rules of the system are written in natural language, and translated into fuzzy logic. For example, the design for a furnace would start with: "If the temperature is too high, reduce the fuel to the furnace. If the temperature is too low, increase the fuel to the furnace."

Measurements from the real world (such as the temperature of a furnace) are converted to values between 0 and 1 by seeing where they fall on a triangle. Usually the tip of the triangle is the maximum possible value, which translates to "1."

Fuzzy logic then modifies Boolean logic to be arithmetical. Usually the "not" operation is "output = 1 - input", the "and" operation is "output = input.1 multiplied by input.2", and "or" is "output = 1 - ((1 - input.1) multiplied by (1 - input.2))."

The last step is to "defuzzify" an output. Basically, the fuzzy calculations make a value between zero and one. That number is used to select a value on a line whose slope and height converts the fuzzy value to a real-world output number. The number then controls real machinery.

If the triangles are defined correctly, and rules are right, the result can be a good control system.