# On graceful difference labelings of disjoint unions of circuits

Alain Hertz, Christophe Picouleau

► To cite this version:

Alain Hertz, Christophe Picouleau. On graceful difference labelings of disjoint unions of circuits. Open Journal of Discrete Applied Mathematics, 2019, 2 (3), pp.38-55. 10.30538/psrp-odam2019.0021. hal-02436800

HAL Id: hal-02436800

https://hal.science/hal-02436800

Submitted on 25 Feb 2020

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
<figure><img src="image_2.png" /></figure>

Article

# On graceful difference labelings of disjoint unions of circuits

Alain Hertz<fnref n="1" />,\* and Christophe Picouleau<fnref n="2" />

Received: 19 September 2019; Accepted: 7 November 2019; Published date: 30 November 2019

**Abstract:** A graceful difference labeling (gdl for short) of a directed graph $G$ with vertex set $V$ is a bijection $f: V \rightarrow \{1, \dots, |V|\}$ such that, when each arc $uv$ is assigned the label $|f(v) - f(u)|$, the resulting arc labels are distinct. We conjecture that all disjoint unions of circuits have a gdl, except in two particular cases. We prove partial results which support this conjecture.

**Keywords:** Graceful labelings, directed graphs, disjoint unions of circuits.

**MSC:** 05C78, 05C20.

## 1 Introduction

A graph labeling is the assignment of labels, traditionally represented by integers, to the vertices or edges, or both, of a graph, subject to certain conditions. As mentioned in the survey by Gallian [1], more than one thousand papers are devoted to this subject. Among all variations, the most popular and studied graph labelings are the $\beta$-valuations introduced by Rosa in 1966 [2], and later called *graceful labelings* by Golomb [3]. Formally, given a graph $G$ with vertex set $V$ and $q$ edges, a graceful labeling of $G$ is an injection $f: V \rightarrow \{0, 1, \dots, q\}$ such that, when each edge $uv$ is assigned the label $|f(v) - f(u)|$, the resulting edge labels are distinct. In other words, the vertices are labeled using integers in $\{0, 1, \dots, q\}$, and these vertex labels induce an edge labeling from 1 to $q$. The famous Ringel-Kotzig conjecture, also known as the graceful labeling conjecture, hypothesizes that all trees are graceful. It is the focus of many papers and is still open, even for some very restricted graph classes such that trees with 5 leaves, and trees with diameter 6. The survey by Gallian [1] lists several papers dealing with graceful labelings of particular classes of graphs, such that the disjoint union of cliques, the disjoint union of cycles, and the union of cycles with one common vertex.

For a directed graph with vertex set $V$ and $q$ edges, a graceful labeling of $G$ is an injection $f: V \rightarrow \{0, 1, \dots, q\}$ such that, when each arc (i.e., directed edge) $uv$ is assigned the label $(f(v) - f(u)) (\text{mod } q + 1)$, the resulting arc labels are distinct. As mentioned in [1] and [4], most results and conjectures on graceful labelings of directed graphs concern directed cycles, the disjoint union of directed cycles, and the union of directed cycles with one common vertex or one common arc. In particular, it is proved that $n\bar{C}_3$, the disjoint union of $n$ copies of the directed cycle with three vertices, has a graceful labeling only if $n$ is even. However, it is not known whether this necessary condition is also sufficient.

In this paper, we study *graceful difference labelings* of directed graphs, which are defined as follows. A graceful difference labeling (gdl for short) of a directed graph $G = (V, A)$ is a bijection $f: V \rightarrow \{1, \dots, |V|\}$ such that, when each arc $uv$ is assigned the *difference label* $f(v) - f(u)$, the resulting arc labels are distinct. The absolute value $|f(v) - f(u)|$ is called the *magnitude* of arc $uv$, while $f(v)$ is the *vertex label* of $v$. Note that in a gdl of $G$, two arcs $uv$ and $u'v'$ may have the same magnitude $|f(v) - f(u)| = |f(v') - f(u')|$ but their difference labels must then be opposite, i.e., $f(v) - f(u) = -(f(v') - f(u'))$.

Given two graphs $G_i = (V_i, A_i)$ and $G_j = (V_j, A_j)$ with $V_i \cap V_j = \emptyset$, their disjoint union, denoted $G_i + G_j$, is the graph with vertex set $V_i \cup V_j$ and arc set $A_i \cup A_j$. By $pG$ we denote the disjoint union of $p$ copies of $G$. For $k \ge 2$ we denote by $\bar{C}_k$ a circuit on $k$ vertices isomorphic to the directed graph with vertex set $V = \{v_1, \dots, v_k\}$

<footnote n="1">¹ Department of Mathematics and Industrial Engineering, Polytechnique Montréal and GERAD, Montréal, Canada.</footnote>

<footnote n="2">² CEDRIC, Conservatoire National des arts et métiers, Paris France.; christophe.picouleau@cnam.fr</footnote>

<footnote>\* Correspondence: alain.hertz@gerad.ca</footnote>
and arc set $A = \{v_i v_{i+1} : 1 \le i < k\} \cup \{v_k v_1\}$. The circuit $\vec{C}_3$ is also called a directed triangle, or simply a triangle. For all graph theoretical terms not defined here the reader is referred to [5].

Not every directed graph has a gdl. Indeed, a necessary condition for $G = (V, A)$ to have a gdl is $|A| \le 2(|V| - 1)$. Nevertheless this condition is not sufficient since, for example, $\vec{C}_3$ has no gdl. Indeed, all bijections $f: V \to \{1,2,3\}$ induce two difference labels equal to 1, or two equal to -1. As a second example, $\vec{C}_2 + \vec{C}_3$ has no gdl. Indeed:

* If the two arcs of $\vec{C}_2$ have a magnitude equal to 1, 2, or 3, then $\vec{C}_3$ also has an arc with the same magnitude, which means that two arcs in $\vec{C}_2 + \vec{C}_3$ have the same difference label;

* If the magnitude of two arcs of $\vec{C}_2$ is equal to 4, then two difference labels in $\vec{C}_3$ are equal to 1 or to -1.

We conjecture that all disjoint unions of circuits have a gdl, except for the two cases mentioned above. We were not able to prove this conjecture, but give partial results on it. In particular, we show that $n\vec{C}_3$ has a gdl if and only if $n \ge 2$.

## 2 Partial proof of the conjecture

We are interested in determining which disjoint unions of circuits have a gdl. As already mentioned in the previous section, $\vec{C}_3$ and $\vec{C}_2 + \vec{C}_3$ have no gdl. We conjecture that these two graphs are the only two exceptions. As first result, we show that if $G$ is a circuit of length $k = 2$ or $k \ge 4$, then $G$ has a gdl. We next prove that if $G$ has a gdl, and if $G'$ is obtained by adding to $G$ a circuit of even length $k = 2$ or $k \ge 6$, or two disjoint circuits of length 4, then $G'$ also has a gdl. We also show that the disjoint union of $\vec{C}_4$ with a circuit of odd length has a gdl. All together, these results prove that if $G$ is the disjoint union of circuits, among which at most one has an odd length, then $G$ has a gdl, unless $G = \vec{C}_3$ or $G = \vec{C}_2 + \vec{C}_3$.

We next show that the disjoint union of $n \ge 2$ circuits of length 3 has a gdl, and this is also the case if a $\vec{C}_4$ is added to $n\vec{C}_3$. Hence, if $G$ is the union of disjoint circuits with no odd circuit of length $k \ge 5$, then $G$ has a gdl, unless $G = \vec{C}_3$ or $G = \vec{C}_2 + \vec{C}_3$. In order to prove the above stated conjecture, it will thus remain to show that if $G$ is the disjoint union of circuits with at least two odd circuits, among which at least one has length $k \ge 5$, then $G$ has a gdl.

Our first lemma shows that all circuits have a gdl, except $\vec{C}_3$.

**Lemma 1.** The circuit $\vec{C}_k$ with $k = 2$ or $k \ge 4$ has a gdl. Moreover, if $k \ge 5$, then $\vec{C}_k$ has a gdl with exactly one arc of magnitude 1.

*Proof.* Clearly, $\vec{C}_2$ has a gdl since the two bijections $f: V \to \{1,2\}$ have 1 and -1 as difference labels. So assume $k \ge 4$. We distinguish four cases, according to the value of $k \bmod 4$:

* If $k = 4p, p \ge 1$, we consider the following vertex labels:

$$- f(v_{2i+1}) = i+1, 0 \le i \le 2p-2;$$

$$- f(v_{2i}) = 4p+1-i, 1 \le i \le 2p-2;$$

$$- f(v_{4p-2}) = 2p+1, f(v_{4p-1}) = 2p+2, f(v_{4p}) = 2p.$$

Clearly, $f$ is a bijection between $\{v_1, \dots, v_k\}$ and $\{1, \dots, k\}$ with the following difference labels:

$$- f(v_{i+1}) - f(v_i) = (-1)^{i+1}(4p-i), 1 \le i \le 4p-4;$$

$$- f(v_{4p-2}) - f(v_{4p-3}) = 2, f(v_{4p-1}) - f(v_{4p-2}) = 1, f(v_{4p}) - f(v_{4p-1}) = -2, f(v_1) - f(v_{4p}) = -2p+1.$$

All magnitudes are distinct, except in three cases:

$$- f(v_{4p-2}) - f(v_{4p-3}) = 2 \text{ and } f(v_{4p}) - f(v_{4p-1}) = -2;$$

$$- \text{ for } p \ge 3, f(v_{2p+2}) - f(v_{2p+1}) = 2p-1 \text{ and } f(v_1) - f(v_{4p}) = -(2p-1);$$

$$- \text{ for } p = 1, f(v_{4p-1}) - f(v_{4p-2}) = 1 \text{ and } f(v_1) - f(v_{4p}) = -1.$$

Hence, $f$ is a gdl, and there is exactly one arc of magnitude 1 when $p \ge 2$.

* If $k = 4p+1, p \ge 1$, we consider the following vertex labels:
$$-f(v_{2i+1}) = i+1, 0 \le i \le 2p;$$

$$-f(v_{2i}) = 4p+2-i, 1 \le i \le 2p.$$

Again, $f$ is a bijection between $\{v_1, \dots, v_k\}$ and $\{1, \dots, k\}$ with the following difference labels:

$$-f(v_{i+1}) - f(v_i) = (-1)^{i+1}(4p+1-i), 1 \le i \le 4p;$$

$$-f(v_1) - f(v_{4p+1}) = -2p.$$

All magnitudes are distinct, except for one pair of arcs: $f(v_{2p+2}) - f(v_{2p+1}) = 2p$ and $f(v_1) - f(v_{4p+1}) = -2p$. Hence, $f$ is a gdl with exactly one arc of magnitude 1.

* If $k = 4p + 2, p \ge 0$, we consider the following vertex labels:

$$-f(v_{2i+1}) = i+1, 0 \le i \le 2p;$$

$$-f(v_{2i}) = 4p+3-i, 1 \le i \le 2p+1.$$

Here also, $f$ is a bijection between $\{v_1, \dots, v_k\}$ and $\{1, \dots, k\}$ with the following difference labels:

$$-f(v_{i+1}) - f(v_i) = (-1)^{i+1}(4p+2-i), 1 \le i \le 4p+1;$$

$$-f(v_1) - f(v_{4p+2}) = -2p-1.$$

There are only two equal magnitudes: $f(v_{2p+2}) - f(v_{2p+1}) = 2p+1$ and $f(v_1) - f(v_{4p+2}) = -(2p+1)$. Hence, $f$ is a gdl with exactly one arc of magnitude 1 when $p \ge 1$.

* If $k = 4p + 3, p \ge 1$, we consider the following vertex labels:

$$-f(v_{2i+1}) = i+1, 0 \le i \le 2p-1;$$

$$-f(v_{2i}) = 4p+4-i, 1 \le i \le 2p;$$

$$-f(v_{4p+1}) = 2p+2, f(v_{4p+2}) = 2p+1, f(v_{4p+3}) = 2p+3.$$

For this last case, $f$ is a bijection between $\{v_1, \dots, v_k\}$ and $\{1, \dots, k\}$ with the following difference labels:

$$-f(v_{i+1}) - f(v_i) = (-1)^{i+1}(4p+3-i), 1 \le i \le 4p-1;$$

$$-f(v_{4p+1}) - f(v_{4p}) = -2, f(v_{4p+2}) - f(v_{4p+1}) = -1, f(v_{4p+3}) - f(v_{4p+2}) = 2, f(v_1) - f(v_{4p+3}) = -(2p+2).$$

All magnitudes are distinct, except in two cases:

$$-f(v_{4p-2}) - f(v_{4p-3}) = 2 \text{ and } f(v_{4p}) - f(v_{4p-1}) = -2;$$

$$-f(v_{2p+2}) - f(v_{2p+1}) = 2p+2 \text{ and } f(v_1) - f(v_{4p+3}) = -(2p+2).$$

Hence, $f$ is a gdl with exactly one arc of magnitude 1.

□

We now show how to add two circuits of length 4, or one even circuit of length $k \ge 6$ to a graph that has a gdl.

**Lemma 2.** If a graph $G$ has a gdl, then $G + 2\vec{C}_4$ also has a gdl.

**Proof.** Let $\{v_1, v_2, v_3, v_4\}$ be the vertex set of the first $\vec{C}_4$, and let $\{v_1v_2, v_2v_3, v_3v_4, v_4v_1\}$ be its arc set. Also, let $\{v_5, v_6, v_7, v_8\}$ be the vertex set of the second $\vec{C}_4$, and let $\{v_5v_6, v_6v_7, v_7v_8, v_8v_5\}$ be its arc set.

Suppose $G = (V, A)$ has a gdl $f$. Define $f'(v) = f(v) + 4$ for all $v \in V$ as well as $f'(v_1) = 1, f'(v_2) = |V| + 8, f'(v_3) = 2, f'(v_4) = |V| + 6, f'(v_5) = 3, f'(v_6) = |V| + 5, f'(v_7) = 4$, and $f'(v_8) = |V| + 7$. Clearly, $f'$ is a bijection between $V \cup \{v_1, \dots, v_8\}$ and $\{1, \dots, |V| + 8\}$. Moreover, the difference labels on the arcs of the two circuits are $f'(v_2) - f'(v_1) = |V| + 7, f'(v_3) - f'(v_2) = -(|V| + 6), f'(v_4) - f'(v_3) = |V| + 4, f'(v_1) - f'(v_4) = -(|V| + 5), f'(v_6) - f'(v_5) = |V| + 2, f'(v_7) - f'(v_6) = -(|V| + 1), f'(v_8) - f'(v_7) = |V| + 3$, and $f'(v_5) - f'(v_8) = -(|V| + 4)$. Since all magnitudes in $G$ are at most equal to $|V| - 1, f'$ is a gdl for $G + 2\vec{C}_4$. □

Note that in the proof of Lemma 2, $G$ can be the empty graph $G$ with no vertex and no arc. Hence $2\vec{C}_4$ has a gdl.

**Lemma 3.** If a graph $G$ has a gdl, then $G + \vec{C}_{2k}$ also has a gdl for $k \ge 1, k \ne 2$.
**Proof.** Suppose $G = (V, A)$ has a gdl $f$, and let $\{v_1, \dots, v_{2k}\}$ be the vertex set and $\{v_1v_2, \dots, v_{2k-1}v_{2k}, v_{2k}v_1\}$ be the arc set of $\overrightarrow{C_{2k}}$. We consider two case.

* If $k$ is odd, then define $f'(v) = f(v) + k$ for all $v \in V$, as well as $f'(v_{2i-1}) = k - i + 1$ and $f'(v_{2i}) = |V| + k + i$ for $1 \le i \le k$. Clearly, $f'$ is a bijection between $V \cup \{v_1, \dots, v_{2k}\}$ and $\{1, \dots, |V| + 2k\}$. Moreover, the magnitudes on $\overrightarrow{C_{2k}}$ are strictly larger than $|V|$ and all different, except in one case : $f'(v_{k+1}) - f'(v_k) = |V| + k$ and $f'(v_1) - f'(v_{2k}) = -(|V| + k)$. Since all magnitudes in $G$ are strictly smaller than $|V|$, $f'$ is a gdl for $G + \overrightarrow{C_{2k}}$.

* If $k$ is even and at least equal to 4, then set $f'(v) = f(v) + k$ for all $v \in V$, and define the vertex labels on $\overrightarrow{C_{2k}}$ as follows:

- $f'(v_{2i-1}) = k - i + 1$ for $1 \le i \le k$;

- $f'(v_{2i}) = |V| + k + i$ for $1 \le i \le k - 3$;

- $f'(v_{2k-4}) = |V| + 2k, f'(v_{2k-2}) = |V| + 2k - 2, f'(v_{2k}) = |V| + 2k - 1$.

$f'$ is bijection between $V \cup \{v_1, \dots, v_{2k}\}$ and $\{1, \dots, |V| + 2k\}$, and all magnitudes on $\overrightarrow{C_{2k}}$ are strictly larger than $|V|$. Moreover, all magnitudes on $\overrightarrow{C_{2k}}$ are different, except in two cases :

- $f'(v_k) - f'(v_{k-1}) = |V| + k - 1$ and $f'(v_1) - f'(v_{2k}) = -(|V| + k - 1)$;

- $f'(v_{2k-4}) - f'(v_{2k-5}) = |V| + 2k - 3$ and $f'(v_{2k-1}) - f'(v_{2k-2}) = -(|V| + 2k - 3)$.

Since all magnitudes in $G$ are strictly smaller than $|V|$, $f'$ is a gdl for $G + \overrightarrow{C_{2k}}$.

□

Since graph $G$ in the statement of Lemma 2 is possibly empty, it follows from Lemmas 1, 2 and 3 that all disjoint unions of circuits of even length have a gdl.

We now consider disjoint unions of circuits among which exactly one has as an odd length. As already observed, $\overrightarrow{C_3}$ and $\overrightarrow{C_2} + \overrightarrow{C_3}$ have no gdl. We show that these are the only two exceptions. According to Lemmas 2 and 3, it is sufficient to prove that $2\overrightarrow{C_2} + \overrightarrow{C_3}, \overrightarrow{C_4} + \overrightarrow{C_{2k+1}} (k \ge 1)$, and $\overrightarrow{C_{2k}} + \overrightarrow{C_3} (k \ge 3)$ have a gdl.

**Lemma 4.** $2\overrightarrow{C_2} + \overrightarrow{C_3}$ has a gdl.

**Proof.** Let $\{v_1, \dots, v_7\}$ be the vertex set and $\{v_1v_2, v_2v_1, v_3v_4, v_4v_3, v_5v_6, v_6v_7, v_7v_5\}$ be the arc set of $2\overrightarrow{C_2} + \overrightarrow{C_3}$. By considering the vertex labels $f(v_1) = 1, f(v_2) = 6, f(v_3) = 3, f(v_4) = 7, f(v_5) = 2, f(v_6) = 4$ and $f(v_7) = 5$, it is easy to observe that $f$ is a gdl.

**Lemma 5.** $\overrightarrow{C_4} + \overrightarrow{C_{2k+1}}$ has a gdl for every $k \ge 1$.

**Proof.** Let $G = \overrightarrow{C_4} + \overrightarrow{C_{2k+1}}$. We distinguish two cases:

* If $k$ is odd, then $G$ contains $n = 4(\frac{k+1}{2}) + 3$ vertices. Consider the vertex labels of $\overrightarrow{C_n}$ used in the last case of the proof of Lemma 1, with $p = \frac{k+1}{2}$, and assume that $\{v_1, v_{n-2}, v_{n-1}, v_n\}$ is the vertex set of the $\overrightarrow{C_4}$ in $G$, while $\{v_2, v_3, \dots, v_{n-3}\}$ is the vertex set of the $\overrightarrow{C_{2k+1}}$. It is sufficient to prove that the difference labels on $v_1v_{n-2}$ and $v_{n-3}v_2$ do not appear on any other arc of $G$.

- $f(v_{n-2}) - f(v_1) = (2p + 2) - 1 = (k + 3) - 1 = k + 2$, which is an odd positive number, while all other odd difference labels are negative.

- $f(v_2) - f(v_{n-3}) = (4p + 3) - (2p + 4) = 2p - 1 = k$, which is again an odd positive number, different for the other negative odd labels.

* If $k$ is even, consider the vertex labels of $\overrightarrow{C_{2k+4}}$ used in the first case of the proof of Lemma 1 with $p = \frac{k}{2} + 1 \ge 2$ (i.e., $4p = 2k + 4$). Also, define $f(v_{2k+5}) = 2k + 5 = 4p + 1$. Assume that $\{v_1, v_{2k+2}, v_{2k+3}, v_{2k+4}\}$ is the vertex set of the $\overrightarrow{C_4}$ in $G$, while $\{v_2, v_3, \dots, v_{2k+1}, v_{2k+5}\}$ is the vertex set of the $\overrightarrow{C_{2k+1}}$. It is sufficient to prove that the difference labels on $v_1v_{2k+2}, v_{2k+5}v_2$, and $v_{2k+1}v_{2k+5}$ do not appear on any other arc of $G$.
- $f(v_{2k+2}) - f(v_1) = (2p+1) - 1 = (k+3) - 1 = k+2$, which is an even positive number, while all other even difference labels are negative.

- $f(v_2) - f(v_{2k+5}) = (4p) - (4p+1) = -1$. Since $p > 1$, the only other arc with magnitude 1 is $v_{2k+2}v_{2k+3}$ which has a difference label of 1.

- $f(v_{2k+5}) - f(v_{2k+1}) = (4p+1) - (2p-1) = 2p+2 = k+4$, which is again an even positive number, while all other even difference labels are negative.

□

**Lemma 6.** $\overrightarrow{\mathbf{C}_k} + \overrightarrow{\mathbf{C}_3}$ has a gdl for every $k \ge 5$.

**Proof.** Let $\{v_1, \dots, v_{k+3}\}$ be the vertex set and $\{v_1v_2, \dots, v_{k-1}v_k, v_kv_1, v_{k+1}v_{k+2}, v_{k+2}v_{k+3}, v_{k+3}v_{k+1}\}$ be the arc set of $G = \overrightarrow{\mathbf{C}_k} + \overrightarrow{\mathbf{C}_3}$. Consider the gdl $f$ defined in the proof of Lemma 1 for $\overrightarrow{\mathbf{C}_k}$, and set $f'(v_i) = f(v_i) + 2$ for all $i = 1, \dots, k$. If the only arc of magnitude 1 has a difference label equal to -1, then define $f'(v_{k+1}) = 1$, $f'(v_{k+2}) = 2$, and $f'(v_{k+3}) = k+3$, else define $f'(v_{k+1}) = 2$, $f'(v_{k+2}) = 1$, and $f'(v_{k+3}) = k+3$. Clearly, $f'$ is a bijection between $\{v_1, \dots, v_{k+3}\}$ and $\{1, \dots, k+3\}$. To conclude that $f'$ is a gdl, it is sufficient to prove that the difference labels on $\overrightarrow{\mathbf{C}_3}$ do not appear on $\overrightarrow{\mathbf{C}_k}$.

* The arc $v_{k+1}v_{k+2}$ is of magnitude 1, and its difference label has the sign opposite to that of magnitude 1 in $\overrightarrow{\mathbf{C}_k$;

* The magnitudes of $v_{k+2}v_{k+3}$ and $v_{k+3}v_{k+1}$ are distinct and larger than $k$, while all magnitudes in $\overrightarrow{\mathbf{C}_k}$ are strictly smaller than $k$.

□

All together, the previous lemmas show that if $G$ be the disjoint union of circuits, among which at most one has an odd length, then $G$ has a gdl if and only if $G \neq \overrightarrow{\mathbf{C}_3}$ and $G \neq \overrightarrow{\mathbf{C}_2} + \overrightarrow{\mathbf{C}_3}$.

We now consider the disjoint union of $n$ circuits of length 3, and show that these graphs have a gdl for all $n \ge 2$.

**Lemma 7.** For every $n \ge 2$, the graph $n\overrightarrow{\mathbf{C}_3}$ has a gdl with at most one arc of magnitude $3n-2$, and all other arcs of magnitude strictly smaller than $3n-2$.

**Proof.** The graphs in Figures 1, 2, 3, 4, 5, 6, 7 and 8 show the existence of the desired gdl for $2 \le n \le 9$.

<figure><img src="image_3.png" /><figcaption>Figure 1. $2\overrightarrow{\mathbf{C}_3}$.</figcaption></figure>

<figure><img src="image_4.png" /><figcaption>Figure 2. $3\overrightarrow{\mathbf{C}_3}$.</figcaption></figure>
<figure><img src="image_5.png" /><figcaption>Figure 3. $4\vec{C}_3$.</figcaption></figure>

<figure><img src="image_6.png" /><figcaption>Figure 4. $5\vec{C}_3$.</figcaption></figure>

<figure><img src="image_7.png" /><figcaption>Figure 5. $6\vec{C}_3$.</figcaption></figure>
<figure><img src="image_8.png" /></figure>

<figure><img src="image_9.png" /></figure>

<figure><img src="image_10.png" /></figure>
We now prove the result by induction on $n$. So, consider the graph $n\vec{C}_3$ with $n \ge 10$, and assume the result is true for less than $n$ directed triangles. Let $t$ and $r$ be two integers such that $-4 \le r \le 2$ and $n = 7t + r$.

We thus have $t \ge 2$. We will show how to construct a gdl for $n\vec{C}_3$ given a gdl for $t\vec{C}_3$. We thus have to add $n-t$ directed triangles to $t\vec{C}_3$. For this purpose, define

$$ \theta = \left\lfloor \frac{n-t}{2} \right\rfloor = 3t + \left\lfloor \frac{r}{2} \right\rfloor. $$

It follows that $n-t = 2\theta$ if $r$ is even, and $n-t = 2\theta-1$ if $r$ is odd. We now prove the lemma by considering the 4 cases A,B,C,D defined in Table 1.

<table><caption>**Table 1.** Four different cases</caption><thead><tr><th>n - t</th><th>r</th><th>θ</th><th>Case</th></tr></thead><tbody><tr><td rowspan="3">2θ</td><td>-4</td><td>3t - 2</td><td rowspan="3">A</td></tr><tr><td>-2</td><td>3t - 1</td></tr><tr><td>0</td><td>3t</td></tr><tr><td rowspan="3">2θ - 1</td><td>2</td><td>3t + 1</td><td>B</td></tr><tr><td>-3</td><td>3t - 1</td><td rowspan="2">C</td></tr><tr><td>-1</td><td>3t</td></tr><tr><td></td><td>1</td><td>3t + 1</td><td>D</td></tr></tbody></table>

**Case A:** $n = 2\theta + t, \theta \in \{3t-2, 3t-1, 3t\}$

Consider $2\theta$ directed triangles $T_1, \dots, T_{2\theta}$, every $T_i$ having $\{v_{3i-2}, v_{3i-1}, v_{3i}\}$ as vertex set and $\{v_{3i-2}v_{3i-1}, v_{3i-1}v_{3i}, v_{3i}v_{3i-2}\}$ as arc set. Consider the vertex labels $f(v_i)$ for $T_1, \dots, T_{2\theta}$ shown in Table 2. Also, let $f'$ be

<table><caption>**Table 2.** The labeling of $T_1, \dots, T_{2\theta}$ for case A.</caption><thead><tr><th>Triangle T<sub>i</sub></th><th>f(v<sub>3i-2</sub>)</th><th>f(v<sub>3i-1</sub>)</th><th>f(v<sub>3i</sub>)</th></tr></thead><tbody><tr><td>T<sub>1</sub></td><td>1</td><td>2θ + 1</td><td>6θ + 3t - 3</td></tr><tr><td>T<sub>2</sub></td><td>2</td><td>6θ + 3t</td><td>4θ + 3t</td></tr><tr><td>T<sub>3</sub></td><td>3</td><td>6θ + 3t - 1</td><td>2θ + 2</td></tr><tr><td>T<sub>4</sub></td><td>4</td><td>4θ + 3t - 1</td><td>6θ + 3t - 2</td></tr><tr><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr><tr><td>T<sub>2k-1</sub></td><td>2k - 1</td><td>2θ + k</td><td>6θ + 3t - 2k + 2</td></tr><tr><td>T<sub>2k</sub></td><td>2k</td><td>6θ + 3t - 2k + 1</td><td>4θ + 3t - k + 1</td></tr><tr><td>k = 3, \dots, θ</td><td></td><td></td><td></td></tr><tr><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr></tbody></table>

a gdl for $t\vec{C}_3$ with at most one arc of magnitude $3t-2$, and all other arcs of magnitude strictly smaller than $3t-2$. Define $f(v_i) = f'(v_i) + 3\theta$ for $i = 6\theta + 1, \dots, 6\theta + 3t$. One can easily check that $f$ is a bijection between the vertex set $\{v_1, \dots, v_{6\theta+3t}\}$ and $\{1, \dots, 6\theta + 3t = 3n\}$.

For each $T_i$, we define its *small difference label* (small-dl for short) as the minimum among $|f(v_{3i-1}) - f(v_{3i-2})|$, $|f(v_{3i}) - f(v_{3i-1})|$, and $|f(v_{3i-2}) - f(v_{3i})|$. Similarly, the *big difference label* (big-dl) of $T_i$ is the maximum of these three values, and the *medium one* (medium-dl) is the third value on $T_i$. Table 3 gives the small, medium and big difference labels of $T_1, \dots, T_{2\theta}$. By considering two dummy directed triangles $D_1$ and $D_2$, we have grouped the triangles into $\theta+1$ pairs $\pi_0, \dots, \pi_\theta$, as shown in Table 3. Two triangles belong to the same pair $\pi_i$ if their small difference labels have the same magnitude. The difference labels given for $D_1$ and $D_2$ are artificial, but are helpful for simplifying the proof.

Let $s_i^1$ be the small-dl of the first triangle of $\pi_i$, and let $s_i^2$ be the small-dl of the its second triangle. Define $m_i^1, m_i^2, b_i^1$ and $b_i^2$ in a similar way for the medium and big difference labels of $\pi_i$. For example, $s_2^1 = -(2\theta - 2)$, $s_2^2 = 2\theta - 2$, $m_2^1 = -(4\theta + 3t - 5)$, $m_2^2 = 4\theta + 3t - 7$, $b_2^1 = 6\theta + 3t - 7$, and $b_2^2 = -(6\theta + 3t - 9)$. Note that $s_i^j + m_i^j = -b_i^j$ and $|s_i^j| + |m_i^j| = |b_i^j|$ for all $i = 0, \dots, \theta$ and $j = 1, 2$. The following properties are valid for every $\pi_i$ with $2 \le i \le \theta$:
<table><caption>**Table 3.** The difference labels of the arcs of $T_1, \dots, T_{2\theta}, D_1, D_2$ for case A.</caption><thead><tr><th>Pair</th><th>Triangle</th><th>Small-dl</th><th>Medium-dl</th><th>Big-dl</th></tr></thead><tbody><tr><td rowspan="2">π<sub>0</sub> = (T<sub>1</sub>, T<sub>2</sub>)</td><td>T<sub>1</sub></td><td>2θ</td><td>4θ + 3t - 4</td><td>-(6θ + 3t - 4)</td></tr><tr><td>T<sub>2</sub></td><td>-2θ</td><td>-(4θ + 3t - 2)</td><td>6θ + 3t - 2</td></tr><tr><td rowspan="2">π<sub>1</sub> = (T<sub>3</sub>, T<sub>4</sub>)</td><td>T<sub>3</sub></td><td>-(2θ - 1)</td><td>-(4θ + 3t - 3)</td><td>6θ + 3t - 4</td></tr><tr><td>T<sub>4</sub></td><td>2θ - 1</td><td>4θ + 3t - 5</td><td>-(6θ + 3t - 6)</td></tr><tr><td rowspan="2">π<sub>2</sub> = (D<sub>1</sub>, T<sub>5</sub>)</td><td>D<sub>1</sub></td><td>-(2θ - 2)</td><td>-(4θ + 3t - 5)</td><td>6θ + 3t - 7</td></tr><tr><td>T<sub>5</sub></td><td>2θ - 2</td><td>4θ + 3t - 7</td><td>-(6θ + 3t - 9)</td></tr><tr><td rowspan="3">π<sub>k</sub> = (T<sub>2k</sub>, T<sub>2k+1</sub>)<br/>k = 3, ..., θ - 1</td><td>...</td><td>...</td><td>...</td><td>...</td></tr><tr><td>T<sub>2k</sub></td><td>-(2θ - k)</td><td>-(4θ + 3t - 3k + 1)</td><td>6θ + 3t - 4k + 1</td></tr><tr><td>T<sub>2k+1</sub></td><td>2θ - k</td><td>4θ + 3t - 3k - 1</td><td>-(6θ + 3t - 4k - 1)</td></tr><tr><td>...</td><td>...</td><td>...</td><td>...</td><td>...</td></tr><tr><td rowspan="2">π<sub>θ</sub> = (T<sub>2θ</sub>, D<sub>2</sub>)</td><td>T<sub>2θ</sub></td><td>-θ</td><td>-(θ + 3t + 1)</td><td>2θ + 3t + 1</td></tr><tr><td>D<sub>2</sub></td><td>θ</td><td>θ + 3t - 1</td><td>-(2θ + 3t - 1)</td></tr></tbody></table>

* $s_i^1, m_i^1$ and $b_i^2$ are negative integers, while $s_i^2, m_i^2$ and $b_i^1$ are positive integers;

* $s_i^2 = -s_i^1, m_i^2 = -m_i^1 - 2$, and $b_i^2 = -b_i^1 + 2$;

* if $i < \theta$, then $s_{i+1}^1 = s_i^1 + 1, m_{i+1}^1 = m_i^1 + 3$, and $b_{i+1}^1 = b_i^1 - 4$.

Note that all big difference labels $b_i^j$ have the same parity for $2 \le i \le \theta, j = 1, 2$, while for the medium ones, the parities alternate between successive $\pi_i$ and $\pi_{i+1}$. Moreover, the largest magnitude is $6\theta + 3t - 2 = 3n - 2$, and there is exactly one arc with this magnitude. Since $\theta < 3t + 1$, we have $\theta + 3t + 1 > 2\theta$, which means that no medium-dl can be equal to a small-dl, with the exception of $m_\theta^2$ which can be equal to $2\theta$ or $2\theta - 1$. But we don't care about this exception since $D_2$ (the second triangle of $\pi_\theta$) is a dummy triangle. Notice also that the small difference labels in Table 3 are all distinct, which is also the case for the medium and the big ones. Since all difference labels on $T_{2\theta+1}, \dots, T_{2\theta+t}$ are distinct, we conclude that there are only two possibilities for two arcs $uv$ and $u'v'$ of $n\vec{C}_3$ to have the same difference label $f(v) - f(u) = f(v') - f(u')$:

* One of these arcs belongs to $T_{2\theta+1}, \dots, T_{2\theta+t}$ and the other to $T_1, \dots, T_{2\theta}$;

* Both arcs belong to $T_1, \dots, T_{2\theta}$, one having a big-dl, and the other a medium-dl.

Consider the first case. Remember that there is at most one arc on $T_{2\theta+1}, \dots, T_{2\theta+t}$ with magnitude $3t - 2$, all other arcs having a smaller magnitude. Since at most one arc on $T_1, \dots, T_{2\theta}$ has a magnitude equal to $\theta \ge 3t - 2$, we conclude that such a situation can only occur at most once (with $\theta = 3t - 2$), and we can avoid it by flipping all triangles $T_{2\theta+1}, \dots, T_{2\theta+t}$.

More precisely, by flipping a directed triangle $\vec{C}_3$ with vertex set $\{x, y, z\}$ and arc set $\{xy, yz, zx\}$, we mean exchanging the vertex labels of $y$ and $z$. Hence, the set of difference labels is modified from $\{f(y) - f(x), f(z) - f(y), f(x) - f(z)\}$ to $\{f(z) - f(x), f(y) - f(z), f(x) - f(y)\}$, which means that each difference label of the original set appears with an opposite sign in the modified set, but with the same magnitude.

Consider the second case, and let $i$ and $j$ be such that $b_i^x = m_j^y$ for $x, y$ in $\{1, 2\}$.

Note that $0 \le j < i \le \theta$. We say that $\pi_i$ is conflicting with $\pi_j$ and we write $\pi_i \to \pi_j$. If $\pi_i$ is not conflicting with $\pi_j$, we write $\pi_i \to \pi_j$. Note that

$$ \text{if there are } k < j < i \text{ such that } \pi_i \to \pi_j \to \pi_k, \text{ then } \pi_k \to \pi_\ell \text{ for all } \ell < k. \quad (1) $$

Indeed, if $\pi_i \to \pi_j \to \pi_k$, then there are $x, y, z, w$ in $\{1, 2\}$ such that $b_i^x = m_j^y$ and $b_j^z = m_k^w$. Then:

$$ |b_k^w| = |m_k^w| + |s_k^w| = |b_j^z| + |s_k^w| \ge |b_j^y| + |s_k^w| - 2 = |m_j^y| + |s_j^y| + |s_k^w| - 2 = |b_i^x| + |s_j^y| + |s_k^w| - 2. $$

Since $|b_i^x| \ge 2\theta + 3t + 1, |s_k^w| > |s_j^y| > |s_i^x| \ge \theta$, we have $\min\{|b_i^1|, |b_k^2|\} \ge |b_k^w| - 2 \ge 4\theta + 3t$. Hence, $\pi_k \to \pi_\ell$ for all $\ell < k$ since there is no arc with medium magnitude at least equal to $4\theta + 3t$.

We now show how to avoid conflicting pairs $\pi_i$ and $\pi_j$ with both $i$ and $j$ at least equal to 2. Conflicts involving $\pi_0$ and $\pi_1$ (i.e., $T_1, \dots, T_4$) will be handled later. Consider $i$ and $j$ such that $2 \le j < i < \theta$ and
$\pi_i \to \pi_j$. Since $b_i^1$ and $m_j^2$ are positive, while $b_i^2$ and $m_j^1$ are negative, we either have $b_i^1 = m_j^2$ or $b_i^2 = m_j^1$. In the first case, we say that $\pi_i$ is 12-conflicting with $\pi_j$, while in the second case, we say that $\pi_i$ is 21-conflicting with $\pi_j$. Note that

$$ \text{if } \pi_i \text{ is 12-conflicting with } \pi_j, \text{ then } \pi_{i-1} \text{ is 21-conflicting with } \pi_j \text{ and } \pi_{i+1} \to \pi_j. \quad (2) $$

$$ \text{if } \pi_i \text{ is 21-conflicting with } \pi_j, \text{ then } \pi_{i+1} \text{ is 12-conflicting with } \pi_j \text{ and } \pi_{i-1} \to \pi_j. \quad (3) $$

Indeed, if $\pi_i$ is 12-conflicting with $\pi_j$, then $b_i^1 = m_j^2$, which implies $b_{i-1}^2 = -b_i^1 - 2 = -m_j^2 - 2 = m_j^1$. Since $\max\{|b_{i+1}^1|, |b_{i+1}^2|\} = |b_{i+1}^1| = b_i^1 - 4 < m_j^2 \le \min\{|m_j^1|, |m_j^2|\}$, we have $\pi_{i+1} \to \pi_j$.

Similarly, if $\pi_i$ is 21-conflicting with $\pi_j$, then $b_i^2 = m_j^1$, which implies $b_{i+1}^1 = -b_i^2 - 2 = -m_j^1 - 2 = m_j^2$. Moreover, since $\min\{|b_{i-1}^1|, |b_{i-1}^2|\} = |b_{i-1}^2| = |b_i^2| + 4 > m_j^1 = \max\{|m_j^1|, |m_j^2|\}$, we have $\pi_{i-1} \to \pi_j$. Observe also that:

$$ \text{if } \pi_i \to \pi_j \text{ for } 2 \le j, \text{ then } \pi_k \to \pi_j \text{ for } 2 \le k \ne i, i-1, i+1. \quad (4) $$

Indeed, if $2 \le k < i - 1$, then $\min\{|b_k^1|, |b_k^2|\} \ge \max\{|m_j^1|, |m_j^2|\} + 4$, while for $\theta \ge k > i + 1$, we have $\max\{|b_k^1|, |b_k^2|\} \le \min\{|m_j^1|, |m_j^2|\} - 4$.

In both cases, none of $m_j^1$ and $m_j^2$ can be equal to $b_k^1$ or $b_k^2$. As next property, note that:

$$ \text{if } \pi_i \to \pi_j \text{ for } 2 \le j, \text{ then } \pi_i \to \pi_k \text{ for } 1 \le k \ne j. \quad (5) $$

Indeed, let us first show that $\pi_i \to \pi_{j-1}$. If $j = 2$, then $m_1^1 = m_2^1 - 2 = -m_2^2 - 4$ and $m_1^2 = -m_1^2 = m_2^2 + 2$. Since we have either $b_i^1 = m_2^2$ and $b_i^2 = -m_2^2 + 2$, or $b_i^2 = m_2^1$ and $b_i^1 = -m_2^1 + 2$, we see that $\pi_i \to \pi_1$. For $j > 2$, observe that $b_i^1, b_i^2, m_j^1, m_j^2$ all have the same parity, while $m_{j-1}^1, m_{j-1}^2$ have the opposite parity. Hence $\pi_i \to \pi_{j-1}$.

Similarly, $\pi_i \to \pi_{j+1}$ for all $2 \le j \le \theta - 1$ since the parity of $m_{j+1}^1, m_{j+1}^2$ is the opposite of the parity of $b_i^1, b_i^2$.

Now, let $x, y \in \{1, 2\}$ be such $b_i^x = m_j^y$. If $1 \le k < j - 1$, then $\min\{|m_k^1|, |m_k^2|\} \ge \max\{|b_i^1|, |b_i^2|\} + 2$, while for $\theta \ge k > j + 1$, $\max\{|m_k^1|, |m_k^2|\} \le \min\{|b_i^1|, |b_i^2|\} - 2$.

In both cases, none of $m_k^1$ and $m_k^2$ can be equal to $b_i^1$ or $b_i^2$, which proves that $\pi_i \to \pi_k$ for $k \ge 1, k \ne j - 1, j, j + 1$.

In what follows, we will remove conflicts by flipping some triangles. More precisely, by flipping $\pi_i$, we mean flipping both triangles in $\pi_i$. Note that:

$$ \text{if } \pi_i \to \pi_j \text{ for } j \ge 2, \text{ then } \pi_i \to \pi_k \text{ for all } k \ge 2 \text{ after the flip of } \pi_i. \quad (6) $$

Indeed, if $\pi_i$ is 12-conflicting with $\pi_j$, then $b_i^1 = m_j^2$, and there is no triangle with medium-dl equal to $-b_i^1 = -m_j^2 = -b_i^2 = -2 = m_j^2 - 2$. Similarly, if $\pi_i$ is 21-conflicting with $\pi_j$, then $b_i^2 = m_j^1$, and there is no triangle with medium-dl equal to $-b_i^1 = -b_i^2 + 2 = -m_j^1 + 2$ or $-b_i^2 = -m_j^1$. Hence, we have $\pi_i \to \pi_k$ for all $k \ge 2$ after the flip of $\pi_i$. Also,

$$ \text{if } \pi_i \to \pi_j \text{ for } j \ge 2, \text{ then } \pi_k \to \pi_j \text{ for all } k \le \theta \text{ after the flip of } \pi_j. \quad (7) $$

Indeed, if $\pi_i$ is 12-conflicting with $\pi_j$, then $b_i^1 = m_j^2$, $b_{i-1}^2 = m_j^1$, and there is no triangle with a big-dl equal to $-m_j^1 = -b_{i-1}^2$ or $-m_j^2 = -b_i^1$. Similarly, if $\pi_i$ is 21-conflicting with $\pi_j$, then $b_i^2 = m_j^1$, $b_{i+1}^1 = m_j^2$, and there is no triangle with a big-dl equal to $-m_j^1 = -b_i^2$ or $-m_j^2 = -b_{i+1}^1$. Hence, we have $\pi_k \to \pi_j$ for all $k \le \theta$ after the flip of $\pi_j$.

Now, let $J$ be the set of integers $j$ such that $\pi_i \to \pi_j \to \pi_k$ for at least one pair $i, k$ of integers with $2 \le k < j < i \le \theta$. Also, let $j' \in J$ be the set of integers $j'$ such that there is $k \ge 2$ and $j \ne j'$ in $J$ with $\pi_j \to \pi_k$ and $\pi_{j'} \to \pi_k$. Note that $J \cap J' = \emptyset$. Indeed, consider $j' \in J'$, and $j \ne j'$ in $J$ such that $\pi_j \to \pi_k$ and $\pi_{j'} \to \pi_k$. It follows from (2), (3) and (4) that $j' = j - 1$ or $j' = j + 1$. Since $j \in J$, $m_j^1$ and $m_j^2$ have the same parity as the big difference labels on $T_5, \dots, T_{2\theta}$, which means that $m_j^1$ and $m_j^2$ have the opposite parity. Hence, there is no $i$ with $\pi_i \to \pi_{j'}$, which proves that $j' \notin J$.
By flipping all $\pi_\ell$ with $\ell \in J \cup J'$, we get $\pi_i \leftrightarrow \pi_j$ for all $2 \le j < i \le \theta$ with $i$ or $j$ in $J \cup J'$. Indeed, it follows from (1) that we cannot have $\pi_i \to \pi_j$ with both $i$ and $j$ in $J \cup J'$, since this would imply the existence of $k, k'$ with $2 \le k < k' \le \theta$ and $\pi_{k'} \to \pi_i \to \pi_j \to \pi_k$. Hence, it follows from (6) and (7) that $\pi_i \leftrightarrow \pi_j$ for $i$ or $j$ in $J, 2 \le j < i \le \theta$. Moreover, as observed above, $j' \in J'$ implies that $m_j^1$ and $m_j^2$ do not have the same parity as the big difference values on $T_5, \dots, T_{2\theta}$. Hence, it follows from (6) that $\pi_i \leftrightarrow \pi_j$ for $i$ or $j$ in $J', 2 \le j < i \le \theta$.

So, after the flipping of all $\pi_\ell$ with $\ell \in J \cup J'$, the remaining conflicts $\pi_i \to \pi_j$ with $2 \le j < i \le \theta$ are such that $\{i, j\} \cap (J \cup J') = \emptyset$. Consider any such conflict. If there is $i' \neq i$ such that $\pi_{i'} \to \pi_j$, then we know from (4) that $i' = i - 1$ or $i + 1$. Without loss of generality, we may assume $i' = i + 1$ (else we permute the roles of $i$ and $i'$). Since none of $j, i, i'$ belongs to $J \cup J'$, there is no $k$ such that $\pi_k \to \pi_i, \pi_k \to \pi_{i'}$ or $\pi_j \to \pi_k$. Also, it follows from (4) that there is no $k \neq i, i'$ such that $\pi_k \to \pi_j$

* if $i \le 2\theta/3$, we flip $\pi_j$. We then have $\min\{|b_i^1|, |b_i^2|\} \ge 6\theta + 3t - 4(2\theta/3) - 1 = 10\theta/3 + 3t - 1$. It follows that $j \le 2\theta/9$ else $\max\{|m_j^1|, |m_j^2|\} \le 4\theta + 3t - 3(2\theta)/9 - 2 = 10\theta/3 + 3t - 2$. Hence $\min\{|b_j^1|, |b_j^2|\} \ge 6\theta + 3t - 4(2\theta/9) - 1 = 46\theta/9 + 3t - 1 > 4\theta + 3t - 2$. Since the medium magnitudes are at most equal to $4\theta + 3t - 2$, we cannot have $\pi_j \to \pi_k$ after the flip of $\pi_j$. Also, it follows from (7) that, after the flip of $\pi_j$, we have $\pi_k \leftrightarrow \pi_j$ for $j < k \le \theta$. Hence, after the flip of $\pi_j$, the difference labels on its two triangles are different from those on the other triangles $T_k, k \ge 5$.

* If $i > 2\theta/3$, we flip $\pi_i$ and $\pi_{i'}$ (if any). In this case, we have $\max\{|m_i^1|, |m_i^2|\} < \max\{|m_i^1|, |m_i^2|\} \le 4\theta + 3t - 3(2\theta/3) = 2\theta + 3t$. Since all big magnitudes on $T_1, \dots, T_{2\theta}$ are strictly larger than $2\theta + 3t$, we cannot have $\pi_k \to \pi_i$ after the flip of $\pi_i$ and $\pi_{i'}$. Also, it follows from (6) that after the flip of $\pi_i$ and $\pi_{i'}$, we have $\pi_i \leftrightarrow \pi_k$ and $\pi_{i'} \leftrightarrow \pi_k$ for $2 \le k < i$. Hence, after the flip of $\pi_i$ and $\pi_{i'}$, the difference labels on their triangles are different from those on the other triangles $T_k, k \ge 5$.

After all these flips, there is no $\pi_i \to \pi_j$ with $2 \le j < i \le \theta$. We consider now triangles $T_1, T_2, T_3, T_4$ involved in $\pi_0$ and $\pi_1$. If there is $j \ge 2$ such that $\pi_j \to \pi_1$ then we know from (5) that $\pi_j \leftrightarrow \pi_k$ for all $2 \le k < j$. Hence, $j \notin J \cup J'$. If, before the flips, there was $i$ such that $\pi_i \to \pi_j$, then $i > 2\theta/3$. Indeed, we have seen above that if $i \le 2\theta/3$, then $\min\{|b_j^1|, |b_j^2|\} > 4\theta + 3t - 2$, which means that $\pi_j \leftrightarrow \pi_1$. So, $\pi_j$ was not flipped, and by flipping $\pi_1$, we get $\pi_j \leftrightarrow \pi_1$ for all $2 \le j \le \theta$.

Since the parity of $m_1^0$ and $m_2^0$ is the opposite of the parity of $b_1^1$ and $b_1^2$ for all $i \ge 2$, we have $\pi_j \leftrightarrow \pi_0$ for all $2 \le j \le \theta$. Hence, the only possible remaining conflict is between $\pi_0$ and $\pi_1$. This can only occur if $b_1^0 = b_1^1$ and $\pi_1$ was flipped. In such a case, we flip $\pi_0$ to remove this last conflict.

**Case B: $n = 2\theta + t, \theta = 3t + 1$**

We treat this case as the previous one. More precisely, the vertex labels $f(v_i)$ on $T_1, \dots, T_{2\theta}$ are given in Table 4. Given a gdl $f'$ for $t\bar{C}_3$ with at most one arc of magnitude $3t - 2$, and all other arcs of magnitude strictly smaller than $3t - 2$, we set $f(v_i) = f'(v_i) + 3\theta$ for $i = 6\theta + 1, \dots, 6\theta + 3t$. Again, one can easily check that $f$ is a bijection between $\{v_1, \dots, v_{6\theta+3t}\}$ and $\{1, \dots, 6\theta + 3t = 3n\}$.

<table><caption>**Table 4.** The labeling of $T_1, \dots, T_{2\theta}$ for case B.</caption><thead><tr><th>Triangle T<sub>i</sub></th><th>f(v<sub>3i-2</sub>)</th><th>f(v<sub>3i-1</sub>)</th><th>f(v<sub>3i</sub>)</th></tr></thead><tbody><tr><td>T<sub>1</sub></td><td>1</td><td>2θ + 1</td><td>6θ + 3t - 3</td></tr><tr><td>T<sub>2</sub></td><td>2</td><td>6θ + 3t</td><td>4θ + 3t</td></tr><tr><td>T<sub>3</sub></td><td>3</td><td>6θ + 3t - 1</td><td>2θ + 2</td></tr><tr><td>T<sub>4</sub></td><td>4</td><td>4θ + 3t - 1</td><td>6θ + 3t - 2</td></tr><tr><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr><tr><td>T<sub>2k-1</sub></td><td>2k - 1</td><td>2θ + k</td><td>6θ + 3t - 2k + 2</td></tr><tr><td>T<sub>2k</sub></td><td>2k</td><td>6θ + 3t - 2k + 1</td><td>4θ + 3t - k + 1</td></tr><tr><td>k = 3, ..., θ - 1</td><td></td><td></td><td></td></tr><tr><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr><tr><td>T<sub>2θ-1</sub></td><td>2θ - 1</td><td>3θ + 3t - 1</td><td>4θ + 3t - 1</td></tr><tr><td>T<sub>2θ</sub></td><td>2θ</td><td>4θ + 3t + 2</td><td>3θ</td></tr></tbody></table>

The small, medium, and big difference labels for triangles $T_1, \dots, T_{2\theta}$ are given in Table 5. Again, the triangles are grouped in pairs, using two dummy triangles $D_1$ and $D_2$ which are paired with $T_5$ and $T_{2\theta-2}$,
respectively. Notice that for every uv on a $T_i$ with $i \le 2\theta$ and every $u'v'$ on a $T_j$ with $j > 2\theta$, we have $f(v) - f(u) \ne f(v') - f(u')$ since the smallest possible magnitude for uv is $\theta = 3t + 1$, while the largest possible magnitude for $u'v'$ is $3t - 2$. Hence, in this case, we do not have to flip triangles $T_{2\theta+1}, \dots, T_{2\theta+t}$. Note also that the largest magnitude is $6\theta + 3t - 2 = 3n - 2$, and there is exactly one arc with this magnitude.

<table><caption>**Table 5.** The difference labels of the arcs of $T_1, \dots, T_{2\theta}, D_1, D_2$ for case B.</caption><thead><tr><th>Pair</th><th>Triangle</th><th>Small-dl</th><th>Medium-dl</th><th>Big-dl</th></tr></thead><tbody><tr><td rowspan="2">π<sub>0</sub> = (T<sub>1</sub>, T<sub>2</sub>)</td><td>T<sub>1</sub></td><td>2θ</td><td>4θ + 3t - 4</td><td>-(6θ + 3t - 4)</td></tr><tr><td>T<sub>2</sub></td><td>-2θ</td><td>-(4θ + 3t - 2)</td><td>6θ + 3t - 2</td></tr><tr><td rowspan="2">π<sub>1</sub> = (T<sub>3</sub>, T<sub>4</sub>)</td><td>T<sub>3</sub></td><td>-(2θ - 1)</td><td>-(4θ + 3t - 3)</td><td>-6θ + 3t - 4</td></tr><tr><td>T<sub>4</sub></td><td>2θ - 1</td><td>4θ + 3t - 5</td><td>-(6θ + 3t - 6)</td></tr><tr><td rowspan="2">π<sub>2</sub> = (D<sub>1</sub>, T<sub>5</sub>)</td><td>D<sub>1</sub></td><td>-(2θ - 2)</td><td>-(4θ + 3t - 5)</td><td>6θ + 3t - 7</td></tr><tr><td>T<sub>5</sub></td><td>2θ - 2</td><td>4θ + 3t - 7</td><td>-(6θ + 3t - 9)</td></tr><tr><td rowspan="3">π<sub>k</sub> = (T<sub>2k</sub>, T<sub>2k+1</sub>)<br/>k = 3, ..., θ - 2</td><td>...</td><td>...</td><td>...</td><td>...</td></tr><tr><td>T<sub>2k</sub></td><td>-(2θ - k)</td><td>-(4θ + 3t - 3k + 1)</td><td>6θ + 3t - 4k + 1</td></tr><tr><td>T<sub>2k+1</sub></td><td>2θ - k</td><td>4θ + 3t - 3k - 1</td><td>-(6θ + 3t - 4k - 1)</td></tr><tr><td>...</td><td>...</td><td>...</td><td>...</td><td>...</td></tr><tr><td rowspan="2">π<sub>θ-1</sub> = (T<sub>2θ-2</sub>, D<sub>2</sub>)</td><td>T<sub>2θ-1</sub></td><td>-(θ + 1)</td><td>-(θ + 3t + 4)</td><td>2θ + 3t + 5</td></tr><tr><td>D<sub>2</sub></td><td>θ + 1</td><td>θ + 3t + 2</td><td>-(2θ + 3t + 3)</td></tr><tr><td rowspan="2">π<sub>θ</sub> = (T<sub>2θ-1</sub>, T<sub>2θ</sub>)</td><td>T<sub>2θ-1</sub></td><td>-θ</td><td>-θ + 3t + 2</td><td>-(2θ + 3t + 2)</td></tr><tr><td>T<sub>2θ</sub></td><td>-θ</td><td>-(θ + 3t + 2)</td><td>2θ + 3t + 2</td></tr></tbody></table>

Since $\theta = 3t + 1$, we have $\theta + 3t + 2 = 2\theta + 1$, which means that no medium-dl can be equal to a small-dl. The small, medium and big difference labels on $T_1, \dots, T_{2\theta-2}$ are exactly the same as those of Table 3. Using the same arguments, as in the previous case, we can avoid conflicts involving medium and big difference labels of $\pi_0, \dots, \pi_{\theta-1}$. Consider now $\pi_\theta$:

* The medium difference values of $\pi_\theta$ can only be conflicting with the medium-dl of $D_2$, but we don't care about such a conflict since $D_2$ is a dummy triangle;

* The big difference values of $\pi_\theta$ can only be conflicting with the medium-dl of a $T_k$. For this to happen, we should have $2\theta + 3t + 2$ equal to $4\theta + 3t - 3k + 1$ or $4\theta + 3t - 3k - 1$, or equivalently $k$ equal to $\frac{2\theta-1}{3} = \frac{6t+1}{3}$ or $\frac{2\theta-3}{3} = \frac{6t-1}{3}$, which is impossible since $k$ is an integer.

**Case C:** $n = 2\theta + t - 1, \theta \in \{3t - 1, 3t\}$

Again, consider the vertex labels $f(v_i)$ on $T_1, \dots, T_{2\theta-1}$ shown in Table 6. Given a gdl $f'$ for $t\vec{C}_3$ with at most one arc of magnitude $3t - 2$, and all other arcs of magnitude strictly smaller than $3t - 2$, we set $f(v_i) = f'(v_i) + 3\theta - 1$ for $i = 6\theta - 2, \dots, 6\theta + 3t - 3$. One can easily check $f$ is a bijection between $\{v_1, \dots, v_{6\theta+3t-3}\}$ and $\{1, \dots, 6\theta + 3t - 3 = 3n\}$. The small, medium, and big difference labels for triangles $T_1, \dots, T_{2\theta}$ are given in Table 7.

<table><caption>**Table 6.** The labeling of $T_1, \dots, T_{2\theta-1}$ for case C.</caption><thead><tr><th>Triangle T<sub>i</sub></th><th>f(v<sub>3i-2</sub>)</th><th>f(v<sub>3i-1</sub>)</th><th>f(v<sub>3i</sub>)</th></tr></thead><tbody><tr><td>T<sub>1</sub></td><td>1</td><td>2θ</td><td>6θ + 3t - 6</td></tr><tr><td>T<sub>2</sub></td><td>2</td><td>6θ + 3t - 3</td><td>4θ + 3t - 2</td></tr><tr><td>T<sub>3</sub></td><td>3</td><td>6θ + 3t - 4</td><td>2θ + 1</td></tr><tr><td>T<sub>4</sub></td><td>4</td><td>4θ + 3t - 3</td><td>6θ + 3t - 5</td></tr><tr><td>T<sub>5</sub></td><td>5</td><td>2θ + 2</td><td>6θ + 3t - 7</td></tr><tr><td>...</td><td>...</td><td>...</td><td>...</td></tr><tr><td>T<sub>2k</sub></td><td>2k</td><td>6θ + 3t - 2k - 2</td><td>4θ + 3t - k - 1</td></tr><tr><td>T<sub>2k+1</sub></td><td>2k + 1</td><td>2θ + k</td><td>6θ + 3t - 2k - 3</td></tr><tr><td>k = 3, ..., θ - 1</td><td></td><td></td><td></td></tr><tr><td>...</td><td>...</td><td>...</td><td>...</td></tr></tbody></table>
<table><caption>**Table 7.** The difference labels of the arcs of $T_1, \dots, T_{2\theta-1}, D_1$ for case C.</caption><thead><tr><th>Pair</th><th>Triangle</th><th>Small-dl</th><th>Medium-dl</th><th>Big-dl</th></tr></thead><tbody><tr><td rowspan="2">π<sub>0</sub> = (T<sub>1</sub>, T<sub>2</sub>)</td><td>T<sub>1</sub></td><td>2θ - 1</td><td>4θ + 3t - 6</td><td>-(6θ + 3t - 7)</td></tr><tr><td>T<sub>2</sub></td><td>-(2θ - 1)</td><td>-(4θ + 3t - 4)</td><td>6θ + 3t - 5</td></tr><tr><td rowspan="2">π<sub>1</sub> = (T<sub>3</sub>, T<sub>4</sub>)</td><td>T<sub>3</sub></td><td>-(2θ - 2)</td><td>-(4θ + 3t - 5)</td><td>6θ + 3t - 7</td></tr><tr><td>T<sub>4</sub></td><td>2θ - 2</td><td>4θ + 3t - 7</td><td>-(6θ + 3t - 9)</td></tr><tr><td rowspan="2">π<sub>2</sub> = (D<sub>1</sub>, T<sub>5</sub>)</td><td>D<sub>1</sub></td><td>-(2θ - 3)</td><td>-(4θ + 3t - 7)</td><td>6θ + 3t - 10</td></tr><tr><td>T<sub>5</sub></td><td>2θ - 3</td><td>4θ + 3t - 9</td><td>-(6θ + 3t - 12)</td></tr><tr><td rowspan="3">π<sub>k</sub> = (T<sub>2k</sub>, T<sub>2k+1</sub>)<br/>k = 3, ..., θ - 1</td><td>...</td><td>...</td><td>...</td><td>...</td></tr><tr><td>T<sub>2k</sub></td><td>-(2θ - k - 1)</td><td>-(4θ + 3t - 3k - 1)</td><td>6θ + 3t - 4k - 2</td></tr><tr><td>T<sub>2k+1</sub></td><td>2θ - k - 1</td><td>4θ + 3t - 3k - 3</td><td>-(6θ + 3t - 4k - 4)</td></tr><tr><td>...</td><td>...</td><td>...</td><td>...</td><td>...</td></tr></tbody></table>

Again, the triangles are grouped in pairs, using one dummy triangle $D_1$ which is paired with $T_5$. Notice that for every uv on a $T_i$ with $i \le 2\theta - 1$ and every $u'v'$ on a $T_j$ with $j > 2\theta - 1$, we have $f(v) - f(u) \ne f(v') - f(u')$ since the smallest possible magnitude for uv is $\theta \ge 3t - 1$, while the largest possible magnitude for $u'v'$ is $3t - 2$. Hence, also in this case, we do not have to flip $T_{2\theta+1}, \dots, T_{2\theta+t}$. Note also that the largest magnitude is $6\theta + 3t - 5 = 3n - 2$, and there is exactly one arc with this magnitude.

Since $\theta < 3t + 1$, we have $\theta + 3t > 2\theta - 1$, which means that no medium-dl can be equal to a small-dl. Using the same arguments, as in the previous cases, we can avoid conflicts involving $\pi_2, \dots, \pi_{\theta-1}$.

If there is $j \ge 2$ such that $\pi_j \to \pi_0$, then assume there is $i > j$ such that $\pi_i \to \pi_j$. If $i \le 2\theta/3$, then $\min\{|b_i^1|, |b_i^2|\} \ge 6\theta + 3t - 4(2\theta/3) - 4 = 10\theta/3 + 3t - 4$. It follows that $j \le (2\theta + 3)/9$ else $\max\{|m_j^1|, |m_j^2|\} \le 4\theta + 3t - 3(2\theta + 3)/9 - 4 = 10\theta/3 + 3t - 5$. Hence $\min\{|b_j^1|, |b_j^2|\} \ge 6\theta + 3t - 4(2\theta + 3)/9 - 4 = 46\theta/9 + 3t - 48/9 > 4\theta + 3t - 4$, which contradicts $\pi_j \to \pi_0$. Hence, we necessarily have $i > 2\theta/3$, and since $j$ cannot belong to $J \cup J'$, we conclude that $j$ was not flipped. Hence, by flipping $\pi_0$, we get $\pi_j \to \pi_0$ for all $j \ge 2$.

Since the parity of $m_1^1$ and $m_1^2$ is the opposite of the parity of $b_1^1$ and $b_1^2$ for all $i \ge 2$, we have $\pi_j \to \pi_1$ for all $j \ge 2$. Hence, the only possible remaining conflict is between $\pi_0$ and $\pi_1$. This can only occur if $b_0^1 = b_1^1$ and $\pi_1$ was flipped. In such a case, we flip $\pi_1$ to remove this last conflict.

**Case D:** $n = 2\theta + t - 1, \theta = 3t + 1$

Consider the vertex labels $f(v_i)$ on $T_1, \dots, T_{2\theta-1}$ shown in Table 8. Given a gdl $f'$ for $t\vec{C}_3$ with at most one arc of magnitude $3t - 2$, and all other arcs of magnitude strictly smaller than $3t - 2$, we set $f(v_i) = f'(v_i) + 3\theta - 1$ for $i = 6\theta - 2, \dots, 6\theta + 3t - 3$. One can easily check $f$ is a bijection between $\{v_1, \dots, v_{6\theta+3t-3}\}$ and $\{1, \dots, 6\theta + 3t - 3 = 3n\}$.

The small, medium, and big difference labels for triangles $T_1, \dots, T_{2\theta}$ are given in Table ?? . Again, the triangles are grouped in pairs, using one dummy triangle $D_1$ which is paired with $T_5$. Notice that for every uv on a $T_i$ with $i \le 2\theta - 1$ and every $u'v'$ on a $T_j$ with $j > 2\theta - 1$, we have $f(v) - f(u) \ne f(v') - f(u')$ since the smallest possible magnitude for uv is $\theta - 2 = 3t - 1$, while the largest possible magnitude for $u'v'$ is $3t - 2$. Hence, also in this case, we do not have to flip $T_{2\theta+1}, \dots, T_{2\theta+t}$. Note also that the largest magnitude is $6\theta + 3t - 5 = 3n - 2$, and there is only one arc with this magnitude.

Since $\theta = 3t + 1$, we have $\theta + 3t + 1 = 2\theta$, which means that no medium-dl can be equal to a small-dl. The small, medium and big difference labels on $T_1, \dots, T_{2\theta-5}$ are exactly the same as those of Table 7. Using the same arguments, as in the previous case, we can avoid conflicts involving $\pi_0, \dots, \pi_{\theta-3}$.

Consider now $\pi_{\theta-2}$ and $\pi_{\theta-1}$. The medium magnitudes $|m_{\theta-2}^1|, |m_{\theta-2}^2|, |m_{\theta-1}^1|$ and $|m_{\theta-1}^2|$ do not appear on any other triangle. Also, the medium magnitudes on a $\pi_k$ with $2 \le k \le \theta - 3$ are equal to $4\theta + 3t - 3k - 1 = 15t - 3k + 3$ or $4\theta + 3t - 3k - 3 = 15t - 3k + 1$, which mean that they are all equal to 0, or 1 mod 3. Hence, the big magnitudes $|b_{\theta-2}^2| = |b_{\theta-1}^2| = 2\theta + 3t + 3 = 9t + 5$ do not appear on any other triangle as medium magnitude. Therefore, these two big magnitudes will not be conflicting if we either flip both $\pi_{\theta-1}$ and $\pi_{\theta-2}$, or none of them. The only remaining possible conflicts involve a medium-dl on a $T_i$ ($i < \theta - 2$) and $b_{\theta-2}^1$ or $b_{\theta-1}^1$.
<table><caption>**Table 8.** The labeling of $T_1, \dots, T_{2\theta-1}$ for case D.</caption><thead><tr><th>Triangle T<sub>i</sub></th><th>f(v<sub>3i-2</sub>)</th><th>f(v<sub>3i-1</sub>)</th><th>f(v<sub>3i</sub>)</th></tr></thead><tbody><tr><td>T<sub>1</sub></td><td>1</td><td>2θ</td><td>6θ + 3t - 6</td></tr><tr><td>T<sub>2</sub></td><td>2</td><td>6θ + 3t - 3</td><td>4θ + 3t - 2</td></tr><tr><td>T<sub>3</sub></td><td>3</td><td>6θ + 3t - 4</td><td>2θ + 1</td></tr><tr><td>T<sub>4</sub></td><td>4</td><td>4θ + 3t - 3</td><td>6θ + 3t - 5</td></tr><tr><td>T<sub>5</sub></td><td>5</td><td>2θ + 2</td><td>6θ + 3t - 7</td></tr><tr><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr><tr><td>T<sub>2k</sub></td><td>2k</td><td>6θ + 3t - 2k - 2</td><td>4θ + 3t - k - 1</td></tr><tr><td>T<sub>2k+1</sub><br>k = 3, ..., θ - 3</td><td>2k + 1</td><td>2θ + k</td><td>6θ + 3t - 2k - 3</td></tr><tr><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr><tr><td>T&#773;<sub>2θ-4</sub></td><td>2θ - 4</td><td>4θ + 3t - 1</td><td>3θ + 3t + 1</td></tr><tr><td>T<sub>2θ-3</sub></td><td>2θ - 3</td><td>4θ + 3t + 2</td><td>3θ - 2</td></tr><tr><td>T<sub>2θ-2</sub></td><td>2θ - 2</td><td>3θ + 3t</td><td>4θ + 3t + 1</td></tr><tr><td>T<sub>2θ-1</sub></td><td>2θ - 1</td><td>3θ - 1</td><td>4θ + 3t</td></tr></tbody></table>

<table><caption>**Table 9.** The difference labels of the arcs of $T_1, \dots, T_{2\theta-1}, D_1$ for case D.</caption><thead><tr><th>Pair</th><th>Triangle</th><th>Small-dl</th><th>Medium-dl</th><th>Big-dl</th></tr></thead><tbody><tr><td rowspan="2">π<sub>0</sub> = (T<sub>1</sub>, T<sub>2</sub>)</td><td>T<sub>1</sub></td><td>2θ - 1</td><td>4θ + 3t - 6</td><td>-(6θ + 3t - 7)</td></tr><tr><td>T<sub>2</sub></td><td>-(2θ - 1)</td><td>-(4θ + 3t - 4)</td><td>6θ + 3t - 5</td></tr><tr><td rowspan="2">π<sub>1</sub> = (T<sub>3</sub>, T<sub>4</sub>)</td><td>T&#773;<sub>3</sub></td><td>-(2θ - 2)</td><td>-(4θ + 3t - 5)</td><td>-6θ + 3t - 7</td></tr><tr><td>T<sub>4</sub></td><td>2θ - 2</td><td>4θ + 3t - 7</td><td>-(6θ + 3t - 9)</td></tr><tr><td rowspan="2">π<sub>2</sub> = (D<sub>1</sub>, T<sub>5</sub>)</td><td>D&#773;<sub>1</sub></td><td>-(2θ - 3)</td><td>-(4θ + 3t - 7)</td><td>6θ + 3t - 10</td></tr><tr><td>T<sub>5</sub></td><td>2θ - 3</td><td>4θ + 3t - 9</td><td>-(6θ + 3t - 12)</td></tr><tr><td rowspan="3">π<sub>k</sub> = (T<sub>2k</sub>, T<sub>2k+1</sub>)<br>k = 3, ..., θ - 3</td><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr><tr><td>T<sub>2k</sub></td><td>-(2θ - k - 1)</td><td>-(4θ + 3t - 3k - 1)</td><td>6θ + 3t - 4k - 2</td></tr><tr><td>T<sub>2k+1</sub></td><td>2θ - k - 1</td><td>4θ + 3t - 3k - 3</td><td>-(6θ + 3t - 4k - 4)</td></tr><tr><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td><td>⋮</td></tr><tr><td rowspan="2">π<sub>θ-2</sub> = (T<sub>2θ-3</sub>, T<sub>2θ-2</sub>)</td><td>T&#773;<sub>2θ-3</sub></td><td>-(θ + 1)</td><td>-(θ + 3t + 4)</td><td>2θ + 3t + 5</td></tr><tr><td>T<sub>2θ-2</sub></td><td>θ + 1</td><td>θ + 3t + 2</td><td>-(2θ + 3t + 3)</td></tr><tr><td rowspan="2">π<sub>θ-1</sub> = (T<sub>2θ-1</sub>, T<sub>2θ-4</sub>)</td><td>T&#773;<sub>2θ-1</sub></td><td>θ</td><td>θ + 3t + 1</td><td>-(2θ + 3t + 1)</td></tr><tr><td>T<sub>2θ-4</sub></td><td>-(θ - 2)</td><td>-(θ + 3t + 5)</td><td>2θ + 3t + 3</td></tr></tbody></table>

Assume there is a triangle $T_i$ with magnitude $2\theta + 3t + 1 = |b_{\theta-1}^1|$. This means that $2\theta + 3t + 1 \le 4\theta + 3t - 3i - 1$, which is equivalent to $i \le (2\theta - 2)/3$. Hence, $\pi_i$ was not flipped. Also, if there is a triangle $T_j$ with magnitude $2\theta + 3t + 5 = b_{\theta-2}^1$, then $j < i \le (2\theta - 2)/3$, which means that $\pi_j$ was not flipped. Now,

* If there is a triangle $T_i$ with medium-dl $-(2\theta + 3t + 1)$, then $m_i^1 = b_{\theta-1}^1$, and $m_{i-2}^2 = -b_{\theta-1}^1 + 4 = 2\theta + 3t + 5 = b_{\theta-2}^1$, and we can avoid both conflicts by flipping both $\pi_{\theta-1}$ and $\pi_{\theta-2}$;

* If there is a triangle $T_j$ with medium-dl $2\theta + 3t + 5$, then $m_j^2 = b_{\theta-2}^1$, and $m_{j+2}^1 = -b_{\theta-2}^1 + 4 = -(2\theta + 3t + 1) = b_{\theta-1}^1$, and we can avoid both conflicts by flipping both $\pi_{\theta-1}$ and $\pi_{\theta-2}$.

* If there is no triangle with medium-dl $-(2\theta + 3t + 1)$ or $2\theta + 3t + 5$, there is no conflict.

□

We already know from Lemma 5 that $\vec{C}_4 + \vec{C}_3$ has a gdl. We now show that this is also the case for $\vec{C}_4 + n\vec{C}_3$, $n \ge 2$.

**Lemma 8.** $\vec{C}_4 + n\vec{C}_3$ has a gdl for every $n \ge 1$.

**Proof.** The graphs in Figures 9, 10, 11, 12, 13, 14 and 15 show the existence of the desired gdl for $2 \le n \le 8$.
<figure><img src="image_11.png" /><figcaption>Figure 9. $2\vec{C}_3 + \vec{C}_4$.</figcaption></figure>

<figure><img src="image_12.png" /><figcaption>Figure 10. $3\vec{C}_3 + \vec{C}_4$.</figcaption></figure>

<figure><img src="image_13.png" /><figcaption>Figure 11. $4\vec{C}_3 + \vec{C}_4$.</figcaption></figure>

<figure><img src="image_14.png" /><figcaption>Figure 12. $5\vec{C}_3 + \vec{C}_4$.</figcaption></figure>
<figure><img src="image_15.png" /></figure>

<figure><img src="image_16.png" /></figure>

<figure><img src="image_17.png" /></figure>

For $n \ge 9$, we know from Lemma 7 that there is a gdl for $(n+1)\vec{C}_3$, which can be obtained by performing a set $F$ of flips, starting from the labelling $f$ defined in Tables 2, 4, 6, and 8 for cases A, B, C and D, respectively. We distinguish two cases.

* For cases A and B, we consider the graph $G$ obtained from $(n+1)\vec{C}_3$ by inserting a new vertex $v_0$ between $v_5$ and $v_6$. More precisely, $G$ is obtained by replacing $T_2$ in $(n+1)\vec{C}_3$ by a $\vec{C}_4$ with vertex set $\{v_0, v_4, v_5, v_6\}$
and arc set {$v_4v_5, v_5v_0, v_0v_6, v_6v_4$}. We then define $f'$ by setting $f'(v_0) = 1$ and $f'(v_i) = f(v_i) + 1$ for $i = 1, \dots, 3(n+1)$. Clearly, $f'$ is bijection between {$v_0, \dots, v_{3(n+1)}$} and {$1, \dots, 3n + 4$}. In order to prove that by performing exactly the same set $F$ of flips, we get a gdl for $G$, it is sufficient to show that the difference labels on $v_5v_0$ and $v_0v_6$ cannot appear on other arcs of $G$.

- $|f'(v_0) - f'(v_5)| = |1 - (6\theta + 3t + 1)| = 6\theta + 3t$, which means that $v_5v_0$ has a magnitude larger than that of any other arc in $G$.

- $f'(v_6) - f'(v_0) = (4\theta + 3t + 1) - 1 = 4\theta + 3t$. Since this value is strictly larger than any other medium magnitude in $G$, the difference label on $v_0v_6$ can only be conflicting with a big-dl on a $T_i$ with $i \ge 5$. But this does not occur since these big difference labels have the opposite parity of $4\theta + 3t$.

* For cases C and D, we consider the graph $G$ obtained from $(n+1)\overrightarrow{\mathbf{C}}_3$ by inserting a new vertex $v_0$ between $v_9$ and $v_7$. More precisely, $G$ is obtained by replacing $T_3$ in $(n+1)\overrightarrow{\mathbf{C}}_3$ by a $\overrightarrow{\mathbf{C}}_4$ with vertex set $\{v_0, v_7, v_8, v_9\}$ and arc set $\{v_7v_8, v_8v_9, v_9v_0, v_0v_7\}$. We then define $f'$ by setting $f'(v_0) = 3n + 4 = 6\theta + 3t - 2$ and $f'(v_i) = f(v_i)$ for $i = 1, \dots, 3(n+1)$. Clearly, $f'$ is bijection between $\{v_0, \dots, v_{3(n+1)}\}$ and $\{1, \dots, 3n + 4\}$. In order to prove that by performing exactly the same set $F$ of flips, we get a gdl for $G$, it is sufficient to show that the difference labels on $v_0v_7$ and $v_9v_0$ do not appear on other arcs of $G$.

- $f'(v_7) - f'(v_0) = 3 - (6\theta + 3t - 2) = -(6\theta + 3t - 5)$. The same difference label appears on $T_2$ but with an opposite sign. These two arcs could be conflicting if exactly one of $\pi_0$ and $\pi_1$ is flipped, but this does not occur since $T_1$ and $T_3$ have big difference labels of the same magnitude, but with opposite signs.

- $f'(v_0) - f'(v_9) = (6\theta + 3t - 2) - (2\theta + 1) = 4\theta + 3t - 3$. Since this value is strictly larger than any other medium magnitude in $G$, the difference label on $v_9v_0$ can only be conflicting with a big-dl on a $T_i$ with $i \ge 5$. But this does not occur since these big difference labels have the opposite parity of $4\theta + 3t - 3$.

□

All together, the results shown in the eight lemmas of this section can be summarized as follows.

**Theorem 1.** If $G$ is the disjoint union of circuits, among which at most one has an odd length, or all circuits of odd length have 3 vertices, then $G$ has a gdl, unless $G = \overrightarrow{\mathbf{C}}_3$ or $G = \overrightarrow{\mathbf{C}}_2 + \overrightarrow{\mathbf{C}}_3$.

## 3 Conclusion

As mentioned in the introduction, it is an open question to determine the values of $n$ for which $n\overrightarrow{\mathbf{C}}_3$ has a graceful labeling, i.e., an injection $f: V \to \{0, 1, \dots, q\}$ such that, when each arc $xy$ is assigned the label $(f(y) - f(x)) \pmod q + 1)$, the resulting arc labels are distinct. Considering graceful difference labelings, we could show that $n\overrightarrow{\mathbf{C}}_3$ has a gdl if and only if $n \ge 2$. We have also proved additional cases that support the following conjecture.

**Conjecture 1.** If $G$ is the disjoint union of circuits, then $G$ has a gdl, unless $G = \overrightarrow{\mathbf{C}}_3$ or $G = \overrightarrow{\mathbf{C}}_2 + \overrightarrow{\mathbf{C}}_3$.

**Author Contributions:** All authors contributed equally to the writing of this paper. All authors read and approved the final manuscript.

**Conflicts of Interest:** "The authors declare no conflict of interest."

## References

[1] Gallian, J. A. (2009). A dynamic survey of graph labeling. *The electronic journal of combinatorics*, 16(6), 1-219.

[2] Rosa, A. (1966, July). On certain valuations of the vertices of a graph. In *Theory of Graphs* (Internat. Symposium, Rome* (pp. 349-355).

[3] Golomb, S. W. (1972). How to number a graph. In *Graph theory and computing* (pp. 23-37). Academic press.
[4] Feng, W., & Xu, C. (2011). A survey of the gracefulness of digraphs. *International Journal of Pure and Applied Mathematics*, 69(3), 245.

[5] West, D. B. (1996). *Introduction to graph theory* (Vol. 2). Upper Saddle River, NJ: Prentice hall.

<figure><img src="image_18.png" /></figure>

© 2019 by the authors; licensee PSRP, Lahore, Pakistan. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC-BY) license (http://creativecommons.org/licenses/by/4.0/).