H
Hicham AMAR
Guest
GIS based combination of AHP as Multi‐criteria Analysis with DRASTIC model is applied in many studies to assess the groundwater vulnerability (Neshat and Pradhan, 2015; Pourghasemi et al., 2012). The DRASTIC model is the popular model with subjective rating from 1 to 10 and weight from 1 to 5 (Alemi-Ardakani et al., 2016; Gogu et al., 2003; Hamza et al., 2015; Mogaji et al., 2014; Sahoo et al., 2016).
AHP was proposed by Saaty and Decision (1990) to solve many complicated decision making problems. It allows to obtain a priority scale derived from a set of alternatives. The construction of pairwise comparison matrices by expert judgments is the most component of the AHP method. This method allows to calculate the weight based on the priority scale of the used parameters. These weights were used to determine the consistency index CI. The ration of consistency index is calculated by dividing consistency index by random index. The CR must be inferior to 0.1 to preserve the pairwise comparison matrices. If the CR is superior to 0.1, the model will be neglected.
In this article, the AHP will be applied to assess the aquifer vulnerability using the DRASTIC model. The parameters used in this application are RASTIC.
To do this, the step to follow are :
The important libraries called for this application are FuzzyAHP for weight calculation, raster for file import, and raster to manage raster files.
############################ AHP et aquifer vulnerability ###############
#######################Devlp ./ Hicham AMAR#############################
#########################Date : 30-01-2022##########################
library("FuzzyAHP")
library('sp')
library('raster')
library('rgdal')
library('ggplot2')
library('RasterLayer')
library(ggplot2)
library(rgdal)
library(rgeos)
library(sf)
library(tidyverse)
library(classInt)
library(viridis)
library(readxl)
library(cowplot) # for plot_grid function
The raster function is used to import the RASTIC parameters.
#################Loading of the Tif files ################3
# set working directory to data folder
setwd("E:/Blog_Geoinfo4all/012022/Article-DRASTIC/Data-Geoinfo4all")
# load raster in an R object called 'DEM'
DEM_R <- raster("RW.tif")
DEM_A <- raster("A.tif")
DEM_S <- raster("S.tif")
DEM_T <- raster("T.tif")
DEM_I <- raster("I.tif")
DEM_C <- raster("C.tif")
The raster files are stored in list to map them.
############Mapping of the six parameters ############
Maps <- list(DEM_R,DEM_A,DEM_S,DEM_T,DEM_I,DEM_C)
names_mps <- c("Net Recharge","Aquifer media","Soil media","Topography","Impact of vadose zone","Conductivity")
#Mapping of the GVI and RASTIC parameters
print(" RASTIC maps ")
#dev.new()
par(mfrow=c(2,3))
for ( x in 1:6 )
{
eq <- names_mps[x]
plot( Maps[[x]] , main= eq, xlab= paste("min-mean-max",cellStats(Maps[[x]], min) ,
"-",round(cellStats(Maps[[x]], mean),0),
"-",cellStats(Maps[[x]], max)) )
}
The six RASTIC parameters
The comparison Matrix with 6 dimensions was elaborated according to the priority scale from 9 to 1/9. The note is assessed by comparing two parameters to define the priority. The first line and column are for R parameter, the second line and column are for A parameters, … Six weights are calculated in the end of the code bellow. The CI and CR are also calculated to evaluate the priority scales in comparison Matrix.
comparison Matrix elaborated for the six parameters
##########################AHP Method #############################################
#AHP for matrix with 6 dimensions
comparisonMatrixValues = c(1,1,3,4,1/2,2,
NA,1,2,3,1/2,1,
NA,NA,1,2,1/3,1/2,
NA,NA,NA,1,1/5,1/3,
NA,NA,NA,NA,1,2,
NA,NA,NA,NA,NA,1)
#define the ncol and n row of your matrix
comparisonMatrix0 = matrix(comparisonMatrixValues, nrow = 6, ncol = 6, byrow = TRUE)
show(comparisonMatrix0)
#Calculate the pairwiseComparisonMatrix
comparisonMatrix1 = pairwiseComparisonMatrix(comparisonMatrix0)
show(comparisonMatrix1)
#Calculate the performance indices CR and CI
consistencyRatio(comparisonMatrix1)
consistencyIndex(comparisonMatrix1)
#weights Calulation
weights = calculateWeights(comparisonMatrix1)
print(weights)
typeof(weights) # S4 class must be converted to vector class
Consistency ratio is: 0.0123421503399513. The pairwise comparison matrix is consistent for calculations. [1] 0.01234215 consistencyIndex(comparisonMatrix1) [1] 0.01542769 w_C_1 w_C_2 w_C_3 w_C_4 w_C_5 w_C_6 0.2162 0.1716 0.0883 0.0536 0.3174 0.1529
The AHP model ameliorates the Wi of the R, S, T, A, and C parameters.
AHP was proposed by Saaty and Decision (1990) to solve many complicated decision making problems. It allows to obtain a priority scale derived from a set of alternatives. The construction of pairwise comparison matrices by expert judgments is the most component of the AHP method. This method allows to calculate the weight based on the priority scale of the used parameters. These weights were used to determine the consistency index CI. The ration of consistency index is calculated by dividing consistency index by random index. The CR must be inferior to 0.1 to preserve the pairwise comparison matrices. If the CR is superior to 0.1, the model will be neglected.
In this article, the AHP will be applied to assess the aquifer vulnerability using the DRASTIC model. The parameters used in this application are RASTIC.
To do this, the step to follow are :
- Libraries loading
The important libraries called for this application are FuzzyAHP for weight calculation, raster for file import, and raster to manage raster files.
############################ AHP et aquifer vulnerability ###############
#######################Devlp ./ Hicham AMAR#############################
#########################Date : 30-01-2022##########################
library("FuzzyAHP")
library('sp')
library('raster')
library('rgdal')
library('ggplot2')
library('RasterLayer')
library(ggplot2)
library(rgdal)
library(rgeos)
library(sf)
library(tidyverse)
library(classInt)
library(viridis)
library(readxl)
library(cowplot) # for plot_grid function
- Import raster files
The raster function is used to import the RASTIC parameters.
#################Loading of the Tif files ################3
# set working directory to data folder
setwd("E:/Blog_Geoinfo4all/012022/Article-DRASTIC/Data-Geoinfo4all")
# load raster in an R object called 'DEM'
DEM_R <- raster("RW.tif")
DEM_A <- raster("A.tif")
DEM_S <- raster("S.tif")
DEM_T <- raster("T.tif")
DEM_I <- raster("I.tif")
DEM_C <- raster("C.tif")
- Mapping of the parameters used RASTIC
The raster files are stored in list to map them.
############Mapping of the six parameters ############
Maps <- list(DEM_R,DEM_A,DEM_S,DEM_T,DEM_I,DEM_C)
names_mps <- c("Net Recharge","Aquifer media","Soil media","Topography","Impact of vadose zone","Conductivity")
#Mapping of the GVI and RASTIC parameters
print(" RASTIC maps ")
#dev.new()
par(mfrow=c(2,3))
for ( x in 1:6 )
{
eq <- names_mps[x]
plot( Maps[[x]] , main= eq, xlab= paste("min-mean-max",cellStats(Maps[[x]], min) ,
"-",round(cellStats(Maps[[x]], mean),0),
"-",cellStats(Maps[[x]], max)) )
}
The six RASTIC parameters
- Application of AHP method
The comparison Matrix with 6 dimensions was elaborated according to the priority scale from 9 to 1/9. The note is assessed by comparing two parameters to define the priority. The first line and column are for R parameter, the second line and column are for A parameters, … Six weights are calculated in the end of the code bellow. The CI and CR are also calculated to evaluate the priority scales in comparison Matrix.
R | A | S | T | I | C | |
R | 1 | 1 | 3 | 4 | 1/2 | 2 |
A | 1 | 2 | 3 | 1/2 | 1 | |
S | 1 | 2 | 1/3 | 1/2 | ||
T | 1 | 1/5 | 1/3 | |||
I | 1 | 2 | ||||
C | 1 |
##########################AHP Method #############################################
#AHP for matrix with 6 dimensions
comparisonMatrixValues = c(1,1,3,4,1/2,2,
NA,1,2,3,1/2,1,
NA,NA,1,2,1/3,1/2,
NA,NA,NA,1,1/5,1/3,
NA,NA,NA,NA,1,2,
NA,NA,NA,NA,NA,1)
#define the ncol and n row of your matrix
comparisonMatrix0 = matrix(comparisonMatrixValues, nrow = 6, ncol = 6, byrow = TRUE)
show(comparisonMatrix0)
#Calculate the pairwiseComparisonMatrix
comparisonMatrix1 = pairwiseComparisonMatrix(comparisonMatrix0)
show(comparisonMatrix1)
#Calculate the performance indices CR and CI
consistencyRatio(comparisonMatrix1)
consistencyIndex(comparisonMatrix1)
#weights Calulation
weights = calculateWeights(comparisonMatrix1)
print(weights)
typeof(weights) # S4 class must be converted to vector class
Consistency ratio is: 0.0123421503399513. The pairwise comparison matrix is consistent for calculations. [1] 0.01234215 consistencyIndex(comparisonMatrix1) [1] 0.01542769 w_C_1 w_C_2 w_C_3 w_C_4 w_C_5 w_C_6 0.2162 0.1716 0.0883 0.0536 0.3174 0.1529
The AHP model ameliorates the Wi of the R, S, T, A, and C parameters.
V AHP RASTIC | V AHP RASTIC | V RASTIC | V RASTIC |