Informal description
Let $f : \mathbb{Q} \times \mathbb{Q} \to \mathbb{Q}$ be a binary operation on rational numbers, and let $f_1, f_2 : \mathbb{Z}^4 \to \mathbb{Z}$ be integer-valued functions. Suppose that:
1. For any rational numbers $\langle n_1, d_1, h_1, c_1 \rangle$ and $\langle n_2, d_2, h_2, c_2 \rangle$, we have:
$$f\left(\langle n_1, d_1, h_1, c_1 \rangle, \langle n_2, d_2, h_2, c_2 \rangle\right) = \frac{f_1(n_1, d_1, n_2, d_2)}{f_2(n_1, d_1, n_2, d_2)}.$$
2. For any integers $n_1, d_1, n_2, d_2$ with $d_1 \neq 0$ and $d_2 \neq 0$, we have $f_2(n_1, d_1, n_2, d_2) \neq 0$.
3. For any integers $a, b, c, d$ with $b \neq 0$ and $d \neq 0$, and for any integers $n_1, d_1, n_2, d_2$ satisfying:
$$a \cdot d_1 = n_1 \cdot b \quad \text{and} \quad c \cdot d_2 = n_2 \cdot d,$$
we have the compatibility condition:
$$f_1(n_1, d_1, n_2, d_2) \cdot f_2(a, b, c, d) = f_1(a, b, c, d) \cdot f_2(n_1, d_1, n_2, d_2).$$
Then, for any integers $a, b, c, d$ with $b \neq 0$ and $d \neq 0$, we have:
$$f\left(\frac{a}{b}, \frac{c}{d}\right) = \frac{f_1(a, b, c, d)}{f_2(a, b, c, d)}.$$