depend on the path chosen.

Now, for each $d$, let $R_d = \cup_{i : d(i) = d} S_i$. Suppose that $S_i, S_j, S_k$ is a good triple, in that order (so, for example, the label on $S_i \rightarrow S_j$ is $a_2/a_1$). Then, setting $d$ = $a_1d(i)$, we have that $d(i) = d/a_1, d(j) = d/a_2 {\text{ and }}d(k) = d/a_3$.

Therefore, all of the solutions coming from the good triple $S_i, S_j, S_k$ will be counted in $T(R_{d/a_1}, R_{d/a_2}, R_{d/a_3})$, and so an upper bound for the total number of solutions coming from good triples is $$\sum_{d} T(R_{d/a_1}, R_{d/a_2}, R_{d/a_3}),$$ where the sum is taken over all $d$ such that all three of the $R_i$ exist (in particular, there can be no more than $n$ terms in the sum).

We may apply Lemma \[lem:uniform\_bound\_symmetric\] to give an upper bound for this. $$\begin{aligned}
\sum_{d} T(R_{d/a_1}, R_{d/a_2}, R_{d/a_3}) &{\leqslant}\frac{1}{4}\sum_d |R_{d/a_1}| |R_{d/a_2}| + |R_{d/a_1}| |R_{d/a_3}| + |R_{d/a_2}| |R_{d/a_3}| + 1 \nonumber\\
&{\leqslant}\frac{1}{4}\sum_{d_1 \sim d_2} |R_{d_1}||R_{d_2}| + K_1, \label{eqn:sum_of_RR}\end{aligned}$$ where the sum on the second line is over *unordered* pairs $d_1, d_2$ such that $d_1/d_2$ is equal to the ratio between two of the $a_i$. The second inequality follows because if $d_1 \sim d_2$, 