fuz_mul.m

来自「FISMAT accommodates different arithmetic」· M 代码 · 共 46 行

M
46
字号
function f = fuz_mul(f1,f2)% f=fuz_mul(f1,f2)%% Multiplication of two fuzzy intervalls (numbers) in LR-representation.% (approximation - Dubois and Prade).% The formula is as more precise as "sharper" the numbers are.% Both numbers can have the same or different sign.% f=f1=f2 = [xmin xmax m n alpha beta]% Condition ymin=0 and ymax=1 .%% f = [xmin, xmax, m1*m2, n1*n2, m1*alpha2+m2*alpha1-alpha1*alpha2,%      n1*beta2+n2*beta1+beta1*beta2 ] % % for f1=f2=positive. (for different signs, first signreversal)%% FSTB - Fuzzy Systems Toolbox for MATLAB% Copyright (c) 1993-1996 by Olaf Wolkenhauer% Control Systems Centre at UMIST% Manchester M60 1QD, UK%% 8-Feb-1994if (fuz_sign(f1) | fuz_sign(f2)) == 3;  error('Error: one (LR-) intervall (number) zero. fuz_mul impossible !');end;if fuz_sign(f1) == 1;          % if f1 positive  if fuz_sign(f2) == 1;        % and  f2 positive    f=fuz_mul1(f1,f2);         % f  = f1 * f2  else                         % if f1 positive and f2 negative    f2=fuz_sire(f2);           % f2 = -f2    f =fuz_mul1(f1,f2);        % f  = f1 * -f2    f =fuz_sire(f);            % f  = -f  end;else                           % if f1 negative  if fuz_sign(f2) == 1;        % and  f2 positive    f1=fuz_sire(f1);           % f1 = -f1    f =fuz_mul1(f1,f2);        % f  = -f1 * f2    f =fuz_sire(f);            % f  = -f  else                         % if f1 and f2 negative    f1=fuz_sire(f1);           % f1 = -f1    f2=fuz_sire(f2);           % f2 = -f2    f =fuz_mul1(f1,f2);        % f  = -f1 * -f2  end;end;

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?