Matlab Fuzzy Logic Toolbox - OR statement in one input

1 次查看(过去 30 天)
Dear,
I have one question about rules in Matlab Fuzzy Toolbox. Is it possible to add OR statement in one input between Membership function in one rule?
Example:
[Input1]
Name='Age'
Range=[18 100]
NumMFs=3
MF1='young':'trapmf',[0 1 23 37]
MF2='middle_aged':'trapmf',[23 37 53 67]
MF3='old':'trapmf',[53 67 100 100]
[Output1]
Name='Primary_Headches_Types'
Range=[0 10]
NumMFs=3
MF1='Migraine':'trimf',[0 2 4]
MF2='TTH':'trimf',[2 4 6]
MF3='TACs':'trimf',[5 7 9]
[Rules]
1. If (Age is young or old) then (Primary_Headches_Types is Migraine) (1)
Or something like this:
[Rules]
1. If (Age is young) or (Age is old) then (Primary_Headches_Types is Migraine) (1)
P.S. This is just simple example, my issue is very complexed. I use Mamadani system.
How can I do something like this to scale the number of rules because I will have over 1200 of them.
Thanks so much for the answer in advance and have a nice weekend!
Best Regards,
Marko Štalmatović

回答(1 个)

Mohith Kulkarni
Mohith Kulkarni 2020-11-25
The addrule function is supporting only one membership function for each input. Even if you add the rule with OR connectiion between membership function of the same input, the rule is being created with the antecedent property having only one of the specified membership function for the input.
As a workaround, two different rules, one for each membership function can be added in such cases.
I have brought this issue to the notice of our developers. They will investigate the matter further.
  1 个评论
Marko Stalmatovic
Marko Stalmatovic 2020-11-29
编辑:Marko Stalmatovic 2020-11-29
Dear,
Thanks for the answer.
I understand and hope that two MF can be added in same input in the near future.
Best Regards,
Marko Štalmatović

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Fuzzy Logic in Simulink 的更多信息

产品


版本

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by