Clear Filters
Clear Filters

grey and fuzzy TOPSIS

8 views (last 30 days)
Ali Naeemah
Ali Naeemah on 18 Oct 2021
Edited: Balavignesh on 24 May 2024
Hello ladies and gentlemen,
Please Kindly, can someone help me find a MATLAB code to solve the grey-TOPSIS method and the fuzzy-TOPSIS method?
Thank you so much

Answers (1)

Balavignesh
Balavignesh on 24 May 2024
Edited: Balavignesh on 24 May 2024
Hi Ali,
The Technique for Order Preference by Similarity to Ideal Solution (TOPSIS) is a method used in multi-criteria decision making (MCDM). Grey-TOPSIS integrates the Grey System Theory with TOPSIS to deal with incomplete or uncertain information, where as Fuzzy-TOPSIS uses fuzzy numbers to represent decision matrix and weights, which allows to handle vagueness and subjectivity in the evaluation process.
Here is a rough implementation of the above mentioned concepts :
% Example Grey-TOPSIS Implementation in MATLAB
% This is a simplified example. Adapt it based on your specific criteria and alternatives.
% Define the decision matrix (alternatives x criteria)
% Assuming 3 alternatives and 4 criteria
D = [0.6 0.5 0.7 0.8; 0.9 0.7 0.6 0.5; 0.7 0.8 0.5 0.6];
% Define the weight for each criterion
W = [0.25 0.25 0.25 0.25]; % Equal weights for simplicity
% Normalize the decision matrix
row_sums = sqrt(sum(D.^2, 1));
N = D ./ row_sums;
% Calculate the weighted normalized decision matrix
V = N .* W;
% Determine the positive ideal (A+) and negative ideal (A-) solutions
A_plus = max(V, [], 1);
A_minus = min(V, [], 1);
% Calculate the distance to the positive ideal solution
D_plus = sqrt(sum((V - A_plus).^2, 2));
% Calculate the distance to the negative ideal solution
D_minus = sqrt(sum((V - A_minus).^2, 2));
% Calculate the similarity to the ideal solution
S = D_minus ./ (D_plus + D_minus);
% Rank the alternatives based on the similarity score
[~, rankIndex] = sort(S, 'descend');
% Display the ranking of alternatives
disp('Ranking of Alternatives:');
Ranking of Alternatives:
disp(rankIndex);
2 1 3
% Example Fuzzy-TOPSIS Implementation in MATLAB
% This is a simplified example. You'll need to adapt it to your specific fuzzy numbers and context.
% Define the fuzzy decision matrix (alternatives x criteria)
% For simplicity, using direct numbers, but in practice, these should be fuzzy numbers
D = [0.6 0.5 0.7 0.8; 0.9 0.7 0.6 0.5; 0.7 0.8 0.5 0.6];
% Define the fuzzy weights for each criterion
W = [0.25 0.25 0.25 0.25]; % Equal weights for simplicity, should be fuzzy numbers
% Normalize the fuzzy decision matrix
% Note: The normalization process might be different based on the fuzzy number operations
row_sums = sqrt(sum(D.^2, 1));
N = D ./ row_sums;
% Calculate the fuzzy weighted normalized decision matrix
V = N .* W;
% Determine the fuzzy positive ideal (A+) and fuzzy negative ideal (A-) solutions
A_plus = max(V, [], 1);
A_minus = min(V, [], 1);
% Calculate the distance to the fuzzy positive ideal solution
D_plus = sqrt(sum((V - A_plus).^2, 2));
% Calculate the distance to the fuzzy negative ideal solution
D_minus = sqrt(sum((V - A_minus).^2, 2));
% Calculate the similarity to the ideal solution
S = D_minus ./ (D_plus + D_minus);
% Rank the alternatives based on the similarity score
[~, rankIndex] = sort(S, 'descend');
% Display the ranking of alternatives
disp('Ranking of Alternatives:');
Ranking of Alternatives:
disp(rankIndex);
2 1 3
Kindly note that these examples are simplified and intended to provide a basic structure. For both Grey-TOPSIS and Fuzzy-TOPSIS, the handling of grey numbers and fuzzy numbers, respectively, needs more detailed implementation based on your specific criteria, alternatives, and the nature of uncertainty or fuzziness in your decision-making context.
Kindly have a look at the following documentation links to have more information on:
Hope that helps!
Balavignesh

Categories

Find more on Fuzzy Logic Toolbox in Help Center and File Exchange

Products

Community Treasure Hunt

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

Start Hunting!