This document discusses the fundamentals of fuzzy logic control systems. It begins by defining fuzzy logic as a problem-solving control system methodology that uses linguistic variables and fuzzy rules to map inputs to outputs. It then outlines the typical elements of a fuzzy logic system, including fuzzy sets, linguistic variables, fuzzy rules, fuzzy inference, and defuzzification. Finally, it provides an example of applying fuzzy logic to control the temperature in a simple heating/cooling system.
4. IntroductionIntroductionIntroductionIntroductionIntroductionIntroductionIntroductionIntroduction
DescribeDescribe thethe valuevalue ofof variablesvariables
Apparatus of Fuzzy logic is built on :
Fuzzy sets :
QualitativelyQualitatively andand quantitativelyquantitativelyLinguistic
9/12/2013 Mahesh J. vadhavaniya 3
QualitativelyQualitatively andand quantitativelyquantitatively
describeddescribed byby fuzzyfuzzy setssets
Linguistic
Variables :
AA knowledgeknowledgeFuzzy if -
then rules :
LinguisticLinguistic valuesvalues toto numericalnumerical valuesvaluesDefuzzification :
6. ApproachApproachApproachApproachApproachApproachApproachApproach
Preliminary Evaluation :
Problem Analysis before Project start !
EvaluationEvaluation CriteriaCriteria :
AssessmentAssessment asas toto whetherwhether FuzzyFuzzy logiclogic isis applicableapplicable forfor
thethe givengiven applicationapplication..
9/12/2013 Mahesh J. vadhavaniya 5
HasHas fuzzyfuzzy logiclogic beenbeen previouslypreviously appliedapplied toto aa similarsimilar applicationapplication
WithWith success?success?
IsIs itit aa multimulti--variablevariable typetype controlcontrol problem?problem?
DoDo operatorsoperators andand engineersengineers possesspossess knowledgeknowledge aboutabout anyany relevantrelevant
interdependenciesinterdependencies ofof thethe processprocess variables?variables?
CanCan furtherfurther knowledgeknowledge aboutabout thethe processprocess behaviorbehavior bebe gainedgained byby
observationobservation oror experiments?experiments?
IsIs itit difficultdifficult toto obtainobtain aa mathematicalmathematical modelmodel fromfrom thethe process?process?
7. UsageUsageUsageUsage
1.1. Define the control objectives and criteriaDefine the control objectives and criteria
What am I trying to control?What am I trying to control?
What do I have to do to control the system?What do I have to do to control the system?
What kind of response do I need?What kind of response do I need?
What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?
ApproachApproachApproachApproachApproachApproachApproachApproach
What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?
2.2. Determine the input and output relationshipsDetermine the input and output relationships
Choose a minimum number of variables for input to theChoose a minimum number of variables for input to the
FL engineFL engine
3.3. Use the ruleUse the rule--based structure of FLbased structure of FL
Break the control problem down into a series of rulesBreak the control problem down into a series of rules
4.4. Create FL membership functionsCreate FL membership functions
Define the meaning (values) of Input / Output terms usedDefine the meaning (values) of Input / Output terms used
in the rulesin the rules
5.5. Test, evaluate, tune and retestTest, evaluate, tune and retest
9/12/2013 Mahesh J. vadhavaniya 6
8. The Rule MatrixThe Rule Matrix
Error (Columns)Error (Columns)
ErrorError--dot (Rows)dot (Rows)
Input conditionsInput conditions
ApproachApproachApproachApproachApproachApproachApproachApproach
--veve
ErrorError
ZeroZero
ErrorError
+ve+ve
ErrorError
--veve
ErrorError--
dotdotInput conditionsInput conditions
(Error and Error(Error and Error--
dot)dot)
Output ResponseOutput Response
ConclusionConclusion
(Intersection of Row(Intersection of Row
and Column)and Column)
dotdot
ZeroZero
ErrorError--
dotdot
NoNo
changechange
+ve+ve
ErrorError--
dotdot
Rule MatrixRule Matrix
9/12/2013 Mahesh J. vadhavaniya 7
9. ComponentsComponents
An electric heating elementAn electric heating element
VariableVariable--speed cooling fanspeed cooling fan
ApplicationApplicationApplicationApplicationApplicationApplicationApplicationApplication
SimpleSimple ProportionalProportional TemperatureTemperature ControllerController :
VariableVariable--speed cooling fanspeed cooling fan
FunctionalityFunctionality
Positive signal output: 0Positive signal output: 0--100% heat100% heat
Negative signal output: 0Negative signal output: 0--100% cooling100% cooling
9/12/2013 Mahesh J. vadhavaniya 8
11. ApplicationApplicationApplicationApplicationApplicationApplicationApplicationApplication
WorkingWorking
Establish a meaningful system for representing theEstablish a meaningful system for representing the
linguistic variables in the Rule Matrixlinguistic variables in the Rule Matrix
"N" = "negative" error/ error"N" = "negative" error/ error--dot input leveldot input level"N" = "negative" error/ error"N" = "negative" error/ error--dot input leveldot input level
"Z" = "zero" error/ error"Z" = "zero" error/ error--dot input leveldot input level
"P" = "positive" error/ error"P" = "positive" error/ error--dot input leveldot input level
"H" = "Heat" output response"H" = "Heat" output response
""--" = "No Change" to current output" = "No Change" to current output
"C" = "Cool" output response"C" = "Cool" output response
9/12/2013 Mahesh J. vadhavaniya 10
12. ApproachApproachApproachApproachApproachApproachApproachApproach
UsageUsageUsageUsage
1.1. Define the control objectives and criteriaDefine the control objectives and criteria
What am I trying to control?What am I trying to control?
What do I have to do to control the system?What do I have to do to control the system?
What kind of response do I need?What kind of response do I need?
What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?
2.2. Determine the input and output relationshipsDetermine the input and output relationships
Choose a minimum number of variables for input to theChoose a minimum number of variables for input to the
FL engineFL engine
3.3. Use the ruleUse the rule--based structure of FLbased structure of FL
Break the control problem down into a series of rulesBreak the control problem down into a series of rules
4.4. Create FL membership functionsCreate FL membership functions
Define the meaning (values) of Input / Output terms usedDefine the meaning (values) of Input / Output terms used
in the rulesin the rules
5.5. Test, evaluate, tune and retestTest, evaluate, tune and retest
9/12/2013 Mahesh J. vadhavaniya 11
13. 1.1. Define the control objectives and criteriaDefine the control objectives and criteria
What am I trying to control?What am I trying to control?
System temperatureSystem temperature
What do I have to do to control the system?What do I have to do to control the system?
Proper balance and control of the functional devicesProper balance and control of the functional devices
ApplicationApplicationApplicationApplicationApplicationApplicationApplicationApplication
Proper balance and control of the functional devicesProper balance and control of the functional devices
What kind of response do I need?What kind of response do I need?
Stable Environment temperatureStable Environment temperature
What are the possible (probable) system failureWhat are the possible (probable) system failure
modes?modes?
The lack of the “No change” regionThe lack of the “No change” region
9/12/2013 Mahesh J. vadhavaniya 12
14. What is being controlled and how?What is being controlled and how?
ApplicationApplicationApplicationApplicationApplicationApplicationApplicationApplication
Typical control system responseTypical control system response
9/12/2013 Mahesh J. vadhavaniya 13
15. ApproachApproachApproachApproachApproachApproachApproachApproach
UsageUsageUsageUsage
1.1. Define the control objectives and criteriaDefine the control objectives and criteria
What am I trying to control?What am I trying to control?
What do I have to do to control the system?What do I have to do to control the system?
What kind of response do I need?What kind of response do I need?
What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?
2.2. Determine the input and output relationshipsDetermine the input and output relationships
Choose a minimum number of variables for input to theChoose a minimum number of variables for input to the
FL engineFL engine
3.3. Use the ruleUse the rule--based structure of FLbased structure of FL
Break the control problem down into a series of rulesBreak the control problem down into a series of rules
4.4. Create FL membership functionsCreate FL membership functions
Define the meaning (values) of Input / Output terms usedDefine the meaning (values) of Input / Output terms used
in the rulesin the rules
5.5. Test, evaluate, tune and retestTest, evaluate, tune and retest
9/12/2013 Mahesh J. vadhavaniya 14
16. ApplicationApplicationApplicationApplicationApplicationApplicationApplicationApplication
2.2. Determine the input and output relationshipsDetermine the input and output relationships2.2. Determine the input and output relationshipsDetermine the input and output relationships
Define the minimum number of possible input productDefine the minimum number of possible input product
combinations and corresponding output responsecombinations and corresponding output response
conclusionsconclusions
INPUT#1: ("Error", positive (P), zero (Z), negative (N))
INPUT#2: ("Error-dot", positive (P), zero (Z), negative (N))
CONCLUSION: ("Output", Heat (H), No Change (-), Cool (C))CONCLUSION: ("Output", Heat (H), No Change (-), Cool (C))
INPUT#1 System Status
Error = Command-Feedback
P=Too cold, Z=Just right, N=Too hot
INPUT#2 System Status
Error-dot = d(Error)/dt
P=Getting hotter Z=Not changing N=Getting colder
OUTPUT Conclusion & System Response
Output H = Call for heating - = Don't change anything C = Call for cooling
9/12/2013 Mahesh J. vadhavaniya 15
17. ApproachApproachApproachApproachApproachApproachApproachApproach
UsageUsageUsageUsage
1.1. Define the control objectives and criteriaDefine the control objectives and criteria
What am I trying to control?What am I trying to control?
What do I have to do to control the system?What do I have to do to control the system?
What kind of response do I need?What kind of response do I need?
What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?
2.2. Determine the input and output relationshipsDetermine the input and output relationships
Choose a minimum number of variables for input to theChoose a minimum number of variables for input to the
FL engineFL engine
3.3. Use the ruleUse the rule--based structure of FLbased structure of FL
Break the control problem down into a series of rulesBreak the control problem down into a series of rules
4.4. Create FL membership functionsCreate FL membership functions
Define the meaning (values) of Input / Output terms usedDefine the meaning (values) of Input / Output terms used
in the rulesin the rules
5.5. Test, evaluate, tune and retestTest, evaluate, tune and retest
9/12/2013 Mahesh J. vadhavaniya 16
18. APPLICATION (Contd.)
3.3. Use the ruleUse the rule--based structure of FLbased structure of FL
ApplicationApplicationApplicationApplicationApplicationApplicationApplicationApplication
9/12/2013 Mahesh J. vadhavaniya 17
19. ApproachApproachApproachApproachApproachApproachApproachApproach
UsageUsageUsageUsage
1.1. Define the control objectives and criteriaDefine the control objectives and criteria
What am I trying to control?What am I trying to control?
What do I have to do to control the system?What do I have to do to control the system?
What kind of response do I need?What kind of response do I need?
What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?
2.2. Determine the input and output relationshipsDetermine the input and output relationships
Choose a minimum number of variables for input to theChoose a minimum number of variables for input to the
FL engineFL engine
3.3. Use the ruleUse the rule--based structure of FLbased structure of FL
Break the control problem down into a series of rulesBreak the control problem down into a series of rules
4.4. Create FL membership functionsCreate FL membership functions
Define the meaning (values) of Input / Output terms usedDefine the meaning (values) of Input / Output terms used
in the rulesin the rules
5.5. Test, evaluate, tune and retestTest, evaluate, tune and retest
9/12/2013 Mahesh J. vadhavaniya 18
21. A sample caseA sample case
ApplicationApplicationApplicationApplicationApplicationApplicationApplicationApplication
9/12/2013 Mahesh J. vadhavaniya 20
22. ApproachApproachApproachApproachApproachApproachApproachApproach
UsageUsageUsageUsage
1.1. Define the control objectives and criteriaDefine the control objectives and criteria
What am I trying to control?What am I trying to control?
What do I have to do to control the system?What do I have to do to control the system?
What kind of response do I need?What kind of response do I need?
What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?What are the possible (probable) system failure modes?
2.2. Determine the input and output relationshipsDetermine the input and output relationships
Choose a minimum number of variables for input to theChoose a minimum number of variables for input to the
FL engineFL engine
3.3. Use the ruleUse the rule--based structure of FLbased structure of FL
Break the control problem down into a series of rulesBreak the control problem down into a series of rules
4.4. Create FL membership functionsCreate FL membership functions
Define the meaning (values) of Input / Output terms usedDefine the meaning (values) of Input / Output terms used
in the rulesin the rules
5.5. Test, evaluate, tune and retestTest, evaluate, tune and retest
9/12/2013 Mahesh J. vadhavaniya 21
23. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
Loading dock (Loading dock ( XXff ,, YYff ))
RearRear
( X( X , Y, Y ))
9/12/2013 Mahesh J. vadhavaniya 22
FrontFront
ɸɸ
ϴϴ
Diagram of Truck and Loading zoneDiagram of Truck and Loading zone
24. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
TheThe goalgoal isis toto makemake thethe trucktruck arrivearrive atat thethe loadingloading dockdock
atat aa rightright angleangle ((ɸɸff==9090)) andand toto alignalign thethe positionposition (x,(x, y)y) ofof
thethe trucktruck withwith thethe desireddesired loadingloading dockdock (( XXff ,, YYff ))..
TheThe trucktruck movesmoves backwardbackward byby somesome fixedfixed distancedistance atat
Goal ?
9/12/2013 Mahesh J. vadhavaniya 23
TheThe trucktruck movesmoves backwardbackward byby somesome fixedfixed distancedistance atat
everyevery stagestage..
TheThe loadingloading zonezone correspondscorresponds toto planeplane [[00,,100100]] XX
[[100100,,00]] andand (( XfXf ,, YfYf )) equaledequaled ((5050,,100100))
AtAt everyevery stagestage thethe FuzzyFuzzy controllercontroller shouldshould produceproduce thethe
steeringsteering angleangle ϴϴ thatthat backsbacks upup thethe trucktruck toto thethe loadingloading
dockdock fromfrom anyany initialinitial positionposition andand fromfrom anyany angleangle inin thethe
loadingloading zonezone..
25. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
TheThe threethree statestate variablesvariables ɸɸ,, xx andand yy exactlyexactly determinedetermine
thethe trucktruck positionposition..
TheThe coordinatecoordinate pairpair (x,(x, y)y) specifiesspecifies thethe positionposition ofof thethe
rearrear centercenter ofof thethe trucktruck inin thethe planeplane..
ɸɸ specifiesspecifies thethe angleangle ofof thethe trucktruck withwith thethe horizontalhorizontal..
9/12/2013 Mahesh J. vadhavaniya 24
rearrear centercenter ofof thethe trucktruck inin thethe planeplane..
First specify controller’s input and output variables.
TheThe inputinput variablesvariables areare thethe trucktruck angleangle ɸɸ andand xx ––
positionposition coordinatecoordinate xx..
TheThe outputoutput isis steeringsteering angleangle signalsignal ϴϴ..
WeWe assumeassume enoughenough clearanceclearance betweenbetween thethe trucktruck andand thethe loadingloading dockdock soso
wewe cancan ignoreignore thethe yy –– positionposition coordinatecoordinate..
26. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
PositivePositive valuesvalues ofof ϴϴ representsrepresents clockwiseclockwise rotationsrotations..
Next specify Fuzzy set values of input and output
variables.
ɸɸ specifiesspecifies thethe angleangle ofof thethe trucktruck withwith thethe horizontalhorizontal..
NegativeNegative valuesvalues ofof ϴϴ representsrepresents countercounter clockwiseclockwise
rotationsrotations..
9/12/2013 Mahesh J. vadhavaniya 25
AngleAngleAngleAngleAngleAngleAngleAngle ɸɸ
RB Right Below
RU Right Upper
RV Right Vertical
VE Vertical
LV Left Vertical
LU Left Upper
LB Left Below
XXXXXXXX--------position xposition xposition xposition xposition xposition xposition xposition x
LE Left
LC Left Center
CE Center
RC Right Center
RI Right
Steering AngleSteering AngleSteering AngleSteering AngleSteering AngleSteering AngleSteering AngleSteering Angle ϴϴϴϴϴϴϴϴ
NB Negative Big
NM Negative Medium
NS Negative Small
ZE Zero
PS Positive Small
PM Positive Medium
PB Positive Big
27. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
Next specify Fuzzy Membership Functions.
9/12/2013 Mahesh J. vadhavaniya 26
0 ≤ x ≤ 1000 ≤ x ≤ 100
28. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
Next specify Fuzzy Membership Functions.
9/12/2013 Mahesh J. vadhavaniya 27
--90 ≤90 ≤ ɸɸ ≤ 270≤ 270
29. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
Next specify Fuzzy Membership Functions.
9/12/2013 Mahesh J. vadhavaniya 28
--30 ≤30 ≤ ϴϴ ≤ 30≤ 30
30. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
Next specify Fuzzy “rulebase” or bank of FAM rules.
xxxx
LE LC CE RC RI
RB PS PM PM PB PB
9/12/2013 Mahesh J. vadhavaniya 29
ɸɸɸɸɸɸɸɸ
RB PS PM PM PB PB
RU NS PS PM PB PB
RV NM NS PS PM PB
VE NM NM ZE PM PM
LV NB NM NS PS PM
LU NB NB NM NS PS
LB NB NB NM NM NS
31. Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…Backing up a Truck…
Next Defuzzification.
9/12/2013 Mahesh J. vadhavaniya 30
CorrelationCorrelation –– minimum inference withminimum inference with centroidcentroid
defuzzificationdefuzzification methodmethod
32. Summary …Summary …Summary …Summary …Summary …Summary …Summary …Summary …
1.1. TheThe plantplant isis observableobservable andand controllablecontrollable :: state,state, inputinput
andand outputoutput variablesvariables areare usuallyusually availableavailable forfor
observationobservation andand measurementmeasurement oror computationcomputation..
Assumptions in a Fuzzy control system design :
2.2. ThereThere existsexists aa bodybody ofof knowledgeknowledge comprisedcomprised ofof aa setset ofof
9/12/2013 Mahesh J. vadhavaniya 31
2.2. ThereThere existsexists aa bodybody ofof knowledgeknowledge comprisedcomprised ofof aa setset ofof
linguisticlinguistic rules,rules, engineeringengineering commoncommon sense,sense, intuition,intuition, oror aa
setset ofof inputinput –– outputoutput measurementsmeasurements datadata fromfrom whichwhich rulesrules
cancan bebe extractedextracted..
3.3. AA solutionsolution existsexists..
4.4. AA controlcontrol engineerengineer isis lookinglooking forfor aa “good“good enough”enough”
solution,solution, notnot necessarilynecessarily thethe optimumoptimum oneone..