31

Click here to load reader

Approximation algorithms for solving the constrained arc routing problem in mixed graphs

  • Upload
    ko-wei

  • View
    214

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Accepted Manuscript

Approximation Algorithms for Solving the Constrained Arc Routing Problem

in Mixed Graphs

Honglin Ding, Jianping Li, Ko-Wei Lih

PII: S0377-2217(14)00381-6

DOI: http://dx.doi.org/10.1016/j.ejor.2014.04.039

Reference: EOR 12290

To appear in: European Journal of Operational Research

Received Date: 22 May 2013

Accepted Date: 26 April 2014

Please cite this article as: Ding, H., Li, J., Lih, K-W., Approximation Algorithms for Solving the Constrained Arc

Routing Problem in Mixed Graphs, European Journal of Operational Research (2014), doi: http://dx.doi.org/

10.1016/j.ejor.2014.04.039

This is a PDF file of an unedited manuscript that has been accepted for publication. As a service to our customers

we are providing this early version of the manuscript. The manuscript will undergo copyediting, typesetting, and

review of the resulting proof before it is published in its final form. Please note that during the production process

errors may be discovered which could affect the content, and all legal disclaimers that apply to the journal pertain.

Page 2: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Approximation Algorithms for Solving the

Constrained Arc Routing Problem

in Mixed Graphs

Honglin Ding

Department of Mathematics

Yunnan University

Kunming 650091, P.R. China

Email:[email protected]

Jianping Li∗

Department of Mathematics

Yunnan University

Kunming 650091, P.R. China

Email:[email protected]

Ko-Wei Lih

Institute of Mathematics

Academia Sinica

Taipei 10617, Taiwan

Email:[email protected]

May 1, 2014

Abstract

Given a mixed graph G with vertex set V , let E and A denote the sets of edges

and arcs, respectively. We use Q+ and Z+ to denote the sets of positive rational

numbers and positive integers, respectively. For any connected mixed graph G =

(V,E ∪A; w; l, u) with a length function w : E ∪A → Q+ and two integer functions

∗Corresponding author, Tel: (0086-871) 65033701, Fax: (0086-871) 65033700

1

Page 3: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

l, u : E ∪ A → Z+ satisfying l(e) ≤ u(e) for each e ∈ E ∪ A, we are asked to

determine a minimum length tour T traversing each e ∈ E ∪ A at least l(e) and at

most u(e) times. This new constrained arc routing problem generalizes the mixed

Chinese postman problem. Let n = |V | and m = |E ∪ A| denote the number of

vertices and edges (including arcs), respectively. Using network flow techniques,

we design a (1 + 1/l0)-approximation algorithm in time O(n2m3 log n) to solve this

constrained arc routing problem such that l(e) < u(e) holds for each edge e ∈ E,

l(e) ≤ u(e) holds for each arc e ∈ A and l0 = min{l(e) | e ∈ E}. In addition, we

present two optimal combinatorial algorithms in times O(n3) and O(nm2 log n) to

solve this problem for the cases A = ∅ and E = ∅, respectively.

Keywords: Combinatorial optimization; arc routing; lower/upper demand bound;

approximation algorithm; combinatorial algorithm.

1 Introduction

In most arc routing problems, the objective is to determine a least-cost traversal of a

set of specified edges or arcs of a mixed graph. Such problems occur in a variety of

practical contexts and have attracted attention from both mathematicians and operations

researchers. The earliest arc routing problem was the Konigsberg seven bridges problem,

which is to determine whether there exists a closed tour traversing exactly once each

of the seven bridges on the Pregel river through Konigsberg. After Euler solved the

Konigsberg seven bridges problem in the negative, he was concerned almost exclusively

with the existence of a tour. The question of determining such a tour was addressed and

solved by Hierholzer and Wiener [22]. The reader is referred to Fleischner [10] for an

interesting account of this problem.

Another closely related well-known problem is the so-called Chinese postman problem

(CPP) posed by Guan [21]. In contrast to the Konigsberg seven bridges problem, Guan

addressed a natural question that is to determine a minimum length tour traversing

each edge of a weighted graph at least once. The CPP is a version of the arc routing

problem specialized to graphs. Using Edmonds’ combinatorial algorithm for solving the

maximum weighted matching problem [6], Edmonds and Johnson [7] designed an optimal

2

Page 4: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

combinatorial algorithm to solve the CPP.

Closely related to the CPP is the directed Chinese postman problem (DCPP), which

is a version of the arc routing problem specialized to directed graphs, or simply digraphs.

Using a combinatorial algorithm in [12] for solving the transportation problem, Edmonds

and Johnson [7] also designed another optimal combinatorial algorithm to solve the DCPP.

The mixed Chinese postman problem (MCPP), listed in Garey and Johnson [14] as

the problem ND25, is a common generalization of the CPP and the DCPP. In the MCPP,

an input graph may contain both undirected and directed edges. A directed edge is also

referred to as an arc. The objective is to determine a tour that traverses at least once

every edge in either direction and every arc in the direction of that arc. Even though

the CPP and the DCPP are both polynomially solvable [7], Papadimitriou [29] showed

that the MCPP becomes NP-complete. Because a number of practical applications, such

as mail delivery, snow removal, and trash pick-up, can be modeled as instances of the

MCPP, it is important to design good approximation algorithms for this problem.

Quite a few papers about the MCPP have appeared in the literature over the past

four decades. Edmonds and Johnson [7] presented the first approximation algorithm for

the MCPP. Christofides et al. [3] designed an exact algorithm for the MCPP based on

a branch-and-bound algorithm using Lagrangian bounds. Afterwards, Frederickson [13]

showed that the approximation algorithm due to Edmonds and Johnson [7] is indeed a

2-approximation algorithm to solve the MCPP. Frederickson provided a mixed strategy

algorithm for the MCPP that is a 5/3-approximation algorithm. As far as we know,

the best approximation algorithm to solve the MCPP is a 3/2-approximation algorithm

due to Raghavachari and Veerasamy [31]. Comprehensive surveys, latest advances and

new challenges on the MCPP are available in [5, 19, 34]. Integer and linear programming

formulations of the postman problems have generated great interest in recent years [26, 32].

Ralphs [32] showed that a linear relaxation of the MCPP has optimal solutions that are

half-integral. One can use this fact to derive a 2-approximation algorithm for the MCPP.

It is interesting to note that the implementation of Nobert and Picard [26] has been

used for scheduling snow removal in Montreal. Corberan et al. [4] presented a heuristic

algorithm for the MCPP, using greedy randomized adaptive search procedure techniques.

Goel and Gruhn [16] recently considered a general vehicle routing problem (GVRP) that

3

Page 5: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

generalizes the MCPP, where the GVRP is a rich vehicle routing problem incorporating

various complexities found in real-life applications. Other interesting materials related to

the GVRP are referred to [15, 23].

In the literature, one may either traverse some required edges or arcs exactly once in a

minimum length feasible tour of a mixed graph or show the non-existence of such a tour.

This becomes a variant of the MCPP. In order to widen the scope of possible applications

for arc routing models, the times that an edge or arc is traversed should be given a

reasonable range rather limited to at least once. We should consider a generalization of

the MCPP for which some required edges or arcs would be traversed at least t1 and at

most t2 times (1 ≤ t1 ≤ t2) in a tour. This new model generalizes the above-mentioned

variant of the MCPP. In this paper, we consider the constrained arc routing problem in

connected mixed graphs (CARM) defined as follows. Let G = (V, E ∪ A; w; l, u) be a

connected mixed graph defined on vertex set V such that E is the set of all edges and A is

the set of all arcs. Let n = |V | and m = |E ∪A| denote the number of vertices and edges

(including arcs), respectively. Let Q+ and Z+ denote the set of positive rational numbers

and the set of positive integers, respectively. For a length function w : E ∪ A → Q+ and

two integer functions l, u : E ∪ A → Z+ satisfying l(e) ≤ u(e) for each e ∈ E ∪ A, we

are asked to determine a tour T traversing each e ∈ E ∪ A at least l(e) and at most u(e)

times such that the objective is to minimize the total length w(T ) =∑

e∈E∪A t(e)w(e),

where t(e) denotes the number of times that the edge or arc e is traversed by T .

There are two special cases to note. (1) If l(e) = u(e) = 1 for each edge e of the

required subset of E ∪ A, then the CARM problem for this version becomes the above-

mentioned variant; (2) If l(e) = 1 and u(e) = +∞ for each edge e ∈ E∪A, then the CARM

problem for this version specializes to the MCPP. It follows that the CARM problem is

also NP-complete.

A capacitated Chinese postman problem (CCPP) was posed by Golden and Wong [20]

as follows. Consider a mixed graph G = (V, E ∪ A; q; c). Vertex v1 represents a depot

where identical vehicles of capacity L are based. Each e ∈ E ∪ A has a positive demand

q(e) and a cost c(e) and can be traversed any number of times by any number of vehicles.

A vehicle route is said to be feasible if it starts and ends at the depot v1 and the total

demand of the edges and arcs traversed by the vehicle does not exceed L. The CCPP looks

4

Page 6: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

for a set of feasible vehicle routes of least total cost such that each edge or arc appears in

at least one route and is traversed by exactly one vehicle. Many authors [2, 19, 25, 35]

studied the capacitated arc routing problem (CARP) that is an extension of the CCPP.

Recently, Lysgaard and Wohlk [24] also considered a variation of the CARP where the

objective is to minimize the sum of arrival times at the customers, for a fixed starting

time of each route.

It is easy to see that the CCPP restricted to the case of one vehicle of capacity

L ≥ ∑e∈E∪A q(e) becomes the MCPP. Christofides et al. [3] proposed a heuristic procedure

for obtaining a reasonable solution to the CCPP. Golden and Wong [20] showed that even

finding a 3/2-approximation algorithm to solve the CCPP remains NP-complete.

We know that the CARM problem and the CCPP generalize the MCPP, but each of

them does not follow from the other. Since the CCPP can be formulated as a set covering

problem [18], Theorem 4.4 in Feige [9] implies that the CCPP would not be approximated

within (1 − ε) log n unless NP ⊆ TIME(nO(log log n)), where ε ∈ (0, 1). However, the

CARM problem can be approximated within a constant performance ratio as shown in

the following text. We will show that two special versions of the CARM problem can be

optimally solved in polynomial times.

The remainder of this paper is organized as follows. In Section 2, we present ter-

minology for the description of our algorithms, and then establish some key lemmas to

ensure the correctness of our algorithms. In Section 3, we study the CARM problem

that can be approximated within performance ratio 1 + 1/l0 and in time O(n2m3 log n),

where l(e) < u(e) holds for each edge e ∈ E, l(e) ≤ u(e) holds for each arc e ∈ A

and l0 = min{l(e) | e ∈ E}. In Section 4, we study the CARM problem for the case

A = ∅ that can be solved optimally by our combinatorial algorithm in time O(n3). In

Section 5, we study the CARM problem for the case E = ∅ that can be solved optimally

by our combinatorial algorithm in time O(nm2 log n). In Section 6, we summarize our

conclusions.

5

Page 7: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

2 Terminology and Key Lemmas

A mixed graph G = (V, E ∪A) contains both edges (unordered pairs of vertices in E) and

arcs (ordered pairs of vertices in A). A mixed graph G is called a multigraph if G contains

parallel edges or arcs, but no self-loops. Parallel edges (or arcs) are called multi-edges (or

multi-arcs). In this case, the set E (or A) is a multiset of edges (or arcs). A mixed graph

G is called a simple mixed graph if G contains neither self-loops nor parallel edges or arcs,

but G may have an edge and an arc with the same end-vertices. The term “edge” is also

used to refer both edge and arc of a mixed graph. Thus, an arc is regarded as a directed

edge. A mixed graph G = (V,E ∪ A) is said to be an undirected graph (or simply, graph)

if A = ∅ and a directed graph (or simply, digraph) if E = ∅, respectively.

In the sequel, G always denotes a mixed graph. A walk in G is an alternating sequence

W = x1e1x2e2x3 · · ·xk−1ek−1xk of vertices xi and edges or arcs ej from G such that either

the two end-vertices of the edge ei are xi and xi+1 or the tail of the arc ei is xi and the

head of the arc ei is xi+1 for every 1 ≤ i ≤ k − 1. This means that this walk W traverses

every edge ei in either direction and every arc ei in the direction of that arc. We say that

W is a walk from x1 to xk or an (x1, xk)-walk. A walk W is closed if x1 = xk, and we

always refer such a closed walk as a tour or circuit.

If the vertices of a walk W are distinct, then W is called as a path. If the vertices

x1, x2, . . . , xk−1 are distinct and x1 = xk, where k ≥ 3, W is called as a cycle. Two paths

P1 and P2 are said to be vertex-disjoint (or edge-disjoint) if their vertex sets (or edge sets)

are disjoint, respectively. Similarly, we can define two directed paths being arc-disjoint.

A mixed graph G = (V, E ∪A) is connected if, for any two vertices x and y in G, there

exists a path Px,y from x to y, where each edge e = uv on Px,y may be traversed in either

direction of this edge, but each arc e = (u, v) on Px,y may only be traversed from u to v.

In addition, when G is a (mixed) weighted graph and Px,y is a path from x to y in G, we

denote w(Px,y) to be the sum of weights of all edges and arcs in the path Px,y, and we

refer dG(x, y) as the weight of a shortest path from x to y, i.e., dG(x, y) = min{w(Px,y)

| Px,y is a path from x to y in G}. On the other hand, a digraph D = (V, A) is strongly

connected if, for any two vertices x and y in D, there exists a directed path Px,y from x

to y and at the same time a directed path P ′y,x from y to x.

6

Page 8: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

For any vertex v in a mixed graph G = (V, E ∪A), the degree of the vertex v, denoted

by dG(v) or d(v), is the number of edges and arcs that are incident to v. For any vertex

v in a mixed graph G = (V,E ∪ A), the vertex v is even if its degree dG(v) is even,

otherwise the vertex v is odd. For any vertex v in a digraph D = (V,A), denote δ+D(v)

the set of arcs leaving v and δ−D(v) the set of arcs entering v, respectively. The out-degree

of a vertex v, denoted by d+D(v), is the number of arcs that have v as their common tail,

and the in-degree of a vertex v, denoted by d−D(v), is the number of arcs that have v as

their common head. Equivalently, d+D(v) = |δ+

D(v)| and d−D(v) = |δ−D(v)|, then the number

d+D(v) + d−

D(v) is the degree of a vertex v.

In a mixed graph G = (V,E∪A), an Eulerian tour is a closed walk that starts at some

vertex v0, traverses each edge or arc exactly once, and returns to the same vertex v0. A

mixed graph is Eulerian if it contains such an Eulerian tour. In addition, if a digraph

D = (V, A) contains a directed Eulerian tour, then this digraph D = (V, A) is called a

directed Eulerian graph, or simply an Eulerian digraph.

A matching in a graph G = (V, E) is a set M of pairwise disjoint edges (i.e., the

end-vertices of edges are all distinct), and each edge in M is called a matching edge. In

addition, M is called a perfect matching if all vertices in V are covered by M , i.e., the

matching M satisfies |M | = |V |/2. Moreover, for a weighted graph G = (V, E; w), M is

called a maximum matching in G if the weight w(M) =∑

e∈M w(e) is maximized among

all matchings in G. Similarly, for a weighted graph G = (V,E; w) and a matching M of

G, M is called a minimum cost perfect matching if M is a perfect matching such that the

weight w(M) =∑

e∈M w(e) is minimized among all perfect matchings in G.

For any network, a synonym of digraph, N = (V, A; u; c; s, t) with a capacity function

u : A → R+, a cost function c : A → R+, a source s and a sink t, a flow from s to t

(briefly, an (s, t)-flow) is a function f from A to the set R+0 of non-negative real numbers,

i.e., f : A → R+0 , satisfying the following conditions

(1) (the capacity constraint) 0 ≤ f(e) ≤ u(e) for each arc e ∈ A;

(2) (the flow conservation)∑

e∈δ+D(v) f(e) =

∑e∈δ−D(v) f(e) for each vertex v ∈ V −{s, t};

(3) v(f) =∑

e∈δ+D(s) f(e) − ∑

e∈δ−D(s) f(e) ≥ 0 for the source s.

7

Page 9: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

We call v(f) the value of an (s, t)-flow f , and we define its cost c(f) =∑

e∈A c(e)f(e).

In addition, if the value f(e) is integral for each arc e ∈ A, we call an (s, t)-flow f as an

integral (s, t)-flow.

For a network N = (V,A; l, u; s, t) with a demand function l : A → R+0 and a capacity

function u : A → R+, a function f : A → R+0 is called a circulation in N if the function f

satisfies l(e) ≤ f(e) ≤ u(e) for each arc e ∈ A and the flow conservation rule (2) holds at

every vertex v in N . When f is a circulation in N , the cost of f is defined to be the value

c(f) =∑

e∈A c(e)f(e). Similarly, we call a circulation f to be integral if f(e) is integral

for each arc e ∈ A.

For any real number r, let �r� (or r�) denote the greatest (or smallest) integer less

(or greater) than or equal to r.

The following key lemmas are needed to design our algorithms later on.

Lemma 1 [22] Suppose that G = (V,E) is a connected graph. Then G is an Eulerian

graph if and only if every vertex v of G has even degree.

If a graph G = (V, E) is Eulerian, we use an algorithm due to Edmonds and John-

son [7] in time O(m) to determine an Eulerian tour on G. We call such an algorithm the

Eulerian-Cycle algorithm.

Lemma 2 [10] Suppose that D = (V, A) is a strongly connected digraph. Then D is an

Eulerian digraph if and only if every vertex v of D has equal in- and out-degrees.

If a digraph D = (V, A) is Eulerian, we use another algorithm due to Edmonds and

Johnson [7] in time O(nm) to determine a directed Eulerian circuit on D. We call such

an algorithm the Eulerian-Circuit algorithm.

Lemma 3 (Goldberg and Tarjan [17]) Let N = (V,A; l, u; c) be a network with a demand

function l : A → R+0 , a capacity function u : A → R+ and a cost function c : A → R+. A

minimum cost circulation f in N can be determined in time O(n2m3 log n). In addition, if

the demand function l(·) and the capacity function u(·) are both integral, then a minimum

cost circulation f in N is integral, and it can be determined with the same running time.

We refer a combinatorial algorithm due to Goldberg and Tarjan [17] to solve the

minimum cost circulation problem as the Cycle-Canceling algorithm.

Lemma 4 (Ford and Fulkerson [12]) Suppose that N = (V, A; u, c; s, t) is an instance of

8

Page 10: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

the minimum cost flow problem. Let f1 be a minimum cost (s, t)-flow of value k0 in N

and f2 an (s, t)-flow of value 1 along an augmentation (s, t)-path P in N ′(f1) of least cost,

where N ′(f1) is the incremental weighted flow network of the flow f1. Then f1 + f2 is a

minimum cost (s, t)-flow of value k0 + 1 in N . In addition, if the capacity function u(·)is integral and f1 is a minimum cost integral (s, t)-flow of value k0 in N , then f1 + f2 is a

minimum cost integral (s, t)-flow of value k0 + 1 in N .

By Lemma 4 and the Belleman-Ford algorithm [1] in time O(nm) to determine an

augmentation (s, t)-path P in N ′(f1) of least cost, we can design an algorithm in time

O(nmk1) to determine a minimum cost (s, t)-flow of integral value k1 in N . We call such

an algorithm the Successive-Shortest-Path algorithm.

The Successive-Shortest-Path algorithm is not a polynomial-time algorithm to

solve the minimum cost flow problem. The capacity scaling algorithm in [27] is a variant

of the Successive-Shortest-Path algorithm, and it solves the minimum cost flow

problem in time O(nm2 log k1). In this paper, we need a more efficient algorithm in [28] to

solve the integral minimum cost (s, t)-flow problem, that is a variant of the capacity scaling

algorithm. We call such an algorithm the Enhanced-Capacity-Scaling algorithm.

Lemma 5 [28] The Enhanced-Capacity-Scaling algorithm solves the capacitated

minimum cost flow problem in time O(m log nS(n,m)), where S(n,m) is the time required

to solve a shortest path problem with n vertices and m arcs. In addition, if the capacity

function u(·) is integral, then a minimum cost integral (s, t)-flow can be determined with

the same running time.

3 The Constrained Arc Routing Problem in Mixed

Graphs

The constrained arc routing problem in mixed graphs (CARM) was defined in the intro-

duction section. We first give an integer programming formulation of the CARM problem

as follows. Each mixed graph G = (V,A∪E) is associated with a digraph←→G = (V,A∪B)

such that B = E+∪E− and each edge e ∈ E is replaced by two arcs e+ ∈ E+ and e− ∈ E−

of opposite direction with the same weight w(e+) = w(e−) = w(e). Since G is a connected

9

Page 11: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

mixed graph, we can obtain a necessary and sufficient condition for any instance of the

CARM problem as follows. A nonnegative integral circulation x in←→G corresponds to an

arc routing of G (i.e., a feasible solution to the instance G of the CARM problem) if and

only if (1) l(e) ≤ x(e) ≤ u(e) for each arc e ∈ A, and (2) l(e) ≤ x(e+) + x(e−) ≤ u(e) for

each edge e ∈ E, where x(e) is the number of times that the arc e ∈ A is traversed in the

arc routing of G and x(e+) + x(e−) is the number of times that edge e ∈ E is traversed

in the arc routing of G for the CARM problem, respectively.

Thus, we can establish an integer program, denoted by CARM(G), which is equivalent

to the CARM problem for the instance G = (V,A ∪ E; w; l, u).

CARM(G) min∑

e∈A∪B w(e)x(e)

subject to∑

e∈δ−←→G

(v) x(e) − ∑e∈δ+←→

G(v) x(e) = 0 for each v ∈ V (1)

l(e) ≤ x(e) ≤ u(e) for each e ∈ A (2)

l(e) ≤ x(e+) + x(e−) ≤ u(e) for each e ∈ E (3)

x(e) ≥ 0 for each e ∈ A ∪ B (4)

x(e) integer for each e ∈ A ∪ B (5)

Now, we construct a new weighted digraph G = (V , A) from the mixed graph G =

(V, E ∪ A; w; l, u) as follows. At the beginning, let V := V and A := A. We replace each

edge e = ab ∈ E, by a directed subgraph De consisting of four vertices a, b, ye, ze and five

arcs (a, ye), (b, ye), (ye, ze), (ze, a), (ze, b) (see Fig.1), where we add the two new vertices

ye and ze into V and the five new arcs into A, and we define lower and upper bounds

and length weights on these five arcs as follows: l(a, ye) = l(b, ye) = l(ze, a) = l(ze, b) = 0,

l(ye, ze) = l(e), u(a, ye) = u(b, ye) = u(ye, ze) = u(ze, a) = u(ze, b) = u(e), and w(a, ye) =

w(b, ye) = w(ze, a) = w(ze, b) = 0, w(ye, ze) = w(e). Thus, each arc in A of the new

weighted digraph G belongs to A or to a directed subgraph De for some e ∈ E, but not

both.

� � ����

�����������

���������

����������

���������

a b a b

ye

zeFig.1 The construction of De

10

Page 12: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

For each new arc e ∈ A of the network G = (V , A; w; l, u), the values l(e), u(e) and

w(e) may be regarded as demand, capacity and unit cost of e, respectively.

Lemma 6. Let G = (V, E ∪ A; w; l, u) be an instance of the CARM problem such that

l(e) < u(e) holds for each edge e ∈ E and l(e) ≤ u(e) holds for each arc e ∈ A. There

exists a feasible tour T in G if and only if there exists an integral circulation f in the

network G = (V , A; w; l, u).

Proof. A feasible tour T to the instance G of the CARM problem can be transformed into

a feasible solution x of the corresponding integer program CARM(G), and vice versa. We

only need to prove that there exists a feasible solution x of the integer program CARM(G)

if and only if there exists an integral circulation f in the network G = (V , A; w; l, u).

Necessity. Suppose that x is a feasible solution of the integer program CARM(G).

We construct an integral circulation f in the network G = (V , A; w; l, u) as follows. For

each arc e ∈ A, let f(e) = x(e). And for each edge e = ab ∈ E, without loss of

generality, we may assume e+ = (a, b) and e− = (b, a), then let f(a, ye) = f(ze, b) = x(e+),

f(b, ye) = f(ze, a) = x(e−) and f(ye, ze) = x(e+) + x(e−). It is easy to verify that f is an

integral circulation in G.

Sufficiency. Suppose that f is an integral circulation in G = (V , A; w; l, u). First, we

may construct a new integral circulation f from f in G that satisfies further properties.

For each arc e ∈ A, let f(e) = f(e). For each edge e = ab ∈ E, we examine either the

pair f(a, ye) and f(ze, b) or the pair f(b, ye) and f(ze, a). If f(a, ye) = f(ze, b) (implying

f(b, ye) = f(ze, a)), let f(e′) = f(e′) for each arc e′ ∈ {(a, ye), (ze, b), (b, ye), (ze, a), (ye, ze)}.If f(a, ye) �= f(ze, b), we may assume f(a, ye) > f(ze, b), then we denote θ1 =

⌊f(a,ye)−f(ze,b)2

and θ2 =⌈f(a,ye)−f(ze,b)

2

⌉. We consider two possibilities.

(1) If f(ye, ze) = l(e), let f(a, ye) = f(a, ye) − θ1, f(ze, b) = f(ze, b) + θ2, f(b, ye) =

f(b, ye) + θ2, f(ze, a) = f(ze, a) − θ1 and f(ye, ze) = f(ye, ze) − θ1 + θ2. It follows that

l(e) = f(ye, ze) ≤ f(ye, ze) ≤ f(ye, ze) + 1 = l(e) + 1 ≤ u(e)

(2) If f(ye, ze) > l(e), let f(a, ye) = f(a, ye) − θ2, f(ze, b) = f(ze, b) + θ1, f(b, ye) =

f(b, ye) + θ1, f(ze, a) = f(ze, a) − θ2 and f(ye, ze) = f(ye, ze) − θ2 + θ1. It follows that

l(e) ≤ f(ye, ze) − 1 ≤ f(ye, ze) ≤ f(ye, ze) ≤ u(e)

11

Page 13: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

It is easy to verify that f is also an integral circulation in G and f(a, ye) = f(ze, b) for

each edge e = ab ∈ E.

Now, we can construct a feasible solution x to the integer program CARM(G) as

follows. For each arc e ∈ A, let x(e) = f(e). For each edge e = ab ∈ E, without loss

of generality, we may assume e+ = (a, b) and e− = (b, a), then we let x(e+) = f(a, ye)

and x(e−) = f(b, ye). Since f is an integral circulation in G, it is easy to see that the

constraint condition (1) in the integer program CARM(G) holds. The constraint condition

(2) holds obviously. For each edge e ∈ E, the constraint condition (3) also holds since

l(e) ≤ x(e+) + x(e−) = f(ye, ze) ≤ u(e). The constraint conditions (4) and (5) clearly

hold. Thus, x is a feasible solution of the integer program CARM(G).

Edmonds and Karp [8] designed an algorithm to solve the minimum cost circulation

problem, but their algorithm is based on a capacity scaling method and it can be imple-

mented to run in time O(m(m+n log n) log U), where U = max{u(e) | e ∈ A}. Tardos [33]

was the first to design a strongly polynomial-time algorithm to solve the minimum cost

circulation problem. In this paper, we invoke a simpler and more efficient combinatorial

algorithm due to Goldberg and Tarjan [17] to solve the minimum cost circulation problem.

It is stated in Lemma 3 and referred to as the Cycle-Canceling algorithm.

Using Lemmas 3 and 6, we can design an approximation algorithm to solve the CARM

problem as follows.

Algorithm 1. CARM

Input: A connected mixed graph G = (V,E ∪ A; w; l, u) with a length function w :

E ∪ A → Q+ and two integer functions l, u : E ∪ A → Z+ satisfying l(e) ≤ u(e) for

each e ∈ E ∪ A.

Output: A constrained arc routing T and its total length.

Begin

Step 1 Construct a new weighted digraph G = (V , A) from the mixed graph G =

(V,E ∪ A; w; l, u) as above.

12

Page 14: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Step 2 Using the Cycle-Cancelling algorithm in [17], determine a minimum cost

integral circulation f in G. If no such circulation exists, then output “no feasible

solution to this instance of the CARM problem”, and stop.

Step 3 Construct a new integral circulation f in G associated with the integral circulation

f as follows

(1) For each arc e ∈ A, let f(e) = f(e).

(2) For each edge e = ab ∈ E, let f(ye, ze) = f(ye, ze) − θ1 + θ2, where θ1 =⌊ |f(a,ye)−f(ye,b)|

2

⌋and θ2 =

⌈ |f(a,ye)−f(ye,b)|2

⌉; and

if (f(a, ye) > f(ye, b)) then

denote f(a, ye) = f(a, ye)−θ1, f(ze, b) = f(ze, b)+θ2, f(b, ye) = f(b, ye)+θ2

and f(ze, a) = f(ze, a) − θ1.

else

denote f(a, ye) = f(a, ye)+θ2, f(ze, b) = f(ze, b)−θ1, f(b, ye) = f(b, ye)−θ1

and f(ze, a) = f(ze, a) + θ2.

Step 4 Construct a feasible solution x to the integer program CARM(G) as follows

(1) For each arc e ∈ A, let x(e) = f(e).

(2) For each edge e = ab ∈ E, do

if (e+ = (a, b) and e− = (b, a)) then

denote x(e+) = f(a, ye) and x(e−) = f(b, ye).

else

denote x(e−) = f(a, ye) and x(e+) = f(b, ye).

Step 5 Construct a digraph GD = (V, A) so that there are x(e) multi-arcs from the vertex

a to the vertex b in GD for each arc e = (a, b) in←→G .

Step 6 Using the Eulerian-Circuit algorithm in [7], find a directed Eulerian tour TD

on GD.

Step 7 For each arc e in TD, remove its direction only if e /∈ A, and then construct a

(mixed) tour T in G.

13

Page 15: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Step 8 Output the tour T and the value w(T ) =∑

e∈A∪B w(e)x(e).

End

For an instance G = (V, E ∪ A; w; l, u) of the CARM problem, let OPT denote the

optimal value and OUT the output value of the algorithm CARM, respectively.

Theorem 1 For any instance G = (V,E∪A; w; l, u) of the CARM problem, if l(e) < u(e)

holds for each edge e ∈ E and l(e) ≤ u(e) holds for each arc e ∈ A, then the algorithm

CARM can produce a feasible arc routing to satisfy OUT ≤ (1 + 1/l0) · OPT , where

l0 = min{l(e) | e ∈ E}, and the running time of the algorithm CARM is O(n2m3 log n).

Proof. We first obtain a minimum cost integral circulation f in G by executing the

Cycle-Canceling algorithm [17] on the weighted digraph G. From the proof of Lemma 6,

we know that f constructed at Step 3 is an integral circulation in G and x constructed

at Step 4 is a feasible solution to the integer program CARM(G). By the definitions of x

and the digraph GD, we obtain w(T ) =∑

e∈A∪B w(e)x(e) = w(f).

Since an optimal solution for the instance G of the CARM problem must correspond

to an integral circulation in G, then Step 2 works correctly. Because f is a minimum cost

integral circulation in the weighted digraph G, we have

w(f) =∑e∈A

w(e)f(e) ≤ OPT.

On the other hand, by Step 3 of the algorithm CARM, we have the facts f(e) = f(e) for

each arc e ∈ A and the inequalities f(ye, ze) ≤ f(ye, ze) = f(ye, ze)−θ1 +θ2 ≤ f(ye, ze)+1

for each edge e = uv ∈ E. Thus, we can obtain

14

Page 16: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

w(T ) = w(f) =∑e∈A

w(e)f(e) +∑e∈E

∑e′∈De

w(e′)f(e′)

=∑e∈A

w(e)f(e) +∑e∈E

w(ye, ze)f(ye, ze)

≤∑e∈A

w(e)f(e) +∑e∈E

w(ye, ze)(f(ye, ze) + 1)

=∑e∈A

w(e)f(e) +∑e∈E

w(ye, ze)f(ye, ze) +∑e∈E

w(ye, ze)

=∑e∈A

w(e)f(e) +∑e∈E

∑e′∈De

w(e′)f(e′) +∑e∈E

w(e)

= w(f) +∑e∈E

w(e)

≤ w(f) +1

l0

∑e∈E

w(e)l(e)

≤ OPT +1

l0· OPT

= (1 +1

l0) · OPT.

where l0 = min{l(e) | e ∈ E}.It is obvious to see that the running time of the algorithm CARM heavily depends on

the running time of the Cycle-Canceling algorithm [17]. According to Lemma 3, we

know that the running time of the algorithm CARM is O(n2m3 log n).

This establishes the theorem.

The following special version of the CARM problem can be derived from the proof of

Theorem 1.

Corollary 1 Given a digraph D = (V,A; w; l, u) with two integer functions l, u : A → Z+

satisfying l(e) ≤ u(e) for each arc e ∈ A and a length function w : A → Q+, the algorithm

CARM produces an optimal arc routing for D and its running time is O(n2m3 log n).

It is well known that Raghavachari and Veerasamy [31] designed a 3/2-approximation

algorithm to solve the mixed Chinese postman problem. We propose a conjecture for the

CARM problem to conclude this section.

Conjecture 1 It would admit a 3/2-approximation algorithm to solve the CARM prob-

lem.

15

Page 17: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

4 The Constrained Edge Routing Problem in Graphs

In this section, we consider the constrained edge routing problem in graphs (CERG), i.e.,

a special version of the constrained arc routing problem in mixed graphs (CARM) for

the case A = ∅. The CERG problem is a generalization of the Chinese postman problem

(CPP).

It is known that the CPP is solvable in polynomial time by the following strategy.

(1) When a graph G is Eulerian, the Eulerian-Cycle algorithm due to Edmonds

and Johnson in [7] produces an Eulerian tour as an optimal solution.

(2) When a graph G is not Eulerian, we must add some edges from G to create a new

Eulerian graph G′. The edges added to create G′ must be of least total length, and an

Eulerian tour in the augmented graph G′ is an optimal solution. As shown in [7], these

edges of least total length can be determined by solving a minimum cost perfect matching

problem on the complete graph H whose vertices are the odd-degree vertices of G.

It is known that each edge in a graph G is used at most twice in any optimal solution

for the CPP. A similar argument can establish the following.

Lemma 7 For any graph G = (V,E; w; l, u) as an instance of the CERG problem, each

edge e in G is used at most l(e) + 1 times in any optimal solution.

For convenience, we may assume u(e) = l(e) + 1 when l(e) < u(e) for each edge e ∈ E

of any instance G = (V, E; w; l, u) for the CERG problem.

In order to describe our combinatorial algorithm to optimally solve the CERG problem,

we need two auxiliary constructions. We construct a multigraph Gl = (V, El), where the

multiset El contains each edge e of E exactly l(e) times. Let Eu = {e ∈ E | l(e) < u(e)}.Then we construct a weighted graph Gu = (V, Eu; wu), where the length function wu :

Eu → Q+ satisfies wu(e) = w(e) for each edge e ∈ Eu.

By Lemma 7, we can design a combinatorial algorithm to solve the CERG problem

by the following strategy.

(1) If needed, find a subset E ′u of Eu such that the augmented multigraph G′ =

(V, El ∪E ′u) is an Eulerian graph, having the minimum total length w(E ′

u) =∑

e∈E′uw(e).

(2) Construct an Eulerian tour on G′. We may call the set E ′u as in [21] a priority set

to the instance G = (V,E; w; l, u) of the CERG problem, or simply a priority set.

16

Page 18: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

In our algorithm to solve the CERG problem, we need an algorithm due to Floyd [11]

in running time O(n3) to find all shortest paths among all odd-degree vertices and an-

other algorithm due to Edmonds [6] in running time O(n3) to find a minimum cost

perfect matching in an appropriate graph. We refer these two algorithms the Floyd

algorithm [11] and the Edmonds algorithm [6], respectively.

An algorithm to solve the CERG problem is designed as follows.

Algorithm 2. CERG

Input: A connected graph G = (V, E; w; l, u) with a length function w : E → Q+ and

two integer functions l, u : E → Z+ satisfying l(e) ≤ u(e) for each e ∈ E.

Output: A minimum length edge routing T on G to satisfy the constraint.

Begin

Step 1 Define El to be a multiset consisting of each edge e of E exactly l(e) times. And

construct the multigraph Gl = (V, El).

Step 2 If (the connected multigraph Gl is Eularian) then

Determine an Eulerian tour T on Gl by means of the Eulerian-Cycle algo-

rithm [7], and stop. The tour T corresponds to an optimal solution on G.

Step 3 Construct a graph Gu = (V, Eu; wu), where Eu = {e ∈ E | l(e) < u(e)} and

wu : Eu → Q+ satisfies wu(e) = w(e) for each edge e ∈ Eu.

Step 4 Determine the set Vo of odd-degree vertices in Gl. Construct a graph H =

(Vo, EH ; wH) with vertex set Vo and edge set EH , where an edge vivj ∈ EH if and

only if there exists a path in Gu to connect the two odd-degree vertices vi and vj,

and then define the cost wH(vi, vj) of edge vivj in H to be the length of a shortest

path Pvi,vjbetween vi and vj in Gu.

Step 5 If (there exists no perfect matching of cardinality |Vo|/2 in H) then

Output “no feasible solution on G”, and stop.

17

Page 19: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Step 6 Use the Edmonds algorithm [6] to find a minimum cost perfect matching M of

cardinality |Vo|/2 in H.

Step 7 Set G′ := Gl. For each edge vivj in the minimum cost perfect matching M , add

to G′ all edges that lie on the shortest path Pvi,vjbetween vi and vj in Gu.

Step 8 Determine an Eulerian tour T on G′ by means of the Eulerian-Cycle algo-

rithm [7], and stop. The tour T corresponds to an optimal solution on G.

End

Using the algorithm CERG, we obtain the following result for the CERG problem.

Theorem 2 The algorithm CERG works correctly to solve the CERG problem and its

running time is O(n3).

Proof. We first prove that the algorithm CERG produces a feasible solution to the

instance G = (V,E; w; l, u) of the CERG problem. Any two shortest paths produced

at Step 4 corresponding to two distinct edges in the minimum cost perfect matching M

must be edge-disjoint, for otherwise another perfect matching M ′ in H can be constructed

satisfying wH(M ′) < wH(M), a contradiction (the proof in details is similar to that in [6],

we omit it here). Then we add to the augmented graph G′ all edges that lie on the shortest

paths Pvi,vjbetween vi and vj in Gu, where vivj corresponds to a matching edge in M .

Thus, G′ becomes an Eulerian graph and the Eulerian tour T on G′ produced at Step 8

is a feasible solution to the instance G = (V, E; w; l, u).

Next, we prove that the Eulerian tour T produced at Step 8 is a minimum total

length solution to the instance G = (V, E; w; l, u) of the CERG problem. We may assume

that T ∗ = (V,E∗) is an optimal tour to G. We shall prove w(T ) ≤ w(T ∗), equivalently,∑

vivj∈M

∑e∈Pvi,vj

w(e) = wH(M) ≤ w(T ∗ − El).

We may assume that the multigraph Gl = (V, El) contains exactly 2k vertices of odd

degree, namely vi1 , vi2 , . . ., vi2k−1, vi2k

, and the vertex set Vo of the graph H at Step 4

consists of precisely these 2k vertices, hence 2k = |Vo|. We consider the reduced graph

H ′ = T ∗ − El, where each vertex of odd degree in H ′ is also a vertex in Vo.

Since El ⊆ E∗ ⊆ (El ∪ Eu) and⋃

vivj∈M E(Pvi,vj) ⊆ Eu, the graph H ′ contains no

cycle. To the contrary, we may suppose that if C were a cycle in H ′, then the reduced

18

Page 20: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

graph T ∗ − E(C), satisfying w(T ∗ − E(C)) < w(T ∗), would be another feasible solution

to the instance G of the CERG problem, which contradicts the optimality of w(T ∗).

Since the graph H ′ contains no cycle, we obtain the fact that H ′ is a forest. Then

the edges in H ′ can be decomposed into k edge-disjoint simple paths by modifying graph

searching algorithm [30] in the following recursive steps (note that H ′ contains at least

two vertices of degree 1).

(1) For r = 1, choose any vertex of degree 1 in H ′, namely vj2r−1 , and by using the

similar graph searching algorithm in [30] to find the next vertex of odd degree along sole

path from vj2r−1 in H ′, namely vj2r , we can construct a simple path P ′vj2r−1

,vj2rto connect

vj2r−1 and vj2r in H ′.

(2) Let H ′ := H ′ − E(P ′vj2r−1

,vj2r). Using the similar argument in (1), we can choose

two new vertices of odd degree in the new graph H ′, namely vj2r+1 and vj2r+2 , and then

construct a simple path P ′vj2r+1

,vj2r+2to connect vj2r+1 and vj2r+2 in H ′. Let r := r + 1 and

execute (2) repeatedly until r = k.

Now, without loss of generality, we assume that the edges in H ′ are decomposed into k

edge-disjoint simple paths P ′vj2r−1

,vj2r, r = 1, 2, . . . , k, such that the edge set {vj1vj2 , vj3vj4 ,

. . ., vj2k−1vj2k

} is a perfect matching in H. It follows that dGu(vj2r−1 , vj2r) ≤ w(P ′vj2r−1

,vj2r),

r = 1, 2, . . . , k, and w(H ′) =∑k

r=1 w(P ′vj2r−1

,vj2r).

Since M is a minimum cost perfect matching in H = (Vo, EH ; wH), we obtain

wH(M) =∑

vivj∈M

∑e∈Pvi,vj

w(e) ≤k∑

r=1

dGu(vj2r−1 , vj2r) ≤k∑

r=1

w(P ′vj2r−1

,vj2r) = w(T ∗ − El).

It implies w(T ) = w(El) + wH(M) ≤ w(El) + w(T ∗ − El) = w(T ∗). This shows that

the Eulerian tour T produced at Step 8 has a minimum total length to the instance

G = (V, E; w; l, u) of the CERG problem.

Finally, the running time of the algorithm CERG can be determined as follows.

(1) Since each of the l(e) multi-edges of G can be constructed within a constant time,

the multigraph Gl = (V,El) at Step 1 needs time O(m) to be constructed.

(2) Since each of the l(e) multi-edges of G can be traversed within a constant time,

an Eulerian tour T on G at Step 2 needs at most time O(m) to be determined.

(3) The graph Gu = (V, Eu) at Step 3 needs time O(m) to be constructed.

19

Page 21: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

(4) The graph H at Step 4 needs time O(n3) to be constructed, by using the Floyd

algorithm [11].

(5) A minimum cost perfect matching M in H at Steps 5 and 6 needs time O(n3) to

be found.

(6) The augmented graph G′ at Step 7 needs at most time O(n2) to be constructed.

(7) An Eulerian tour T on G′ at Step 8 needs at most time O(n2) to be determined.

Hence, the total running time of the algorithm CERG is O(n3). This establishes the

theorem.

Using the algorithm CERG, we can obtain the following immediately.

Corollary 2 For any connected graph G = (V,E; w; u), where a length function w :

E → Q+ and an integer function u : E → Z+, the algorithm CERG can either produce

a minimum length tour traversing each edge e at least once and at most u(e) times or

determine that there is none.

5 The Constrained Arc Routing Problem in Digraphs

In this section, we consider the constrained arc routing problem in digraphs (CARD), that

is the constrained arc routing problem in mixed graphs specialized to the case E = ∅.This problem is a generalization of the directed Chinese postman problem (DCPP).

We know that the DCPP is solvable in polynomial time. A solution exists if and

only if the digraph D is strongly connected. The techniques used to solve the DCPP are

similar to those used for the undirected case. If D is symmetric, i.e., each vertex in D

has equal in- and out-degrees, then the directed Chinese postman tour constructed by the

Eulerian-Circuit algorithm [7] corresponds to a directed Eulerian circuit in D.

If D is not symmetric, then copies of some arcs of D must be added to D so that the

augmented digraph D′ becomes symmetric. A directed Eulerian circuit in D′ corresponds

to a directed Chinese postman tour in D. The digraph D′ can be obtained from D by

solving a transportation problem described in [12].

In order to describe our algorithm to optimally solve the CARD problem, we need

two auxiliary constructions. First, we construct a multidigraph Dl = (V,Al), where

20

Page 22: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

the multiset Al contains each arc e of A exactly l(e) times. Let Au denote the subset

{e ∈ A | l(e) < u(e)}. Next, we construct a weighted digraph Du = (V,Au; wu), where

the length function wu : Au → Q+ satisfies wu(e) = w(e) for each arc e ∈ Au. For

any feasible solution for the CARD problem, find some multi-arcs from Au to create the

multiset A′u such that the augmented multidigraph D′ = (V, Al ∪ A′

u) is Eulerian.

Modifying the steps to solve the DCPP, we can solve the CARD problem by the

following strategy.

(1) If needed, find a multiset A′u of Au such that the augmented multidigraph D′ =

(V, Al ∪ A′u) is Eulerian, having the minimum total length w(A′

u) =∑

e∈A′uw(e).

(2) Construct a directed Eulerian circuit in D′.

In our algorithm to solve the CARD problem, we needed a combinatorial algorithm

in [28] to solve the minimum cost integral (s, t)-flow problem, that was referred the

Enhanced-Capacity-Scaling algorithm in Lemma 5.

We design an algorithm to solve the CARD problem as follows.

Algorithm 3. CARD

Input: A strongly connected digraph D = (V,A; w; l, u) with a length function w : A →Q+ and two integer functions l, u : A → Z+ satisfying l(e) ≤ u(e) for all arcs e ∈ A.

Output: A minimum length arc routing T on D to satisfy the constraint.

Begin

Step 1 Let Al denote the multiset consisting of each arc e of A exactly l(e) times. And

construct the multidigraph Dl = (V, Al).

Step 2 For each vertex v ∈ V , compute σDl(v) = d−

Dl(v) − d+

Dl(v).

Step 3 If (Dl is strongly connected and σDl(v) = 0 for each vertex v ∈ V ) then

Determine a directed Eulerian circuit T on Dl by using the Eulerian-Circuit

algorithm in [7], and stop. The tour T corresponds to an optimal solution on D.

Step 4 Construct the digraph Du = (V,Au; wu), where Au = {e ∈ A | l(e) < u(e)} and

wu : Au → Q+ satisfies wu(e) = w(e) for each arc e ∈ Au.

21

Page 23: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Step 5 Let I = {vi ∈ V | σDl(vi) > 0} and J = {vj ∈ V | σDl

(vj) < 0}.

Step 6 Construct a network N = (V ′, A′; u′; c; s, t) from the digraph Du = (V, Au; wu)

satisfying the following.

(1) Let V ′ = V ∪ {s, t} and A′ = Au ∪ AI ∪ AJ . The source s and the sink t are

two vertices not belonging to V so that AI = {(s, vi) | vi ∈ I} and AJ = {(vj, t) |vj ∈ J}.

(2) Define the capacity function u′ : A′ → Z+ as follows

u′(e) =

⎧⎪⎪⎪⎨⎪⎪⎪⎩

u(e) − l(e) if the arc e ∈ Au,

σDl(vi) if the arc e = (s, vi) ∈ AI ,

−σDl(vj) if the arc e = (vj, t) ∈ AJ .

(3) Define the cost function c : A′ → Q+ as follows

c(e) =

⎧⎪⎪⎪⎨⎪⎪⎪⎩

w(e) if the arc e ∈ Au,

0 if the arc e = (s, vi) ∈ AI ,

0 if the arc e = (vj, t) ∈ AJ .

(4) Let σ0 =∑

vi∈I σDl(vi).

Step 7 If (there exists no (s, t)-flow of value σ0) then

Output “no feasible solution in D”, and stop.

Step 8 Using the Enhanced-Capacity-Scaling algorithm in [28], determine a min-

imum cost integral (s, t)-flow f of value σ0 in N .

Step 9 Construct the multiset of arcs Af = {(x, y)1, (x, y)2, . . . , (x, y)f(x,y) | (x, y) ∈Au and f(x, y) > 0}.

Step 10 Construct the multidigraph Df := (V,Al ∪ Af ).

Step 11 Determine a directed Eulerian circuit T on Df by the Eulerian-Circuit

algorithm in [7], and stop. The tour T corresponds to an optimal solution on D.

End

22

Page 24: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Using the algorithm CARD, we obtain the following result for the CARD problem.

Theorem 3 The algorithm CARD works correctly to solve the CARD problem, and its

running time is O(nm2 log n).

Proof. First, we prove the output tour T produced by the algorithm CARD is a feasible

directed circuit to the digraph D = (V, A; w; l, u) of the CARD problem. If T is produced

at Step 3, it is easy to verify that T is an optimal solution to the digraph D = (V, A; w; l, u).

Now, we assume that output T is produced at Step 11. Since f is a minimum cost integral

(s, t)-flow of value σ0, where σ0 =∑

vi∈I σDl(vi), we obtain the following three facts.

(1)∑

x:(vi,x)∈Au

f(vi, x) − ∑x:(x,vi)∈Au

f(x, vi) = f(s, vi) = σDl(vi) for each vertex vi of I;

(2)∑

y:(y,vj)∈Au

f(y, vj) −∑

y:(vj ,y)∈Au

f(vj, y) = f(vj, t) = −σDl(vj) for each vertex vj of J ;

(3)∑

x:(x,z)∈Au

f(x, z) =∑

y:(z,y)∈Au

f(z, y) for each vertex z of V − (I ∪ J).

For each vertex vi ∈ I, we have

d+Df

(vi) = d+Dl

(vi) +∑

x:(vi,x)∈Au

f(vi, x)

= d+Dl

(vi) +∑

x:(x,vi)∈Au

f(x, vi) + σDl(vi)

= d+Dl

(vi) +∑

x:(x,vi)∈Au

f(x, vi) + (d−Dl

(vi) − d+Dl

(vi))

= d−Dl

(vi) +∑

x:(x,vi)∈Au

f(x, vi)

= d−Df

(vi).

For each vertex vj ∈ J , we have

d−Df

(vj) = d−Dl

(vj) +∑

y:(y,vj)∈Au

f(y, vj)

= d−Dl

(vj) +∑

y:(vj ,y)∈Au

f(vj, y) − σDl(vj)

= d−Dl

(vj) +∑

y:(vj ,y)∈Au

f(vj, y) − (d−Dl

(vj) − d+Dl

(vj))

= d+Dl

(vj) +∑

y:(vj ,y)∈Au

f(vj, y)

= d+Df

(vj).

23

Page 25: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

For each vertex z of V − (I ∪ J), we have

d+Df

(z) = d+Dl

(z) +∑

y:(z,y)∈Au

f(z, y)

= d−Dl

(u) +∑

x:(x,z)∈Au

f(x, z)

= d−Df

(z).

This shows that d+Df

(z) = d−Df

(z) for each vertex z in Df . Since D is strongly connected,

so is Df . Thus, Df is an Eulerian digraph. Obviously, the output tour T on Df produced

at Step 11 is a feasible solution to the instance D = (V,A; w; l, u) of the CARD problem.

Next, we prove that the Eulerian tour T produced at Step 11 is a minimum total

length solution to the instance D = (V, A; w; l, u). We may assume that T ∗ = (V, A∗)

is an optimal directed tour on D = (V, A; w; l, u) such that each arc e in A appears in

T ∗ exactly lT ∗(e) times, where l(e) ≤ lT ∗(e) ≤ u(e), and that w(T ∗) =∑

e∈T ∗ w(e) is

minimized.

Let the directed subgraph H ′ = D[T ∗ − Al] be obtained from the multidigraph H =

T ∗ − Al by replacing multi-arcs joining the same pair of end-vertices by one arc. Since

T ∗ is an optimal directed tour in D, by the fact that Al is a multiset of arcs of A, the

multidigraph H contains no directed circuit, otherwise the optimal value w(T ∗) would be

reduced. It follows that the reduced digraph H ′ is an acyclic subdigraph of the digraph Du.

Now, let I ′ = {vi ∈ V | d+H(vi) > d−

H(vi)} and J ′ = {vj ∈ V | d−H(vj) > d+

H(vj)}.Since T ∗ is an optimal directed tour in D and it traverses all arcs in Al, and for every

vertex v ∈ V , we have d+T ∗(v) = d+

Dl(v) + d+

H(v), d−T ∗(v) = d−

Dl(v) + d−

H(v) and d+T ∗(v) =

d−T ∗(v). It follows that d+

H(v) − d−H(v) = d−

Dl(v) − d+

Dl(v) = σDl

(v). In addition, we have

known I ′ = I and J ′ = J such that∑

vi∈I(d+H(vi) − d−

H(vi)) =∑

vi∈I σDl(vi) = σ0 and

∑vj∈J(d+

H(vj) − d−H(vj)) =

∑vj∈J σDl

(vj) = −σ0.

We define a network N∗ = (V (H ′)∪{s, t}, A′′∪AI∪AJ ; u∗; c; s, t) from H ′ = D[T ∗−Al]

so that A′′ is the arc set of H ′ (clearly, A′′ ⊆ Au), AI = {(s, vi) | vi ∈ I} and AJ = {(vj, t) |vj ∈ J}. The capacity function u∗ : A′′ ∪ AI ∪ AJ → Z+ is defined as follows

u∗(e) =

⎧⎪⎪⎪⎨⎪⎪⎪⎩

lT ∗(e) − l(e) if the arc e ∈ A′′,

σDl(vi) if the arc e = (s, vi) ∈ AI ,

−σDl(vj) if the arc e = (vj, t) ∈ AJ .

24

Page 26: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

and the cost function c : A′′ ∪ AI ∪ AJ → Q+ is defined as follows

c(e) =

⎧⎪⎪⎪⎨⎪⎪⎪⎩

w(e) if the arc e ∈ A′′,

0 if the arc e = (s, vi) ∈ AI ,

0 if the arc e = (vj, t) ∈ AJ .

Now, we can construct an integral (s, t)-flow of value σ0 in N∗ as follows. For each

arc e ∈ A′′, we define f ∗(e) = lT ∗(e) − l(e), f ∗(s, vi) = σDl(vi) for (s, vi) ∈ AI and

f ∗(vj, t) = −σDl(vj) for (vj, t) ∈ AJ . Since T ∗ is an optimal directed tour in D, it is easy

to verify that f∗ is an integral (s, t)-flow of value σ0 in N∗ (and in N) and its cost is

c(f ∗) =∑

e∈A′′ w(e) · (lT ∗(e) − l(e)). It follows that c(f ∗) +∑

e∈Alw(e) =

∑e∈T ∗ w(e).

Since f is a minimum cost integral (s, t)-flow of value σ0 at Step 8 of the algorithm

CARD, we have w(Af ) = c(f) ≤ c(f∗). It follows that w(T ) =∑

e∈Auw(e)f(e) +

∑e∈Al

w(e) = c(f)+∑

e∈Alw(e) ≤ c(f ∗)+

∑e∈Al

w(e) =∑

e∈T ∗ w(e). Hence, the directed

Eulerian tour T produced at Step 11 is a minimum total length solution to the instance

D = (V, A; w; l, u) of the CARD problem.

Finally, the running time of algorithm CARD can be determined as follows.

(1) For each arc e in D, the l(e) multi-arcs at Step 1 need a constant time to be

constructed. Hence, the multidigraph Dl = (V,Al) needs time O(m) to be constructed.

(2) All σDl(v) at Step 2 need at most time O(m) to compute.

(3) For each arc e in D, the l(e) multi-arcs at Step 3 need a constant time to traverse.

A directed Eulerian tour T on D needs at most time O(nm) to be determined.

(4) The digraph Du = (V, Au) at Step 4 needs time O(m) to be constructed.

(5) The network N at Steps 5 and 6 can be constructed in time O(m).

(6) A minimum cost integral (s, t)-flow f in N at Steps 7 and 8 needs time O(nm2 log n)

to be found. The Belleman-Ford algorithm [1] used to solve the shortest path problem

needs time O(nm).

(7) The augmented multidigraph Df at Steps 9 and 10 needs at most time O(m) to

be constructed.

(8) For each arc e in D, the l(e) multi-arcs need a constant time to traverse. A directed

Eulerian tour T on Df at Step 11 needs at most time O(nm) to be determined.

Hence, the running time of algorithm CARD is O(nm2 log n). This establishes the

theorem.

25

Page 27: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Using the algorithm CARD, we can obtain the following immediately.

Corollary 3 For any strongly connected digraph D = (V, A; w; u), where a length function

w : A → Q+ and an integer function u : A → Z+, the algorithm CARD can either produce

a minimum length directed tour traversing each arc e at least once and at most u(e) times

or determine that there is none.

6 Conclusions

In this paper, we considered the constrained arc routing problem in mixed graphs (CARM)

and obtained the following three results.

(1) For any instance G = (V,E ∪ A; w; l, u) of the CARM problem, where l(e) < u(e)

holds for each edge e ∈ E, l(e) ≤ u(e) holds for each arc e ∈ A and l0 = min{l(e) | e ∈ E},we have designed a (1+1/l0)-approximation algorithm in time O(n2m3 log n) to solve the

CARM problem.

(2) We presented a combinatorial algorithm in time O(n3) to optimally solve the

CARM problem for the case A = ∅.(3) We provided a combinatorial algorithm in time O(nm2 log n) to optimally solve

the CARM problem for the case E = ∅.

Acknowledgments

We are very grateful to the two anonymous reviewers for giving us good suggestions and

comments so that we are able to improve our manuscript substantially.

H.L. Ding and J.P. Li are supported by the National Natural Science Foundation of

China [No.61063011], the Project of First 100 High-level Overseas Talents of Yunnan

Province and IRTSTYN. K.W. Lih is supported by NSC [No.102-2115-M-001-010] of

Taiwan.

26

Page 28: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

References

[1] Bellman, R.E. (1958). On a routing problem. Quarterly of Applied Mathematics, 16,

87-90.

[2] Beullens, P., Muyldermans, L., Cattrysse, D., & Oudheusden, D.V. (2003). A guided

local search heuristic for the capacitated arc routing problem, European Journal of

Operational Research, 147, 629-643.

[3] Christofides, N., Benavent, E., Campos, V., Corberan, A., & Mota, E. (1984). An

optimal method for the mixed postman problem. In System Modelling and Optimiza-

tion, Notes in Control and Information Sciences, Vol. 59, Springer.

[4] Corberan, A., Marti, R., & Sanchis, J.M. (2002). A GRASP heuristic for the mixed

Chinese postman problem. European Journal of Operational Research, 142, 70-80.

[5] Dror, M. (Eds.) (2000). Arc Routing: Theory, Solutions and Applications. Springer.

[6] Edmonds, J. (1965). Maximum matching and a polyhedron with (0,1) vertices. Jour-

nal of Research of the National Bureau of Standards B, 69, 125-130.

[7] Edmonds, J., & Johnson, E.L. (1973). Matching, Euler tours and the Chinese post-

man. Mathematical Programming, 5, 88-124.

[8] Edmonds, J., & Karp, R.M. (1972). Theoretical improvements in algorithmic effi-

ciency for network flow problems. Journal of the ACM, 19, 248-264.

[9] Feige, U. (1998). A threshold of lnn for approximating set cover. Journal of the ACM,

45, 634-652.

[10] Fleischner, H. (1991). Eulerian Graphs and Related Topics (Part 1, Vol. 2). Annals

of Discrete Mathematics, 50, North-Holland, Amsterdam.

[11] Floyd, R.W. (1962). Algorithm 97: Shortest path. Communications of the ACM, 5,

345.

[12] Ford, L.R., & Fulkerson, D. R. (1962). Flows in Networks. Princeton University Press,

Princeton, N.J.

27

Page 29: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

[13] Frederickson, G.N. (1979). Approximation algorithms for some postman problems.

Journal of the ACM, 26, 538-554.

[14] Garey, M.R., & Johnson, D.S. (1979). Computers and Intractability: A Guide to the

Theory of NP-Completeness. W. H. Freeman and Co., New York, 212.

[15] Ghiani, G., & Improta, G. (2000). An effcient transformation of the generalized

vehicle routing problem. European Journal of Operational Research, 122, 11-17.

[16] Goel, A., & Gruhn, V. (2008). A general vehicle routing problem. European Journal

of Operational Research, 191, 650-660.

[17] Goldberg, A.V., & Tarjan, R.E. (1989). Finding minimum-cost circulations by can-

celling negative cycles. Journal of the ACM, 36, 873-886.

[18] Golden, B. (1978). Recent developments in vehicle routing. in Computers and Math-

ematical Programming, W. White (Eds.), National Bureau of Standards Special Pub-

lication 502, Washington, D.C., 233-240.

[19] Golden, B., Raghavan, S., & Wasil, E. (Eds.) (2008). The Vehicle Routing Problem:

Latest Advances and New Challenges. Springer.

[20] Golden, B.L., & Wong, R.T. (1981). Capacitated arc routing problems. Networks,

11(3), 305-315.

[21] Guan, M.G. (1960). Graphic programming using odd and even points (in Chinese).

Acta Mathematica Sinica, 10, 263-266. [English translation: Chinese Mathematics,

1: 273-277, 1962]

[22] Hierholzer, C., & Wiener, C. (1873). Uber die Moglichkeit, einen Linienzug ohne

Wiederholung und ohne Unterbrechung zu umfahren. Mathematische Annalen (in

German), 6, 30-32. [Retrieved 17 August 2012]

[23] Nicolas Jozefowiez, N., Semet, F., & Talbi, E.G. (2008). Multi-objective vehicle rout-

ing problems. European Journal of Operational Research, 189, 293-309.

28

Page 30: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

[24] Lysgaard, J., & Wohlk, S. (2014). A branch-and-cut-and-price algorithm for the

cumulative capacitated vehicle routing problem. European Journal of Operational

Research, 236, 800-810.

[25] Mourao, M.C., & Amado, L. (2005). Heuristic method for a mixed capacitated arc

routing problem: A refuse collection application, European Journal of Operational

Research, 160, 139-153.

[26] Nobert, Y., & Picard, J.C. (1996). An optimal algorithm for the mixed Chinese

postman problem. Networks, 27, 95-108.

[27] Orlin, J.B. (1988). A faster strongly polynomial minimum cost flow algorithm. Pro-

ceedings of the 20th ACM Symposium on the Theory of Computing, 377-387.

[28] Orlin, J.B. (1993). A faster strongly polynomial minimum cost flow algorithm.

Opreations Research, 41(2), 338-350.

[29] Papadimitriou, C.H. (1976). On the complexity of edge traversing. Journal of the

ACM, 23(3), 544-554.

[30] Papadimitriou, C.H., & Steiglitz, K. (1998). Combinatorial Optimization: Algo-

rithms and Complexity (Second edition), Dover Publications, 194-195.

[31] Raghavachari, B., & Veerasamy, J. (1999). A 3/2-approximation algorithm for the

mixed postman problem. SIAM Journal on Discrete Mathematics, 12(4), 425-433.

[32] Ralphs, T.K. (1993). On the mixed Chinese postman problem. Operations Research

Letters, 14, 123-127.

[33] Tardos, E. (1985). A strongly polynomial minimum cost circulation algorithm. Com-

binatorica, 5, 247-255.

[34] Toth, P., & Vigo, D. (Eds.) (2002). The Vehicle Routing Problem. SIAM Monographs

on Discrete Mathematics and Applications.

[35] Zachariadis, E.E., & Kiranoudis, C.T. (2011) Local search for the undirected capac-

itated arc routing problem with profits, European Journal of Operational Research,

210, 358-367.

29

Page 31: Approximation algorithms for solving the constrained arc routing problem in mixed graphs

Title: Approximation Algorithms for Solving the Constrained Arc Routing Problem in Mixed Graphs

Research Highlights:

We consider the constrained arc routing problem that generalizes the mixed Chinese postman problem. he objective is to determine a minimum length tour T traversing each edge e at least l(e) and at most u(e) times. We design an (1+1/l_0)-approximation algorithm in time O(n^2m^3\log n) to solve this problem, where l(e)<u(e) holds for each edge e\in E, l(e)<u(e) holds for each arc e\in A and l_0=\min\{l(e) \mid e\in E\}, l_0=\min\{l(e) \mid e\in E\} We also present two optimal combinatorial algorithms in times O(n^3) and O(nm^2\log n) to solve this problem for the cases A=\emptyset and E=\emptyset, respectively.