6
$\begingroup$

We have two functions: $$ f: \{0,1\}^* \to \{0,1\}^* $$ $$ g: \{0,1\}^* \to \{0,1\}^* $$ that commute: $$ f[g(x)] = g[f(x)] $$

These two functions can be calculated in polynomial time (in the length of the input). Moreover, the outputs have the same length of the inputs: $|f(x)| = |x|$ and $|g(x)| = |x|$ .

A trivial example of functions that commute can be easily constructed by splitting the strings into two parts and defining: $$ f(x,y) = ( a(x), y ) $$ and $$ g(x,y) = ( x, b(y) ) $$ where the functions $a(x)$ and $b(y)$ can be calculated in polynomial time (in their inputs).

I was able to construct slightly more complex examples, but not much more complex. In all the examples, the evolution obtained by repeatedly applying $f$ seems to be independent of the evolution obtained by repeatedly applying $g$. More rigorously, in my examples, the following proposition holds:

Proposition 1

There are two functions $n'$ and $m'$ depending on $n$ and $m$, at most polynomial, such that there is an algorithm that, for any integers $n$ and $m$, calculates the function $f^n[g^m(x)]$, operating in polynomial time (in the length of its input), and taking the following inputs: the numbers $n$ and $m$, $f^{n'}(x)$, and $g^{m'}(x)$.

I remark that this happens even if $n$ and $m$ increase exponentially in $|x|$.

In the trivial example above, setting $n'=n$ and $m'=m$, we see that $f^n(x)= ( a^n(x), y )$ and $g^m(x) = (x, b^m(y) )$, from which it is easy to calculate $f^n[g^m(x,y)] = ( a^n(x), b^m(y) ) $.

Is Prop. 1 a general theorem? Alternatively, is there a counter-example to Prop. 1?

Literature references, improved formalization of the problem, nomenclature, and any other suggestion are welcome.

$\endgroup$
10
  • 1
    $\begingroup$ For another example to consider, suppose $h \colon \{0,1\}^* \to \{0,1\}^*$ is any function of this type, and we have $f(x) = h(h(x))$, $g(x) = h(h(h(x)))$, or any other composition of this type. It is not quite clear to me what Proposition 1 means, but it's possible that it would be false in this case. $\endgroup$ Commented Oct 27, 2022 at 19:55
  • $\begingroup$ Rigorously, the example holds! You propose f(x)=h^2(x) and g(x)=h^3(x). Then f^n[g^m(x)] =h^(2n+3m)(x), that is equal to f^(n+3m/2)(x) only for even values of m. $\endgroup$ Commented Oct 27, 2022 at 20:08
  • $\begingroup$ I wasn't certain whether you allowed taking $n'$ or $m'$ to be $n+3m/2$. Another thought: what do you suggest doing with $f(x,y,z) = (a(x), b(y), z)$ and $g(x,y,z) = (x, b(y), c(z))$? $\endgroup$ Commented Oct 27, 2022 at 20:16
  • 1
    $\begingroup$ Well, if $m$ is odd, then you can take $f^{n+3(m-1)/2}(x)$ as input and apply $h$ to it! $\endgroup$ Commented Oct 27, 2022 at 20:22
  • 1
    $\begingroup$ "Given two integers n and m, there is an algorithm that calculates (...)": you should add that the algorithm does not depend upon $n$ or $m$. Otherwise just take $m'=m$ and the algorithm is $f^n$ applied to $g^m(x)$. $\endgroup$ Commented Oct 30, 2022 at 13:53

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.