模糊综合评价法中的矩阵合成运算,要求相乘取小,相加取大
来源:学生作业帮 编辑:神马作文网作业帮 分类:综合作业 时间:2024/11/12 12:15:36
模糊综合评价法中的矩阵合成运算,要求相乘取小,相加取大
举个例子你就明白了,并可用matlab编程计算
matlab计算代码如下:先建立函数文件
function ab=synt(a,b);
m=size(a,1);
n=size(b,2);
for i=1:m
for j=1:n
ab(i,j)=max(min([a(i,:);b(:,j)']));
end
end
再键入
a=[0.4,0.5,0.6;0.1,0.2,0.3],b=[0.1,0.2;0.3,0.4;0.5,0.6]
ab=synt(a,b),ba=synt(b,a)
计算得
a =
0.4000 0.5000 0.6000
0.1000 0.2000 0.3000
b =
0.1000 0.2000
0.3000 0.4000
0.5000 0.6000
ab =
0.5000 0.6000
0.3000 0.3000
ba =
0.1000 0.2000 0.2000
0.3000 0.3000 0.3000
0.4000 0.5000 0.5000
matlab计算代码如下:先建立函数文件
function ab=synt(a,b);
m=size(a,1);
n=size(b,2);
for i=1:m
for j=1:n
ab(i,j)=max(min([a(i,:);b(:,j)']));
end
end
再键入
a=[0.4,0.5,0.6;0.1,0.2,0.3],b=[0.1,0.2;0.3,0.4;0.5,0.6]
ab=synt(a,b),ba=synt(b,a)
计算得
a =
0.4000 0.5000 0.6000
0.1000 0.2000 0.3000
b =
0.1000 0.2000
0.3000 0.4000
0.5000 0.6000
ab =
0.5000 0.6000
0.3000 0.3000
ba =
0.1000 0.2000 0.2000
0.3000 0.3000 0.3000
0.4000 0.5000 0.5000