\documentclass[letter,12pt,a4Paper]{article}
\topmargin-0.5in
\oddsidemargin-0.25in
\evensidemargin-0.25in
\textheight9in
\textwidth17cm
%\pdfoutput1
\usepackage{times}
\usepackage[]{graphicx}
\usepackage[bf,small]{caption}
\newcommand{\cc}{{\cal C}}
\newcommand{\cf}{{\cal F}}
\newcommand{\cg}{{\cal G}}
\newcommand{\cs}{{\cal S}}
\newcommand{\ch}{{\cal H}}
\newcommand{\ck}{{\cal K}}
\newcommand{\cu}{{\cal U}}
\newcommand{\en}{{\cal N}}
\newcommand{\cn}{{\cal N}}
\newcommand{\ct}{{\cal T}}
\newcommand{\1}{\mbox{\large \sf 1}}
\newcommand{\eN}{\mbox{{\sf I}\hspace{-0,3ex}{\sf N}}}
\newcommand{\eR}{\mbox{{\sf I}\hspace{-0,3ex}{\sf R}}}
\renewcommand{\baselinestretch}{0.99}
\title{\bf\large Fuzzy Logic Introduction}
 \author{\bf\normalsize M. Hellmann \\
\small Laboratoire Antennes Radar Telecom,
\small F.R.E CNRS 2272, Equipe Radar Polarimetrie,\\
\small Universit{\'e} de Rennes 1,
\small UFR S.P.M, Campus de Beaulieu - Bat. 22,\\
\small 263 Avenue General Leclerc, CS 74205, 35042 Rennes Cedex, France\\}
\date{}
\pagestyle{empty}
\begin{document}
\maketitle
\thispagestyle{empty}
%\vspace{-12em}
%\noindent
\noindent
\begin{center}
{\sc 1.Introduction}
\end{center} 


\noindent Fuzzy Logic was initiated in 1965 [1], [2], [3], by Lotfi A. Zadeh , professor for computer science at the University of California in Berkeley. 
Basically, Fuzzy Logic (FL) is a multivalued logic, that allows intermediate values to be defined between conventional evaluations like true/false, yes/no,  high/low, etc. Notions like rather tall or very fast can be formulated mathematically and processed by computers, in order to apply a more human-like way of thinking in the programming of computers [4]. 
Fuzzy systems is an alternative to traditional notions of set membership and logic that has its origins in ancient Greek philosophy. The precision of mathematics owes its success in large part to the efforts of Aristotle and the philosophers who preceded him. In their efforts to devise a concise theory of logic, and later mathematics, the so-called "Laws of Thought" were posited [5]. One of these, the "Law of the Excluded Middle," states that every proposition must either be True or False. Even when Parminedes proposed the first version of this law (around 400 B.C.) there were strong and immediate objections: for example, Heraclitus proposed that things could be simultaneously True and not True. It was Plato who laid the foundation for what would become fuzzy logic, indicating that there was a third region (beyond True and False) where these opposites "tumbled about." Other, more modern philosophers echoed his sentiments, notably Hegel, Marx, and Engels. But it was Lukasiewicz who first proposed a systematic alternative to the bi--valued logic of Aristotle [6]. Even in the present time some Greeks are still outstanding examples for  fussiness  and fuzziness, (note: the connection to logic got lost somewhere during the last 2 mileniums [7]). 
Fuzzy Logic has emerged as a a profitable tool for the controlling and steering of of systems and complex industrial processes, as well as for household and entertainment electronics, as well as for other expert systems and applications like the classification of SAR  data. 

\begin{center}
{\sc 2. Fuzzy Sets and Crisp Sets}
\end{center} 

\noindent The very basic notion of fuzzy systems is a fuzzy  (sub)set. In classical mathematics we are familiar with what we call crisp sets. For example, the possible interferometric coherence g  values are the set X  of all real numbers between 0 and 1. From this set X a subset A can be defined, (e.g. all values 
0 $\le$ g $\le$ 0.2).  The characteristic function of  A, (i.e. this function assigns a number 1 or  0  to each element in  $X$,  depending on whether the element is in the subset A or not) is shown in Fig.1.

\begin{figure}[htb]
\begin{center}
\includegraphics[height=4cm]{fig_2_7a.eps}
%\vspace{-1.4em}
\caption{Characteristic Function of a Crisp Set}
\label{rule_based_clustering_col2}
\end{center}
%\vspace{-1em}
\end{figure}		           

\noindent The elements which have been assigned the number 1 can be interpreted as the elements that are in the set  A and the elements which have assigned the number 0 as the elements that are not  in the set A. This concept is sufficient for many areas of applications, but it can easily be seen, that it lacks in flexibility for some applications like classification of remotely sensed data analysis.
For example it is well known that water shows low interferometric coherence g  in SAR images. Since g  starts at 0,  the lower range of this set ought to be clear. The upper range, on the other hand, is rather hard to define. As a first attempt, we set the upper range to 0.2. Therefore we get  B as a crisp interval B=[0,0.2]. But this means that a g  value of 0.20 is low but a g value of  0.21 not. Obviously, this  is a structural problem, for if we moved the upper boundary of the range from g =0.20 to an arbitrary point we can pose the same question. A more natural way to construct the set  B  would be to relax the strict separation between low and not low. This can be done by allowing not only the (crisp) decision  Yes/No, but more flexible rules like " fairly low". A fuzzy set allows us to define such a notion. 
The aim is to use fuzzy sets in order to make computers more 'intelligent', therefore, the idea above has to be coded more formally. In the example, all the elements were coded with 0 or 1. A straight way to generalize this concept, is to allow more values between 0 and 1. In fact, infinitely many alternatives can be allowed between the boundaries 0 and 1, namely the unit interval  I = [0, 1].
The interpretation of the numbers, now assigned to all elements is much more difficult. Of course, again the number 1 assigned to an element means, that the element is in the set  B and  0 means that the element is definitely not in the set  B. All other values mean a  gradual membership to the set  B. This  is shown in Fig. 2. The membership function is a graphical representation of the magnitude of participation of each input. It associates a weighting with each of the inputs that are processed, define functional overlap between inputs, and ultimately determines an output response. The rules use the input membership values as weighting factors to determine their influence on the fuzzy output sets of the final output conclusion. 

\begin{figure}[htb]
\begin{center}
\includegraphics[height=4cm]{fuzzyset.eps}
%\vspace{-1.4em}
\caption{Characteristic Function of a Fuzzy Set}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}		 
		       

\noindent The membership function, operating in this case on the fuzzy set of interferometric coherence g, returns a value between 0.0 and 1.0. For example, an interferometric coherence  g  of 0.3 has a membership of 0.5 to the set low coherence (see Fig. 2). It is  important to point out the distinction between fuzzy logic and probability. Both operate over the same numeric range, and have similar values: 0.0 representing False (or non-membership), and 1.0 representing True (or full-membership). However, there is a distinction to be made between the two statements: The probabilistic approach yields the natural-language statement, "There is an 50\% chance that g is low," while the fuzzy terminology corresponds to "g's degree of membership within the set of low interferometric coherence is 0.50." The semantic difference is significant: the first view supposes  that g  is or is not low; it is just that we only have an 50\% chance of knowing which set it is  in. By contrast, fuzzy  terminology supposes that  g  is "more or less"  low, or in some other term corresponding to the value of 0.50.

\begin{center}
{\sc 4. Operations on Fuzzy Sets}
\end{center}

\noindent We can introduce basic operations on fuzzy sets. Similar to the operations on crisp sets we also want to intersect,  unify  and negate fuzzy sets. In his very first paper about fuzzy sets [1], L. A. Zadeh suggested the minimum operator for the intersection and the maximum operator  for the union of two fuzzy sets. It can be shown that these operators coincide with the crisp unification, and intersection if we only consider the membership degrees 0 and 1.  For example, if A is a fuzzy interval between 5 and 8 and B  be a fuzzy number about 4 as shown in the Figure below

\begin{figure}[htb]
\begin{center}
\includegraphics[height=3cm,width=16cm]{fuzzyab.eps}
%\vspace{-1.4em}
\caption{Example fuzzy sets}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}		 				
 
\noindent  In this  case, the fuzzy set between 5 and 8 AND about 4 is 

\begin{figure}[htb]
\begin{center}
\includegraphics[height=3cm]{fuzzyand.eps}
%\vspace{-1.4em}
\caption{Example: Fuzzy AND}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}		 
				 
\noindent set between 5 and 8 OR about 4 is shown in the next figure

\begin{figure}[htb]
\begin{center}
\includegraphics[height=3cm]{fuzzyor.eps}
%\vspace{-1.4em}
\caption{Example: Fuzzy OR}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}	

\noindent the NEGATION of the fuzzy set A is shown below

\begin{figure}[htb]
\begin{center}
\includegraphics[height=3cm]{fuzzyneg.eps}
%\vspace{-1.4em}
\caption{Example: Fuzzy NEGATION}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}	
				

\begin{center}
{\sc 5. Fuzzy Classification}
\end{center} 

\noindent Fuzzy classifiers are one application of fuzzy theory. Expert knowledge is used and can be expressed in a very natural way using linguistic variables , which are described by fuzzy sets 
			
\begin{figure}[htb]
\begin{center}
\includegraphics[height=7cm]{fuzzysetexamples.eps}
%\vspace{-1.4em}
\caption{Example: Linguistic Variables}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}	


\noindent Now the expert knowledge for this variables can be formulated as  a rules like

IF feature A low AND  feature B medium AND  feature C medium  AND  feature D medium THEN  Class  = class 4

\noindent The rules can be combined in a table calls rule base 



\begin{table}[h!]  
\begin{center}
\begin{tabular}{|c|c|c|c|c|c|} %%% this part creates array of columns; ccc to center each entry in each column
\hline  %----------------------
\rule{0pt}{2.5ex} R\#  & feature A & feature B & feature C & feature D & class \\[0.2ex]
\hline  %----------------------
\hline 
 1: &low 	  &medium      &medium &medium	  & class1\\[0.2ex] \hline
 2: &medium	  &high      &medium &low	  & class2\\[0.2ex] \hline
   3: &low &high      &medium &high	  & class3 \\[0.2ex] \hline
   4: & low &high      &medium &high	  & class 1\\[0.2ex]\hline  
	   5: &medium &medium      &medium &medium	  & class 4\\[0.2ex] \hline
 ...: &... &...     &... &...	  & ...\\[0.2ex] \hline
 N: &low & high      &medium &low 	  & unknown\\[0.2ex] \hline 
\end{tabular}
\caption{Example for a fuzzy rule base: Rules read as (e.g. RULE No.1: {\bf IF}  $A$ is  low  {\bf AND} $H$ is  med. {\bf AND}  $\alpha$ is  med {\bf AND}  $A$ is  med. {\bf THEN}  pixel is  class 1}
\end{center}
\end{table}

   
\noindent Linguistic rules describing the control system consist of two parts; an antecedent block (between the IF and THEN) and a consequent block (following THEN). Depending on the system, it may not be necessary to evaluate every possible input combination, since some may rarely or never occur. By making this type of evaluation, usually done by an experienced operator, fewer rules can be evaluated, thus simplifying the processing logic and perhaps even improving the fuzzy logic system performance. 
The inputs are combined logically using the AND operator to produce output response values  for all expected inputs.  The active conclusions are then combined into a logical sum for each membership function. A firing strength for each output membership function is computed. All that remains is to combine these logical sums in a defuzzification process  to produce the crisp output. E.g for a for the rule consequents  for each class  a so-called singleton or a min--max interference can be derived which is the characteristic function of the respective set . E.g. For the input pair of $H=0.35$ and $\alpha=30^°$ the scheme below (see Figure 7.) would apply.

\begin{figure}[htb]
\begin{center}
\includegraphics[height=7cm]{fuzzyintab.eps}
%\vspace{-1.4em}
\caption{Interference for rule IF H very low AND a low THEN Class = class 1}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}	

\noindent The fuzzy outputs for all rules are finally  aggregated to one fuzzy set.To obtain a crisp decision from this fuzzy output, we have to defuzzify the fuzzy set, or the set of singletons. Therefore, we have to choose one representative value as the final output. There are several heuristic methods (defuzzification methods), one of them is e.g. to take the center of gravity of the fuzzy set as shown in figure 7., which is widely used for fuzzy sets. For the discrete case with singletons usually the the maximum-method is used where the point with the maximum singleton is chosen.

\begin{figure}[htb]
\begin{center}
\includegraphics[height=5cm]{fuzzy_result.eps}
%\vspace{-1.4em}
\caption{Defuzzification using the center of gravity approach}
\label{}
\end{center}
%\vspace{-1em}
\end{figure}	

\begin{center}
{\sc 4.1. Example: Classification of Polarimetric SAR Data}
\end{center} 

\noindent One way to use the the fuzzy logic approach for the classification of SAR data is to applied a fuzzy rule base in order to incorporate expert
knowledge. These rules are given in a descriptive way and one may use techniques of approximate
reasoning to evaluate them. In the literature there is a variety of textbooks dealing with
this subject [15],[16], and the example below is used to illustrate the
 strategy.

\begin{table}[htb]
\begin{center}
%\small
\begin{tabular}{|c|c|c||c|}\hline $
\lambda   $&  H             & $  \alpha   $&  {\em Decision } \\ \hline
\hline very high & medium & & urban\\
 \hline high or very high& very low  & medium/high & urban \\
\hline high & high & & forest \\
\hline medium  & high & medium/high & forest \\ medium  & medium
& medium/low & vegetation \\
medium  & low or very low & low & vegetation \\ \hline (very) low &  & & runway \\
 \hline \end{tabular} \label{rules} \caption{Classification rules}
\vspace{-1ex}
\end{center} 
\end{table}

%\normalsize
\noindent First we fix a set of 'expert rules' which are used to classify the image.
E.g. the third line reads: IF $\lambda$ is high AND $H$ is high THEN pixel is 
of class 'forest'.
Every term in each rule such as '$\lambda$ is high' is a so--called {\em linguistic variable},
 i.e. is of an imprecise nature. Following Zadeh [1] one can describe them with fuzzy sets. A
{\em fuzzy set} {\em A} is defined by a membership function $\mu_A$ from the universe of
discourse $X_i$(i.e. the possible values of the variable -- $X_H=[0,1] $ for the entropy {\em H},
$X_{\alpha}=[0,90]$ for the $\alpha$--angle) to the closed unit interval [0,1]. We interpret
$\mu_A(x)$ as the degree of membership of {\em x} in {\em A}. The linguistic variables and their
representation as fuzzy sets are shown in Fig. ~\ref{fuzzy_scheme} . For the entropy and $\alpha$ -- angle parameters it is
possible to define the fuzzy sets data independently. This is -- in general --
not possible for the first eigenvalue as its range depends on the data. So these fuzzy
sets for the linguistic variables have to be interactively defined.
To this end, in order to visualize the first eigenvalue, the logarithm of it is used and
scaled it to the grey scale interval [0,255]. From this interval six occurring (grey)values are chosen (e.g. ranging from very low (water or any very smooth surface) to very high (reflections from buildings). These values   determine the shape of the membership
functions (Fig. ~\ref{fuzzy_scheme}). For computational simplicity in all cases triangular or trapezoid were chosen.


\begin{figure}[htb]
\begin{center}
\includegraphics[width=16cm, height=8cm]{ieee_fig4.eps}
\caption{The linguistic variables and their representation as fuzzy sets}
\label{fuzzy_scheme}
\end{center}
\end{figure}

\noindent The algorithm now determines the class of an image pixel following the expert rules of Tab. 2 according to the Mamdani approach for fuzzy control [15].

\begin{figure}[htb]
\begin{center}
\includegraphics[width=16cm]{diss_fuzzy_sheme.eps}
\caption{Fuzzy classification scheme}
\label{class_scheme}
\end{center}
\end{figure}

\noindent Input to the system is a triple of values ($\lambda,H,\alpha$) for the image pixel.
In a first step this triple is {\em fuzzified}, i.e. for each linguistic
variable the degree is determined to which $(\lambda,H,\alpha)$ fulfills it. This is done by evaluating
the values of the corresponding membership functions. For example for the triple
$[(\lambda,H,\alpha)]$=[100,0.5,30)] the degree of 'medium $\lambda$' is $\mu_{medium-\lambda}(100)=0.74$.
The degree of the rule antecedents is then computed by taking the minimum of all present degrees.
This degree is also chosen as the degree with which the rule is fulfilled, i.e. the degree
of the rule consequent. E.g. the triple {\em (100,0.5,30)} fulfills the third rule with
degree $degree(rule3)=\min\{\mu_{high-\lambda}(100),\mu_{high-entropy}(0.5)\} = \min\{0.74,1\}=0.74$.
The degree of the class 'forest' is then computed by taking the maximum of all rules
describing this class i.e. $degree(forest)=\max\{degree(rule3),degree(rule6)\}$. A pixel
may thus belong to several classes with certain degrees, a fact which reflects very well
the problem of having more than one class in one resolution cell.
To obtain a crisp classification from this fuzzy classification  the fuzzy output of the system has to be {\em defuzzified}. For example, his can be done by assigning the class with maximum degree to the pixel. However, with this last step information is lost. For example, a pixel belonging 
to the class 'forest' with degree 0.8 and to the class 'urban' with degree 0.9 is assigned
to the class 'urban', whereas the representation of the pixel as 'forest or urban' would be
more appropriate. This additional information is a particular advantage of a fuzzy system
compared to crisp classification systems. For example, in a subsequent context based
Filtering this information can be evaluated if a pixel belonging to class {\em A}
is surrounded by pixels belonging to class {\em B} and the membership value for for class {\em B} of
 the pixel of interest is also high the pixel is assigned to class {\em B}.


\begin{center}
{\sc 5. Conclusions}
\end{center} 

\noindent Fuzzy Logic provides a different way to approach a control or classification problem. This  method focuses on what the system should do rather than trying to model how it works. One can concentrate on solving the problem rather than trying to model the system mathematically, if that is even possible.  On the other hand the fuzzy approach requires a sufficient expert knowledge for the formulation of the rule base, the combination of the sets and the defuzzification. In General, the employment of fuzzy logic might be helpful, for very complex processes, when there is no simple mathematical model (e.g. Inversion problems),  for highly nonlinear processes  or if the processing of (linguistically formulated) expert knowledge is  to be performed. According to literature the employment of fuzzy logic is not recommendable, if the conventional approach yields a satisfying result,  an easily solvable and adequate mathematical model already exists , or the problem is not solvable ;)


 
\begin{center}
{\sc References}
\end{center} 

\begin{description}

\vspace{-0.5em}
\item$[1]$ L.A. Zadeh, Fuzzy Sets, Information and Control, 1965 
\vspace{-0.5em}
\item$[2]$ L.A. Zadeh, Outline of A New Approach to the Analysis of of Complex Systems and Decision Processes, 1973
\vspace{-0.5em}
\item$[3]$  L.A. Zadeh, "Fuzzy algorithms," Info. \& Ctl., Vol. 12, 1968, pp. 94-102. 
\vspace{-0.5em}
\item$[4]$  L.A. Zadeh, "Making computers think like people," IEEE. Spectrum, 8/1984, pp. 26-32. 
\vspace{-0.5em}
\item$[5]$  S. Korner, "Laws of thought," Encyclopedia of Philosophy, Vol. 4, MacMillan, NY: 1967, pp. 414-417. 
\vspace{-0.5em}
\item$[6]$  C. Lejewski, "Jan Lukasiewicz," Encyclopedia of Philosophy, Vol. 5, MacMillan, NY: 1967, pp. 104-107. 
\vspace{-0.5em}
\item$[7]$  A. Reigber, "My life with Kostas", unpublished report, Neverending Story Press , 1999 
\vspace{-0.5em}
\item$[8]$  J.F. Baldwin, "Fuzzy logic and fuzzy reasoning," in Fuzzy Reasoning and Its Applications, E.H. Mamdani and B.R. Gaines (eds.), London: Academic Press, 1981. 
\vspace{-0.5em}
\item$[9]$  W. Bandler and L.J. Kohout, "Semantics of implication operators and fuzzy relational products," in Fuzzy Reasoning and Its Applications, E.H. Mamdani and B.R. Gaines (eds.), London: Academic Press, 1981. 
\vspace{-0.5em}
\item$[10]$  M. Eschbach and J. Cunnyngham, "The logic of fuzzy Bayesian influence," paper presented at the International Fuzzy Systems Association Symposium of Fuzzy information Processing in Artificial Intelligence and \vspace{-0.5em}
Operational Research, Cambridge, England: 1984. 
\item$[11]$  F. Esragh and E.H. Mamdani, "A general approach to linguistic approximation," in Fuzzy Reasoning and Its Applications, E.H. Mamdani and B.R. Gaines (eds.), London: Academic Press, 1981. 
\vspace{-0.5em}
\item$[12]$  J. Fox, "Towards a reconciliation of fuzzy logic and standard logic," Int. Jrnl. of Man-Mach. Stud., Vol. 15, 1981, pp. 213-220. 
\vspace{-0.5em}
\item$[13]$  S. Haack, "Do we need fuzzy logic?" Int. Jrnl. of Man-Mach. Stud., Vol. 11, 1979, pp.437-445.
\vspace{-0.5em}
\item$[14]$  T. Radecki, "An evaluation of the fuzzy set theory approach to information retrieval," in R. Trappl, N.V. Findler, and W. Horn, Progress in Cybernetics and System Research, Vol. 11: Proceedings of a Symposium Organized by the Austrian Society for Cybernetic Studies, Hemisphere Publ. Co., NY: 1982. 
\vspace{-0.5em}
\item$[15]$  R. Kruse, J. Gebhardt, F. Klawon, "Foundations of Fuzzy Systems", Wiley, Chichester 1994  
\vspace{-0.5em}
\item$[16]$  Zimmermann H.J.,
{\em Fuzzy Sets, Decision Making and Expert Systems},
Boston, Kluwer 1987
\vspace{-0.5em}
\item$[16]$  M. Hellmann, "Classification of fully  polarimetric SAR for Cartographic Applications", {\em DLR Forschungsbericht FB--2000--19}, PhD thesis, DLR, Oberpfaffenhofen, Germany, 2000   
 
\end{description}
\end{document}
