matlab - Convert data to fuzzy data -


i beginner. have matrix in matlab , want convert matrix's number fuzzy number , use these fuzzy number function's input .how can this? correct convert number double number between 0,1 dividing numbers 1000 this? [256,12;3,56]--->[0.256,0.12;0.003,0.056]

but double number should do?

what mean fuzzy number?!! far know matlab uses normal numbers fuzzy system. after there fuzzifiers change real numbers points on membership functions. , fuzzy logic decides how number have selected, , on...! on other hand, if want change scale of number in range [-1 1] or [0 1] has nothing fuzzy.

and change range [0 1] [a b] use line of code:

r = + (b-a)*z; 

where z in range [0 1], , r in range [a b]

for example, changing z=0.5 [0 1] range [0 10], r becomes:

r = 0 + (10-0)*0.5 = 5 

to change [a b] [0 1] can this:

z = (r - a)/(b-a); 

so if r = 5 in range [0 10], z = 0.5 in range [0 1];

in addition, real fuzzy operation, try this:

point_n = 101;          % determines mf's resolution  min_x = -20; max_x = 20;    % universe [min_x, max_x]  x = linspace(min_x, max_x, point_n)';  = trapmf(x, [-10 -2 1 3]);    % trapezoidal fuzzy set b = gaussmf(x, [2 5]);      % gaussian fuzzy set b  c1 = fuzarith(x, a, b, 'sum');  subplot(2,1,1); plot(x, a, 'b--', x, b, 'm:', x, c1, 'c'); title('fuzzy addition a+b');  c2 = fuzarith(x, a, b, 'sub'); subplot(2,1,2); plot(x, a, 'b--', x, b, 'm:', x, c2, 'c'); title('fuzzy subtraction a-b');  c3 = fuzarith(x, a, b, 'prod'); 

that's how perform fuzzy arithmetic. according mathworks:

using interval arithmetic, c = fuzarith(x, a, b, operator) returns fuzzy set c result of applying function represented string, operator, performs binary operation on sampled convex fuzzy sets , b. elements of , b derived convex functions of sampled universe, x:

  1. a, b, , x vectors of same dimension.
  2. operator 1 of following strings: 'sum', 'sub', 'prod', , 'div'.
  3. the returned fuzzy set c column vector same length x.

and can perform fuzzy inference calculation using 'evalfis' function in matlab. inputs , outputs function real numbers well:

fismat = readfis('tipper'); out = evalfis([2 1; 4 9],fismat) 

this syntax generates response

out =     7.0169     19.6810  

Comments

Popular posts from this blog

javascript - JS causing window size to be bigger than necessary - Dropdown bug -

php - Calling a template part from a post -

How to mention the localhost in android -