Here's an example I proposed to Bob Pease in a letter a year or so ago: Consider the current popular concept of how radar works: if you delve into the subject you'll find that there isn't the pop science precision that has been seen in the movies and on tv for years. Instead, there's a terribly imprecise sort of 'blob' of energy that may or may not represent a legitimate echo. The problem is to quantify these blips of signal and decide whether or not there's something that should be displayed on the operator's vdt. How do you go about this? Well, you could set a threshold and display anything that exceeds it, but you'll quickly find that there are cases that are missed. You can set a variable threshold that is in turn adjusted by some set of rules, perhaps derived from observing human operators looking at a raw data display (like my father-in-law in the Pacific during WW2). There are almost as many approaches as there are similar problems; every embedded system programmer has run up against the problem of qualifying data in a 'crisp' way where the data refuses to cooperate. For these situations fuzzy logic presents a useful tool for representing the rule system and the data and applying the rules. There are other routes to building such a system, but the representation of the problem in fuzzy logic is one of the most elegant I've seen. The selection (or creation) of data structures that allow easy expressions of the applied algortihms is in my opinion on of the keys to successful programming. The degree of influence that the data representation has on how you think about solving problems is astonishing. At the end of the data manipulation (for the radar problem) the solution is removed from the fuzzy domain, which may make it seem that there is some sort af unneeded slight-of-hand going on. Let me assure you that there isn't. Remember, the human operator is also, in the end, making a decision whether or not to start yelling about bogies, but he isn't nearly as easily fooled by garbage on the display as most linear algorithms. Keeping the data and the rules in the fuzzy domain up until the final determination allows you to more closely approximate what goes on in the operator's head without a clue as to how it actually happens, in a neuronal sense. And programming the logical manipulations are pretty easy, so all in all, I consider it a really useful trick. -- Tom Rogers