here is the code snippet
addMF(input_temperature, 'trimf', [0 0 50], 'cold');
addMF(input_temperature, 'trimf', [0 50 100], 'medium');
addMF(input_temperature, 'trimf', [50 100 100], 'hot');
addMF(input_humidity, 'trimf', [0 0 50], 'low');
addMF(input_humidity, 'trimf', [0 50 100], 'medium');
addMF(input_humidity, 'trimf', [50 100 100], 'high');

 채택된 답변

Sam Chak
Sam Chak 2023년 10월 13일

0 개 추천

Some syntax issues. They are fixed as shown below:
fis = mamfis;
fis = addInput(fis, [0 100], "Name", "input_temperature");
fis = addInput(fis, [0 100], "Name", "input_humidity");
fis = addMF(fis, "input_temperature", 'trimf', [0 0 50], "Name", 'cold');
fis = addMF(fis, "input_temperature", 'trimf', [0 50 100], "Name", 'medium');
fis = addMF(fis, "input_temperature", 'trimf', [50 100 100], "Name", 'hot');
fis = addMF(fis, "input_humidity", 'trimf', [0 0 50], "Name", 'low');
fis = addMF(fis, "input_humidity", 'trimf', [0 50 100], "Name", 'medium');
fis = addMF(fis, "input_humidity", 'trimf', [50 100 100], "Name", 'high');
subplot(211)
plotmf(fis, "input", 1)
subplot(212)
plotmf(fis, "input", 2)

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Fuzzy Inference System Modeling에 대해 자세히 알아보기

제품

릴리스

R2023b

질문:

2023년 10월 13일

댓글:

2023년 10월 13일

Community Treasure Hunt

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

Start Hunting!

Translated by