2.1 直觉模糊加权几何算子
定义2.1
设
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)是一组直觉模糊数,若
IFWG
\operatorname{IFWG}
IFWG是一个映射:
F
n
→
F
F_{n} \rightarrow F
Fn→F,使得:
IFWG
ω
(
A
~
1
,
A
~
2
,
.
.
.
,
A
~
n
)
=
(
A
~
1
)
ω
1
⊕
(
A
~
2
)
ω
2
⊕
.
.
.
⊕
(
A
~
n
)
ω
n
(2.1)
\color{red} { {\operatorname{IFWG}_{\omega}}\left( \tilde{A}_{1},\tilde{A}_{2},...,\tilde{A}_{n}\right) = (\tilde{A}_{1})^{\omega_{1}} \oplus (\tilde{A}_{2})^{\omega_{2}}\oplus...\oplus(\tilde{A}_{n})^{\omega_{n}} \tag{2.1} }
IFWGω(A~1,A~2,...,A~n)=(A~1)ω1⊕(A~2)ω2⊕...⊕(A~n)ωn(2.1)
则称
IFWG
\operatorname{IFWG}
IFWG为直觉模糊加权几何算子,其中
ω
=
(
ω
1
,
ω
2
,
.
.
.
,
ω
n
)
T
\boldsymbol{\omega} = {\left(\omega_{1},\omega_{2},...,\omega_{n}\right)}^{T}
ω=(ω1,ω2,...,ωn)T为
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)的权重向量,
ω
j
∈
[
0
,
1
]
(
j
=
1
,
2
,
.
.
.
,
n
)
,
∑
j
=
1
n
ω
j
=
1
\omega_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}{\omega_{j}}=1
ωj∈[0,1](j=1,2,...,n),∑j=1nωj=1
特别地,若
ω
=
(
1
n
,
1
n
,
.
.
.
,
1
n
)
T
\boldsymbol{\omega} = {\left(\frac{1}{n},\frac{1}{n},...,\frac{1}{n}\right)}^{T}
ω=(n1,n1,...,n1)T,则
IFWG
\operatorname{IFWG}
IFWG算子退化为直觉模糊几何算子:
IFG
(
A
~
1
,
A
~
2
,
.
.
.
,
A
~
n
)
=
(
A
~
1
⊕
A
~
2
⊕
.
.
.
⊕
A
~
n
)
1
n
(2.2)
{\operatorname{IFG}}\left( \tilde{A}_{1},\tilde{A}_{2},...,\tilde{A}_{n}\right) = {\left(\tilde{A}_{1} \oplus \tilde{A}_{2}\oplus...\oplus\tilde{A}_{n}\right)}^{\frac{1}{n}} \tag{2.2}
IFG(A~1,A~2,...,A~n)=(A~1⊕A~2⊕...⊕A~n)n1(2.2)
定理2.1
设
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}}_{j} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j=1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)是一组直觉模糊数,则有
IFWG
\operatorname{IFWG}
IFWG算子运算得到的结果仍然是直觉模糊数,且
IFWG ω ( A ~ 1 , A ~ 2 , . . . A ~ n ) = ⟨ ∏ j = 1 n ( μ j ) ω j , 1 − ∏ j = 1 n ( 1 − ν j ) ω j ⟩ ‾ (2.3) \color{red} { \underline { \operatorname{IFWG}_{\omega}\left({\tilde{A}_{1}},{\tilde{A}_{2}},...{\tilde{A}_{n}}\right) = \left\langle{ {\prod_{j=1}^{n}\left(\mu_{j}\right)}^{\omega_{j}}, 1-{\prod_{j=1}^{n}{\left(1-\nu_{j}\right)}^{\omega_{j}}} }\right\rangle } } \tag{2.3} IFWGω(A~1,A~2,...A~n)=⟨j=1∏n(μj)ωj,1−j=1∏n(1−νj)ωj⟩(2.3)
其中, ω = ( ω 1 , ω 2 , . . . , ω n ) T \omega = {\left(\omega_{1},\omega_{2},...,\omega_{n}\right)}^{T} ω=(ω1,ω2,...,ωn)T为 A ~ j = ⟨ μ j , ν j ⟩ ( j = 1 , 2 , . . . , n ) \tilde{A}_{j} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j=1,2,...,n\right) A~j=⟨μj,νj⟩(j=1,2,...,n)的权重向量, ω j ∈ [ 0 , 1 ] ( j = 1 , 2 , . . . , n ) , ∑ j = 1 n ω j = 1 \omega_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}\omega_{j}=1 ωj∈[0,1](j=1,2,...,n),∑j=1nωj=1
推理过程:
已知:(1)
α
1
⊕
α
2
=
(
μ
α
1
+
μ
α
2
−
μ
α
1
μ
α
2
,
ν
α
1
ν
α
2
)
\alpha_{1} \oplus \alpha_{2} = \left( \mu_{\alpha_{1}} + \mu_{\alpha_{2}} -\mu_{\alpha_{1}}\mu_{\alpha_{2}}, \nu_{\alpha_{1}}\nu_{\alpha_{2}} \right)
α1⊕α2=(μα1+μα2−μα1μα2,να1να2);(2)
α
λ
=
(
μ
α
λ
,
1
−
(
1
−
ν
α
)
λ
)
\alpha^\lambda = \left({\mu_\alpha}^{\lambda}, 1 - \left(1-\nu_\alpha\right)^\lambda \right)
αλ=(μαλ,1−(1−να)λ)
原式: IFWG ω ( A ~ 1 , A ~ 2 , . . . , A ~ n ) = ( A ~ 1 ) ω 1 ⊕ ( A ~ 2 ) ω 2 ⊕ . . . ⊕ ( A ~ n ) ω n {\operatorname{IFWG}_{\omega}}\left( \tilde{A}_{1},\tilde{A}_{2},...,\tilde{A}_{n}\right) = (\tilde{A}_{1})^{\omega_{1}} \oplus (\tilde{A}_{2})^{\omega_{2}}\oplus...\oplus(\tilde{A}_{n})^{\omega_{n}} IFWGω(A~1,A~2,...,A~n)=(A~1)ω1⊕(A~2)ω2⊕...⊕(A~n)ωn
S1.计算:
A
~
1
ω
1
,
A
~
2
ω
2
,
.
.
.
,
A
~
n
ω
n
{\tilde{A}_{1}}^{\omega_{1}}, {\tilde{A}_{2}}^{\omega_{2}},...,{\tilde{A}_{n}}^{\omega_{n}}
A~1ω1,A~2ω2,...,A~nωn
R1.可得:
T
1
=
A
~
1
ω
1
=
(
μ
1
ω
1
,
1
−
(
1
−
ν
1
)
ω
1
)
T_{1} = {\tilde{A}_{1}}^{\omega_{1}} = \left({\mu_{1}}^{\omega_{1}},1 - {\left(1 - \nu_{1}\right)}^{\omega_{1}}\right)
T1=A~1ω1=(μ1ω1,1−(1−ν1)ω1),
T
2
=
A
~
2
ω
2
=
(
μ
2
ω
2
,
1
−
(
1
−
ν
2
)
ω
2
)
T_{2} = {\tilde{A}_{2}}^{\omega_{2}} = \left({\mu_{2}}^{\omega_{2}},1 - {\left(1 - \nu_{2}\right)}^{\omega_{2}}\right)
T2=A~2ω2=(μ2ω2,1−(1−ν2)ω2),…,
T
n
=
A
~
n
ω
n
=
(
μ
n
ω
n
,
1
−
(
1
−
ν
n
)
ω
n
)
T_{n} = {\tilde{A}_{n}}^{\omega_{n}} = \left({\mu_{n}}^{\omega_{n}},1 - {\left(1 - \nu_{n}\right)}^{\omega_{n}}\right)
Tn=A~nωn=(μnωn,1−(1−νn)ωn)
S2.计算:
T
1
⊕
T
2
T_{1}\oplus T_{2}
T1⊕T2
R2.可得:
T
1
⊕
T
2
=
(
μ
1
ω
1
μ
2
ω
2
,
1
−
(
1
−
ν
1
)
ω
1
+
1
−
(
1
−
ν
2
)
ω
2
−
(
1
−
(
1
−
ν
1
)
ω
1
)
(
1
−
(
1
−
ν
1
)
ω
1
)
)
=
(
μ
1
ω
1
μ
2
ω
2
,
2
−
(
1
−
ν
1
)
ω
1
−
(
1
−
ν
2
)
ω
2
−
[
1
−
(
1
−
ν
2
)
ω
2
−
(
1
−
ν
1
)
ω
1
+
(
1
−
ν
1
)
ω
1
(
1
−
ν
2
)
ω
2
]
)
=
(
μ
1
ω
1
μ
2
ω
2
,
1
−
(
1
−
ν
1
)
ω
1
(
1
−
ν
2
)
ω
2
)
\begin{aligned} T_{1}\oplus T_{2} &= \left({\mu_{1}}^{\omega_{1}}{\mu_{2}}^{\omega_{2}}, 1 - {\left(1 - \nu_{1}\right)}^{\omega_{1}} + 1 - {\left(1 - \nu_{2}\right)}^{\omega_{2}} - \left(1 - {\left(1 - \nu_{1}\right)}^{\omega_{1}}\right)\left(1 - {\left(1 - \nu_{1}\right)}^{\omega_{1}}\right)\right)\\ &= \left({\mu_{1}}^{\omega_{1}}{\mu_{2}}^{\omega_{2}},2- {\left(1 - \nu_{1}\right)}^{\omega_{1}} - {\left(1 - \nu_{2}\right)}^{\omega_{2}} - \left[1-{\left(1 - \nu_{2}\right)}^{\omega_{2}}-{\left(1 - \nu_{1}\right)}^{\omega_{1}} + {\left(1 - \nu_{1}\right)}^{\omega_{1}}{\left(1 - \nu_{2}\right)}^{\omega_{2}}\right]\right)\\ &= \left({\mu_{1}}^{\omega_{1}}{\mu_{2}}^{\omega_{2}},1-{\left(1 - \nu_{1}\right)}^{\omega_{1}}{\left(1 - \nu_{2}\right)}^{\omega_{2}}\right)\\ \end{aligned}
T1⊕T2=(μ1ω1μ2ω2,1−(1−ν1)ω1+1−(1−ν2)ω2−(1−(1−ν1)ω1)(1−(1−ν1)ω1))=(μ1ω1μ2ω2,2−(1−ν1)ω1−(1−ν2)ω2−[1−(1−ν2)ω2−(1−ν1)ω1+(1−ν1)ω1(1−ν2)ω2])=(μ1ω1μ2ω2,1−(1−ν1)ω1(1−ν2)ω2)
同理可以计算得到:
T
1
⊕
T
2
⊕
T
3
=
(
μ
1
ω
1
μ
2
ω
2
μ
3
ω
3
,
1
−
(
1
−
ν
1
)
ω
1
(
1
−
ν
2
)
ω
2
(
1
−
ν
3
)
ω
3
)
T_{1}\oplus T_{2} \oplus T_{3} = \left({\mu_{1}}^{\omega_{1}}{\mu_{2}}^{\omega_{2}}{\mu_{3}}^{\omega_{3}},1-{\left(1 - \nu_{1}\right)}^{\omega_{1}}{\left(1 - \nu_{2}\right)}^{\omega_{2}}{\left(1 - \nu_{3}\right)}^{\omega_{3}}\right)
T1⊕T2⊕T3=(μ1ω1μ2ω2μ3ω3,1−(1−ν1)ω1(1−ν2)ω2(1−ν3)ω3)
依次类推,可得到: T 1 ⊕ T 2 ⊕ . . . ⊕ T n = ( μ 1 ω 1 μ 2 ω 2 . . . μ n ω n , 1 − ( 1 − ν 1 ) ω 1 ( 1 − ν 2 ) ω 2 . . . ( 1 − ν n ) ω n ) T_{1}\oplus T_{2} \oplus...\oplus T_{n} = \left({\mu_{1}}^{\omega_{1}}{\mu_{2}}^{\omega_{2}}...{\mu_{n}}^{\omega_{n}},1-{\left(1 - \nu_{1}\right)}^{\omega_{1}}{\left(1 - \nu_{2}\right)}^{\omega_{2}}...{\left(1 - \nu_{n}\right)}^{\omega_{n}}\right) T1⊕T2⊕...⊕Tn=(μ1ω1μ2ω2...μnωn,1−(1−ν1)ω1(1−ν2)ω2...(1−νn)ωn)
合并结果为: T 1 ⊕ T 2 ⊕ . . . ⊕ T n = ⟨ ∏ j = 1 n ( μ j ) ω j , 1 − ∏ j = 1 n ( 1 − ν j ) ω j ⟩ T_{1}\oplus T_{2} \oplus...\oplus T_{n} = \left\langle{{\prod_{j=1}^{n}{\left(\mu_{j}\right)}^{\omega_{j}}},1-{\prod_{j=1}^{n}\left(1-\nu_{j}\right)}^{\omega_{j}} }\right\rangle T1⊕T2⊕...⊕Tn=⟨∏j=1n(μj)ωj,1−∏j=1n(1−νj)ωj⟩
即: IFWG ω ( A ~ 1 , A ~ 2 , . . . A ~ n ) = ⟨ ∏ j = 1 n ( μ j ) ω j , 1 − ∏ j = 1 n ( 1 − ν j ) ω j ⟩ \operatorname{IFWG}_{\omega}\left({\tilde{A}_{1}},{\tilde{A}_{2}},...{\tilde{A}_{n}}\right) = \left\langle{{\prod_{j=1}^{n}{\left(\mu_{j}\right)}^{\omega_{j}}},1-{\prod_{j=1}^{n}\left(1-\nu_{j}\right)}^{\omega_{j}}}\right\rangle IFWGω(A~1,A~2,...A~n)=⟨∏j=1n(μj)ωj,1−∏j=1n(1−νj)ωj⟩
示 例 2.1 \color{red}{示例 2.1} 示例2.1
设 A ~ 1 = ⟨ 0.2 , 0.5 ⟩ \tilde{A}_{1}=\left\langle0.2,0.5\right\rangle A~1=⟨0.2,0.5⟩, A ~ 2 = ⟨ 0.7 , 0.1 ⟩ \tilde{A}_{2}=\left\langle0.7,0.1\right\rangle A~2=⟨0.7,0.1⟩, A ~ 3 = ⟨ 0.5 , 0.2 ⟩ \tilde{A}_{3}=\left\langle0.5,0.2\right\rangle A~3=⟨0.5,0.2⟩, A ~ 4 = ⟨ 0.4 , 0.3 ⟩ \tilde{A}_{4}=\left\langle0.4,0.3\right\rangle A~4=⟨0.4,0.3⟩, A ~ 5 = ⟨ 0.6 , 0.2 ⟩ \tilde{A}_{5}=\left\langle0.6,0.2\right\rangle A~5=⟨0.6,0.2⟩为五个直觉模糊数, ω = ( 0.20 , 0.25 , 0.18 , 0.22 , 0.15 ) T \omega={\left(0.20,0.25,0.18,0.22,0.15\right)}^{T} ω=(0.20,0.25,0.18,0.22,0.15)T为该直觉模糊数组权重向量,则 IFWG \operatorname{IFWG} IFWG结果是多少?
代码如下:
import numpy as np
def calculate_IFWG(IF_matrix,weight):
IFWG = [1,1]
for i in range(IF_matrix.shape[1]):
IFWG[0] *= np.power(IF_matrix[0][i],weight[i])
IFWG[1] *= np.power(1-IF_matrix[1][i],weight[i])
IFWG[1] = 1 - IFWG[1]
return IFWG
IF_matrix = np.array([[0.2,0.7,0.5,0.4,0.6],[0.5,0.1,0.2,0.3,0.2]])
weight = np.array([0.20,0.25,0.18,0.22,0.15])
print("IF矩阵:\n",IF_matrix)
print("权重向量:\n",weight)
print('IFWG:\n',calculate_IFWG(IF_matrix,weight))
IF矩阵:
[[0.2 0.7 0.5 0.4 0.6]
[0.5 0.1 0.2 0.3 0.2]]
权重向量:
[0.2 0.25 0.18 0.22 0.15]
IFWG:
[0.4430686230851544, 0.2717241768779469]
2.2 直觉模糊有序几何算子
定义2.2
设
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)是一组直觉模糊数,若
IFOWG
\operatorname{IFOWG}
IFOWG是一个映射:
F
n
→
F
F_{n} \rightarrow F
Fn→F,使得:
IFOWG
w
(
A
~
1
,
A
~
2
,
.
.
.
,
A
~
n
)
=
A
~
σ
(
1
)
w
1
⊕
A
~
σ
(
2
)
w
2
⊕
.
.
.
⊕
A
~
σ
(
n
)
w
n
(2.4)
\color{red} { {\operatorname{IFOWG}_{w}}\left( \tilde{A}_{1},\tilde{A}_{2},...,\tilde{A}_{n}\right) = {\tilde{A}_{\sigma(1)}}^{w_{1}} \oplus {\tilde{A}_{\sigma(2)}}^{w_{2}}\oplus...\oplus{\tilde{A}_{\sigma(n)}}^{w_{n}} \tag{2.4} }
IFOWGw(A~1,A~2,...,A~n)=A~σ(1)w1⊕A~σ(2)w2⊕...⊕A~σ(n)wn(2.4)
则称
IFOWG
\operatorname{IFOWG}
IFOWG为直觉模糊有序加权平均算子,其中
w
=
(
w
1
,
w
2
,
.
.
.
,
w
n
)
T
\boldsymbol{w} = {\left(w_{1},w_{2},...,w_{n}\right)}^{T}
w=(w1,w2,...,wn)T为与
IFOWA
\operatorname{IFOWA}
IFOWA算子相关联的权重向量,
w
j
∈
[
0
,
1
]
(
j
=
1
,
2
,
.
.
.
,
n
)
,
∑
j
=
1
n
w
j
=
1
w_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}{w_{j}}=1
wj∈[0,1](j=1,2,...,n),∑j=1nwj=1,
(
σ
(
1
)
,
σ
(
2
)
,
.
.
.
,
σ
(
n
)
)
\left(\sigma(1),\sigma(2),...,\sigma(n)\right)
(σ(1),σ(2),...,σ(n))为数组
(
1
,
2
,
.
.
.
,
n
)
\left(1,2,...,n\right)
(1,2,...,n)的一个置换,使得对任意k,有
A
~
σ
(
k
1
)
≥
A
~
σ
(
k
)
\tilde{A}_{\sigma(k1)}\geq\tilde{A}_{\sigma(k)}
A~σ(k1)≥A~σ(k),即
A
~
σ
(
k
)
\tilde{A}_{\sigma(k)}
A~σ(k)是直觉模糊数
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)按直觉模糊数的排序规则确定的第k个最大直觉模糊数。
特别地,若
w
=
(
1
n
,
1
n
,
.
.
.
,
1
n
)
T
\boldsymbol{w} = {\left(\frac{1}{n},\frac{1}{n},...,\frac{1}{n}\right)}^{T}
w=(n1,n1,...,n1)T,则
IFOWA
\operatorname{IFOWA}
IFOWA算子退化为直觉模平均
IFA
\operatorname{IFA}
IFA算子:
IFOWA
w
(
A
~
1
,
A
~
2
,
.
.
.
,
A
~
n
)
=
1
n
(
A
~
1
⊕
A
~
2
⊕
.
.
.
⊕
A
~
n
)
{\operatorname{IFOWA}_{w}}\left( \tilde{A}_{1},\tilde{A}_{2},...,\tilde{A}_{n}\right) = \frac{1}{n}\left(\tilde{A}_{1} \oplus \tilde{A}_{2}\oplus...\oplus\tilde{A}_{n}\right)
IFOWAw(A~1,A~2,...,A~n)=n1(A~1⊕A~2⊕...⊕A~n)
定理2.2
设
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}}_{j} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j=1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)是一组直觉模糊数,
A
~
σ
(
k
)
\tilde{A}_{\sigma(k)}
A~σ(k)是直觉模糊数
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)按直觉模糊数的排序规则确定的第k个最大直觉模糊数,则有
IFOWG
\operatorname{IFOWG}
IFOWG算子运算得到的结果仍然是直觉模糊数,且
IFOWG
w
(
A
~
1
,
A
~
2
,
.
.
.
A
~
n
)
=
⟨
∏
j
=
1
n
(
μ
σ
(
j
)
)
w
j
,
1
−
∏
j
=
1
n
(
1
−
ν
σ
(
j
)
)
w
j
⟩
‾
(2.5)
\color{red} { \underline { \operatorname{IFOWG}_{w}\left({\tilde{A}_{1}},{\tilde{A}_{2}},...{\tilde{A}_{n}}\right) = \left\langle{ {\prod_{j=1}^{n}{\left(\mu_{\sigma(j)}\right)}^{w_{j}}}, 1-{\prod_{j=1}^{n}\left(1-\nu_{\sigma(j)}\right)}^{w_{j}} }\right\rangle } } \tag{2.5}
IFOWGw(A~1,A~2,...A~n)=⟨j=1∏n(μσ(j))wj,1−j=1∏n(1−νσ(j))wj⟩(2.5)
其中,
w
=
(
w
1
,
w
2
,
.
.
.
,
w
n
)
T
\boldsymbol{w} = {\left(w_{1},w_{2},...,w_{n}\right)}^{T}
w=(w1,w2,...,wn)T为与
IFOWG
\operatorname{IFOWG}
IFOWG算子相关联的权重向量,
w
j
∈
[
0
,
1
]
(
j
=
1
,
2
,
.
.
.
,
n
)
,
∑
j
=
1
n
w
j
=
1
w_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}{w_{j}}=1
wj∈[0,1](j=1,2,...,n),∑j=1nwj=1。
2.3 直觉模糊混合几何算子
定义2.3
设
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)是一组直觉模糊数,若
IFHG
\operatorname{IFHG}
IFHG是一个映射:
F
n
→
F
F_{n} \rightarrow F
Fn→F,使得:
IFHG
w
(
A
~
1
,
A
~
2
,
.
.
.
,
A
~
n
)
=
A
′
~
σ
(
1
)
w
1
⊕
A
′
~
σ
(
2
)
w
2
⊕
.
.
.
⊕
A
′
~
σ
(
n
)
w
n
(2.6)
\color{red} { {\operatorname{IFHG}_{w}}\left( \tilde{A}_{1},\tilde{A}_{2},...,\tilde{A}_{n}\right) = {\tilde{A^{'}}_{\sigma(1)}}^{w_{1}} \oplus {\tilde{A^{'}}_{\sigma(2)}}^{w_{2}}\oplus...\oplus {\tilde{A^{'}}_{\sigma(n)}}^{w_{n}} \tag{2.6} }
IFHGw(A~1,A~2,...,A~n)=A′~σ(1)w1⊕A′~σ(2)w2⊕...⊕A′~σ(n)wn(2.6)
则称
IFHG
\operatorname{IFHG}
IFHG为直觉模糊混合平均算子,其中
w
=
(
w
1
,
w
2
,
.
.
.
,
w
n
)
T
\boldsymbol{w} = {\left(w_{1},w_{2},...,w_{n}\right)}^{T}
w=(w1,w2,...,wn)T为与
IFHG
\operatorname{IFHG}
IFHG算子相关联的权重向量,
w
j
∈
[
0
,
1
]
(
j
=
1
,
2
,
.
.
.
,
n
)
,
∑
j
=
1
n
w
j
=
1
w_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}{w_{j}}=1
wj∈[0,1](j=1,2,...,n),∑j=1nwj=1;
A
′
~
j
=
(
A
~
j
)
n
ω
j
=
⟨
μ
′
j
,
ν
′
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
\tilde{A^{'}}_{j} = {\left(\tilde{A}_{j}\right)}^{n\omega_{j}}=\left\langle{\mu^{'}}_{j},{\nu^{'}}_{j}\right\rangle\left(j=1,2,...,n\right)
A′~j=(A~j)nωj=⟨μ′j,ν′j⟩(j=1,2,...,n),
(
A
′
~
σ
(
1
)
,
A
′
~
σ
(
2
)
,
.
.
.
,
A
′
~
σ
(
n
)
)
\left(\tilde{A^{'}}_{\sigma(1)},\tilde{A^{'}}_{\sigma(2)},...,\tilde{A^{'}}_{\sigma(n)}\right)
(A′~σ(1),A′~σ(2),...,A′~σ(n))为加权的直觉模糊数数组
(
A
′
~
1
,
A
′
~
2
,
.
.
.
,
A
′
~
n
)
\left(\tilde{A^{'}}_{1},\tilde{A^{'}}_{2},...,\tilde{A^{'}}_{n}\right)
(A′~1,A′~2,...,A′~n)的一个置换,使得对任意k,有
A
′
~
σ
(
k
−
1
)
≥
A
′
~
σ
(
k
)
\tilde{A^{'}}_{\sigma(k-1)}\geq\tilde{A^{'}}_{\sigma(k)}
A′~σ(k−1)≥A′~σ(k),即
A
′
~
σ
(
k
)
\tilde{A^{'}}_{\sigma(k)}
A′~σ(k)是直觉模糊数
A
′
~
j
=
⟨
μ
j
′
,
ν
j
′
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A^{'}}_{j}} = \left\langle\mu^{'}_{j},\nu^{'}_{j}\right\rangle\left(j = 1,2,...,n\right)
A′~j=⟨μj′,νj′⟩(j=1,2,...,n)按直觉模糊数的排序规则确定的第
k
k
k个最大直觉模糊数。
ω
=
(
ω
1
,
ω
2
,
.
.
.
,
ω
n
)
T
\boldsymbol{\omega} = {\left(\omega_{1},\omega_{2},...,\omega_{n}\right)}^{T}
ω=(ω1,ω2,...,ωn)T为
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)的权重向量,
ω
j
∈
[
0
,
1
]
(
j
=
1
,
2
,
.
.
.
,
n
)
,
∑
j
=
1
n
ω
j
=
1
\omega_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}{\omega_{j}}=1
ωj∈[0,1](j=1,2,...,n),∑j=1nωj=1,
n
n
n为平衡系数。
特别地,若 w = ( 1 n , 1 n , . . . , 1 n ) T \boldsymbol{w} = {\left(\frac{1}{n},\frac{1}{n},...,\frac{1}{n}\right)}^{T} w=(n1,n1,...,n1)T,则 IFHG \operatorname{IFHG} IFHG算子退化为直觉模糊加权几何算子 IFWG \operatorname{IFWG} IFWG;若 ω = ( 1 n , 1 n , . . . , 1 n ) T \boldsymbol{\omega} = {\left(\frac{1}{n},\frac{1}{n},...,\frac{1}{n}\right)}^{T} ω=(n1,n1,...,n1)T,则 IFHG \operatorname{IFHG} IFHG算子退化为直觉模糊有序加权几何算子 IFOWG \operatorname{IFOWG} IFOWG。
定理2.3
设
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}}_{j} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j=1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)是一组直觉模糊数,令
A
′
~
j
=
A
~
j
n
ω
j
=
⟨
μ
j
′
,
ν
j
′
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
\tilde{A^{'}}_{j} = {\tilde{A}_{j}}^{n\omega_{j}}=\left\langle\mu^{'}_{j},\nu^{'}_{j}\right\rangle\left(j=1,2,...,n\right)
A′~j=A~jnωj=⟨μj′,νj′⟩(j=1,2,...,n),
A
′
~
σ
(
k
)
\tilde{A^{'}}_{\sigma(k)}
A′~σ(k)是直觉模糊数
A
′
~
j
=
⟨
μ
j
′
,
ν
j
′
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A^{'}}_{j}} = \left\langle\mu^{'}_{j},\nu^{'}_{j}\right\rangle\left(j = 1,2,...,n\right)
A′~j=⟨μj′,νj′⟩(j=1,2,...,n)中按直觉模糊数的排序规则确定的第
k
k
k个最大直觉模糊数,则有
I
F
H
G
\boldsymbol{IFHG}
IFHG算子运算得到的结果仍然是直觉模糊数,且
IFHG ω , w ( A ~ 1 , A ~ 2 , . . . A ~ n ) = ⟨ 1 − ∏ j = 1 n ( 1 − μ σ ( j ) ′ ) w j , ∏ j = 1 n ( ν σ ( j ) ′ ) w j ⟩ ‾ (2.7) \color{red} { \underline { \operatorname{IFHG}_{\omega,w}\left({\tilde{A}_{1}},{\tilde{A}_{2}},...{\tilde{A}_{n}}\right) = \left\langle{ 1-{\prod_{j=1}^{n}\left(1-\mu^{'}_{\sigma(j)}\right)}^{w_{j}}, {\prod_{j=1}^{n}{\left(\nu^{'}_{\sigma(j)}\right)}^{w_{j}}} }\right\rangle } } \tag{2.7} IFHGω,w(A~1,A~2,...A~n)=⟨1−j=1∏n(1−μσ(j)′)wj,j=1∏n(νσ(j)′)wj⟩(2.7)
其中,
w
=
(
w
1
,
w
2
,
.
.
.
,
w
n
)
T
\boldsymbol{w} = {\left(w_{1},w_{2},...,w_{n}\right)}^{T}
w=(w1,w2,...,wn)T为与
IFOWG
\operatorname{IFOWG}
IFOWG算子相关联的权重向量,
w
j
∈
[
0
,
1
]
(
j
=
1
,
2
,
.
.
.
,
n
)
,
∑
j
=
1
n
w
j
=
1
w_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}{w_{j}}=1
wj∈[0,1](j=1,2,...,n),∑j=1nwj=1;
ω
=
(
ω
1
,
ω
2
,
.
.
.
,
ω
n
)
T
\boldsymbol{\omega} = {\left(\omega_{1},\omega_{2},...,\omega_{n}\right)}^{T}
ω=(ω1,ω2,...,ωn)T为
A
~
j
=
⟨
μ
j
,
ν
j
⟩
(
j
=
1
,
2
,
.
.
.
,
n
)
{\tilde{A}_{j}} = \left\langle\mu_{j},\nu_{j}\right\rangle\left(j = 1,2,...,n\right)
A~j=⟨μj,νj⟩(j=1,2,...,n)的权重向量,
ω
j
∈
[
0
,
1
]
(
j
=
1
,
2
,
.
.
.
,
n
)
,
∑
j
=
1
n
ω
j
=
1
\omega_{j} \in [0,1]\left(j=1,2,...,n\right),\sum_{j=1}^{n}{\omega_{j}}=1
ωj∈[0,1](j=1,2,...,n),∑j=1nωj=1,
n
n
n为平衡系数。
示 例 2.3 \color{red}{示例2.3} 示例2.3
设 A ~ 1 = ⟨ 0.2 , 0.5 ⟩ \tilde{A}_{1}=\left\langle0.2,0.5\right\rangle A~1=⟨0.2,0.5⟩, A ~ 2 = ⟨ 0.3 , 0.4 ⟩ \tilde{A}_{2}=\left\langle0.3,0.4\right\rangle A~2=⟨0.3,0.4⟩, A ~ 3 = ⟨ 0.5 , 0.1 ⟩ \tilde{A}_{3}=\left\langle0.5,0.1\right\rangle A~3=⟨0.5,0.1⟩, A ~ 4 = ⟨ 0.7 , 0.2 ⟩ \tilde{A}_{4}=\left\langle0.7,0.2\right\rangle A~4=⟨0.7,0.2⟩, A ~ 4 = ⟨ 0.6 , 0.3 ⟩ \tilde{A}_{4}=\left\langle0.6,0.3\right\rangle A~4=⟨0.6,0.3⟩为五个直觉模糊数, ω = ( 0.25 , 0.15 , 0.20 , 0.18 , 0.22 ) T \omega={\left(0.25,0.15,0.20,0.18,0.22\right)}^{T} ω=(0.25,0.15,0.20,0.18,0.22)T为 A ~ j ( j = 1 , 2 , 3 , 4 , 5 ) \tilde{A}_{j}\left(j=1,2,3,4,5\right) A~j(j=1,2,3,4,5)的权重向量, w = ( 0.112 , 0.236 , 0.304 , 0.236 , 0.112 ) T w={\left(0.112,0.236,0.304,0.236,0.112\right)}^{T} w=(0.112,0.236,0.304,0.236,0.112)T为与 IFHG \operatorname{IFHG} IFHG算子相关联的权重向量, 则 IFHG \operatorname{IFHG} IFHG结果是多少?
代码如下:
import numpy as np
def calculate_weight_IF(IF_matrix,weight_IF):
weight_IF_ = weight_IF * IF_matrix.shape[1] # 计算<A_j_'> = (<A_j>)^(n×<w_j>)
weighted_IF_matrix = np.zeros(IF_matrix.shape) # 初始化矩阵用于存放加权后的结果
weighted_IF_matrix[0] = np.power(IF_matrix[0],weight_IF_) # 计算加权后的μ_i = (<u_i>)^<w_i>
weighted_IF_matrix[1] = 1 - np.power(1 - IF_matrix[1],weight_IF_) # 计算加权后的v_i = 1-(1-<v_i>)^<w_i>
return weighted_IF_matrix
def IF_rank(IF_matrix):
# 计算每个直觉模糊数的得分值score=μ-v
score = IF_matrix[0] - IF_matrix[1]
# 按照得分值从大到小进行重新排序
index = np.argsort(-score) # 获取从大到小排序索引
IF_sequence_matrix = np.zeros(IF_matrix.shape) # 初始化结果矩阵
for i in range(IF_matrix.shape[1]): # 更新结果矩阵
IF_sequence_matrix[0][i] = IF_matrix[0][index[i]]
IF_sequence_matrix[1][i] = IF_matrix[1][index[i]]
return score,IF_sequence_matrix,index
def calculate_IFHG(IF_sequence_matrix,weight):
IFHG = [1,1]
for i in range(IF_sequence_matrix.shape[1]):
IFHG[0] *= np.power(IF_sequence_matrix[0][i],weight[i])
IFHG[1] *= np.power(1-IF_sequence_matrix[1][i],weight[i])
IFHG[1] = 1 - IFHG[1]
return IFHG
# 输入
IF_matrix = np.array([[0.2,0.3,0.5,0.7,0.6],[0.5,0.4,0.1,0.2,0.3]])
weight_IF = np.array([0.25,0.15,0.20,0.18,0.22])
weight_IFHA = np.array([0.112,0.236,0.304,0.236,0.112])
# S1: 计算加权直觉模糊数A_j_'
weighted_IF_matrix = calculate_weight_IF(IF_matrix,weight_IF)
print('Weighted_IF_matrix:\n',weighted_IF_matrix)
# S2:计算A_j_'的得分值
# S3:排序
ranked_IF = IF_rank(weighted_IF_matrix)
print('\nscores: {}\nRanked_IF:{}\nindex: {}\n'.format(ranked_IF[0],ranked_IF[1],ranked_IF[2]+1))
# S4:计算IFHA
IFHG = calculate_IFHG(ranked_IF[1],weight_IFHA)
print('\nIFHG:\n',IFHG)
计算结果如下:
Weighted_IF_matrix:
[[0.13374806 0.40536005 0.5 0.72541785 0.57012013]
[0.57955179 0.31826838 0.1 0.18194785 0.32452723]]
scores: [-0.44580373 0.08709167 0.4 0.54346999 0.2455929 ]
Ranked_IF:[[0.72541785 0.5 0.57012013 0.40536005 0.13374806]
[0.18194785 0.1 0.32452723 0.31826838 0.57955179]]
index: [4 3 5 2 1]
IFHG:
[0.44540105671448443, 0.2981859482602651]
2.4 基于直觉模糊混合几何算子的多属性决策步骤
基于直觉模糊混合几何算子的多属性决策步骤
步骤 1 确定多属性决策问题的方案集
Y
=
{
Y
1
,
Y
2
,
.
.
.
,
Y
m
}
Y=\left\{Y_{1},Y_{2},...,Y_{m}\right\}
Y={Y1,Y2,...,Ym}和属性集
G
=
{
G
1
,
G
2
,
.
.
.
,
G
n
}
G=\left\{G_{1},G_{2},...,G_{n}\right\}
G={G1,G2,...,Gn}。
步骤 2 获取多属性决策问题中各方案
Y
i
∈
Y
Y_{i} \in Y
Yi∈Y关于属性
G
j
∈
G
G_{j} \in G
Gj∈G的直觉模糊特征信息,构建直觉模糊决策矩阵
F
F
F。
步骤 3 确定多属性决策问题各属性的权重,得到属性权重向量
ω
=
(
ω
1
,
ω
2
,
.
.
.
,
ω
n
)
T
\boldsymbol{\omega} = {\left(\omega_{1},\omega_{2},...,\omega_{n}\right)}^{T}
ω=(ω1,ω2,...,ωn)T。
步骤 4 利用正态分布赋权法等确定与
IFHA
\operatorname{IFHA}
IFHA算子相关联的权重向量(或位置向量)
w
=
(
w
1
,
w
2
,
.
.
.
,
w
n
)
T
\boldsymbol{w} = {\left(w_{1},w_{2},...,w_{n}\right)}^{T}
w=(w1,w2,...,wn)T。
步骤 4 利用
IFHG
ω
,
w
(
A
~
1
,
A
~
2
,
.
.
.
A
~
n
)
=
⟨
1
−
∏
j
=
1
n
(
1
−
μ
σ
(
j
)
′
)
ω
j
,
∏
j
=
1
n
(
ν
σ
(
j
)
′
)
ω
j
⟩
\operatorname{IFHG}_{\omega,w}\left({\tilde{A}_{1}},{\tilde{A}_{2}},...{\tilde{A}_{n}}\right) = \left\langle{ 1-{\prod_{j=1}^{n}\left(1-\mu^{'}_{\sigma(j)}\right)}^{\omega_{j}},{\prod_{j=1}^{n}{\left(\nu^{'}_{\sigma(j)}\right)}^{\omega_{j}}} }\right\rangle
IFHGω,w(A~1,A~2,...A~n)=⟨1−∏j=1n(1−μσ(j)′)ωj,∏j=1n(νσ(j)′)ωj⟩计算方案
Y
i
Y_{i}
Yi的综合属性值
d
~
i
=
IFHG
w
,
ω
(
(
~
F
)
i
1
,
(
~
F
)
i
2
,
.
.
.
,
(
~
F
)
i
n
,
)
\tilde{d}_{i} = \operatorname{IFHG}_{w,\omega}\left(\tilde(F)_{i1},\tilde(F)_{i2},...,\tilde(F)_{in},\right)
d~i=IFHGw,ω((~F)i1,(~F)i2,...,(~F)in,)。首先利用属性权重
w
=
(
w
1
,
w
2
,
.
.
.
,
w
n
)
T
\boldsymbol{w} = {\left(w_{1},w_{2},...,w_{n}\right)}^{T}
w=(w1,w2,...,wn)T和平衡系数
n
n
n计算加权的直觉模糊数
F
′
~
i
j
=
F
~
i
j
…
…
n
w
j
\tilde{F^{'}}_{ij} = {\tilde{F}_{ij}}……{n{w_j}}
F′~ij=F~ij……nwj,然后利用直觉模糊数的排序规则对
F
′
~
i
j
(
j
=
1
,
2
,
.
.
.
,
n
)
\tilde{F^{'}}_{ij}\left(j=1,2,...,n\right)
F′~ij(j=1,2,...,n)进行排序,得到直觉模糊数组
F
′
~
σ
(
1
)
,
F
′
~
σ
(
2
)
,
.
.
.
,
F
′
~
σ
(
n
)
\tilde{F^{'}}_{\sigma(1)},\tilde{F^{'}}_{\sigma(2)},...,\tilde{F^{'}}_{\sigma(n)}
F′~σ(1),F′~σ(2),...,F′~σ(n);最后根据与
IFHG
\operatorname{IFHG}
IFHG算子相关的权重向量
ω
=
(
ω
1
,
ω
2
,
.
.
.
,
ω
n
)
T
\boldsymbol{\omega} = {\left(\omega_{1},\omega_{2},...,\omega_{n}\right)}^{T}
ω=(ω1,ω2,...,ωn)T计算方案
Y
i
Y_{i}
Yi的综合属性值
d
~
i
=
IFHG
w
,
ω
(
F
~
i
1
,
F
~
i
2
,
.
.
.
,
F
~
i
n
)
\tilde{d}_{i}=\operatorname{IFHG}_{w,\omega}\left(\tilde{F}_{i1},\tilde{F}_{i2},...,\tilde{F}_{in}\right)
d~i=IFHGw,ω(F~i1,F~i2,...,F~in)
2.5 基于直觉模糊混合几何算子的多属性决策的实例分析
示 例 2.4 \color{red}{示例2.4} 示例2.4
考虑地方政府公共财政支出绩效评价问题。公共财政支出绩效评价是对财政支出活动的经济性、效率性、有效性进行评价,可以从教育支出绩效( G 1 G_{1} G1)、养老支出绩效( G 2 G_{2} G2)、就业支出绩效( G 3 G_{3} G3)和基础设施建设支出绩效( G 4 G_{4} G4)四个方面进行绩效评估。假设通过调研与专家咨询可以获得五个地区 Y i ( i = 1 , 2 , 3 , 4 , 5 ) Y_{i}(i=1,2,3,4,5) Yi(i=1,2,3,4,5)关于属性 G j ( j = 1 , 2 , 3 , 4 ) G_{j}(j=1,2,3,4) Gj(j=1,2,3,4)的直觉模糊评价结果如下表所示。同时利用层次分析法可以得到属性 G j ( j = 1 , 2 , 3 , 4 ) G_{j}(j=1,2,3,4) Gj(j=1,2,3,4)的权重向量为 ω = ( 0.273 , 0.279 , 0.275 , 0.173 ) T \omega={(0.273,0.279,0.275,0.173)}^{T} ω=(0.273,0.279,0.275,0.173)T。假设由正态分布赋权法得到与 IFHG \operatorname{IFHG} IFHG算子相关联的权重向量 w = ( 0.2 , 0.3 , 0.3 , 0.2 ) w=\left(0.2,0.3,0.3,0.2\right) w=(0.2,0.3,0.3,0.2)
G 1 G_1 G1 | G 2 G_2 G2 | G 3 G_3 G3 | G 4 G_4 G4 | |
---|---|---|---|---|
Y 1 Y_1 Y1 | ⟨ 0.51 , 0.44 ⟩ \langle0.51,0.44\rangle ⟨0.51,0.44⟩ | ⟨ 0.45 , 0.32 ⟩ \langle0.45,0.32\rangle ⟨0.45,0.32⟩ | ⟨ 0.40 , 0.55 ⟩ \langle0.40,0.55\rangle ⟨0.40,0.55⟩ | ⟨ 0.35 , 0.50 ⟩ \langle0.35,0.50\rangle ⟨0.35,0.50⟩ |
Y 2 Y_2 Y2 | ⟨ 0.45 , 0.50 ⟩ \langle0.45,0.50\rangle ⟨0.45,0.50⟩ | ⟨ 0.36 , 0.45 ⟩ \langle0.36,0.45\rangle ⟨0.36,0.45⟩ | ⟨ 0.45 , 0.40 ⟩ \langle0.45,0.40\rangle ⟨0.45,0.40⟩ | ⟨ 0.70 , 0.20 ⟩ \langle0.70,0.20\rangle ⟨0.70,0.20⟩ |
Y 3 Y_3 Y3 | ⟨ 0.65 , 0.30 ⟩ \langle0.65,0.30\rangle ⟨0.65,0.30⟩ | ⟨ 0.55 , 0.40 ⟩ \langle0.55,0.40\rangle ⟨0.55,0.40⟩ | ⟨ 0.50 , 0.42 ⟩ \langle0.50,0.42\rangle ⟨0.50,0.42⟩ | ⟨ 0.45 , 0.50 ⟩ \langle0.45,0.50\rangle ⟨0.45,0.50⟩ |
Y 4 Y_4 Y4 | ⟨ 0.60 , 0.25 ⟩ \langle0.60,0.25\rangle ⟨0.60,0.25⟩ | ⟨ 0.75 , 0.15 ⟩ \langle0.75,0.15\rangle ⟨0.75,0.15⟩ | ⟨ 0.65 , 0.25 ⟩ \langle0.65,0.25\rangle ⟨0.65,0.25⟩ | ⟨ 0.50 , 0.35 ⟩ \langle0.50,0.35\rangle ⟨0.50,0.35⟩ |
Y 5 Y_5 Y5 | ⟨ 0.55 , 0.30 ⟩ \langle0.55,0.30\rangle ⟨0.55,0.30⟩ | ⟨ 0.50 , 0.35 ⟩ \langle0.50,0.35\rangle ⟨0.50,0.35⟩ | ⟨ 0.55 , 0.15 ⟩ \langle0.55,0.15\rangle ⟨0.55,0.15⟩ | ⟨ 0.55 , 0.20 ⟩ \langle0.55,0.20\rangle ⟨0.55,0.20⟩ |
代码如下:
import numpy as np
def calculate_weight_IF_IFHG(IF_matrix,weight_IF):
weight_IF_ = IF_matrix.shape[1]*weight_IF # 计算<A_j_'> = (<A_j>)^(n×<w_j>)
weighted_IF_matrix = np.zeros(IF_matrix.shape) # 初始化矩阵用于存放加权后的结果
weighted_IF_matrix[0] = np.power(IF_matrix[0],weight_IF_) # 计算加权后的μ_i = (<u_i>)^<w_i>
weighted_IF_matrix[1] = 1 - np.power(1 - IF_matrix[1],weight_IF_) # 计算加权后的v_i = 1-(1-<v_i>)^<w_i>
return weighted_IF_matrix
def IF_rank_IFHG(IF_matrix):
# 计算每个直觉模糊数的得分值score=μ-v
score = IF_matrix[0] - IF_matrix[1]
# 按照得分值从大到小进行重新排序
index = np.argsort(-score) # 获取从大到小排序索引
IF_sequence_matrix = np.zeros(IF_matrix.shape) # 初始化结果矩阵
for i in range(IF_matrix.shape[1]): # 更新结果矩阵
IF_sequence_matrix[0][i] = IF_matrix[0][index[i]]
IF_sequence_matrix[1][i] = IF_matrix[1][index[i]]
return score,IF_sequence_matrix,index
def calculate_IFHG(IF_sequence_matrix,weight):
IFHG = [1,1]
for i in range(IF_sequence_matrix.shape[1]):
IFHG[0] *= np.power(IF_sequence_matrix[0][i],weight[i])
IFHG[1] *= np.power(1-IF_sequence_matrix[1][i],weight[i])
IFHG[1] = 1 - IFHG[1]
return IFHG
# 输入
IF_matrix_IFHG = np.array([[[0.51,0.45,0.40,0.35],[0.44,0.32,0.55,0.50]],
[[0.45,0.36,0.45,0.70],[0.50,0.45,0.40,0.20]],
[[0.65,0.55,0.50,0.45],[0.30,0.40,0.42,0.50]],
[[0.60,0.75,0.65,0.50],[0.25,0.15,0.25,0.35]],
[[0.55,0.50,0.55,0.55],[0.30,0.35,0.15,0.20]]])
weight_IF_IFHG = np.array([0.273,0.279,0.275,0.173])
weight_IFHG = np.array([0.2,0.3,0.3,0.2])
# S1: 计算加权直觉模糊数A_j_'
weighted_IF_matrix_IFHG = []
for item in IF_matrix_IFHG:
#print(weight_attr_4)
weighted_IF_matrix_IFHG.append(calculate_weight_IF_IFHG(item,weight_IF_IFHG))
print('\nWeight_IF_Matrix:\n',weighted_IF_matrix_IFHG)
score_IFHG = []
ranked_IF_IFHG = []
index_IFHG = []
for item in weighted_IF_matrix_IFHG:
tmp_rlt = IF_rank_IFHG(item)
score_IFHG.append(tmp_rlt[0])
ranked_IF_IFHG.append(tmp_rlt[1])
index_IFHG.append(tmp_rlt[2])
print('\nscore: {}\nRanked_IF_IFHG:{}\nIndex_IFHG: {}'.format(score_IFHG,ranked_IF_IFHG,index_IFHG))
# S4:计算IFHA
IFHG_Result = []
for item in ranked_IF_IFHG:
IFHG_Result.append(calculate_IFHG(item,weight_IFHG))
print('\nIFHG:\n',IFHG_Result)
# 再次排序
IFHG_Result_2 = np.array(IFHG_Result)
tmp_matrix = np.zeros((2,IFHG_Result_2.shape[0]))
for i in range(tmp_matrix.shape[1]):
tmp_matrix[0][i] = IFHG_Result_2[i][0]
tmp_matrix[1][i] = IFHG_Result_2[i][1]
score,final_result,index = IF_rank_IFHG(tmp_matrix)
print('\nFinal score: \n',score)
print('\nFinal Result: \n',final_result)
print('Final Index: \n',index+1)
计算结果如下:
Weight_IF_Matrix:
[array([[0.47936534, 0.41019009, 0.36497741, 0.48360979],
[0.46908949, 0.34975062, 0.58453565, 0.38100485]]), array([[0.41812686, 0.31976696, 0.41546435, 0.78128204],
[0.5308894 , 0.48684949, 0.42987987, 0.14308396]]), array([[0.62474298, 0.51315051, 0.4665165 , 0.57547049],
[0.32259709, 0.43452059, 0.45074908, 0.38100485]]), array([[0.57245475, 0.72538466, 0.62259366, 0.61899515],
[0.26958968, 0.16587426, 0.27126876, 0.25777421]]), array([[0.52056631, 0.46137125, 0.51808254, 0.66119716],
[0.32259709, 0.38168283, 0.16370246, 0.14308396]])]
score: [array([ 0.01027586, 0.06043947, -0.21955823, 0.10260494]), array([-0.11276254, -0.16708253, -0.01441552, 0.63819808]), array([0.30214589, 0.07862991, 0.01576742, 0.19446564]), array([0.30286507, 0.5595104 , 0.3513249 , 0.36122094]), array([0.19796922, 0.07968842, 0.35438008, 0.5181132 ])]
Ranked_IF_IFHG:[array([[0.48360979, 0.41019009, 0.47936534, 0.36497741],
[0.38100485, 0.34975062, 0.46908949, 0.58453565]]), array([[0.78128204, 0.41546435, 0.41812686, 0.31976696],
[0.14308396, 0.42987987, 0.5308894 , 0.48684949]]), array([[0.62474298, 0.57547049, 0.51315051, 0.4665165 ],
[0.32259709, 0.38100485, 0.43452059, 0.45074908]]), array([[0.72538466, 0.61899515, 0.62259366, 0.57245475],
[0.16587426, 0.25777421, 0.27126876, 0.26958968]]), array([[0.66119716, 0.51808254, 0.52056631, 0.46137125],
[0.14308396, 0.16370246, 0.32259709, 0.38168283]])]
Index_IFHG: [array([3, 1, 0, 2], dtype=int64), array([3, 2, 0, 1], dtype=int64), array([0, 3, 1, 2], dtype=int64), array([1, 3, 2, 0], dtype=int64), array([3, 2, 0, 1], dtype=int64)]
IFHG:
[[0.43395805570821366, 0.4460448768044488], [0.44820927151279855, 0.42877251908288205], [0.5419934328192367, 0.4010993532851309], [0.6301290295254321, 0.24683398721603678], [0.5322783547272674, 0.2573361600206997]]
Final score:
[-0.01208682 0.01943675 0.14089408 0.38329504 0.27494219]
Final Result:
[[0.63012903 0.53227835 0.54199343 0.44820927 0.43395806]
[0.24683399 0.25733616 0.40109935 0.42877252 0.44604488]]
Final Index:
[4 5 3 2 1]