Hi @Juan Lopez
Specifying the number of data points (numPoints) in the 'plofmf' command to plot for each MF will solve the problem.
%% Parameters
num_MF_input = 7;
LB = -8;
Base_input = 4;
numPoints = 201;
%% Create a Mamdani FIS object named "Fuzzy_Lopez"
fis = mamfis("Name", "Fuzzy_Lopez");
%% Add an Input variable named "Name_1D_in"
fis = addInput(fis, [LB -LB], "Name", "Name_1D_in");
%% Automate the creation the fuzzy sets
for j=1:num_MF_input
a = LB + (Base_input*j/2 - Base_input/2);
fis = addMF(fis, "Name_1D_in", "trimf", [a a+Base_input/2 a+Base_input]);
end
%% Plot input fuzzy sets
plotmf(fis, 'input', 1, numPoints), grid on, grid minor