1 Introduction

The first recognizable description of comparative judgements in the literature was credited to Ramon Llull, the 13th-century mystic and philosopher (Faliszewski et al. 2010; Koczkodaj et al. 2016). Thurstone (1927) underlined significant principles of comparative judgement. Saaty (1977, 1980, 1990) developed the Analytic Hierarchical Process (AHP) leading to a considerable impact on the pairwise comparison research. Whilst the AHP based on the paired ratio scale potentially leads to misapplications, Yuen (2009, 2012, 2014) proposed the Cognitive Network Process (CNP) based on the paired differential scale for pairwise comparisons, and some recent applications were presented in (Guan et al. 2019; Yuen 2022). Rezaei (2015) introduced a merely reduced form of AHP, Best Worst Method (BWM), which is gaining growing attention from researchers. The consistency is considered improved over the AHP simply because the reduced version requires fewer inputs from users, reducing the chances of making mistakes.

Mi et al. (2019) published a survey paper for BWM based on 124 publications. To list some recent articles related to BWM after 2019, Hafezalkotob et al. (2020) integrated interval values, MULTIMOORA, Borda rule and BWM for hybrid vehicle engine selection. Chen and Ming (2020) integrated rough–fuzzy approach, BWM and data envelopment analysis for smart product service module selection. Faizi et al. (2021) combined Hamacher aggregation operations for intuitionistic 2-tuple linguistic sets to BWM. Ali and Rashid (2021) applied BWM to robot selection. Oztas and Erdem (2021) applied conjoint analysis and BWM to framework selection for developing optimization algorithms. Yucesan and Gul (2021) proposed neutrosophic BWM for failure prioritization and control. Dong et al. (2021) integrated the triangular fuzzy numbers and Wan et al. (2021) integrated interval-valued trapezoidal fuzzy numbers to BWM. Jafarzadeh Ghoushchi et al. (2021) incorporated the BWM into the importance-necessity concept. Kheybari and Ishizaka (2022) proposed behavioural BWM. Ma et al. (2023) combined a granular computing-based method in the BWM framework. Qin et al. (2023) proposed a consensus model for the group BWM. Malakoutikhah et al. (2022) combined the fuzzy BWM and fuzzy cognitive map to model the factors affecting unsafe behaviours. Wan and Dong (2022), Chen et al. (2023) and Dong and Wan (2024) integrated intuitionistic fuzzy sets into BWM.

Regarding the studies of consistency measurement, the first BWM study (Rezaei 2015) collected 322 pairs of vectors for BWM and 322 matrices for AHP from 46 valid respondents (university students) for selecting the mobile phone from 4 alternatives based on 6 criteria. However, the weights produced by Rezaei, (2015) are problematic as Example 5 of this study shows that the same objective value (Model (3) or (4)) can lead to multiple versions of non-reproducible weights, and therefore, the conclusion of the hypothesis testing was unreliable. Rezaei (2016) present the linear model (Model (4) or (5)) that can produce a unique version of weights for the optimal objective value with two numerical examples to roughly show the calculation concepts. Although MS Excel Solver (https://bestworstmethod.com/software/) refers to Rezaei (2015, 2016), the software and tools were not mentioned in Rezaei (2015, 2016), whilst different numerical solvers with different algorithms of different seeds in different software packages/applications usually performed differently, no clear relationship between Model (3) or (4) and Model (5) or (4) are shown.

Regarding the recent simulation studies, Wu et al. (2022) randomly generated a total of 80,000 pairs for the criteria size from 3 to 10. The simulation was implemented in Matlab including the fmincon function. When the order size increases, the percentage of consistency ratio more than 0.1 decreases. (Liang et al. 2022) generated 10,000 pairs of ordinal-inconsistent vectors and 10,000 pairs of ordinal-consistent vectors (total size is not directly mentioned in the article). Liang et al., (2020) studied the consistency issues for the thresholds by generating a set of only 20,000 random pairs of vectors (ABO and AOW) for each case from three to nine criteria based on one- to nine-point scales. Mazurek et al. (2021) conducted a Monte Carlo Simulation of no more than 6000 instances to compare three prioritization methods, the Geometric Mean and Eigenvalue Methods implemented in C# and the BWM implemented in MS Excel Solver. For the simulations above, the results may not be reliable as the sample size is very small, which may be limited by the significant computational time using the solver. On the other hand, two proposed closed forms take only 1.27 h to complete one million instance computation with a basic laptop in a single processing. The detail of the simulation is presented in Sect. 9.

According to the literature survey to date on Aug 2023 (the release date of this first preprint in http://dx.doi.org/10.2139/ssrn.4551188), no study has provided closed-form solutions for the CR of BWM. To address these problems, the following contributions of this study have been made.

  • Section 2 presents a comprehensive review to discuss the limitations and drawbacks of BWM and the motivations of this study. To understand the properties of the optimization models which are not mentioned in the previous studies, equivalent forms of two types of Minmax models without absolute functions are proposed in Sect. 3.

  • The concepts and principles of individual edge errors and co-edge errors are presented in Sects. 4 and 5, respectively.

  • For the closed forms of the consistency ratio, the max of edge error matrix method is presented in Sect. 6, whilst the Minmax edge error determinant method is presented in Sect. 7.

  • Several two-step optimization models with several forms are presented in Sect. 8. The models provide more alternative forms for the different solvers of different algorithms to implement to guarantee the precision that the largest Minmax edge error is minimized by observing the expected unique optimal objective value.

  • In Sect 9, six numerical examples are demonstrated for the usability of the proposed solutions. Two stochastic simulations are conducted to verify the reliability of the proposed solutions. Three supplementary files for the examples and simulations are attached and can be found in Yuen (2023).

  • Section 10 discusses the results, concludes remarks and provides future research recommendations. The summary of notations is presented in Appendix section.

2 Review and motivations

2.1 Backgrounds of BWM

The BWM was proposed in Rezaei (2015, 2016) and the calculation steps are illustrated as follows:

1. Define a set of decision criteria.

2. Define the best and the worst criteria. If the best or the worst criterion is more than one, any one among them can arbitrarily be chosen.

3. Evaluate a Best-to-Others vector with numbers between 1 and 9. Reciprocals are not used.

$${A}_{B}=\left({a}_{B1},\dots ,{a}_{Bj},\dots ,{a}_{Bn}\right).$$
(1)

4. Evaluate an others-to-worst vector with numbers between 1 and 9.

$${A}_{W}={\left({a}_{1W},\dots ,{a}_{jW},\dots ,{a}_{nW}\right)}^{T}.$$
(2)

5: Solve the optimization model below to obtain the weights \(w= \left\{{w}_{j}\right\}\).

$$\begin{gathered} \min {\mathop {\max }\limits_j} \left\{ {\left| {\frac{w_B }{{w_j }} - a_{Bj} } \right|,\left| {\frac{w_j }{{w_W }} - a_{jW} } \right|} \right\} \hfill \\ {\text{S.T.}}{ } \sum \limits_j w_j = 1, \hfill \\ w_j \ge 0, \forall j. \hfill \\ \end{gathered}$$
(3)

The solution of the model above is transferred to the form below.

$$\begin{gathered} \min \xi \hfill \\ {\text{S}}.{\text{ T}}.{ } \left| {\frac{w_B }{{w_j }} - a_{Bj} } \right| \le \xi , \forall j \hfill \\ \left| {\frac{w_j }{{w_W }} - a_{jW} } \right| \le \xi , \forall j \hfill \\ \sum \limits_j w_j = 1, w_j \ge 0, \forall j. \hfill \\ \end{gathered}$$
(4)

Solving Problem (4) to obtain \({\xi }^{*}\). Alternatively,

$$\begin{gathered} \min {\mathop {\max }\limits_j} \left\{ {\left| {w_B - a_{Bj} w_j } \right|,\left| {w_j - a_{jW} w_W } \right|} \right\} \hfill \\ {\text{S}}.{\text{ T}}.{ } \sum \limits_j w_j = 1,w_j \ge 0, \forall j. \hfill \\ \end{gathered}$$
(5)

The model above is transferred to the form below.

$$\begin{gathered} \min \xi \hfill \\ {\text{S}}.{\text{ T}}.{ } \left| {w_B - a_{Bj} w_j } \right| \le \xi , \forall j \hfill \\ \left| {w_j - a_{jW} w_W } \right| \le \xi , \forall j \hfill \\ \sum \limits_j w_j = 1, w_j \ge 0, \forall j. \hfill \\ \end{gathered}$$
(6)

The consistency ratio (CR) is the ratio of \({\xi }^{*}\) to the consistent index (CI).

$$CR=\frac{{\xi }^{*}}{CI} .$$
(7)

Rezaei (2015, 2016) did not discuss the threshold values for consistency of the paired vectors until his team (Liang et al. 2020) recently discussed this topic. The discussion of thresholds for CR is beyond the scope of this research, although there are a lot of problems, which will discuss in the future study.

2.2 Problems and motivations

Several problems are identified as follows: Firstly, Models (3)–(6) have ill definitions for \({w}_{j}\ge 0\). Considering \(\frac{{w}_{B}}{{w}_{j}}\), \({w}_{j}\) cannot be 0, i.e. \({w}_{j}\ne 0\), due to the divided-by-zero error. Since \({\sum }_{j}{w}_{j}=1\) and \({w}_{j}\ne 0\), the improper constraint \({w}_{j}\ge 0\) should be changed to the constraint as below.

$$0<{w}_{j}<1, \forall j, {\text{i}}.{\text{e}}. {w}_{j}\in \left(\mathrm{0,1}\right), \forall j.$$
(8)

\(\left(\mathrm{0,1}\right)\) means from 0 to 1 exclusive. Equation (8) can avoid divided-by-zero error for the optimizer based on numerical solution.

Secondly, \(\xi\) should be bounded, i.e. \(CI\ge \xi \ge 0\) for Model (4) and \(\xi \ge 0\) for Model (5). Whilst the upper bound of Model (6) is beyond discussion in this study, the upper bound of Model (4) can refer to the simple algebraic form in Eq. (42) to guide the solver not to try the negative values for \(\xi\), but the values between the lower bound of zero and the upper bound less than or equal to the Consistency Index value with respect to the best-over-worst score \({a}_{BW}\), which is the worst case for \({\xi }^{*}\) when \({a}_{BW}\) is used for \({a}_{Bj}\) and \({a}_{jW}\).

Thirdly, the absolute function cannot be used for some optimization algorithms. To remove the absolute function, Model (4) is equivalent to Model (17) shown in Sect. 3. In addition, unlike the AHP’s reciprocal matrix, none of the matrix operations are used in BWM; transposition in Eq. (2) is completely useless or confused for Models (3) to (7), especially when the models are implemented into programming codes, and therefore, \({A}_{W}\) is defined without transposition in this study. Regarding the use of subscripts, the notations i,j,k and others are chosen in order.

Fourthly, whilst Model (3) is not equivalent to Model (5), Model (4) is not equivalent to Model (6), as they produce different objective values for the same notation\(\xi\). Only the \(\xi\) produced by solving Model (4) is\({\xi }^{*}\). In this paper, Model (3) or (4) is called CR optimization model. The simulation results in this study show that Models (3) and (4) produce different versions of weights for the same objective value \({\xi }^{*}\), whilst Models (5) and (6) should produce unique results. Two model categories are completely not equivalent. As the examples are shown in Sect. 9, it is recommended that the weights are produced by Model (5) or (6), whilst Model (3) or (4) produces \({\xi }^{*}\) for consistency only, although Models (5) and (6) are very different from Models (3) and (4) in nature, especially for their weights and objective values produced, although even the recent paper (Liang et al. 2020) with the original BWM author did not point out this.

In this study, the closed-form solutions for CR shown in Eq. (7) are developed, and thus, the optimization solver software applications to solve Model (3) or (4) are not necessary, as exact precision of \({\xi }^{*}\) can be obtained by much simpler proposed closed forms. The measurement of prioritization weights is beyond the scope of this study. Normally, most BWM prioritization methods are the reduced forms of the AHP’s prioritization methods, where the comparisons of AHP prioritizations can be found in Yuen (2009, 2010).

3 Equivalent forms without absolute functions

To understand more properties of \({\xi }^{*}\), absolute functions for Models (4) and (6) are firstly removed, and the following proposition holds.

Proposition 1 (Equivalent Forms of Absolute Function)

Let x be any real number. If \(\left|x\right|\le \xi\) and \(\xi \ge 0\), the following two inequalities hold.

$$x\le \xi ,$$
(9)
$$-x\le \xi .$$
(10)

As the absolute value of any real number is positive, \(\xi \ge 0\). With respect to \(\left|x\right|\le \xi\), if either \(x\ge 0\) or \(x\le 0\), Eqs. (9) and (10) hold. For example, let \(x=4, \xi =5\). According to Eqs. (9) and (10), either \(4\le 5\) or \(-4\le 5\) is true. Similarly, if \(x=-4\), either \(-4\le 5\) or \(-\left(-4\right)\le 5\) is true. In short, If \(\left|\pm 4\right|\le 5\), then \(\pm 4\le 5\).

Analogue to the example above, let \(x=\frac{{w}_{B}}{{w}_{i}}-{a}_{Bi}\). The inequality with the absolute function

$$\left|\frac{{w}_{B}}{{w}_{i}}-{a}_{Bi}\right|\le \xi$$
(11)

is equivalent to two forms without the absolute function below:

$$\frac{{w}_{B}}{{w}_{i}}-{a}_{Bi}\le \xi ,$$
(12)
$$-\frac{{w}_{B}}{{w}_{i}}+{a}_{Bi}\le \xi .$$
(13)

Similarly, the inequality with the absolute function

$$\left|\frac{{w}_{i}}{{w}_{W}}-{a}_{iW}\right|\le \xi$$
(14)

is equivalent to two forms without the absolute function below:

$$\frac{{w}_{i}}{{w}_{W}}-{a}_{iW}\le \xi ,$$
(15)
$$-\frac{{w}_{i}}{{w}_{W}}+{a}_{iW}\le \xi .$$
(16)

Finally, Model (4) is equivalent to

$$\begin{gathered} \min \xi \hfill \\ {\text{S.T.}}{ }\frac{w_B }{{w_i }} - a_{Bi} \le \xi ,{ }\forall i \hfill \\ - \frac{w_B }{{w_i }} + a_{Bi} \le \xi , \forall i \hfill \\ \frac{w_i }{{w_W }} - a_{iW} \le \xi , \forall i \hfill \\ - \frac{w_i }{{w_W }} + a_{iW} \le \xi , \forall i \hfill \\ \sum \limits_i w_i = 1, 0 \le \xi \le CI, 0 < w_i < 1, \forall i. \hfill \\ \end{gathered}$$
(17)

Similarly, Model (6) is equivalent to

$$\begin{gathered} \min \xi \hfill \\ {\text{S}}.{\text{ T}}.{ }w_B - w_i a_{Bi} \le \xi ,{ }\forall i \hfill \\ - w_B + w_i a_{Bi} \le \xi , \forall i \hfill \\ w_i - w_W a_{iW} \le \xi , \forall i \hfill \\ - w_i + w_W a_{iW} \le \xi , \forall i \hfill \\ \sum \limits_i w_i = 1, \xi \ge 0, 0 < w_i < 1, \forall i. \hfill \\ \end{gathered}$$
(18)

For the advantage, Model (17) is easier to be implemented with most software packages than Model (4) as treating absolute function is not needed anymore for some optimization algorithms. Rezaei (2015, 2016) did not define a meaningful name for the notation \(\xi\) or \({\xi }^{*}\) in Model (4). On the basis of the mathematical formation in the Model (4), \({\xi }^{*}\) is called the Minmax Edge Error (MEE) in this paper, which is the minimum of maximum absolute distance between \(\frac{{w}_{B}}{{w}_{j}}\) and \({a}_{Bj}\), as well as \(\frac{{w}_{j}}{{w}_{W}}\) and \({a}_{jW}\), for all j. More properties are explored for the edge errors in the following sections.

4 Individual edge errors

If a pair of best and worst vectors, \({A}_{B}\) and \({A}_{W}\), are perfectly consistent, the following equality holds, and vice versa.

$${a}_{Bi}{a}_{iW}={a}_{BW},\forall i\in \left\{1,\ldots ,n\right\}.$$
(19)

The inconsistency is induced if one of two conditions below is satisfied.

$${a}_{Bi}{a}_{iW}>{a}_{BW},\exists i;$$
(20)
$${a}_{Bi}{a}_{iW}<{a}_{BW},\exists i.$$
(21)

Let an Individual Edge Error (IEE) for \({c}_{i}\) in comparison with \({c}_{B}\) and \({c}_{W}\) be \({\xi }_{i}\). If \({a}_{Bi}{a}_{iW}>{a}_{BW}\), \({a}_{Bi}\) and \({a}_{iW}\) are decreased by \({\xi }_{i,}\) respectively, and \({a}_{BW}\) is increased by \({\xi }_{i}\), to achieve an equality as below:

$$\left({a}_{Bi}-{\xi }_{i}\right)\left({a}_{iW}-{\xi }_{i}\right)=\left({a}_{BW}+{\xi }_{i}\right).$$
(22)

Expand the form above to have a quadratic equation below:

$${\xi }_{i}^{2}-\left(1+{a}_{Bi}+{a}_{iW}\right){\xi }_{i}+\left({{a}_{Bi}{a}_{iW}-a}_{BW}\right)=0.$$
(23)

On the other hand, if \({a}_{Bi}{a}_{iW}<{a}_{BW}\), \({a}_{Bi}\) and \({a}_{iW}\) are decreased by \({\xi }_{i},\) respectively, and \({a}_{BW}\) is increased by\({\xi }_{i}\), to achieve an equality as below:

$$\left({a}_{Bi}+{\xi }_{i}\right)\left({a}_{iW}+{\xi }_{i}\right)=\left({a}_{BW}-{\xi }_{i}\right).$$
(24)

Expand the form above to have a quadratic equation as below:

$${\xi }_{i}^{2}+\left(1+{a}_{Bi}+{a}_{iW}\right){\xi }_{i}+\left({a}_{Bi}{a}_{iW}-{a}_{BW}\right)=0.$$
(25)

To find the \({\xi }_{i}\) for the two equality relationships above, Theorem 1 holds.

Theorem 1 (Individual Edge Error).

The Individual Edge Error (IEE) for \({c}_{j}\) in comparisons with \({c}_{B}\) and \({c}_{W}\) is obtained as below:

$${\xi }_{i}=\frac{1}{2}\left|\left(1+{a}_{Bi}+{a}_{iW}\right)-\sqrt{{\left(1+{a}_{Bi}+{a}_{iW}\right)}^{2}-4\left({{a}_{Bi}{a}_{iW}-a}_{BW}\right)}\right|,\forall i.$$
(26)

Precisely, the absolute form above is equivalent to the piecewise equation below with specifying conditions:

$${\xi }_{i}=\left\{\begin{array}{c}\frac{-\left(1+{a}_{Bi}+{a}_{iW}\right)+\sqrt{{\left(1+{a}_{Bi}+{a}_{iW}\right)}^{2}-4\left({{a}_{Bi}{a}_{iW}-a}_{BW}\right)}}{2}, {a}_{Bi}{a}_{iW}-{a}_{BW}<0 \\ \frac{\left(1+{a}_{Bi}+{a}_{iW}\right)-\sqrt{{\left(1+{a}_{Bi}+{a}_{iW}\right)}^{2}-4\left({{a}_{Bi}{a}_{iW}-a}_{BW}\right)}}{2}, {a}_{Bi}{a}_{iW}-{a}_{BW}>0 \\ 0 { ,a}_{Bi}{a}_{iW}={a}_{BW} \end{array},\forall i.\right.$$
(27)

Proof.

$$\mathrm{Let }\,{\gamma }_{i1}=1,$$
(28)
$${\gamma {\prime}}_{i2}=\left\{\begin{array}{c} {\gamma }_{i2}\\ - {\gamma }_{i2}\end{array}\right.=\left\{\begin{array}{c} \left(1+{a}_{Bi}+{a}_{iW}\right), \quad {\gamma }_{i3}\le 0\\ -\left(1+{a}_{Bi}+{a}_{iW}\right), \quad {\gamma }_{i3}\ge 0\end{array},\right.$$
(29)
$${\gamma }_{i3}={{a}_{Bi}{a}_{iW}-a}_{BW}, \forall i\in \left[1,\ldots ,n\right].$$
(30)

To substitute the above equations to Eqs. (23) and (25),

$${\gamma }_{i1}{\xi }_{i}^{2}+{\gamma {\prime}}_{i2}{\xi }_{i}+{\gamma }_{i3}=0.$$
(31)

To solve the above quadratic equation to have two roots,

$${\xi {\prime}}_{i}=\frac{-{\gamma {\prime}}_{i2}\pm \sqrt{{\gamma {\prime}}_{i2}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}}{2{\gamma }_{i1}}=\frac{1}{2}\left(-{\gamma {\prime}}_{i2}\pm \sqrt{{\gamma {\prime}}_{i2}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}\right).$$
(32)

As the edge error is positive and minimized,

$${\xi }_{i}={\text{min}}(\left|{{\xi }{\prime}}_{i}\right|).$$
(33)

Precisely, without absolute function, as

$$\frac{1}{2}\left(-{\gamma }_{i2}-\sqrt{{\gamma }_{i2}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}\right)\ge \frac{1}{2}\left(-{\gamma }_{i2}+\sqrt{{\gamma }_{i2}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}\right), {\gamma }_{i3}\le 0,$$
(34)
$$\frac{1}{2}\left({\gamma }_{i2}-\sqrt{{\gamma }_{i2}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}\right)\le \frac{1}{2}\left({\gamma }_{i2}+\sqrt{{\gamma }_{i2}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}\right), {\gamma }_{i3}\ge 0,$$
(35)

the \({\text{min}}(\left|{{\xi }^{\mathrm{^{\prime}}}}_{i}\right|)\) is

$${\xi }_{i}=\left\{\begin{array}{c}\frac{1}{2}\left(-{\gamma }_{i2}+\sqrt{{{\gamma }_{i2}}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}\right), {\gamma }_{i3}\le 0\\ \frac{1}{2}\left({\gamma }_{i2}-\sqrt{{{\gamma }_{i2}}^{2}-4{\gamma }_{i1}{\gamma }_{i3}}\right), { \gamma }_{i3}\ge 0\end{array}\right. .$$
(36)

Therefore, Eqs. (26) and (27) hold.□

The piecewise form of three cases of Eq. (27) can be reduced to two cases by removing the third case with adding equality to the conditions, e.g. in Eq. (36). The advantage of the piecewise form of three cases of Eq. (27) is that the Case 3 can be determined immediately.

Individual Edge Error (IEE) for \({c}_{j}\) compared with \({c}_{B}\) and \({c}_{W}\) is independent of the rating scores with respect to the other criteria compared. However, if another criterion is involved, an impact to the MEE may be induced, and therefore, the concept of co-edge errors is established in the next section.

5 Co-edge errors

If the rating scores are perfectly consistent, the following equality holds.

$${a}_{Bi}{a}_{iW}={a}_{Bj}{a}_{jW}={a}_{BW}.$$
(37)

If there is inconsistency, the equality above does not hold. In addition to the IEE introduced in the previous section, the concept of co-edge error \({\xi }_{ij}\) is introduced. Co-edge error \({\xi }_{ij}\) is the multiplication discrepancy between \({a}_{Bi}{a}_{iW}\) and \({a}_{Bj}{a}_{jW}\) satisfying the following two conditions.

If \({a}_{Bi}{a}_{iW}\le {a}_{Bj}{a}_{jW}\), both \({a}_{Bi}\) and \({a}_{iW}\) are increased by \({\xi }_{ij}\), and both \({a}_{Bj}\) and \({a}_{jW}\) are decreased by \({\xi }_{ij}\), to achieve an equality as below:

$$\left({a}_{Bi}+{\xi }_{ij}\right)\left({a}_{iW}+{\xi }_{ij}\right)=\left({a}_{Bj}-{\xi }_{ij}\right)\left({a}_{jW}-{\xi }_{ij}\right).$$
(38)

If \({a}_{Bi}{a}_{iW}\ge {a}_{Bj}{a}_{jW}\), both \({a}_{Bi}\) and \({a}_{iW}\) are decreased by \({\xi }_{ij}\), and both \({a}_{Bj}\) and \({a}_{jW}\) are decreased by \({\xi }_{ij}\), to achieve an equality as below:

$$\left({a}_{Bi}-{\xi }_{ij}\right)\left({a}_{iW}-{\xi }_{ij}\right)=\left({a}_{Bj}+{\xi }_{ij}\right)\left({a}_{jW}+{\xi }_{ij}\right).$$
(39)

To find the \({\xi }_{ij}\) for the equality relationships above, Theorem 2 holds.

Theorem 2 (Co-Edge Error)

A Co-Edge Error (CEE) with respect to \({c}_{i}\) and \({c}_{j}\) is computed by the form below:

$${\xi }_{ij}=\left\{\begin{array}{c}\frac{{a}_{Bi}{a}_{iW}-{a}_{Bj}{a}_{jW}}{{a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}},{a}_{Bi}{a}_{iW}\ge {a}_{Bj}{a}_{jW}\\ \frac{{a}_{Bj}{a}_{jW}-{a}_{Bi}{a}_{iW}}{{a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}},{a}_{Bi}{a}_{iW}\le {a}_{Bj}{a}_{jW}\end{array}\right..$$
(40)

Or the piecewise equation above is equivalent to the below form without specifying conditions:

$${\xi }_{ij}=\frac{\left|{a}_{Bi}{a}_{iW}-{a}_{Bj}{a}_{jW}\right|}{{a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}}.$$
(41)

Proof.

If \({a}_{Bi}{a}_{iW}\le {a}_{Bj}{a}_{jW}\), rearrange Eq. (38) as below:

$${\xi }_{ij}^{2}+\left({a}_{Bi}+{a}_{iW}\right){\xi }_{ij}+{a}_{Bi}{a}_{iW}={\xi }_{ij}^{2}-\left({a}_{Bj}+{a}_{jW}\right){\xi }_{ij}+{a}_{Bj}{a}_{jW}$$
$$\left({a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}\right){\xi }_{ij}={a}_{Bj}{a}_{jW}-{a}_{Bi}{a}_{iW}$$
$${\xi }_{ij}=\frac{{a}_{Bj}{a}_{jW}-{a}_{Bi}{a}_{iW}}{\left({a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}\right)}.$$

If \({a}_{Bi}{a}_{iW}\ge {a}_{Bj}{a}_{jW}\), rearrange Eq. (39) as below:

$${\xi }_{ij}^{2}-\left({a}_{Bi}+{a}_{iW}\right){\xi }_{ij}+{a}_{Bi}{a}_{iW}={\xi }_{ij}^{2}+\left({a}_{Bj}+{a}_{jW}\right){\xi }_{ij}+{a}_{Bj}{a}_{jW}$$
$${a}_{Bi}{a}_{iW}-{a}_{Bj}{a}_{jW}=\left({a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}\right){\xi }_{ij}$$
$${\xi }_{ij}=\frac{{a}_{Bi}{a}_{iW}-{a}_{Bj}{a}_{jW}}{{a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}}.$$

Therefore, Form (40) holds. As \({\xi }_{ij}\ge\) 0, Eq. (41) also holds.□

6 Max of edge error matrix method

The consistency ratio (CR) is the ratio of Minimax Edge Error (MEE or \({\xi }^{*}\)) to the consistent index (CI), i.e. \(CR=\frac{{\xi }^{*}}{CI}\). The closed-form solution of CI is derived by Eq. (42) of Theorem 3, whilst the closed-form solution of Minmax Edge Error \({\xi }^{*}\) is derived by Eq. (44) of Theorem 4. The details are presented as below.

6.1 Closed-form solution of consistency index

The BWM applications only refer to a CI table stated in (Rezaei 2015, 2016) for the CI with respect to \({a}_{BW}\). In fact, the CI can be derived from the simple form in Eq. (42) of Theorem 3 stated as below.

Theorem 3 (Consistency Index of BWM)

The Consistency Index of \({a}_{BW}\) is computed by the form below:

$${CI}_{{a}_{BW}}=CI\left({a}_{BW}\right)=\frac{1}{2}\left(1+2{a}_{BW}-\sqrt{8{a}_{BW}+1}\right).$$
(42)

Proof.

From Eq. (27), if \({a}_{Bi}{a}_{iW}-{a}_{BW}>0\), then.

$${\xi }_{i}=\frac{\left(1+{a}_{Bi}+{a}_{iW}\right)-\sqrt{{\left(1+{a}_{Bi}+{a}_{iW}\right)}^{2}-4\left({{a}_{Bi}{a}_{iW}-a}_{BW}\right)}}{2}.$$

Substitute \({a}_{Bi}={a}_{iW}={a}_{BW}\), the worst case, to the form above to obtain \(CI\left({a}_{BW}\right)\) below:

$$CI\left({a}_{BW}\right)=\frac{\left(1+{a}_{BW}+{a}_{BW}\right)-\sqrt{{\left(1+{a}_{BW}+{a}_{BW}\right)}^{2}-4\left({a}_{BW}{a}_{BW}-{a}_{BW}\right)}}{2}$$
$$CI\left({a}_{BW}\right)=\frac{\left(1+2{a}_{BW}\right)-\sqrt{{\left(1+2{a}_{BW}\right)}^{2}-4{a}_{BW}^{2}+4{a}_{BW}}}{2}$$
$$CI\left({a}_{BW}\right)=\frac{\left(1+2{a}_{BW}\right)-\sqrt{4{a}_{BW}^{2}+4{a}_{BW}+1-4{a}_{BW}^{2}+4{a}_{BW}}}{2}$$
$$CI\left({a}_{BW}\right)=\frac{1}{2}\left(\left(1+2{a}_{BW}\right)-\sqrt{8{a}_{BW}+1}\right).$$

Thus, Eq. (42) holds. □

To have the CR, CI is obtained as above, and the formulation and calculation of \({\xi }^{*}\) are discussed in the following section.

6.2 Closed-form solution of minmax edge error

\({\xi }^{*}\) can be obtained by finding the largest value of the elements in the Edge Error Matrix (EEM) denoted by \(\ddot{\xi }\) of the form below:

$$\ddot{\xi }=\left\{{\ddot{\xi }}_{ij}:{\ddot{\xi }}_{ij}=\left\{\begin{array}{c}{\xi }_{i} , i=j\\ {\xi }_{ij},i\ne j\end{array}\right., \forall i,j\in \left[1,\ldots ,n\right]\right\}.$$
(43)

The size of largest values is at least one. \(\ddot{\xi }\) is the \(n\times n\) symmetric matrix. The diagonal elements where \(i=j\) are filled by\({\xi }_{i}\),\(\forall i\), which are obtained by Eq. (26) or (27). The non-diagonal elements are filled by \({\xi }_{ij}\), \(i\ne j\),\(\forall i,\forall j\), which are obtained by Eq. (40) or (41). Elements in the upper triangular matrix of \(\ddot{\xi }\), denoted by\({\ddot{\xi }}^{+}\), are the same as their corresponding positions in lower triangular matrix of\(\ddot{\xi }\), denoted by \({\ddot{\xi }}^{-}\). Thus, \(\ddot{\xi }\) is a symmetric matrix, i.e.\({\xi }_{ij}={\xi }_{ji},\forall i,j\). Theorem 4 is established on top of Theorems 1 and 2 to compute the EEM.

Theorem 4 (Max of Edge Error Matrix Method: \({\xi }^{*}=max\left({\ddot{\xi }}^{+}\right)\))

The Minmax edge error is the largest value of the set of all individual edge errors and all co-edge errors, which can be formed by the upper triangular edge error matrix.

$${\xi }^{*}=max\left({\ddot{\xi }}^{+}\right)=max\left(\left\{{\xi }_{i}\right\}, \left\{{\xi }_{ij}\right\}\right)=max\left\{{\ddot{\xi }}_{ij}^{+}:{\ddot{\xi }}_{ij}^{+}=\left\{\begin{array}{c}{\xi }_{i} , i=j\\ {\xi }_{ij},i\ne j\end{array}\right., \forall j\in \left[i,\ldots ,n\right],\forall i\in \left[1,\ldots ,n\right]\right\}$$
$${\xi }_{i}=\frac{1}{2}\left|\left(1+{a}_{Bi}+{a}_{iW}\right)-\sqrt{{\left(1+{a}_{Bi}+{a}_{iW}\right)}^{2}-4\left({{a}_{Bi}{a}_{iW}-a}_{BW}\right)}\right|,\forall i$$
(44)
$${\xi }_{ij}=\frac{\left|{a}_{Bi}{a}_{iW}-{a}_{Bj}{a}_{jW}\right|}{{a}_{Bi}+{a}_{iW}+{a}_{Bj}+{a}_{jW}},\forall j\in \left[i+1,\ldots ,n\right],\forall i\in \left[1,\ldots ,n\right].$$

Proof.

\({\xi }_{i}\) and \({\xi }_{ij}\) have been proved in Theorems 1 and 2, respectively, with alternative forms without absolute function. In order to have Theorem 4, it is essential to show how Theorems 1 and 2 are related to Model (4). Let \(\left({i}^{*},{j}^{*}\right)=argmax\left({\ddot{\xi }}^{+}\right)\), which occurs either only at i*, where i* = j*, or between i* and j*, where i* ≠ j*. If \({\xi }^{*}\) occurs at i*, there are two scenarios shown in Cases 1 and 2. If \({\xi }^{*}\) occurs at between i* and j*, there are two scenarios shown in Cases 3 and 4.

Case 1 (\({a}_{B{i}^{*}}{a}_{{i}^{*}W}<{a}_{BW}\)):

If \({\xi }^{*}\) occurs at \({i}^{*}\) such that \({a}_{B{i}^{*}}{a}_{{i}^{*}W}<{a}_{B\left(i\ne {i}^{*}\right)}{a}_{\left(i\ne {i}^{*}\right)W},\forall i\), substitute \({\xi }^{*}={\xi }_{{i}^{*}}={\xi }_{i}\) to Eq. (24) to have

$$\left({a}_{B{i}^{*}}+{\xi }^{*}\right)\left({a}_{{i}^{*}W}+{\xi }^{*}\right)=\left({a}_{BW}-{\xi }^{*}\right),$$
(45)

substituted by

$$\frac{{w}_{B}}{{w}_{{i}^{*}}}={a}_{B{i}^{*}}+{\xi }^{*}\,\,\mathrm{and }\,\,\frac{{w}_{{i}^{*}}}{{w}_{W}}={a}_{{i}^{*}W}+{\xi }^{*}$$
(46)

to have

$$\left(\frac{{w}_{B}}{{w}_{{i}^{*}}}\right)\left(\frac{{w}_{{i}^{*}}}{{w}_{W}}\right)=\frac{{w}_{B}}{{w}_{W}}=\left({a}_{BW}-{\xi }^{*}\right).$$
(47)

Therefore, if \({\xi }^{*}={\xi }_{{i}^{*}}\ge {\xi }_{i}\),\(i\ne {i}^{*},\forall i\), then Eq. (47) equals Eq. (45). We can see the relationship among \({w}_{{i}^{*}}\),\({w}_{B}\), \({w}_{W}\) and \({a}_{B{i}^{*}}\),\({a}_{{i}^{*}W}\), \({a}_{{i}^{*}W}\) and \({\xi }^{*}\).

Case 2 (\({a}_{B{i}^{*}}{a}_{{i}^{*}W}>{a}_{BW}\)):

\({\xi }^{*}\) occurs at \({i}^{*}\) such that \({a}_{B{i}^{*}}{a}_{{i}^{*}W}>{a}_{B\left(i\ne {i}^{*}\right)}{a}_{\left(i\ne {i}^{*}\right)W},\forall i\). From Eq. (22),

$$\left({a}_{B{i}^{*}}-{\xi }^{*}\right)\left({a}_{{i}^{*}W}-{\xi }^{*}\right)=\left({a}_{BW}+{\xi }^{*}\right),$$
(48)

substituted by

$$\frac{{w}_{B}}{{w}_{{i}^{*}}}={a}_{B{i}^{*}}-{\xi }^{*}\,\,\mathrm{and }\frac{{w}_{{i}^{*}}}{{w}_{W}}={a}_{{i}^{*}W}-{\xi }^{*}$$
(49)

to have

$$\left(\frac{{w}_{B}}{{w}_{{i}^{*}}}\right)\left(\frac{{w}_{{i}^{*}}}{{w}_{W}}\right)=\frac{{w}_{B}}{{w}_{W}}=\left({a}_{BW}+{\xi }^{*}\right).$$
(50)

Therefore, the relationship between Eqs. (48) and 50) is shown.

Case 3 (\({a}_{B{i}^{*}}{a}_{{i}^{*}W}<{a}_{BW}<{a}_{B{j}^{*}}{a}_{{j}^{*}W}\)):

\({\xi }^{*}\) occurs at i* and \({j}^{*}\) such that \({a}_{B{i}^{*}}{a}_{{i}^{*}W}<{a}_{B{j}^{*}}{a}_{{j}^{*}W}\). From Eq. (38),

$$\left({a}_{B{i}^{*}}+{\xi }^{*}\right)\left({a}_{{i}^{*}W}+{\xi }^{*}\right)=\left({a}_{B{j}^{*}}-{\xi }^{*}\right)\left({a}_{j*W}-{\xi }^{*}\right),$$
(51)

substituted by

$$\frac{{w}_{B}}{{w}_{{i}^{*}}}={a}_{B{i}^{*}}+{\xi }^{*},\frac{{w}_{i}*}{{w}_{W}}={a}_{{i}^{*}W}+\xi *,\frac{{w}_{B}}{{w}_{j*}}={a}_{Bj*}-{\xi }^{*}\,\,\mathrm{and }\,\,\frac{{w}_{j}*}{{w}_{W}}={a}_{j*W}-{\xi }^{*}$$
(52)

to have

$$\left(\frac{{w}_{B}}{{w}_{{i}^{*}}}\right)\left(\frac{{w}_{{i}^{*}}}{{w}_{W}}\right)=\left(\frac{{w}_{B}}{{w}_{{j}^{*}}}\right)\left(\frac{{w}_{{j}^{*}}}{{w}_{W}}\right)=\frac{{w}_{B}}{{w}_{W}}=\left({a}_{B{j}^{*}}-{\xi }^{*}\right)\left({a}_{{j}^{*}W}-{\xi }^{*}\right)=\left({a}_{B{i}^{*}}+\xi *\right)\left({a}_{{i}^{*}W}+{\xi }^{*}\right).$$
(53)

This means that the above equality holds only if \(i={i}^{*}\) and \(j={j}^{*}\).

Case 4 (\({a}_{Bi*}{a}_{i*W}>{a}_{BW}>{a}_{Bj*}{a}_{j*W}\)):

\({\xi }^{*}\) occurs at j* and i* such that \({a}_{B{i}^{*}}{a}_{{i}^{*}W}>{a}_{Bj*}{a}_{j*W}\). From Eq. (39),

$$\left({a}_{B{i}^{*}}-{\xi }^{*}\right)\left({a}_{{i}^{*}W}-{\xi }^{*}\right)=\left({a}_{B{j}^{*}}+{\xi }^{*}\right)\left({a}_{{j}^{*}W}+{\xi }^{*}\right),$$
(54)

substituted by

$$\frac{{w}_{B}}{{w}_{{i}^{*}}}={a}_{Bi*}-{\xi }^{*}, \frac{{w}_{i}*}{{w}_{W}}={a}_{{i}^{*}W}-{\xi }^{*}, \frac{{w}_{B}}{{w}_{j*}}={a}_{B{j}^{*}}+{\xi }^{*}\,\,\mathrm{and }\,\,\frac{{w}_{j}*}{{w}_{W}}={a}_{{j}^{*}W}+{\xi }^{*}$$
(55)

to have

$$\left(\frac{{w}_{B}}{{w}_{{i}^{*}}}\right)\left(\frac{{w}_{{i}^{*}}}{{w}_{W}}\right)=\left(\frac{{w}_{B}}{{w}_{{j}^{*}}}\right)\left(\frac{{w}_{{j}^{*}}}{{w}_{W}}\right)=\frac{{w}_{B}}{{w}_{W}}=\left({a}_{B{i}^{*}}-{\xi }^{*}\right)\left({a}_{{i}^{*}W}-{\xi }^{*}\right)=\left({a}_{B{j}^{*}}+{\xi }^{*}\right)\left({a}_{{j}^{*}W}+{\xi }^{*}\right).$$
(56)

The above equality holds if \(i={i}^{*}\) and \(j={j}^{*}\).

In short, Minmax Edge Error occurs if one of the above four conditions holds such that \({\xi }^{*}=max\left(\left\{{\xi }_{i}\right\}, \left\{{\xi }_{ij}\right\}\right).\)

Theorem 4 shows the exhaustive approach to find the Minmax Edge Error, i.e. \(IEE=max\left(EEM\right)\). Firstly, Individual Edge Errors for all criteria are calculated. Secondly, co-edge errors for all pairs among the criteria are calculated. Finally, MEE is the maximal value of the individual edge errors and co-edge errors. The computation size of Individual Edge Errors is n, whilst the computation size of co-edge errors is \(\frac{1}{2}\left(n-1\right)\left(n-2\right)\), and \({\xi }_{ij}={\xi }_{ji}, \forall i,j\). The advantage of the exhaustive method is that the Edge Error Matrix can provide an overview of the edge errors. If only Minmax Edge Error is introduced, a smarter method may be needed to avoid unnecessary computation, and the determinant method for MEE is introduced in the next section by investigating more properties of Theorem 4.

7 Minmax edge error determinant method

Theorem 4 is the exhaustive search for the upper triangle EEM that requires \(\frac{1}{2}n\left(n-1\right)\) calculations. The MEE determinant method is proposed to find the \({\xi }^{*}\) by initially determining locations inducing \({\xi }^{*}\). Algorithm 1 is presented to show the determinant method to find MEE. Algorithm 1 only concerns the MEE without providing the information for the other edge errors shown in the edge error matrix. For the definitions in this paper, the best criterion is located at B, the worst criterion is located at W, and the rest should be called “others” if the rest size is plural, or “another” if the size is singular.

For the comparison located at best criterion, i.e. \(i=B\),

$${{a}_{BB}{a}_{BW}-a}_{BW}=0.$$
(57)

For the comparison located at best criterion, i.e. \(i=W\),

$${a}_{BW}{a}_{WW}-{a}_{BW}=0.$$
(58)

By Theorem 1, both IEE results in 0, i.e. \({\xi }_{B}={\xi }_{W}=0\). By Theorem 2, both CEE results in 0, i.e. \({\xi }_{BW}={\xi }_{WB}=0\). In addition, \({\xi }_{i}\ge \left|{\xi }_{iW}\right|\) or \({\xi }_{i}\ge \left|{\xi }_{Bi}\right|\). Thus, when finding the locations of criteria for \({\xi }^{*}\), rating scores at B in \({A}_{B}\) and W in \({A}_{W}\) can be removed. In other words, only the others in \({A}_{B}\) and \({A}_{W}\) are considered. If \(n=3\), the size of the others is 1, and thus, MEE is the IEE based on paired comparisons related to the other criterion. When \(n>3\), both IEE and CEE are considered.

According to Eq. (27) of Theorem 1, five properties of IEE concerning inequality and equality are further inducted as below. To better understand the properties, examples of pair scores for their relationships are demonstrated in Fig. 1, which is further studied in Example 6 of Sect. 9.

  1. 1.

    If \({a}_{Bi}{a}_{iW}\) = \({a}_{Bj}{a}_{jW}\) and \({a}_{Bi}+{a}_{iW}\) > \({a}_{Bj}+{a}_{jW}\), then \({\xi }_{i}<{\xi }_{j}\).

  2. 2.

    If \({a}_{Bi}{a}_{iW}{-a}_{BW}<0\), \({a}_{Bi}{a}_{iW}\) < \({a}_{Bj}{a}_{jW}\) and \({a}_{Bi}+{a}_{iW}\) = \({a}_{Bj}+{a}_{jW}\), then \({\xi }_{i}>{\xi }_{j}\).

  3. 3.

    If \({a}_{Bi}{a}_{iW}{-a}_{BW}>0\), \({a}_{Bi}{a}_{iW}\) < \({a}_{Bj}{a}_{jW}\) and \({a}_{Bi}+{a}_{iW}\) = \({a}_{Bj}+{a}_{jW}\), then \({\xi }_{i}<{\xi }_{j}\).

  4. 4.

    If \(\left|{a}_{Bi}{a}_{iW}{-a}_{BW}\right|\)< \(\left|{a}_{Bj}{a}_{jW}-{a}_{BW}\right|\) and \({a}_{Bi}+{a}_{iW}\) = \({a}_{Bj}+{a}_{jW}\), then \({\xi }_{i}<{\xi }_{j}\).

  5. 5.

    Swapping a pair of scores at i, i.e. \(\left({a}_{Bi},{a}_{iW}\right)\)= \(\left({a}_{iW},{a}_{Bi}\right)\), has no impact to \({\xi }_{i}\).

Fig. 1
figure 1

Examples of the relationships of five properties of IEE

From the properties above, \({a}_{Bk}{a}_{kW}\) and \({a}_{Bk}+{a}_{kW}\) are the core parts for the determination. These properties are essentially used to determine the location of MEE. The highest IEE is more likely to be MEE as the highest CEE is also required to check. In addition, considering Eqs. (40) and (41) from Theorem 2 and the simulation results performed in Sect. 9, the determinant values of others are defined below:

$${D}_{k}=\frac{{a}_{Bk}{a}_{kW}-{a}_{BW}}{{a}_{Bk}+{a}_{kW}-1},\forall k\in \left[1,\ldots ,p\right], {a}_{BW}\le 9.$$
(59)

The value p is the size of the other criteria excluding the best and worst criteria. In short, when the numerator, \({a}_{Bk}+{a}_{kW}\), is higher and the pure value of denominator, \(\left|{a}_{Bk}{a}_{kW}-{a}_{BW}\right|\), is lower, chance of \({\xi }_{k}\) to be \({\xi }^{*}\) is higher. The \(-1\) is selected based on the simulation results of one million random samples in Sect. 9. \(+1\) or 0 does not produce accurate MEE results. Without absolute value, the determinant value has direction, and so the minimum function is used to address Property 2 when \({D}_{k}\) is negative and maximum function is used to address Property 3 when \({D}_{k}\) is positive. According to the simulation, the highest CEE is located between a pair with the least negative \({D}_{i}\) and the highest positive \({D}_{j}\), when \({a}_{BW}\ge 9\). When \({a}_{BW}>9\), Eq. (59) may not be valid. Finally, Algorithm 1 is formed to determine \({\xi }^{*}\) with the least computation.

For Algorithm 1, when n > 3, the extra little computation is to find the D to avoid computing all CEEs and IEEs. If \({a}_{Bj}{a}_{jW}<{a}_{Bi}{a}_{iW}\) and \({a}_{Bi}{a}_{iW}-{a}_{BW}<0\), then \({\xi }_{j}>{\xi }_{i}\), and Eq. (60) is used. If \({a}_{Bj}{a}_{jW}>{a}_{Bi}{a}_{iW}\) and \({a}_{Bi}{a}_{iW}-{a}_{BW}>0\), then \({\xi }_{j}>{\xi }_{i}\), and Eq. (61) is used. If \({a}_{Bi}{a}_{iW}-{a}_{BW}<0\) and \({a}_{Bj}{a}_{jW}-{a}_{BW}>0\), then \({\xi }^{*}\) is determined by Eq. (62). Case 3 includes Cases 1 and 2 including Case 0. Basically, Case 3 can be used for general purpose, but not the fastest one to determine \({\xi }^{*}\) when the cases fit for Cases 0 to 2. The demonstrations are shown in Sect. 9.

Algorithm 1 (\({\varvec{d}}{\varvec{e}}{\varvec{t}}{\varvec{M}}{\varvec{E}}{\varvec{E}}\left({{\varvec{A}}}_{{\varvec{B}}},{{\varvec{A}}}_{{\varvec{W}}}\right)\): Determinant Method for \({\xi }^{*}\)).

Input: paired vectors: \({A}_{B}\) and \({A}_{W}\) such that \({a}_{BW}\le 9\)

Step 1: exclude B and W in in \({A}_{B}\) and \({A}_{W}\) to form \({A{\prime}}_{B}\) and \({A{\prime}}_{W}\), where the new size of each vector is\(p=n-2\). The criteria indices of \({A{\prime}}_{B}\) and \({A{\prime}}_{W}\) are updated

Step 2: if \(p=1\), i.e., \(n=3\), compute \({\xi }^{*}={\xi }_{1}\), and go to return \({\xi }^{*}\). Otherwise, go to the next step

Step 3: compute \(D = \left\{\frac{{a}_{Bk}{a}_{kW}-{a}_{BW}}{{a}_{Bk}+{a}_{kW}-1}:\forall k\in \left[1,\ldots ,p\right]\right\}\)

Step 4: compute \({\xi }^{*}\) with respect to different cases

Case 0: if all elements in D are zero, i.e. \(min(D)=min(D)=0\), then \({\xi }^{*}=0\)

Case 1: if all elements in D are positive, i.e. \(min(D)\ge 0\), find the index set of highest values in D to calculate the MEE

\({\xi }^{*}=\underset{i\in {S}^{+}}{\mathit{max}}({\xi }_{i}), {S}^{+}=argmax(D)\) (60)

Case 2: if all elements in D are negative, i.e. \(max(D)\le 0\), find the index set of lowest values in D to calculate the MEE

\({\xi }^{*}=\underset{i\in {\mathit{ S}}^{-}}{\mathit{max}}({\xi }_{i}), { S}^{-}=argmin(D)\) (61)

Case 3: if elements in D contain both positive and negative numbers, i.e. \(min(D)<0\) and \(max(D)>0\), calculate the MEE

\({\xi }^{*}=max\left(\left\{{\xi }_{i}:i\in \left\{{S}^{+}\cup {S}^{-}\right\}\right\},\left\{{\xi }_{ij}:i\in {S}^{+},j\in {S}^{-}\right\}\right), {S}^{+}=argmax(D), { S}^{-}=argmin(D)\) (62)

Return \({\xi }^{*}\)

8 Two-step optimization models

As the closed-form solution of Minmax Edge Error can be obtained by Theorem 4 or Algorithm 1, the Minmax Model (3) and its equivalent Model (4) can be improved and converted to two-step optimization models to find the weights with the exact optimal objective value of Model (3) or (4). The goal of two-step optimization is to find the Minmax Edge Error in the first step and find the weights in the second step. The details of two-step optimization model are shown in Algorithm 2.

Algorithm 2 (Two-step optimization model with known \({\xi }^{*}\) for weights).

Input: \({A}_{B}\) and \({A}_{W}\)

Step 1: get \({\xi }^{*}\) by Eq. (44) of Theorem 4, or Algorithm 1

Step 2: compute the parameters by

        \(\mathit{min}\left|1-{\sum }_{i}{w}_{i}\right|\)

        S.T.\(\left|\frac{{w}_{B}}{{w}_{i}}-{a}_{Bi}\right|\le {\xi }^{*}, \forall i\)

            \(\left|\frac{{w}_{i}}{{w}_{W}}-{a}_{iW}\right|\le {\xi }^{*}, \forall i\)

            0<\({w}_{i}<1, \forall i\) (63)

Return: w

For Algorithm 2, as \({\xi }^{*}\) is known after step 1, the constraint \({\sum }_{i}{w}_{i}=1\) is changed to the objective function \({\text{min}}\left|1-{\sum }_{i}{w}_{i}\right|\), in which the expected objective value (or difference) must reach to zero. There are several alternative forms for Model (63) in step 2. Alternatively, the absolute error can be changed to the squared error form below:

$${\text{min}}{\left(1-{\sum\limits }_{j}{w}_{i}\right)}^{2}.$$
(64)

Both absolute and squared forms can produce the weights leading to the same \({\xi }^{*}\), the objective value of Model (63) or (64) is expected to be minimized to zero (or very close to zero due to rounded or truncated errors from floating-point computation). Analogue to Model (17) without absolute function, the Model (63) can be changed to the equivalent model below:

$$\begin{gathered} \min ({\text{or}} \max ) \sum \limits_j w_i \\ S.T.w_B /w_i - a_B i \le \xi^* ,\forall i \\ - \frac{w_B }{{w_i }} + a_{Bi} \le \xi^* , \forall i \\ \frac{w_i }{{w_W }} - a_{iW} \le \xi^* , \forall i \\ - \frac{w_i }{{w_W }} + a_{iW} \le \xi^* , \forall i \\ \sum \limits_i w_i = 1, 0 < w_i <1, \forall i. \\ \end{gathered}$$
(65)

Using either min or max function, the expected objective value must ideally be one or very close to one due to little precision errors from floating-point operations, as the constraint \({\sum }_{i}{w}_{i}=1\) is set. Alternatively, Model (63) is changed to the quadratic form below:

$$\begin{gathered} \min \left( {1 - \sum \limits_j w_i } \right)^2 \hfill \\ S.T.\;w_B /w_i - a_B i \le \xi^* ,\forall i \hfill \\ - \frac{w_B }{{w_i }} + a_{Bi} \le \xi^* , \forall i \hfill \\ \frac{w_i }{{w_W }} - a_{iW} \le \xi^* , \forall i \hfill \\ - \frac{w_i }{{w_W }} + a_{iW} \le \xi^* , \forall i \hfill \\ 0 < w_i < 1,\forall i. \hfill \\ \end{gathered}$$
(66)

Similarly, Model (63) can be changed to the form below:

$$\begin{gathered} \min \left| {1 - \sum \limits_j w_i } \right| \hfill \\ S.T.|w_B - a_B iw_i | \le \xi^* w_i ,\forall i \hfill \\ \left| {w_i - a_{iW} w_W } \right| \le \xi^* w_i , \forall i \hfill \\ 0 < w_j < 1, \forall j. \hfill \\ \end{gathered}$$
(67)

The above model is equivalent to a quadratic programming form below:

$$\begin{gathered} \min \left( {1 - \sum \limits_j w_i } \right)^2 \hfill \\ S.T.w_B - a_{Bi} w_i \le \xi^* w_i ,\forall i \hfill \\ - w_B + a_{Bi} w_i \le \xi^* w_i ,\forall i \hfill \\ w_i - a_{iW} w_W \le \xi^* w_W ,\forall i \hfill \\ - w_i + a_{iW} w_W \le \xi^* w_W , \forall i \hfill \\ 0 < w_i < 1,\forall i. \hfill \\ \end{gathered}$$
(68)

Models (67) and (68) can preserve the same \({\xi }^{*}\) from Model (3), which is also verified by the simulation results in Sect. 9. In principle, since the objective value of Model (3) or (4) can be obtained by Theorem 4 or Algorithm 1, by observing the expected result of objective values, Models (61)–(68) could more precisely generate the weights leading to the exact \({\xi }^{*}\) than Model (3) or (4). Models (63)–(68) can preserve the exact \({\xi }^{*}\) if expected objective value of 0 for Model (63)–(64) and (66)–(68) is reached, and the objective value of 1 for Model (65) is reached. The choice of models may depend on the optimization algorithms. According to the simulation presented in Sect. 9, the Minmax of Model (3) and its equivalent Model (4) do not produce the unique version of weight vector with the same \({\xi }^{*}\) if n > 3. Similarly, the optimization Models (63)–(68) can also produce multiple versions of weights as they are merely inherited from Models (3) and (4) with the given \({\xi }^{*}\). With the use of optimization Models (3)–(4) and (61)–(68), we can understand more about the properties for \({\xi }^{*}\) and \({w}_{i}\), although the weights produced by them are unreliable to be used.

To measure the prioritization performance, Eqs. (69)–(71) are proposed as below. The difference between the weight ratio scores and corresponding rating scores for \({A}_{B}\) and \({A}_{W}\) can be shown as below:

$$\widehat{\xi }=\left[\begin{array}{ll}{{\xi }_{B}}\\{{\xi }_{W}}\end{array}\right]=\left[\begin{array}{c}\left\{\frac{{w}_{B}}{{w}_{i}}-{a}_{Bi}\right\}\\ \left\{\frac{{w}_{i}}{{w}_{W}}-{a}_{iW}\right\}\end{array}\right].$$
(69)

\(\widehat{\xi }\) is the Weight-Ratio-To-Edge-Error Matrix (WRTEEM) of size \(2\times n\). The first row is a vector of the best-over-all edge errors denoted by \({\xi }_{B}\) and the second row is a vector of the all-over-worst edge errors denoted by \({\xi }_{W}\).

$$\overline{\xi }={\text{max}}\left(\left|\widehat{\xi }\right|\right)={\text{max}}\left[\left|\begin{array}{ll}{{\xi }_{B}}\\{{\xi }_{W}}\end{array}\right|\right]={\text{max}}\left[\begin{array}{c}\left|\frac{{w}_{B}}{{w}_{i}}-{a}_{Bi}\right|\\ \left|\frac{{w}_{i}}{{w}_{W}}-{a}_{iW}\right|\end{array}\right].$$
(70)

To verify weights produced by the optimization model, the following equality is used to measure whether the weights lead to \({\xi }^{*}\).

$${\xi }^{*}=\overline{\xi }=\underset{i}{\mathit{max}}\left\{\left|\frac{{w}_{B}}{{w}_{i}}-{a}_{Bj}\right|\left|\frac{{w}_{i}}{{w}_{W}}-{a}_{jW}\right|\right\}.$$
(71)

9 Simulations and discussions

To facilitate the demonstration, analysis and discussion, the following examples are set by arranging or defining \(B=1\) for the best criterion, \(W=2\) for the worst criterion, the indices of other criteria are \(3,\ldots ,n\). As mentioned earlier, \({A}_{W}\) in Eq. (2) is revised and defined without transposition, i.e. T, in this paper, due to redundancy or confusion for calculation. The R programming language is used for the implementation in this study. The NLOPT_GN_ISRES algorithm of the nloptr package (Johnson 2023) is used as the optimization solver after testing a broad range of optimization algorithms behind, but beyond discussion in this paper. The hardware used is the basic model, OMEN by Laptop 15 with Intel i7-7700HQ CPU and 16 GB RAM, and hence, the simulations of this paper are reproducible without high-end hardware requirement. The simulation dataset based on R and a program of MS Excel version for six numerical examples during the current study are available in the supplementary files and more files may be further included and updated in Yuen (2023).

9.1 Numerical examples

Six examples are used to demonstrate the usability of Algorithms 1 and 2 and Theorems 1–4. For the implementation using an optimization solver, Model (3), instead of Model (4), is used due to simplicity and fewer constraints to be implemented. To increase the precision for Model (3), the maximum number of function evaluations is set to 150,000. If the maximum number is not large enough, e.g. just a few thousands, the objective values may not research to the exact or ideal optimal solution. For Examples 2–4 and 6, the numerical approximate solution of Model (3) is almost the same as the closed-form solution of Theorem 4 or Algorithm 1 with the precision of at least 8 decimal places. The Excel file for the calculation of the following examples is available in Supplementary 1.

Example 1.

To compute the Consistency Index of \({a}_{BW}=\) 8, substitute \({a}_{BW}=\) 8 to Eq. (42) of Theorem 3 to get the CI value below.

$${CI}_{8}=\frac{1}{2}\left(\left(1+2\times 8\right)-\sqrt{8\times 8+1}\right)=4.4689.$$

Similarly, CI values of four significant decimal digits for \({a}_{BW}\in \left[2,\ldots ,12\right]\) are shown in Table 1. The partial results are the same to the presentations rounded to two significant decimal digits for \({a}_{BW}\in \left[2,\ldots ,9\right]\) shown in Rezaei (2015, 2016).

Table 1 CI values for \({a}_{BW}\in \left[1,\ldots ,12\right]\)

Example 2.

Given \({A}_{B}=\left(\mathrm{1,8},3\right)\) and \({A}_{W}=\left(\mathrm{8,1},2\right)\). By Algorithm 1, \(p=3-2=1\) and \(3\times 2-8<0\), the MEE and CR are computed as below:

$${\xi }^{*}={\xi }_{1}=\frac{1}{2}\left(-\left(1+3+2\right)+\sqrt{{\left(1+3+2\right)}^{2}-4\left(3\times 2-8\right)}\right)=0.3166;$$
$$CR=\frac{0.3166}{4.4689}=0.071.$$

For another pair, given \({A}_{B}=\left(\mathrm{1,8},5\right)\) and \({A}_{W}=\left(\mathrm{8,1},4\right)\). As \(5\times 4-8>0\),

$${\xi }^{*}={\xi }_{1}=\frac{1}{2}\left(\left(1+5+4\right)-\sqrt{{\left(1+5+4\right)}^{2}-4\left(5\times 4-8\right)}\right)=1.3944;$$
$$CR=\frac{1.3944}{4.4689}=0.312.$$

If the rating scores at the same location of the other criterion of \({A}_{B}\) and \({A}_{W}\) are exchanged, i.e. \({A}_{B}=\left(\mathrm{1,8},4\right)\) and \({A}_{W}=\left(\mathrm{8,1},5\right)\), MEE is also the same as above, as the equation explains this scenario.

Example 3.

Given \({A}_{B}=\left(\mathrm{1,8},\mathrm{2,2}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{2,3}\right)\). By Algorithm 1, \(p=4-2=2\). By removing elements in criteria B and W, \({A{\prime}}_{B}=\left(\mathrm{2,2}\right)\) and \({A{\prime}}_{W}=\left(\mathrm{2,3}\right)\). \(D=\left(\frac{2\times 2-8}{2+2-1}, \frac{2\times 3-8}{2+3-1}\right)=\left(-\frac{4}{3},-\frac{1}{2}\right)\). Since \(min(D)\le max(D)\le 0\), Case 2 in Algorithm 1 is applied. As \({S}^{-}={\text{argmin}}(D)={\text{argmin}}\left(-\frac{4}{3},-\frac{1}{2}\right)=\left\{1\right\}\) and\(2\times 2-8<0\), the MEE is

$${\xi }^{*}=\underset{i\in \left\{1\right\}}{{\text{max}}}({\xi }_{i})={\text{max}}\left( \frac{1}{2}\left(-\left(1+2+2\right)+\sqrt{{\left(1+2+2\right)}^{2}-4\left(2\times 2-8\right)}\right)\right)=0.7016.$$

For another pair, given \({A}_{B}=\left(\mathrm{1,8},\mathrm{3,3},5\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{3,5},4\right)\). As \({A^{\prime}}_{B}=\left(\mathrm{3,3},5\right)\) and \({A{\prime}}_{W}=\left(\mathrm{3,5},4\right)\), \(D=\left(\mathrm{0.2,1},1.5\right)\). Since \({\text{max}}(D)\ge {\text{min}}(D)\ge 0\), Case 1 is applied. As \({S}^{+}={\text{argmax}}(D)=\left\{3\right\}\) and \(5\times 4-8>0\), the MEE is

$${\xi }^{*}=\underset{i\in \left\{3\right\}}{\mathit{min}}({\xi }_{i})=max\left( \frac{1}{2}\left(\left(1+5+4\right)-\sqrt{{\left(1+5+4\right)}^{2}-4\left(5\times 4-8\right)}\right)\right)=1.3944.$$

If more other criteria are included and evaluated, e.g. \({A}_{B}=\left(\mathrm{1,8},\mathrm{3,3},\mathrm{2,3},5\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{3,5},\mathrm{4,3},4\right)\) such that \({\text{min}}(D)\ge 0\) and \({\text{max}}(D)=1.5\) at \(\left(\mathrm{5,4}\right)\), \({\xi }^{*}\) is still 1.3944, without any changes. Similarly, if \({A}_{B}=\left(\mathrm{1,8},\mathrm{2,2},\mathrm{1,6}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{2,3},\mathrm{5,1}\right)\) such that \({\text{max}}(D)\le 0\) and \({\text{min}}(D)=-\frac{4}{3}\) at \(\left(\mathrm{2,2}\right)\), \({\xi }^{*}\) is still 0.7016 and not changed. It is concluded that the number or size of criteria is not related to MEE for Cases 1 and 2.

Example 4.

Given \({A}_{B}=\left(\mathrm{1,8},\mathrm{2,2}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{2,7}\right)\). By Algorithm 1, as \({A^{\prime}}_{B}=\left(\mathrm{2,2}\right)\) and \({A^{\prime}}_{W}=\left(\mathrm{2,7}\right)\), \(D=\left(-\mathrm{1.33,0.75}\right)\), \({\text{min}}(D)=-1.33<0\) and \({\text{max}}(D)=0.75>0\), Case 3 is met. As \({S}^{+}= 2\) and \({S}^{-}=1\),

$${\xi }^{*}={\text{max}}\left(\left\{{\xi }_{1},{\xi }_{2}\right\},\left\{{\xi }_{12}\right\}\right)={\text{max}}\left(\left\{\mathrm{0.6411,0.7516}\right\},\left\{0.7692\right\}\right)=0.7692.$$

Now the third elements in \({A}_{B}\) and \({A}_{W}\) are changed to 1 and 4, but their multiplication is still 4, i.e. \({A}_{B}=\left(\mathrm{1,8},\mathrm{1,2}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{4,7}\right)\). However, the new determinant value at (1,4) is \(-1\). The new MEE is

$${\xi }^{*}={\text{max}}\left(\left\{{\xi }_{1},{\xi }_{2}\right\},\left\{{\xi }_{12}\right\}\right)={\text{max}}\left(\left\{0.\mathrm{6411,0.6056}\right\},\left\{0.7143\right\}\right)=0.7143.$$

If the pair is mixed with more numbers, e.g. \({A}_{B}=\left(\mathrm{1,8},\mathrm{2,1},\mathrm{2,7}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{2,4},\mathrm{7,2}\right)\). By Algorithm 1, as \({A^{\prime}}_{B}=\left(\mathrm{2,1},\mathrm{2,7}\right)\) and \({A^{\prime}}_{W}=\left(\mathrm{2,4},\mathrm{7,2}\right)\), \(D=\left(-1.33,-\mathrm{1,0.75,0.75}\right)\), \({\text{min}}(D)=-1.33<0\) and \({\text{max}}(D)=0.75>0\), Case 3 is satisfied. As \({S}^{+}= \left\{\mathrm{3,4}\right\}\) and \({S}^{-}=\left\{1\right\}\),

$${\xi }^{*}={\text{max}}\left(\left\{0.6411,.6411,0.7516\right\},\left\{\mathrm{0.7692,0.7692}\right\}\right)=0.7692.$$

The last MEE is also the same as the initial one. Although multiplications of the third elements of the first pair and second pair of vectors are the same, i.e. \(2\times 2=1\times 4=4\), and the other elements remain the same, their \({\xi }^{*}\) values are different. On the other hand, for the third pairs, swapping the number between the same positions of both vectors does not change the error results. For the details, the Edge Error Matrices for the above three paired vectors are shown in Tables 2, 3, and 4. The maximal values of the elements in the matrices are their corresponding MEE, respectively.

Table 2 The edge error matrix for \({A}_{B}=\left(\mathrm{1,8},\mathrm{2,2}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{2,7}\right)\)
Table 3 The edge error matrix for \({A}_{B}=\left(\mathrm{1,8},\mathrm{1,2}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{4,7}\right)\)
Table 4 The edge error matrix for \({A}_{B}=\left(\mathrm{1,8},\mathrm{2,1},\mathrm{2,7}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{2,4},\mathrm{7,2}\right)\)

Example 5.

Given \({A}_{B}=\left(\mathrm{1,8},2\right)\) and \({A}_{W}=\left(\mathrm{8,1},2\right)\). Models (3), (4) and (63)–(68) produce the same result, i.e. (0.663, 0.091, 0.246). If \(n=3\), the weights are unique due to the reason explained by applying Eq. (69) as below:

$$\widehat{\xi }=\left[\begin{array}{ll}{{\xi }_{B}}\\{{\xi }_{W}}\end{array}\right]=\left[\begin{array}{ccc}0& -0.7016& 0.7016\\ -0.7016& 0& 0.7016\end{array}\right].$$

The absolute weight-ratio-to-edge-error for each pair of different criteria is \({\xi }^{*}\). By solving the equations below, we can get the unique weights.

$$\frac{{w}_{B}}{{w}_{2}}-{a}_{B2}=\frac{{w}_{1}}{{w}_{W}}-{a}_{1W}=-0.7016,$$
$$\frac{{w}_{B}}{{w}_{3}}-{a}_{B3}=\frac{{w}_{3}}{{w}_{W}}-{a}_{3W}=0.7016.$$

However, if the matrix is inconsistent and \(n>3\), multiple versions of weights with the same \({\xi }^{*}\) are generated. For \({A}_{B}=\left(\mathrm{1,8},\mathrm{2,2}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{2,3}\right)\) in Example 3, the same model produces multiple solutions with respect to the same \({\xi }^{*}\), in which three different sample solution sets for each selected model are shown in Table 5. The reason can be explained by Eq. (69), in which the \(\widehat{\xi }\) results are presented in Table 6. According to Example 3 using Algorithm 1, \({\xi }^{*}\) is induced by the first other criterion, that is i = 3 shown in Table 6. However, there is some flexibility to choose the error for a criterion from the others, e.g. i = 4 in \({\xi }_{B}\) and \({\xi }_{W}\). Another reason to produce the multiple solutions is the flexibility to change \({w}_{B}\) and \({w}_{W}\) which is shown in Eq. (46), (49), (52) and (55). For example, by applying Eq. (47) to the Test Case 1 in Models (3), (61) and (65) shown in Tables 4 and 5 with more significant digits for actual calculation, the results leading to the same value of \({\xi }^{*}\) are shown as below:

$$\frac{0.5233927}{0.07171297}=\frac{0.5292615}{0.07251709}=\frac{0.5288694}{0.07246336}=\left(8-0.7015621\right)=7.298438.$$
Table 5 Multiple weight solutions with respect to the same \({\xi }^{*}\) for Example 5
Table 6 Weight-ratio-to-edge-error matrices for the cases in Table 5 for Example 5

It is observed that \({\xi }^{*}\) and weights produced in Model (3) or (4) do not have direct relationship to the \({\xi }^{*}\) and weights produced in Model (5) or (6), which have the unique solution for their own objective value and weights. If \({\xi }^{*}\) of Model (3) solved by a closed form is assigned to Model (67), which is transformed from Model (6), multiple weight solutions are also unavoidable.

If Model (6) is used, a unique weight set presented in Table 5 is produced no matter how many times are executed. If Eqs. (69) and (70) are applied to the unique weights, the results are presented in Table 6. The \(\overline{\xi }\) or \({\xi }^{*}\) derived from Model 6 is not the same as the \({\xi }^{*}\) derived from Model (3). Therefore, objective value and weights derived from Model (5) or (6) have no direct observed relationship to Model (3) or (4). The consistency ratio from Model (3) or (4) is independent of the weights from Model (5) or (6).

Example 6.

Refer to Fig. 1, \({A}_{B}=\left(\mathrm{1,8},\mathrm{1,2},\mathrm{6,2},\mathrm{2,3},\mathrm{2,4}\right)\) and\({A}_{W}=\left(\mathrm{8,1},\mathrm{4,2},\mathrm{1,3},\mathrm{6,4},\mathrm{8,4}\right)\). The edge error matrix is presented in Table 7. By Theorem 4, MEE is \({\xi }^{*}={\text{Max}}({\text{EEM}}) = 1\). By Algorithm 1, \({A{\prime}}_{B}=\left(\mathrm{1,2},\mathrm{6,2},\mathrm{2,3},\mathrm{2,4}\right)\) and\({A{\prime}}_{W}=\left(\mathrm{4,2},\mathrm{1,3},\mathrm{6,4},\mathrm{8,4}\right)\),\(D=\left(-1,-1.33,-0.33,-\mathrm{0.5,0.5714,0.667,0.8889,1.1429}\right)\). Case 3 is satisfied. As \({S}^{+}= \left\{8\right\}\) and\({S}^{-}=\left\{2\right\}\), which are located at \({c}_{4}\) and \({c}_{10}\), \({\xi }^{*}={\text{max}}\left(\left\{0.7016,1\right\},\left\{1\right\}\right)=1\).

Table 7 The Edge Error Matrix for \({A}_{B}=\left(\mathrm{1,8},\mathrm{1,2},\mathrm{6,2},\mathrm{2,3},\mathrm{2,4}\right)\) and \({A}_{W}=\left(\mathrm{8,1},\mathrm{4,2},\mathrm{1,3},\mathrm{6,4},\mathrm{8,4}\right)\) for Example 6

9.2 Simulations and verifications

To further verify the reliability of closed-form solutions from the Max of Edge Error Matrix method (Theorem 4) and the Minmax Edge Error Determinant Method (Algorithm 1), especially to investigate if any missing cases are not uncovered for the algorithm design and implementation, the pseudo code of a test algorithm is proposed in Algorithm 3. Let \({\xi }^{minMax}\), \({\xi }^{maxEEM}\) and \({\xi }^{detMEE}\) be the MEE values obtained by Model (3) or (4), Eq. (43) of Theorem 4, and MEED method of Algorithm 1, respectively. In principle, the following relationship holds.

$${\text{error}}=\left\{\begin{array}{ll}0,{\xi }^{minMax}={\xi }^{maxEEM}={\xi }^{detMEE}\\ 1, {\rm Otherwise} \end{array}\right..$$
(72)

In practice, the relationship above is implemented as three conditions stated in Step 2c of Algorithm 3. As the numerical solvers may only achieve a good enough solution that approximates to the exact solution, approximation error can be produced. In addition, if \({\xi }^{maxEEM}\) or \({\xi }^{detMEE}\) value is the unique and exact closed-form solution, the \({\xi }^{minMax}\) value is not possible less than them, i.e. \({\xi }^{minMax}\ge {\xi }^{maxEEM}={\xi }^{detMEE}\). However, as floating-point operations may induce rounded and truncated errors, a very small negative error for \({\xi }^{minMax}-{\xi }^{maxEEM}\) is still possible. Therefore, the conditions of Eq. (72) are changed and defined for simulations as below:

$${-10}^{-6}\le \left({\xi }^{minMax}-{\xi }^{maxEMM}\right)\le {10}^{-4}\,\,\mathrm{ and \,\,}{\xi }^{maxEEM}={\xi }^{detMEE}.$$
(73)

If the difference between the numerical solution from the solver and the closed-form solution is more than \({10}^{-4}\) or less than \({-10}^{-6}\), the potential error from Theorem 4 or Algorithm 1 for \({\xi }^{maxEEM}\) or \({\xi }^{detMEE}\) will be reported by the algorithm. According to the simulations in this study, the error flag normally resulted from the optimizers being unable to find the optimal values. If the optimization re-runs several times and/or enhance the research cost, the \({\xi }^{maxEEM}\) finally reaches to the defined range.

To obtain the better accuracy of the optimization solver, firstly, the maximum number of function evaluations for the NLOPT_GN_ISRES solver algorithm of the nloptr package (Johnson 2023) to implement Algorithm 2 is set to 200,000 with the fractional tolerance of \({10}^{-10}\), and secondly, the weights obtained by Algorithm 2 are used as the initial values for Model (3) implemented by the same optimization algorithm solver of the same settings for the function evaluations and fractional tolerance. If only Model (3) is implemented, an error from the solver could be more than \({10}^{-4}\).

Algorithm 3 (Testing for MEE derived from solver, max(EEM) and detMEE method)

Input: N: Testing sample size; \({n}^{max}\): maximum number of criteria; \({a}^{max}\): maximum value for \({a}_{BW}\),

Step 1: Initialize the values

times = 1 # case number or counter

error = 0 # error checking

flag = TRUE # flag to continue or exist the while loop

Step 2: Perform comparisons for N samples

While (flag):

Step 2a: Generate \(\left({A}_{B},{A}_{W}\right)\)

\({a}_{BW}=random(2,{a}^{max})\) # generate a random integer between 2 and \({a}^{max}\) for \({a}_{BW}\)

n \(=random(3,{n}^{max})\) # generate a random integer between 3 and \({n}^{max}\) for n

\(\left({A}_{B},{A}_{W}\right)=generateBW\left({a}_{BW},n\right)\) # generate a pair of random vectors with \({a}^{max}\) and n

Step 2b: Obtain MEE’s with Model (3) with solver, Theorem 4 and Algorithm 1

\({\xi }^{minMax}=minMaxOpt\left({A}_{B},{A}_{W}\right)\) # Obtain MEE with solver for Model (3)

\({\xi }^{maxEEM}=maxEEM\left({A}_{B},{A}_{W}\right)\) # Obtain MEE with MEEM of Theorem 4

\(the {\xi }^{detMEE}=detMEE\left({A}_{B},{A}_{W}\right)\) # Obtain MEE with determinant method of Algorithm 1

Step 2c: comparing \({\xi }^{minMax},{\xi }^{maxEEM}\), and \({\xi }^{detMEE}\)

# Condition 1: check if the difference between \({\xi }^{minMax}\) and \({\xi }^{maxEMM}\) is very small

\(con1=\left\{\begin{array}{ll}1,\left({\xi }^{minMax}-{\xi }^{maxEEM}\right)\le {10}^{-4}\\ 0, otherwise\end{array}\right.\)

# Condition 2: check if \({\xi }^{Minmax}\ge {\xi }^{maxEMM}\) within floating-point error allowance

\(con2=\left\{\begin{array}{ll}1,\left({\xi }^{minMax}-{\xi }^{maxEEM}\right)\ge {-10}^{-6}\\ 0, otherwise\end{array}\right.\)

# Condition 3: check if Theorem 4 and Algorithm 1 produce the same results including floating-point error

\(con3=\left\{\begin{array}{ll}1,{\xi }^{detMEE}={\xi }^{maxEEM}\\ 0, otherwise\end{array}\right.\)

# If all conditions above are met, no error is found

\(error=\left\{\begin{array}{ll}0, con1 \times con2\times con3=1\\ 1, otherwise\end{array}\right.\)

Step 3c: determine the flag for the while loop

times +  = 1 # increment by 1

# If N instances are performed or an error is found, exit the while loop. Otherwise, continue

\(flag=\left\{\begin{array}{l}FALSE,error\ne 0 or times > N\\ TRUE, otherwise\end{array}\right.\)

End While

# If an error is found, return the last \(\left({A}_{B},{A}_{W}\right)\) inducing potential error for further study. Otherwise, no error is found, i.e. error = 0

Return: error, \(\left({A}_{B},{A}_{W}\right)\) if \(error\ne 0\)

Algorithm 3 presents the pseudo code for the core procedure. For implementation, the print functions, for example, are added in Algorithm 3 where appropriate for tracking, debugging and analysing. Two simulations have been performed. Both the maximum number of criteria, denoted by \({n}^{max}\), and the maximum value for \({a}_{BW}\), denoted by \({a}^{max}\), are set to 9. When \({a}_{BW}>9,\) Eq. (59) may not be suitable, which will be discussed in the future study. As the rating is on nine-point scale, Eq. (59) can be used.

For the first simulation, 20,000 random instances have been performed by taking 94,838 s (26.34 h). The file of the simulation data is available in Supplementary 2 or Yuen (2023). According to the simulation results, no error or unexpected case is found from all generated instances. It can be concluded that Theorem 4 or Algorithm 1 produces the exact closed-form solution for Model (3) or (4), and the results can be used to verify the solutions of the optimization solver.

The second simulation is to extensively test the efficiency of the proposed closed-form solutions and verify that the Theorem 4 and Algorithm 1 always produce the same MEE. A new algorithm (called Algorithm 4) is created by removing calculations of \({\xi }^{minMax}\), Conditions 1 and 2 from Algorithm 3, and with only using Condition 3 to check if any potential error occurs. One million random instances have been performed by taking only 4600 s (1.27 h). The file of the simulation data is available in Supplementary 3 or Yuen (2023). Again, no error is found from the one million random instances. For very rough estimation based on two simulations, the computation time of the proposed closed forms could be \(((94838 - 4600/50) 50 -(4600/2))/(4600/2)=2058\) times faster than the Model (3) or (4) subject to implementation configuration for the solver. It can be concluded that it is quite computationally expensive for the solver to obtain better precision of MEE. The determination method of Algorithm 1 can be used to quickly determine the MEE with slightly less computational effort, whilst Theorem 4 can provide the details of EEM for reference.

10 Discussion and conclusions

The major contribution of this study is the provision of closed-form solutions for the exact Consistency Ratio in BWM Minmax Optimization Model, which currently must use optimization solvers such as Excel Solver in (https://bestworstmethod.com/software/) or MATLAB (Wu et al. 2022). CR is ratio of MEE (or \({\xi }^{*}\)) to the Consistency Index. Whilst the CI is computed by Eq. (42), the MEE is obtained by the Max of Edge Error Matrix Method (Eq. (44) of Theorem 4) and the Minmax Edge Error Determinant Method (Algorithm 1). In Theorem 4, the upper triangular part of the edge error matrix is first computed, and the maximum value of the triangular matrix is the MEE. As EEM is the symmetric matrix, the max of either the upper or lower part is MEE. For the MEED of Algorithm 1, the determinant values are first computed to determine the location(s) and the case of the MEE, and then the appropriate function in the case is used to compute the MEE. If the best-over-worst score is more than nine, MEEM method should be used, as the constraint condition in Eq. (59) of MEED is indicated.

Several essential properties of the consistency ratio toward or extended from the closed-form solutions are discussed. Firstly, although Rezaei (2015, 2016) claimed that the comparisons ideally up to 9 criteria, according to Theorem 4, the inconsistency based on MEE is independent of number of criteria as MEE is determined by the worst case determined by the largest value of IEE (Theorem 1) or CEE (Theorem 2). The aggregate edge errors are not considered, as the optimal value is independent of the number of criteria but determined by the most discrepant scores for some criteria.

With the simple algebraic form of EEM, the individual values over the threshold defined by the decision maker can be identified. If the paired vectors are inconsistent, decision makers can find sufficient high values in EEM to identify the inconsistency locations and then revise the judgement ratings. The examples of EEM are shown in Tables 2, 3, 4, and 7.

As the exact MEE can be obtained by the algebraic forms, the optimization models can be revised with fewer variables and constraints, e.g. Algorithm 2 of Model (63) and its alternative Models (64)–(68). All objective values of the models must be one, except for Model (65), which is zero. If these conditions are satisfied, the weights generated from the models can preserve the MEE calculated by Eq. (70). However, the same MEE can lead to different versions of non-reproducible weights due to the reasons discussed in Sect. 8, and Example 5 also demonstrated these issues. According to the testing in this study, weights generated from Models (5) and (6) are more reliable than Models (3) and (4) since Models (5) and (6) produce the unique exact solution of weights. However, according to the closed-form solution formula, the weights generated from Models (5) and (6) are independent of or have no obvious relationship to the EEM generated from Models (3) and (4). Since the CR optimization model must calculate weights to obtain the MEE, the new methods do not need to compute weights to have the MEE. The significance of this paper is that all BWM applications can efficiently use the proposed closed forms for the exact CR values, instead of using an expensive optimization solver to find the approximate values with potential error.