Designing quantum networks using preexisting infrastructure

We consider the problem of deploying a quantum network on an existing fiber infrastructure, where quantum repeaters and end nodes can only be housed at specific locations. We propose a method based on integer linear programming (ILP) to place the minimal number of repeaters on such an existing network topology, such that requirements on end-to-end entanglement-generation rate and fidelity between any pair of end-nodes are satisfied. While ILPs are generally difficult to solve, we show that our method performs well in practice for networks of up to 100 nodes. We illustrate the behavior of our method both on randomly-generated network topologies, as well as on a real-world fiber topology deployed in the Netherlands.

We consider the problem of deploying a quantum network on an existing fiber infrastructure, where quantum repeaters and end nodes can only be housed at specific locations.We propose a method based on integer linear programming (ILP) to place the minimal number of repeaters on such an existing network topology, such that requirements on end-to-end entanglement-generation rate and fidelity between any pair of end-nodes are satisfied.While ILPs are generally difficult to solve, we show that our method performs well in practice for networks of up to 100 nodes.We illustrate the behavior of our method both on randomly-generated network topologies, as well as on a real-world fiber topology deployed in the Netherlands.

I. INTRODUCTION
The quantum internet will provide an infrastructure for quantum communication between any two devices in the world [1][2][3][4].This can be used to perform tasks which are provably impossible with the classical internet.Many of these are cryptographic in nature and allow unconditional security, such as quantum key distribution [5,6], secure multi-party cryptography [7] and blind quantum computation [8].Other applications of the quantum internet include fast byzantine agreement [9] and clock synchronization [10].
A major challenge in the construction of terrestrial quantum networks is to overcome exponential loss in optical fibers.In order to enable quantum communication over large distances, quantum repeaters are required.These can form a quantum-repeater chain in which consecutive nodes are connected by elementary links.Quantum repeaters are a very active research area and major advances have been achieved recently [11][12][13][14][15].However, the technology is not yet at the stage of practical deployment, and we anticipate that the first practical quantum repeaters will be costly.It seems likely that before a global quantum internet is effected, smaller quantum networks connecting a limited number of end nodes are deployed.A cost-efficient way of deploying such networks is using existing classical infrastructure by converting already-deployed optical fiber and installing quantum repeaters at strategic locations.
We model a classical fiber network which forms the basis of a quantum network as an undirected, weighted graph G = (N , F, L).The nodes N are partitioned into a set of end nodes C ⊂ N and a set of potential repeater locations R = N \ C. The goal of the quantum network is to enable quantum communication between end nodes.Potential repeater locations are any location in the network where a quantum repeater could be placed.Such a location could, for example, be a hub in the classical network with the facilities required to run a quantum repeater.The edges of the graph are the fibers of the network, F, where L(f ) is the length of fiber f ∈ F. In case a quantum repeater is installed at a potential repeater location, the potential repeater location becomes a quantum-repeater node.When deploying a quantum network based on a classical fiber network, it is essential to determine which potential repeater locations should be turned into quantum-repeater nodes.
In order to have an operational quantum network, nodes must be connected by elementary links.For many quantum-repeater schemes (such as those using heralded entanglement generation [16]), elementary links consist of fibers with active elements measuring qubits.Therefore, when deploying a quantum network based on a classical fiber network, it must also be determined which fibers to convert into elementary links.Here, we consider that elementary links can be constructed from any number of consecutively-adjacent fibers in the graph G (passing through potential repeater locations).Both fibers and potential repeater locations can be part of multiple elementary links, which is motivated by the fact that fibers are typically constructed in bundles (meaning that each elementary link could, in fact, use the same fiber bundle but a different fiber).Additionally, multiplexing over different wavelengths could be used to enable the use of a single fiber in multiple elementary links.For an example of how a (very) small classical fiber network can be used to create a quantum network, see Figure 1.
Here, we introduce the problem of determining how to construct a quantum network using a preexisting classical fiber network as the repeater-allocation problem.We define it as follows: Figure 1: Example of how a quantum network can be constructed.(a) Graph representing a simple fiber network.Nodes A and B are end nodes, while the other two nodes are potential repeater locations.(b) Quantum network that is constructed using the preexisting fiber network.The first node from A is used as a quantum-repeater node (blue hexagon) and there are two elementary links.One elementary link is made from A to the quantum-repeater node, while the other starts at the quantum-repeater node and ends at B.
Repeater-Allocation Problem: Given a classical fiber network corresponding to the undirected, weighted graph G = (N , F, L) with end nodes C ⊂ N .Which of the potential repeater locations R = N \ C should be turned into quantum-repeater nodes, and which fibers should be converted into elementary links, such that a quantum network is obtained which satisfies a set of network requirements, while the associated costs are minimized?
In this paper we present, to the best of our knowledge for the first time, a method which solves the repeaterallocation problem.Here, we only consider the costs associated to installing quantum repeaters, as we expect that the first practical quantum repeaters will come at a high cost.Furthermore, the set of network requirements that we consider are the following: 1 Rate and fidelity.
The quantum network must be able to distribute bipartite entangled quantum states between any pair of end nodes at some minimum rate, which we denote R min .Furthermore, the states must have some minimum fidelity to a maximally entangled state, which we denote F min .The network must be able to do this for every pair of end nodes simultaneously.
In a quantum-repeater chain with fixed hardware, the rate of entanglement distribution is limited by loss and noise in elementary links and in quantum repeaters.Therefore, it is generally possible to lower bound the rate by upper bounding the number of quantum repeaters (and thereby the number of elementary links), and the length of each elementary link (assuming the photon loss probability per unit length is constant).Similarly, fidelity is limited by noisy operations in quantum repeaters, while it can also be a decreasing function of the elementary link length (this can be, for example, due to dark counts in detectors).Therefore, fidelity too can be lower bounded by upper bounding the number of quantum repeaters and the elementary link length.We use these bounds to assess whether the rate and fidelity between a pair of end nodes is sufficient.For any R min and F min , we can find N max and L max such that a repeater chain of N max repeaters and elementary links of length L max can deliver entangled states at rate R min with fidelity F min .Then, we consider two end nodes capable of receiving entangled states with at least rate R min and at least fidelity F min if there is a free path between them which contains at most N max repeaters and of which each elementary link is at most L max long.How exactly N max and L max can be determined from R min and F min is specific to the quantum-repeater architecture and depends on various performance parameters.We give a toy-model calculation in Section IV B as an example.Note that when considering a quantum-repeater architecture which is not based on entanglement distribution, the method presented in this paper is still applicable if a performance metric like rate and fidelity can be determined which can be lower bounded by upper bounding the number of repeaters and the elementary link lengths of a repeater chain.
When a part of a quantum network breaks down, all other requirements should still be met.We quantify this using the minimum number of quantum-repeater nodes or elementary links (it can be any combination) that need to break down before one of the other requirements can no longer be met.Here, we use the symbol K to refer to this number.
3 Repeater capacity.Quantum-repeater nodes should never be required to operate above their capacity in order to meet all other network requirements.We define the capacity of a quantum-repeater node as the maximum number of quantumcommunication sessions it can facilitate simultaneously.In an entanglement-based network, this could be directly related to the number of entangled states that can be stored in memory or the number of Bell-state measurements that can be performed simultaneously.Here, we use the symbol D to refer to the capacity of the quantumrepeater nodes.

II. RESULTS
In this section we present a method, detailed in Box I, which aids in the design of a quantum network using existing classical infrastructure.Specifically, given a fiber network, our method makes it possible to choose at which locations quantum repeaters should be installed.This is done such that entangled states can be distributed between all pairs of end nodes simultaneously with a minimum rate and fidelity.Furthermore, our method guarantees that the resulting quantum network is robust against failure of quantum repeaters and elementary links, and can take finite capacity of quantum repeaters into account.At the same time, our method minimizes the total number of quantum repeaters that need to be installed.We dub the problem that our method solves the repeater-allocation problem.
• Set of end nodes C ⊂ N .
• Minimum rate Rmin and fidelity Fmin required by end nodes.a • Required robustness parameter K (number of quantum-repeater nodes and elementary links that must be incapacitated before network operation is compromised).
• Capacity parameter D (number of quantum-communication sessions that one quantum repeater can facilitate simultaneously).

Method
1. Determine values for the parameters Lmax and Nmax such that a quantum-repeater chain consisting of Nmax repeaters and elementary links of length Lmax is able to deliver entangled states at rate Rmin with fidelity Fmin to a maximally entangled state.

Construct the set of potential repeater locations
where ∈R implies picked uniformly at random.
4. For every (s, t) ∈ Q, construct the set and then construct the set 5. For every (u, v) ∈ E, determine the shortest path from u to v in the fiber-network graph G. Store the length of the path as L (u, v) and the fibers making it up as F (u, v) .
6. Solve the link-based formulation in Box III using an ILP solver.Store the values of the variables x q,k uv and yu. 7. Apply the path extraction algorithm, i.e.Algorithm 1, to obtain the set P * .For every (u, v) ∈ E, set x q,k uv = 0 if there is no p ∈ P * such that (u, v) ∈ p.

Solution
• Every potential repeater location u ∈ R for which yu = 1 should be used as a quantum-repeater node.
• For every (u, v) ∈ E for which x q,k uv = 1 for some value of q and k, an elementary link should be constructed using the fibers F (u, v) .
Box I: Method to solve the repeater-allocation problem.Key to our method is integer linear programming (ILP), which can be used to obtain the optimal repeater placement with an optimization solver such as Clp [17], Gurobi [18] or CPLEX [19].Our method has been tested both using a real fiber network and a large number of randomized graphs, on which we report in Sections III A and III B respectively.The real network contains four end nodes and 50 potential repeater locations, and a solution was found in 74 seconds using a computer running a quad-core Intel Xeon W-2123 processor at 3.60 GHz and 16 GB of RAM, demonstrating that the method is feasible for realistically-sized networks.
a Instead of a minimum rate and fidelity, one can also use the minimum value(s) for other performance metric(s), as long as these can be lower bounded by upper bounding the number of repeaters and elementary link lengths of a quantum-repeater chain.
Here, we put forward two different ILP formulations.The first, which we call the path-based formulation (see Box II), is based on enumerating and then choosing paths between end nodes of the quantum network.It is relatively easy to show and understand that this formulation indeed solves the repeater-allocation problem (see Section IV A).However, it is not efficient, as the number of variables and constraints in the formulation grows exponentially with the size of the network.The second formulation is the link-based formulation (see Box III).This formulation is much more efficient than the path-based formulation, as it only grows polynomially with the size of the network.Therefore, our method as described in Box I uses the link-based formulation.It is, however, harder to see that the link-based formulation can be used to solve the repeater-allocation problem.Yet, the link-based formulation is equivalent to the path-based formulation, as we show in Section IV C.
The structure of the paper is as follows.In the remainder of this section, we present our method for solving the repeater-allocation problem and introduce both the intuitive path-based formulation and the efficient link-based formulation.Next, in Section III, we first give an example of the use of our method on a real fiber network in the Netherlands.We also study the behaviour and performance of the method on a large number of randomly-generated network graphs.Furthermore, we present ways in which our method can be extended, and we discuss its limitations.Finally, in Section IV, we argue that the path-based formulation can indeed be used to solve the repeater-allocation problem, we give an example of a rate-fidelity analysis, we sketch a proof of the equivalence of the path-based formulation and the link-based formulation, we explain how we generate random network graphs and we present the scaling of the two ILP formulations.

A. Path-Based Formulation
The main idea behind the path-based formulation, which is shown in Box II, is to enumerate and then choose paths for every (s, t) ∈ Q, where Q is the set of all ordered pairs of end nodes as defined in Equation (2).A path between s and t is a sequence of elementary links that does not contain any loops and connects s and t.Quantum-repeater nodes are then allocated in such a way that they enable the chosen paths to be used.This can be considered an instance of the set cover problem [20].To guarantee a minimum rate R min and fidelity F min , we require every chosen path to contain at most N max quantum-repeater nodes, and we require every elementary link in the path to be at most L max long.N max and L max are functions of R min and F min , and what these functions look like depends on the specific quantum-repeater implementation under consideration.For an example of how N max and L max can be derived from R min and F min , see Section IV B. Furthermore, to guarantee the network is robust, we choose K different paths per end-node pair.They are chosen such that none of the K paths share a quantum-repeater node or an elementary link.Finally, to account for the finite capacity of quantum repeaters, we choose the paths such that every quantum-repeater node is only used by at most D different paths.It can be intuitively understood that any quantum network accommodating the use of all these paths, will satisfy all network requirements considered in this paper.
Key to the path-based formulation are the binary decision variables x p , which are defined for every path p ∈ P = ∪ (s,t)∈Q P (s,t) , where P (s,t) is the set of all possible paths from end node s to end node t.The elementary links that can be contained by a path p ∈ P (s,t) must all be in E (s,t) , which is defined in Equation (3).Each x p has value 1 when p is considered part of the chosen set of paths, and 0 otherwise.Furthermore, there are the binary decision variables y u for all u ∈ R. y u is 1 if a quantum repeater is placed at potential repeater location u, and 0 otherwise.Constraints (6) to (10) guarantee that these variables are chosen such that all network requirements are satisfied.The objective function (5) ensures that they are chosen such that the total number of quantum-repeater nodes is minimized.It is argued that solutions to the path-based formulation are indeed solutions to the repeater-allocation problem in Section IV A.
The path-based formulation requires us to define one variable x p corresponding to each path p ∈ P. Hence, the total number of variables as well as the number of constraints are at least |P|, which is O(|N |!).Therefore the size of the input to the ILP solver scales exponentially with the number of nodes.This makes the path-based formulation unsuitable for designing quantum networks based on large fiber networks.Our implementation of the path-based formulation in CPLEX can be found in the repository [21].In the next section, we give a more efficient formulation.

B. Link-Based Formulation
Here we present the link-based formulation, which can be found in Box III.This formulation is inspired by the capacitated facility location problem [20].Instead of choosing which paths to use, we choose which elementary links |p|xp ≤ Nmax + 1 ∀p ∈ P (7) where rup = 1 if path p uses u as a quantum-repeater node 0 otherwise ∀u ∈ R, p ∈ P Box II: Path-based formulation.
to use.Quantum repeaters can then be placed such that each chosen elementary link is enabled.To this end, for each end-node pair q ∈ Q, for every elementary link (u, v) ∈ E q and for k = 1, 2, . . ., K, we define the binary decision variable x q,k uv .It can be thought of as indicating whether elementary link (u, v) is used in the k th path used to connect end node s to end node t, where q = (s, t).Furthermore, we again use the variables y u that indicate whether node u ∈ R is used as a quantum-repeater node. (u,v)∈Eq Box III: Link-based formulation.
Because the number of elementary links scales polynomially with the number of nodes, both the number of variables and the number of constraints also scale polynomially with the number of nodes |N |.In particular, they are O(|N | 2 ) (see Section IV E for a derivation).Our implementation of the link-based formulation in CPLEX can be found in the repository [21].
In Section IV C, we sketch the proof of the equivalence of the path-based formulation and the link-based formulation.Furthermore, we sketch why the variables x q,k uv and y u still provide a solution to the link-based formulation after performing step 7 of Box I.The reason this step is included in our method is because, otherwise, elementary links could be included in the solution which are not necessary to meet the network requirements.The detailed version of the proof can be found in Appendix B. Since the link-based formulation scales much more favourably with the size of the fiber network under consideration, it is more efficient to use this formulation when solving the repeater-allocation problem for large networks.

III. DISCUSSION
In this section we illustrate our method as implemented by the link-based formulation using the Python API of CPLEX version 12.9 [19].The corresponding code can be found in the repository [21].Furthermore, we investigate the effect of varying network-requirement parameters and discuss possible extensions and limitations of our method.

A. Example on a Real Network
Here, we demonstrate our method by solving the repeater-allocation problem for a real fiber network.The fiber network that we consider is the core network of SURFnet.The latter is a network provider for Dutch educational and research institutions and has provided us with the network data, which is available in the repository [21].The network graph is depicted in Figure 2.
As end nodes of the network, we have chosen the cities of Delft, Enschede, Groningen and Maastricht.In this example, we consider an entanglement-based quantum network utilizing massive multiplexing as described in e.g.[22].For the end nodes, we require a minimum rate of R min = 1 Hz (one entangled state per second) and a fidelity to a maximally entangled state F min = 0.93.Furthermore, we set the robustness parameter to K = 2 (thus requiring that any single quantum repeater or elementary link in the network can break down without compromising network functionality), and we set the capacity parameter to D = 4 (which, in this case, means that we assume each quantum repeater can perform four Bell-state measurements simultaneously).
The first step of our method requires us to calculate the L max and N max corresponding to the minimal rate and fidelity we have chosen.This requires us to study the behaviour of a quantum-repeater chain consisting of N + 1 elementary links of length L each.L max and N max then have to be chosen as the largest possible values for L and N respectively such that the repeater chain still achieves the required rate and fidelity.Here, we make a couple of simplifying assumptions to make the calculations more tractable.Particularly, we assume elementary links generate Werner states, and we assume that the only losses are due to fiber attenuation and probabilistic Bell-state measurements (which we take to have a 50% success probability).In Section IV B, we perform the calculation and find that for an elementary-link fidelity F link = 0.99, number of multiplexing modes M = 1000, speed of light in fiber c fiber = 200, 000 km/s and attenuation length L att = 22 km, we have N max = 6 and L max = 136 km.
The rest of the steps of the method in Box I have been performed using a Python script and CPLEX [21].The resulting solution is shown graphically in Figure 3.All chosen repeater nodes are shown as blue hexagons, while all fibers that are used in elementary links are drawn as thick lines.We see that repeaters are placed around Groningen in order to bridge the large distance to the other end nodes without exceeding the maximum elementary-link length L max .Additionally, placing quantum-repeater nodes close to Groningen means they can be used for several of Groningen's outgoing connections.There are multiple such nodes close together because each only has a limited capacity (D = 4), and the redundancy increases the robustness of the network.
On our setup (see Section II), it took us approximately 74 seconds to find the optimal solution to the link-based formulation for this network.Note that a feasible solution is a combination of decision variable values that satisfy all the constraints, while the optimal solution is a feasible solution that also minimizes the objective function.

B. Effect of Network-Requirement Parameters
Here, we demonstrate and investigate the effect of the different network-requirement parameters on the outcome of our method.The network-requirement parameters are, in principle, the minimum rate R min , the minimum fidelity F min , the robustness parameter K and the capacity parameter D. However, since R min and F min are translated into a maximum number of repeaters N max and a maximum elementary-link length L max in our method, we here consider the network-requirement parameters to be L max , N max , K and D. This way, we can keep our discussion agnostic about the exact hardware used to create a quantum network and how R min and F min are mapped to N max and L max .
First we give a visual demonstration on how the different network-requirement parameters affect the repeater placement.To this end, we have created a network graph with end nodes in the corners of the network and 10 possible repeater locations randomly distributed in between the end nodes.For details on how the graph was obtained, see Section IV D. While keeping the network fixed, we vary the network-requirement parameters D, K and L max .In Figures 4a to 4c, we explore how the robustness parameter influences the total number of required quantum repeaters.Since each repeater has a capacity of D = 6 to distribute entanglement between the six end-node pairs, and because the network is set up in such a way that each path needs exactly one quantum-repeater node to connect end nodes without elementary links exceeding L max = 0.9, the optimal solution always contains K repeaters.In Figures 4d to 4f on the other hand, we see that as the capacity of quantum repeaters is varied from D = 1 to D = 3, the required number of quantum repeaters decreases when D increases.Note that since K = 1, the optimal solution here always happens to contain |Q|/D repeaters.Finally, in Figures 4g to 4i we see that as we allow for longer elementary  links to be used, the total number of repeaters is decreased.If we would increase L max even further, at a certain point every end node can be connected to another end node with a direct elementary link and hence the number of repeaters will drop to zero.The degeneracy of the optimal solution is visible from the fact that the solutions with two repeaters for K = 2 (Figure 4b), D = 3 (Figure 4f) and L max = 0.75 (Figure 4h) are not equal.In Section III D, it is discussed how this degeneracy can be lifted.We do not show the effect of N max .Since the total number of repeaters is already minimized, changing the value of N max does not change the repeater allocation, but only determines whether a feasible solution exists at all.
Considering how the repeater placement on a single network varies with the network-requirement parameters can offer insight into how our method operates.However, it does not provide a general investigation into the properties of our method.In order to make more general and quantitative statements about our method, we will next consider the effect of varying network-requirement parameters on the repeater allocation for an ensemble of random networks.In this work, we construct random network graphs using random geometric graphs.That is, network graphs are constructed by scattering nodes randomly on a unit square.Edges are put only between nodes if the Euclidean distance separating them is smaller than some number, which is called the radius of the random geometric graph.The nodes which form the convex hull of the network are chosen as end nodes, so that the others are potential repeater locations.This choice is motivated by the fact that any potential-repeater locations that do not lie between end nodes would probably not play an important role anyway.For a more elaborate account of how we generate random network graphs, see Section IV D.
Figure 4: Solutions obtained using our method for an example network graph using the network-requirement parameters L max = 0.9, N max = 3, K = 1 and D = 6, unless noted otherwise in the caption of a specific solution.(a)-(c) Visualization of the effect of K.A higher robustness implies that we require more repeaters.(d)-(f ) Visualization of the effect of D. As the capacity of quantum-repeater nodes increases, multiple paths can use the same repeater and hence the overall number of repeaters decreases.(g)-(i) Visualization of the effect of L max .When longer elementary-link lengths are allowed, less quantum-repeater nodes are required to bridge the distance between end nodes.
We here report how the number of placed repeaters and the (vertex) connectivity of quantum networks designed using our method vary as a function of the network-requirement parameters.The number of placed repeaters is interesting to consider since the aim of our method is to minimize this.On the other hand, the connectivity is interesting since it lower bounds the minimum number of quantum repeaters that need to break down before any pair of end nodes becomes disconnected, thereby giving an indication of how robust a quantum network is.Note that connectivity is not the same as the robustness parameter K, which lower bounds the minimum number of quantum repeaters or elementary links that need to break down before end nodes can no longer distribute entanglement with a minimum rate and fidelity, while at the same time taking repeater capacity into account.We have first generated 1000 random network graphs for which our method was able to find solutions for the parameter values L max = 0.9, N max = 6, K = 6 and D = 4.Then, while keeping all other parameters constant, we have varied each of the parameters D, K and L max .This has been done in such a way that all considered values are less restrictive than the original values, such that we can be sure that a solution exists for each parameter value.Of each resulting quantum network, we determine the number of repeaters and the connectivity, and for each parameter value we determine the average number of repeaters and the average connectivity over all 1000 quantum networks.
In Figures 5a and 5b, we show the number of repeaters and the connectivity as a function of the repeater capacity D. We see that both the number of repeaters and the connectivity decrease as D increases, and they both accurately follow an exponential fit in the domain under consideration.In Figures 5c and 5d, we show how the number of repeaters and connectivity vary as a function of the robustness parameter K.We see that both increase linearly in the domain under consideration.For D (K) the number of repeaters decreases (increases) following the same line of reasoning as we mentioned above for the visual demonstration.Generally, we expect the connectivity to follow the change in the number of repeaters, because a network with less quantum repeaters is easier to disconnect.Finally, in Figures 5e and 5f, we investigate the effect of L max on the number of repeaters and connectivity.While the number of repeaters decreases, the connectivity increases, although they both flatten from L max = 1.2.The number of repeaters does not decrease to zero because K = 6.Therefore, even if L max is large enough to allow for paths between end nodes with zero quantum-repeater nodes, there are still at least five quantum-repeater nodes required to make the network Figure 5: Simulation on 1000 random geometric graphs with a radius of 0.9 and n = 25 nodes for varying network parameters.We use L max = 0.9, N max = 6, K = 6 and D = 4, and except for the varied parameter.In the plots, each of the points represents the average number of placed repeaters or average connectivity over all samples for each value of (a)-(b) the capacity parameter D, (c)-(d) the robustness parameter K or (e)-(f ) the maximum elementary-link length L max .We either use a linear or an exponential function for the fits.The error bars represent one standard deviation of the mean.Solving an instance to optimality requires approximately 30 seconds on average.robust against the breakdown of direct elementary links between end nodes.On the other hand, the connectivity increases since it also takes paths through other end nodes into account in its computation, and with an increasing value of L max , we expect more direct elementary links to appear.

C. Computation Times
Even though the link-based formulation has a scaling of O(|N | 2 ) in terms of the number of variables and constraints, it remains an ILP.In general, ILP's are NP-hard and thus generally require an exponential amount of time to solve.In order to investigate the performance of our method for varying network sizes, we determined the computation time for finding an optimal solution as a function of the number of nodes.The result is shown in Figure 6, in which we see that the computation time indeed increases exponentially.Nonetheless, instances on random geometric graphs with 100 nodes can be solved to optimality in about one minute on our setup (see Section II).
The computation time can be strongly affected by the network topology and the chosen parameter values, since these can alter the difficulty of finding an optimal solution as well as the number of variables and constraints (see Section IV E).However, the parameters that we use for Figure 6 are neither very strict nor loose and provide us with insight into the approximate scaling of the computation time, rather than the worst-case behavior.Note that we expect that, in practical use cases, the topology and the parameter values will be determined once and remain more or less fixed, which implies that the repeater-allocation problem will not need to be solved repeatedly.This makes the increasingly large computation time for sizable graphs or stringent parameters less problematic.

D. Extensions
There are various ways in which our method can be extended.Here, we present two possible extensions.Such extensions change the ILP formulation in Box III.The result of these is the generalized link-based formulation, which is presented in Box IV.To incorporate the extensions into the method in Box I, the generalized link-based formulation must be used where otherwise the link-based formulation would be used.
The first extension we can make is solving the repeater-allocation problem in case of heterogeneous network requirements.So far, we have considered the network requirements to be homogeneous, i.e. the same throughout the network.However, it can be the case that some end nodes require a higher rate and fidelity, that some end nodes need access to more robust quantum communication, or that quantum repeaters with a larger capacity can be placed at some potential repeater locations than at other.Then, we can define the network-requirement parameters on a per-end-node-pair or per-node basis.Specifically, for every pair of end nodes q ∈ Q, we define the minimum rate R q min and fidelity F q min of entanglement generation, and the required robustness parameter K q (in order to break Box IV: Generalized link-based formulation. communication between the end nodes q, at least K q quantum repeaters or elementary links must be incapacitated).Furthermore, for every potential repeater location u ∈ R, we define the quantum-repeater capacity D u .To incorporate this into the method, the input parameters must be adapted accordingly, and the maximum number of repeaters and maximum elementary-link length must be calculated for every pair of end nodes separately (i.e.L q max and N q max must be determined from R q min and F q min for each q ∈ Q).
A second extension has to do with the fact that the link-based formulation in Box III typically has a highlydegenerate optimal solution.That is, often there are multiple possible quantum-repeater placements for which all constraints are satisfied and the total number of quantum-repeater nodes is minimal.However, it might be the case that some solutions are more desirable than others.To pick out these solutions, one can define a secondary objective.This secondary objective can then be taken into account by defining a corresponding objective function, and adding it to the existing objective function, while scaling it such that it does not influence the optimal number of repeaters.In particular, the scale factor α should be chosen such that the secondary objective value does not exceed 1.This can be seen as a form of weighted goal programming [23].As an example, in Box IV, we use as secondary objective to minimize the total length of all used elementary links.Other secondary objectives, such as minimizing the largest elementary-link length, could be implemented in a similar fashion.

E. Limitations
In this section we discuss some of the limitations of the method we present in this work.Each limitation represents a way that our method could be further extended, but is beyond the scope of this paper.
A first major limitation is the complexity of ILP's.While we provide an efficient ILP formulation, in which the number of variables and constraints scales polynomially with the network size, it remains an ILP.This cannot be helped, as choosing whether a repeater should be placed at a certain potential repeater location is inherently binary.In general, it is NP-hard to solve an ILP.While we indeed observe exponential scaling of the computation time in Section III C, we are able to find optimal solutions of realistically-sized networks within tractable time using CPLEX, which is also demonstrated using a real network in Section III A. Conceivably, one can use heuristics or approximation algorithms to obtain solutions faster, although the solutions then may no longer be optimal.
Another limitation that we consider here is the fact that our method is agnostic about how elementary links are constructed.We assume that any number of fibers can be combined to form an elementary link.However, quantum-repeater protocols relying on heralded entanglement generation typically require the presence of a midpoint station with the capability to perform Bell-state measurements [16].If there are constraints on the placement of such stations, our method is insufficient.Conceivably, if such stations can only be placed at potential repeater locations, a modified version of our method could be used.Furthermore, we assume that an elementary link between two nodes is always constructed from the fibers which minimize the elementary-link length such that rate and fidelity are maximized.However, if one would like to incorporate the number of fibers (rather than elementary links) that need to be disabled before the quantum network is incapacitated as an additional network requirement (thereby guaranteeing more robustness), this may no longer be a useful assumption.It may then be better to try to construct different elementary links from different fibers as much as possible, such that individual fibers do not become too critical.

A. Explanation of the Path-Based Formulation
In Section II A, we introduced the path-based formulation.This ILP formulation can be found in Box II, and we claim that solutions to the path-based formulation can be used to construct solutions to the repeater-allocation problem.Here, we show how and why this can be done.
The idea behind the path-based formulation is to choose a combination of feasible paths that minimize the overall number of utilized repeaters.If a path is chosen that uses potential repeater location u ∈ R as a quantum-repeater node, a repeater should be placed at u.The binary variables x p are used to parameterize the chosen paths, while the binary variables y u are used to parameterize where quantum repeaters should be placed.A coupling between these variables is realized by Constraints (10): if a path p ∈ P is chosen in which a node u ∈ R is used as quantum-repeater node, the corresponding y u variables must have value 1. Conversely, when y u = 1 for a given repeater node u ∈ R, up to D paths can use this repeater node in order for the corresponding constraint to hold, thereby also imposing a limit on the repeater capacity.After all, if p∈P r up x p > D then more than D paths are chosen in which node u ∈ R is used as a repeater, which renders the solution infeasible.
Paths are moreover only considered useful if they can be used to deliver entanglement between end nodes with the minimum required rate R min and fidelity F min .In the path-based formulation, this is implemented by requiring chosen paths to contain at most N max + 1 elementary links, each with a length of at most L max .The values of N max and L max can be determined from R min and F min as detailed in Box I.These requirements are straightforwardly enforced by Constraints ( 6) and (7).Constraints (6) can only hold when x p = 0 for all paths that contain an elementary link ((u, v) ∈ p) which is too long (L((u, v)) > L max ).Similarly, Constraints (7) can only hold when x p = 0 for all paths for which the number of elementary links (|p|) exceeds the maximum (N max + 1).
Furthermore, the choice of paths must be such that it is guaranteed that up to K potential repeater nodes or elementary links can break down before there is no path available between any pair of end nodes that can deliver entanglement at the required rate and fidelity.This is implemented by choosing, per pair of end nodes, K different paths.All of these paths are chosen such that none of them share a quantum-repeater node.Since elementary links connect quantum-repeater nodes, this automatically also means that none of the paths share an elementary link.Therefore, when a quantum-repeater node or elementary link becomes incapacitated, this can disrupt at most one path between a pair of end nodes.When there are K break downs, in the worst case, this can disrupt all paths between a pair of end nodes.But as long as there are fewer break downs, there will be at least one path available.
Since every chosen path can deliver entanglement at the required rate and fidelity, this guarantees robustness of the quantum network against up to K break downs.It is enforced by Constraints (8) that there are exactly K paths chosen between every pair of end nodes.Furthermore, Constraints (9) make sure that the number of chosen paths connecting a pair of end nodes using u as a quantum-repeater node ( p∈Pq r up x p ) is at most one, thereby guaranteeing that all K paths are disjoint.Note that, when considering the quantum-repeater capacity, all chosen paths are taken into account.In other words, Constraints (10) guarantee that the repeater capacity is not exceeded when all paths are used simultaneously.Therefore, if one path between a pair of end nodes is disrupted and they are forced to switch to another path, it is guaranteed that none of the quantum repeaters along that path are overloaded.
It is now easy to obtain a solution to the repeater-allocation problem from the solution to the path-based formulation.Every potential repeater location u ∈ R for which y u = 1 in the solution to the path-based formulation should be used as a quantum-repeater node.Furthermore, each elementary link which is part of a chosen path ((u, v) ∈ p such that x p = 1) should be constructed.This is done using the fibers making it up (F (u, v) ).Then, the resulting quantum network will be such that all network requirements are satisfied.Furthermore, the number of quantum-repeater nodes will be minimal.This is because this number, which is exactly u∈R y u , is minimized by the objective function ( 5) of the path-based formulation.Therefore, the path-based formulation can indeed be used to solve the repeater-allocation problem.
B. Toy-Model Calculation of Nmax and Lmax from R min and F min In this section we calculate the maximum number of repeaters and maximum elementary-link length from the minimum required rate R min and fidelity F min using a toy model of a quantum-repeater chain.The quantum-repeater architecture that we consider is of the massively-multiplexed type as described in e.g.[22].The toy model that we consider here makes the following simplifying assumptions: • the states distributed over elementary links are Werner states, • the noise in the states distributed over elementary links is the only noise, • the only sources of photon loss are fiber attenuation and non-deterministic Bell-state measurements, • all processes except light traveling through fiber are instantaneous.

It is shown in Appendix
A that in this model, a repeater chain with N quantum repeaters, M entanglementdistribution attempts per round per elementary link, elementary-link length L, elementary-link fidelity F link , speed of light in fiber c fiber and a 50% Bell-state measurement success probability has the following end-to-end rate R and fidelity F : N max can now be obtained from the fidelity.Specifically, it is the lowest-integer solution to the equation To find L max , we can put the resulting value of N max into the equation The smallest value for L that solves Equation ( 35) is then L max .Note that the calculation here is somewhat simplified because the fidelity is not a function of L max .If both fidelity and rate would be functions of N and L, there would not exist a unique solution.In that case, there is some freedom in choosing N max and L max .
The calculation of N max and L max for the example parameters F min = 0.93, R min = 1 Hz, F link = 0.99, c fiber = 200, 000 km/s, M = 1000 and L att = 22 km results in N max = 6 and L max = 136 km (rounded down).

C. Proof of Equivalence
In this section we briefly outline the proof of why the path-based formulation and the link-based formulation are equivalent.The main idea is to use an optimal solution to the path-based formulation to construct a feasible solution to the link-based formulation and vice versa.We prove that this is always possible in such a way that the value of the objective function of the constructed feasible solution is the same as that of the original optimal solution.This can be used to show that the optimal objective values of both formulations are always the same.Therefore, the feasible solution to one formulation constructed from an optimal solution to another formulation is itself an optimal solution.
We say that two ILP formulations are equivalent if optimal solutions to one can be obtained from the other and vice versa, and therefore we conclude that the path-based formulation and the link-based formulation are equivalent.
To construct a solution to the link-based formulation using a solution to the path-based formulation, we use the elementary links that appear in chosen paths.More specifically, for each q = (s, t) ∈ Q and k = 1, 2, . . ., K, we set x q,k uv = 1 if elementary link (u, v) ∈ E q is in the k th chosen path connecting s and t.Conversely, Constraints (15) guarantee that, for every q = (s, t) ∈ Q and k = 1, 2, . . ., K, the elementary links (u, v) ∈ E q for which x q,k uv = 1 can be used to form exactly one path between s and t.These paths can be obtained by using Algorithm 1, which outputs the set P * that contains the extracted paths over all q ∈ Q and k = 1, 2, . . ., K. Thus, we can construct a solution to the path-based formulation from a solution to the link-based formulation by setting x p = 1 for all p ∈ P * .Furthermore, the repeater-placement variables y u are kept the same when translating between formulations.
By comparing the different constraints, it can be understood that if a solution to one formulation is feasible, the solution to the other formulation that can be obtained from it is also feasible.Constraints ( 6) and ( 16) both guarantee that elementary-link lengths do not exceed L max , while Constraints ( 7) and ( 17) both guarantee that each path includes N max quantum-repeater nodes at maximum.Constraints ( 8) and ( 15) make sure there are K paths between each pair of end nodes.These paths are guaranteed to be disjoint for the path-based formulation by Constraints (9) and for the link-based formulation by Constraints ( 18) and (19).Lastly, Constraints (10) and ( 20) couple the x variables to the y variables and make sure the quantum-repeater capacity is taken into account.
In step 7 of Box I, we manually set x q,k uv = 0 for all elementary links (u, v) ∈ E which are not in one of the paths p ∈ P * .We do this because, on some occasions, the variables x q,k uv are allowed to have value 1 in such a way that they form loops (which are disjoint from the path between s and t).For example, it could be the case that for some q ∈ Q and k = 1, 2, . . ., K, it holds that x q,k u1u2 = x q,k u2u1 = 1, which does not violate any of the constraints in Box III, and also does not influence the objective function (14).Since these loops do not connect end nodes, they do not contribute to realizing any of the network requirements.Therefore, any variable x q,k uv with value 1 such that it is part of a loop can safely be set to 0 without violating any constraint.This is shown rigorously in Appendix B. Only allowing for elementary links which are part of paths between end nodes realizes the removal of such loops.Since the method in Box I recommends the construction of elementary link (u, v) ∈ E if x q,k uv = 1, setting them to 0 whenever this is possible helps to prevent the construction of unnecessary elementary links.One way in which the appearance of loops in optimal solutions can be prevented in the first place by is to use the generalized link-based formulation in Box IV.In this formulation, the minimization of the total elementary-link length is used as secondary objective.

D. Generating Random Networks
Here, we describe how we generate random network graphs based on random geometric graphs.These networks are used to demonstrate our method and study the effect of different network-requirement parameters in Section III B.
while un = t do Find the unique node v ∈ R ∪ {t} for which x q,k unv = 1; n = n + 1; un = v; end p = (s, u1), (u1, u2), . . ., (un−1, t) ; The recipe for generating a random geometric graph on a two-dimensional Euclidean space with n nodes and radius d is as follows [24].First, n points are distributed uniformly at random on a unit square, by sampling both their horizontal and vertical coordinates uniformly at random.To every two points p 1 , p 2 we associate r(p 1 , p 2 ), which is the Euclidean distance between the two points.From this, an undirected weighted graph is constructed in which every node corresponds to one of the points, and edges between nodes corresponding to points p 1 , p 2 are added if r(p 1 , p 2 ) ≤ d.The weight that is given to the edge is r(p 1 , p 2 ).
To turn a random geometric graph into a suitable network graph, it must be decided which of the nodes are end nodes, and which are potential repeater locations.To this end, we determine the convex hull of the graph.We choose to use nodes corresponding to vertices of the convex hull of the graph as end nodes, i.e. they make up the set C. All other nodes are thus considered potential repeater locations, i.e. they make up the set R. This method is used because it is expected that potential repeater locations lying outside of the area spanned by the end nodes will only rarely be chosen as quantum-repeater nodes.When the end nodes form the convex hull, there are no such potential repeater locations, and the number of nodes that are not of relevance to the repeater-allocation problem is minimized.We generate the random geometric graphs using NetworkX [25] and determine the convex hull using an algorithm [26] which is included in SciPy [27].
The random network graph used in Figure 4 has been based on a random geometric graph with n = 10 and d = 0.6, but has been further edited to be made suitable for demonstration purposes.Some nodes were displaced manually.Additionally, end nodes have been added at the corners of the unit square and connected to the three closest potential repeater locations.

E. Scaling of the Formulations
The path-based formulation relies on the enumeration of all the paths between two end nodes.For every pair (s, t) ∈ Q we must consider all possible permutations of intermediate nodes in which r repeaters are placed on a path.For r = 0, we get a single path directly from s to t and for r = 1 we should consider all possible paths that utilize one repeater, which are |R| in total.Next, when r = 2 we must consider all paths that contain exactly two repeaters and additionally all permutations of the repeater placements in these paths, which gives |R|(|R| − 1) paths in total, et cetera.The number of y u variables is |R|, so that the number of variables n pbf var of the path-based formulation is given by If |R| > 1, this simplifies to [28] where e denotes Euler's number and [•] represents the rounding operator.We assume that the number of end nodes |C|, and therefore the number of end-node pairs |Q| = |C|(|C| − 1)/2, is constant so that this does not scale with the total number of nodes |N | in our graph.This implies that the number of possible repeater locations R = N \ C scales linearly with the number of nodes.The number of variables, as well as the number of constraints, is thus O (|N |!).
One important detail of our implementation of the path-based formulation is that we take Constraints ( 6) and ( 7) into account while enumerating all the paths.If we encounter a path which contains an elementary link with a length that exceeds L max or which uses more than N max repeaters, we simply exclude it from the set P. This can greatly reduce the total number of variables, although it will remain to scale exponentially with |N |.
In the link-based formulation, we need to enumerate all the elementary links in the network.To this end, we need to count every elementary link from s to every node v ∈ R ∪ {t}, and from u ∈ R to t which results in 2|R| + 1 elementary links.Next, we also need to consider the elementary link from every node u ∈ R to v ∈ R and back, in order to allow for directional paths from s to t, which are |R|(|R| − 1) in total.Additionally, since we use the index k for our x q,k uv variables in order to keep track of the redundant paths that are required for the given level of robustness, we need to make a copy of these variables for every value of k = 1, 2, . . ., K. When we combine this with the |R| y u variables, we get that the total number of variables of the link-based formulation is given by which is O |N | 2 , if we assume that K is a fixed constant.Note that the link-based formulation therefore also has O |N | 2 constraints.
To determine the rate, we now need to know how long every round takes.In the toy model, the only aspect of entanglement generation that takes any time is the photons traveling to the midpoints stations, and the messages heralding success or failure of the entanglement attempts traveling from the midpoint stations back to the repeaters.We assume both are light traveling through fiber.Thus, every round takes as long as it takes for light to travel the distance L through fiber.Denoting the speed of light in fiber c fiber , this gives a round time of L/c fiber , so that the repetition rate is c fiber /L.The end-to-end entanglement distribution rate is obtained by multiplying the repetition rate with the success probability, given by Appendix B: Proof of Equivalence In this appendix, we prove the equivalence between the link-based formulation and path-based formulation.In order to make this material self-contained, in Box V we reintroduce some of the notations.Next, in Appendix B 1, we briefly re-describe both of the formulations.After that, in Appendices B 2 and B 3, we show how to construct a feasible solution to the link-based formulation from the optimal solution to the path-based formulation and vice versa.By combining this result with the proof that the optimal objective values are equal, we conclude that the two formulations are equivalent.Here, we consider two ILP formulations to be equivalent if an optimal solution to one formulation can be used to obtain an optimal solution to the other and vice versa.

Q
Set of all ordered pairs (s, t) of end-nodes.

Pq
Set of all possible paths for a pair q ∈ Q. P Set of all possible paths between all of the pairs q ∈ Q.

Eq
Set of all elementary links that can be used by a pair q ∈ Q. R Set of potential repeater locations in the network.

Lmax
Maximum length of an elementary link.

Nmax
Maximum number of repeaters in a path.K The robustness parameter, which denotes the minimum number of quantum-repeater nodes or elementary links (it can be any combination) that need to break down before one of the other requirements can no longer be met.

K
Set of all integers from 1 to K (inclusive).

D
The capacity parameter, which denotes the number of quantum-communication sessions that one quantum repeater can facilitate simultaneously.
Box V: Overview of the sets and parameters that are relevant for the proof.

Formulations
Here we will restate both the path-based and link-based formulation for completeness.In the path-based formulation, we define the binary decision variables x p corresponding to a path p ∈ P = ∪ (s,t)∈Q P (s,t) , where P (s,t) is the set of all possible paths from end node s to end node t.A path itself is a sequence of elementary links reaching from s to t that does not contain any loops.They have value 1 when p is considered part of the set of chosen paths, and 0 otherwise.Furthermore, we use the binary decision variables y p u for all u ∈ R. Note that we introduce the superscript p here to more clearly distinguish between the two formulations, which differs from the main text.The variable y p u is 1 if a quantum repeater is placed at potential repeater location u, and 0 otherwise.The exact formulation is given in Box VI.
On the other hand, in the link-based formulation we define the binary decision variable x q,k uv for each pair of end nodes q = (s, t) ∈ Q, every elementary link (u, v) ∈ E q and k ∈ K = {1, 2, . . .K}.These variables can be interpreted as indicating whether an elementary link (u, v) is used in the k th path connecting the end nodes s and t.Furthermore, in the link-based formulation we use the variables y l u to indicate whether node u ∈ R is used as a quantum-repeater node.The exact formulation is given in Box VII.
where rup = 1 if path p uses u as a quantum-repeater node Box VI: Path-based formulation.
Box VII: Link-based formulation.
2. From the Path-Based Formulation to the Link-Based Formulation In this section we will construct a solution to the link-based formulation from the optimal solution to the path-based formulation.We then proceed by proving that this newly constructed solution is indeed a feasible solution to the link-based formulation, i.e. that it satisfies all constraints.
From the optimal solution to the path-based formulation we can use the values of the variables x p and y p u to assign values to our new binary decision variables xq,k uv and ỹl u , which presumably give a solution to the link-based formulation, using Algorithm 2.
Algorithm 2: Methodology for assigning the values of xq,k uv and ỹl u .For all q ∈ Q, k ∈ K and (u, v) ∈ E q , set xq,k uv = 0 and for all u ∈ R, set ỹl u = y p u ; for q ∈ Q do k = 1; for p ∈ P q do if x p = 1 then for (u, v) ∈ p do xq,k uv = 1; end k = k + 1; end end end From Algorithm 2, we can see that for each pair q ∈ Q and value of k ∈ K, we select a single, unique path p for which x p = 1 (because there are exactly K paths with x p = 1 in P q , due to Constraints (B4)) and use its elementary links to assign the corresponding xq,k uv variables to have value 1.Let us denote this path by p q,k for ease of notation in the remainder of this section.
Next, we will prove that the newly constructed solution is indeed feasible, by showing that all of the xq,k uv and ỹl u variables satisfy all constraints of the link-based formulation.
Proposition 1.The variables xq,k uv that we obtain with Algorithm 2 satisfy Constraints (B11) of the link-based formulation, i.e.
Proof.Consider the path p q,k for specific values of q = (s, t) ∈ Q and k ∈ K, for which x p q,k = 1..This path starts at s and ends at t by construction, so there is exactly one node v ∈ R ∪ {t} for which xq,k sv = 1 and hence If p q,k visits any other node u ∈ R, it holds that there is exactly one incoming edge and one outgoing edge from this node, since a path cannot start nor end here and neither can a path contain loops by definition.In other words, there must be exactly one node v ∈ R ∪ {s} for which xq,k vu = 1 and one node v ∈ R ∪ {t} (where v = v ) for which xq,k uv = 1.This results in Finally, if a node u ∈ R is not visited by p q,k , there are no incoming and no outgoing edges.Thus, xq,k vu = 0 for all v ∈ R ∪ {s}, and xq,k uv = 0 for all v ∈ R ∪ {t}.As a result, Equation (B22) is also satisfied in this case.The combination of (B20), (B21) and (B22) for all q ∈ Q and k ∈ K concludes the proof.
Proposition 2. The variables xq,k uv that we obtain with Algorithm 2 satisfy Constraints (B12) of the link-based formulation, i.e.
Proof.Consider the path p q,k for specific values of q = (s, t) ∈ Q and k ∈ K.Because x p q,k = 1 by definition, it follows from Constraints (B2) that any elementary link (u, v) ∈ p q,k has length L((u, v)) ≤ L max .Since xq,k uv = 1 only if (u, v) is in p q,k , it follows that every elementary link for which xq,k uv = 1 must have a length smaller than or equal to L max .Because this argument can be made for any q ∈ Q and any k ∈ K, Constraints (B12) are satisfied whenever xq,k uv = 1.Furthermore, they are trivially satisfied when xq,k uv = 0. Proof.Consider the path p q,k for specific values of q = (s, t) ∈ Q and k ∈ K, for which x p q,k = 1.According to Algorithm 2, xq,k uv = 1 only if (u, v) ∈ p q,k .Hence, the number of (u, v) ∈ E q for which xq,k uv = 1 is the same as the number of elementary links in p q,k , which is |p q,k |.Thus, where the first equality holds because x p q,k = 1 by definition of p q,k .According to Constraints (B3), which implies |p q,k |x p q,k ≤ N max + 1 ∀q ∈ Q, k ∈ K. (B27) If we substitute (B25) into (B27) we directly get that Proof.Consider the path p q,k for specific values of q = (s, t) ∈ Q and k ∈ K, for which x p q,k = 1.According to Equation (B9), the parameter r up q,k = 1 if the potential repeater location u ∈ R is in p q,k .If this is the case, the path p q,k contains exactly one outgoing elementary link at u, and thus v:(u,v)∈Eq xq,k uv = 1.Otherwise, there are no outgoing elementary links, and v:(u,v)∈Eq xq,k uv = 0. Therefore, Since the variables x q,k uv are binary, this implies that there is exactly one v such that x qk sv = 1.Now, we assume that u = u i such that u i = s and u i = t and show there is a unique v such that x q,k uiv = 1.First, we combine Constraints (B14) with the fact that v (ui,v)∈Eq x q,k uiv ≤ v (ui,v)∈Eq k∈K x q,k uiv , (B44) to find that v (ui,v)∈Eq x q,k uiv ≤ 1. (B45) From Constraints (B11) with u i ∈ R we find that v (ui,v)∈Eq x q,k uiv = v (v,ui)∈Eq We know that the left-hand side of this equation is upper bounded by 1 because of Equation (B45).Furthermore, because node u i was selected by Algorithm 3 (when entering the while loop for u = u i−1 ), we know that x q,k ui−1ui = 1.This implies that the right-hand side is at least one.Therefore, both sides must be equal to one.Because the variables are binary, the equality of the right-hand side to 1 implies there is exactly one v such that x q,k uiv = 1.
This procedure only concludes if there is an n such that u n = t.This must be the case, as there is only a finite number of nodes in N , and two nodes u k , u l cannot be the same unless k = l.To see that this last property holds, assume for the moment that there are a k and l > k such that u k = u l .In that case, by virtue of how Algorithm 3 works, it must be the case that x q,k u k−1 u k = x q,k u l−1 u k = 1.Since we concluded earlier that there can only be one v such that x q,k vu = 1, this implies that u l−1 = u k−1 .Then, the above argument can be repeated to find u l−2 = u k−2 .This can be continued until we find that u l−k = u k−k = u 0 = s.Because l − k > 0, u l−k can only be in pq,k if x q,k u l−k−1 u l−k = x q,k u l−k−1 s = 1.However, this variable is not defined, because there is no elementary link (v, s) ∈ E q for any v ∈ N .We have thus reached a contradiction, and we can conclude that u k = u l as long as k = l and thus Algorithm 3 must eventually terminate.
At this point we can conclude that Algorithm 3 creates the sequence pq,k = (u 0 , u 1 ), (u 1 , u 2 ), (u 2 , u 3 ), . . ., (u n−1 , u n ) (B47) for some integer n, where u 0 = s and u n = t.Clearly, this is a sequence of adjacent elementary links which connect the end node s to the end node t.Furthermore, since we concluded that u k = u l for k = l, there are no loops, and thus pq,k is in fact a path pq,k = p q,k ∈ P. Since p q,k ∈ P, the variable xp q,k is well-defined and can be set to 1.
Next, we address the fact that optimal solutions to the link-based formulation can contain chosen elementary links that form loops, which do not contribute to satisfying constraints, but also do not violate them.To avoid the construction of ineffective elementary links, we define the variables xq,k uv for all q ∈ Q, k ∈ K and (u, v) ∈ E q .We set xq,k uv = 1 if (u, v) ∈ p for some p ∈ P * and xq,k uv = 0 otherwise for all q ∈ Q and k ∈ K, where P * is the output of Algorithm 1 when applied to the variables x q,k uv (which are part of an optimal solution to the link-based formulation).In other words, xq,k uv represent a choice of elementary links that corresponds to the optimal solution, but with all links that are not in any of the paths p ∈ P * removed.

Proposition 7. The variables xq,k
uv and y l u form an optimal solution to the the link-based formulation.Proof.If the variables form a feasible solution, they also form an optimal solution, since the variables y l u are defined to be part of an optimal solution and the objective function is independent of the values of xq,k uv .
The variables form a feasible solution if they satisfy all constraints in Box VII (but with x q,k uv substituted by xq,k uv everywhere).It is easily verified that Constraints (B12 -B16) are satisfied.Each of these set an upper bound on sums over (linear functions of) xq,k uv variables.Since xq,k uv is either equal to x q,k uv or set to 0, it always holds that xq,k uv ≤ x q,k uv .

Figure 2 :
Figure 2: Graph representation of SURFnet core network.Node locations roughly correspond to geographical locations but have been adjusted for readability.Lengths of fibers connecting nodes are not shown.Nodes that are used as end nodes are shown as orange squares.Potential repeater locations are shown as white circles.A'dam and R'dam are used as abbreviations for Amsterdam and Rotterdam respectively.

Figure 3 :
Figure 3: Solution to the repeater-allocation problem for R min = 1 Hz, F min = 0.93, K = 2 and D = 4.The network graph used as input corresponds to the SURFnet network, depicted in Figure 2. End nodes are shown as orange squares, quantum-repeater nodes are shown as blue hexagons and the fibers that are used in the elementary links are highlighted with thick lines.

Figure 6 :
Figure 6: Computation time in seconds for 100 random geometric graphs with L max = 1, N max = 6, K = 2 and D = 8 for varying number of nodes n.The error bars represent one standard deviation of the mean.For the fit we have used an exponential function of the form a(e bn 3 − 1), where a and b are free parameters.