Background. This question originates from the problem of finding a function $f$ such that its $n$-th iterate is equal to its $n$-th power, which I asked about here. Now I would like to focus on the related case $n = -1$, because it seems to be quite a different problem. In other words, I am looking for a function $f$ such that its compositional inverse is equal to its multiplicative inverse, that is, $$f^{-1}(x) = \frac 1 {f(x)}.$$ It is immediate to see that this is equivalent to $$f \left ( \frac 1 {f(x)} \right ) = x$$ which is the equation in the title.
I believe I have found an example of a function $f \colon \mathbb Q^+ \to \mathbb Q^+$ satisfying the equation, but it is quite convoluted. The construction is as follows:
Let $x \in \mathbb Q^+$. Then we can write $$x = \left ( \frac {p_1^{a_1} \dotsb p_h^{a_h}} {q_1^{b_1} \dotsb q_k^{b_k}} \right )^n$$ where $p_1, \dotsc, p_h, q_1, \dotsc, q_k$ are distinct prime factors, $p_1^{a_1} \dotsb p_h^{a_h} \le q_1^{b_1} \dotsb q_k^{b_k}$, the exponents $a_1, \dotsc, a_h, b_1, \dotsc, b_k$ are coprime positive integers, and $n \in \mathbb Z$. Then we define $$\rho \colon \mathbb Q^+ \to \mathbb Q^+ \qquad \rho (x) = \frac {p_1^{a_1} \dotsb p_h^{a_h}} {q_1^{b_1} \dotsb q_k^{b_k}}.$$ Clearly the image $\rho(\mathbb Q^+)$ is countably infinite, so we can fix two sequences $(r_m)_{m \in \mathbb N}$ and $(s_m)_{m \in \mathbb N}$ such that: $$r_0, s_0, r_1, s_1, \dotsc, r_m, s_m, \dotsc$$ is an injective enumeration of $\rho(\mathbb Q^+)$.
Notice then that each $x \in \mathbb Q^+$ is either $r_m^n$ or $s_m^n$ for some $m \in \mathbb N$ and $n \in \mathbb Z$, in a unique way. Therefore, we define $$f(r_m^n) = s_m^n \qquad f(s_m^n) = r_m^{-n}$$ for all $m \in \mathbb N$ and $n \in \mathbb Z$. With this definition, we can check that the above property is satisfied: $$f \left ( \frac 1 {f(r_m^n)} \right ) = f \left ( \frac 1 {s_m^n} \right ) = f (s_m^{-n}) = r_m^n$$ $$f \left ( \frac 1 {f(s_m^n)} \right ) = f \left ( \frac 1 {r_m^{-n}} \right ) = f (r_m^n) = s_m^n.$$
My questions are:
- Are there any less artificial functions satisfying the equation?
- If so, is there such a function that is defined on an interval of $\mathbb R$?
Remark. If $f$ is defined on an interval $I$ of $\mathbb R$ and is always positive (or negative), then it is monotonic. Indeed, if $f$ were increasing we would have $$x_1 < x_2 \implies f(x_1) < f(x_2) \implies \frac 1 {f(x_1)} > \frac 1 {f(x_2)} \implies x_1 > x_2$$ and similarly if $f$ were decreasing.