Since the initial phase is randomised, the heuristic
is restarted several times and returns the best feasible
solution found among all the attempts.
3 COMPUTATIONAL RESULTS
In this section we report the results obtained by the
computational experiments conducted on the revisited
branch and bound algorithm, that in the following we
will denote as RevBB. All the experiments are con-
ducted on a Linux server, with processor Intel Xeon
E5-2620 2.1 GHz and 16 GB of RAM, that is the same
machine used in Boggio Tomasaz et al. (2023a). The
algorithm is coded in C99 and compiled with GNU
GCC 8.3.0, and runs in a single thread.
The instances are the ones presented in the litera-
ture by Macambira et al. (2019) and the ones added
by Hosteins (2020) and extended in Boggio Tomasaz
et al. (2023a). They can be found at this link: https:
//homes.di.unimi.it/cordone/research/wssp.html. The
graphs are randomly generated in accordance with the
Erd
˝
os-Renyi model. In the former set the number
of vertices progressively rises from 10 to 30 and the
number of edges is |E| = δ·|V |·(|V |−1)/2, where the
density parameter assumes values δ ∈ {0.3,0.5,0.7}.
There are weighted instances with random weights
extracted from a uniform distribution in {1,...,100}
and unweighted instances with weights uniformly set
to 1. This benchmark consists of 21 · 3 · 2 = 126 in-
stances. In the latter set, the number of vertices is
|V | ∈ {20, 25,30,35,40,50,60} and the density pa-
rameter assumes values δ ∈ {0.1,0.2,0.3,0.4}. For
each combination of |V | and δ there are 5 weighted
instances with random uniform integer weights be-
tween 1 and 10 and 5 unweighted instances, that is
7 · 4 · 5 · 2 = 280 instances overall.
3.1 Effect of the Revised Relaxation
In this section we compare the computational results
of the revisited algorithm with those reported in Bog-
gio Tomasaz et al. (2023a) for the original branch and
bound within the time limit of one hour. Tables 1
and 2 provide in the first two columns the density δ
and the size |V | of the instances. The following four
columns show the gap (formatted as a percentage), the
number of solved instances in each group, the com-
putational time in seconds (CPU) and the number of
branching nodes (BN). Each value is averaged over
the 5 instances with the density and size indicated
in the corresponding row. The gap is computed as
(UB − LB)/LB, where UB and LB are the best upper
and lower bounds found by the algorithm. The last
four columns contain the same information for algo-
rithm RevBB. The computational times and the num-
bers of branching nodes marked with ∗ point out that
the exhaustion of memory anticipated the termination
on some instances. The symbol OM indicates that all
5 instances of a group went “out of memory”.
In the weighted case (see Table 1), the revisited al-
gorithm leaves only 2 unsolved instances out of 140,
instead of 5. One of the newly solved instances was
previously terminated because it exceeded the avail-
able memory. The two remaining unsolved instances
strictly improve both the upper and the lower bound:
the residual gap is about one third of its original value.
The computational time and the number of branch-
ing nodes is roughly halved, except for the instances
in which the memory is no longer exhausted and the
computation can proceed for a longer time.
Considering the unweighted instances (see Ta-
ble 2), the unsolved ones decrease from 21 to 16 out
of 140. The ones with an out-of-memory termination
decrease from 11 to 10. On average, the gaps of the
16 unsolved instances are more than 2 times smaller,
with the exception of the instances with δ = 0.2, for
which there is a moderate increase. In this specific
case, the weaker lower bound is not completely coun-
terbalanced by its advantages, leading to an over-
consumption of memory. The comparison between
the computational times and the number of branch-
ing nodes still shows an improvement, in particular
for the denser instances, but less pronounced than in
the weighted case. The instances with |V | = 60 and
δ ∈ {0.1, 0.2} are difficult to compare from this point
of view because of the anticipated termination.
3.2 Effect of the Initial Heuristic
In this section we present the results obtained by
exploiting the SDT heuristic presented in Bog-
gio Tomasaz et al. (2023b) as an initial incumbent
for the RevBB algorithm. Tables 3 and 4 share the
same structure of Tables 1 and 2, but show the re-
sults obtained by RevBB and SDT+RevBB. Since the
RevBB algorithm solves to optimality the instances
with |V | ≤ 35 in few seconds, we do not consider
those instances in the comparison. The time limit for
SDT+RevBB is one hour, to obtain a fair comparison
with the original branch and bound. The computa-
tional time for the SDT heuristic is set to 0.1 seconds
for |V | = 40, 1 second for |V | = 50 and 10 seconds
for |V | = 60. The aim is to keep into account the
longer time required by each iteration as the size of
the instance grows, but also to slightly increase the
number of iterations, that is in the range of a few
thousands. The heuristic runs with the same parame-
A Revisited Branch and Bound Method for the Weighted Safe Set Problem
117