1 Introduction

The MEDKC problem, proven to be a \(\mathcal{N}\mathcal{P}\)-hard (Könemann et al. 2004), can be outlined as follows: In a given edge-weighted, undirected and connected graph \(G=(V,E,w)\)—with V denoting the vertex-set and E representing the edge-set, and w as the edge-weight function—let \(\varPi \subset V\) refer to a set of K center vertices and every other vertex \(v \in V\) is allotted to only one vertex \(\pi _v \in \varPi \), where \(K > 0\) is a parameter. The objective of the MEDKC problem is to identify a set \(\varPi \) of K center vertices and assign each remaining vertex to a unique vertex in \(\varPi \) in a manner that minimizes the stretch of the solution (\(\varPi ,{\pi _v}_{v \in V}\)). The stretch of a solution (\(\varPi ,\{\pi _v\}_{v \in V}\)) = \(\underset{(u,v)\in V \times V}{\textrm{max}} \{\frac{d_\pi (u,v)}{d_w(u,v)}\}\) is described as the maximum stretch among all pairs of vertices in G.

The stretch for a pair of vertices (\(u,v \in V\)) is the ratio of the center distance (\(d_\pi (u,v)\)) to the shortest distance (\(d_w(u,v)\)) in G, represented as \(\frac{d_\pi (u,v)}{d_w(u,v)}\), where \(d_\pi (u,v)\) with respect to \(\varPi \) is defined as

$$\begin{aligned} d_\pi (u,v) = d_w (u,\pi _u) + d_w(\pi _u,\pi _y) + d_w(\pi _y,v). \end{aligned}$$
(1)

Here, \(d_w(u,v)\) signifies the shortest path between u and v.

The optimal solution for a given G is denoted as Opt(G) = min(\(\varPi ,\{\pi _v\}_{v \in V}\)) over all possible subsets \(\varPi \) and assignment \(\{\pi _v\}_{v \in V}\).

In the literature, the MEDKC problem exhibits connections to various problems (Garcia-Diaz et al. 2019). Some of these related problems include:

  • p-Center problem aims to seek a set of p vertices \(\in V\), such that the maximum distance from any vertex to its closest center is as minimum as possible (Davidović et al. 2011; Garcia-Diaz et al. 2019).

  • The capacitated K-center problem allows each center to attend only a certain number of vertices (Khuller and Sussmann 2000)

  • The fault tolerant K-center problem in which each selected center must belong to a set of \(\alpha \le K\) centers close to it (Khuller et al. 2000).

  • The p-next center problem that aims to minimize the total sum of the distance from the farthest vertex to its nearest center and the distance between this center to its nearest alternative center (López-Sánchez et al. 2019).

  • The mixed K-center problem in which q centers must be in the set of vertices, and the remaining vertices can be anywhere (\(q < K\)) (Xu et al. 2018).

Könemann et al. (2004) introduced the MEDKC problem, inspired by a practical application in routing schemes within computer networks. In such schemes, each source node has the capability to route messages to a destination node. A host (node) stores information about routing paths to every other host in its routing table. To ensure shortest-path routing for the entire network, each node requires \(\mathcal {O}(n)\) entries in its routing table to retain information about the shortest-path routing to every other node.

Considering computer networks in modern times comprising of millions of nodes poses a challenge for each node to store information on shortest-path routing for other nodes because of memory limitations. Attempts have been made to develop an efficient routing scheme, prioritizing considerations for memory constraints. Researchers focus on two main objectives: minimize the size of routing tables and/or minimize the stretch of a routing scheme. Modern routing protocols such as OSPF (Moy 1998) enable the division of a network into areas, where each node retains information about paths within the same area. Routing between nodes in distinct areas is accomplished through a backbone network of area border routers connecting these areas. This results in a decrease in the routing table size for each node, with the anticipation that the overall network stretch remains acceptable.

The objective of the MEDKC problem is based on this principle that K center nodes in computer networks are exactly the area border routers, while each remaining node in the network is assigned to a router. The task is to construct a compact routing scheme that minimizes the maximal stretch of the entire network.

2 Literature review

The literature has seen numerous papers addressing compact routing schemes, with a primary emphasis on balancing the trade-off between the size of routing tables and the stretch. In the initial stages, (Peleg and Upfal 1989) pioneered compact routing schemes tailored for undirected graphs. Subsequently, a routing scheme (Awerbuch et al. 1990; Awerbuch and Peleg 1990) was proposed for weighted graphs. Thorup and Zwick (2001) introduced a labeled compact routing scheme with a stretch of 4K-5 using a routing table of size \(\mathcal {O}(\frac{1}{k})\)-bit by each vertex. Chechik (2013) enhanced the outcome of Thorup and Zwick (2001). Eilam et al. (2003) employed the pivot interval routing (PIR) scheme, achieving a stretch factor of at most 5 and an average stretch factor of at most 3. Each vertex utilized a routing table of size \(\mathcal {O}(\sqrt{n}\log ^{3/2}n)\) bits. Cowen (2001) demonstrated that if \(\mathcal {O}(n/2/3\log ^{4/3} n)\) space is allowed at each vertex in a given weighted undirected network (G), a solution can be found where the routing path between any pair of vertices ((\(u,v \in V\))) is at most three times as long as the shortest uv-path in G. Krioukov et al. (2007) established that using sub-linear sized routing tables, a stretch of less than 3 is achievable. Enachescu et al. (2008) applied Internet-like graphs and proposed a routing scheme with a stretch value of less than 3 with high probability while retaining o(n) memory. Later, (Abraham et al. 2004) presented a routing scheme for a given weighted undirected network achieving a stretch of 3 using a \(\mathcal {O}(\sqrt{n})\) space at each vertex. Roditty and Tov (2015) introduced a routing scheme that surpasses previous results achieving a stretch of 5+\(\epsilon \) using \(\mathcal {O}(\frac{1}{\epsilon }n^{1/3}\log \) \(D)\) memory at each node, the label of each node of \(\mathcal {O}(\log \) \(n)\) size, and \(\mathcal {O}(\frac{1}{\epsilon }\log \) \(D)\)-bit headers.

Based on the literature discussed above, it is evident that there is currently no existing solution approach for the MEDKC problem applicable to practical scenarios. Moreover, the methods developed for creating a compact routing scheme cannot be directly employed, given the distinct characteristics of the two problems. Compact routing scheme problems are concerned with balancing the trade-off between stretch and the size of routing tables. In contrast, the MEDKC problem, where memory that is used to store distance information is not an issue, aims to find a set of K central nodes and to arrange the paths over them in a manner that minimizes the maximum stretch (Könemann et al. 2004).

Könemann et al. (2004) proved that the MEDKC problem is a \(\mathcal{N}\mathcal{P}\)-hard problem. They also introduced a polynomial-time approximation algorithm (referred to as \(Approx\_Kon\)), which is at most 4.Opt + 3, where Opt represents the optimal stretch value. The study on the results for the MEDKC problem (Könemann et al. 2004) is of theoretical importance, as their proposed approximation algorithm provides only an upper bound for any solution. Given its status as an \(\mathcal{N}\mathcal{P}\)-hard problem (Könemann et al. 2004), employing metaheuristic techniques becomes a favorable approach to obtain high-quality solutions within a reasonable computational timeframe. Readers are suggested to study a tutorial on metaheuristic techniques (Osaba et al. 2021). To the best of our knowledge, among metaheuristic techniques, only Matic et al. (2017) proposed two variants (GA1 and GA2) of genetic algorithm which are evolutionary algorithms. In both variants of GA, authors used binary coding and used modified crossover and mutation operators, particularly for each GA variant, to maintain feasibility of solutions throughout the optimization process. Based on the literature survey, it is clear that the MEDKC problem is an under-studied problem in terms of metaheuristic techniques.

Swarm intelligence techniques have been attracting significant attention from researchers due to their capability to find high-quality solutions for numerous hard optimization problems. This capability arises from the collective behavior of decentralized and self-organized swarms. The foraging behavior of honey bees (swarms) is one of them, such as BeeHive (Wedde et al. 2004), bees algorithm (Pham et al. 2006), bee colony optimization algorithm (Lučić and Teodorović 2001), honeybee search algorithm (Olague and Puente 2006), and artificial bee colony (ABC) algorithm (Karaboga 2005). All of them came up with different concepts for designing algorithms. Readers can find a survey on the bees’ behavior inspiring algorithms in (Karaboga and Akay 2009; Rajasekhar et al. 2017). Among them, ABC algorithm, introduced by (Karaboga 2005), has received world-wide researchers’ attention for solving complex optimization problems across diverse domains (Karaboga et al. 2014; Singh 2009; Sundar et al. 2017; Singh and Sundar 2018a, b; Ghoshal and Sundar 2021, 2020a) since its inception. This motivated us to work on ABC algorithm for the MEDKC problem. In this paper, the proposed ABC algorithm uses two adaptable neighborhood operators tailored to the MEDKC problem. On available benchmark instances, computational results indicate that the proposed ABC algorithm overall performs superior to the existing two variants of genetic algorithm in both solution quality and computational time. The proposed ABC algorithm also exhibits superiority over an existing polynomial-time approximation algorithm (\(Approx\_Kon\)) in terms of solution quality.

The remainder of the paper is summarized as follows: Sect. 3 provides a concise introduction to the artificial bee colony algorithm; Sect. 4 discusses an ABC algorithm tailored for the MEDKC problem; Sect. 5 discusses the computational results of ABC algorithm in comparison to the existing approaches; and Sect. 6 discusses concluding remarks.

3 Artificial bee colony algorithm

Artificial Bee Colony (ABC) algorithm was developed by Karaboga (2005), inspired by the intelligent foraging behavior of honey bee swarms. Initially designed for optimizing numerical problems, ABC algorithm has shown its capability in tackling various optimization problems since its inception. Relevant studies include (Karaboga et al. 2014; Singh 2009; Sundar et al. 2017; Singh and Sundar 2018a, b; Ghoshal and Sundar 2020a, 2021). In ABC algorithm, artificial bees, as per their task, are classified into three groups—employed bees, onlooker bees, and scout bees—work in cooperation to find high-quality solutions within the search space. ABC algorithm presumes that each artificial employed bee is associated with a food source, representing a solution to the optimization problem at hand. Consequently, the number of employed bees in the colony equals the number of food sources. The nectar amount of a food source is associated with the solution quality (fitness) of its associated solution. ABC algorithm starts with a set of generated initial solutions (food sources), and the size of this set is referred to as the employed bee population. Subsequently, ABC algorithm iteratively (generation) progresses through three phases—employed bee phase, scout bee phase, and onlooker bee phase. ABC algorithm continues its iteration by moving toward better solutions (in terms of fitness) through neighborhood search mechanism while abandoning inferior solutions. The iteration process concludes when a termination criterion is met. In ABC algorithm, employed bees and onlooker bees exploit the search space by determining new neighboring solutions, while the scout bee explores the search space. One can find an in-depth understanding of the framework of ABC algorithm in Karaboga et al. (2014); Singh (2009).

4 ABC algorithm for the MEDKC problem

This section describes our proposed ABC algorithm for the MEDKC problem (referred to as ABC_MEDKC). In the beginning of ABC_MEDKC, precompute the shortest paths between all pairs of vertices of a given input graph (G).

The salient features of ABC_MEDKC are discussed in the following subsections:

4.1 Solution representation

Each feasible solution is denoted as a set of K vertices acting as centers. Vertices that are not included in the K center vertices of the solution are classified as non-center vertices.

4.2 Initial solution generation

Algorithm 1
figure a

Pseudo-code of generation of an initial solution \(E_i\)

Each initial solution, denoted as \(E_i\), within the employed bee population, is randomly generated, where the size of the employed bee population is \(E_{pop}\). The initial solution \(E_i\), designed to contain K center vertices, begins as an empty set. Initially, all vertices are assigned to a set called U. In the subsequent steps, the procedure, at each iteration, randomly selects a vertex (denoted as r) from U and assigns it as the center vertex for \(E_i\). The set U is then updated by removing the selected vertex r. This iterative process continues until K vertices are assigned as center vertices to \(E_i\). Vertices not included in \(E_i\) remain in set U and are considered non-center vertices. Algorithm 1 provides the pseudo-code for the procedure outlining the generation of the initial solution \(E_i\).

4.3 Fitness computation

Upon the completion of constructing a feasible solution (denoted as S), the fitness, represented by the stretch of S, is computed by determining the maximum stretch among all pairs of vertices in G. This is defined as follows:

$$\begin{aligned} \underset{(u,v)\in V \times V}{\textrm{max}} \left\{ \frac{d_\pi (u,v)}{d_w(u,v)}\right\} . \end{aligned}$$

Readers are suggested to refer to the introduction section (Sect. 1) for more details of the stretch of a feasible solution in the context of the MEDKC problem.

4.4 Probability of selecting a solution

In ABC_MEDKC, each onlooker bee uses a binary tournament selection method to select a solution from the employed bee population. This selection mechanism involves randomly selecting two different solutions from the employed bee population. The preferred solution, based on the fitness defined in Sect. 4.3, is chosen with a probability \(P_{bt}\), while the less favorable one is chosen with a probability of \(1-P_{bt}\). This method prioritizes better solutions over inferior ones, encouraging more onlooker bees to opt for higher quality solutions. Additionally, this selection method is employed to choose a distinct solution in the first neighborhood operator (refer to Sect. 4.5.1) when determining a new neighboring solution.

4.5 Neighborhood operators

Neighborhood operators in ABC algorithm play a significant role in finding high-quality solutions for \(\mathcal{N}\mathcal{P}\)-hard combinatorial optimization problems (Sundar et al. 2017; Singh and Sundar 2018a; Pan et al. 2011; Singh 2009; Ghoshal and Sundar 2020b). For the MEDKC problem, we apply two neighborhood operators in a mutually exclusive way to determine a new neighboring solution (say \(E'_i\)) within the vicinity of the current employed bee solution (say \(E_i\)) of employed bee population. The first neighborhood operator (Nbr_cv) is based on this fact that if a center vertex is present in a solution with high fitness, the chance of that center vertex being present in many other solutions of the employed bee population is high, whereas the second neighborhood (Nbr_swp) is based on the swapping of center vert(ex/ices) with non-center vert(ex/ices) in a mixed strategies of greedy and random approach. The details of each neighborhood are outlined as follows.

4.5.1 First neighborhood operator (Nbr_cv)

The first neighborhood operator (Nbr_cv) first creates a copy (say \(E'_i\)) of the current employed bee solution (say \(E_i\)), and then, it selects a solution (say \(E_j\)), different from \(E_i\), using binary tournament selection method (see Sect. 4.4 in detail). A check is performed whether \(E_i\) and \(E_j\) are identical. If both are different, then a certain number (say nocv_1) of center vertices of \(E_j\) are selected randomly, where nocv_1 = max(1, (int)(Para1 \(\times \) cnt)). Here, cnt in \(E_j\) is the number of those center vertices which are different from the center vertices in \(E_i\). Para1 is a parameter whose value is determined empirically. All these selected center vertices from \(E_j\) are assigned to \(E'_i\), making solution \(E'_i\) infeasible. To make \(E'_i\) feasible, the same number (nocv) of center vertices which are originally part of \(E_i\) is removed from \(E'_i\). This way makes \(E'_i\) feasible, resulting in a new feasible neighboring solution \(E'_i\).

It is important to emphasize that if both \(E_i\) and \(E_j\) are identical, the continuation of the first neighborhood operator (\(Nbr\_cv\)) is halted, a scenario referred to as a collision (Singh 2009). Such duplication of two solutions within the employed bee population poses an obstacle to effectively searching for high-quality solutions in the search space. To handle this issue, the employed bee associated with \(E_i\) is designated as a scout. The scout bee then explores and identifies a new solution (refer to Sect. 4.6). This approach aids in eliminating a duplicated solution from the employed bee population, promoting greater diversity within the population. However, in the event of a collision during the onlooker bee phase, the first neighborhood operator (\(Nbr\_cv\)) is similarly discontinued for the associated solution, and a very large fitness value is assigned to that particular solution associated by its onlooker bee.

4.5.2 Second neighborhood operator (Nbr_swp)

The second neighborhood operator (Nbr_swp) is based on the swapping of center vert(ex/ices) with non-center vert(ex/ices) in a mixed strategies of greedy and random approach. Nbr_swp initiates with creating a copy (say \(E'_i\)) of the current employed solution \(E_i\). Subsequently, Nbr_swp randomly selects a certain number (say nocv_2) of center vertices from \(E_j\), where nocv_2 = max(1, (int)(Para2 \(\times K))\). Here, K is the number of center vertices. Para2 is a parameter whose value is to be determined empirically. Each selected random center vertex (say \(v_c\)) of \(E'_i\) is replaced with a candidate non-center vertex (\(v_{nc}\)) of \(E'_i\) in either two ways. With probability (Para3), Nbr_swp applies a greedy approach in which a candidate non-center vertex is selected from a subset of total number of non-center vertices of \(E'_i\) (say \(no\_ncv = (int)(val \times (V\)-K)), where val is set to 0.1 based on our preliminary experiments to balance a trade-off between running time and solution quality) based on having minimum fitness. Otherwise, Nbr_swp applies a random approach wherein a candidate non-center vertex is selected randomly from the total number of non-center vertices of \(E'_i\) with probability (1-Para3).

4.6 Scout bee phase

During the scout bee phase, if an employed bee solution ceases to show improvement for a specific number of generations (referred to as limit), the employed bee promptly abandons its non-improving solution, transitioning its status to that of a scout bee. The scout bee then seeks a new solution through a prescribed procedure (refer to Sect. 4.5.2). Once the process for finding a new solution concludes, the scout bee reverts to the state of an employed bee. The parameter limit to be determined empirically holds substantial importance in the ABC algorithm. In addition, a collision (as described in Sect. 4.5.1) can also prompt the transformation of an employed bee into a scout. It is crucial to note that the ABC algorithm does not impose an upper limit on the number of scouts in a single generation. A generation may witness multiple scouts if the conditions mentioned earlier (limit and collision conditions) are met; otherwise, no scouts are encountered.

Algorithm 2
figure b

The pseudo-code of ABC_MEDKC

Algorithm 2 outlines the pseudo-code of ABC_MEDKC in which the procedure \(BTSM(E_1, E_2, \dots , E_{E_{pop}})\) is a binary tournament selection method that provides an index of a solution in \(< E_1, E_2, \dots , E_{E_{pop}}>\); \(Nbr\_cv(X_1,X_2)\) is the first neighborhood operator that provides a new neighboring solution (say \(X'\)); and \(Nbr\_swp(X)\) is the second neighborhood operator that provides a new neighboring solution (say \(X'\)).

It is important to highlight that the most time-consuming part of ABC_MEDKC is the computation of the fitness for each generated solution. This process involves computing shortest paths between all pairs of vertices in a given input \(G=(V,E,w)\), incurring a time complexity of \(\mathcal {O}(V^3)\). Additionally, it encompasses (i) the computation of center distance for each pair of vertices, with a complexity of \(\mathcal {O}((V\)-\(K) \times K)\), and (ii) the computation of stretch for each pair of vertices, with a complexity of \(\mathcal {O}((V\)-\(K)^2)\) (refer to the first two paragraphs of Sect. 1). To alleviate this computational load, the approach precomputes the shortest paths between all pairs of vertices in a given input \(G=(V,E,w)\) once. Consequently, the fitness function procedure for each generated solution utilizes this precomputed information of shortest paths between all pairs of vertices, reducing the running time from \(\mathcal {O}(V^3)\) to \(\mathcal {O}((V\)-\(K)^2)\). Another time-consuming part of ABC_MEDKC involves a greedy approach applied by Nbr_swp with probability (Para3). In this procedure, a selected random center vertex is tried for swap with a subset of total number of non-center vertices (\(no\_ncv\)) one-by-one, and the swap that results in the minimum fitness is chosen. The running time for this greedy approach is \(\mathcal {O}(no\_ncv \times (V\)-\(K)^2)\), where \(\mathcal {O}((V\)-\(K)^2)\) is the running time for computing the fitness of a newly generated solution after a swap.

5 Computational results

C language is used to code ABC_MEDKC, and experiments are conducted on a Linux system equipped with an Intel Core i5-4570 CPU @ 3.2 GHz \(\times \) 4 processor and 4 GB of RAM using a single thread. Similar to Matic et al. (2017), the performance of ABC_MEDKC is tested on the same set of benchmark instances. ABC_MEDKC is allowed to execute 20 independent runs for each instance. The termination criterion for ABC_MEDKC allows to execute for either at least 150 generations or until the best-so-far obtained solution does not improve after (\(K \times 30\)) generations.

In the subsequent subsections, we discuss on instances, parameter settings, and computational results of ABC_MEDKC in comparison to existing approaches, including a polynomial-time approximation algorithm (\(Approx\_Kon\)) (Könemann et al. 2004) and two variants of genetic algorithms, namely GA1 and GA2 (Matic et al. 2017).

Table 1 Influence of parameter setting on the solution quality

5.1 Instances

Similar to GA1 and GA2 (Matic et al. 2017), we have also used the same two set of instances available in the public domain. The first set pertains to the BX instances, comprising 7 graphs that are 4-regular and possess varying vertex sizes from the set \(\{25,50,75,100,200,400,1000\}\) (Blesa and Xhafa 2000). The second set corresponds to the BB instances, including 7 graphs: 5 edge-weighted graphs of grid with sizes ranging from < 15 \(\times \) 15, 33 \(\times \) 33, 45 \(\times \) 5, 50 \(\times \) 50 and 100 \(\times \) 10 >, and two large Steiner tree benchmark instances, namely steinc5 and steind5, each having 500 vertices and 1000 vertices, respectively (Blum and Blesa 2005). Each instance is examined for different values of K with in the set \(\in \{2,3,4,5,10,15,20\}\). It is important to note that for K=1, the MEDKC problem is not \(\mathcal{N}\mathcal{P}\)-hard (Matic et al. 2017).

5.2 Parameter settings

Given its stochastic nature, ABC_MEDKC encompasses a set of parameters, and the configuration of each parameter is critical for its effectiveness. While tuning these parameters can be challenging, it is feasible to approximate the setting of each parameter value in such a way that it helps ABC_MEDKC in finding solutions of high quality. To set the value of each parameter used in ABC_MEDKC, ABC_MEDKC was examined on ten instances, i.e., bb15\(\times \)15_1 (k = 20), bb15\(\times \)15_1 (k = 4), g25-4-01 (k = 10), g50-4-01 (k = 3), g100-4-01 (k = 15), g200-4-01 (k = 15), bb45\(\times \)5_1 (k = 20), bb15\(\times \)15_1 (k = 15), g50-4-01 (k = 15), and g50-4-01 (k = 10). Drawing from existing literature and our prior experience with ABC algorithm, we considered a range of potential values for each parameter (refer to Table 1). Initial experiments indicated that ABC_MEDKC exhibited the best overall performance across the ten instances under consideration when \(E_{pop}=10\), \(On_{pop}=30\), \(limit=25\), \(P_{bt}=0.85\), \(P\_{nbr}=0.7\), \(Para1=0.1\), \(Para2=0.1\), and \(Para3=0.5\). One can observe the best potential value (highlighted in bold) of each parameter and its solution quality obtained (highlighted in bold) in Table 1.

5.3 Comparison of results of ABC_MEDKC against state-of-the-art approaches

This section presents a comparative analysis of the results achieved by ABC_MEDKC against the results of an existing polynomial-time approximation algorithm (\(Approx\_Kon\)) (Könemann et al. 2004) and state-of-the-art approaches (GA1 and GA2 (Matic et al. 2017)) on the BX and BB instances.

Tables 2 and 3 presents the results of \(Approx\_Kon\), GA1, GA2 and ABC_MEDKC on the 49 BX instances and 42 BB instances respectively. In these Tables 2 and 3, Instance column indicates the name of the instance; |V| column represents the number of vertices in G; the column Value represents the value of solution returned by \(Approx\_Kon\); the next two three columns, i.e., Best, Avg, ATTB, and ATET, respectively, represent the best-so-far value, average value, average time to reach the best solution (in seconds), and average total execution time (in seconds) over 20 runs obtained by GA1 and GA2; the last five columns, i.e., Best, Avg, SD, ATTB, and ATET, respectively, represent the best-so-far value, average value, standard deviation, average time to reach the best solution (in seconds), and average total execution time over 20 runs obtained by ABC_MEDKC. The best Avg results are highlighted in bold in both Tables 2 and 3. The code for the polynomial-time approximation algorithm (\(Approx\_Kon\)) (Könemann et al. 2004) for the MEDKC problem is available to us; we executed this code on considered instances using the same computer configuration used for ABC_MEDKC and reported the results of \(Approx\_Kon\) in Tables 2 and 3.

Table 2 presents the results of 49 BX weighted instances. In comparison with GA1, ABC_MEDKC, in terms of Best, is better on 10, same on 26 and worse on 13; ABC_MEDKC, in terms of Avg, is better on 35, same on 9 and worse on 5. comparing with GA2, ABC_MEDKC, in terms of Best, is better on 27, same on 16 and worse on 6; ABC_MEDKC, in terms of Avg, is better on 45, same on 2 and worse on 2. The results in Table 2 indicate that ABC_MEDKC, in terms of Avg, demonstrates higher robustness compared to GA1 and GA2. In comparison to \(Approx\_Kon\), ABC_MEDKC outperforms in both Best and Avg on all 49 BX weighted instances.

Table 3 reports the results of 42 BB weighted instances. The results reveal that ABC_MEDKC dominates GA1 and GA2, not only in terms of solution quality, but also in terms of computational time. Comparing with GA1, ABC_MEDKC, in terms of Best, is better on 8 and is same on 34; ABC_MEDKC, in terms of Avg, is better on 33, same on 8 and worse on 1. Comparing with GA2, ABC_MEDKC, in terms of Best, is better on 34 and is same on 8; ABC_MEDKC, in terms of Avg, is better on 41 and is same on 1. In comparison to \(Approx\_Kon\), ABC_MEDKC outperforms in both Best and Avg on all 42 BB weighted instances.

In terms of computational time (ATET), ABC_MEDKC is much faster than GA1 and GA2 on 49 BX weighted instances except one instance (g1000-1-01 (K = 20)) on GA1 reported in Table 2; however, ABC_MEDKC is much better than GA1 in terms of Avg on this instance (g1000-1-01 (K = 20)). Also, ABC_MEDKC is much faster than GA1 and GA2 on 42 BB weighted instances except one instance (steind5 (K = 20)) reported in Table 3; however, ABC_MEDKC is much better than GA1 in terms of Avg, and is much better than GA2 in terms of Best and Avg on this instance (steind5 (K = 20)). It is important to note that the execution environment for GA1 and GA2 in (Matic et al. 2017) was a PC with a 3.40 GHz Intel Core i7-4770 processor and 8 GB RAM, while ABC_MEDKC is executed on a PC with a 3.2 GHz \(\times \) 4 Intel Core i5 processor and 4 GB RAM.

In summary, the results of ABC_MEDKC on 49 BX weighted instances and 42 BB weighted instances highlight its superior robustness compared to GA1 and GA2, in both solution quality (Avg) and computational time (ATET). Additionally, ABC_MEDKC identifies new Best values in 17 out of 91 instances, as indicated by the instances highlighted in bold in Tables 2 and 3.

Table 2 Results of \(Approx\_Kon\), GA1, GA2, and ABC_MEDKC on BX instances
Table 3 Results of \(Approx\_Kon\), GA1, GA2, and ABC_MEDKC on BB weighted instances
Fig. 1
figure 1

Evolution of average solution quality over average number of generations

5.4 Convergence behavior of ABC_MEDKC

This subsection discusses the convergence behavior of ABC_MEDKC. To carry out this experimentation, three instances < g400_4_01 (k = 10), bb33\(\times \)33_1 (\(k=15\)), steinc5 (\(k=10)>\) are considered. Figure 1a–c illustrates the evolution of solution quality (Avg) against the successive average number of generations. The X-axis represents the “Average Number of Generations" over 20 runs, while the Y-axis represents the “Average Solution Quality" over 20 runs. It is noteworthy that we opted for successive average number of generations instead of average total execution time (ATET) or the termination criterion of ABC_MEDKC, as the total number of generations executed within a given termination criterion of ABC_MEDKC can be easily computed. The curves in Fig. 1a–c depict a continuous decrease in the fitness of the solution obtained by ABC_MEDKC with the increase in generations.

5.5 Impact of neighborhood operators (Nbr_cv and Nbr_swp)

Before considering the use of both neighborhood operators (Nbr_cv and Nbr_swp) in a mutually exclusive way in ABC_MEDKC, a preliminary experiment was conducted. Two variants, namely, ABC_Nbr_cv and ABC_Nbr_swp, were created by disabling Nbr_swp and Nbr_cv, respectively, in ABC_MEDKC. These variants were executed on some benchmark instances using a setup similar to ABC_MEDKC. The results, including the average solution quality (Avg) and average total execution time (ATET) of ABC_Nbr_cv, ABC_Nbr_swp, and ABC_MEDKC, are reported in Table 4. The findings indicate that ABC_MEDKC, utilizing both neighborhood operators (Nbr_cv and Nbr_swp) in a mutually exclusive way, achieves better average solution quality (highlighted in bold) on most of the considered instances while requiring less computational time. It is noteworthy that the Nbr_swp operator is computationally more expensive compared to Nbr_cv. The use of both operators (Nbr_cv and Nbr_swp) in a mutually exclusive way in ABC_MEDKC demonstrates its effectiveness in obtaining high-quality solutions within a reasonable computational time.

5.6 Statistical analysis

Table 4 Results of ABC_Nbr_cv, ABC_Nbr_swp, and ABC_MEDKC on some benchmark instances

For the statistical analysis, a two-tailed nonparametric Wilcoxon’s signed-rank test was conducted on the best (Best) and average solution quality (Avg) values across 91 benchmark instances (49 BX instances and 42 BB instances, as reported in Tables 2 and 3) using Wilcoxon’s Signed-Rank test calculator (Wilcoxon 1945). The significance criterion was set at 0.05. The results of Wilcoxon’s signed-rank test, reported in Tables 5 and 6, show that ABC_MEDKC finds significant difference with GA1 and GA2.

6 Conclusion

This paper presents an artificial bee colony algorithm, denoted as ABC_MEDKC, for the minimum edge-dilation K-Center (MEDKC) problem on a connected, undirected and edge-weighted graph. ABC_MEDKC incorporates two adaptable neighborhood operators specifically tailored for this problem. The synergistic coordination of all components within ABC_MEDKC contributes to achieving solutions of high quality for the MEDKC problem. To evaluate its performance, ABC_MEDKC is compared with state-of-the-art approaches, namely two variants (GA1 and GA2) of the genetic algorithm (Matic et al. 2017), using available benchmark instances. Computational results show that ABC_MEDKC dominates the existing two variants of genetic algorithm in both solution quality and computational time. Notably, ABC_MEDKC exhibits greater robustness (in terms of average solution quality) compared to the genetic algorithm variants (GA1 and GA2). ABC_MEDKC also dominates an existing polynomial-time approximation algorithm (\(Approx\_Kon\)) in terms of finding solutions of high quality. Moreover, ABC_MEDKC finds new values for 17 instances out of 91 instances. The paper also explores the convergence behavior of ABC_MEDKC and conducts a statistical test, revealing a significant difference with GA1 and GA2.

Table 5 Statistical test on the results of Best values
Table 6 Statistical test on the results of Avg values

As future work, the research can be extended for the development of new metaheuristic techniques specifically tailored for the MEDKC problem.