home › Forums › # Technical Support › Mamdani Output
- This topic has 1 reply, 2 voices, and was last updated 9 years, 3 months ago by
Juan Rada-Vilela (admin).
-
AuthorPosts
-
June 11, 2014 at 21:37 #1100
Unknown
MemberHi,
I’m having some problem to figure out how the output of a really simple example is computed.Below I have attached the output of my model.
While I’m completely ok with the two “Accumulating terms”:
– Accumulating term: UP Thresholded 0.600 Minimum term: UP
– Accumulating term: STY Thresholded 0.133 Minimum term: STYI cannot figure out why these terms becames 0.541 (instead of 0.6) and 0.094 (instead of 0.133):
DeltaC.fuzzy = 0.000/BDW + 0.000/DWN + 0.094/STY + 0.541/UP + 0.000/BUP
Of course I am missing something in the fuzzy theory, and for this I just need link to know more about these values. Otherwise, it could be a bug but I do not think so !
The engine is set as:
– conj: Min
– disj: Max
– activation: Min
– accumulation: MaxThanks,
Massimo
(below the fuzzylite output)Engine type: Mamdani /src/Engine.cpp::process[205]:=============== /src/Engine.cpp::process[206]:CURRENT INPUTS: /src/Engine.cpp::process[212]:Cres.input = 0.120 /src/Engine.cpp::process[213]:Cres.fuzzy = 0.600/LOW + 0.133/FINE + 0.000/HIGH /src/Engine.cpp::process[212]:Rgain.input = 0.200 /src/Engine.cpp::process[213]:Rgain.fuzzy = 0.000/LOW + 1.000/FINE + 0.000/HIGH /src/rule/RuleBlock.cpp::activate[47]:=================== /src/rule/RuleBlock.cpp::activate[48]:ACTIVATING RULEBLOCK /src/rule/RuleBlock.cpp::activate[51]:if Cres is LOW and Rgain is LOW then DeltaC is BUP [activationDegree=0] /src/rule/RuleBlock.cpp::activate[51]:if Cres is LOW and Rgain is FINE then DeltaC is UP [activationDegree=0.6] /src/rule/Consequent.cpp::modify[74]:Accumulating term: UP Thresholded 0.600 Minimum term: UP Triangle 0.050 0.125 0.200 /src/rule/RuleBlock.cpp::activate[51]:if Cres is LOW and Rgain is HIGH then DeltaC is UP [activationDegree=0] /src/rule/RuleBlock.cpp::activate[51]:if Cres is FINE and Rgain is LOW then DeltaC is UP [activationDegree=0] /src/rule/RuleBlock.cpp::activate[51]:if Cres is FINE and Rgain is FINE then DeltaC is STY [activationDegree=0.133333] /src/rule/Consequent.cpp::modify[74]:Accumulating term: STY Thresholded 0.133 Minimum term: STY Triangle -0.100 0.000 0.100 /src/rule/RuleBlock.cpp::activate[51]:if Cres is FINE and Rgain is HIGH then DeltaC is DWN [activationDegree=0] /src/rule/RuleBlock.cpp::activate[51]:if Cres is HIGH and Rgain is LOW then DeltaC is STY [activationDegree=0] /src/rule/RuleBlock.cpp::activate[51]:if Cres is HIGH and Rgain is FINE then DeltaC is DWN [activationDegree=0] /src/rule/RuleBlock.cpp::activate[51]:if Cres is HIGH and Rgain is HIGH then DeltaC is BDW [activationDegree=0] /src/Engine.cpp::process[229]:=============== /src/Engine.cpp::process[230]:CURRENT OUTPUTS: /src/Engine.cpp::process[235]:DeltaC.default = nan /src/Engine.cpp::process[238]:DeltaC.lockRange = 0 /src/Engine.cpp::process[241]:DeltaC.lockValid = 0 /src/Engine.cpp::process[246]:DeltaC.output = 0.0905711 /src/Engine.cpp::process[248]:DeltaC.fuzzy = 0.000/BDW + 0.000/DWN + 0.094/STY + 0.541/UP + 0.000/BUP /src/Engine.cpp::process[249]:term: fuzzyOutput Accumulated -1.000 1.000 Maximum term: UP Thresholded 0.600 Minimum term: UP Triangle 0.050 0.125 0.200 term: STY Thresholded 0.133 Minimum term: STY Triangle -0.100 0.000 0.100 /src/Engine.cpp::process[254]:==============
June 11, 2014 at 22:40 #1101Juan Rada-Vilela (admin)
KeymasterHi Massimo,
thank you for your post and for noticing that tricky bit.
The fuzzy output is indeed what you expect, but what you see is not a bug. The “fuzzy output” shown in QtFuzzyLite v4.0 refers to the membership value of the defuzzified value over the terms in the variable, that is, you are seeing the fuzzified output value (\mu(y)). I have addressed this bit in QtFuzzyLite v5.0 by showing both the fuzzy output value that you refer to (\tilde{y}), and the fuzzified output value (\mu(y)). QtFuzzyLite v5.0 will be released early July, 2014, and it will be truly amazing. Stay tuned!
I have mentioned this bit in the forum of known issues:
Fuzzy Output Text in qtfuzzylite
Let me know if that answers your question.
Cheers,
Juan
-
This reply was modified 9 years, 3 months ago by
Juan Rada-Vilela (admin).
-
This reply was modified 9 years, 3 months ago by
Juan Rada-Vilela (admin).
-
This reply was modified 9 years, 3 months ago by
-
AuthorPosts
- You must be logged in to reply to this topic.