Search code examples
logicfuzzy

How many rules we need in fuzzy logic?


How can determine how many rules and fuzzy sets we need in our fuzzy system? Is by increasing the rules and fuzzy sets, the system would be better? How can we determine how many rules and fuzzy sets we need actually for better results? Thanks


Solution

  • There are many different methods of determining where you need to model fuzziness in a particular application. The overarching principles to keep in mind are: 1) Look for places where it would be beneficial to treat ordinal or nominal data on a continuous scale, even at the cost of imprecision and 2) The "fuzz" should be naturally present in the data or problem you're trying to solve; it's not a secret ingredient one adds to make an application better, as is sometimes implied by overeager enthusiasts. Only add fuzzy rules and sets where it when you can justify the added computational/data collection/other costs in terms of greater accuracy or some other practical use.

    With those principles in mind, here are some ways of detecting places where fuzzy rules and sets might be useful:

    • The number one candidate is natural language modeling, perhaps through a Behavioral-Driven Development (BDD) process if you're in a software development environment. For example, you can interview people with domain knowledge and look for naturally fuzzy statements, such as "cloudy," "overcast" and "sunny" in meteorology, or fuzzy numbers, like "about half" or "most." Then find membership functions that most accurately match the meaning assigned to those terms. Note that sometimes terms from multiple fuzzy sets can occur together; for example, you grade the truth of the statement "about half of these days were cloudy," which might require three separate membership functions, one for truth, one for the fuzzy number and a third for the "cloudy" category. Linguistic analysis is the simplest way, since people naturally use fuzzy language every day; be aware though that multiple fuzzy sets can actually be combined to model fuzzy logic curiosities that don't often occur in natural language, like "“John is taller than he is clever,” “Inventory is higher than it is low,” “Coffee is at least as unhealthy as it is tasty,” and “Her last novel is more political than it is confessional.” Those examples come from p. 16, Bilgic, Taner and Turksen, I.B. August 1994, “Measurement–Theoretic Justification of Connectives in Fuzzy Set Theory,” pp. 289–308 in Fuzzy Sets and Systems, January 1995. Vol. 76, No. 3.

    • Another important task is sorting out how to model "linguistic connectives" like fuzzy ANDs and ORs, or crisp conjunctions between fuzzy statements. Some guiding principles have been worked out and are available in such sources as Alsina, C.; Trillas E. and Valverde, L., 1983, “On Some Logical Connectives for Fuzzy Sets Theory," pp. 15-26 in Journal of Mathematical Analysis and Applications. Vol. 93; Dubois, Didier and Prade, Henri, 1985, “A Review of Fuzzy Set Aggregation Connectives," pp. 85-121 in Information Sciences, July-August, 1985. Vol. 36, Nos. 1-2.

    • Pooling the opinions of experts (as in an expert system) or the subjective scores of others (as in a movie ratings system). The ratings themselves would constitute one level of fuzziness, while another tier could be added to weight the importance of each expert or other individual's particular score, if they're particularly authoritative.

    • Another option is to use neural nets to determine whether or not the addition of various fuzzy rules and sets to your model actually improves accuracy or some other metric related to your end goal.

    • Other options include estimating membership functions and the parameters of T-norms and T-conorms (which are used often in fuzzy complements, unions and intersections) with such techniques as regression, Maximum Likelihood Estimation (MLE), LaGrange interpolation, curve fitting and parameter estimation. All of these are discussed in my favorite reference for fuzzy set math, Klir, George J. and Yuan, Bo, 1995, Fuzzy Sets and Fuzzy Logic: Theory and Applications. Prentice Hall: Upper Saddle River, N.J.

    • In the same vein, deciding whether or not to include particular fuzzy rules or sets may depend on whether or not you can find a good fit between its underlying and possibly unknown "actual" membership function and the one's your testing. Most of the time triangular, trapezoidal or Gaussian functions will suffice, but in some situations distribution testing might be necessary to find just the right distribution function. Empirical Distribution Functions (EDFs) might come in handy here.

    To make a long story short, a lot of different statistical and machine learning techniques can be applied to give ballpark answers to these questions. The key is to always stay within the bounds of the two main principles above and only model things with fuzzy sets when it would serve your practical goals, then leave out the rest. I hope that helps.