31.10.2014 Views

What Is Fuzzy Logic?

What Is Fuzzy Logic?

What Is Fuzzy Logic?

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

2 Tutorial<br />

and the membership function line2 is defined by the equation<br />

output = () 1 × input + ( −1)<br />

The input membership functions and rules define which of these output<br />

functions are expressed and when:<br />

showrule(fismat)<br />

ans =<br />

1. If (input is low) then (output is line1) (1)<br />

2. If (input is high) then (output is line2) (1)<br />

The function plotmf shows us that the membership function low generally<br />

refers to input values less than zero, while high refers to values greater<br />

than zero. The function gensurf shows how the overall fuzzy system output<br />

switches smoothly from the line called line1 tothelinecalledline2.<br />

subplot(2,1,1), plotmf(fismat,'input',1)<br />

subplot(2,1,2),gensurf(fismat)<br />

low<br />

1<br />

high<br />

Degree of belief<br />

0.8<br />

0.6<br />

0.4<br />

0.2<br />

0<br />

−5 −4 −3 −2 −1 0 1 2 3 4 5<br />

input<br />

4<br />

3<br />

output<br />

2<br />

1<br />

0<br />

−1<br />

−5 −4 −3 −2 −1 0 1 2 3 4 5<br />

input<br />

2-104

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!