Mathematical Modeling: Evaluative Model Learning - Analytic Hierarchy Process (AHP Model)


foreword

I have simply used the AHP in coursework before, and this time I will study it again systematically and write a study note!


1. Process introduction

  1. build hierarchy
  2. Build a judgment matrix
  3. Calculating weights, consistency checks
  4. Calculate the score to draw conclusions

2. Model realization

1. Build a Hierarchy

Explore the ranking of urban tourism competitiveness of the following five cities: Chengdu, Hangzhou, Changsha.

Select the six indicators of the criterion layer to establish the following hierarchical structure:

 

 

2. Build a judgment matrix

        For the pairwise comparison of the importance of elements of the same level with respect to a certain criterion in the previous level, construct a pairwise comparison matrix (judgment matrix)

1. Empower the indicators

        When determining the weight of each factor at each level, the consistent matrix method proposed by TLSaaty et al.
The two-to-two comparison between the various influencing factors minimizes the difficulty of comparing the factors with different natures, so as to improve the
Accuracy.
The following table shows the 9 importance levels and their assignments given by TLSaaty:
factor i than factor j quantized value
Equally important 1
slightly important 3
stronger important 5
strongly important 7
extremely important 9
Adjacent judgment intermediate value 2、4、6、8

2. Establish a judgment matrix

Each factor in the matrix needs to be manually filled in according to experience:

index
A1
A2
A3
A4
A5
A6
A1
1 1/2 1/3 1/5 3 5
A2
2 1 1/2 1/4 4 4
A3
3 2 1 1/3 4 5
         A4 5 4 3 1 5 6
A5
1/3 1/4 1/4 1/5 1 3
A6
1/5 1/4 1/5 1/6 1/3 1

3. Hierarchical single sorting and consistency check

1. Standard layer

In simple terms, hierarchical single sorting is to calculate the weight of each index of the judgment matrix;

Define the consistency index as CI = λ-n/n-1, where λ is the largest eigenvalue of the judgment matrix, and n is the order of the judgment matrix. The closer the CI is to 0, the higher the degree of agreement.
To measure CI, the random consistency index RI is introduced, and the average value of the random consistency index RI is as follows:

 

Considering that the consistency deviation may be caused by random reasons, when testing whether the judgment matrix has satisfactory consistency, it is necessary to compare CI with RI, and obtain CR=CI/RI. Generally, if CR<0.1, the judgment matrix is ​​considered to pass the consistency test:
%matlab代码

A = [1,1/2,1/3,1/5,3,5;
    2,1,1/2,1/4,4,4;
    3,2,1,1/3,4,5;
    5,4,3,1,5,6;
    1/3,1/4,1/4,1/5,1,3;
    1/5,1/4,1/5,1/6,1/3,1;];

[x,y] = eig(A); eigenvalue = diag(y); 
Lmax = max(eigenvalue); %计算最大特征值 

n = size(A,1); %计算判断矩阵阶数
w = x(:,1)/sum(x(:,1)); %计算归一化权向量 

CI = (Lmax-n)/(n-1); 
RI = [0 0 0.58 0.90 1.12 1.24 1.32 1.41 1.45 1.49 1.51]; 
CR = CI/RI(n); %计算 CR

The result is as follows:

CI

0.0839

CR 0.0677
Lmax (maximum characteristic root) 6.4195
w (weight) [0.1089,0.1503,0.2188,0.4269,0.0593,0.0358]

CI=0.0839<0.1, indicating that the judgment matrix passed the consistency test.

2. Program layer

Establish a judgment matrix A1 for the factor of the number of tourists:

number of tourists Chengdu hangzhou Changsha
Chengdu 1 3 5
hangzhou 1/3 1 3
Changsha 1/5 1/3 1

In this way, six judgment matrices are established and the weights are calculated and the consistency test is performed:

All of the above have passed the consistency test, and the original data will be given later.

 4. Calculate the score

Multiply the weight matrix of the criterion layer and the weight matrix of the scheme layer to obtain the final scores of the three cities and perform normalization

\begin{pmatrix} 0.6370,0.5816,0.5396,0.3196,0.3196,0.5396\\ 0.2583,0.03090,0.2970,0.5584,0.5584,0.2970\\ 0.1047,0.1095,0.1634,0.1220,0.1220,0.1634 \end{pmatrix}*\begin{pmatrix} 0.1089\\ 0.1503\\0.2188 \\ 0.4269\\0.0593\\0.0358 \end{pmatrix}

The result is: \begin{pmatrix} 0.4496\\ 0.3799\\ 0.1288 \end{pmatrix}      that is, the final rankings are Chengdu, Hangzhou, and Changsha.

3. Method Analysis

advantage:

  • Systematic: Analytic Hierarchy Process takes the research object as a system, and makes decisions according to the way of thinking of decomposition, comparison and judgment, and synthesis
  • Simplicity: This method neither purely pursues advanced mathematics, nor pays one-sided attention to behavior, logic, and reasoning, but organically combines qualitative and quantitative methods
  • Extensive: Analytic Hierarchy Process mainly starts from the evaluator's understanding of the nature and elements of the evaluation problem, and emphasizes qualitative analysis and judgment more than general quantitative methods

shortcoming:

  • Confined to the old: only one can be selected from the original plan, and there is no way to come up with a better new plan
  • Subjectivity: the selection of indicators, the construction of judgment matrix and other links need to be led by humans, which lacks popularity
  • Ambiguity: pay attention to qualitative, do not require high data volume, lack of quantitative methods, it is difficult to solve the problem of large data volume

Summarize

This time I used an example I used before for improvement. I hope you can correct me if there are mistakes.

In order to simplify the whole process, only three cities and six indicators were selected. If you want the original data, you can private message or comment

Also ask for a like! !

Guess you like

Origin blog.csdn.net/weixin_67565775/article/details/126567801